Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -84,7 +84,7 @@ def search_courses(query):
|
|
| 84 |
query_embedding = model.encode([query])
|
| 85 |
|
| 86 |
# Search for the closest courses using FAISS
|
| 87 |
-
top_k =
|
| 88 |
distances, indices = index.search(np.array(query_embedding), top_k)
|
| 89 |
|
| 90 |
# Collect the results based on the indices returned by FAISS
|
|
|
|
| 84 |
query_embedding = model.encode([query])
|
| 85 |
|
| 86 |
# Search for the closest courses using FAISS
|
| 87 |
+
top_k = 6 # Retrieve the top 6 closest matches
|
| 88 |
distances, indices = index.search(np.array(query_embedding), top_k)
|
| 89 |
|
| 90 |
# Collect the results based on the indices returned by FAISS
|