Token-Guard: Towards Token-Level Hallucination Control via Self-Checking Decoding

Yifan Zhu, Huiqiang Rong, Haoran Luo · 2026

Read Token-Guard: Towards Token-Level Hallucination Control via Self-Checking Decoding by Yifan Zhu, Huiqiang Rong, Haoran Luo (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2601-21969.txt.

Introduction

Yifan Zhu, Huiqiang Rong, and Haoran Luo try to stop language models from hallucinating, one token at a time. Models often generate content that conflicts with their input. Retrieval systems and human-feedback training can reduce the problem, but both are expensive to build and run.

Lighter decoding methods exist, yet they lack explicit control over hallucination. The team's 2026 preprint proposes Token-Guard, a decoding approach where the model checks its own output at the level of individual tokens as it generates. Self-checking during generation could catch fabrications at the moment they appear. Cheap, built-in hallucination control would make models safer to deploy in support, education, and drafting tools.

Catalog record

CREATORYifan Zhu, Huiqiang Rong, Haoran Luo
YEAR2026
COLLECTIONPAPERS
FORMATTXT
FILE SIZE67 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2601-21969

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

Token-Guard: Towards Token-Level Hallucination Control via Self-Checking Decoding Yifan Zhu, Huiqiang Rong, Haoran Luo Abstract Large Language Models (LLMs) often hallucinate, generating content inconsistent with the input. Retrieval-Augmented Generation (RAG) and Reinforcement Learning with Human Feedback (RLHF) can mitigate hallucinations but require resource-intensive retrieval or large-scale fine-tuning. Decoding-based methods are lighter yet lack explicit hallucination control. To address this, we present Token-Guard , a token-level hallucination control method based on self-checking decoding. Token-Guard performs internal verification at each reasoning step to detect hallucinated tokens before they propagate. Candidate fragments are further evaluated in a latent space with explicit hallucination risk scoring, while iterative pruning and regeneration dynamically correct detected errors. Experiments on HALU datasets show Token-Guard substantially reduces hallucinations and improves generation accuracy, offering a scalable, modular solution for reliable LLM outputs. Our code is publicly available 1 1 1 https://github.com/rhq945/Token-Guard . 1 Introduction Figure 1: An illustration of Token-Guard. Large Language Models (LLMs) ( 45 ) have achieved widespread success in natural language processing tasks. However, in knowledge-intensive or proprietary scenarios, they still suffer from the hallucination problem ( 43 ) , generating inaccurate or misleading content. To improve factual consistency, strategies such as RAG ( 19 ; 23 ) and RLHF ( 32 ) have been proposed. These methods alleviate hallucinations but heavily rely on external knowledge retrieval or large-scale fine-tuning, which is resource-intensive. To address this, decoding-based methods have been adopted to further enhance the model’s generation process, improving both quality and output reliability. Existing decoding methods, including Auto-Regressive Chain-of-Thought(CoT) ( 36 ) , Tree-of-Thought ( 41 ) , Guided ( 38 ) , and Predictive Decoding ( 26 ) , share three main characteristics: First, outputs are generated progressively through step-wise reasoning, allowing the model to build multi-step chains of thought. Second, exploratory generation is often adopted, where multiple reasoning paths are expanded in parallel to increase the chance of reaching a correct solution. Finally, intermediate self-evaluation provides feedback at each reasoning step, enabling partial assessment of coherence and consistency before proceeding further. Figure 2: Comparison of F1 scores across HALU benchmarks, illustrating model performance on various tasks and effectiveness in hallucination mitigation. Despite these advances, current decoding methods still face three major challenges in hallucination control: (i) Limited token-level hallucination checking . Most existing decoding methods do not implement an explicit token-level hallucination checking mechanism, relying instead on general representations without self-validation. This may allow token-level errors in reasoning steps to propagate and compound ( 44 ) . (ii) Hallucination risk not explicitly quantified. Traditional probability scoring methods fail to explicitly quantify hallucination risk in the encoded space, leading to undirected token selection and unstable reasoning results ( 42 ) . (iii) Limited dynamic correction capability in iterative and generation stages. Most methods support only single-pass generation or limited iterations, lacking mechanisms for dynamic correction and resource allocation, which undermines output consistency and may incur unnecessary time and computational costs ( 34 ) . To address these challenges, we propose Token-Guard (see Figure 1 ), a token-level hallucination-controlled decoding method. Token-Guard introduces three key innovations: (1) Token-level Hallucination Control. At each reasoning step, we score candidate tokens in the latent space and prune low-confidence tokens, enabling the model to effectively detect and suppress hallucinated tokens, improving factual precision. (2) Segment-level Explicit Hallucination Scoring. We group relevant tokens into candidate fragments and assign hallucination risk scores, guiding more reliable and accurate fragment selection, thus improving relevance. (3) Local Enhancement and Global Iteration. When hallucinations are detected, local fragment regeneration and global iteration strategies are applied to dynamically correct prior fragments. For multi-fragment reasoning paths, these strategies maintain logical consistency while avoiding unnecessary time and computational overhead. We evaluated Token-Guard on multiple standard HALU datasets. Experimental results show that Token-Guard, when integrated with llm, achieves substantial improvements over both conventional decoding-based approaches combined with large models and the base large models themselves. Specifically, Token-Guard demonstrates significant gains in generation accuracy, with relative improvements of up to 16.3% over the strongest baseline, and notable enhancements in output quality, including logical and factual consistency, as illustrated in Figure 2 . 2 Related Work LLM Hallucination Control. LLMs often produce hallucinations—outputs that are factually incorrect or unsupported. Existing approaches address this through RAG ( 19 ; 31 ; 22 ) with domain-specific pipelines ( 20 ) and benchmarks like RAGTruth ( 37 ) , alignment methods including instruction fine-tuning and RLHF ( 6 ; 32 ; 4 ) with multi-modal or interactive extensions ( 12 ; 1 ) , and post-generation detection via uncertainty estimation ( 18 ) or classifiers like HaloScope ( 8 ) . These methods can be computationally intensive or domain-specific, limiting practical use. Decoding and Decoding Methods for Large Language Models. Decoding strategies significantly improve reasoning quality and efficiency. Chain-of-Thought (CoT) enables explicit multi-step reasoning. Methods such as DoLa ( 7 ) and KCTS ( 5 ) introduce different forms of token-level hallucination detection, allowing models to filter unreliable tokens and enhance factual consistency during generation. Phi-Decoding ( 39 ) uses adaptive pruning and foresight sampling to improve computational efficiency and better control hallucinations. Building on multi-level control ( 13 ) and self-reflective decoding ( 16 ) , we introduce Token-Guard, a decoding method designed to provide explicit and robust hallucination reduction throughout the LLM reasoning process. 3 Preliminaries We summarize key concepts and fundamental principles underlying token-level generation, multi-level supervision, and iterative verification processes in modern autoregressive models: (a) Token-Level Auto-Regressive Generation. A sequence of tokens a_{1},\dots,a_{T} is generated autoregressively. Formally, the probability of the entire sequence given input x is defined as: P(a_{1},\dots,a_{T}\mid x)=\prod_{t=1}^{T}P_{\theta}(a_{t}\mid x,a_{<t}), (1) where T is the sequence length, a_{<t}=\{a_{1},\dots,a_{t-1}\} denotes the tokens generated before step t , and P_{\theta} represents the model-assigned conditional probability of a_{t} . (b) Multi-Level Supervision. Token probabilities can be modulated by hierarchical signals: C_{t}=\sum_{l\in\mathcal{L}}w_{l}\,g_{l}(a_{t}\mid x,a_{<t},C_{t-1}), (2) where \mathcal{L} is the set of supervision levels, g_{l} is the control function at level l , w_{l} is its weight, and C_{t-1} is the previous combined score. C_{t} represents a composite guidance score. (c) Iterative Verification. Generated sequences can be refined iteratively: K^{(t+1)}=\begin{cases}K^{(t)},&S(K^{(t)}\mid Q)\geq\tau\\ R(K^{(t)},S(K^{(t)}\mid Q),Q),&S(K^{(t)}\mid Q)<\tau\end{cases} (3) where K^{(t)} is the sequence at iteration t , Q is the input query, S(\cdot\mid Q) is a score measuring correctness or hallucination risk, \tau is the threshold, and R(\cdot) is a refinement function applied to low-scoring sequences to improve accuracy and reduce potential hallucinations. 4 Methodology: Token-Guard In this section, as illustrated in Figure 3 , we introduce Token-Guard, including token-level self-checking initialization, iterative token scoring and local fix, pruning-based candidate selection, global iratation and final response generation to control hallucinations during decoding. 4.1 Prompt Self-Checking Before the Token-Guard pipeline, we use a unified prompting strategy combining a general template with domain-specific constraints. The general prompt enforces reliance on the input and a standardized output format (“Answer:[…]”), while domain-specific prompts add restrictions such as “Yes/No/Maybe” in PubMedQA , financial reporting in FinanceBench , or input-dependent answers in History , CovidQA , and RagTruth . Full details are provided in the Appendix A.1 . Figure 3: Overview of the Token-Guard framework: an iterative token-level decoding trajectory with self-checking, hallucination scoring, local fix, and pruning to ensure reliable output. 4.2 Token-Level

Read the complete text