Large Language Diffusion Models

Shen Nie, Fengqi Zhu, Zebin You, Xiaolu Zhang, Jingyang Ou +5 more
2/14/2025
cs.CLcs.LG

No official code found. Best implementation: ML-GSAI/LLaDA (3,907 stars, MIT, last commit 2025-11-12). 1 more below.

Abstract

The capabilities of large language models (LLMs) are widely regarded as relying on autoregressive models (ARMs). We challenge this notion by introducing LLaDA, a diffusion model trained from scratch under the pre-training and supervised fine-tuning (SFT) paradigm. LLaDA employs a forward data masking process and a reverse generation process, parameterized by a Transformer to predict masked tokens. It provides a principled generative approach for probabilistic inference by optimizing a likelihood lower bound. Across extensive benchmarks on general tasks, math, code, and so on, LLaDA demonstrates strong scalability and performs comparably to our self-constructed ARM baselines. Remarkably, LLaDA 8B is competitive with strong LLMs like LLaMA3 8B in in-context learning and, after SFT, exhibits impressive instruction-following abilities in case studies such as multi-turn dialogue. Moreover, LLaDA addresses the reversal curse, surpassing GPT-4o in a reversal poem completion task. Our findings show the promise of diffusion models for language modeling at scale and challenge the common assumption that core LLM capabilities discussed above inherently depend on ARMs. Project page and codes: https://ml-gsai.github.io/LLaDA-demo/.

View on arXivView PDF

Code Implementations(2)

ML-GSAI/LLaDACommunity75%
MIT

Official PyTorch implementation for "Large Language Diffusion Models"

3,907271CSS, HTMLFeb 13, 202511 months agoMIT
PyTorch

Shift from autoregressive to masked diffusion: A clean PyTorch implementation of LLaDA (arXiv:2502.09992) demonstrating iterative text generation on Apple Silicon.

00PythonDec 3, 202510 months ago
apple-silicondiffusion-modelsfrom-scratchllmmasked-language-modeling+2 more

Similar Papers

Cite this paper

@article{nie2025large,
  title  = {Large Language Diffusion Models},
  author = {Shen Nie and Fengqi Zhu and Zebin You and Xiaolu Zhang and Jingyang Ou and Jun Hu and Jun Zhou and Yankai Lin and Ji-Rong Wen and Chongxuan Li},
  year   = {2025},
  eprint = {2502.09992},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.09992v3},
  journal = {NEURIPS 2025 2025}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.09992.svg)](https://codeofpaper.com/paper/2502.09992)

Discussion