Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -83,7 +83,7 @@ def find_similar_texts2(df1, df2, column_name, exact_matches, threshold=0.3):
|
|
83 |
for j, row2 in df2.iterrows():
|
84 |
if i not in exact_match_indices and j not in exact_match_indices:
|
85 |
similarity = similarity_matrix[i, len(df1) + j]
|
86 |
-
if similarity
|
87 |
# Calculate Levenshtein distance between strings
|
88 |
distance = levenshtein_distance(row1[column_name], row2[column_name])
|
89 |
max_length = max(len(row1[column_name]), len(row2[column_name]))
|
|
|
83 |
for j, row2 in df2.iterrows():
|
84 |
if i not in exact_match_indices and j not in exact_match_indices:
|
85 |
similarity = similarity_matrix[i, len(df1) + j]
|
86 |
+
if similarity ==1: # EXact matches
|
87 |
# Calculate Levenshtein distance between strings
|
88 |
distance = levenshtein_distance(row1[column_name], row2[column_name])
|
89 |
max_length = max(len(row1[column_name]), len(row2[column_name]))
|