arXiv:2610.30744cs.LGOct 2026

Manuscript Offprint

arXiv:2610.30744

Random Remasking Scales Masked Diffusion Inference

Zhaoyi Zhou, Frank Wu, Andrea Zanette

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

ABSTRACT

Masked diffusion models (MDMs) generate sequences by progressively unmasking tokens, but errors introduced during decoding are typically irreversible. Recent work has shown that iterative correction can improve sample quality, yet existing theory fails to explain this given a learned, imperfect denoiser model. We reformulate MDM inference as a Markov chain on the clean sequence space, defined by a remask-denoise kernel that randomly re-introduces masks and then denoises. This helps us analyze the actual denoising trajectory towards the data distribution. The analysis motivates Random Remask-Denoise (R²D) inference, a purely test-time, finetuning-free, reward-free procedure. To further improve performance, we propose Trajectory Correction Training (TCT), a denoiser-training procedure that exposes the model to its own errors along the generation trajectory. On logical tasks, our approach exhibits a striking near-log-linear test-time scaling, achieving over 97% accuracy on hard Sudoku puzzles and over 99% accuracy on 3-SAT. Our approach also applies to pretrained models on actual language tasks, beating iterative correction baselines and the official Q-mode accuracy of LLaDA2.1-mini on HumanEval+.

1 INTRODUCTION

Masked diffusion models (MDMs) have emerged as a strong alternative to autoregressive models (ARMs) for sequence generation (Sahoo et al., 2024; Lou et al., 2024; Ou et al., 2024; Shi et al., 2024). By denoising under bidirectional attention rather than committing to a left-to-right factorization, MDMs can in principle leverage context from both sides when filling in tokens, an advantage that has shown promise on reasoning-heavy tasks.

A central limitation of standard MDM decoding is that revealed tokens are frozen for the rest of the trajectory: Errors introduced by parallel decoding cannot be undone. Iterative correction methods have been proposed to resolve this, either by remasking committed tokens for re-generation (Wang et al., 2026), or by training a model with self-correction ability (Schiff et al., 2026). These methods not only serve as a remedy for parallel-decoding errors, but also unlock test-time scaling for MDMs: The number of model evaluations is no longer bounded by the response length. Each correction step can be viewed as an additional unit of compute spent refining the answer, in spirit analogous to chain-of-thought reasoning for autoregressive models, with iterative error correction itself acting as a form of reasoning.

Despite the empirical success, iterative-correction methods fail to explain why they improve generation quality from the theoretical perspective. Existing explanations, e.g., the ReMDM (Wang et al., 2026) and the predictor–corrector framework (Campbell et al., 2022) only provide convergence analysis of the intermediate sequence marginal distribution under a perfect denoising model. They fail to analyze the actual trajectory generated by an imperfect denoiser, which is the question that really matters.

The prevailing formulation treats MDM inference as an iterative denoising process from a fully masked sequence into a clean sequence. This is hard for a generation trajectory analysis, as intermediate sequences correspond to different masking ratios and hence lie in different subspaces. Observing that each inference step can be further decomposed into a denoise step and a remask step, we re-formulate the entire MDM inference process in this work as an iteration over the clean

Figure

(a) Sudoku-Hard

Figure

(b) 3-SAT

Figure 1: Inference scaling on Sudoku-Hard and 3-SAT. R 2^{2}D and ReMDM are run on standard training checkpoints, both using the standard variant; ProSeCo has its own training method. R 2^{2}D scales near-log-linearly on both tasks and stays above ReMDM at every budget, whereas ProSeCo plateaus after a handful of correction steps.

sequence space: At each step, some of the tokens in the clean sequence are remasked, and then denoised back into a clean sequence. We identify the remask–denoise kernel as the single object underlying both standard decoding and correction, and we derive a single-step update bound of the KL divergence that identifies how the chain more likely moves toward the data distribution at each step.

The bound exposes three factors: Inference timestep schedule, task structure and model quality. The bound suggests a non-increasing timestep schedule, reducing gradually from 1 (fully masked sequence) to 0 (clean sequence). The challenge is how to decide the number of iterations at each step. We propose a natural solution: Keep iterating at the given step until the clean sequence prediction stabilizes, which leads to our Random Remask-Denoise (R²D) inference. Random remasking is more favorable for tasks with local constraints, so that the model better reconstructs masks with revealed information, leading to lower denoising error. The model should be trained under the actual inference trajectory, and thus we propose Trajectory Correction Training (TCT), a self-correction training method that is paired with R²D inference.

On logical tasks like Sudoku-Hard and 3-SAT, R²D with standard training shows significant scaling effect (Figure 1), boosting accuracy from 19.7% and 86% to 93.5% and 98.5%. TCT training further increases accuracy to 97.5% and 99.3%, respectively. R²D also works well on language tasks. On the coding benchmark HumanEval+, R²D with off-the-shelf LLaDA2.1-mini surpasses iterative correction baselines and the official Q-mode inference.

Our main contributions are:

• A unified Markov-chain framework for MDM inference, in which standard decoding and self-correction are instances of a single remask–denoise kernel acting on the complete sequence space.

• Random Remask-Denoise (R²D), a reward-free, finetuning-free inference algorithm with an adaptive timestep schedule motivated by the single-step update bound.

• Trajectory Correction Training (TCT), a denoiser-training procedure that supplies trajectory-aware supervision at every position and pairs naturally with R 2^{2}D.

• Across domains like logical tasks and coding, we demonstrate R2DR^{2}D achieves test-time scaling, and the scaling effect is dependent on the token coupling nature of the task. TCT training further boosts R2DR^{2}D with self-correction ability.

2 RELATED WORK

Iterative-correction inference. A growing body of work equips MDMs with the ability to revise tokens that have already been revealed, falling into two groups. Training-free methods (Wang et al., 2026; Shah et al., 2026) modify only the inference procedure of a pretrained denoiser. For instance, ReMDM (Wang et al., 2026) derives a principled remasking sampler from a custom backward process and remasks already-decoded tokens either uniformly at random or by model confidence before re-predicting them. Trained approaches instead fine-tune or augment the denoiser to recognize and revise its own mistakes. ProSeCo (Schiff et al., 2026) learns a corrector that consumes the denoiser's own outputs and alternates unmasking with correction at inference. PRISM (Kim et al., 2025), RemeDi (Huang et al., 2025), BackPlay (Liu et al., 2026), and Corrective DLM (Zhang et al., 2026) differ in the training recipe but share the same goal of producing per-token quality signals that drive selective remasking. All of these approaches frame correction defensively, as a way to repair errors introduced by parallel decoding; We instead treat iterative remasking and correction as a reasoning mechanism in its own right and as a primary axis for test-time scaling.

Test-time scaling for reward guidance. Most test-time scaling work for MDMs lies in the reward-guidance regime, in which an external reward function or verifier steers sampling toward higher-quality outputs. These methods scale through three mechanisms: particle-based sampling (Singhal et al., 2025; Dang et al., 2026; Ou et al., 2026), iterative noise-denoise refinement (Lee et al., 2025; Uehara et al., 2025; Phunyaphibarn & Sung, 2026), and direct guidance (Tejaswi et al., 2026; Chen et al., 2025). The closest to our framing is Phunyaphibarn & Sung (2026), which also samples from a Markov chain on the complete sequence space but offers limited theoretical analysis of the sampler's convergence. All three families rely on an external quality signal to guide intermediate generation, whereas the inference algorithms we study are reward-free.

References (39)