pnpm install @langchain/community
This package, along with the main LangChain package, depends on @langchain/core.
If you are using this package with other LangChain packages, you should make sure that all of the packages depend on the same instance of @langchain/core.
You can do so by adding appropriate field to your project's package.json like this:
{
"name": "your-project",
"version": "0.0.0",
"dependencies": {
"@langchain/community": "^0.0.0",
"@langchain/core": "^0.3.0"
},
"resolutions": {
"@langchain/core": "^0.3.0"
},
"overrides": {
"@langchain/core": "^0.3.0"
},
"pnpm": {
"overrides": {
"@langchain/core": "^0.3.0"
}
}
}
The field you need depends on the package manager you're using, but we recommend adding a field for the common yarn, npm, and pnpm to maximize compatibility.
LangChain Community contains third-party integrations that implement the base interfaces defined in LangChain Core, making them ready-to-use in any LangChain application.
As an open-source project in a rapidly developing field, we are extremely open to contributions, whether it be in the form of a new feature, improved infrastructure, or better documentation.
For detailed information on how to contribute, see here.
Class representing a toolkit for interacting with AWS Step Functions.
Abstract base class for toolkits in LangChain. Toolkits are collections
ConneryToolkit provides access to all the available actions from the Connery Runner.
Abstract base class for toolkits in LangChain. Toolkits are collections
Abstract base class for toolkits in LangChain. Toolkits are collections
Cache LLM results using Redis.
A cache that uses Momento as the backing store.
A cache that uses Upstash as the backing store.
A cache that uses Vercel KV as the backing store.
Upstash Ratelimit Error
Callback to handle rate limiting based on the number of requests
Chain for question-answering against a graph by generating Cypher statements.
Wrapper around Ali Tongyi large language models that use the Chat endpoint.
AWS Bedrock chat model integration.
AWS Bedrock chat model integration.
Wrapper around Fireworks API for large language models fine-tuned for chat
The ChatFriendli class is used to interact with Friendli inference Endpoint models.
To use this model you need to have the node-llama-cpp module installed.
Wrapper around Minimax large language models that use the Chat endpoint.
Interface defining the input to the MoonshotChatInput class.
Novita chat model implementation
Wrapper around Perplexity large language models that use the Chat endpoint.
Integration with a chat model.
Wrapper around Tencent Hunyuan large language models that use the Chat endpoint.
Wrapper around Tencent Hunyuan large language models that use the Chat endpoint.
TogetherAI chat model integration.
To use this model you need to have the @mlc-ai/web-llm module installed.
Interface defining the input to the ZhipuAIChatInput class.
A class that extends the TextLoader class. It represents a document
A class that extends the BufferLoader class. It represents a document
A class that extends the BaseDocumentLoader class. It represents a
A class that extends the DirectoryLoader class. It represents a
Represents a loader for directories containing Obsidian markdown files. This loader extends
A class that extends the BufferLoader class. It represents a document
A class that extends the BufferLoader class. It represents a document
A class that extends the TextLoader class. It represents a document
A document loader that loads unstructured documents from a directory
A document loader that uses the Unstructured API to load unstructured
A class that extends the BaseDocumentLoader and implements the
Transcribe audio and load subtitles for the transcript as srt or vtt format.
Transcribe audio and load the transcript as a document using AssemblyAI.
Transcribe audio and load the paragraphs of the transcript, creating a document for each paragraph.
Transcribe audio and load the sentences of the transcript, creating a document for each sentence.
Class representing a document loader that loads documents from an Azure
Class representing a document loader that loads a specific file from
Load pre-rendered web pages using a headless browser hosted on Browserbase.
A class that extends the BaseDocumentLoader and implements the
A document loader specifically designed for loading documents from the
Class representing a document loader for loading pages from Confluence.
loader for couchbase document
Class representing a document loader for loading Figma files. It
Class representing a document loader for loading data from
Class representing a document loader specifically designed for loading
A class that extends the BaseDocumentLoader and implements the
A class that extends the BaseDocumentLoader class. It represents a
A class that extends the CheerioWebBaseLoader class. It represents a
A class that extends the CheerioWebBaseLoader class. It represents a
Class responsible for converting Jira issues to Document objects
Class representing a document loader for loading pages from Confluence.
A class that extends the BaseDocumentLoader class. It represents a
A document loader for loading data from PDFs.
Class representing a document loader for scraping web pages using
Class that extends the BaseDocumentLoader class and implements the
A class that extends the BaseDocumentLoader class. It represents a
Class representing a document loader for loading search results from
Class representing a document loader for loading search results from
Interface representing the parameters for initializing a SitemapLoader.
A class that represents a document loader for transcribing audio files
Class representing a document loader for loading data from the SortXYZ
Class representing a document loader for loading data from
Class representing a document loader for loading Taskade project. It
A document loader for loading data from YouTube videos. It uses the
A transformer that converts HTML content to plain text.
A transformer that uses the Mozilla Readability library to extract the
A class for generating embeddings using the DeepInfra API.
A class for generating embeddings using the Fireworks AI API.
Class for generating embeddings using the Gradient AI's API. Extends the
Class that extends the Embeddings class and provides methods for
Class for generating embeddings using the Minimax API. Extends the
Class for generating embeddings using the Prem AI's API. Extends the
Class for generating embeddings using the Tencent Hunyuan API.
Class for generating embeddings using the Tencent Hunyuan API.
Class that extends the Embeddings class and provides methods for
Class for generating embeddings using the TogetherAI API. Extends the
A class for generating embeddings using the Voyage AI API.
Interface that extends EmbeddingsParams and defines additional
To use this model you need to have the Built-in AI Early Preview Program
Class for generating embeddings for text and images using Google's
Class representing the AI21 language model. It extends the LLM (Large
Specific implementation of a Large Language Model (LLM) designed to
A type of Large Language Model (LLM) that interacts with the Bedrock
A type of Large Language Model (LLM) that interacts with the Bedrock
Wrapper around Fireworks API for large language models
The Friendli class is used to interact with Friendli inference Endpoint models.
The GradientLLM class is used to interact with Gradient AI inference Endpoint models.
Class implementing the Large Language Model (LLM) interface using the
Integration with an LLM.
To use this model you need to have the node-llama-cpp module installed.
The RaycastAI class, which extends the LLM class and implements the RaycastAIInput interface.
Class responsible for managing the interaction with the Replicate API.
A handler class to transform input from LLM to a format that SageMaker
The SageMakerEndpoint class is used to interact with SageMaker
Class representing a Writer Large Language Model (LLM). It interacts
Abstract class that provides a base for implementing different types of
Class used to manage the memory of a chat session using the Mem0 service.
Class for managing chat message memory using the Motorhead service. It
Class used to manage the memory of a chat session, including loading
Class used to manage the memory of a chat session, including loading
A retriever that searches arXiv for relevant articles based on a query.
Example usage:
A retriever that uses the BM25 algorithm to rank documents based on their
Class used to interact with the Metal service, a managed retrieval &
Abstract class for interacting with a remote server to retrieve
Class for performing hybrid search operations on a Supabase database.
A class for retrieving documents related to a given search term
Class responsible for retrieving data from Vespa. It extends the
Class for retrieving information from a Zep long-term memory store.
Class for retrieving information from a Zep Cloud long-term memory store.
A concrete implementation of BaseStore for interacting with a Cassandra database.
Class that extends the BaseStore class to interact with a Convex
Class that extends the BaseStore class to interact with a Redis
Class that extends the BaseStore class to interact with an Upstash Redis
Class that extends the BaseStore class to interact with a Vercel KV
Abstract class for a document store. All document stores should extend
Class that provides an interface for interacting with Google Cloud
Class for storing and retrieving documents in memory asynchronously.
Class for storing and retrieving documents in memory synchronously.
Class for storing chat message history with Astra DB. It extends the
Class for managing chat message history using a Amazon Aurora DSQL Database as a
Class for storing chat message history within Cassandra. It extends the
Class providing methods to interact with a DynamoDB table to store and
Store chat message history using a local JSON file.
Class for managing chat message history using Google's Firestore as a
Class for storing chat message history in-memory. It extends the
Class used to store chat message history in Redis. It provides methods
A class that stores chat message history using Momento Cache. It
Class for storing and retrieving chat message history from a
Class for managing chat message history using a Postgres Database as a
Class used to store chat message history in Redis. It provides methods
A class for managing chat message history using Xata.io client. It
Class used to manage the memory of a chat session, including loading
Specialized translator for the Chroma vector database. It extends the
A specialized translator designed to work with Supabase, extending the
Class for creating instances of AI tools from plugins. It extends the
Class for invoking AWS Lambda functions within the LangChain framework.
Class for checking the status of an AWS Step Function execution.
Class for sending a task success signal to an AWS Step Function
Class for starting the execution of an AWS Step Function.
A tool for web search functionality using Bing's search engine. It
Class for interacting with the Brave Search engine. It extends the Tool
A LangChain Tool object wrapping a Connery action.
A service for working with Connery Actions.
The DadJokeAPI class is a tool for generating dad jokes based on a
DataForSeoAPISearch
A tool for searching for messages within a discord channel using a bot.
A tool for retrieving all servers a bot is a member of. It extends the
A tool for retrieving messages from a discord channel using a bot.
A tool for retrieving text channels within a server/guild a bot is a member
A tool for sending messages to a discord channel using a bot.
DuckDuckGo tool integration.
A tool that can be created dynamically from a function, name, and
A tool that can be created dynamically from a function, name, and description.
Class that uses the Google Search API to perform custom searches.
Tool that queries the Google Places API
Class for interacting with the Google Routes API
Tool for querying Google Scholar using the SerpApi service.
Tool that queries the Google Trends API. Uses default interest over time.
Represents a tool for creating and managing webhooks with the IFTTT (If
SearchApi Class Definition.
SearxngSearch class represents a meta search engine tool.
Wrapper around SerpAPI.
Wrapper around serper.
Class for interacting with the StackExchange API
Wikipedia query tool integration.
Provides a centralized and streamlined factory for creating and configuring instances of the Cassandra client.
Represents a Cassandra table, encapsulating functionality for schema definition, data manipulation, and querying.
Class that provides methods for creating and managing a collection of
Example usage:
Azure AI Search vector store.
Class for interacting with the Cassandra database. It extends the
Chroma vector store integration.
Class for interacting with the ClickHouse database. It extends the
Class that implements a vector store using Hierarchical Navigable Small
Class that implements a vector store using CloseVector, It extends the SaveableVectorStore class and
Class that is a wrapper around Convex storage and vector search. It is used
Class for interacting with the Couchbase database using Query service for vector search.
Class for interacting with the Couchbase database. It extends the
Elasticsearch vector store supporting vector and hybrid search.
Hybrid search strategy combining vector and BM25 search using RRF.
A class that wraps the FAISS (Facebook AI Similarity Search) vector
A Document that optionally includes the ID of the document.
A class that represents a connection to a Google Vertex AI Matching Engine
Class that implements a vector store using Hierarchical Navigable Small
A wrapper for an open-source database for vector-search with persistent
A vector store using LibSQL/Turso for storage and retrieval.
MariaDB vector store integration.
Class for interacting with a Milvus database. Extends the VectorStore
A vector store that uses the Momento Vector Index.
Class for interacting with the MyScale database. It extends the
Class that provides an interface to a Neon Postgres database. It
Class that provides a wrapper around the OpenSearch service for vector
PGVector vector store integration.
A specific implementation of the VectorStore class that is designed to
Exposes Rockset's vector store/search functionality
Error that is thrown when a RocksetStore function is called
Generic Rockset vector storage error
Class for interacting with SingleStoreDB, a high-performance
Supabase vector store integration.
Class for managing and operating vector search applications with
Class that provides an interface to a Postgres vector database. It
Class that extends the Document base class and adds an embedding
Typesense vector store.
The main class that extends the 'VectorStore' class. It provides
Class that extends SaveableVectorStore and provides methods for
Class for interacting with the Vectara API. Extends the VectorStore
Class that provides an interface to a Vercel Postgres vector database. It
Class that extends VectorStore. It allows to perform similarity search using
Class for interacting with a Xata database as a VectorStore. Provides
ZepVectorStore is a VectorStore implementation that uses the Zep long-term memory store as a backend.
ZepCloudVectorStore is a VectorStore implementation
Function that converts an array of messages into a single string prompt
Function that converts an array of messages into a single string prompt
Get a session for the Portkey API. If one already exists with the same options,
Load a LangChain module from a serialized text representation.
Get a unique name for the module, rather than parent class implementations.
Condenses memory content into a single HumanMessage with context
Extracts and formats memory content into a system prompt
Converts Mem0 memories to a list of BaseMessages
Condenses Zep memory context into a single HumanMessage.
Extracts summary from Zep memory and composes a system prompt.
Converts Zep Memory to a list of BaseMessages, preserving the structure.
Converts a ReadableStream into a callback pattern.
Parses arbitary byte chunks into EventSource line buffers.
Parses line buffers into EventSourceMessages.
Interface for the arguments required to create an AWS Step Functions
The settings to instantiate the Momento standard cache.
The ChatFriendliParams interface defines the input parameters for
Deployed params
Project/space params
Project/space params
Deployed params
Project/space params
Deployed params
Gateway params
Project/space params
Note that the modelPath is the only required parameter. For testing you
The name and arguments of a function that should be called, as generated by the model.
Interface defining the input to the MoonshotChatInput class.
Interface defining the parameters for the Perplexity chat model.
Input to chat model class.
Interface defining the input to the ChatTencentHunyuan class.
Interface defining the input to the ChatTencentHunyuan class.
Interface defining the input to the ZhipuAIChatInput class.
Represents the parameters for configuring the CheerioWebBaseLoader. It
Interface representing the response from the Confluence API.
Interface representing a Confluence page.
Interface representing the parameters for configuring the
Interface representing a Figma file. It includes properties for the
Interface representing the parameters for configuring the FigmaLoader.
An interface that represents a file in a GitHub repository. It has
An interface that represents the parameters for the GithubRepoLoader
Represents the parameters for configuring WebBaseLoaders. It extends the
Interface representing the parameters for configuring the
Interface representing the parameters for configuring the
Represents the parameters for the S3Loader class. It includes
Interface representing the parameters for initializing a SitemapLoader.
See https://docs.sort.xyz/docs/api-keys to get your free Sort API key.
Interface representing the response from the SortXYZ API.
Interface representing the parameters for the SortXYZBlockchainLoader
Interface representing the parameters for configuring the TaskadeLoader.
Interface representing a Taskade project. It includes properties for the
Input parameters for the DeepInfra embeddings
Response from the DeepInfra embeddings API.
Interface for the request body to generate embeddings.
Interface that extends EmbeddingsParams and defines additional
Interface for GradientEmbeddings parameters. Extends EmbeddingsParams and
Interface that extends EmbeddingsParams and defines additional
Note that the modelPath is the only required parameter. For testing you
Interface for MinimaxEmbeddings parameters. Extends EmbeddingsParams and
Interface for PremEmbeddings parameters. Extends EmbeddingsParams and
Interface that extends EmbeddingsParams and defines additional
Interface that extends EmbeddingsParams and defines additional
Interface that extends EmbeddingsParams and defines additional
Interface for TogetherAIEmbeddingsParams parameters. Extends EmbeddingsParams and
Interface for the request body to generate embeddings.
Interface that extends EmbeddingsParams and defines additional
Interface that extends EmbeddingsParams and defines additional
Parameters for the GoogleVertexAIMultimodalEmbeddings class, extending
Interface for AI21 input parameters.
Interface for the input parameters specific to the Aleph Alpha LLM.
The FriendliParams interface defines the input parameters for
The GradientLLMParams interface defines the input parameters for
Interface defining the parameters for configuring the Hugging Face
Call interface for second parameter of inbuild methods
Parameters for basic llm invoke
Parameters for basic llm invoke
Constructor input interfaces for each mode
Parameters for basic llm invoke
Note that the modelPath is the only required parameter. For testing you
The input parameters for the RaycastAI class, which extends the BaseLLMParams interface.
Interface defining the structure of the input data for the Replicate
The SageMakerEndpointInput interface defines the input parameters for
Note that the modelPath is the only required parameter. For testing you
Interface for the input parameters specific to the Writer model.
Interface for objects that can be serialized.
Interface for the input parameters of the BaseChatMemory class.
Interface defining the structure of the input data for the Mem0Client
Interface defining the structure of the input data for the Mem0Memory
Interface for the structure of a memory message in the Motorhead
Interface defining the structure of the input data for the ZepMemory
Interface defining the structure of the input data for the ZepMemory
Interface for the arguments required to initialize an Azion library.
Interface for the fields required during the initialization of a
Interface for the parameters required to initialize a RemoteRetriever
Interface for the parameters required to initialize a RemoteRetriever
Configuration interface for the ZepRetriever class. Extends the
Configuration interface for the ZepRetriever class. Extends the
Configuration options for initializing a CassandraKVStore.
Type definition for the input parameters required to initialize an
Interface that defines the configuration for the
Extends the DataStax driver's client options with additional configurations for service providers,
Interface defining the fields required to create an instance of
Type for the input to the FileSystemChatMessageHistory constructor.
Interface for FirestoreDBChatMessageHistory. It includes the collection
The settings to instantiate the Momento chat message history.
Interface for parameters required to create an instance of
Interface for AWS Step Functions configuration.
Interface for the parameters required to instantiate a BraveSearch
An object containing configuration parameters for the ConneryService class.
DataForSeoApiConfig
Base interface for the input parameters of the DynamicTool and
Interface for the input parameters of the DynamicStructuredTool class.
Interface for the input parameters of the DynamicTool class.
Interface for parameters required by GoogleCustomSearch class.
Interface for parameters required by GooglePlacesAPI class.
Interface for parameter s required by GoogleRoutesAPI class.
Interface for parameters required by the SERPGoogleScholarAPITool class.
Interface for parameters required by SERPGoogleTrendsTool class.
Interface for the parameters that can be passed to the
Defines the configuration options for connecting to Astra DB, DataStax's cloud-native Cassandra-as-a-Service.
Extends the DataStax driver's client options with additional configurations for service providers,
Encapsulates the service provider-specific arguments required for creating a Cassandra client.
Defines the configuration arguments for initializing a Cassandra table within an application.
Represents the definition of a column within a Cassandra table schema.
Represents a filter condition used in constructing WHERE clauses for querying Cassandra tables.
Defines an index on a Cassandra table column, facilitating efficient querying by column values.
Represents a message sent in an event stream
Interface defining the arguments required to create an instance of
Interface for the arguments required to initialize an Azion library.
Configuration options for the AzureAISearchStore constructor.
Azure AI Search settings.
Extends the DataStax driver's client options with additional configurations for service providers,
Defines the parameters for the delete method in the Chroma class.
Type for filtering search results in the ClickHouse database.
Arguments for the ClickHouseStore class, which include the host, port,
Mapping of columns in the ClickHouse database.
Arguments for creating a CloseVectorNode instance, extending CloseVectorHNSWLibArgs.
Arguments for creating a CloseVectorWeb instance, extending CloseVectorHNSWLibArgs.
This interface define the optional fields for adding vector
This interface defines the fields required to initialize a query vector store
Interface for create_index method parameters
This interface define the optional fields for adding vector
This interface defines the fields required to initialize a vector store
Interface defining the arguments required to create an Elasticsearch
Configuration options for hybrid retrieval strategy.
Interface for the arguments required to initialize a FaissStore
Allows us to create IdDocument classes that contain the ID.
Parameters necessary to configure the Matching Engine.
Used to represent parameters that are necessary to delete documents
Information about the Matching Engine public API endpoint.
Interface defining the arguments required to create an instance of
Interface for the arguments that can be passed to the HNSWLib
Interface for the base configuration of HNSWLib. It includes the space
Interface for LibSQLVectorStore configuration options.
Interface that defines the arguments required to create a
Interface for the arguments required by the Milvus class constructor.
Mapping of columns in the MyScale database.
Type for filtering search results in the MyScale database.
Arguments for the MyScaleStore class, which include the host, port,
Interface that defines the arguments required to create a
Interface defining the arguments required to create an instance of the
Interface that defines the arguments required to create a
Configuration for column types to enable proper type casting in SQL queries.
Vector store arguments
Interface for the arguments required to initialize a Supabase library.
Interface that defines the arguments required to create a
Typesense vector store configuration.
This interface defines the arguments for the UpstashVectorStore class.
Interface that defines the arguments that can be passed to the
Interface for the context configuration used in Vectara API calls.
Interface for the file objects to be uploaded to Vectara.
Interface for the arguments required to initialize a VectaraStore
Interface that defines the arguments required to create a
Interface for the arguments required to create a XataClient. Includes
Interface for the arguments required to initialize a ZepVectorStore
Interface for the configuration options for a ZepVectorStore instance.
Interface for the parameters required to delete documents from a
Interface for the configuration options for a ZepCloudVectorStore instance.
Interface for the parameters required to delete documents from a
Type representing the role of a message in the Tongyi chat model.
Type representing the role of a message in the Friendli chat model.
Type representing the sender_type of a message in the Minimax chat model.
Type representing the role of a message in the Perplexity chat model.
Set the chunking_strategy to chunk text into larger or smaller elements. Defaults to None with optional arg of by_title
Represents the available hi-res models for the UnstructuredLoader. It can
To enable or disable table extraction for file types other than PDF, set
An enumeration of possible handling strategies for unknown file types.
Represents the available strategies for the UnstructuredLoader. It can
A type that represents a function that takes a single object (an Apify
Represents the parameters for the GoogleCloudStorageLoader class. It includes
Type representing a function for evaluating JavaScript code on a web
Type representing a function for evaluating JavaScript code on a web
The media should have a text property, an image property, or both.
Options for configuring the SQLiteRecordManager class.
Type definition for AI21 penalty data.
Types of standard sensitive information that can be detected.
Options for the redact function.
Represents a filter condition for querying the Azion database
Represents a database column name
Valid SQL operators that can be used in filter conditions
Type for the authentication method used by the RemoteRetriever. It can
Type for the JSON response values from the remote server.
Options for the TavilySearchAPIRetriever class, which includes a BaseLanguageModel
Type that defines the config required to initialize the
Type definition for the input parameters required when instantiating a
Type that defines the config required to initialize the
Represents a lightweight file chat session.
Type for the store of chat sessions.
Represents a stored chat session.
Type for the input parameter of the RedisChatMessageHistory
Type definition for the input parameters required when instantiating a
Type definition for the input parameters required when instantiating a
Type definition for the input parameters required to initialize an
An object type that represents the input for the XataChatMessageHistory
SearchApiParameters Type Definition.
Defines the parameters that can be passed to the Serper class during
Defines a type for specifying WHERE clause conditions in Cassandra queries.
Represents a filter condition for querying the Azion database
Represents a database column name
Valid SQL operators that can be used in filter conditions
Azure AI Search options for adding documents.
Azure AI Search indexed document.
Azure AI Search options metadata schema.
Azure AI Search filter type.
Azure AI Search query type.
Defines the arguments that can be passed to the Chroma class
Type that defines the config required to initialize the
Enum for different distance strategies supported by Couchbase vector search
Defines the arguments for the LanceDB class constructor. It includes a
Type of metric used in the MyScale database.
Functions to measure vector distance/similarity by.
Type definition for the arguments required to initialize a
Type that defines the parameters for the delete method.