Research map / Large language models / Language, safety and interpretability
Robust Hallucination Detection in LLMs via Adaptive Token Selection
Read the paperCheck your idea against 108,967 papers
AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.
Proposes HaMI, a multiple-instance-learning detector that adaptively selects the most hallucination-indicative tokens from LLM hidden states jointly with detector training, augmented by uncertainty-enhanced representations.
Problem
Hallucination detection from internal representations usually relies on predetermined tokens (first, last, before-last), which is unstable for free-form generations of varying length with sparse hallucinated entities.
Approach
Formulates hallucination detection as multiple instance learning over token-level hidden states: each response is a bag, top-k scoring tokens are selected end-to-end with a MIL margin loss plus a sequential smoothness loss, and hidden states are scaled by semantic-entropy-based uncertainty.
Key results
- HaMI reaches 0.897 AUROC on TriviaQA with LLaMA-3.1-8B, versus 0.835 for SAPLMA and 0.828 for Semantic Entropy.
- HaMI improves average AUROC over MARS-SE by 8.1% to 11.9% across the three LLMs.
- In cross-dataset generalisation, HaMI outperforms the best competing method SAPLMA by 7% to 9%.
Measured effects reported in the paper
| What was changed | Where | Measured | Effect |
|---|---|---|---|
| Use HaMI's adaptive token selection instead of the first generated token (ablation) | Hallucination detection · Trivia QA and SQuAD; LLaMA-3.1-8B and Mistral | AUROC: average improvement of 6% | Helped |
| Use HaMI's adaptive token selection instead of the last generated token (ablation) | Hallucination detection · Trivia QA and SQuAD; LLaMA-3.1-8B and Mistral | AUROC: average improvement of 2% | Helped |
| Augment original representations with semantic consistency uncertainty (ablation) | HaMI · Trivia QA and SQuAD; LLaMA-3.1-8B and Mistral | AUROC: improvements up to 6.7% | Helped |
| Augment original representations with sentence-level uncertainty (ablation) | HaMI · Trivia QA and SQuAD; LLaMA-3.1-8B and Mistral | AUROC | Helped |
| Augment original representations with token-level uncertainty (ablation) | HaMI · Trivia QA and SQuAD; LLaMA-3.1-8B and Mistral | AUROC | No clear effect |
| Add the smoothness loss to the MIL loss (ablation) | HaMI · Within-dataset and cross-dataset benchmarks | AUROC: 0.7% and 1.1% | Helped |
| Increase uncertainty augmentation strength from 0.0 toward 1.0 (ablation) | HaMI · Four QA benchmarks; LLaMA-3.1-8B | AUROC | Helped |
| Use HaMI instead of the strongest listed baseline | Hallucination detection · Trivia QA, SQuAD, NQ, and BioASQ across three LLMs | AUROC | Helped |
Surprising findings
- Token-level uncertainty (predictive probability) gives only limited gains as a representation enhancer, while semantic consistency gives the largest gains.
Limitations
- Requires access to internal representations, so it is limited to open-source LLMs.
- The uncertainty integration (scaling hidden states by (1 + lambda * uncertainty)) is simple and may not be the best fusion method.
Experimental setup
Datasets: TriviaQA SQuAD Natural Questions BioASQ
Benchmarks: TriviaQA SQuAD Natural Questions BioASQ
Metrics: AUROC
Baselines: p(True) Perplexity Semantic Entropy MARS MARS-SE CCS SAPLMA HaloScope CED LLM-Check
Builds on: Semantic Entropy HaloScope SAPLMA multiple instance learning
Closest papers by meaning
- Scalable Token-Level Hallucination Detection in Large Language Models (NeurIPS 2026 · similarity 0.93)
- LLM-Check: Investigating Detection of Hallucinations in Large Language Models (NeurIPS 2024 · similarity 0.92)
- HaDeMiF: Hallucination Detection and Mitigation in Large Language Models (ICLR 2025 · similarity 0.92)
- Detecting and Mitigating Hallucination in Large Vision Language Models via Fine-Grained AI Feedback (AAAI 2025 · similarity 0.92)
- Sample Transform Cost-Based Training-Free Hallucination Detector for Large Language Models (NeurIPS 2026 · similarity 0.91)
- HaloScope: Harnessing Unlabeled LLM Generations for Hallucination Detection (NeurIPS 2024 · similarity 0.91)
Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.
