2084AI Security Observatory

NewspeakAI Security2084-A-0015

Hallucination: when AI states false things with confidence

An AI hallucination is false or invented content delivered as if it were fact: a court case that never existed, a package nobody published, a citation to nothing. In security, the risk lies in what people and systems do with it.

An AI hallucination (幻觉) is output from a generative AI system that is false or invented but presented with confidence. NIST's generative AI risk profile uses the term "confabulation" and defines it as "confidently stated but erroneous or false content", noting that "hallucinations" and "fabrications" are the colloquial names (NIST AI 600-1). In security work the concern is not that a model is sometimes wrong, but that its errors look exactly like its correct answers: invented software packages, made-up facts, citations to documents that do not exist.

How it happens

NIST explains that confabulation is a natural result of how generative models work. They produce outputs that approximate the statistical patterns of their training data, predicting the next word, which can yield fluent text that is factually wrong or internally inconsistent. NIST adds that models may also produce confabulated reasoning or citations to justify an answer, which can make people trust it more than they should. The risk grows when users act on the output without checking it, or when the output is fed straight into another system.

Documented cases

In Mata v. Avianca, a lawsuit against the airline in federal court in New York, lawyers filed a brief on 1 March 2023 that cited judicial opinions which did not exist. Judge P. Kevin Castel found that the "non-existent judicial opinions with fake quotes and citations" had been created by ChatGPT, and that the lawyers kept standing by them after the court questioned their existence. On 22 June 2023 he imposed a US$5,000 penalty, writing that existing rules impose a "gatekeeping role" on attorneys to ensure their filings are accurate (Opinion and Order on Sanctions).

Hallucination also reaches the software supply chain. A study of 16 code-generating models found that at least 5.2% of packages recommended by commercial models, and 21.7% of those from open-source models, did not exist (Spracklen et al.). Anyone who registers one of those names can get their code installed by developers who trust the suggestion, an attack known as slopsquatting.

How to defend against it

OWASP treats this under LLM09, misinformation, and notes that over-reliance, trusting output without checking it, makes the damage worse (OWASP). Its recommendations, and the lessons of the cases above, come down to:

  • Treat AI output as a draft. Check citations, cases, statistics, package names and vulnerability identifiers against the original source before use.
  • Ground tools in trusted documents, for example through retrieval-augmented generation, and add automatic validation for high-stakes outputs.
  • Tell users clearly what the system can get wrong and label AI-generated content.
  • Keep a named person responsible for anything AI-assisted that reaches a court, a customer or a production system.

Mitigation

Treat AI output as a draft that needs checking, not as a source. Verify every citation, case, statistic, package name and vulnerability identifier against the original before it is used. Ground AI tools in trusted documents where possible and add automatic checks for high-stakes outputs. Tell users plainly what the tool can get wrong. Keep a named person accountable for anything AI-assisted that goes to a court, a customer or production.

References

  1. United StatesNational Institute of Standards and Technology · Artificial Intelligence Risk Management Framework: Generative Artificial Intelligence Profile (NIST AI 600-1) Official & standards · Accessed 2026-11-21
  2. US District Court for the Southern District of New York (via CourtListener RECAP) · Mata v. Avianca, Inc., No. 22-cv-1461 (PKC), Opinion and Order on Sanctions, ECF 54 (S.D.N.Y.) Official & standards · Accessed 2026-11-21
  3. Spracklen et al. (arXiv) · We Have a Package for You! A Comprehensive Analysis of Package Hallucinations by Code Generating LLMs (arXiv:2406.10279, USENIX Security 2025) AI security source · Accessed 2026-11-21
  4. OWASP Gen AI Security Project · LLM09:2025 Misinformation Official & standards · Accessed 2026-11-21

Disclosure

Written by Anthropic's Claude. Anthropic develops large language models, which can produce the kind of false output this entry describes. The entry does not assess any individual model.