Skip to content

[docs] nested knn only supports score_mode max #125582

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

Merged
merged 2 commits into from
Mar 26, 2025

Conversation

tteofili
Copy link
Contributor

@tteofili tteofili commented Mar 25, 2025

docs need to mention that nested knn queries only support score_mode=max.
see #122625

@elasticsearchmachine elasticsearchmachine added the needs:triage Requires assignment of a team area label label Mar 25, 2025
@tteofili tteofili added >docs General docs changes :Search Relevance/Search Catch all for Search Relevance labels Mar 25, 2025
@tteofili tteofili added the priority:normal A label for assessing bug priority to be used by ES engineers label Mar 25, 2025
@elasticsearchmachine elasticsearchmachine added Team:Docs Meta label for docs team Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch and removed needs:triage Requires assignment of a team area label labels Mar 25, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-docs (Team:Docs)

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-search-relevance (Team:Search Relevance)

@@ -71,7 +71,7 @@ See [Multi-level nested queries](#multi-level-nested-query-ex) for an example.


`score_mode`
: (Optional, string) Indicates how scores for matching child objects affect the root parent document’s [relevance score](/reference/query-languages/query-dsl/query-filter-context.md#relevance-scores). Valid values are:
: (Optional, string) Indicates how scores for matching child objects affect the root parent document’s [relevance score](/reference/query-languages/query-dsl/query-filter-context.md#relevance-scores). Default is `avg`, but nested `knn` queries only support `score_mode=max`. Valid values are:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mind also putting a reference on query-dsl-knn-query.md There is a section there on Knn query inside a nested query

Also, it seems like we need to also now update: https://github.com/elastic/docs-content/blob/main/solutions/search/vector/knn.md in a separate PR.

Copy link
Member

@benwtrent benwtrent left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call out, added two more places where we should mention this if its not already mentioned.

@tteofili tteofili merged commit 7a610c3 into elastic:main Mar 26, 2025
6 checks passed
tteofili added a commit to elastic/docs-content that referenced this pull request Mar 26, 2025
documentation fix related to
[this](elastic/elasticsearch#122625), this
adds a note that nested KNN queries only support `score_mode=max`.
see also elastic/elasticsearch#125582.
omricohenn pushed a commit to omricohenn/elasticsearch that referenced this pull request Mar 28, 2025
* [docs] nested knn only supports score_mode max
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>docs General docs changes priority:normal A label for assessing bug priority to be used by ES engineers :Search Relevance/Search Catch all for Search Relevance Team:Docs Meta label for docs team Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants