-
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
Function score: score_mode avg looks broken #19068
Comments
Well, I see the problem, but I don't know enough to understand why it's being done this way. Perhaps not for a real reason and it's just incorrect? When a I'm not sure why the |
@brwe What do you think? |
Ah, I see. Perhaps we should re-add a basic, unweighted average as
I'm not sure this would work when you want to use more complex queries/filters? E.g. if docA matches |
I think Britta meant using a
|
yes
If we find we need an unweighted average then I'd prefer the latter option. |
Ah, I see. Thanks for the explanation :) |
This isn't the first time this has come up, perhaps it should be better explained in the docs? https://www.elastic.co/guide/en/elasticsearch/reference/2.3/query-dsl-function-score-query.html |
yes, I opened #19154 |
It seems like this was addressed in documentation in #19154 so I'll close this issue. If there is more to be done please reopen |
Elasticsearch version: 2.3.3
The function score with
score_mode: avg
looks broken:All the scores are now
1
if you change to
"score_mode": "sum",
everything works as expected, with 10, 20 and 30 being the score.The text was updated successfully, but these errors were encountered: