langchain
b5d67049 - partners/milvus: allow creating a vectorstore with sparse embeddings (#25284)

Commit
1 year ago
partners/milvus: allow creating a vectorstore with sparse embeddings (#25284) # Description Milvus (and `pymilvus`) recently added the option to use [sparse vectors](https://milvus.io/docs/sparse_vector.md#Sparse-Vector) with appropriate search methods (e.g., `SPARSE_INVERTED_INDEX`) and embeddings (e.g., `BM25`, `SPLADE`). This PR allow creating a vector store using langchain's `Milvus` class, setting the matching vector field type to `DataType.SPARSE_FLOAT_VECTOR` and the default index type to `SPARSE_INVERTED_INDEX`. It is only extending functionality, and backward compatible. ## Note I also interested in extending the Milvus class further to support multi vector search (aka hybrid search). Will be happy to discuss that. See [here](https://github.com/langchain-ai/langchain/discussions/19955), [here](https://github.com/langchain-ai/langchain/pull/20375), and [here](https://github.com/langchain-ai/langchain/discussions/22886) similar needs. --------- Co-authored-by: Erick Friis <erick@langchain.dev>
Author
Parents
Loading