Closed Neeraj-Ghodla closed 1 year ago
This PR address this Github issue by adding support for fuzzy matching in Full-Text search.
To add fuzzy matching support, the function definition for match and matches methods have been modified
match
matches
from
match(value: string | number | boolean): Search matches(value: string | number | boolean): Search
to
match(value: string | number | boolean, options?: { fuzzyMatching?: boolean; levenshteinDistance?: 1 | 2 | 3 }): Search matches(value: string | number | boolean, options?: { fuzzyMatching?: boolean; levenshteinDistance?: 1 | 2 | 3 }): Search
The fuzzyMatching parameter is used to enable fuzzy matching and the levenshteinDistance parameter is used to define the Levenshtein distance for fuzzy matching.
fuzzyMatching
levenshteinDistance
For more info about fuzzy matching with Redis please checkout the Redis docs
Probably gonna do a publish with a couple of community PRs in the next week or so. This will be amongst them. Thanks!
Merged and published. https://www.npmjs.com/package/redis-om
This PR address this Github issue by adding support for fuzzy matching in Full-Text search.
To add fuzzy matching support, the function definition for
match
andmatches
methods have been modifiedfrom
to
The
fuzzyMatching
parameter is used to enable fuzzy matching and thelevenshteinDistance
parameter is used to define the Levenshtein distance for fuzzy matching.For more info about fuzzy matching with Redis please checkout the Redis docs