θΏ™ζ˜―indexlocζδΎ›ηš„ζœεŠ‘οΌŒδΈθ¦θΎ“ε…₯任何密码
Skip to content

Conversation

@aeromech-1
Copy link
Contributor

Pull Request Type

  • ✨ feat
  • πŸ› fix
  • ♻️ refactor
  • πŸ’„ style
  • πŸ”¨ chore
  • πŸ“ docs

Relevant Issues

resolves #4544

What is in this change?

This change corrects the batching logic in the Qdrant vector provider (index.js).

Previously, the code would attempt to upsert all generated vector chunks in a single request. This caused an error when the number of chunks exceeded Qdrant's batch limit (e.g., >500).

The fix ensures the code properly iterates through the pre-defined chunks and sends them in smaller, valid batches, allowing for the successful embedding of documents with a large number of chunks.

Additional Information

This issue was discovered when a less aggressive chunking strategy was used on a document, increasing the chunk count from ~200 to ~2000, which triggered the bug.

Developer Validations

  • I ran yarn lint from the root of the repo & committed changes
  • Relevant documentation has been updated
  • I have tested my code functionality
  • Docker build succeeds locally

@timothycarambat
Copy link
Member

Changed the original O(3N) complexity of the batch creation to be O(N). Otherwise LGTM

@timothycarambat timothycarambat merged commit 985527c into Mintplex-Labs:master Oct 15, 2025
@aeromech-1 aeromech-1 deleted the fix/qdrant-batching branch October 15, 2025 19:43
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

Successfully merging this pull request may close these issues.

[BUG]: Qdrant integration fails on document upload with more than 500 chunks

2 participants