You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
langchain/langchain/vectorstores
Tom Bocklisch 47c3221fda
Max marginal relecance search fails if there are not enough docs (#1117)
Implementation fails if there are not enough documents. Added the same
check as used for similarity search.

Current implementation raises
```  
File ".venv/lib/python3.9/site-packages/langchain/vectorstores/faiss.py", line 160, in max_marginal_relevance_search
    _id = self.index_to_docstore_id[i]
KeyError: -1
```
1 year ago
..
__init__.py Chroma in LangChain (#1010) 1 year ago
base.py Support similarity search by vector (in FAISS) (#961) 1 year ago
chroma.py Fix typo in integration with Chroma (#1070) 1 year ago
elastic_vector_search.py add search kwargs (#664) 1 year ago
faiss.py Max marginal relecance search fails if there are not enough docs (#1117) 1 year ago
milvus.py Harrison/milvus (#856) 1 year ago
pinecone.py added i_end in batch extraction (#907) 1 year ago
qdrant.py Hotfix: Qdrant content retrieval (revert: #1088) (#1093) 1 year ago
utils.py MMR example selector (#377) 2 years ago
weaviate.py add search kwargs (#664) 1 year ago