FIELD NOTES ·

RAG that doesn't lie to your users

Retrieval is still the default for company knowledge. Most of it hallucinates politely.

rag · forge · evals

RAG that doesn't lie to your users

RAG (retrieval-augmented generation) is still how most companies bolt private knowledge onto an LLM. The failure mode is familiar: beautiful answers that cite nothing real, or cite the wrong PDF chunk with total confidence. Users trust the tone; legal trusts nothing.

The problem is rarely “embeddings aren't good enough.” It is pipeline sloppiness — bad chunks, no keyword fallback, no citation requirement, no eval set — dressed up as an AI product.

Fixes that move the needle

These are not exotic. They are the difference between a demo that impresses a room and a product that survives the first angry Slack thread from someone who knows the doc better than the model.

Pipeline we ship in Forge

Our default RAG stack is boring on purpose:

  1. Ingest with structure preserved — markdown headings, ticket fields, code fences. Metadata: source, last-updated, access tier.
  2. Hybrid retrieval: BM25 or equivalent for exact matches, vector for semantic near-misses, rerank the top-k before context injection.
  3. Prompt contract: answer only from provided sources; quote or link; refuse if sources conflict or are empty.
  4. Log retrieval hits per query so you can debug “why did it cite the 2022 policy?” without guessing.

We skip the vector-db beauty contest unless latency or scale forces it. A well-chunked index on Postgres with pgvector has shipped more than one production workload without a dedicated search vendor.

Evals that catch lying

RAG evals need three checks, not one “sounds right” score:

Run these in CI alongside your prompt evals. A retrieval regression is silent until a customer notices — which is the worst time to find out.

When RAG is the wrong tool

If the truth changes every hour — inventory, pricing, account status — you need tools that fetch live data, not a nightly index job pretending it is current. If the agent needs to act — file a ticket, update a record, send an approval — you need workflows and Embed integration, not a bigger vector DB.

RAG answers “what does our documentation say?” It does not answer “what is true right now?” Know which question you are building for.

← All field notes · Book a strike call →