An ordinary chatbot makes a modest promise: it will answer from what it absorbed when it was built. A retrieval-augmented generation system — a RAG system — makes a stronger one, and the strength is the point. It says: I will answer from these documents, the ones you chose, and I will show you where each answer came from.

That promise has a name worth learning before any machinery: the retrieval contract. If you cannot state it for a system you are building — which documents it may use, which questions it is for, and what it does when the documents lack the answer — you do not yet have a system. You have a demonstration.

The contract is kept or broken in stages

A RAG system is not one thing. It is a pipeline, and the contract is kept or broken at specific stages, never in general.

First comes the corpus: the set of documents admitted as evidence. Then preparation: those documents cleaned, deduplicated, and cut into passages. Then the index: the passages converted into a form a machine can search quickly, with their source information attached. Then retrieval: a question arrives, the index is searched, and a shortlist of passages comes back, ranked. Then generation: the model reads the question and the shortlist and writes an answer. Finally, presentation: the answer shown with its sources, so a user can check a claim against the passage it rests on.

Six stages. When an answer is wrong, one or two are responsible. The professional skill is finding which — because the fix, and its owner, differ by stage.

The same wrong answer, three different causes

Consider a pilot system asked a precise question: what torque to use on the housing bolts of a particular pump. It answers confidently — with a figure that belongs to a different pump. The symptom is single. The causes are not.

The first possibility is a corpus failure. The manual for that pump was never admitted, and the closest document in the corpus is another model's manual. Retrieval faithfully found the best available evidence, and the best available evidence was wrong for this question.

The second possibility is a retrieval failure. The correct manual is present, but the torque table was cut across two passages during preparation, so neither passage alone looks like a torque answer, and a general passage about bolt care outranks both.

The third possibility is a generation failure. The correct passage was retrieved and ranked first, and the model still blended it with a figure from a second passage about a larger pump.

Three identical-looking failures, three different fixes, three different owners. A team that cannot separate them will fix the wrong stage — usually by changing the model, the one stage that was innocent in two cases out of three.

The clause users remember: the right to refuse

The contract has a second clause, the one users remember longest. When the evidence is not there, the system must say so.

A RAG system that answers every question is a liability, because its silence would have been information and its invention is harm. The refusal — the documents I can search do not cover that — is not a failure to apologize for. It is a designed behavior: retrieval must be able to report weak evidence, and generation must be instructed, and tested, to stop when evidence is weak. Teams that treat refusal as an embarrassment will tune it away, one demonstration at a time, until the system answers everything and can be trusted with nothing.

Scope is what makes the promise believable

A third clause concerns scope: which questions are in and which are out, named before users discover the boundary by accident.

A system scoped to product documentation — specifications, procedures, warranty terms, safety limits — is not scoped to pricing negotiations, personnel matters, or engineering judgment about a novel installation. Those exclusions are not modesty. They are what makes the inclusions believable. When a user asks an out-of-scope question, the correct behavior is a boundary answer that says what the system is for, not a retrieval attempt against documents that were never meant to settle the matter.

Write the scope down, where users can see it. A contract nobody has read protects nobody.

The contract is owed to someone, for something

The contract is also owed to a named user with a named stake. Installers working on ladders and under machines face a different cost from a wrong torque figure than a hobbyist searching a cookbook collection does. The architecture may be the same; the strictness should not be. Before building, answer three questions in writing: Who asks? What will they do with the answer? What does a wrong answer cost them? Those answers set how much evidence an answer needs, how visible its sources must be, and how readily the system must refuse.

One final clause belongs in the contract: name how the system will be judged. Which question set, which measures, whose grading. Without it, every stakeholder grades by anecdote — the loudest user's worst experience becomes the quality report. Settle the yardstick while everyone is calm: a standard question set and a graded sample of answers, reviewed on a schedule, with a single failure triggering investigation, never a verdict by itself.

The common mistake underneath all of this is to believe that bolting a language model onto your documents makes it an expert on them. It does not. The model does the writing; the documents do the knowing, only to the extent the pipeline delivers them. Hand a model no passage about that pump and it will still produce a fluent paragraph about it, drawn from whatever it absorbed long before your documents existed. Treat the model as the component that knows, and you will under-build every stage that determines correctness — then blame the one component that was never the source of truth.

Experience it, don’t just read about it

The promise that an answer comes from chosen documents, with its sources shown and its limits stated, is Concept 1 of RAG & Agentic AI Systems (Course No. 203), from Cognosco Learning, a learning company powered by AI. The course builds the full design of retrieval systems beyond this distinction — Corpus Audit, Grounding, and Citation and Attribution — each worked through with an Agentic Socratic AI coach, one learner at a time. Try a Free Preview at cognoscolearning.com.

Try a Free PreviewAll Signature CoursesThe Corporate License

Navigate your own course.

← All Insights

© 2026 Cognosco Learning. All rights reserved.