Back to library

Vector Database Evaluation and Requirements

A vector database stores and searches high-dimensional numerical representations (embeddings) of content. For AI products, it's the infrastructure layer that makes semantic search, RAG, and similarity-based recommendations possible.

---

Context

When you need a vector database: RAG, semantic search, recommendations, deduplication, AI agent memory. When you do NOT need one: Data fits in one LLM context window, keyword search is sufficient, or fewer than ~10,000 embeddings.

---

Step 1 — Define the vector database use case

Assess: content type, data volume (now and 12 months), query volume, metadata filtering needs, freshness requirement, and read/write ratio.

Step 2 — Evaluate implementation options

Four options:

  • Managed service (Pinecone, Weaviate Cloud, Qdrant Cloud): Production reliability, no infra overhead
  • Self-hosted open-source (Qdrant, Weaviate, Milvus): Cost control at scale, data sovereignty
  • pgvector (PostgreSQL extension): Teams already on Postgres, < 1M vectors
  • In-memory/embedded (FAISS, ChromaDB local, LanceDB): Prototyping, < 100k vectors
  • Recommendation framework based on vector count, team capacity, and use case.

    Step 3 — Write the vector database requirements

    Functional (upsert, delete, similarity search, metadata filtering, similarity scores), Performance (query latency p95, ingestion throughput, index build time), Scale (launch to 12-month targets), Reliability (availability, durability, backups), Security (auth, encryption, data residency, audit logging), and Operational (monitoring, alerting, schema migration).

    Step 4 — Define the data model

    Record structure (id, vector, metadata fields), index configuration (HNSW/IVF/Flat, distance metric, parameters), namespace/collection strategy, and embedding model alignment (dimension must match).

    Quality check before delivering

    Data volume estimate includes 12-month projection
    Metadata filtering fields are explicitly listed
    Vector dimension is specified — must match embedding model
    Performance requirements have numeric targets
    pgvector vs. dedicated vector DB decision is explicit
    Suggested next step: Before selecting a vector database, confirm the embedding model dimension. Changing the embedding model after the vector database is populated requires re-embedding all content — an expensive migration. Lock the embedding model first.