Key takeaways
Standard diffusion
Early · Large noise
Late · Small noiseBlocked Gibbs diffusion
Early · Large block
Late · Small blockBloGDiT performs iterative block resampling: early steps modify large blocks for global exploration, while later steps focus on smaller blocks for local refinement. On hard Sudoku, BloGDiT achieves 94.1% accuracy, compared to 48.6% for DiT. On large-scale MaxCut, it reduces the average gap from 162.00 to 32.75.
Motivation
Why blocked Gibbs diffusion?
Improving a near-feasible solution often requires changing a selected subset of variables while preserving the rest. Standard diffusion denoises all variables at every step and can disrupt already-correct assignments.
Why unsupervised learning?
Solution samples are often difficult to obtain for complex constraint problems. BloGDiT uses differentiable problem energies in an unsupervised Boltzmann objective to learn a reusable proposal mechanism without solution labels.
Learned proposals for Sudoku
Classical sampling methods typically solve each instance from scratch using hand-designed proposal mechanisms. BloGDiT instead learns a reusable proposal mechanism across instances. In this Sudoku example, the non-learned baseline makes many exploratory updates, several of which remain close to the initial assignment.
Non-learned sampling · 1,024 steps
BloGDiT · 3 steps
Constraint optimization as Boltzmann sampling
-
Constrained optimization
The goal is to find an assignment X that satisfies all constraints while minimizing the objective.
-
Energy with constraint penalties
The energy combines the objective with nonnegative constraint penalties, weighted to prioritize feasible assignments.
-
Boltzmann distribution
The Boltzmann distribution assigns higher probability to lower-energy assignments. Decreasing the temperature τ concentrates probability mass near energy minimizers.
Blocked Gibbs Diffusion Transformer
BloGDiT performs iterative block resampling, denoising selected variables conditional on the unmasked part of the current assignment.
Forward and reverse trajectories
The forward process applies Gaussian corruption to selected blocks. The reverse chain starts from a Gaussian prior in logit space and denoises each selected block while preserving the remaining variables.
Near the noisy start

Near the final assignment

Select a block
Sample a binary mask mt identifying the variables to update.
Denoise the block
The Transformer predicts the Gaussian mean and variance used to resample the selected logits.
Copy the complement
Copy unmasked variables unchanged.
Diffusion in logit space
Each Sudoku variable is represented by nine logits, one per possible digit. The model resamples the logits for selected variables, while the given clues remain fixed.
During training, constraint energies are evaluated on continuous assignments obtained by applying a row-wise softmax to the logits. For Graph Coloring, the penalty for an edge is the dot product of its endpoints’ color probabilities, penalizing assignments that favor the same color. At inference, a row-wise argmax produces the discrete assignment.
Forward and reverse distributions
We augment each forward and reverse transition with a binary mask that selects the variables to update. The resulting transition factors into mask selection and conditional denoising.
Blocked Gibbs diffusion
Introducing auxiliary masks does not change the corresponding marginal diffusion trajectory: summing out the masks recovers the distribution over assignments (Proposition 3.1). The Boltzmann distribution remains the target over final assignments.
Unsupervised training
Forward KL requires samples from the Boltzmann target, which are generally unavailable for complex constraint problems. We instead minimize a mask-augmented joint KL upper bound on the reverse KL between the model distribution and the Boltzmann target.
Training objective in detail
Let qθ and p denote the reverse and forward joint distributions over trajectories and auxiliary masks.
Multiplying the joint KL by τ yields energy, entropy, forward noise-matching, and mask distribution-matching terms, up to a constant independent of θ. Expectations are taken under the reverse joint distribution.
- Sample energy
- Entropy
- Forward noise matching
- Mask distribution matching
The masked Gaussian transitions yield closed-form entropy and forward noise-matching terms. The mask distribution-matching term vanishes because the forward and reverse processes share the same training mask schedule.
Which variables enter the block?
During training, forward and reverse processes use the same time-dependent, state-agnostic Bernoulli mask schedule, with masking rate ρt. At inference, the sampler can select blocks adaptively based on model uncertainty or constraint violations.
Experiments
Sampling step 1
Sudoku
Graph coloring
Sampling step 50
Sudoku
Graph coloring
Sampling step 1,000
Sudoku
Graph coloring
We compare BloGDiT with a standard DiT baseline using the same Transformer backbone, training data, unsupervised objective, optimization settings, and inference budget. DiT applies Gaussian denoising to all variables at each step.
Benchmark results
Table 2. Performance comparison across four benchmarks. Bold indicates the best result and underline the second-best result. Higher is better for Sudoku, Graph Coloring, and MIS; lower is better for MaxCut.
Sudoku
| Method | Easy ↑ | Hard ↑ |
|---|---|---|
| OR-Tools | 100 | 100 |
| SATNet | 98.3 | 3.2 |
| RRN | 99.8 | 28.6 |
| Yang et al. (2023) | 100 | 32.9 |
| IRED | 99.4 | 62.1 |
| RLSA | 4.2 | 1.8 |
| ConsFormer | 100 | 77.7 |
| DiT | 100 | 48.6 |
| BloGDiT | 100 | 94.1 |
Instances solved (%). Easy is SATNet. Hard is the out-of-distribution RRN split.
OR-Tools solves all instances on both splits. BloGDiT achieves the highest accuracy among learned methods on the harder, out-of-distribution RRN split.
Graph coloring
| Method | 5 colors | 10 colors | ||
|---|---|---|---|---|
| n = 50 ↑ | n = 100 ↑ | n = 100 ↑ | n = 200 ↑ | |
| OR-Tools | 83.08 | 57.16 | 52.41 | 10.25 |
| Greedy | 32.42 | 0.00 | 0.75 | 0.00 |
| Feasibility Jump | 82.83 | 54.50 | 35.66 | 6.00 |
| ANYCSP | 79.17 | 34.83 | 0.00 | 0.00 |
| RLSA | 37.83 | 0.42 | 10.75 | 2.50 |
| ConsFormer | 81.00 | 47.33 | 52.60 | 11.92 |
| DiT | 79.75 | 48.91 | 50.50 | 14.25 |
| BloGDiT | 83.00 | 54.67 | 53.92 | 18.58 |
Instances solved (%). For each color count, the larger graphs are out of distribution.
BloGDiT remains competitive with OR-Tools on the 5-color splits and achieves the highest solve rates on both 10-color splits.
Maximum independent set
| Method | RB-small ↑ | RB-large ↑ |
|---|---|---|
| OR-Tools | 20.10 | 42.66 |
| LwD | 19.01 | 32.32 |
| INTEL | 18.47 | 34.47 |
| DGL | 17.36 | 34.50 |
| LTFT | 19.18 | 37.48 |
| DIFUSCO | 18.52 | – |
| RLSA | 19.97 | 40.19 |
| X2GNN | 20.07 | 39.28 |
| DiffUCO | 18.88 | 38.10 |
| DiT | 8.05 | 0.29 |
| BloGDiT | 19.52 | 37.05 |
Mean independent set size on the two RB test splits.
BloGDiT substantially improves over DiT on both RB splits, while OR-Tools achieves the highest average objective values.
MaxCut
| Method | 800 ↓ | 1,000 ↓ | 2,000 ↓ | ≥ 3,000 ↓ |
|---|---|---|---|---|
| OR-Tools | 143.89 | 112.78 | 365.89 | 378.62 |
| RUNCSP | 185.89 | 156.56 | 357.33 | 401.00 |
| ECO-DQN | 65.11 | 54.67 | 157.00 | 428.25 |
| ECORD | 8.67 | 8.78 | 39.22 | 187.75 |
| ANYCSP | 1.22 | 2.44 | 13.11 | 51.63 |
| RLSA | 3.22 | 4.00 | 13.0 | 66.75 |
| X2GNN | 21.11 | 6.00 | 22.44 | 46.38 |
| DiffUCO | 4.11 | 6.33 | 31.67 | 116.75 |
| ConsFormer | 16.33 | 12.44 | 52.11 | 115.25 |
| DiT | 56.11 | 50.00 | 101.33 | 162.00 |
| BloGDiT | 0.11 | 1.33 | 7.88 | 32.75 |
Mean absolute gap to the best-known cut size, grouped by the number of vertices in GSET graphs.
BloGDiT achieves the smallest average gap across all GSET size buckets. For graphs with at least 3,000 vertices, the gap decreases from 162.00 for DiT to 32.75 for BloGDiT.
Effect of adaptive mask selection
We ablate adaptive mask selection by replacing it with random block selection at the same masking rate. On MIS-RB-large, the average independent set size increases from 17.16 to 37.05 with adaptive selection. On hard Sudoku, accuracy increases from 88.21% to 94.12%.
Number of sampling steps
On Sudoku, accuracy improves rapidly during the early denoising steps and exhibits diminishing returns beyond a few hundred steps. Additional inference steps do not always improve solution quality: on some MaxCut splits, a larger sampling budget increases the gap to the best-known solution.
BibTeX
@inproceedings{xu2026blocked,
title={Blocked Gibbs meets Diffusion Transformers: Unsupervised Learning for Constraint Optimization},
author={Yudong Will Xu and Wenhao Li and Xiaoyu Wang and Scott Sanner and Elias Boutros Khalil},
booktitle={The Fortieth Annual Conference on Neural Information Processing Systems},
year={2026},
url={https://openreview.net/forum?id=z5oDNb2lwJ}
}