Introduction
Large Language Models (LLMs) frequently exhibit overconfidence, asserting incorrect facts or flawed logic with high certainty. This behavior poses significant risks in safety-critical domains such as medicine or law. While Chain-of-Thought (CoT) reasoning improves problem-solving capabilities, it often exacerbates overconfidence as models "convince" themselves of incorrect answers through plausible-sounding but erroneous logical steps. This phenomenon creates a false sense of reliability, where the model's internal reasoning path reinforces its commitment to a wrong answer.
Existing Uncertainty Quantification (UQ) methods typically face a trade-off. Prompt-wise methods, such as Self-Consistency, require generating 10 or more different responses to the same prompt to measure agreement, which is computationally slow and expensive. Conversely, response-wise methods look at a single response but often ignore the internal reasoning process, missing the "red flags" hidden in the steps leading to the final answer.
The CoT-UQ Framework
To address these limitations, we introduce CoT-UQ, a novel framework that leverages the model's own reasoning steps to calibrate its confidence. The pipeline consists of four distinct stages designed to extract "logical weight" from the model's inference process.
- Reasoning Extraction: The model generates a step-by-step reasoning path (CoT) followed by a final answer. This provides the raw material for analyzing the model's logic.
- Keywords Extraction: The LLM identifies critical tokens within each reasoning step—such as specific numbers, entities, or logical operators. This step filters out redundant filler text that can act as noise, allowing the UQ mechanism to focus on the most impactful parts of the reasoning.
- Importance Scoring: The model assigns an importance score (on a scale of 1 to 10) to each keyword based on its vital role in reaching the final answer. This ensures that errors in pivotal steps trigger much higher uncertainty than minor linguistic variations or typos in less critical steps.
- Reasoning Enhanced UQ Strategy: This metadata is used to upgrade two standard UQ approaches:
- Aggregated Probabilities (AP): Instead of a simple average of all token probabilities, CoT-UQ calculates an importance-weighted average of keyword probabilities.
- Self-Evaluation (SE): The model is asked to judge its own answer, but it is explicitly prompted to "Consider the reasoning path" or "Focus on the most critical steps" identified in the previous stages.
Experimental Setup and Datasets
The framework was evaluated across five benchmarks spanning two distinct domains to ensure broad applicability:
- Logical Reasoning: HotpotQA and 2WikiMultiHopQA, which require multi-step information retrieval and synthesis.
- Mathematical Reasoning: GSM8K, SVAMP, and ASDiv, which test numerical logic and problem-solving.
Experiments were conducted using the Llama family (Llama 3.1-8B, Llama 2-13B) and Mistral 7B to demonstrate that the method generalizes across different model architectures and sizes.
Key Results and Performance
CoT-UQ demonstrates significant improvements in uncertainty calibration and efficiency compared to traditional baselines.
- Significant AUROC Gains: CoT-UQ outperformed existing UQ methods by an average of 5.9% AUROC. In specific cases, such as the
Probas-minbaseline, the improvement was as high as 16.8%. - Efficiency over Sampling: While high-quality UQ often relies on sampling many answers, CoT-UQ achieves superior results while being roughly 4x faster. It incurs only ~8 seconds of overhead compared to the 30+ seconds required for sampling-based methods.
- Domain-Specific Insights: The researchers found that the optimal strategy depends on the task. For logical tasks, filtering down to just keywords provides the cleanest signal. For mathematical tasks, the model benefits from the full context of the steps (the "ALLSteps" strategy) because mathematical logic is highly sensitive to the structural relationships between all numbers in the sequence.
- Calibration Accuracy: The importance-scoring mechanism successfully "down-weighted" incorrect answers that previously had high confidence scores. For example, in a math problem where a model confused a monthly salary with an annual one, CoT-UQ dropped the confidence from 80% to 10% by identifying the conceptual error in the reasoning path.
Conclusion and Future Work
CoT-UQ provides a robust, efficient method for making LLMs more "honest" about their mistakes by analyzing the internal logic of their responses. By focusing on critical keywords and their relative importance, the framework significantly reduces overconfidence. While the current implementation requires logit access for the Aggregated Probabilities strategy—limiting its use with some closed-source APIs—it offers a powerful tool for open-source model deployment. Future research will explore applying this framework to subjective, open-ended tasks and integrating it with retrieval-augmented generation (RAG) to quantify uncertainty regarding external facts.
Summary updated