-
Notifications
You must be signed in to change notification settings - Fork 25k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Painless Context Doc: Add min should match example #35423
Painless Context Doc: Add min should match example #35423
Conversation
Pinging @elastic/es-core-infra |
actors play. You have a list of favorite actors in mind, and you want | ||
to find performances that have at least certain minimum number of actors | ||
from your favorite list. `terms_set` query with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of "where your favorite actors play", maybe "by your favorite actors."?
The second sentence could be pared down to: "You have a list of favorite actors in mind, and you want to find performances where the cast includes at least a certain number of them."
the parameter `num_terms`, which represents the length of the list of | ||
your favorite actors. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd pare this down to: "To ensure that the minimum number of actors doesn't exceed the number of favorite actors, you can use num_terms
to get the number of actors in the list and Math.min
to get the lesser of the two."
|
||
Submit the following request to find seats to performances with your favorite actors: | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"The following request finds seats to performances with at least two of the three specified actors."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tech side looks good to me. Really good example - thank you!
@debadair Thank you for your feedback. I have modified the doc file according to it. Please let me know if this PR is ready for the approval. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…min-should-match-example
relates to #34829