Sanity Context vs Supabase Vector for Lean AI Stacks
Your team shipped a support agent in a weekend. Supabase Vector, an embeddings table, a cron job to re-embed changed rows, and a thin retrieval function. It demoed beautifully.
Your team shipped a support agent in a weekend. Supabase Vector, an embeddings table, a cron job to re-embed changed rows, and a thin retrieval function. It demoed beautifully. Three weeks later the agent confidently cites a refund policy that changed in March, because the embedding for that paragraph never got re-generated when an editor fixed the source doc. Nobody noticed until a customer did.
That is the lean-stack trap. The pieces are cheap to assemble and expensive to keep honest. A vector database stores math, not meaning, and it has no idea your content drifted out from under it. Sanity Context is the AI Content Operating System for grounding agents, an intelligent backend where retrieval, embeddings, and editorial governance live in the same place instead of being stitched across three services you now have to babysit.
This article is a head-to-head for teams who genuinely want to stay lean. Supabase Vector is a legitimately good Postgres extension, and we are not going to pretend otherwise. The question is what "lean" costs you once the agent has to stay correct against content that changes every day, and where the glue you saved on day one turns into the system you maintain forever.

The day-one build looks identical, the day-90 build does not
On a whiteboard, both stacks draw the same: content goes in, embeddings get generated, an agent queries by similarity, answers come out. Supabase Vector gets you there with pgvector inside a Postgres database you may already run. You write the schema, the embedding job, and the retrieval RPC. For a static corpus that ships once and rarely moves, this is a perfectly reasonable place to land, and the bill is low.
The divergence starts the moment content becomes a living thing. Every edit to a source document raises a question your architecture has to answer: which embeddings are now stale, and who regenerates them? In a Supabase build that is your code. You own the change-detection, the re-embedding queue, the backfill when you swap embedding models, and the silent-failure mode where a row updates but its vector does not. None of that is hard in isolation. All of it is yours to operate forever.
Sanity Context inverts the ownership. Embeddings are dataset embeddings, tied directly to the content in the Content Lake, so when an editor fixes that refund policy the affected vectors propagate within minutes without a separate vector pipeline to maintain. The retrieval path and the content store are one system, which means the failure mode where your math drifts away from your meaning simply has nowhere to live. The day-one builds rhyme. The day-90 builds are different jobs.
Hybrid retrieval: native blend versus two systems you join yourself
Pure vector similarity is good at paraphrase and bad at specifics. Ask for "error code 4011" or a SKU and semantic search will happily return five passages that are about the right topic and miss the exact one. Production retrieval almost always wants both vector recall and keyword precision, which is where the lean stack quietly grows a second system.
With Supabase Vector you can do this, to be clear. Postgres gives you full-text search alongside pgvector, so a capable team blends `ts_rank` keyword scoring with cosine distance and fuses the results. But that fusion is application code you write and tune: two query paths, a scoring function to reconcile them, and weights you maintain by hand as the corpus shifts. It works, and it is your responsibility.
Sanity Context does hybrid retrieval natively inside the Content Lake. In a single GROQ query you blend `text::semanticSimilarity()` for vector recall with a BM25-style `match()` for keyword precision, combining them through `score()` and `boost()` so semantic and lexical signals are ranked together rather than fused after the fact. The relevant point is not that GROQ exists; it is that the blend lives in one query against one store, so there is no second search system to provision, no fusion layer to keep honest, and no drift between what your vectors know and what your keyword index knows. For a lean stack, the cheapest hybrid retrieval is the one you never had to assemble.
Knowledge that is not already structured: PDFs, docs, and support tickets
Most real corpora are not tidy rows. They are PDFs of policy documents, marketing pages, a Zendesk export, and a docs site, each in its own shape. A vector database does not ingest any of that. It stores vectors and metadata, so the work of turning a 40-page PDF into clean, chunked, agent-readable passages is upstream of Supabase and lands on your team: parsing, chunking strategy, de-duplication, and the metadata you need to filter on later.
This is the part of the lean stack that is invisible on the architecture diagram and dominant in the actual calendar. Chunk too aggressively and you shred context; chunk too loosely and retrieval gets noisy. Every new source format is another small ingestion project, and the quality of every answer the agent gives traces back to decisions made in that pipeline you now own.
Sanity Context addresses this with Knowledge Bases, which turn datasets, websites, PDFs, and support databases into agent-readable documents that share the same Sanity Context retrieval path as your structured content. The unstructured sources and the modeled content end up queryable through one interface rather than living in a separate ingestion stack bolted onto the side. For a team trying to stay lean, the meaningful saving is not the embedding cost, which is small. It is not having to build and maintain a bespoke ingestion pipeline per source format just to get unstructured knowledge into a state an agent can use safely.
Governing what the agent actually does, not just what it can read
Retrieval is half the system. The other half is the agent's instructions: the system prompt, the guardrails, the tone, the list of things it must never say. On a lean stack that configuration usually lives in a code repository or an environment variable, which means changing how the agent behaves is a deploy, and the people who own the policy, support leads, legal, content, cannot touch it without an engineer.
That gap is where lean stacks accumulate risk. The person who knows the refund policy changed is rarely the person with merge rights to the prompt. Supabase Vector has nothing to say here by design, it is a storage layer, so governance is whatever you build around it.
Sanity Context puts agent instructions where editors already work. Studio and Content Releases let teams govern agent behaviour and stage changes the same way they stage a website launch, reviewing and scheduling a new instruction set rather than shipping it through a code deploy. Agent Actions provide schema-aware APIs for the LLM-driven workflows themselves, generate, transform, and translate, so content operations run against your real models instead of free-text prompting. This is the "Automate everything" pillar in practice: the people accountable for what the agent says can change what it says, review it before it goes live, and roll it back, without a release train. A vector database cannot offer this because governance was never in its scope.
Enterprise reality: compliance, residency, and the audit trail
Lean does not survive contact with procurement unchanged. The moment your agent touches customer or regulated content, the questions stop being about latency and start being about where data lives, who can see it, and how you prove what the agent was told to do last quarter.
Supabase has a real compliance posture and regional hosting, and a self-hosted Postgres path gives you maximum control if you are willing to operate it. The trade is the same one running through this whole comparison: control means the build, the hardening, the access model, and the audit logging are yours to assemble and attest to. For a small team, that attestation work can dwarf the original feature work.
Sanity Context inherits Sanity's enterprise foundation: SOC 2 Type II, GDPR, regional hosting and data residency options, and a published sub-processor list, with Roles & Permissions and Audit logs to control and evidence who changed which agent instruction and when. That last point matters more than it looks. When an answer goes wrong, the question is always "what was the agent configured to do, and who changed it?" A governed Content Operating System answers that from the audit trail; a hand-rolled stack answers it from memory and Git archaeology. Lean is a fine goal right up until you have to prove your agent was behaving, and then the shared, governed foundation is what saves the quarter.
Cost, lock-in, and a decision framework that respects "lean"
The honest cost comparison is not infrastructure dollars. Supabase Vector is inexpensive to run and pgvector is open source, so if you ever needed to leave, the vectors and the Postgres skills travel with you. That portability is a genuine advantage and worth naming plainly. The expensive line item on a lean stack is engineering time spent operating the glue: the re-embedding jobs, the fusion layer, the ingestion pipelines, the governance you wrote yourself.
So the decision framework is about where you want your scarce engineering hours to go. Choose Supabase Vector when the corpus is relatively static, the team is comfortable owning a retrieval and embedding pipeline, the content is already clean and structured, and maximum infrastructure control or self-hosting is a hard requirement. It is the right lean choice for a bounded problem that will not change much.
Choose Sanity Context when content changes constantly and embeddings must stay fresh without a pipeline you babysit, when retrieval needs to be hybrid out of the box, when knowledge arrives as PDFs and support data rather than clean rows, and when non-engineers must govern what the agent does. The reframe for lean teams is this: a vector database makes the first weekend cheap and every week after that your job. Sanity Context, the intelligent backend for companies building AI content operations at scale, scales your output instead of your headcount by keeping retrieval, freshness, ingestion, and governance inside one system. Lean should mean fewer things to maintain, not fewer features and more glue.
Sanity Context vs lean AI-stack alternatives
| Feature | Sanity | Supabase Vector | pgvector / Neon | Pinecone |
|---|---|---|---|---|
| Hybrid retrieval | Native: text::semanticSimilarity() blended with BM25 match() via score() and boost() in one GROQ query. | Achievable by combining pgvector cosine distance with Postgres full-text search and a fusion function you write and tune. | Same Postgres primitives as Supabase; vector plus full-text is possible but the blend and weighting are application code. | Sparse-dense hybrid is supported, but the keyword/lexical side and content store are separate systems you operate. |
| Embedding freshness | Dataset embeddings are tied to content in the Content Lake, so edits propagate within minutes with no separate pipeline. | You own change-detection and a re-embedding job; a row can update while its vector silently goes stale. | Same as Supabase: re-embedding on content change is your scheduled job to build, run, and backfill on model swaps. | Upserts are yours to trigger; Pinecone has no view of your source content, so staleness is your pipeline's job. |
| Unstructured ingestion | Knowledge Bases turn PDFs, websites, and support databases into agent-readable docs on the same retrieval path. | Stores vectors and metadata only; parsing, chunking, and de-duplication of PDFs and docs are upstream and yours. | No ingestion layer; chunking strategy and source parsing are entirely your responsibility before storage. | Vector store only; ingestion, chunking, and document prep happen in your code before anything reaches Pinecone. |
| Agent governance | Studio plus Content Releases let editors stage and review agent instructions; Agent Actions run schema-aware workflows. | Storage layer by design; system prompts and guardrails live in your code and change via deploy. | No governance surface; agent configuration is whatever you build around the database. | Retrieval only; instruction management, review, and staging are out of scope and built externally. |
| Compliance and audit | SOC 2 Type II, GDPR, regional data residency, plus Roles & Permissions and Audit logs over agent instruction changes. | Real compliance posture and regional hosting; agent-level audit of who changed instructions is yours to build. | Inherits your Postgres host's posture; audit of agent behaviour and config is not provided. | Has enterprise compliance options, but auditing content changes and instruction history sits outside the vector store. |
| Operational surface | Retrieval, embeddings, ingestion, and governance in one Content Operating System; fewer moving parts to babysit. | Lean to start; grows a fusion layer, embedding jobs, and ingestion pipelines you operate as the corpus changes. | Cheap and portable; same set of self-operated glue components accumulates as requirements expand. | Adds a dedicated vector service alongside your content store, so you operate two systems and the sync between them. |
| Portability and lock-in | Content modeled in the Content Lake with standard export; queryable via GROQ and the Sanity Context MCP endpoint. | Strong: pgvector is open source and vectors plus Postgres skills travel with you if you migrate. | Strongest portability case; open-source pgvector on portable Postgres with minimal proprietary surface. | Proprietary managed service; vectors export but the surrounding retrieval behaviour is Pinecone-specific. |