ArXiv

Grad Detect: Gradient-Based Hallucination Detection in LLMs

Authors
Anand Kamat, Daniel Blake, Brent M. Werness
Categories
cs.LG, cs.AI
arXiv
https://arxiv.org/abs/2606.24790v1
PDF
https://arxiv.org/pdf/2606.24790v1

Brief

Grad Detect is a gradient-based approach that predicts hallucinations by analyzing layer-wise gradients from a single forward-backward pass. Evaluated on several Q&A benchmarks for hallucination detection and abstention prediction, it outperforms confidence- and sampling-based baselines. Layer ablations over 11 models (four families) show the final five layers carry >97% of the discriminative signal.

Why it matters

Grad Detect uses layer-wise gradient patterns from a single forward-backward pass to predict LLM hallucinations, and it outperforms confidence-based and sampling-based baselines on multiple Q&A benchmarks (paper published 2026-06-23 by Anand Kamat, Daniel Blake, Brent M. Werness).

Key details

  • Layer ablation across 11 models from 4 architectural families shows the final five layers concentrate over 97% of the discriminative gradient signal, enabling efficient deployment with minimal performance loss.
  • The method addresses both hallucination detection and model abstention prediction, offering interpretable insights into where and how failures originate; accepted to the 2nd Workshop on Compositional Learning at ICML 2026.
Source evidence

Abstract

Large Language Models (LLMs) have demonstrated remarkable capabilities across diverse tasks, yet they remain prone to generating hallucinations. Detecting these hallucinations is critical for deploying LLMs reliably in high-stakes applications. We present Grad Detect, a gradient-based approach for predicting hallucinations by analyzing layer-wise gradient patterns from a single forward-backward pass during inference. Our method shows that the internal gradient structure of a model carries rich information about the correctness of its output. This information is not accessible through output-level signals alone. We evaluate Grad Detect on several Q&A benchmarks across both hallucination detection and model abstention prediction, where it consistently outperforms confidence-based and sampling-based baselines. Through comprehensive layer ablation studies across all eleven models from four architectural families, we find that the final five layers concentrate over 97% of the discriminative gradient signal, enabling efficient deployment with minimal performance loss. Grad Detect provides a unified framework for predicting multiple dimensions of LLM reliability, offering strong predictive performance alongside interpretable insights into where and how model failures originate.

Comment: Accepted to the 2nd Workshop on Compositional Learning at ICML 2026, Seoul, South Korea. Copyright 2026 by the author(s)
Journal: 2nd Workshop on Compositional Learning: Safety, Interpretability, and Agents, ICML 2026