Inferensys

Glossary

Factual Consistency Metric

A quantitative evaluation score measuring the alignment between a generated summary or output and the source document to detect hallucinations.
AI evaluator reviewing output quality on laptop, comparison metrics visible, casual evaluation session.
HALLUCINATION DETECTION

What is Factual Consistency Metric?

A quantitative evaluation score measuring the alignment between a generated summary or output and the source document to detect hallucinations.

A Factual Consistency Metric is a quantitative evaluation score that measures the degree of semantic alignment between a generated text and its source document to detect hallucinations. It identifies whether an AI model has fabricated, contradicted, or omitted information not supported by the original input, providing a numerical signal of factual reliability.

These metrics typically leverage Natural Language Inference (NLI) or Textual Entailment models to classify each atomic claim in a generated summary as entailed, neutral, or contradicted by the source. Advanced implementations decompose complex outputs into sub-claims and aggregate entailment probabilities into a single consistency score, enabling automated Hallucination Risk Assessment without human evaluation.

Core Evaluation Dimensions

Key Characteristics of Factual Consistency Metrics

Factual consistency metrics are quantitative evaluation scores that measure the alignment between a generated summary or output and the source document to detect hallucinations. These metrics decompose the verification task into distinct, measurable dimensions to provide a granular view of a model's faithfulness.

01

Entailment-Based Scoring

Leverages Natural Language Inference (NLI) models to determine if a generated hypothesis is logically entailed by the source premise. A high score indicates that the output can be strictly inferred from the source.

  • Mechanism: Classifies each atomic claim as 'entailment', 'contradiction', or 'neutral'.
  • Key Metric: The ratio of entailed claims to total claims.
  • Example: A summary stating 'Revenue grew 15%' is checked against a source stating 'Revenue increased by 15% year-over-year'.
ANLI
Adversarial NLI Benchmark
MNLI
Multi-Genre NLI Corpus
02

Question Answering Equivalence

Tests consistency by generating questions from the source text and checking if the model's output can correctly answer them. This verifies that the output preserves the same factual content without distortion.

  • Process: A question-generation model creates queries from the source, and the output must provide matching answers.
  • Advantage: Provides a fine-grained, interpretable score for specific factual overlap.
  • Use Case: Validating that a medical summary retains correct dosage and symptom information from a clinical note.
03

Token-Level Alignment

Measures factual consistency at the most granular level by computing the overlap of key information-bearing tokens between the source and the generated text.

  • Techniques: Uses BERTScore or METEOR with a focus on precision and recall of named entities and numeric values.
  • Limitation: Captures surface-level overlap but may miss semantic equivalence or rephrasing.
  • Application: A fast, initial filter to flag outputs with missing or hallucinated numbers and dates.
04

Knowledge Graph Grounding

Extracts relational triples (subject, predicate, object) from both the source and the output, then compares them for structural consistency.

  • Method: If the source contains (Company, acquired_by, Competitor), the output must not contain (Company, merged_with, Competitor).
  • Strength: Highly robust against paraphrasing and semantic shifts that confuse token-based metrics.
  • Tooling: Often implemented using OpenIE systems and graph matching algorithms.
05

Contradiction Detection

A specialized binary classification task focused exclusively on identifying direct logical conflicts between the source and the generated text.

  • Focus: Detects 'hallucinations' where the output asserts the opposite of the source.
  • Architecture: Fine-tuned sentence-pair classifiers trained on contradiction datasets.
  • Critical Metric: A single detected contradiction can zero out an overall consistency score, as it represents a critical factual failure.
06

Source Attribution Fidelity

Evaluates whether a generated text correctly attributes claims to the right entities and sources mentioned in the original document.

  • Check: Verifies that 'According to the CEO' in the output corresponds to a statement actually made by the CEO in the source.
  • Importance: Prevents 'source hallucination' where a model invents a citation or misattributes a quote.
  • Evaluation: Combines coreference resolution with relation extraction to map attributions accurately.
FACTUAL CONSISTENCY METRIC

Frequently Asked Questions

Explore the core concepts behind measuring and mitigating hallucinations in AI-generated text through quantitative factual consistency evaluation.

A Factual Consistency Metric is a quantitative evaluation score that measures the semantic alignment between a generated text (such as a summary) and its source document to detect hallucinations. It works by decomposing both the source and the generated text into atomic factual claims, then computing an entailment ratio—the proportion of generated claims that are logically supported by the source. Modern implementations use Natural Language Inference (NLI) models fine-tuned on datasets like FEVER and PAWS to classify each claim as entailed, contradicted, or neutral. The final metric is typically expressed as a percentage: a score of 100% indicates perfect factual grounding, while lower scores flag potential hallucinations for human review or automatic regeneration.

COMPARATIVE ANALYSIS

Factual Consistency Metrics vs. Related Evaluation Approaches

How factual consistency metrics differ from adjacent evaluation frameworks in scope, mechanism, and primary use case.

FeatureFactual Consistency MetricNatural Language Inference (NLI)Veracity Prediction

Primary Objective

Measure alignment between generated output and source document

Determine if a hypothesis can be inferred from a premise

Classify a claim as true, false, or mixed based on aggregated evidence

Input Scope

Generated text + single source document

Premise-hypothesis text pair

Claim + multi-source evidence corpus

Core Mechanism

Token-level entailment scoring and semantic overlap analysis

Logical inference classification (entailment, contradiction, neutral)

Evidence aggregation and source reliability weighting

Hallucination Detection

Requires External Knowledge Base

Granularity of Output

Continuous score (0.0–1.0) with token-level attribution

Discrete 3-class label

Discrete veracity label with confidence score

Primary Use Case

Evaluating summarization and RAG output quality

Benchmarking reasoning capabilities of language models

Automated fact-checking of public claims

Typical Benchmark

SummaC, FactCC, AlignScore

MNLI, ANLI, SNLI

FEVER, LIAR, MultiFC

Prasad Kumkar

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.