Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -164,7 +164,7 @@ def search():
|
|
| 164 |
# 2. Filter based on the raw L2 distance score. Lower is better.
|
| 165 |
# A threshold of 1.0 is a good starting point. You can make it smaller (e.g., 0.8)
|
| 166 |
# for stricter matches, or larger for looser matches.
|
| 167 |
-
score_threshold = 1.
|
| 168 |
filtered_results = [(doc, score) for doc, score in results_with_scores if score < score_threshold]
|
| 169 |
|
| 170 |
# 3. Pass the correctly filtered list to the formatting function.
|
|
|
|
| 164 |
# 2. Filter based on the raw L2 distance score. Lower is better.
|
| 165 |
# A threshold of 1.0 is a good starting point. You can make it smaller (e.g., 0.8)
|
| 166 |
# for stricter matches, or larger for looser matches.
|
| 167 |
+
score_threshold = 1.5
|
| 168 |
filtered_results = [(doc, score) for doc, score in results_with_scores if score < score_threshold]
|
| 169 |
|
| 170 |
# 3. Pass the correctly filtered list to the formatting function.
|