Artificial Intelligence

What is AI Hallucination?

AI hallucination is when a model confidently produces information that is false, fabricated, or not grounded in its input.

AI hallucination is when a model — often a large language model — confidently produces information that is false, made up, or not supported by its input. The output sounds plausible and fluent, but it's simply wrong, like a fabricated citation or a nonexistent API.

Why It Happens:

  • LLMs predict likely text, not verified facts
  • They fill gaps with statistically plausible content
  • They lack a built-in source of truth or fact-checker
  • Ambiguous or leading prompts can push them toward invention

Common Examples:

  • Fake citations: Realistic-looking but nonexistent papers
  • Wrong facts: Confident but incorrect dates or numbers
  • Invented APIs: Functions or parameters that don't exist
  • Made-up quotes: Attributing statements no one said

How to Reduce It:

  • Retrieval-augmented generation (RAG): Ground answers in real documents
  • Ask for sources: And verify them independently
  • Lower temperature: Less randomness for factual tasks
  • Human review: Keep a person in the loop for high-stakes output

FAQ

Can hallucinations be fully eliminated?

Not entirely with current technology. You can reduce them significantly with grounding, verification, and careful prompting, but always verify critical facts.

Why does the model sound so confident when it's wrong?

Language models are trained to produce fluent, confident text. Confidence in wording does not reflect confidence in correctness — the two are unrelated.

Promote your content

Reach over 400,000 developers and grow your brand.

Join our developer community

Hang out with over 4,500 developers and share your knowledge.