From 7e7682a06dc186403165b5a2535fc1896b3fc00c Mon Sep 17 00:00:00 2001 From: Kartik Date: Sat, 27 Jun 2026 12:40:16 +0530 Subject: [PATCH] docs(vectordbs): correct vector store config defaults & imports (#5843) --- docs/components/vectordbs/dbs/baidu.mdx | 2 +- docs/components/vectordbs/dbs/elasticsearch.mdx | 2 ++ docs/components/vectordbs/dbs/faiss.mdx | 1 + docs/components/vectordbs/dbs/langchain.mdx | 6 +++--- docs/components/vectordbs/dbs/mongodb.mdx | 6 +++--- docs/components/vectordbs/dbs/neptune_analytics.mdx | 2 +- docs/components/vectordbs/dbs/upstash-vector.mdx | 4 +++- docs/components/vectordbs/dbs/valkey.mdx | 4 ++-- docs/components/vectordbs/dbs/vertex_ai.mdx | 5 +++-- docs/components/vectordbs/dbs/weaviate.mdx | 5 +++-- docs/components/vectordbs/overview.mdx | 2 +- 11 files changed, 23 insertions(+), 16 deletions(-) diff --git a/docs/components/vectordbs/dbs/baidu.mdx b/docs/components/vectordbs/dbs/baidu.mdx index 0a738fd6e..72a26a4ce 100644 --- a/docs/components/vectordbs/dbs/baidu.mdx +++ b/docs/components/vectordbs/dbs/baidu.mdx @@ -46,7 +46,7 @@ Here are the parameters available for configuring Baidu VectorDB: | `account` | Baidu VectorDB account name | `root` | | `api_key` | API key for accessing Baidu VectorDB | Required | | `database_name` | Name of the database | `mem0` | -| `table_name` | Name of the table | `mem0_table` | +| `table_name` | Name of the table | `mem0` | | `embedding_model_dims` | Dimensions of the embedding model | `1536` | | `metric_type` | Distance metric for similarity search | `L2` | diff --git a/docs/components/vectordbs/dbs/elasticsearch.mdx b/docs/components/vectordbs/dbs/elasticsearch.mdx index d6d4dec1c..1c6961c3f 100644 --- a/docs/components/vectordbs/dbs/elasticsearch.mdx +++ b/docs/components/vectordbs/dbs/elasticsearch.mdx @@ -56,6 +56,8 @@ Here are the parameters available for configuring Elasticsearch: | `api_key` | API key for authentication | `None` | | `user` | Username for basic authentication | `None` | | `password` | Password for basic authentication | `None` | +| `use_ssl` | Whether to use SSL for the connection | `True` | +| `ca_certs` | Path to CA bundle for SSL certificate verification | `None` | | `verify_certs` | Whether to verify SSL certificates | `True` | | `auto_create_index` | Whether to automatically create the index | `True` | | `custom_search_query` | Function returning a custom search query | `None` | diff --git a/docs/components/vectordbs/dbs/faiss.mdx b/docs/components/vectordbs/dbs/faiss.mdx index cf98a5e66..b4523afed 100644 --- a/docs/components/vectordbs/dbs/faiss.mdx +++ b/docs/components/vectordbs/dbs/faiss.mdx @@ -55,6 +55,7 @@ Here are the parameters available for configuring FAISS: | `path` | Path to store FAISS index and metadata | `/tmp/faiss/` | | `distance_strategy` | Distance metric strategy to use (options: 'euclidean', 'inner_product', 'cosine') | `euclidean` | | `normalize_L2` | Whether to normalize L2 vectors (only applicable for euclidean distance) | `False` | +| `embedding_model_dims` | Dimensions of the embedding model | `1536` | ### Performance Considerations diff --git a/docs/components/vectordbs/dbs/langchain.mdx b/docs/components/vectordbs/dbs/langchain.mdx index edaedab6c..ce4cd0537 100644 --- a/docs/components/vectordbs/dbs/langchain.mdx +++ b/docs/components/vectordbs/dbs/langchain.mdx @@ -47,12 +47,12 @@ m.add(messages, user_id="alice", metadata={"category": "movies"}) ``` ```typescript TypeScript -import { Memory } from "mem0ai"; +import { Memory } from "mem0ai/oss"; import { OpenAIEmbeddings } from "@langchain/openai"; -import { MemoryVectorStore as LangchainMemoryStore } from "langchain/vectorstores/memory"; +import { MemoryVectorStore } from "langchain/vectorstores/memory"; const embeddings = new OpenAIEmbeddings(); -const vectorStore = new LangchainVectorStore(embeddings); +const vectorStore = new MemoryVectorStore(embeddings); const config = { "vector_store": { diff --git a/docs/components/vectordbs/dbs/mongodb.mdx b/docs/components/vectordbs/dbs/mongodb.mdx index f110609c1..57f3fd432 100644 --- a/docs/components/vectordbs/dbs/mongodb.mdx +++ b/docs/components/vectordbs/dbs/mongodb.mdx @@ -42,8 +42,8 @@ Here are the parameters available for configuring MongoDB: | Parameter | Description | Default Value | | --- | --- | --- | | db_name | Name of the MongoDB database | `"mem0_db"` | -| collection_name | Name of the MongoDB collection | `"mem0_collection"` | +| collection_name | Name of the MongoDB collection | `"mem0"` | | embedding_model_dims | Dimensions of the embedding vectors | `1536` | -| mongo_uri | The MongoDB URI connection string | `mongodb://username:password@localhost:27017` | +| mongo_uri | The MongoDB URI connection string | `mongodb://localhost:27017` | -> **Note**: If `mongo_uri` is not provided, it will default to `mongodb://username:password@localhost:27017`. +> **Note**: If `mongo_uri` is not provided, it will default to `mongodb://localhost:27017`. diff --git a/docs/components/vectordbs/dbs/neptune_analytics.mdx b/docs/components/vectordbs/dbs/neptune_analytics.mdx index ae3cb814a..12d601b99 100644 --- a/docs/components/vectordbs/dbs/neptune_analytics.mdx +++ b/docs/components/vectordbs/dbs/neptune_analytics.mdx @@ -10,7 +10,7 @@ description: "Use AWS Neptune Analytics as a vector store in Mem0, combining gra ## Installation ```bash -pip install mem0ai[vector_stores] +pip install mem0ai[vector-stores] ``` ## Usage diff --git a/docs/components/vectordbs/dbs/upstash-vector.mdx b/docs/components/vectordbs/dbs/upstash-vector.mdx index 979242fef..6b20544b8 100644 --- a/docs/components/vectordbs/dbs/upstash-vector.mdx +++ b/docs/components/vectordbs/dbs/upstash-vector.mdx @@ -18,7 +18,9 @@ os.environ["UPSTASH_VECTOR_REST_TOKEN"] = "..." config = { "vector_store": { "provider": "upstash_vector", - "enable_embeddings": True, + "config": { + "enable_embeddings": True, + } } } diff --git a/docs/components/vectordbs/dbs/valkey.mdx b/docs/components/vectordbs/dbs/valkey.mdx index af1e28219..e326f2b64 100644 --- a/docs/components/vectordbs/dbs/valkey.mdx +++ b/docs/components/vectordbs/dbs/valkey.mdx @@ -9,7 +9,7 @@ description: "Use Valkey as an open-source vector store in Mem0 for high-perform ## Installation ```bash -pip install mem0ai[vector_stores] +pip install mem0ai[vector-stores] ``` ## Usage @@ -51,7 +51,7 @@ Here are the parameters available for configuring Valkey: | `hnsw_ef_construction` | Size of dynamic candidate list for HNSW | `200` | | `hnsw_ef_runtime` | Size of dynamic candidate list for search | `10` | | `cluster_mode` | Enable cluster mode for Valkey cluster (CME) deployments | `false` | -| `distance_metric` | Distance metric for vector similarity | `cosine` | +| `timezone` | Timezone for timestamp handling | `UTC` | ## Cluster Mode diff --git a/docs/components/vectordbs/dbs/vertex_ai.mdx b/docs/components/vectordbs/dbs/vertex_ai.mdx index e3a326eeb..6df1b5b1d 100644 --- a/docs/components/vectordbs/dbs/vertex_ai.mdx +++ b/docs/components/vectordbs/dbs/vertex_ai.mdx @@ -24,7 +24,7 @@ config = { "deployment_index_id": "YOUR_DEPLOYMENT_INDEX_ID", # Required: Deployment-specific ID "project_id": "YOUR_PROJECT_ID", # Required: Google Cloud project ID "project_number": "YOUR_PROJECT_NUMBER", # Required: Google Cloud project number - "region": "YOUR_REGION", # Optional: Defaults to GOOGLE_CLOUD_REGION + "region": "YOUR_REGION", # Required: Google Cloud region "credentials_path": "path/to/credentials.json", # Optional: Defaults to GOOGLE_APPLICATION_CREDENTIALS "vector_search_api_endpoint": "YOUR_API_ENDPOINT" # Required for get operations } @@ -45,5 +45,6 @@ m.add("Your text here", user_id="user", metadata={"category": "example"}) | `project_id` | Google Cloud project ID | Yes | | `project_number` | Google Cloud project number | Yes | | `vector_search_api_endpoint` | Vector search API endpoint | Yes (for get operations) | -| `region` | Google Cloud region | No (defaults to GOOGLE_CLOUD_REGION) | +| `region` | Google Cloud region | Yes | | `credentials_path` | Path to service account credentials | No (defaults to GOOGLE_APPLICATION_CREDENTIALS) | +| `service_account_json` | Service account credentials as a dictionary (alternative to `credentials_path`) | `None` | diff --git a/docs/components/vectordbs/dbs/weaviate.mdx b/docs/components/vectordbs/dbs/weaviate.mdx index b08629d92..2d24e8546 100644 --- a/docs/components/vectordbs/dbs/weaviate.mdx +++ b/docs/components/vectordbs/dbs/weaviate.mdx @@ -7,7 +7,7 @@ description: "Use Weaviate as an open-source vector search engine in Mem0 for st ### Installation ```bash -pip install weaviate weaviate-client +pip install weaviate-client ``` ### Usage @@ -48,4 +48,5 @@ Here are the parameters available for configuring Weaviate: | `collection_name` | The name of the collection to store the vectors | `mem0` | | `embedding_model_dims` | Dimensions of the embedding model | `1536` | | `cluster_url` | URL for the Weaviate server | `None` | -| `auth_client_secret` | API key for Weaviate authentication | `None` | \ No newline at end of file +| `auth_client_secret` | API key for Weaviate authentication | `None` | +| `additional_headers` | Additional headers to include in requests (`Dict[str, str]`) | `None` | \ No newline at end of file diff --git a/docs/components/vectordbs/overview.mdx b/docs/components/vectordbs/overview.mdx index dbc06e7ed..13a27c883 100644 --- a/docs/components/vectordbs/overview.mdx +++ b/docs/components/vectordbs/overview.mdx @@ -10,7 +10,7 @@ Mem0 includes built-in support for various popular databases. Memory can utilize See the list of supported vector databases below. - The following vector databases are supported in the Python implementation. The TypeScript implementation currently only supports Qdrant, Redis, Valkey, Vectorize and in-memory vector database. + The following vector databases are supported in the Python implementation. The TypeScript implementation currently supports Qdrant, Redis, PGVector, Supabase, LangChain, Azure AI Search, Vectorize, and an in-memory store.