Spaces:
Runtime error
Runtime error
Update agent.py
Browse files
agent.py
CHANGED
@@ -389,7 +389,7 @@ texts = [doc.page_content for doc in docs]
|
|
389 |
# Initialize the embedding model
|
390 |
embedding_model = HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
|
391 |
|
392 |
-
docs = [Document(page_content=
|
393 |
|
394 |
# Create the FAISS index
|
395 |
#vector_store = FAISS.from_documents(docs, embedding_model)
|
|
|
389 |
# Initialize the embedding model
|
390 |
embedding_model = HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
|
391 |
|
392 |
+
docs = [Document(page_content=texts, metadata={"task_id": item["task_id"]}) for item in data]
|
393 |
|
394 |
# Create the FAISS index
|
395 |
#vector_store = FAISS.from_documents(docs, embedding_model)
|