Repository navigation
feat(filter): match multi-word queries as an AND of terms - #1768
Merged
Merged
Conversation
Exact phrase hits still rank first. Space-separated words also match filenames that contain every word, so "duck txt" finds ducks_in_the_pool.txt.
Multi-word queries apply typo tolerance per word, so the filter change classifier must look at each word rather than the whole query; otherwise GTK keeps rows hidden that a typo-eligible word now matches. Also match a single word with trailing whitespace, drop the scoring offset that could not change ordering within a query, and document the behavior.
Contributor
|
Review pass: merged Fixed
Simplified
Verification
|
IKurokami
pushed a commit
to IKurokami/strata
that referenced
this pull request
Oct 23, 2026
* feat(filter): match multi-word queries as an AND of terms Exact phrase hits still rank first. Space-separated words also match filenames that contain every word, so "duck txt" finds ducks_in_the_pool.txt. * fix(filter): classify typo eligibility per word for multi-word queries Multi-word queries apply typo tolerance per word, so the filter change classifier must look at each word rather than the whole query; otherwise GTK keeps rows hidden that a typo-eligible word now matches. Also match a single word with trailing whitespace, drop the scoring offset that could not change ordering within a query, and document the behavior. --------- Co-authored-by: Ray Winkelman <[email protected]> Co-authored-by: Pierre Berube <[email protected]> (cherry picked from commit fd63272)
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Filename filter and search now treat space-separated queries as an AND of words after checking for an exact phrase. Typing
duck txtstill prefers names that contain that phrase, and also finds names likeducks_in_the_pool.txtthat contain every word.Wildcard (
*) patterns are unchanged.Visual evidence
N/A. Matching behavior is covered by unit tests; the listing UI is unchanged.
How to test
ducks_in_the_pool.txtandduck report.txt.duck txt.Expected result: both files appear; names that contain the contiguous phrase rank ahead of scattered multi-word hits.
Related issue
Closes #1693