Skip to content
AI.info

Research

From Entropy to Calibrated Uncertainty: Training Language Models to Reason About Uncertainty

Overview Research area: Machine learning / natural language processing, specifically uncertainty quantification and calibration for large language models, combined with reinforcement learning post-tra

From Entropy to Calibrated Uncertainty: Training Language Models to Reason About Uncertainty
arXiv
2603.06317
Published
2026-03-06
Authors
Azza Jenane, Nassim Walha, Lukas Kuhn, Florian Buettner

AI summary

Overview

Research area: Machine learning / natural language processing, specifically uncertainty quantification and calibration for large language models, combined with reinforcement learning post-training.

Technical level: Intermediate. The paper assumes familiarity with calibration concepts (Expected Calibration Error, Platt scaling), reinforcement learning for LLMs (GRPO, PPO, LoRA), and entropy-based uncertainty estimation, but explains each in its background section.

One-sentence scope: The paper proposes a three-stage pipeline that post-trains an LLM to verbalize calibrated uncertainty about its own answers, using entropy-based uncertainty scores as calibrated reward targets during reinforcement learning.

What This Paper Is About

LLMs frequently produce confident but incorrect answers, and existing ways of measuring their uncertainty are either computationally expensive (they require sampling many responses at test time) or uncalibrated (their outputs are useful for ranking but do not map to true probabilities). The paper's goal is to train a model once, via reinforcement learning, so that at test time it can simply state an interpretable uncertainty value that is both well-calibrated and cheap to obtain, without any repeated sampling.

Key Contributions

  1. A novel uncertainty calibration reward. The authors introduce a reward that aligns a model's verbalized uncertainty with a state-of-the-art sampling-based entropy measure (von Neumann entropy over response embeddings), while explicitly targeting calibrated probability outputs via Platt scaling.
  2. Ranking quality plus calibration plus efficiency. They show the reward yields verbalized uncertainties with high rank-correlation to the sampling-based measure, inheriting its strong ranking-metric performance while also achieving better calibration and avoiding repeated sampling at inference time.
  3. Direct comparison against a Brier-score reward. They benchmark their reward against the Brier-score-based reward commonly used in prior work and report superior in-distribution and out-of-distribution results.
  4. A parameter-efficient training recipe. They pair GRPO with LoRA adapters and decouple answer generation from uncertainty estimation, so answer quality is unaffected by the calibration objective and adapters can be applied selectively after answers are generated.

Main Findings

  • Best in-domain calibration: On TriviaQA + Natural Questions, the entropy-based method achieves an ECE of 7.2%, compared with 41.99% (Base), 34.17% (Base+CoT), and 15.70% (Brier).
  • Strong in-domain ranking: AUROC reaches 83.36% for the Brier variant and 81.53% for the entropy-based method, versus 51.89% (Base) and 66.18% (Base+CoT). The Brier variant is marginally higher here.
  • Best alignment with calibrated targets: The entropy-based method attains the highest Spearman correlation at 0.67, compared with 0.03 (Base), 0.17 (Base+CoT), and 0.52 (Brier).
  • Best out-of-domain calibration: On GSM8K, the entropy-based method reduces ECE to 3.15%, versus 32.22% (Base), 22.25% (Base+CoT), and 33.28% (Brier). Notably, the Brier variant's OOD ECE (33.28%) is higher than the untrained Base model's.
  • Out-of-domain ranking: AUROC on GSM8K is 66.89% (Brier) and 66.73% (entropy-based), versus 53.79% (Base) and 62.17% (Base+CoT).
  • Generalization without further processing: The trained models transfer to the unseen task (GSM8K) without additional post-processing, which the authors interpret as evidence of a learned uncertainty reasoning behavior.
  • CoT prompting alone is insufficient: Chain-of-thought prompting improves ranking metrics but does not consistently yield well-calibrated uncertainty estimates.

Methodology in Plain English

The approach runs in three stages.

Stage 1: Measure uncertainty by sampling. For each training question, the base model is sampled K times at temperature 1.0. The responses are embedded, a kernel matrix of pairwise similarities is built, and its eigenvalues are used to compute von Neumann entropy. This produces a continuous "semantic dispersion" score, S(x), that captures how varied the model's answers are in representation space — not just whether the answer was right or wrong.

Stage 2: Turn that score into a probability. Because the raw entropy score is not a probability, the authors fit Platt scaling — a logistic transformation σ(As + B) — on held-out data with binary correctness labels (obtained by comparing low-temperature, t = 0.1 answers against ground truth, judged by GPT-4o-mini). The result, u_cal(x) = g(S(x)), estimates the probability the answer is incorrect.

Stage 3: Train the model to predict that value. The model is given the question and a pre-generated answer, and is prompted to produce a short chain-of-thought reflection followed by a scalar uncertainty between 0 and 1. Training uses GRPO with the reward R_entropy = 1 − max(0.05, |u_θ − u_cal|), which rewards the model for matching the calibrated target and floors the penalty so training stays stable. LoRA adapters with rank 16 and scaling factor 32 are used instead of full fine-tuning, and answer generation is kept separate from uncertainty prediction.

Training used 18,000 samples from TriviaQA + NQ with 2,000 held-out evaluation samples, running GRPO for 1,000 update steps with batch size 32, group size 16, and group sampling at temperature 1.5. All experiments ran on a single NVIDIA H200 NVL GPU, with training time between 10 and 14 hours depending on method.

Why This Matters

Impact on research. The paper reframes uncertainty estimation from a test-time sampling problem into a trainable behavior. If a model can be post-trained to emit calibrated probabilities directly, it sidesteps the cost and the calibration gap that plague sampling-based and verbalized-confidence approaches. It also shows that a reward derived from an entropy measure can beat a reward derived from binary correctness alone, which is a meaningful signal for how RL-based uncertainty training should be designed.

Real-world applications:

  • Healthcare, where calibrated confidence supports risk-aware decision-making and appropriate human oversight of model outputs.
  • Finance, where downstream systems need probabilities rather than unranked scores to size risk.
  • Legal decision support, where overconfident wrong answers carry serious consequences.
  • Privacy-sensitive on-device deployment, where smaller models have been shown to produce poorly calibrated confidence — the efficiency argument matters most here since repeated sampling is impractical.

Industry relevance. Inference cost is a first-order constraint in production. A method that removes multi-sample uncertainty estimation at test time while preserving ranking quality and improving calibration is directly relevant to any team deploying LLMs in settings where a model must flag when it is likely wrong.

Future Directions

  • Broaden the model set. The authors state that extending experiments to a broader set of models beyond Qwen2.5-7B-Instruct would yield a more comprehensive assessment.
  • Establish theoretical grounding. The evaluation is purely empirical, and the authors explicitly leave open the question of why the entropy-based reward produces better calibration than the Brier-based one.
  • Understand the calibration/ranking trade-off. The Brier variant achieved a marginally higher in-domain and out-of-domain AUROC while the entropy variant won decisively on ECE and Spearman correlation; the conditions under which each reward type is preferable remain uncharacterized.
  • Test efficiency claims quantitatively. The paper argues inference-time efficiency versus sampling-based methods but does not report a head-to-head latency or compute comparison in the content provided.

Target Audience

Researchers and practitioners working on LLM reliability, hallucination mitigation, and uncertainty quantification will get the most from this paper. It is also relevant to applied machine-learning engineers deploying models in regulated or high-stakes settings who need calibrated confidence signals without paying the cost of repeated sampling, and to those working on reinforcement learning post-training, who may find the reward design itself — a calibrated entropy target rather than a binary correctness signal — the most transferable idea.

Authors’ abstract

Large Language Models (LLMs) that can express interpretable and calibrated uncertainty are crucial in high-stakes domains. While methods to compute uncertainty post-hoc exist, they are often sampling-based and therefore computationally expensive or lack calibration. We propose a three-stage pipeline to post-train LLMs to efficiently infer calibrated uncertainty estimates for their responses. First, we compute fine-grained entropy-based uncertainty scores on the training data, capturing the distributional variability of model outputs in embedding space. Second, these scores are calibrated via Platt scaling, producing reliable and human-interpretable uncertainty signals. Finally, the target LLM is post-trained via reinforcement learning to align its policy with these calibrated signals through a verifiable reward function. Unlike post-hoc uncertainty estimation methods, our approach provides interpretable and computationally efficient uncertainty estimates at test time. Experiments show that models trained with our pipeline achieve better calibration than baselines and generalize to unseen tasks without further processing, suggesting that they learn a robust uncertainty reasoning behavior.

Read the original paper