acceptodds
Under review as a conference paper at ICLR 2027

Online Class Posteriors for Interpretable and Controllable Discrete Diffusion

Abstract

Discrete diffusion models remain far less understood than their continuous counterparts, despite recent breakthroughs across modalities, most notably in text. Leveraging tools from continuous diffusion, we formulate a theoretical framework to track the class-conditional posterior in an online manner by combining conditional and unconditional model predictions. In masked language modeling, this posterior offers highly interpretable dynamics: tokens aligned with a class boost the posterior, while contradictory ones suppress it. We also show that the posterior can be used for logical guidance operations (AND, OR, NOT) in discrete diffusion. These operations enable precise control over generation, such as avoiding specific classes. In addition, we discuss a mismatch in the formulation of classifier-free guidance between discrete and continuous settings: discrete models mix the data distributions, while continuous models mix the marginals. We validate our methods and discuss their potential applications on synthetic data, with all quantities analytically tractable, as well as on MNIST, text, and antibody sequences

Primary area:
generative models
Keywords:
Discrete Diffusion Models, Diffusion Guidance, Diffusion Language Models

Reviews

Among:
Shape:
1234this paper, Top 15%
Figure 1. Mean review rating of the reviewed papers at ICLR 2027. This paper averages 3.00 over 3 reviews, above 85% of the others.
Reviewer_UxXrOpenReview ↗
Rating
2
Confidence
3
Informativeness
2
Presentation
3
Soundness
2
Read review
Paper summary

This paper proposes a framework that tracks the class posterior pt(c∣xt)p_t(c\mid x_t) online during generation in discrete diffusion models. The posterior is updated by accumulating the log-difference between conditional and unconditional predictions (Eq. 10), and taking this as weights, logical operators AND/OR/NOT are derived at the level of discrete rate functions. The core application is a dynamic NOT gate, where repulsive guidance increases only when there are signs that the class to be avoided is appearing. The authors show 1. tracking accuracy on synthetic data where analytical ground truth exists, and 2. interpretability and NOT gate performance across four modalities: MNIST, text, and antibody sequences. Furthermore, they point out that discrete CFG and continuous CFG are different operations that multiplicatively mix data distribution and marginals, respectively.

Critical strengths
  1. Unlike autoregressive models, it was difficult in Diffusion LMs to see "at what point what is decided," but this paper tracks the fluctuation of the posterior in units of token flips, providing direct signals such as "surging at wine/variety/red, no reaction at a/the" (Table 1). This can be reused not only for generation control but also as a tool to analyze the internal dynamics of dLMs, and opens a genuinely new analysis axis to this community in that it has no counterpart in the continuous domain. (It is considered the longest-lasting contribution of this paper.)

  2. Under extreme class imbalance in antibody generation(IGHV3 44% vs IGHV7 0.5%), it safely removes both majority/minority with a single hyperparameter. This contrasts with static CFG requiring recalibration per regime. In image and protein modalities where concepts cannot be avoided by prompting, it enables "avoiding specific classes," so there is room for it to be cited importantly in academia such as biological sequence design.

Critical weaknesses
  1. The point that discrete CFG multiplicatively mixes data distributions is conceptually interesting, but there is no answer to what measurable consequence this difference produces in generation quality, or what practitioners should change. Fig 5 is merely a toy illustration; there is no prescription like "in this case, this mixture is correct," nor an experiment isolating and showing the quality difference between the two operations. For this observation to carry real weight, it needs to guide actual modeling choices; right now, it reads more like a side remark. This itself limits the paper's potential impact.

  2. Posterior tracking (Eq. 10) directly follows Koulischer's τ,δ\tau,\delta formula, and the authors acknowledge that the NOT gate's "only difference from continuous is changing score to rate." Moreover, the authors directly state that the OR gate is "not strictly necessary for class-conditional generation," and text NOT is "rather silly since it can be done by prompting" (Appendix E.3). As a result, the new practical value converges to the NOT gate of image/antibody. The benchmarks are also weak to support this: MNIST is insufficient to prove controllability based on 2027 standards, and the near-perfect performance in antibodies is explained by the authors themselves as "because the classes are so well separated that the task is easy"(Appendix F.4). The baseline also stops at a single comparison with static negative CFG, lacking a contrast with more sophisticated discrete guidance in this field (such as time-dependent schedules of Rojas 2026). That is, the content regarding "why this was non-trivially difficult in discrete and what we broke through" is empty.

Questions for authors
  1. Can you theoretically characterize the phenomenon where the tracked posterior deviates from the ground-truth when using the DFM sampler used in practice (Fig 6b)? Does this gap place an upper bound on the reliability of the NOT gate?

  2. Can you show measurable differences that the CFG mismatch produces in generation results? For example, are there results comparing quality metrics by isolating data-level mixing and marginal-level mixing in the same setting?

  3. How much does the superiority of the dynamic NOT gate (Fig 4, 17) depend on the hyperparameter search budget? Is the Pareto superiority maintained even when matched to the same search budget as the static baseline?

  4. How does the AUC of posterior tracking change in more difficult discrete image/text settings beyond MNIST? How does saturation shift depending on task difficulty?

3 comments
AuthorsOpenReview ↗

Reply to review

General We thank the reviewer for their careful review and helpful feedback. We are glad they recognize the potential of online posterior estimation for analyzing denoising dynamics in discrete diffusion and the advantages of dynamic over static guidance, particularly for highly unbalanced distributions.

Reply to Ws and Qs Below we will adress all weaknesses and questions brought up by the reviewer. We split the second weakness in three subtopics for more readability.

  • W1 + Q2 (D- vs C- CFG): Discrete and continuous CFG (data/marginal-level mixture) are evaluated using LLaDA on MATH-2000 [1]. Both schemes improve on the baseline, and perform comparably (Fig. 5a). The main difference between the schemes, is that the discrete variant degrades much faster at high guidance scales (Fig. 5b). This could explain why guidance scales typically range from 0–3 in discrete settings but can reach 10 in continuous settings. More details in Appendix D.4.
  • W2.1 + Q4 (Scalability): Our experimental design aims to demonstrate the generality of posterior tracking across different modalities (images, text, and antibody sequences), rather than relying on a single benchmark or modality. However, we agree that evaluating posterior tracking on more challenging tasks is important to assess its scalability:
    Image experiments: We evaluate posterior tracking on a 120M-parameter CIFAR10 uniform diffusion model, with corresponding posterior-tracking AUCs in Fig. 29. Despite our best efforts, obtaining a high quality unconditional CIFAR model proved difficult. We have added Appendix C.5 on this topic, with for instance comparison to smaller 35M models on the same modality. The AUC curves show the same qualitative behavior as the MNIST curves with as difference that the final obtained AUC is lower.
    Text experiments: We evaluate the posterior using LLaDA on a more realistic story-generation task (App. D). The posterior stabilizes at around 86% AUC (Fig. 37), despite greater diversity of possible generations. Together with our antibody experiments, these results demonstrate posterior tracking's applicability to open-ended generation across modalities.
    We acknowledge that a systematic investigation of how tracking accuracy scale with task complexity remains an interesting direction for future work, and have added this to the limitations.
  • W2.2 (Missing baseline: guidance schedules): We agree that a baseline with time-dependent schedules [2] was missing. We ablate three schedules: increasing, decreasing, and sine-shaped. The decreasing schedule performs best for negative guidance on MNIST, consistent with our dynamic guidance. It performs comparably to ours on class 0 but worse on classes 1–2 (Fig. 4). We thank the reviewer for this valuable suggestion, which enables a fairer comparison of negative guidance methods for discrete diffusion.
  • W2.3 (What does the paper add to the field?): Most conclusions that held in the continuous setting transfer to the discrete, yet demonstrating this, through both theoretical derivations and experimental validations is relevant. We value findings that are different even more; the interpretability of the token flips, difference of best performing guidance profiles [3],... Analysing these differences yields fundamental insights into discrete diffusion, such as the connection of the OR gate to the flow matching conditioning construction, and the difference between how CFG is implemented in the discrete and continuous literature.
  • Q1 (Error of posterior): We expanded Appendix A.3 to address the error introduced by using the DFM sampler. The average error between the DFM-tracked and exact Bayesian log posterior is: ϵtˉ(c,xt)=IDFM(c;x≤t)−IDFM(c;xt)\bar{\epsilon_t}(c,x_t) = I_{DFM}(c;x_{\leq t}) - I_{DFM}(c;x_t). Three complementary bound can be derived, yielding 0≤ϵtˉ≤min⁡(H(c∣xt),B(t))0 \leq \bar{\epsilon_t} \leq \min{(H(c|x_t),B(t)}), where the conditional entropy bound is tighter at low noise and (B(t)=∑s<tIDFM(c;xs+1∣xs)B(t)=\sum_{s<t}I_{DFM}(c;x_{s+1}|x_s)) is tighter at high noise (Fig. 8). We further analyse the relationship between the DFM-tracked and exact posteriors empirically (Fig. 9). This analysis provides a solid starting point for future work.
  • Q3 (Setting τ\tau): As shown in Fig. 20, our grid search reveals a broad region of hyperparameter space with strong performance, indicating a stable performance landscape around the optimum. This suggests that coarser grid searches should suffice in practice, keeping the computational cost manageable. Nevertheless, finding the optimum introduces an additional hyperparameter and may require further tuning. Addressing this issue is a promising direction for future work.

[1] Measuring Mathematical Problem Solving With the MATH Dataset, Hendrycks et al., NeurIPS21
[2] Improving Classifier-Free Guidance in Masked Diffusion: Low-Dim Theoretical Insights with High-Dim Impact, Rojas et al., ICLR26
[3] Dynamic Negative Guidance of Diffusion Models, Koulischer et al., ICLR25

I appreciate for thorough rebuttal and newly added experiments. I think this paper makes a meaningful contribution to the community. However, some concerns remain. First, for Q1, I asked whether the gap between the DFM-tracked and the true posterior places upper bound on the reliability of NOT gate. The response bounds the average posterior error but does not connect that bound to NOT-gate performance. For Q4, CIFAR experiments cover only posterior tracking. NOT gate is still evaluated only on MNIST, so the controllability concern remains. For Q3, a broad region of strong performance does not show that the Pareto advantage holds under a matched search budget. For it, you should show either 1. the Pareto curve with a randomly chosen or worst-case τ, or 2. results with τ selected on a validation set and evaluated on a held-out test set. Lastly, it is still unclear how easily practitioners can adopt this method in real-world tasks, given the extra hyperparameters and the authors' own recommendation of negative CFG for text. (If the concerns in Q1 and Q3 are adequately addressed, I am willing to raise my score)

AuthorsOpenReview ↗

Reply to remaining concerns

General We thank the reviewer for acknowledging the meaningful contribution of our manuscript, and hope that the clarifications below address the remaining concerns.

Further discussion on Q1 and Q3:

  • Q1 (Effect of posterior error on the NOT gate): We added Appendix A.3 on this. With an approximate posterior p^c\hat{p}_c, the gate rate becomes R^t¬c=λRtc+(1−λ)Rt¬c\hat{R}_t^{\neg c} = \lambda R_t^{c} + (1-\lambda) R_t^{\neg c} with λ=pc−p^c1−p^c\lambda = \frac{p_c-\hat{p}_c}{1-\hat{p}_c} (see Fig. 7). Underestimating the posterior moves it towards the unconditional rate, leaking parts of class cc. Overestimating the posterior moves the rate past the exact NOT rate, overshooting the suppression and possibly producing negative rates, which are clamped to zero. We also noticed while addressing this question, that this clamping was not stated explicitly in the original manuscript; it is now specified in the main text. We thank the reviewer for their comment, which helped us address a small but meaningful gap in the analysis.

  • Q3 (Sensitivity of NOT gate on τ\tau): In response to the remaining concern, we added the experiment shown in Fig. 21 (see App. C.4): it shows how the pareto curves vary for the values of τ\tau swept in the grid search for the NOT gate on MNIST. The 5 ablated curves outperform the static CFG baseline. We believe that this much better illustrates our method's stability in τ\tau on this modality and thank the reviewer for suggesting the addition of this figure to the document.

We hope that these additional results help the reviewer to overcome their remaining hesitation.

Reviewer_jXiqOpenReview ↗
Rating
3
Confidence
1
Informativeness
2
Presentation
3
Soundness
2
Read review
Paper summary

This paper studies online class information in discrete diffusion models. It accumulates conditional-versus-unconditional transition log-likelihood ratios during generation to obtain a class-related score, with practical temperature and offset adjustments. Experiments cover analytically tractable synthetic sequences, MNIST, LLaDA-based text generation, and antibody sequences. The reported results show informative intermediate class scores and improvements over static negative CFG in the quality–violation tradeoff on images and antibodies.

Critical strengths
  • An accessible class-evidence signal that reuses generative predictions. The method uses conditional and unconditional predictions rather than a separately trained noisy-state classifier; these predictions can be reused when they are already computed for guidance.
Critical weaknesses

None

Questions for authors
  • What concrete uses does the proposed method currently offer for DLM text generation beyond inspecting class-evidence trajectories? In practice, users can express topic and avoidance constraints directly in the prompt. In which text-generation scenarios do the demonstrated benefits justify the additional conditional predictions and hyperparameter tuning?
2 comments
AuthorsOpenReview ↗

Reply to review

General We thank the reviewer for taking the time to read the paper, even if not aligned well with their area of expertise, and we appreciate that they still found the paper informative and well-presented. Our work combines different theoretical elements (online posterior estimation, logical operators and differences in CFG implementations) as well as different modalities (synthetic, text, images, antibody sequences), which made writing a coherent paper require a lot of effort, as recognised by the reviewer.

Reply to Ws and Qs Below we will adress the reviewers question:

  • Q1 (Practicality of approach for DLMs): We agree that the value of our work on text is not centered around the NOT gate itself, and for this reason we chose to move the text NOT gate to the appendix. Instead, we see the real value of our work in the text domain in posterior tracking. We envision several avenues for future work beyond the scope of this paper: early rejection when an undesired class is being generated, combining prompted and guided NOT, and using posterior tracking as an analysis tool to better understand the generation process of DLMs. Furthermore, in this rebuttal, we analysed the differences between discrete and continuous CFG (logit mixing vs probability mixing), providing an empirical perspective on their respective guidance-scale behaviour. In short the broader value of our contribution lies in posterior tracking and its potential applications as well as the distinction between continous and discrete CFG.

Thank you for your clarification. I will keep my score.

Reviewer_gvY5OpenReview ↗
Rating
4
Confidence
4
Informativeness
3
Presentation
3
Soundness
3
Read review
Paper summary

The paper transfers two inference-time tools from continuous diffusion to the discrete setting: (i) online tracking of the class-conditional posterior during generation, by combining conditional and unconditional model predictions, and (ii) logical operators (AND, OR, NOT) over discrete rate functions for composing conditional processes. The posterior is exact when analytical quantities are available and yields interpretable token-level dynamics (which token flips move the sample toward or away from a class). The authors also formalize a mismatch between discrete and continuous CFG - discrete mixes the data distributions multiplicatively, continuous mixes the marginals additively. The methods are validated on synthetic data with exact ground truth, MNIST, text, and antibody sequences.

Critical strengths

The paper has a few significant strengths overall, which I will outline below.

Strengths:

  1. The central result - that the class posterior can be tracked online and exactly (given analytical quantities), from the conditional/unconditional predictions already used for guidance and at no additional cost - is elegant and cleanly derived.
  2. The interpretability is genuinely new: in masked language modeling one can see which specific token flips move the sample toward or away from a class, which has no continuous analogue and is nicely illustrated (Table 1, Fig. 2a).
  3. The logical operators are given in closed form, with the OR gate recovering a clean posterior-weighted (Bayesian) average of rates and the NOT gate yielding a dynamic negative guidance that is better motivated than the static negative CFG.
  4. The additive-vs-multiplicative discrete/continuous CFG mismatch is a sharp and, to my knowledge, previously unremarked observation, and the empirical validation is well-designed - exact synthetic ground truth first, then across several modalities, with the NOT gate’s advantage shown on Pareto curves and under class imbalance.
Critical weaknesses

However, despite its strengths, the paper has a few weaknesses.

Weaknesses:

  1. The experiments stay on relatively small models and low-dimensional / few-class settings (MNIST, a 50M antibody model, topic-steering with LLaDA), so the scalability of the posterior tracking and the logical operators to higher-dimensional, large-vocabulary or many-class discrete diffusion is not really demonstrated.
  2. The “exact” posterior relies on analytical quantities / a Markovian kernel, but in the real experiments a discrete-flow-matching transition kernel is substituted for stability. The error introduced by this substitution is not quantified, so the gap between the exact theory and the implemented estimator remains unclear.
  3. The AND gate - arguably the most subtle operator, because of the (non)commutativity of mixing and noising - is only derived, not evaluated empirically (only OR and NOT are tested).
  4. It would strengthen the paper to also show the framework for discrete diffusion samplers from unnormalized densities, not only for conditional generation.
Questions for authors

I would like to see especially the responses to the issues mentioned as weaknesses. Besides, I have a few additional questions:

  1. Is the approach usable for higher-dimensional discrete diffusion problems such as molecular design (large vocabularies / structured outputs)? How do the cost and the accuracy of the posterior tracking scale there?
  2. Could the posterior and the logical-operator machinery be applied to discrete samplers from unnormalized densities?
  3. How large is the error from using the discrete-flow-matching kernel instead of the exact Markovian one, and how is the NOT-gate hyperparameter \tau chosen in practice?
2 comments
AuthorsOpenReview ↗

Reply to review

General We thank the reviewer for their positive assessement of the manuscript as well as their constructive feedback. We appreciate that they found the paper both well presented and informative. We further thank the reviewer for recognising the novelty of the interpretability using the posterior, and our finding of the mismatch between discrete and continuous implementations of CFG.

Reply to Ws and Qs Below we try to adress all weaknesses and questions brought up by the reviewer. When appropriate we combine a question and corresponding weakness into a single reply:

  • W1+Q1 (Scalability of approach): Our experimental design prioritises demonstrating the generality of our methods across different modalities, rather than exhaustively scaling up within a single modality. Nevertheless, we agree that additional at larger experiments scales are valuable.
    Image experiments: We increased the size of the MNIST models and updated the corresponding figures; the conclusions remain unchanged. We additionally evaluate posterior tracking on a 120M-parameter CIFAR-10 uniform diffusion model, although despite our best efforts, obtaining a high quality unconditional CIFAR model proved difficult (details in Appendix C.5). The posterior-tracking AUCs for the available 120M uniform model, shows trends that are consistent with MNIST (Fig. 29).
    Large vocabulary experiments: We extend our LLaDA experiments to a more realistic story-writing task (Fig. 36-37). The posterior stabilizes around 86%, providing further evidence of applicability in large-vocabulary settings. Unfortunately we could not find existing models in settings such as molecular design, neither did we have the time to train them, thus we cannot follow up on that suggestion. We acknowledge that a systematic study of how tracking accuracy scale with sequence length, etc. remains open. We added this to the limitations section.
  • W2+Q3 (Error of DFM transition kernel for online posterior): We expanded Appendix A.4 to address the error introduced by using the DFM sampler. Our main result is that the average error between the DFM-tracked log posterior and the exact Bayesian log posterior is: ϵtˉ(c,xt)=IDFM(c;x≤t)−IDFM(c;xt)\bar{\epsilon_t}(c,x_{t}) = I_{DFM}(c;x_{\leq t}) - I_{DFM}(c;x_t). We further derive three complementary bounds, yielding 0≤ϵtˉ≤min⁡(H(c∣xt),B(t))0 \leq \bar{\epsilon_t} \leq \min{(\mathrm{H}(c|x_t),B(t)}), where the conditional entropy bound is tighter at low noise and (B(t)=∑s<tIDFM(c;xs+1∣xs)B(t)=\sum_{s<t}I_{DFM}(c;x_{s+1}|x_s)) is tighter at high noise. We illustrate the error and bounds on synthetic data (Fig. 8). We further analyse the relationship between the DFM-tracked and exact posteriors empirically (Fig. 9). We believe this analysis provides a useful theoretical understanding of the approximation introduced by the DFM sampler.
  • W3 (AND gate ablations): We evaluate the multiplicative AND gate through classifier-free guidance (CFG). LLaDA is evaluated on MATH-2000 [4] using: discrete guidance, combining distributions in logit space, and continuous guidance, mixing probabilities directly. This allows us to isolate the impact of mixing methods on the AND operator. We find that both mixing methods yield higher accuracy than the baseline (going from 35.6% to 37.1% and 37.6% for data-level and marginal-level mixture respectively) and have added this to the main paper in Figure 5a. However, from one single benchmark, we cannot conclusively claim one method is better than the other. We include these additional experiments in Appendix D.4 with Fig. 39.
  • W4+Q2 (Posterior for unnormalised densities): Our framework does not require normalised densities, but rather knowledge of the corresponding rate function. Extending it to unnormalised densities therefore mainly requires estimating this rate function, which can be challenging. For instance, approaches based on MCMC rollouts have been proposed [1,2]. Once the rate function is available, our logical operators apply without modification. We leave this extension to future work.
  • Q3 (Setting τ\tau). In practice, for all experiments, we follow [3] and perform a grid search over the hyperparameters, selecting the best-performing setting. As shown in Fig. 20, performance is relatively stable around the identified optimum, suggesting that a considerably coarser search may suffice in practice. To further facilitate practical use, we have extended Appendix F with a discussion of the effects of the different hyperparameters on posterior tracking.

[1] D-DOIT: Training-free Adaptation of Discrete Diffusion via Doob’s h-Transform, Wu et al., NeurIPS26
[2] Discrete Feynman-Kac Correctors, Hasan et al., preprint
[3] Dynamic Negative Guidance of Diffusion Models, Koulischer et al., ICLR25
[4] Measuring Mathematical Problem Solving With the MATH Dataset, Hendrycks et al., NeurIPS21

I thank the authors for some additional clarifications. I will maintain my high score.

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Related papers

Loading the map…

Discussion (0)

Sign in to comment.