Spaces:
Runtime error
Runtime error
mend
Browse files- app.py +4 -2
- data/my_faiss_index.json +1 -1
app.py
CHANGED
|
@@ -162,8 +162,10 @@ def start_haystack():
|
|
| 162 |
except:
|
| 163 |
pass
|
| 164 |
shutil.copy("./data/faiss_document_store.db", ".")
|
| 165 |
-
document_store = FAISSDocumentStore
|
| 166 |
-
|
|
|
|
|
|
|
| 167 |
print(f"Index size: {document_store.get_document_count()}")
|
| 168 |
retriever = EmbeddingRetriever(
|
| 169 |
document_store=document_store,
|
|
|
|
| 162 |
except:
|
| 163 |
pass
|
| 164 |
shutil.copy("./data/faiss_document_store.db", ".")
|
| 165 |
+
document_store = FAISSDocumentStore(
|
| 166 |
+
faiss_index_path=f"./data/my_faiss_index.faiss",
|
| 167 |
+
faiss_config_path=f"./data/my_faiss_index.json",
|
| 168 |
+
)
|
| 169 |
print(f"Index size: {document_store.get_document_count()}")
|
| 170 |
retriever = EmbeddingRetriever(
|
| 171 |
document_store=document_store,
|
data/my_faiss_index.json
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
{"similarity": "cosine", "embedding_dim": 512, "sql_url": "sqlite:///
|
|
|
|
| 1 |
+
{"similarity": "cosine", "embedding_dim": 512, "sql_url": "sqlite:///faiss_document_store.db"}
|