1 Answer
- Newest
- Most votes
- Most comments
0
Hi, to start understanding what's happening in the RAG involving the knowledge base, you should start by tracing to see what chunks are retrieved in the KB and how the prompt is built with those chunks to see why it exceeds the limit.
The tracing of such activity is detailled here: https://repost.aws/articles/AR-LV1HoR_S0m-qy89wXwHmw/the-leverage-of-llm-system-prompt-by-knowledge-bases-for-bedrock-in-rag-workflows
Best,
Didier
Relevant content
- asked 8 months ago
- asked 2 years ago
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 6 months ago

Hi , Thank you for your comment . Yes I understand how RAG works. Here my doubt is, In this Prompt flow, its quit simple and very basic . but there no placeholder to set/modify that 1000 limit. How its says my query exceeds 1000 characters. My question is simple "what is pmi". So i need help where and how to fix this . Do you see any complexity in my Prompt flow. I think its very very basic and simple.
Your issue might be that the RAG returns text chunks at retrieve stage that are finally too big for the generates stage in the retrieve_and_generate verb used for this prompting. Tracing as suggested would allow you to see those chunks of text and validate that they are not too big.