LangChain AWS
Official LangChain integrations for Amazon Bedrock, SageMaker, and other AWS services.
Repository Health
Technical Analysis
LangChain AWS is the official package of LangChain integrations for Amazon Web Services. It bundles chat models and LLMs for Amazon Bedrock and SageMaker, Bedrock and other AWS embeddings, retrievers (including Bedrock Knowledge Bases and Kendra), vector stores, agents, and utilities, so LangChain and LangGraph applications can use AWS-hosted models and data services through a consistent interface.
Built on langchain-core and boto3, it assumes standard AWS credential configuration and exposes provider-specific classes such as ChatBedrock and BedrockEmbeddings alongside AWS retriever and vector-store integrations, letting teams build generative-AI applications entirely on AWS infrastructure.
What You Get
- ChatBedrock, ChatBedrockConverse, and SageMaker chat/LLM classes for AWS-hosted models
- BedrockEmbeddings and related embedding integrations
- Retrievers for Amazon Bedrock Knowledge Bases and Kendra, plus vector-store integrations
- Agents, tools, document compressors, and utilities built for the AWS ecosystem
Common Use Cases
- Calling Amazon Bedrock foundation models from LangChain chains and agents
- Building RAG pipelines backed by Bedrock Knowledge Bases or Amazon Kendra
- Generating embeddings and running vector search on AWS-managed services
Under The Hood
Architecture - The langchain_aws package (in libs/aws of a dedicated monorepo) is organized by integration type: chat_models, llms, embeddings, retrievers, vectorstores, agents, chains, tools, middleware, runnables, document_compressors, graphs and utilities. Each subpackage adapts an AWS service to the corresponding langchain-core base class - for example ChatBedrock/ChatBedrockConverse wrap the Bedrock runtime via boto3, and retrievers wrap Bedrock Knowledge Bases and Kendra. A function_calling.py module normalizes tool-calling across model families.
Tech Stack - Pure Python built with the standard LangChain toolchain, depending on langchain-core, boto3, pydantic v2 and numpy, with optional extras for Anthropic-on-Bedrock, Valkey, Nova Sonic and browser tools. Packaged for PyPI while versioned inside the monorepo.
Code Quality - The repo is actively maintained with strong CI, a large tests suite (unit and integration), TESTING.md guidance, and snapshot testing via syrupy. Integrations consistently subclass langchain-core abstractions, keeping behavior aligned with the wider ecosystem.
API Design - Ergonomics match the rest of LangChain: import a provider class (e.g. ChatBedrock, BedrockEmbeddings), rely on ambient AWS credentials, and use the standard runnable interface for invocation, streaming and tool calls. The main learning curve is AWS-side (IAM, Bedrock model access) rather than the library itself.
Used by 3 apps in this directory
deepagents
AI Agents · AI Development
The batteries-included Python agent harness — planning, sub-agents, filesystem, shell, memory, and skills bundled in, built on LangGraph.
Langflow
AI Agents · AI Development
Build, test, and deploy AI agents and RAG workflows visually with native API and MCP server export.
MaxKB
AI Development · Knowledge Management
Build enterprise-grade AI agents with RAG, workflows & multi-modal support