aws-samples / aws-samples/bedrock-chat
[BUG] "When using a chatbot with a dictionary set to large chunks (e.g., 4096), an error occurs after asking questions two or more times
- Dominant language
- TypeScript
- Stars
- 1.3k
- Forks
- 535
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 10
Description
## Describe the bug
When using a chatbot with a dictionary set to large chunks (e.g., 4096) , an error occurs after asking questions two or more times.
## To Reproduce
Steps to reproduce the behavior:
1. Create Chatbot
large chunks (e.g., 4096) & Contextual Grounding threshold is set to 0
2. asking questions two or more
3. See error
## Screenshots
1. Chatbot Setting

3.

## Additional context
・Confirmed conditions:
Reproduced with hierarchical chunks
Parent Chunksize=4096, Child Chunksize=256 - Error occurs mostly on second query
Parent Chunksize=2048, Child Chunksize=256 - Error occurs mostly on third query
Parent Chunksize=1500, Child Chunksize=300 - Error occurs after fourth query
With fixed chunks
Parent Chunksize=4096 Error occurs mostly on second query
Parent Chunksize=2048 Error occurs mostly on third query
・Similar to #637, this error occurs even when the Harmful Categories threshold is set to 0
Contributor guide
Research direction
Reproduce the chatbot failure using hierarchical and fixed chunks with the listed parent and child sizes, a Contextual Grounding threshold of 0, and repeated questions. Compare the behavior with issue #637, then trace the error from the second, third, or fourth query; done means repeated questions no longer produce the reported error under these settings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, python, react, typescript
- Domain
- ai, backend, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100