Files
langchain-python/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
```
2023-02-17 15:12:31 -08:00
..
2023-02-12 17:43:48 -08:00
2023-02-02 22:05:47 -08:00
2022-12-19 17:09:27 -05:00
2023-01-20 07:42:08 -08:00