[GH-ISSUE #4308] [BUG]: RAG returns same chunk multiple times #2737

Closed
opened 2026-02-22 18:31:01 -05:00 by yindo · 2 comments
Owner

Originally created by @mihkeltiks on GitHub (Aug 18, 2025).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/4308

Originally assigned to: @shatfield4 on GitHub.

How are you running AnythingLLM?

Docker (local)

What happened?

I am getting multiple returns for the same chunk from one document using a chunk size of 512 and overlap of 52. Is this some configuration issue on my side or an intended mechanism?

Image

Are there known steps to reproduce?

No response

Originally created by @mihkeltiks on GitHub (Aug 18, 2025). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/4308 Originally assigned to: @shatfield4 on GitHub. ### How are you running AnythingLLM? Docker (local) ### What happened? I am getting multiple returns for the same chunk from one document using a chunk size of 512 and overlap of 52. Is this some configuration issue on my side or an intended mechanism? <img width="675" height="672" alt="Image" src="https://github.com/user-attachments/assets/98fac2b0-22dd-483e-a6e2-9f08b52d5a86" /> ### Are there known steps to reproduce? _No response_
yindo added the possible buginvestigating labels 2026-02-22 18:31:01 -05:00
yindo closed this issue 2026-02-22 18:31:01 -05:00
Author
Owner

@timothycarambat commented on GitHub (Aug 19, 2025):

Depending on the main document, this could very well just be chunking + overlapping - however, it seems they are all the same, even semantically. We do de-dupe based on vector id, so these should all be vector IDs that are different since we dont do direct string comparison.

Can you provide some more information on the document, workspace vector count - just trying to repro this.

@timothycarambat commented on GitHub (Aug 19, 2025): Depending on the main document, this could very well just be chunking + overlapping - however, it seems they are all the same, even semantically. We do de-dupe based on vector id, so these _should_ all be vector IDs that are different since we dont do direct string comparison. Can you provide some more information on the document, workspace vector count - just trying to repro this.
Author
Owner

@mihkeltiks commented on GitHub (Aug 19, 2025):

Okay, after resetting the vector database in the workspace I found this no longer happens. I expected this sort of "reset" to happen after removing the documents from the right side of "Embed a document" as well, but it seems that after removing and adding a few times, the old values stuck around. This can be closed from my side, but might be something to look into! :)

@mihkeltiks commented on GitHub (Aug 19, 2025): Okay, after resetting the vector database in the workspace I found this no longer happens. I expected this sort of "reset" to happen after removing the documents from the right side of "Embed a document" as well, but it seems that after removing and adding a few times, the old values stuck around. This can be closed from my side, but might be something to look into! :)
yindo changed title from [BUG]: RAG returns same chunk multiple times to [GH-ISSUE #4308] [BUG]: RAG returns same chunk multiple times 2026-06-05 14:48:16 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#2737