Skip to main content

Module search

Module search 

Source

Functionsยง

exact_terms_match
Returns true when every whitespace-separated term in query appears as a case-insensitive substring within candidate. Both query and candidate are expected to be pre-lowered (via normalize_query and construction-time lowering respectively), so this function performs zero allocations.
fuzzy_match
Returns true when every term in the query appears as a fuzzy match within the candidate text using nucleo-matcher.
fuzzy_score
Returns a score for the fuzzy match between query and candidate using nucleo-matcher. Returns None if no match is found, Some(score) if a match exists.
fuzzy_subsequence
Returns true when the characters from needle can be found in order within haystack (kept for backward compatibility).
normalize_query
Normalizes a user-provided query by trimming whitespace, collapsing internal spaces, and converting everything to lowercase ASCII.