Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -25,7 +25,7 @@ embeddings = OpenAIEmbeddings(openai_api_key=openai_api_key)
|
|
25 |
#with open("index.pkl", "rb") as f:
|
26 |
#db = faiss.deserialize_index(f.read())
|
27 |
|
28 |
-
db = FAISS.load_local("index
|
29 |
|
30 |
def get_response_from_query(db, query, k=3):
|
31 |
|
|
|
25 |
#with open("index.pkl", "rb") as f:
|
26 |
#db = faiss.deserialize_index(f.read())
|
27 |
|
28 |
+
db = FAISS.load_local("index", embeddings, allow_dangerous_deserialization=True)
|
29 |
|
30 |
def get_response_from_query(db, query, k=3):
|
31 |
|