RAG Explained: How a Model Answers From Your Documents

RAG Explained: How a Model Answers From Your Documents

Business Pill 27 · Answering from your own documents

RAG lets a model answer from your own documents without retraining it: look up the right pages first, then hand them to the model with the question.

A short explainer video. The numbers in it are round numbers for illustration.

The Short Answer

A model knows only what it was trained on. It has never seen your contracts, your manuals, or last week’s prices. Ask about them and it either refuses or guesses.

The fix is simple: before the model answers, look up the relevant pages, then hand them to the model together with the question.

Three Steps

First, retrieve: search your documents for the passages closest to the question. Second, augment: add those passages to the request. Third, generate: the model writes its answer using what it was just given.

An Example

An employee asks, how many days of leave do I get for a new child? The system finds the right page of the staff handbook, the model reads it, and answers with the exact number.

That is retrieval-augmented generation, usually shortened to RAG.

Why It Is Popular, and Its Weak Point

It is popular for good reasons. The knowledge stays current, because you update the documents, not the model. The answer can show its sources. And private information stays in your own systems.

But it has one weak point: the answer is only as good as what was retrieved. If the search brings back the wrong page, the model answers confidently from the wrong page.

Three Questions to Ask

  1. Are the right documents in the system?
  2. Does the search find the right passage?
  3. Can we see which source each answer used?

See It in the News

Cloudflare Web Search API Prices $0.25 to $7.00. A news piece on a service that hands live web results to a model before it answers.

TextQL Ontology GA: Context, Not Capability. A news piece on giving a model the context of a business’s own data.

More Business Pills

Business Engineer

The Map of AI

The Business Engineer framework maps where each part of the AI stack sits and who holds the leverage. These pills are short lessons from the same library.

Explore the Map of AI →
Scroll to Top

Discover more from FourWeekMBA

Subscribe now to keep reading and get access to the full archive.

Continue reading

FourWeekMBA