- Newest
- Most votes
- Most comments
Yes, It's True: The knowledge base in Amazon Bedrock can remember and use the context of a conversation to give better, more relevant answers as the conversation goes on.
How It Works:
Session Memory: The system can store information about the conversation in memory while you’re chatting. This helps the AI remember what you’ve already talked about. Session IDs or Tokens: These can link your current question to previous parts of the conversation, allowing the AI to pull in relevant details from earlier. Persistent Storage: For long-term memory, like remembering details across different sessions, the context might be stored in a database. Related to API Requests:
When you send a request to the API, you might include a session ID or previous conversation data to help the system remember the context. Can You Try It on the Console?
Yes, but… You can play around with some basic features in the Bedrock console. However, if you want to do more advanced stuff, like managing conversation memory over time, you’ll probably need to write some code or use a notebook with the Bedrock SDK. Citations in Responses:
The knowledge base can also provide citations or references to the exact documents or information it used to generate an answer, so you can check where the information came from. In short, Bedrock can remember what you’re talking about and use that memory to improve its responses, but for deeper control over this, using code is the way to go.
Hi,
AFAIK, the context is not retained by Bedrock KB but by Bedrock Agent: see https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html to understand which levers you have to control / influence session state. Their are a few context parameters that you can influence to obtain better results for your use case.
On KB retrieval, please have a look at my article https://repost.aws/articles/AR-LV1HoR_S0m-qy89wXwHmw/the-leverage-of-llm-system-prompt-by-knowledge-bases-for-bedrock-in-rag-workflows
You will understand in full details (traces included) how it works to leverage text chunks of your KB in the responses and retain corresponding citations.
Best,
Didier
Relevant content
- asked 6 months ago
- asked 4 months ago
- AWS OFFICIALUpdated 4 days ago
- AWS OFFICIALUpdated 5 months ago
- AWS OFFICIALUpdated 5 months ago