repositories
loading repo index
repositories
loading repo index
repository
loading code, commits, and activity
public Clawd ADK gateway launch mirror
stars
latest
clone command
git clone gitlawb://did:key:z6Mkq5mY...iFZ5/my-project-publ...git clone gitlawb://did:key:z6Mkq5mY.../my-project-publ...2fa351d6docs: add automaton and perps launch sources16d ago| #1 | --- |
| #2 | title: Vertex AI Vector Search |
| #3 | --- |
| #4 | |
| #5 | |
| #6 | ### Usage |
| #7 | |
| #8 | To use Google Cloud Vertex AI Vector Search with `mem0`, you need to configure the `vector_store` in your `mem0` config: |
| #9 | |
| #10 | |
| #11 | ```python |
| #12 | import os |
| #13 | from mem0 import Memory |
| #14 | |
| #15 | os.environ["GOOGLE_API_KEY"] = "sk-xx" |
| #16 | |
| #17 | config = { |
| #18 | "vector_store": { |
| #19 | "provider": "vertex_ai_vector_search", |
| #20 | "config": { |
| #21 | "endpoint_id": "YOUR_ENDPOINT_ID", # Required: Vector Search endpoint ID |
| #22 | "index_id": "YOUR_INDEX_ID", # Required: Vector Search index ID |
| #23 | "deployment_index_id": "YOUR_DEPLOYMENT_INDEX_ID", # Required: Deployment-specific ID |
| #24 | "project_id": "YOUR_PROJECT_ID", # Required: Google Cloud project ID |
| #25 | "project_number": "YOUR_PROJECT_NUMBER", # Required: Google Cloud project number |
| #26 | "region": "YOUR_REGION", # Optional: Defaults to GOOGLE_CLOUD_REGION |
| #27 | "credentials_path": "path/to/credentials.json", # Optional: Defaults to GOOGLE_APPLICATION_CREDENTIALS |
| #28 | "vector_search_api_endpoint": "YOUR_API_ENDPOINT" # Required for get operations |
| #29 | } |
| #30 | } |
| #31 | } |
| #32 | m = Memory.from_config(config) |
| #33 | m.add("Your text here", user_id="user", metadata={"category": "example"}) |
| #34 | ``` |
| #35 | |
| #36 | |
| #37 | ### Required Parameters |
| #38 | |
| #39 | | Parameter | Description | Required | |
| #40 | |-----------|-------------|----------| |
| #41 | | `endpoint_id` | Vector Search endpoint ID | Yes | |
| #42 | | `index_id` | Vector Search index ID | Yes | |
| #43 | | `deployment_index_id` | Deployment-specific index ID | Yes | |
| #44 | | `project_id` | Google Cloud project ID | Yes | |
| #45 | | `project_number` | Google Cloud project number | Yes | |
| #46 | | `vector_search_api_endpoint` | Vector search API endpoint | Yes (for get operations) | |
| #47 | | `region` | Google Cloud region | No (defaults to GOOGLE_CLOUD_REGION) | |
| #48 | | `credentials_path` | Path to service account credentials | No (defaults to GOOGLE_APPLICATION_CREDENTIALS) | |
| #49 |