This prompt is for audit, compliance, and AI engineering teams who need to verify that every factual claim in a generated text is directly supported by a specific source passage. The primary job-to-be-done is traceability at scale: you have a model-generated output (an answer, a summary, a report) and a set of source documents, and you need to prove that the output is grounded. The ideal user is a developer or QA engineer integrating this verification step into a CI/CD pipeline for a RAG application, a compliance officer reviewing AI-generated audit evidence, or a product manager defining acceptance criteria for a cited-answer feature. The required context includes the full generated text, the complete set of retrieved or provided source passages, and a defined alignment tolerance for your use case.
Prompt
Source-to-Claim Alignment Verification Prompt

When to Use This Prompt
Define the job, reader, and constraints for the Source-to-Claim Alignment Verification Prompt.
Do not use this prompt when you need a quick, probabilistic hallucination score without passage-level traceability. This prompt performs fine-grained claim decomposition and source mapping, which is computationally and token-intensive. It is overkill for real-time chat moderation or low-risk content generation where a simpler LLM-as-judge eval will suffice. It is also not a substitute for a retrieval step; it verifies alignment between claims and already-provided sources. If your sources are missing or irrelevant, use a retrieval expansion or evidence gap identification prompt first. For regulated industries, the output of this prompt is a decision-support artifact, not a compliance certification—human review of misaligned or stretched claims is mandatory before any filing or submission.
Before using this prompt, ensure you have a clear definition of what constitutes an 'aligned' versus 'stretched' versus 'misaligned' claim for your domain. A financial audit team might require exact figure matching, while a market intelligence brief might accept paraphrased summaries as aligned. Define your alignment distance scoring thresholds upfront. After running this prompt, route high-distance or misaligned claims to a human review queue and use the output to trigger a regeneration or correction workflow. Never silently discard alignment failures in production.
Use Case Fit
Where the Source-to-Claim Alignment Verification Prompt works and where it introduces risk. Use this to decide if the prompt fits your workflow before integrating it into a production harness.
Good Fit: Audit and Compliance Workflows
Use when: you need to produce an auditable record mapping every factual claim to a specific source passage. Guardrail: pair the alignment output with a human review step before it becomes part of a compliance submission.
Good Fit: Pre-Publication Fact-Checking
Use when: generated content must be verified against a known document corpus before release. Guardrail: set an alignment distance threshold and flag any claim that exceeds it for manual correction.
Bad Fit: Real-Time Chat Without Source Context
Avoid when: the model is responding in a conversational setting with no retrieval step or source documents loaded. Guardrail: this prompt requires explicit evidence passages; without them, it will flag every claim as unsupported.
Bad Fit: Creative or Opinion-Based Generation
Avoid when: the output is subjective analysis, strategic opinion, or creative synthesis where strict source mapping is not expected. Guardrail: use a separate classification step to route creative tasks away from alignment verification.
Required Inputs
What you must provide: the generated text to verify, a set of source passages with identifiers, and an alignment distance threshold. Guardrail: validate that source passages are complete and correctly chunked before running verification; truncated sources produce false misalignment flags.
Operational Risk: False Positives on Paraphrased Claims
Risk: the alignment scorer may flag legitimate paraphrases as misaligned if the distance metric is too strict. Guardrail: calibrate the alignment distance threshold on a labeled dataset of acceptable paraphrases before deploying to production.
Copy-Ready Prompt Template
A reusable prompt that maps each factual claim to its supporting source passage and flags misaligned or stretched attributions.
The following prompt template is designed to be dropped into an audit or compliance harness. It takes a generated text block and a set of source passages, then produces a structured alignment report. Every factual assertion in the generated text must be traced to at least one source passage. Claims that cannot be mapped, or that stretch the source beyond what it supports, are flagged with an alignment distance score. This prompt is not a general-purpose fact-checker; it assumes the source passages are authoritative and complete for the domain.
textYou are an evidence-audit assistant. Your task is to verify that every factual claim in the [GENERATED_TEXT] is supported by the provided [SOURCE_PASSAGES]. You must produce a structured alignment report. ## INPUTS - GENERATED_TEXT: [GENERATED_TEXT] - SOURCE_PASSAGES: [SOURCE_PASSAGES] - ALIGNMENT_THRESHOLD: [ALIGNMENT_THRESHOLD] ## INSTRUCTIONS 1. Extract every discrete factual claim from [GENERATED_TEXT]. A factual claim is a statement that can be verified against a source. Ignore opinions, stylistic language, and transitional phrases. 2. For each claim, search [SOURCE_PASSAGES] for the best supporting passage. A supporting passage must contain the same factual content, not merely related topics. 3. Assign an alignment score from 0 to 100 for each claim-source pair: - 100: Verbatim or near-verbatim match. - 75-99: Strong support with minor rephrasing. - 50-74: Partial support; the source implies but does not state the claim. - 25-49: Weak support; the source is topically related but does not confirm the claim. - 0-24: No support; the claim cannot be found in any source. 4. Flag any claim with a score below [ALIGNMENT_THRESHOLD] as MISALIGNED. 5. Flag any claim that combines information from multiple sources in a way that creates a new assertion not present in any single source as STRETCHED. 6. If a claim has no supporting passage, set the source to "NONE" and the score to 0. ## OUTPUT SCHEMA Return a JSON object with the following structure: { "claims": [ { "claim_id": "string", "claim_text": "string", "best_source_id": "string | null", "best_source_text": "string | null", "alignment_score": number, "flag": "ALIGNED | MISALIGNED | STRETCHED", "explanation": "string" } ], "summary": { "total_claims": number, "aligned_claims": number, "misaligned_claims": number, "stretched_claims": number, "average_alignment_score": number } } ## CONSTRAINTS - Do not invent source passages. If a claim cannot be matched, set best_source_id to null and flag as MISALIGNED. - Do not skip claims. Every factual assertion in [GENERATED_TEXT] must appear in the output. - If [GENERATED_TEXT] contains no factual claims, return an empty claims array with a summary noting zero claims. - Preserve the exact text of claims and source passages. Do not paraphrase in the output fields.
To adapt this template, replace the square-bracket placeholders with your application's inputs. [GENERATED_TEXT] should be the model output under audit. [SOURCE_PASSAGES] should be a JSON array of objects, each with an id and text field, representing the retrieval corpus or document set. [ALIGNMENT_THRESHOLD] is an integer between 0 and 100 that defines the cutoff for flagging a claim as misaligned; start with 50 for initial testing and adjust based on your tolerance for partial matches. The output schema is strict JSON, which means your application harness should validate the structure before accepting the result. If the model returns malformed JSON, use a schema repair prompt from the Output Repair and Validation Prompts pillar rather than retrying this prompt blindly.
Prompt Variables
Required inputs for the Source-to-Claim Alignment Verification Prompt. Each variable must be populated before the prompt is assembled and sent. Validation notes describe how to check the input at the harness level before the model call.
| Placeholder | Purpose | Example | Validation Notes |
|---|---|---|---|
[GENERATED_TEXT] | The full model output containing factual claims to verify against sources | The new privacy regulation requires opt-in consent for all data collection activities starting next quarter. | Must be a non-empty string. Check length > 0. If the text contains no factual assertions, the prompt should return an empty claim list rather than hallucinate claims. |
[SOURCE_PASSAGES] | The retrieved or provided evidence documents to align claims against | [{"source_id": "doc-42", "passage": "Section 4.2 requires explicit opt-in consent before any personal data collection.", "metadata": {"page": 12}}] | Must be a valid JSON array with at least one object containing source_id and passage fields. Validate schema before prompt assembly. Empty array triggers evidence insufficiency path. |
[ALIGNMENT_THRESHOLD] | The minimum alignment distance score below which a claim-to-source mapping is flagged for review | 0.7 | Must be a float between 0.0 and 1.0. Values below 0.5 produce excessive flags; values above 0.9 may miss stretched attributions. Default 0.7 if not specified. |
[CLAIM_EXTRACTION_MODE] | Controls whether the prompt extracts all claims or only verifiable factual claims | factual_only | Must be one of: all_claims, factual_only, named_entity_claims. Invalid values should cause harness to reject the request before model call. factual_only is recommended for audit workflows. |
[OUTPUT_SCHEMA] | The expected JSON structure for the alignment output | {"claims": [{"claim_text": "...", "mapped_source_id": "...", "alignment_score": 0.92, "alignment_status": "aligned"}]} | Must be a valid JSON Schema or example structure. Harness should validate that the schema includes required fields: claim_text, mapped_source_id, alignment_score, alignment_status. Missing fields cause post-processing failures. |
[MAX_CLAIMS] | Upper bound on the number of claims to extract and align | 50 | Must be a positive integer. Set based on expected output length. Exceeding this value should trigger truncation with a warning. Prevents runaway processing on very long generated texts. |
[ABSTENTION_POLICY] | Instruction for handling claims that cannot be mapped to any source | flag_and_continue | Must be one of: flag_and_continue, remove_claim, halt_and_escalate. flag_and_continue preserves output for human review. halt_and_escalate is appropriate for compliance-critical workflows requiring immediate intervention. |
Common Failure Modes
Source-to-claim alignment verification is brittle in production. These are the most common failure modes that break alignment pipelines, along with practical guardrails to catch them before they reach users or auditors.
Claim Extraction Misses Compound Assertions
What to watch: The model extracts simple atomic claims but misses compound assertions where two facts are fused into one sentence. A sentence like 'The system processed 1.2M transactions with 99.9% uptime in Q3' contains two distinct claims, but extraction often captures only one. Guardrail: Use a two-pass approach—first extract all sentences with factual content, then decompose each sentence into atomic claims. Validate that every numeric or categorical assertion in the source sentence appears in at least one extracted claim.
Alignment Distance Scoring Produces False Positives
What to watch: Semantic similarity metrics flag claims as misaligned when the source passage uses different terminology but conveys the same fact. A claim stating 'revenue grew 14%' mapped to a source saying 'top-line increased by 14%' may score as misaligned due to vocabulary mismatch. Guardrail: Implement a two-tier alignment check—first use exact match or near-exact match for numeric values and entities, then apply semantic similarity only for qualitative claims. Set separate thresholds for numeric alignment versus semantic alignment, and flag borderline cases for human review rather than auto-rejecting.
Stretched Attributions Pass Alignment Checks
What to watch: The model maps a claim to a source passage that is tangentially related but does not actually support the claim. A claim that 'customers reported 40% faster onboarding' gets mapped to a source discussing general customer satisfaction improvements without specific onboarding metrics. Guardrail: Require the alignment step to extract and compare the specific evidence fragment from the source that directly supports the claim, not just the passage topic. Add a 'direct evidence required' constraint that rejects mappings where the supporting sentence does not contain the claim's key entities or values.
Source Chunk Boundaries Fragment Evidence
What to watch: Retrieved source chunks cut evidence mid-sentence or split related facts across chunk boundaries. A claim depends on a table and its caption, but the chunker separates them. The alignment step then marks the claim as unsupported because no single chunk contains the complete evidence. Guardrail: Implement overlapping chunk windows with metadata that preserves document structure. Before flagging a claim as unsupported, check adjacent chunks for complementary evidence. Add a chunk-boundary awareness flag to alignment outputs so downstream systems know when evidence may be fragmented.
Alignment Scoring Normalizes Away Critical Differences
What to watch: Alignment scores aggregate multiple dimensions into a single number, masking specific failure types. A claim with perfect entity alignment but incorrect temporal attribution (Q2 vs Q3) may still score above threshold because entity matching dominates the score. Guardrail: Decompose alignment scoring into independent dimensions—entity alignment, numeric alignment, temporal alignment, and qualifier alignment—and set per-dimension thresholds. A claim must pass all dimension checks, not just the aggregate score. Surface dimension-level failures explicitly in the output.
Negative Claims Lack Source Grounding Strategy
What to watch: Claims that assert the absence of something—'no security incidents were reported' or 'the system did not experience downtime'—cannot be directly mapped to a source passage stating the absence. The alignment step either fabricates a mapping or incorrectly flags the claim as unsupported. Guardrail: Define explicit handling rules for negative claims. Require the source to contain either an explicit statement of absence or a complete enumeration that implies absence. If neither exists, flag the claim as 'unverifiable from provided sources' rather than 'misaligned,' and require the generating system to either cite the absence statement or qualify the claim with temporal and scope boundaries.
Evaluation Rubric
Use this rubric to test the Source-to-Claim Alignment Verification Prompt before shipping. Each criterion targets a specific failure mode in claim extraction, source mapping, or alignment scoring.
| Criterion | Pass Standard | Failure Signal | Test Method |
|---|---|---|---|
Claim Extraction Completeness | All discrete factual assertions in [GENERATED_TEXT] are extracted as separate claims with no omissions | A verifiable fact in the input text is missing from the claims list | Count claims manually in 5 test samples; compare against extracted claim count |
Source Passage Mapping Coverage | Every extracted claim maps to at least one [SOURCE_PASSAGE] with a non-null passage_id | A claim returns null passage_id or an empty source_mapping array | Parse output JSON; assert claim_mappings[].passage_id is not null for all claims |
Alignment Distance Score Validity | Each alignment score is a float between 0.0 and 1.0 with a non-null rationale string | Score is outside 0.0-1.0 range, null, or missing rationale | Schema validation: check score type, range, and rationale presence for all mappings |
Misalignment Flag Accuracy | Claims with alignment_score < [THRESHOLD] are flagged as misaligned; claims above threshold are not flagged | A clearly unsupported claim is not flagged, or a well-supported claim is incorrectly flagged | Use 10 pre-labeled claim-source pairs with known alignment; measure precision and recall of flagging |
Stretched Attribution Detection | Claims that add interpretation beyond source text receive alignment_score < 0.5 and a stretched_attribution warning | A claim that extrapolates beyond source evidence scores above 0.7 | Test with 5 known stretched-attribution examples; verify score and warning presence |
Output Schema Compliance | Output matches [OUTPUT_SCHEMA] exactly: all required fields present, no extra fields, correct types | JSON parse error, missing required field, or type mismatch in any field | Validate output against JSON Schema; run on 20 varied inputs and check for schema violations |
Abstention for Unmappable Claims | Claims with no supporting source passage produce alignment_score 0.0, misaligned true, and a clear unmappable explanation | Unmappable claim receives a non-zero score or is silently dropped from output | Include 3 inputs with claims unsupported by provided sources; verify unmappable handling |
Multi-Source Claim Resolution | Claims supported by multiple passages list all supporting passage_ids with individual alignment scores | Only one passage is cited when multiple sources provide relevant support | Test with overlapping source passages; verify all supporting passage_ids appear in mapping |
Implementation Harness Notes
How to wire the Source-to-Claim Alignment Verification Prompt into an audit or compliance application harness.
The Source-to-Claim Alignment Verification Prompt is not a standalone chat instruction; it is a verification node inside a larger evidence-grounding pipeline. The harness must supply the generated text and the full set of retrieved source passages as structured inputs, then parse the model's alignment report into a machine-readable schema. This prompt is designed for post-generation audit, meaning it runs after an answer or document has been produced, not during initial generation. The harness should treat this as a synchronous verification step with a strict output contract: every factual claim must be mapped to a source passage, and any unmapped or low-alignment claim must be flagged for human review before the output reaches an end user or compliance record.
Wire the prompt into an application by first extracting discrete claims from the generated text using a lightweight claim-splitting preprocessor or by instructing the model to perform extraction and mapping in a single pass. The harness should validate the JSON output against a schema that requires claim_text, source_passage_id, alignment_score, and flag fields for each claim. Implement a retry wrapper: if the model returns malformed JSON, missing required fields, or an alignment score array that does not match the claim count, re-invoke the prompt once with the validation error message appended to the [CONSTRAINTS] block. After two failed retries, escalate the entire output for human review rather than looping indefinitely. For high-stakes compliance workflows, log every alignment report—including scores, flags, and the raw prompt—to an immutable audit store so that reviewers can trace why a claim was marked as stretched or unsupported.
Model choice matters here. Use a model with strong instruction-following and structured output capabilities, such as GPT-4o or Claude 3.5 Sonnet, and set the temperature to 0 or near-zero to maximize deterministic alignment scoring. If your application already uses a RAG pipeline, pass the same retrieved chunks that were used during generation as the [SOURCE_PASSAGES] input; do not re-retrieve or expand the context during verification, as that would invalidate the alignment comparison. The alignment distance scoring should be treated as a signal for review prioritization, not as an absolute truth. Set a threshold—such as alignment_score < 0.7—that triggers mandatory human review, and configure the harness to route flagged claims into a review queue with the source passage and generated text side by side. Avoid using this prompt on streaming or real-time outputs without buffering the full generated text first; partial claims produce unreliable alignment maps.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Adapt This Prompt
How to adapt
Start with the base prompt and a small set of 3-5 source-claim pairs. Remove alignment distance scoring and use a simpler binary match/mismatch output. Accept plain-text output instead of structured JSON.
codeFor each claim in [CLAIMS_LIST], indicate whether it is SUPPORTED or UNSUPPORTED by [SOURCE_TEXT].
Watch for
- Overly generous alignment on vague claims
- No distinction between direct support and loose implication
- Missing edge cases where a claim is partially supported

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us