Skip to content

Providers

Embex supports a wide range of vector databases. Switching providers is as simple as changing the provider and URL parameters.

StageProviderWhy?
DevelopmentLanceDBZero Setup. Runs locally (embedded). No Docker or API keys needed.
ProductionQdrant / Pinecone / MilvusScale. Managed services, high throughput, distributed.

Start here. LanceDB runs in-process and stores data in the local filesystem.

# Persist to local folder (creates ./data directory)
client = await EmbexClient.new_async(provider="lancedb", url="./data")

When you’re ready to scale, switch to a cloud provider.

Managed serverless vector database.

client = await EmbexClient.new_async(
provider="pinecone",
url="https://index-name.svc.pinecone.io",
api_key="your-api-key"
)

High-performance Rust vector database (Cloud or Self-Hosted).

# Qdrant Cloud
client = await EmbexClient.new_async(
provider="qdrant",
url="https://xyz-example.eu-central.aws.cloud.qdrant.io:6333",
api_key="your-api-key"
)
# Local Docker
client = await EmbexClient.new_async(
provider="qdrant",
url="http://localhost:6333"
)

The Elasticsearch adapter is available in the source tree for the next release. Use the elasticsearch provider with the cluster’s HTTP(S) endpoint. Pass the encoded Elasticsearch API key through api_key in Python or as the third argument to newAsync in Node.js. Omit it for a local cluster with security disabled.

import os
client = await EmbexClient.new_async(
provider="elasticsearch",
url=os.environ["ELASTICSEARCH_URL"],
api_key=os.environ.get("ELASTICSEARCH_API_KEY"),
)

Create collections through Embex so the index has the vector and metadata mappings. Collection names use lowercase ASCII letters, digits, hyphens, underscores and periods, starting with a letter or digit. Elasticsearch 8.19 and 9.x provide the kNN and point-in-time APIs used by the adapter. The adapter uses Elasticsearch relevance scores, exact string filters, and numeric range filters. Give each metadata key a consistent type across points. Numeric metadata is indexed as double precision for filtering. Bulk writes wait for a refresh, which requires the maintenance or manage index privilege on secured clusters. A migration cursor stays valid for one minute between pages.

Run the optional lifecycle integration test against a dedicated Elasticsearch instance with ELASTICSEARCH_URL and, when needed, ELASTICSEARCH_API_KEY set.

Terminal window
cargo test -p bridge-embex-elasticsearch --test elasticsearch real_elasticsearch_lifecycle -- --ignored
client = await EmbexClient.new_async(provider="milvus", url="http://localhost:19530")
client = await EmbexClient.new_async(provider="weaviate", url="http://localhost:8080")
client = await EmbexClient.new_async(provider="chroma", url="http://localhost:8000")
client = await EmbexClient.new_async(
provider="pgvector",
url="postgresql://user:pass@localhost:5432/db"
)
ProviderProvider StringExample URL
Pinecone"pinecone""https://index-name.svc.pinecone.io"
Qdrant"qdrant""http://localhost:6333"
Milvus"milvus""http://localhost:19530"
Weaviate"weaviate""http://localhost:8080"
Chroma"chroma""http://localhost:8000"
PgVector"pgvector""postgresql://user:pass@localhost:5432/db"
LanceDB"lancedb""./data"
Elasticsearch"elasticsearch""http://localhost:9200"

The opensearch and redis adapters are experimental placeholders. Their vector operations currently return NotImplemented.