Latent Refinement Decoding: Enhancing Diffusion Language Models by Refining Belief States

Qinglin Zhu, Yizhen Yao, Runcong Zhao, Yanzheng Xiang, Siya Qi, Amrutha Saseendran, Chen Jin, Philip Alexander Teare, Bin Liang, Yulan He, Lin GuiNeurIPS 2026

TL;DR

Diffusion language models promise fast, parallel text generation, yet they suffer from "amnesia" at every step—locking in confident words while wiping all uncertain positions back to blank masks. Latent Refinement Decoding (LRD) cures this by letting the model "think latently" using soft blends of predicted token embeddings before committing to final words. Without any retraining, this simple shift boosts reasoning and coding accuracy while accelerating inference by up to 18.4× when paired with existing speedups.

What Problem Does This Paper Address?

Standard autoregressive models (like GPT) generate text one token at a time—a sequential bottleneck that makes long outputs slow. Diffusion large language models (dLLMs), like LLaDA and Dream, break this bottleneck by starting with a sequence of blank [MASK] tokens and refining all of them in parallel over multiple steps.

However, standard dLLMs rely on hard assignment. At each step, the model predicts a probability distribution of words for every blank spot, permanently locks in the most confident ones, and resets every other uncertain spot back to a generic [MASK] token.

This creates two headaches:

  1. Information Loss: All the nuanced "hunches" (probability distributions) the model just calculated for uncertain positions are thrown in the trash. Self-attention can't share partial clues across positions in the next step.
  2. Brittle Commitment: Locking in tokens aggressively risks propagating early mistakes, while being conservative wastes compute on fixed iteration budgets—even for easy prompts.

Methods

The authors introduce Latent Refinement Decoding (LRD), a training-free, two-stage decoding framework that operates in continuous embedding space before settling into discrete words.

Figure 1: Comparison between the existing decoding strategy and the proposed method. Different colours represent distinct tokens, while gradient colours indicate predicted token representations. Top: In the existing strategy, all [MASK] tokens share the same embedding and are repeatedly remasked if not selected. Bottom: In LRD, Phase 1 refines each [MASK] embedding, and Phase 2 progressively commits confident tokens while keeping uncertain ones soft for context-aware decoding.

Instead of resetting uncertain positions to pure [MASK] embeddings, LRD uses Soft Diffusion. For any undecided position, it creates a "mixed embedding"—a weighted blend of the [MASK] vector and the expected embeddings of the top-$p$ predicted tokens. The blend is governed by prediction entropy (uncertainty) and capped by a maximum mixing ratio ($r_f$): high uncertainty stays mostly mask-like; high confidence leans toward the predicted words.

LRD orchestrates this across two phases, monitored via the KL-divergence (how much predictions change) between consecutive steps:

  • Phase 1: Latent Refinement: No discrete words are locked in. Every position updates its soft mixture in parallel, allowing the model to establish a globally coherent "belief state" across the whole sequence. Once step-to-step KL-divergence drops below a threshold, it transitions to Phase 2.
  • Phase 2: Predictive Feedback Loop: Confident tokens are progressively finalized into hard words (one by one, or in batches), while uncommitted spots keep their rich, mixed embeddings as context for the next step. When KL-divergence flattens out again, early stopping kicks in, finishing generation early rather than burning through a fixed step count.

Datasets

Because LRD is strictly an inference-time method, no training datasets are used. Evaluation spans:

  • Code Generation: HumanEval and MBPP.
  • Math Reasoning: GSM8K and MATH500.
  • General Language & QA (in appendices): RACE, CNN/DailyMail, NQ-Open, TruthfulQA, GPQA, and BBH.

No new benchmarks are introduced.

Key Insights and Ideas

  • Never Go Full Token (in the Soft Phase): You might assume that if a model is super confident during soft refinement, you should let the [MASK] embedding vanish completely ($r_f = 1.0$). Surprisingly, this causes accuracy to collapse! Keeping a strong anchor to the [MASK] token (an intermediate cap around $r_f \approx 0.1 - 0.3$) keeps the embeddings inside a locally stable mathematical region that the frozen transformer knows how to handle.
Figure 3: Accuracy of Dream-Ins on four bench- marks under different maximum token propor- tions, where rf = 0 corresponds to no mixing.
  • Genuine Beliefs Beat Random Jitter: Could soft embeddings just be acting like helpful random noise that shakes the model out of bad local optima? An ablation replacing LRD's predictive mixtures with comparable Gaussian noise tanked HumanEval accuracy from 56.1% to 47.0%, whereas LRD boosted it to 60.9%. Sharing actual token-level probabilities across self-attention is doing the heavy lifting.
  • Global Consensus Happens Fast: Phase 1 doesn't drag out latency—on HumanEval, nearly 69% of prompts stabilize by step 2, and over 85% by step 3.

Key Results

Tested on frozen models like Dream-7B and LLaDA-8B across sequence lengths of 256 and 512, LRD improves both quality and speed simultaneously:

  • Accuracy Gains: Standalone LRD beats standard entropy-minimization decoding across the board, delivering up to +6.3 points on HumanEval, +2.6 on MBPP (up to +3.1 on LLaDA-Ins), +2.9 on GSM8K (+3.2 on LLaDA-Ins), and +3.8 on MATH500.
  • Standalone Speedups: Thanks to KL-guided early stopping, standalone LRD accelerates generation up to 10.6× overall (and cuts Dream-Instruct's HumanEval runtime from 41.8s down to 14.4s despite a slight per-step compute overhead).
  • Drop-in Composability: LRD plugs cleanly into multi-token andKV-caching accelerators. Pairing Fast-dLLM + LRD reaches 15.2× speedup on Dream-Base and 18.4× on LLaDA-Ins (GSM8K, length 512) while recovering and surpassing the accuracy normally lost to aggressive parallel decoding.

Limitations and Future Work

  • Where the Speedup Actually Comes From: Soft mixing actually adds a tiny per-step latency overhead (e.g., 81.8 ms to 94.3 ms). The authors candidly note that headline speedups in large generation windows mainly stem from sequence-level early stopping (avoiding wasted steps after an answer is done)—when normalized strictly by content length without early stopping, speedups are a much more modest 1.06×–1.21×.
  • Theoretical Bounds Have Scope Limits: Their mathematical stability guarantees apply to continuous soft updates while holding committed tokens fixed; massive simultaneous batches of hard-token commitments can still jolt self-attention dynamics.
  • The Bigger Picture: While LRD makes diffusion LLMs substantially better and faster, the broader head-to-head battle between diffusion and classic autoregressive models remains an open question for future work.

Summary updated

Abstract

Autoregressive (AR) models remain the dominant paradigm for natural language generation, but their strictly sequential decoding process leads to high inference latency. Recent diffusion-inspired language models, such as LLaDA and Dream, alleviate this issue through parallel generation, yet they still face two key limitations: information loss, since predictive distributions over non-finalised tokens are discarded at each step, and unstable commitment dynamics, where local token decisions are not sufficiently coordinated at the global level. We propose Latent Refinement Decoding (LRD), a two-stage decoding framework consisting of Latent Refinement and a Predictive Feedback Loop. In the first stage, LRD keeps masked positions as distributional mixtures of predicted tokens and the mask embedding, enabling the model to form more globally consistent beliefs before committing tokens. In the second stage, LRD progressively finalises confident tokens while preserving uncertain ones for further iterative refinement, with KL-divergence dynamics serving as a stable criterion for convergence and early stopping. Experiments show that LRD improves performance on both coding tasks, including HumanEval by 6.3 and MBPP by 2.6, and reasoning tasks, including GSM8K by 2.9 and MATH500 by 3.8, while achieving up to 10.6× overall speedup. Moreover, LRD is compatible with single-token decoding, multi-token threshold commitment, and system-level accelerators; when combined with Fast-dLLM, it reaches up to 18.4× speedup over vanilla decoding while further improving accuracy.
BibTeX
@inproceedings{zhu2026latent,
  author = {Qinglin Zhu and Yizhen Yao and Runcong Zhao and Yanzheng Xiang and Siya Qi and Amrutha Saseendran and Chen Jin and Philip Alexander Teare and Bin Liang and Yulan He and Lin Gui},
  title = {{Latent Refinement Decoding: Enhancing Diffusion Language Models by Refining Belief States}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=poXCPd4Q9D},
}
Figure