The query string and the fuzziness parameter use the Damerau-Levenshtein distance to find the terms.
cntrl~1
means that the search terms will match the original document containing central
, only if the edit distance equals 1.
Edit distance here means that the search term will match the original term, either by adding, deleting, or transposing the characters once, i.e. the original term should be restored in 1 step.
For Example:
The original term is central
cntrl
-> centrl
-> central
(2 steps, so this will not match with (~1))
centrl
-> central
(1 step so this will match with (~1))
And in the case of AUTO
, the following rule is applied
Generates an edit distance based on the length of the term. Low and high distance arguments may be optionally provided AUTO:[low],[high]. If not specified, the default values are 3 and 6, equivalent to AUTO:3,6 that make for lengths:
0..2 Must match exactly
3..5 One edit allowed
5 Two edits allowed