Blog / Databases

Databases

PostgreSQL-first data design: pgvector, row-level security, migrations and keeping embeddings beside the rows they describe.

Every AI stack article assumes a dedicated vector database. I have not needed one. In Kilele Archade the vectors describe rows that already live in PostgreSQL — documents, subjects, competences — so splitting them across two systems would have bought a second security model, a second backup story and a sync problem for no capability I was using.

These notes are about that trade and the practical edges of it: picking an embedding dimension you can live with, when an index is actually worth building, and why transactions over documents and their embeddings are worth more than a marginally faster similarity search.

Writing on databases (1)

Built in practice

Hire for this

Other topics

← All writing · Work with Fredrick Onyango