How to use a persistent vector store as the docstore in a MultiVectorRetriever setup #27236
latifs
announced in
Ask Dosu (Archived)
Replies: 1 comment 1 reply
-
I found some similar discussions that might help:
To use a persistent vector store as the docstore in a
Here's a simplified example: from langchain_pinecone import PineconeVectorStore
from langchain.retrievers.multi_vector import MultiVectorRetriever
# Initialize Pinecone vector stores
summaries_vectorstore = PineconeVectorStore(index=index, embedding=embeddings, namespace=f"{namespace}_summaries")
full_text_vectorstore = PineconeVectorStore(index=index, embedding=embeddings, namespace=f"{namespace}_full")
# Create MultiVectorRetriever
retriever = MultiVectorRetriever(
vectorstore=summaries_vectorstore,
docstore=full_text_vectorstore,
id_key="doc_id",
) This setup allows you to use |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Trying to pass a persistent vector Store as a docstore in a MultiVectorRetriever setup:
Since I wanted to persist the inMemoryVectorStore just in case.
how could I either transform my full_text_vector store to a inMemory one
Beta Was this translation helpful? Give feedback.
All reactions