Hallucination

A hallucination is output that is fluent, confident and wrong — an invented citation, a function that does not exist, a statistic with no source. It is not a malfunction bolted onto an otherwise reliable system; it is the same next-token prediction that produces correct answers, applied where the model has no grounding.

Also called: confabulation, making things up · Reviewed

Why does it happen?

A model is trained to produce likely text, not true text, and it has no internal signal separating "I know this" from "this is the shape an answer would take". Asked for a citation, it generates something with the cadence of a real citation: plausible authors, a plausible journal, a plausible year. Fluency is preserved end to end; accuracy is not, because accuracy was never the objective being optimised.

Rare, specific and recent facts are the danger zone. Anything thinly represented in training data — a small company, a niche API, last month's release — is where invention is most likely and hardest to spot.

What actually reduces it?

Grounding beats instruction. Retrieval-augmented generation, where the model answers from documents you supply and cites them, removes most of the guesswork for factual questions. Letting the model call a tool — a search, a database query, a calculator — is the same principle: replace recall with a lookup.

Then verify. Ask for quotes rather than summaries so claims can be checked against the source, keep a human between the model and any irreversible action, and build an eval set from the failures you have actually seen so you can tell whether a change helped.

What do people get wrong?

Believing the problem can be prompted away. "Do not make anything up" and "only answer if you are certain" help at the margin and fail exactly where they are needed most, because a model that could reliably detect its own uncertainty would not have hallucinated in the first place.

The other error is treating confidence as evidence. Tone carries no information about correctness — a fabricated answer reads exactly like a sound one, which is precisely why hallucination is dangerous rather than merely annoying.

Learning this properly is easier with other people.

OneShopAI is where students, developers and founders work through this material together — sessions, builds and people who answer questions.