Fuzzy string matching like a boss.
How to get started? First you should know Python programming.
pip install fuzzywuzzy
Then you can use it like this:
#!/usr/bin/python3 from fuzzywuzzy import fuzz from fuzzywuzzy import process r = fuzz.ratio("this is a test", "this is a test!") print(r) r = fuzz.ratio("fuzzy wuzzy was a bear", "wuzzy fuzzy was a bear") print(r)
This outputs the ratio:
You can run this from the interpreter:
>>> fuzz.ratio("this is a test", "this is a test!") 97
Another example of fuzzywuzzy:
>>> from fuzzywuzzy import fuzz >>> fuzz.ratio("this is a test","a test this is") 50