Spaces:
Sleeping
Sleeping
Update utils.py
Browse files
utils.py
CHANGED
|
@@ -248,7 +248,7 @@ def _get_idiom_meaning_embeddings(idiom_map_tuple):
|
|
| 248 |
embeddings = model.encode(meanings, convert_to_tensor=True)
|
| 249 |
return idioms, embeddings
|
| 250 |
# DETECT IDIOMS
|
| 251 |
-
def detect_idioms_ai(text, idiom_map, threshold=0.
|
| 252 |
model = load_similarity_model()
|
| 253 |
|
| 254 |
idiom_map_tuple = tuple(
|
|
|
|
| 248 |
embeddings = model.encode(meanings, convert_to_tensor=True)
|
| 249 |
return idioms, embeddings
|
| 250 |
# DETECT IDIOMS
|
| 251 |
+
def detect_idioms_ai(text, idiom_map, threshold=0.3):
|
| 252 |
model = load_similarity_model()
|
| 253 |
|
| 254 |
idiom_map_tuple = tuple(
|