Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -44,8 +44,9 @@ def respond(
|
|
44 |
scores = (query_embeddings @ encoded_questions.T) * 100
|
45 |
selected_references['similarity'] = scores.tolist()[0]
|
46 |
sorted_references = selected_references.sort_values(by='similarity', ascending=False)
|
47 |
-
sorted_references =
|
48 |
sorted_references = selected_references.sort_values(by='similarity', ascending=True)
|
|
|
49 |
print(sorted_references['similarity'].tolist())
|
50 |
|
51 |
from googletrans import Translator
|
|
|
44 |
scores = (query_embeddings @ encoded_questions.T) * 100
|
45 |
selected_references['similarity'] = scores.tolist()[0]
|
46 |
sorted_references = selected_references.sort_values(by='similarity', ascending=False)
|
47 |
+
sorted_references = sorted_referencesiloc[:3]
|
48 |
sorted_references = selected_references.sort_values(by='similarity', ascending=True)
|
49 |
+
print(sorted_references.shape[0])
|
50 |
print(sorted_references['similarity'].tolist())
|
51 |
|
52 |
from googletrans import Translator
|