- Notifications
You must be signed in to change notification settings - Fork 25.5k
Closed
Labels
:Search Relevance/SearchCatch all for Search RelevanceCatch all for Search Relevancebug"" muted="" aria-describedby="MDU6TGFiZWwyMzE3Mw==-tooltip :R5b96b:">>bugTeam:Search RelevanceMeta label for the Search Relevance team in ElasticsearchMeta label for the Search Relevance team in Elasticsearchpriority:highA label for assessing bug priority to be used by ES engineersA label for assessing bug priority to be used by ES engineers
Description
Elasticsearch Version
8.18
Installed Plugins
No response
Java Version
23.0.2
OS Version
22.6.0 Darwin Kernel Version
Problem Description
_score is always 0 when DSL filter is being applied. This is extremely important for kibana as prefiltering is always added.
Steps to Reproduce
Check this:
POST _query/async { "query": "FROM movies METADATA _score | WHERE Title: \"Shakespeare\" | sort _score DESC | KEEP Title, _score", "locale": "en", "include_ccs_metadata": true, "filter": { "bool": { "must": [], "filter": [], "should": [], "must_not": [] } } }
This returns:
#! No limit defined, adding default limit of [1000] { "is_running": false, "took": 4, "is_partial": false, "columns": [ { "name": "Title", "type": "text" }, { "name": "_score", "type": "double" } ], "values": [ [ "Shakespeare in Love", 0 ], [ "Shakespeare in Love", 0 ], [ "Shakespeare in Love", 0 ] ] }
If I remove the DSL:
POST _query/async { "query": "FROM movies METADATA _score | WHERE Title: \"Shakespeare\" | sort _score DESC | KEEP Title, _score", "locale": "en", "include_ccs_metadata": true }
#! No limit defined, adding default limit of [1000] { "is_running": false, "took": 4, "is_partial": false, "columns": [ { "name": "Title", "type": "text" }, { "name": "_score", "type": "double" } ], "values": [ [ "Shakespeare in Love", 7.960540771484375 ], [ "Shakespeare in Love", 7.960540771484375 ], [ "Shakespeare in Love", 7.960540771484375 ] ] }
Logs (if relevant)
No response
Metadata
Metadata
Assignees
Labels
:Search Relevance/SearchCatch all for Search RelevanceCatch all for Search Relevancebug"" muted="" aria-describedby="MDU6TGFiZWwyMzE3Mw==-tooltip :Ra5pmb:">>bugTeam:Search RelevanceMeta label for the Search Relevance team in ElasticsearchMeta label for the Search Relevance team in Elasticsearchpriority:highA label for assessing bug priority to be used by ES engineersA label for assessing bug priority to be used by ES engineers