AI Agents Evaluation Hallucination

Hallucination Detection Prompt

Catch the confident invention — check an AI output's claims against its source and flag every statement that isn't supported, with the unsupported span quoted.

Overview

The dangerous AI failure isn't being wrong loudly — it's being wrong confidently, with an invented fact that reads exactly like a real one. This prompt audits an output against its source material: it extracts the checkable claims, marks each as supported, contradicted, or unsupported, and quotes the exact span that isn't backed by the source — so hallucinations are caught before a user trusts them.

How to use this resource

  1. Assemble the output and its source

    Gather the AI output you want to check and the source material it should be based on. The audit judges claims only against this source, so include everything the answer was meant to draw from.

  2. Open this resource in AI Output Validator

    Load the prompt into AI Output Validator and paste in the source and the output. The tool runs the check so every claim is classified without copying spans by hand.

  3. Review the classified claims

    Read each claim marked supported, contradicted, or unsupported with its quoted span, focusing on the unsupported claims a user would act on.

  4. Feed the unsupported claims back

    Use the flagged spans to correct the output or tighten the prompt that produced it, then re-run the check to confirm the inventions are gone.

Why This Works

  • Classifying every claim catches the plausible invention, not just obvious errors
  • Quoting the unsupported span makes the finding actionable, not vague
  • Judging only against the source is what separates hallucination from 'sounds right'

Best for

  • RAG systems and summarizers grounded in source text
  • High-stakes outputs where a wrong fact is costly
  • Evaluation pipelines needing a hallucination check

Not for

  • Open-ended generation with no source to check against
  • Grounded-answer verification specifically — use the Groundedness Check Prompt

Use cases

  • Checking a RAG or summary output against its source
  • Catching invented facts before they reach a user
  • Auditing agent answers for unsupported claims

FAQ

How do I use a hallucination detection prompt to check an AI answer?

Paste the SOURCE (the ground truth the answer should be based on) and the AI OUTPUT into the prompt, then run it in your own AI tool. It extracts the output's checkable claims and marks each SUPPORTED, CONTRADICTED, or UNSUPPORTED, so you review the flagged spans instead of re-reading the whole answer. The key rule: it judges only against your source, never against the model's own knowledge.

What should I paste into the hallucination detection prompt?

Two things: the SOURCE material the answer was supposed to be grounded in, and the OUTPUT you want checked. The audit compares one against the other, so without a source there is nothing to verify against — it can only flag claims your source doesn't back, not facts about the world. Include everything the answer was meant to draw from, or supported claims may look unsupported.

What output does the hallucination detection prompt produce?

It returns a list of the output's discrete factual claims, each classified SUPPORTED, CONTRADICTED, or UNSUPPORTED against the source. For every contradicted or unsupported claim it quotes the exact span and notes what the source actually says (or that it is silent), then ranks the unsupported claims a user would act on as high-risk. The result is a triaged list of what isn't backed, not a rewrite.

Does this prompt guarantee the AI answer is accurate?

No — it checks whether each claim is backed by the source you provide, not whether the answer is true in the real world. A claim can be SUPPORTED by a wrong source, or flagged UNSUPPORTED yet still correct, so a clean audit is a grounding signal, not an accuracy guarantee. You run it in your own AI tool, and the final factual review stays with you.

More resources from AI Output Validator

Resources that pair well

Related tools

Projects that use this resource

Workflows that use this resource

Guides for this resource

Tip: Save time by exploring related resources and tools that integrate with this resource.