Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -97,8 +97,8 @@ def get_top_chunks(query, chunk_embeddings, text_chunks):
|
|
| 97 |
top_chunks = []
|
| 98 |
|
| 99 |
# Loop through the top indices and retrieve the corresponding text chunks
|
| 100 |
-
for
|
| 101 |
-
top_chunks.append(
|
| 102 |
|
| 103 |
# Return the list of most relevant chunks
|
| 104 |
return top_chunks
|
|
|
|
| 97 |
top_chunks = []
|
| 98 |
|
| 99 |
# Loop through the top indices and retrieve the corresponding text chunks
|
| 100 |
+
for i in top_indices:
|
| 101 |
+
top_chunks.append(text_chunks[i])
|
| 102 |
|
| 103 |
# Return the list of most relevant chunks
|
| 104 |
return top_chunks
|