Agentic retrieval with LangChain and Amazon Bedrock Knowledge Bases
Machine Learning Blog
This article demonstrates agentic retrieval with LangChain and Amazon Bedrock Knowledge Bases, showing how it improves upon standard retrieval for complex, multi-part questions.
- Standard retrieval uses a single query vector that misses multiple intents; agentic retrieval decomposes questions into sub-queries
- Amazon Bedrock Managed Knowledge Base handles chunking, embedding, storage, and retrieval without self-managed vector stores
- Two APIs available: Retrieve (single-shot, cheaper, faster) and AgenticRetrieveStream (multi-step planning with trace events)
- Agentic retrieval plans queries, evaluates evidence sufficiency, and re-retrieves if needed across up to five knowledge bases
- Trace events show the planning loop including SpeculativeRetrieval, Planning, Retrieval, and FullDocumentExpansion steps
- Use standard Retrieve for short, well-scoped questions; use agentic retrieval for multi-part, comparative, or exploratory questions
- Includes code examples for creating knowledge bases, querying with LangChain, and reading trace events via boto3
Agentic retrieval trades higher per-call cost for improved recall on complex questions by using built-in model-based query planning.
The AWS News Feed is currently looking for gold sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.
Related articles
Jul 23
2026
2026
Agentic retrieval for Amazon Bedrock Managed Knowledge Base
Oct 26
2026
2026
Build agentic retrieval on a Managed Amazon Bedrock Knowledge Base with CDK
Nov 9
2026
2026
Single-shot and agentic retrieval with Amazon Bedrock Managed Knowledge Base
Aug 31
2026
2026
Build observable enterprise agentic retrieval using Managed Amazon Bedrock Knowledge Base with AWS CloudFormation
The AWS News Feed is currently looking for silver sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.