Hallucination prevention by construction
Guide · AI Visibility · 3 min read · last verified 2026-07-23
The dependable way to prevent hallucination is not better prompting — it is pipeline construction: constrain the AI to reading, extracting, classifying, and scoring real documents; attach the source to every claim at the moment it is written; make "no public evidence found" a legitimate output; and gate publication, with a mechanical check that rejects unsourced statistics outright and independent editorial and commercial review on top. Instructions ask a model to behave. Construction removes the paths misbehavior normally travels.
Why doesn't "tell the model not to hallucinate" work?
Because it manages behavior when the risk lives in artifacts. Prompt instructions plausibly reduce fabrication rates — we label that a hypothesis, since rates vary by model and task and we have not instrumented the comparison — but a reduced rate is still a rate, and one invented number in a report an executive forwards is the whole cost. The engineering stance is the same one applied to security: do not audit intentions, audit what can pass through. A pipeline that joins claims to sources at write time, refuses when evidence is missing, and mechanically gates unsourced statistics leaves fabrication few places to hide — and each remaining place is one a reviewer can inspect.
What does prevention by construction look like?
Each known failure mode gets a structural counter, not a request for better behavior:
| Failure mode | Structural counter in the Magrios pipeline |
|---|---|
| Invented fact | Every claim links to the source page it came from; the AI's role is confined to reading, extracting, classifying, and scoring what was actually collected |
| Answering the unknowable | "No public evidence found" is a first-class output — the report says it plainly instead of guessing |
| Unsourced statistic in published content | A mechanical gate rejects it at publish time; editorial review is added on top, never substituted |
| Fabricated measurement | Model answers are stored verbatim and every score is recomputed from the stored text by pure functions — anyone can re-derive it, no one can invent it |
| Fake precision after failure | A failed run scores null, never zero; error rows are excluded rather than imputed |
The pattern across all five rows: the claim and its evidence are joined at write time and never travel separately. There is no later step where someone re-attaches sources to finished prose, because that step is where honesty quietly becomes formatting. This is the working definition of evidence-first AI, and the joined record is the evidence trail a reviewer walks afterward.
How do you verify a vendor's groundedness claim before paying?
Every vendor now says "grounded" and "source-backed." Three checks separate architecture from adjectives, and all three work from outside:
- Open the evidence before purchase. Ask for a real report — ours are open as samples — pick any specific claim, and follow its link to the source page. If claims are not individually linked, groundedness is an aggregate promise, which is to say a promise.
- Ask what the system outputs when it does not know. Request an example of a refusal — a "no public evidence found" or equivalent in real output. A system that cannot show you one has an architecture that always answers, and an architecture that always answers guesses. Refusals and receipts is the longer argument for why the refusal is the trust signal.
- Ask what a failed run looks like. Errors shown as errors — with the score withheld — indicate a pipeline that would rather report nothing than report fiction.
What does this architecture cost?
Honesty about the trade: gates reject usable-sounding content, and some of it was probably fine. Reports say "no public evidence found" where a competitor's report offers a confident estimate, and in a sales comparison the estimate looks better. Joining every claim to its source is engineering effort that never demos as a feature. Construction also constrains scope — a pipeline that speaks only from collected evidence cannot opine on questions no public evidence answers, so some report sections run shorter than a fluent model would happily make them. We count every one of those missing paragraphs as a hallucination that did not ship.
The return is specific: output an enterprise reviewer can spot-check in minutes, forward without re-verifying, and quote without a disclaimer. For a research product, that is not a nice-to-have property. It is the product.