Skip to content

fix: max_score when used with full_score - #1

Merged
piki merged 2 commits into
mainfrom
fix/max-score-policy
Sep 17, 2026
Merged

piki merged 2 commits into
mainfrom
fix/max-score-policy

Conversation

@darwich6

Copy link
Copy Markdown
Contributor

max_score() used the regular scoring policy even when paired with full_score(). Frequent terms and scoring stop words could therefore contribute to the numerator but not the denominator, producing incorrect normalization or a zero maximum.
Make max_score() use full scoring when a corresponding full_score() appears in the same query level.

Add a regression test covering both operand orders and a max_score() > 0 filter.

@darwich6
darwich6 requested a review from piki September 17, 2026 19:13
@piki
piki merged commit 0e29dbe into main Sep 17, 2026
8 checks passed
@darwich6
darwich6 deleted the fix/max-score-policy branch September 17, 2026 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants