Overview
Vector databases store AI-generated embeddings for similarity search, enabling Retrieval-Augmented Generation (RAG) systems. By routing embedding generation through ModelRiver, you get automatic failover across embedding providers: ensuring your ingestion and search pipelines never stall.
Why use ModelRiver with a vector database?
- Embedding failover: If one embedding provider is down, another takes over
- Consistent embeddings: Same workflow, same dimensions, regardless of provider
- Cost tracking: Monitor embedding generation costs separately from chat costs
- Unified observability: Both embedding and chat requests in one dashboard
Supported databases
| Database | Type | Highlights | Difficulty | Guide |
|---|---|---|---|---|
| Pinecone | Managed | Serverless, fast queries, production-scale | ⭐⭐ Medium | View guide → |
| Weaviate | Open-source | Custom vectorisers, hybrid search | ⭐⭐ Medium | View guide → |
| Supabase | PostgreSQL + pgvector | Full-stack, auth, real-time, RLS | ⭐⭐ Medium | View guide → |
How RAG works with ModelRiver
User question │ ▼┌─────────────────┐│ ModelRiver │──── Embed question via embedding workflow│ (Embeddings) │└────────┬────────┘ │ ▼┌─────────────────┐│ Vector DB │──── Find similar documents│ (Pinecone, etc) │└────────┬────────┘ │ ▼┌─────────────────┐│ ModelRiver │──── Generate answer with context via chat workflow│ (Chat) │└─────────────────┘Both the embedding and chat steps are routed through ModelRiver, so each has independent failover, cost tracking, and observability.
Pinecone
Fully managed vector database optimised for AI. Serverless deployment, fast queries, and production-scale indexing.
1from openai import OpenAI2from pinecone import Pinecone3 4client = OpenAI(base_url="https://api.modelriver.com/v1", api_key="mr_live_...")5pc = Pinecone(api_key="YOUR_PINECONE_KEY")Weaviate
Open-source vector search engine with custom vectorisers, hybrid search, and multi-modal support.
1from openai import OpenAI2import weaviate3 4client = OpenAI(base_url="https://api.modelriver.com/v1", api_key="mr_live_...")5wv = weaviate.connect_to_local()Supabase
Open-source Firebase alternative with built-in pgvector. Store embeddings alongside application data with auth, real-time, and Row Level Security.
1from openai import OpenAI2from supabase import create_client3 4client = OpenAI(base_url="https://api.modelriver.com/v1", api_key="mr_live_...")5supabase = create_client("https://YOUR_PROJECT.supabase.co", "YOUR_KEY")Next steps
- Observability Tools: Datadog and Sentry integration
- LLM Frameworks: Build RAG with LangChain or LlamaIndex
- API reference: Endpoint documentation