TLDR: A new research paper introduces the Sandwiched Policy Gradient (SPG) algorithm, which addresses the challenge of training Diffusion Large Language Models (dLLMs) with reinforcement learning. By leveraging both upper and lower bounds of the intractable log-likelihood, SPG provides a more robust and less biased policy gradient. Combined with a block-wise masking strategy and a mixture objective, SPG significantly improves accuracy on mathematical and logical reasoning benchmarks, outperforming previous state-of-the-art methods by up to 27.0%.
Diffusion Large Language Models, or dLLMs, are quickly becoming a powerful alternative to traditional language models. Their unique ability to generate multiple tokens at the same time offers a significant speed advantage, making them very efficient for various text generation tasks. However, a major hurdle has been effectively training these models using reinforcement learning (RL) to align them with human preferences or specific task goals.
The core challenge lies in the ‘intractable log-likelihood’ of dLLMs. In simpler terms, it’s incredibly difficult to directly calculate how likely a dLLM is to produce a certain sequence of text. This calculation is crucial for standard RL methods, which rely on ‘policy gradients’ to improve the model’s performance. Previous attempts to overcome this have used approximations, like the ‘evidence lower bound’ (ELBO), but these one-sided estimates can introduce significant inaccuracies, leading to suboptimal training.
Introducing Sandwiched Policy Gradient (SPG)
A new research paper, titled “SPG: Sandwiched Policy Gradient for Masked Diffusion Language Models,” proposes an innovative solution called the Sandwiched Policy Gradient (SPG). Developed by Chenyu Wang, Paria Rashidinejad, DiJia Su, Song Jiang, Sid Wang, Siyan Zhao, Cai Zhou, Shannon Zejiang Shen, Feiyu Chen, Tommi Jaakkola, Yuandong Tian, and Bo Liu, SPG tackles the intractable log-likelihood problem by using both an upper and a lower bound of the true log-likelihood. This ‘sandwiching’ approach provides a more robust and less biased way to estimate the policy gradient.
The fundamental idea behind SPG is elegant: when a dLLM generates a high-reward response, the algorithm works to maximize a tractable lower bound of its log-likelihood. Conversely, for low-reward responses, it minimizes a tractable upper bound. This dual approach ensures that the model learns effectively from both positive and negative feedback, which is critical for sophisticated RL algorithms.
Enhancements for Stability and Efficiency
Beyond the core ‘sandwiching’ concept, SPG introduces a ‘block-wise masking strategy’ for its Monte Carlo estimations. This technique helps to align the data distributions during training and optimization, leading to more stable and efficient learning. Additionally, for negative feedback, SPG uses a clever mixture of the upper and lower bounds. This mixture is theoretically proven to reduce the variance of the gradient, making the training process more stable and reliable.
Also Read:
- Balancing Efficiency and Accuracy in Large AI Models with PAC Reasoning
- The Locality Dial: Bridging Interpretability and Performance in LLMs
Impressive Performance Gains
The effectiveness of SPG was rigorously tested across four challenging mathematical and logical reasoning benchmarks: GSM8K, MATH500, Countdown, and Sudoku. The results were compelling, showing that SPG significantly outperforms existing state-of-the-art RL methods for dLLMs. For instance, SPG improved accuracy by 3.6% in GSM8K, 2.6% in MATH500, a remarkable 18.4% in Countdown, and an even more impressive 27.0% in Sudoku. These gains highlight SPG’s ability to enable dLLMs to achieve higher accuracy and faster convergence in complex reasoning tasks.
The research paper demonstrates that SPG not only provides a principled solution to a long-standing challenge in dLLM training but also sets new benchmarks for performance. This work paves the way for more advanced and human-aligned diffusion language models. You can read the full research paper here.


