If you want to use similar fuzzy matching in plugins without feeding it through the quick panel or writing your own algorithm, you can try using difflib.
[code]>>> get_close_matches(‘appel’, ‘ape’, ‘apple’, ‘peach’, ‘puppy’])
‘apple’, ‘ape’]
import keyword
get_close_matches(‘wheel’, keyword.kwlist)
‘while’]
get_close_matches(‘apple’, keyword.kwlist)
]
get_close_matches(‘accept’, keyword.kwlist)
‘except’]
[/code]
You can control the fuzziness and the number of return values.
[code]difflib.get_close_matches(word, possibilities, n], cutoff])
Return a list of the best “good enough” matches. word is a sequence for which close matches are desired (typically a string), and possibilities is a list of sequences against which to match word (typically a list of strings).
Optional argument n (default 3) is the maximum number of close matches to return; n must be greater than 0.
Optional argument cutoff (default 0.6) is a float in the range [0, 1]. Possibilities that don’t score at least that similar to word are ignored.
The best (no more than n) matches among the possibilities are returned in a list, sorted by similarity score, most similar first.[/code]
There are also other functions as well for different purposes or different applications.
docs.python.org/library/difflib.html