René's URL Explorer Experiment


Title: langchain_aws | LangChain Reference

Open Graph Title: langchain_aws

X Title: langchain_aws

Description: Python API reference for langchain_aws. Part of the LangChain ecosystem.

Open Graph Description: Python API reference for langchain_aws. Part of the LangChain ecosystem.

X Description: Python API reference for langchain_aws. Part of the LangChain ecosystem.

Opengraph URL: https://reference.langchain.com/python/langchain-aws

direct link

Domain: reference.langchain.com

og:imagehttps://reference.langchain.com/og/python/langchain-aws
og:image:width1200
og:image:height630
og:image:altlangchain_aws
og:typearticle
twitter:cardsummary_large_image
twitter:imagehttps://reference.langchain.com/og/python/langchain-aws

Links:

LangChain Reference home pagehttps://reference.langchain.com/
GitHubhttps://github.com/langchain-ai
Main Docshttps://docs.langchain.com/
Deep Agentshttps://reference.langchain.com/python/deepagents
LangChainhttps://reference.langchain.com/python/langchain/overview
LangGraphhttps://reference.langchain.com/python/langgraph/overview
Integrationshttps://reference.langchain.com/python/integrations/overview
LangSmithhttps://reference.langchain.com/python/langsmith
Overviewhttps://reference.langchain.com/python/integrations/overview
Overviewhttps://reference.langchain.com/python/langchain-aws
Chat Modelshttps://reference.langchain.com/python/langchain-aws/chat-models
LLMshttps://reference.langchain.com/python/langchain-aws/llms
Embeddingshttps://reference.langchain.com/python/langchain-aws/embeddings
Retrievershttps://reference.langchain.com/python/langchain-aws/retrievers
Google GenAI (Gemini)https://reference.langchain.com/python/langchain-google-genai
Google Vertex AIhttps://reference.langchain.com/python/langchain-google-vertexai
IBMhttps://reference.langchain.com/python/langchain-ibm
https://chat.langchain.com/
Overviewhttps://reference.langchain.com/python/langchain-aws
Chat Modelshttps://reference.langchain.com/python/langchain-aws/chat-models
LLMshttps://reference.langchain.com/python/langchain-aws/llms
Embeddingshttps://reference.langchain.com/python/langchain-aws/embeddings
Retrievershttps://reference.langchain.com/python/langchain-aws/retrievers
Google GenAI (Gemini)https://reference.langchain.com/python/langchain-google-genai
Google Vertex AIhttps://reference.langchain.com/python/langchain-google-vertexai
IBMhttps://reference.langchain.com/python/langchain-ibm
https://pypi.org/project/langchain-aws/#history
https://opensource.org/licenses/MIT
https://pypistats.org/packages/langchain-aws
the docshttps://docs.langchain.com/oss/python/integrations/providers/aws
ClassAnthropicToolhttps://reference.langchain.com/python/langchain-aws/function_calling/AnthropicTool
ClassFunctionDescriptionRepresentation of a callable function to send to an LLM.https://reference.langchain.com/python/langchain-aws/function_calling/FunctionDescription
ClassToolDescriptionRepresentation of a callable function to the OpenAI API.https://reference.langchain.com/python/langchain-aws/function_calling/ToolDescription
ClassToolsOutputParserhttps://reference.langchain.com/python/langchain-aws/function_calling/ToolsOutputParser
ClassAnthropicToolhttps://reference.langchain.com/python/langchain-aws/llms/bedrock/AnthropicTool
ClassLLMInputOutputAdapterAdapter class to prepare the inputs from Langchain to a format that LLM model expects. It also provides helper function to extract the generated text from the model response.https://reference.langchain.com/python/langchain-aws/llms/bedrock/LLMInputOutputAdapter
ClassBedrockBaseBase class for Bedrock models.https://reference.langchain.com/python/langchain-aws/llms/bedrock/BedrockBase
ClassBedrockLLMBedrock models. To authenticate, the AWS client uses the following methods to automatically load credentials: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html If a spechttps://reference.langchain.com/python/langchain-aws/llms/bedrock/BedrockLLM
ClassLineIteratorA helper class for parsing the byte stream input. The output of the model will be in the following format: b'{"outputs": [" a"]} ' b'{"outputs": [" challenging"]} ' b'{"outputs": ["https://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint/LineIterator
ClassContentHandlerBaseA handler class to transform input from LLM to a format that SageMaker endpoint expects. Similarly, the class handles transforming output from the SageMaker endpoint to a format that LLM class expecthttps://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint/ContentHandlerBase
ClassLLMContentHandlerContent handler for LLM class.https://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint/LLMContentHandler
ClassSagemakerEndpointSagemaker Inference Endpoint models. To use, you must supply the endpoint name from your deployed Sagemaker model & the region where it is deployed. To authenticate, the AWS client uses the followinhttps://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint/SagemakerEndpoint
ClassAmazonQAmazon Q Runnable wrapper. To authenticate, the AWS client uses the following methods to automatically load credentials: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.htmlhttps://reference.langchain.com/python/langchain-aws/runnables/q_business/AmazonQ
ClassInMemoryVectorStoreInMemoryVectorStore vector database. To use, you should have the redis python package installed for AWS MemoryDB .. code-block:: bash Once running, you can connect to the MemoryDB server withhttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/base/InMemoryVectorStore
ClassInMemoryVectorStoreRetrieverRetriever for InMemoryVectorStore.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/base/InMemoryVectorStoreRetriever
ClassInMemorySemanticCacheCache that uses MemoryDB as a vector-store backend.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/cache/InMemorySemanticCache
ClassInMemoryDBDistanceMetricDistance metrics for Redis vector fields.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/InMemoryDBDistanceMetric
ClassInMemoryDBFieldBase class for Redis fields.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/InMemoryDBField
ClassTextFieldSchemaSchema for text fields in Redis.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/TextFieldSchema
ClassTagFieldSchemaSchema for tag fields in Redis.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/TagFieldSchema
ClassNumericFieldSchemaSchema for numeric fields in Redis.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/NumericFieldSchema
ClassInMemoryDBVectorFieldBase class for Redis vector fields.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/InMemoryDBVectorField
ClassFlatVectorFieldSchema for flat vector fields in Redis.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/FlatVectorField
ClassHNSWVectorFieldSchema for HNSW vector fields in Redis.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/HNSWVectorField
ClassInMemoryDBModelSchema for MemoryDB index.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/InMemoryDBModel
ClassInMemoryDBFilterOperatorInMemoryDBFilterOperator enumerator is used to create InMemoryDBFilterExpressionshttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBFilterOperator
ClassInMemoryDBFilterCollection of InMemoryDBFilterFields.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBFilter
ClassInMemoryDBFilterFieldBase class for InMemoryDBFilterFields.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBFilterField
ClassInMemoryDBTagInMemoryDBFilterField representing a tag in a InMemoryDB index.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBTag
ClassInMemoryDBNumInMemoryDBFilterField representing a numeric field in a InMemoryDB index.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBNum
ClassInMemoryDBTextInMemoryDBFilterField representing a text field in a InMemoryDB index.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBText
ClassInMemoryDBFilterExpressionLogical expression of InMemoryDBFilterFields. InMemoryDBFilterExpressions can be combined using the & and | operators to create complex logical expressions that evaluate to the InMemoryDB Query languhttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/InMemoryDBFilterExpression
ClassBedrockRerankDocument compressor that uses AWS Bedrock Rerank API.https://reference.langchain.com/python/langchain-aws/document_compressors/rerank/BedrockRerank
ClassChatPromptAdapterAdapter class to prepare the inputs from Langchain to prompt format that Chat model expects.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/ChatPromptAdapter
ClassChatBedrockA chat model that uses the Bedrock API.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/ChatBedrock
ClassChatBedrockConverseBedrock chat model integration built on the Bedrock converse API. This implementation will eventually replace the existing ChatBedrock implementation once the Bedrock converse API has feature parityhttps://reference.langchain.com/python/langchain-aws/chat_models/bedrock_converse/ChatBedrockConverse
ClassNeptuneRdfGraphNeptune wrapper for RDF graph operations.https://reference.langchain.com/python/langchain-aws/graphs/neptune_rdf_graph/NeptuneRdfGraph
ClassNeptuneQueryExceptionException for the Neptune queries.https://reference.langchain.com/python/langchain-aws/graphs/neptune_graph/NeptuneQueryException
ClassBaseNeptuneGraphhttps://reference.langchain.com/python/langchain-aws/graphs/neptune_graph/BaseNeptuneGraph
ClassNeptuneAnalyticsGraphNeptune Analytics wrapper for graph operations.https://reference.langchain.com/python/langchain-aws/graphs/neptune_graph/NeptuneAnalyticsGraph
ClassNeptuneGraphNeptune wrapper for graph operations.https://reference.langchain.com/python/langchain-aws/graphs/neptune_graph/NeptuneGraph
ClassBedrockAgentsRunnableInvoke a Bedrock Agenthttps://reference.langchain.com/python/langchain-aws/agents/base/BedrockAgentsRunnable
ClassBedrockInlineAgentsRunnableInvoke Bedrock Inline Agent as a Runnable.https://reference.langchain.com/python/langchain-aws/agents/base/BedrockInlineAgentsRunnable
ClassBedrockAgentFinishAgentFinish with session id information.https://reference.langchain.com/python/langchain-aws/agents/types/BedrockAgentFinish
ClassBedrockAgentActionAgentAction with session id information.https://reference.langchain.com/python/langchain-aws/agents/types/BedrockAgentAction
ClassGuardrailConfigurationhttps://reference.langchain.com/python/langchain-aws/agents/types/GuardrailConfiguration
ClassKnowledgebaseConfigurationhttps://reference.langchain.com/python/langchain-aws/agents/types/KnowledgebaseConfiguration
ClassInlineAgentConfigurationConfigurations for an Inline Agent.https://reference.langchain.com/python/langchain-aws/agents/types/InlineAgentConfiguration
ClassBedrockEmbeddingsBedrock embedding models. To authenticate, the AWS client uses the following methods to automatically load credentials: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.htmlhttps://reference.langchain.com/python/langchain-aws/embeddings/bedrock/BedrockEmbeddings
ClassSearchFilterFilter configuration for retrieval.https://reference.langchain.com/python/langchain-aws/retrievers/bedrock/SearchFilter
ClassVectorSearchConfigConfiguration for vector search.https://reference.langchain.com/python/langchain-aws/retrievers/bedrock/VectorSearchConfig
ClassRetrievalConfigConfiguration for retrieval.https://reference.langchain.com/python/langchain-aws/retrievers/bedrock/RetrievalConfig
ClassAmazonKnowledgeBasesRetrieverAmazon Bedrock Knowledge Bases retrieval. See https://aws.amazon.com/bedrock/knowledge-bases for more info. Args: knowledge_base_id: Knowledge Base ID. region_name: The awshttps://reference.langchain.com/python/langchain-aws/retrievers/bedrock/AmazonKnowledgeBasesRetriever
ClassHighlightInformation that highlights the keywords in the excerpt.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/Highlight
ClassTextWithHighLightsText with highlights.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/TextWithHighLights
ClassAdditionalResultAttributeValueValue of an additional result attribute.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/AdditionalResultAttributeValue
ClassAdditionalResultAttributeAdditional result attribute.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/AdditionalResultAttribute
ClassDocumentAttributeValueValue of a document attribute.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/DocumentAttributeValue
ClassDocumentAttributeDocument attribute.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/DocumentAttribute
ClassResultItemBase class of a result item.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/ResultItem
ClassQueryResultItemQuery API result item.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/QueryResultItem
ClassRetrieveResultItemRetrieve API result item.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/RetrieveResultItem
ClassQueryResultAmazon Kendra Query API search result.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/QueryResult
ClassRetrieveResultAmazon Kendra Retrieve API search result.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/RetrieveResult
ClassAmazonKendraRetrieverAmazon Kendra Index retriever.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/AmazonKendraRetriever
Functionsetup_logginghttps://reference.langchain.com/python/langchain-aws/setup_logging
Functionget_system_messagehttps://reference.langchain.com/python/langchain-aws/function_calling/get_system_message
Functionconvert_to_anthropic_toolhttps://reference.langchain.com/python/langchain-aws/function_calling/convert_to_anthropic_tool
Functionenforce_stop_tokensCut off the text as soon as any stop words occur.https://reference.langchain.com/python/langchain-aws/utils/enforce_stop_tokens
Functionanthropic_tokens_supportedCheck if all requirements for Anthropic count_tokens() are met.https://reference.langchain.com/python/langchain-aws/utils/anthropic_tokens_supported
Functionget_num_tokens_anthropicGet the number of tokens in a string of text.https://reference.langchain.com/python/langchain-aws/utils/get_num_tokens_anthropic
Functionget_token_ids_anthropicGet the token ids for a string of text.https://reference.langchain.com/python/langchain-aws/utils/get_token_ids_anthropic
Functionthinking_in_paramsCheck if the thinking parameter is enabled in the request.https://reference.langchain.com/python/langchain-aws/utils/thinking_in_params
Functionextract_tool_callshttps://reference.langchain.com/python/langchain-aws/llms/bedrock/extract_tool_calls
Functionenforce_stop_tokensCut off the text as soon as any stop words occur.https://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint/enforce_stop_tokens
Functioncheck_index_existsCheck if MemoryDB index exists.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/base/check_index_exists
Functionread_schemaRead in the index schema from a dict or yaml file. Check if it is a dict and return RedisModel otherwise, check if it's a path and read in the file assuming it's a yaml file and return a RedisModelhttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema/read_schema
Functioncheck_operator_misuseDecorator to check for misuse of equality operators.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters/check_operator_misuse
Functionconvert_messages_to_prompt_llamaConvert a list of messages to a prompt for llama.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/convert_messages_to_prompt_llama
Functionconvert_messages_to_prompt_llama3Convert a list of messages to a prompt for llama.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/convert_messages_to_prompt_llama3
Functionconvert_messages_to_prompt_anthropicFormat a list of messages into a full prompt for the Anthropic model Args: messages (List[BaseMessage]): List of BaseMessage to combine. human_prompt (str, optional): Human prompthttps://reference.langchain.com/python/langchain-aws/chat_models/bedrock/convert_messages_to_prompt_anthropic
Functionconvert_messages_to_prompt_mistralConvert a list of messages to a prompt for mistral.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/convert_messages_to_prompt_mistral
Functionconvert_messages_to_prompt_deepseekConvert a list of messages to a prompt for DeepSeek-R1.https://reference.langchain.com/python/langchain-aws/chat_models/bedrock/convert_messages_to_prompt_deepseek
Functionget_boto_sessionConstruct the boto3 sessionhttps://reference.langchain.com/python/langchain-aws/agents/utils/get_boto_session
Functionparse_agent_responseParses the raw response from Bedrock Agenthttps://reference.langchain.com/python/langchain-aws/agents/utils/parse_agent_response
Functiontrim_queryTrim the query to only include Cypher keywords.https://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher/trim_query
Functionextract_cypherExtract Cypher code from text using Regex.https://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher/extract_cypher
Functionuse_simple_promptDecides whether to use the simple prompthttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher/use_simple_prompt
Functionget_promptSelects the final prompthttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher/get_prompt
Functioncreate_neptune_opencypher_qa_chainChain for question-answering against a Neptune graph by generating openCypher statements. Security note: Make sure that the database connection uses credentials that are narrowly-scoped to onlyhttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher/create_neptune_opencypher_qa_chain
Functionextract_sparqlExtract SPARQL code from a text.https://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_sparql/extract_sparql
Functionget_promptSelects the final prompt.https://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_sparql/get_prompt
Functioncreate_neptune_sparql_qa_chainChain for question-answering against a Neptune graph by generating SPARQL statements. Security note: Make sure that the database connection uses credentials that are narrowly-scoped to only inchttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_sparql/create_neptune_sparql_qa_chain
Functionclean_excerptClean an excerpt from Kendra.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/clean_excerpt
Functioncombined_textCombine a ResultItem title and excerpt into a single string.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/combined_text
Modulelangchain_awshttps://reference.langchain.com/python/langchain-aws/langchain_aws
Modulefunction_callingMethods for creating function specs in the style of Bedrock Functions for supported model providershttps://reference.langchain.com/python/langchain-aws/function_calling
Moduleutilshttps://reference.langchain.com/python/langchain-aws/utils
Modulellmshttps://reference.langchain.com/python/langchain-aws/llms
Modulebedrockhttps://reference.langchain.com/python/langchain-aws/llms/bedrock
Modulesagemaker_endpointSagemaker InvokeEndpoint API.https://reference.langchain.com/python/langchain-aws/llms/sagemaker_endpoint
Modulerunnableshttps://reference.langchain.com/python/langchain-aws/runnables
Moduleq_businesshttps://reference.langchain.com/python/langchain-aws/runnables/q_business
Modulevectorstoreshttps://reference.langchain.com/python/langchain-aws/vectorstores
Moduleinmemorydbhttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb
ModulebaseWrapper around MemoryDB vector database.https://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/base
Modulecachehttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/cache
Moduleschemahttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/schema
Modulefiltershttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/filters
Moduleconstantshttps://reference.langchain.com/python/langchain-aws/vectorstores/inmemorydb/constants
Moduledocument_compressorshttps://reference.langchain.com/python/langchain-aws/document_compressors
Modulererankhttps://reference.langchain.com/python/langchain-aws/document_compressors/rerank
Modulechat_modelshttps://reference.langchain.com/python/langchain-aws/chat_models
Modulebedrockhttps://reference.langchain.com/python/langchain-aws/chat_models/bedrock
Modulebedrock_conversehttps://reference.langchain.com/python/langchain-aws/chat_models/bedrock_converse
Modulegraphshttps://reference.langchain.com/python/langchain-aws/graphs
Moduleneptune_rdf_graphhttps://reference.langchain.com/python/langchain-aws/graphs/neptune_rdf_graph
Moduleneptune_graphhttps://reference.langchain.com/python/langchain-aws/graphs/neptune_graph
Moduleagentshttps://reference.langchain.com/python/langchain-aws/agents
Modulebasehttps://reference.langchain.com/python/langchain-aws/agents/base
Moduleutilshttps://reference.langchain.com/python/langchain-aws/agents/utils
Moduletypeshttps://reference.langchain.com/python/langchain-aws/agents/types
Moduleembeddingshttps://reference.langchain.com/python/langchain-aws/embeddings
Modulebedrockhttps://reference.langchain.com/python/langchain-aws/embeddings/bedrock
Modulechainshttps://reference.langchain.com/python/langchain-aws/chains
Modulegraph_qahttps://reference.langchain.com/python/langchain-aws/chains/graph_qa
Moduleneptune_cypherhttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_cypher
Moduleneptune_sparqlQuestion answering over an RDF or OWL graph using SPARQL.https://reference.langchain.com/python/langchain-aws/chains/graph_qa/neptune_sparql
Modulepromptshttps://reference.langchain.com/python/langchain-aws/chains/graph_qa/prompts
Moduleretrievershttps://reference.langchain.com/python/langchain-aws/retrievers
Modulebedrockhttps://reference.langchain.com/python/langchain-aws/retrievers/bedrock
Modulekendrahttps://reference.langchain.com/python/langchain-aws/retrievers/kendra
TypeOutputTypehttps://reference.langchain.com/python/langchain-aws/agents/types/OutputType
TypeFilterValuehttps://reference.langchain.com/python/langchain-aws/retrievers/bedrock/FilterValue
TypeDocumentAttributeValueTypePossible types of a DocumentAttributeValue. Dates are also represented as str.https://reference.langchain.com/python/langchain-aws/retrievers/kendra/DocumentAttributeValueType

Viewport: width=device-width, initial-scale=1


URLs of crawlers that visited me.