Skip to content

Commit 5f0b19d

Browse files
authored
Merge pull request #48 from RobinL/issue_40
(WIP) Get rid of Levenstein dep
2 parents b5ad5a7 + f102e07 commit 5f0b19d

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

fuzzymatcher/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from metaphone import doublemetaphone
2-
from Levenshtein import ratio
2+
from fuzzywuzzy.fuzz import ratio
33

44
def tokens_to_dmetaphones(tokens):
55
new_tokens = []
@@ -40,7 +40,7 @@ def is_mispelling(token_left, token_right):
4040
if len(dml.intersection(dmr).difference({''})) > 0:
4141
return True
4242

43-
if ratio(token_left, token_right) >= 0.9:
43+
if ratio(token_left, token_right) >= 90:
4444
return True
4545

4646
return False

requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
pandas>=0.20.3
22
metaphone
3-
python-Levenshtein
43
fuzzywuzzy
54
python-dateutil

0 commit comments

Comments
 (0)