Skip to content

Using native upsert method for Milvus vector store #71

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Mateusz-Switala opened this issue May 13, 2025 · 2 comments
Closed

Using native upsert method for Milvus vector store #71

Mateusz-Switala opened this issue May 13, 2025 · 2 comments

Comments

@Mateusz-Switala
Copy link

Based on the source code, current langchain_milvus.Milvus.upsert methods delete the chunks with the proper ids from the collection and then insert the chunks provided in the method: https://github.com/langchain-ai/langchain-milvus/blob/main/libs/milvus/langchain_milvus/vectorstores/milvus.py#L1993-#L2024

However, since the last few Milvus versions, there is a native upsert method for MilvusClient: https://milvus.io/api-reference/pymilvus/v2.5.x/MilvusClient/Vector/upsert.md Using the dedicated method for the upsert process, may be a more efficient approach and will definitely reduce the code complexity.

Shouldn't the langchain_milvus.Milvus use the mative upsert method under the hood?

@zc277584121
Copy link
Collaborator

@Mateusz-Switala thanks, you are right, we will update it within few days

zc277584121 added a commit that referenced this issue May 30, 2025
as mentioned here
#71

Signed-off-by: ChengZi <[email protected]>
@zc277584121
Copy link
Collaborator

fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants