Vald vector database.
To use, you should have the vald-client-python python package installed.
TiDB Vector Store.
Tair vector store.
VectorStore backed by pgvecto_rs.
DocumentDB Similarity Type as enumerator.
Amazon DocumentDB (with MongoDB compatibility) vector store.
Please refer to the official Vector Search documentation for more details:
https://docs.aws.amazon.com/documentdb/latest/developerguide/v
Momento Vector Index (MVI) vector store.
Momento Vector Index is a serverless vector index that can be used to store and
search vectors. To use you should have the momento python package instal
Base class for Elasticsearch retrieval strategies.
VectorStore connecting to Pathway Vector Store.
LanceDB vector store.
To use, you should have lancedb python package installed.
You can install it with pip install lancedb.
Jaguar API vector store.
See http://www.jaguardb.com See http://github.com/fserv/jaguar-sdk
Baidu Elasticsearch vector store.
Configuration for a Zep Collection.
If the collection does not exist, it will be created.
Zep vector store.
It provides methods for adding texts or documents to the store, searching for similar documents, and deleting documents.
Search scores are calculated using cosine similarity norm
NucliaDB vector store.
ClickHouse client configuration.
ClickHouse vector store integration.
Enumerator for different search strategies in FalkorDB VectorStore.
SearchType.VECTOR: This option searches using only
the vector indexes in the vectorstore, relying on the
similarity between vecEnumerator of the index types.
FalkorDB vector index.
To use, you should have the falkordb python package installed
Baidu VectorDB Connection params.
See the following documentation for details: https://cloud.baidu.com/doc/VDB/s/6lrsob0wy
Baidu VectorDB table params.
See the following documentation for details: https://cloud.baidu.com/doc/VDB/s/mlrsob0p6
Baidu VectorDB as a vector store.
In order to use this you need to have a database instance. See the following documentation for details: https://cloud.baidu.com/doc/VDB/index.html
Annoy vector store.
To use, you should have the annoy python package installed.
Enumerator of the Distance strategies for calculating distances between vectors.
vikingdb connection config
See the following documentation for details: https://www.volcengine.com/docs/6459/1167770
vikingdb as a vector store
In order to use this you need to have a database instance. See the following documentation for details: https://www.volcengine.com/docs/6459/1167774
DashVector vector store.
To use, you should have the dashvector python package installed.
TileDB vector store.
To use, you should have the tiledb-vector-search python package installed.
AwaDB vector store.
Qdrant related exceptions.
Hippo vector store.
You need to install hippo-api and run Hippo.
Please visit our official website for how to run a Hippo instance: https://www.transwarp.cn/starwarp
Enumerator of the Distance strategies.
Some default dimensions for known embeddings.
Kinetica client configuration.
Kinetica vector store.
To use, you should have the gpudb python package installed.
Atlas vector store.
Atlas is the Nomic's neural database and rhizomatic instrument.
To use, you should have the nomic python package installed.
Supabase Postgres vector store.
It assumes you have the pgvector
extension installed and a match_documents (or similar) function. For more details:
https://integrations.langchain.com/vectorstor
Zilliz vector store.
You need to have pymilvus installed and a
running Zilliz database.
See the following documentation for how to run a Zilliz instance: https://docs.zilliz.com/docs/create-clus
CosmosDB Query Type
Aerospike vector store.
To use, you should have the aerospike_vector_search python package installed.
Xata vector store.
It assumes you have a Xata database created with the right schema. See the guide at: https://integrations.langchain.com/vectorstores?integration_name=XataVectorStore
StarRocks client configuration.
StarRocks vector store.
You need a pymysql python package, and a valid account
to connect to StarRocks.
Right now StarRocks has only implemented cosine_similarity function to
compute distance
VLite is a simple and fast vector database for semantic search.
Cosmos DB Similarity Type as enumerator.
Cosmos DB Vector Search Type as enumerator.
Azure Cosmos DB for MongoDB vCore vector store.
To use, you should have both:
pymongo python package installedAmazon OpenSearch Vector Engine vector store.
Alibaba Cloud Opensearch` client configuration.
Alibaba Cloud OpenSearch vector store.
DuckDB vector store.
This class provides a vector store interface for adding texts and performing similarity searches using DuckDB.
For more information about DuckDB, see: https://duckdb.org/
Thi
Meilisearch vector store.
To use this, you need to have meilisearch python package installed,
and a running Meilisearch instance.
To learn more about Meilisearch Python, refer to the in-depth Me
Infinispan VectorStore interface.
This class exposes the method to present Infinispan as a VectorStore. It relies on the Infinispan class (below) which takes care of the REST interface with the ser
Helper class for Infinispan REST interface.
This class exposes the Infinispan operations needed to create and set up a vector db.
You need a running Infinispan (15+) server without authentication.
Apache Doris client configuration.
Apache Doris vector store.
You need a pymysql python package, and a valid account
to connect to Apache Doris.
For more information, please visit [Apache Doris official site](https://doris.ap
SurrealDB as Vector Store.
To use, you should have the surrealdb python package installed.
FAISS vector store integration.
See The FAISS Library paper.
Bagel.net Inference platform.
To use, you should have the bagelML python package installed.
Upstash Vector vector store
To use, the upstash-vector python package must be installed.
Also an Upstash Vector index is required. First create a new Upstash Vector index and copy the `index_url
ScaNN vector store.
To use, you should have the scann python package installed.
Typesense vector store.
To use, you should have the typesense python package installed.
Configuration for summary generation.
is_enabled: True if summary is enabled, False otherwise max_results: maximum number of results to summarize response_lang: requested language for the summary pro
Configuration for Maximal Marginal Relevance (MMR) search. This will soon be deprated in favor of RerankConfig.
is_enabled: True if MMR is enabled, False otherwise mmr_k: number of results to fetc
Configuration for Reranker.
reranker: "mmr", "rerank_multilingual_v1", "udf" or "none" rerank_k: number of results to fetch before reranking, defaults to 50 mmr_diversity_bias: for MMR only - a numbe
Configuration for Vectara query.
k: Number of Documents to return. Defaults to 10. lambda_val: lexical match parameter for hybrid search. filter Dictionary of argument(s) to filter on metadata. For e
Vectara API vector store.
See (https://vectara.com).
Vectara Retriever class.
Vectara RAG runnable.
SemaDB vector store.
This vector store is a wrapper around the SemaDB database.
Wrapper around Epsilla vector database.
As a prerequisite, you need to install pyepsilla package
and have a running Epsilla vector database (for example, through our docker image)
See the followi
Hologres API vector store.
connection_string is a hologres connection string.embedding_function any embedding function implementing
langchain.embeddings.base.Embeddings interface.Dingo vector store.
To use, you should have the dingodb python package installed.
KDB.AI vector store.
See https://kdb.ai.
To use, you should have the kdbai_client python package installed.
MyScale client configuration.
MyScale vector store.
You need a clickhouse-connect python package, and a valid account
to connect to MyScale.
MyScale can not only search with simple vector indexes. It also supports a complex
MyScale vector store without metadata column
This is super handy if you are working to a SQL-native table
Vectorstore that uses ThirdAI's NeuralDB.
To use, you should have the thirdai[neural_db] python package installed.
Vectorstore that uses ThirdAI's NeuralDB Enterprise Python Client for NeuralDBs.
To use, you should have the thirdai[neural_db] python package installed.
Relyt (distributed PostgreSQL) vector store.
Relyt is a distributed full postgresql syntax cloud-native database.
connection_string is a postgres connection string.embedding_function any eManticoreSearch Engine vector store.
To use, you should have the manticoresearch python package installed.
AnalyticDB (distributed PostgreSQL) vector store.
AnalyticDB is a distributed full postgresql syntax cloud-native database.
connection_string is a postgres connection string.Base class for serializing data.
Serialize data in JSON using the json package from python standard library.
Serialize data in Binary JSON using the bson python package.
Serialize data in Apache Parquet format using the pyarrow package.
Exception raised by SKLearnVectorStore.
Simple in-memory vector store based on the scikit-learn library
NearestNeighbors.
Yellowbrick as a vector database. Example: .. code-block:: python from langchain_community.vectorstores import Yellowbrick from langchain_community.embeddings.openai import OpenAIE
Enumerator for the supported Index types within Yellowbrick.
Parameters for configuring a Yellowbrick index.
Zep vector store.
It provides methods for adding texts or documents to the store, searching for similar documents, and deleting documents.
Search scores are calculated using cosine similarity norm
Enumerator of the Distance strategies.
Base model for the SQL stores.
Azure Cognitive Search vector store.
Retriever that uses Azure Cognitive Search.
Base class for the Lantern embedding store.
Result from a query.
Enumerator of the Distance strategies.
Postgres with the lantern extension as a vector store.
lantern uses sequential scan by default. but you can create a HNSW index using the create_hnsw_index method.
connection_string is a postRockset vector store.
To use, you should have the rockset python package installed. Note that to use
this, the collection being used must already exist in your Rockset instance.
You must also ens
Tablestore vector store.
To use, you should have the tablestore python package installed.
Base model for all SQL stores.
Collection store.
Embedding store.
Result from a query.
Postgres with the pg_embedding extension as a vector store.
pg_embedding uses sequential scan by default. but you can create a HNSW index using the create_hnsw_index method.
connection_stringImplementation of Vector Store using LLMRails.
See https://llmrails.com/
Retriever for LLMRails.
Marqo vector store.
Marqo indexes have their own models associated with them to generate your embeddings. This means that you can selected from a range of different models and also use CLIP models
Timescale Postgres vector store
To use, you should have the timescale_vector python package installed.
Enumerator for the supported Index types
Enumerator of the Search strategies for searching in the vectorstore.
Vespa vector store.
To use, you should have the python client library pyvespa installed.
Tencent vector DB Connection params.
See the following documentation for details: https://cloud.tencent.com/document/product/1709/95820
Tencent vector DB Index params.
See the following documentation for details: https://cloud.tencent.com/document/product/1709/95826
MetaData Field for Tencent vector DB.
Tencent VectorDB as a vector store.
In order to use this you need to have a database instance. See the following documentation for details: https://cloud.tencent.com/document/product/1709/104489
SQLite with Vec extension as a vector database.
To use, you should have the sqlite-vec python package installed.
Example:
.. code-block:: python
from langchain_community.vectorstores
Enumerator of the types of search to perform.
Neo4j vector index.
To use, you should have the neo4j python package installed.
SQLite with VSS extension as a vector database.
To use, you should have the sqlite-vss python package installed.
Example:
.. code-block:: python
from langchain_community.vectorstores
USearch vector store.
To use, you should have the usearch python package installed.
ecloud Elasticsearch vector store.
Clarifai AI vector store.
To use, you should have the clarifai python SDK package installed.
RedisFilterOperator enumerator is used to create RedisFilterExpressions.
Collection of RedisFilterFields.
Base class for RedisFilterFields.
RedisFilterField representing a tag in a Redis index.
RedisFilterField representing a numeric field in a Redis index.
RedisFilterField representing a text field in a Redis index.
Logical expression of RedisFilterFields.
RedisFilterExpressions can be combined using the & and | operators to create complex logical expressions that evaluate to the Redis Query language.
This pres
Distance metrics for Redis vector fields.
Base class for Redis fields.
Schema for text fields in Redis.
Schema for tag fields in Redis.
Schema for numeric fields in Redis.
Base class for Redis vector fields.
Schema for flat vector fields in Redis.
Schema for HNSW vector fields in Redis.
Schema for Redis index.
Retriever for Redis VectorStore.
HnswLib storage using DocArray package.
To use it, you should have the docarray package with version >=0.32.0 installed.
You can install it with pip install docarray.
In-memory DocArray storage for exact search.
To use it, you should have the docarray package with version >=0.32.0 installed.
You can install it with pip install docarray.
Base class for DocArray based vector stores.
Helper for executing an MMR traversal query.
A link to/from a tag of a given kind.
Documents in a :class:graph vector store <langchain_community.graph_vectorstores.base.GraphVectorStore>
are connected via "links".
Links form a bipartite graph
Link documents with common named entities using GLiNER_.
GLiNER_ is a Named Entity Recognition (NER) model capable of identifying any
entity type using a bidirectional transformer encoder (BERT-l
Interface for extracting links (incoming, outgoing, bidirectional).
DocumentTransformer for applying one or more LinkExtractors.
ElasticVectorSearch uses the brute force method of searching on vectors.
Recommended to use ElasticsearchStore instead, which gives you the option to uses the approx HNSW algorithm which performs be
[DEPRECATED] Elasticsearch with k-nearest neighbor search
(k-NN) vector store.
Recommended to use ElasticsearchStore instead, which supports metadata filtering, customising the query retriever an
Approximate retrieval strategy using the HNSW algorithm.
Exact retrieval strategy using the script_score query.
Sparse retrieval strategy using the text_expansion processor.
Elasticsearch vector store.
ChromaDB vector store.
To use, you should have the chromadb python package installed.
Qdrant vector store.
from qdrant_client import QdrantClient
from langchain_qdrant import Qdrant
client = QdrantClient()
collection_name = "MyCollection"
qdrant = Qdrant(client, collectio
Google Cloud BigQuery vector store.
To use, you need the following packages installed: google-cloud-bigquery
Azure Cosmos DB for NoSQL vector store.
To use, you should have both:
- the azure-cosmos python package installed
You can read more about vector search, full text search and hybrid search
Deprecated. Use PineconeVectorStore instead.
Couchbase Vector Store vector store.
To use it, you need
couchbase libraryPostgres/PGVector vector store.
DEPRECATED: This class is pending deprecation and will likely receive no updates. An improved version of this class is available in `langchain_postgres
SingleStore DB vector store.
The prerequisite for using this class is the installation of the singlestoredb
Python package.
The SingleStoreDB vectorstore can be created by providing an embeddi
Milvus vector store. DO NOT USE. KEPT FOR BACKWARDS COMPATIBILITY.
You need to install pymilvus and run Milvus.
See the following documentation for how to run a Milvus instance: https://milvus.i
Redis vector database.
Node in the GraphVectorStore.
Edges exist from nodes with an outgoing link to nodes with a matching incoming link.
For instance two nodes a and b connected over a hyperlink https://some-url
A hybrid vector-and-graph graph store.
Document chunks support vector-similarity search as well as edges linking chunks based on structural and semantic properties.
.. versionadded:: 0.3.1
Retriever for GraphVectorStore.
A graph vector store retriever is a retriever that uses a graph vector store to retrieve documents. It is similar to a vector store retriever, except that it uses both
Import lancedb package.
Converts a dict filter to a LanceDB filter string.
Check if a string contains multiple substrings. Args: s: string to check. *args: substrings to check.
Convert a dictionary to a YAML-like string without using external libraries.
Parameters:
Returns:
Construct a metadata filter by directly injecting the filter values into the query.
Processes a nested list of entity data to extract information about labels, entity types, properties, index types, and index details (if applicable).
Import annoy if available, otherwise raise error.
Calculate maximal marginal relevance.
Filter out metadata types that are not supported for a vector store.
Import tiledb-vector-search if available, otherwise raise error.
Get the URI of the vector index.
Get the URI of the documents array from group.
Get the URI of the vector index.
Get the URI of the documents array.
Call the synchronous method if the async method is not implemented.
This decorator should only be used for methods that are defined as async in the class.
Check if a string has multiple substrings. Args: s: The string to check *args: The substrings to check for in the string
Print a debug message if DEBUG is True. Args: s: The message to print
Get a named result from a query. Args: connection: The connection to the database query: The query to execute
Create metadata from fields.
Import faiss if available, otherwise raise error. If FAISS_NO_AVX2 environment variable is set, it will be considered to load FAISS with no AVX2 optimization.
Normalize vectors to unit length.
Import scann if available, otherwise raise error.
Check if a string contains multiple substrings. Args: s: string to check. *args: substrings to check.
Get the embedding store class.
Create an index of embeddings for a list of contexts.
Translate LangChain filter to Tencent VectorDB filter.
Serializes a list of floats into a compact "raw bytes" format
Source: https://github.com/asg017/sqlite-vec/blob/21c5a14fc71c83f135f5b00c84115139fd12c492/examples/simple-python/demo.py#L8-L10
Check if the values are not None or empty string
Remove Lucene special characters
Import usearch if available, otherwise raise error.
Decorator to check for misuse of equality operators.
Read 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 RedisModel
Check if Redis index exists.
Render a collection of GraphVectorStore documents to GraphViz format.
Get the links from a document.
Add links to the given metadata.
Return a document with the given links added.
Return the networkx directed graph corresponding to the documents.
Convert nodes to documents.