You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
variation of the spelling type for the rewritten/alternative queries
but no alteration of the logic for the original query part (lines 122-124)
Second part: for the original query part, we might want to do the same, but I must admit I don't understand that legacy logic behind enforcing SPELLING_TYPE_EXACT for the original query.
I get the flawed legacy for the rewritten queries : "how, if we have a synonym, then that means the rewritten query has an exact word" (ignoring the case of multi-terms queries).
rbayet
changed the title
[Thesaurus] Do not always enforce SPELLING_TYPE_EXACT for rewritten queries
[Thesaurus] [DO NOT MERGE] Do not always enforce SPELLING_TYPE_EXACT for rewritten queries
Feb 11, 2026
Second part: for the original query part, we might want to do the same, but I must admit I don't understand that legacy logic behind enforcing SPELLING_TYPE_EXACT for the original query. I get the flawed legacy for the rewritten queries : "how, if we have a synonym, then that means the rewritten query has an exact word" (ignoring the case of multi-terms queries).
After internal discussion, we'll keep the logic of switching the original query to SPELLING_TYPE_EXACT whatever the number of terms.
The original idea was probably (and especially for single term query) :
I'm searching for X that does not exist in the engine, so the term vector will tell me to enable fuzziness
But I have a synonym rule, so I'll search also for Y
And since I don't want the results for synonym Y to be polluted by fuzzy matches for X, I'll force the search for X to be EXACT
That original idea is also tangentially correct for multiple terms query, so we'll keep things as is.
rbayet
changed the title
[Thesaurus] [DO NOT MERGE] Do not always enforce SPELLING_TYPE_EXACT for rewritten queries
[Thesaurus] Do not always enforce SPELLING_TYPE_EXACT for rewritten queries
Feb 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.