Skip to main content
This page covers all LangChain integrations with the Amazon Web Services (AWS) platform.

Chat models

Bedrock Mantle

The AWS Bedrock Mantle API exposes models through the OpenAI and Anthropic Messages protocols. ChatOpenAIMantle and ChatAnthropicMantle are the recommended interfaces for accessing these models. Both classes accept a Bedrock API key via the bedrock_api_key parameter or the AWS_BEARER_TOKEN_BEDROCK environment variable. When neither is available, both derive short-lived API keys from standard AWS credentials and refresh them transparently. ChatOpenAIMantle inherits from BaseChatOpenAI. See the corresponding Responses API docs for usage examples and capabilities. Refer to the AWS Mantle OpenAI-compatible API docs for supported models. ChatAnthropicMantle inherits from ChatAnthropic and targets the Anthropic Messages endpoint on Mantle. See the ChatAnthropic docs for usage examples and capabilities. Refer to the AWS Mantle Anthropic API docs for supported models.

Bedrock Converse

Amazon Bedrock is a fully managed service that offers a choice of high-performing foundation models (FMs) from leading AI companies like AI21 Labs, Anthropic, Cohere, Meta, OpenAI, Stability AI, and Amazon via a single API. Since Amazon Bedrock is serverless, you don’t have to manage any infrastructure, and you can securely integrate and deploy generative AI capabilities into your applications using the AWS services you are already familiar with.
AWS Bedrock maintains a Converse API that provides a unified conversational interface for Bedrock models. You can see a list of all models that are supported here. See a usage example.

Embedding models

Bedrock

See a usage example.

Document loaders

Amazon MemoryDB

Amazon MemoryDB is a durable, in-memory database service that delivers ultra-fast performance. MemoryDB is compatible with Redis OSS, a popular open source data store, enabling you to quickly build applications using the same flexible and friendly Redis OSS APIs, and commands that they already use today. InMemoryVectorStore class provides a vectorstore to connect with Amazon MemoryDB.
See a usage example.

Valkey

Valkey is an open source, high-performance key/value datastore that supports workloads such as caching, message queues, and can act as a primary database. Use ValkeyVectorStore to connect with Amazon ElastiCache for Valkey or Amazon MemoryDB for Valkey.
See a usage example.

Retrievers

Amazon Bedrock (Knowledge bases)

Knowledge bases for Amazon Bedrock is an Amazon Web Services (AWS) offering which lets you quickly build RAG applications by using your private data to customize foundation model response.
We need to install the langchain-aws library.
See a usage example.

Tools

Amazon Bedrock AgentCore Browser

Amazon Bedrock AgentCore Browser enables agents to interact with web pages through a managed Chrome browser for navigation, content extraction, and web automation.
See a usage example.

Amazon Bedrock AgentCore Code Interpreter

Amazon Bedrock AgentCore Code Interpreter enables agents to execute Python, JavaScript, and TypeScript code in secure, managed sandbox environments for calculations, data analysis, and visualizations.
See a usage example.
Amazon Bedrock AgentCore Web Search gives agents current information from the web with a source URL on every result, authenticated with your AWS credentials rather than a search API key.
See a usage example.

Sandboxes

AgentCoreSandbox

Amazon Bedrock AgentCore Code Interpreter sandbox backend for deepagents.

Graphs

Amazon neptune

Amazon Neptune is a high-performance graph analytics and serverless database for superior scalability and availability.
For the Cypher and SPARQL integrations below, we need to install the langchain-aws library.

Amazon neptune with cypher

See a usage example.

Amazon neptune with SPARQL

Memory

Amazon Bedrock AgentCore Memory

Amazon Bedrock AgentCore Memory provides managed persistence for LangGraph agents, enabling conversation history and state management across sessions with automatic scaling and high availability.
Key features:
  • Managed infrastructure with no database setup required
  • Automatic scaling and high availability
  • Multi-agent support via actor_id isolation
  • Encryption at rest and in transit

Amazon Bedrock AgentCore Memory Store

Amazon Bedrock AgentCore Memory Store provides long-term memory with semantic search capabilities for LangGraph agents, enabling storage and retrieval of user preferences, facts, and extracted memories across sessions.

Chains

Amazon Comprehend moderation chain

Amazon Comprehend is a natural-language processing (NLP) service that uses machine learning to uncover valuable insights and connections in text.
We need to install the boto3 and nltk libraries.
See a usage example.
The langchain-experimental package is no longer maintained. Examples that import from langchain_experimental may be outdated or broken. Use with caution.

Runtime

Amazon Bedrock AgentCore Runtime

Amazon Bedrock AgentCore Runtime provides managed, serverless execution for LangGraph agents with built-in observability, automatic scaling, and seamless integration with other AgentCore services.
Deploy using the AgentCore CLI: