
An AI hallucination is output that sounds fluent and confident but is wrong or not supported by any source. You cannot remove hallucinations entirely, but you can reduce them sharply by grounding answers in your own documents, constraining the task, using tools for facts and arithmetic, validating outputs, and putting a person in the loop where mistakes are costly.
Key takeaways
- Hallucination means plausible but unsupported output. It is a normal behaviour of language models, not a rare glitch.
- Risk depends on the use case: low for brainstorming, high for facts, numbers, legal, medical, financial and customer commitments.
- No single fix works. Layer several: retrieval with citations, narrow tasks, tools, validation, human review and an option to say "I do not know".
- Test with a fixed set of real and adversarial questions, and re-run it whenever the model, prompt or data changes.
- Monitor in production, capture user feedback and have an incident process ready.
- Be honest with users: show sources, signal uncertainty and never promise that answers are always correct.
What is an AI hallucination?
A language model generates text by predicting what is likely to come next. It is very good at producing language that reads well. It is not a database of verified facts, and it has no built-in sense of when it is guessing.
Hallucinations show up in several forms:
- An invented fact, such as a policy clause, product feature or statistic that does not exist.
- A fabricated source, such as a reference or link that looks real but is not.
- A wrong calculation presented with confidence.
- An answer that ignores the documents you supplied and relies on general knowledge instead.
Why do language models hallucinate?
In plain words, the model is completing a pattern, not looking something up. If your question is vague, if the relevant information was never in its training, or if the prompt invites an answer whatever the evidence, it fills the gap with the most plausible-sounding text. Models also tend to be agreeable: asked a leading question, they often go along with the premise.
Long or cluttered prompts and missing context make this more likely, as does asking for exact figures, dates or names that the model cannot verify.
Which business uses carry the most risk?
Match your safeguards to what a wrong answer would cost.
- Low risk: brainstorming names, drafting a first version of internal text, suggesting alternatives. A human naturally reviews and rewrites.
- Medium risk: summarising documents, drafting customer replies, classifying requests. Errors are caught often but not always.
- High risk: facts and figures, legal or regulatory statements, medical or health guidance, financial advice, and anything that commits the business to a price, refund, deadline or contract term.
For regulated areas, requirements differ by country and sector and change over time, so involve a qualified professional when designing the controls.
What mitigation layers actually work?
Think of defence in depth. Each layer catches some errors the others miss.
Ground answers in your own documents
Retrieval-augmented generation fetches relevant passages from your approved content and asks the model to answer only from them, ideally with citations. This is the most effective single measure for question answering. Our guide to RAG and AI answers from your own documents explains the approach. Remember that retrieval can still fail: if the wrong passage is fetched, the answer can still be wrong.
Constrain the task and the format
Narrow tasks are safer than open ones. Ask for classification into a fixed list, extraction into named fields, or a short answer in a set structure, instead of free-form essays. A constrained output is easier to check automatically.
Allow the model to say it does not know
Instruct it clearly to answer only from the supplied material and to say when the information is not there. Then test that it does so. Abstention is a feature to design and verify, not something you can assume.
Use tools for facts and arithmetic
Do not ask a language model to remember prices, stock levels or account balances, or to do multi-step maths in its head. Let it call a database, an API or a calculator and report the result. Models are good at deciding what to look up, and systems of record are good at being right.
Validate outputs with rules and schemas
Check what comes back before it reaches a user or a downstream system. Does the output match the expected structure? Is the date plausible? Does the quoted order number exist? Does the cited document actually contain the claimed text? Rejected outputs can be retried or sent for human review.
Keep humans in the loop for high-risk cases
Route anything high value, sensitive or low-confidence to a person, showing the sources used. Make the reviewer's job realistic: enough time, enough evidence and real authority to change or reject the answer.
How should you test for hallucinations?
Testing is where most teams cut corners, and where most of the value lies.
- Build a golden test set. Collect real questions from support logs, sales calls and staff, each with an approved correct answer and the source it should come from.
- Add adversarial prompts. Include questions with false premises, questions the documents cannot answer, requests for exact figures and attempts to pressure the system into promises.
- Score more than correctness. Check whether the answer is supported by the cited source, whether it abstains when it should and whether the tone is appropriately cautious.
- Run regression checks. Repeat the whole set whenever the model, prompt, documents or retrieval settings change. A fix in one area often breaks another.
- Review failures by hand and trace each to its cause: retrieval, instructions, missing content or model behaviour.
How do you monitor and respond in production?
A system that passed testing can still drift as documents, products and user behaviour change.
- Log questions, retrieved sources and answers, with privacy controls suited to your data.
- Offer a simple thumbs-up or thumbs-down and a way to report a wrong answer, then review that feedback regularly.
- Sample conversations each week and grade them against your standard.
- Define an incident process: who can switch the feature off or narrow it, how affected customers are contacted and how the fix is tested before relaunch.
For customer-facing assistants, our article on AI chatbots for customer support: what works covers escalation and handover in more detail.
What should the user experience show?
Good design makes limits visible and errors easy to catch.
- Show the sources behind an answer, with links to the original document.
- Use plain wording that signals this is AI-assisted and may contain mistakes.
- Make it easy to reach a human.
- Avoid wording that implies certainty the system does not have.
Do not tell users the system is always accurate or that answers are verified unless a person has verified them.
Which vendor settings help?
Ask your provider what controls exist, and test their effect on your own data rather than trusting defaults. Common ones include lower randomness settings for factual tasks, structured output modes, system-level instructions, content filters and options to restrict the model to supplied context. The settings help, but they do not replace grounding and testing. When buying an AI product, our guide on how to evaluate AI vendors and AI products lists questions to ask about accuracy evidence and controls.
A short worked example
Imagine a training company that adds a chat assistant to answer questions about course terms. In the first version, the model answers from general knowledge and confidently states a refund window that the company does not offer. The team then changes the design: the assistant retrieves the current terms page, answers only from it, quotes the relevant sentence with a link, and replies "I cannot find that in our terms; I will pass you to a person" when nothing relevant is retrieved. Any message mentioning a refund, complaint or legal matter goes straight to staff. They build a test set of real customer questions plus tricky ones, and re-run it every time the terms change. Errors still happen, but they are now visible and traceable.
What mistakes should you avoid?
- Trusting a polished demo, which uses friendly questions and clean data.
- Asking for exact numbers or citations without a tool or source to check them.
- Assuming retrieval always fetches the right passage when it can fetch the wrong one.
- Having no plan for what to do on the day it goes wrong.
FAQ
What causes AI hallucinations?
Language models generate text by predicting likely words, not by looking up verified facts. When information is missing, the question is vague or the prompt pushes for a confident answer, the model fills the gap with plausible text. Poor retrieval and cluttered context make it worse.
Can AI hallucinations be eliminated completely?
Not with current technology. You can reduce them substantially by grounding answers in approved documents, using tools for facts and calculations, validating outputs and adding human review for risky cases. The goal is to make errors rarer, visible and low-impact rather than to promise none.
Does RAG stop hallucinations?
Retrieval helps a great deal because the model answers from supplied sources, but it is not a cure on its own. If the wrong passage is retrieved or the model ignores it, errors still occur. Combine retrieval with citations, instructions to abstain, validation and testing.
How do I test an AI system for hallucinations?
Create a golden set of real questions with approved answers, add tricky and adversarial questions including ones the documents cannot answer, and score both correctness and support from sources. Re-run the set whenever the model, prompt or content changes, and review failures by hand.
Related reading
- RAG Explained: AI Answers Grounded in Your Own Documents
- AI Chatbots for Customer Support: What Works, What Backfires
- AI Ethics, Bias and Fairness: Basics for Business Leaders
Next steps
Choose one AI use case you run or plan to launch and rate its risk as low, medium or high. For anything medium or high, write twenty real questions with correct answers, run them through the system and note every wrong or unsupported reply. That small exercise will show which layer to add first. If you would like help designing grounded, testable AI features, contact us and we will review your use case with you.


