Spaces:
Sleeping
Sleeping
Update app/utils/faiss_index.py
Browse files- app/utils/faiss_index.py +4 -4
app/utils/faiss_index.py
CHANGED
|
@@ -13,10 +13,10 @@ db = client["clinical_trials_db"]
|
|
| 13 |
collection = db["trial_details"]
|
| 14 |
|
| 15 |
# Paths
|
| 16 |
-
|
| 17 |
-
os.
|
| 18 |
-
|
| 19 |
-
|
| 20 |
|
| 21 |
# FAISS setup
|
| 22 |
dimension = 768
|
|
|
|
| 13 |
collection = db["trial_details"]
|
| 14 |
|
| 15 |
# Paths
|
| 16 |
+
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 17 |
+
faiss_index_path = os.path.join(BASE_DIR, "../../clinical_trials.index")
|
| 18 |
+
id_mapping_path = os.path.join(BASE_DIR, "../../faiss_id_mapping.json")
|
| 19 |
+
")
|
| 20 |
|
| 21 |
# FAISS setup
|
| 22 |
dimension = 768
|