Skip to content

Hallucination

Abstract

Hallucination — a situation where a neural network confidently outputs false or fabricated information.

Why Does It Happen

The model does not store facts — it predicts the most probable next word. Sometimes, 'most probable' does not mean 'true'. If the model does not know the answer, it may generate plausible lies: non-existent articles, made-up people, incorrect dates.

Examples

  • Fabricated source references
  • Non-existent books and quotes
  • Incorrect formulas that look correct
  • Confident answers to questions not present in the data

How to Combat

  • RAG: provide the model with facts before the answer so that it relies on them. See RAG.
  • Temperature lower: less randomness — less fabrication. See Temperature.
  • Request to admit ignorance: specify in the prompt 'say you don’t know if you don’t know.'
  • Fact-checking: do not trust important answers without verifying against sources.

See Also