pgvector
The Postgres extension that adds vector types and similarity indexes to the database you already run — the pragmatic default for embedding search below very large scale.
Production AI is a system: context, tools, permissions, traces, evals, and feedback loops around the model.
What it is
pgvector is an open-source Postgres extension: a vector column type, distance operators (cosine, L2, inner product), and HNSW or IVFFlat indexes for fast approximate search. Embeddings live in the same database as the rows they describe, with joins, transactions, and access control included.
Why it matters
A dedicated vector database is another system to deploy, govern, sync, and pay for — and the sync is where retrieval bugs breed. With pgvector, the metadata filter, the permission check, and the similarity search are one SQL query against one source of truth.
How we use it
pgvector with HNSW indexes is the only vector store in our production stack. Retrieval chunks, identity vectors, and memory embeddings all live in Postgres, and hybrid search fuses the vector leg with Postgres full-text ranking at query time.
Related resources
How an AI agent finds the right document, chunk, or row to ground its answer in — and why the part that matters is the pipeline around the database, not the database itself.
The search behind your AI combines two ways of looking — by exact words and by meaning — then gives the best candidates a careful second read, so answers that exist in your documents actually get found.
The pattern where an AI agent retrieves relevant context from your data before generating an answer — instead of relying only on what the model learned during training.
An architecture that combines cheap object storage with warehouse-grade table guarantees — the substrate where analytics, AI retrieval, and ML training read from the same governed tables.