Spaces:
Sleeping
Sleeping
Update modelo.py
Browse files
modelo.py
CHANGED
@@ -31,7 +31,7 @@ def get_chain():
|
|
31 |
docs = text_splitter.split_documents(data)
|
32 |
#DB y retriever
|
33 |
db = FAISS.from_documents(docs, embeddings) # Create a retriever object from the 'db' with a search configuration where it retrieves up to 4 relevant splits/documents.
|
34 |
-
db = FAISS.
|
35 |
|
36 |
retriever = db.as_retriever(search_kwargs={"k": 3})
|
37 |
|
|
|
31 |
docs = text_splitter.split_documents(data)
|
32 |
#DB y retriever
|
33 |
db = FAISS.from_documents(docs, embeddings) # Create a retriever object from the 'db' with a search configuration where it retrieves up to 4 relevant splits/documents.
|
34 |
+
db = FAISS.save_local("cache")
|
35 |
|
36 |
retriever = db.as_retriever(search_kwargs={"k": 3})
|
37 |
|