SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2310.16834 · ICML · 2024

Discrete Diffusion Modeling by Estimating the Ratios of the Data Distribution

Chenlin Meng, Stefano Ermon, Aaron Lou

arXiv · PDF · Open in the Atlas

Code that ran

16 of 18 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 2 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 14 failures of our instrument; 2 no recorded run), measured 2026-11-23; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2310.16834.json · badge: /api/ran/2310.16834.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
louaaron/Score-Entropy-Discrete-Diffusion canonical (classifier label)
classifier basis: census
16 ran · 2 no recorded run
FunctionStatusWhere it lives
bias_dropout_add_scale Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
louaaron/Score-Entropy-Discrete-Diffusion/model/fused_add_dropout_scale.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("0bb0f3f46e52f14d")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_bias_dropout_add_scale Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/model/fused_add_dropout_scale.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("06f8b66017690883")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_model_fn Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/model/utils.py
code served (permissive licence) · get_code("4a58edfade53c8c1")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned function. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

class SimpleScoreModel(nn.Module):
    """Minimal score-based model that accepts x and sigma."""
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 3)
    
    def forward(self, x, sigma):
        """
        Args:
            x: input tensor of shape (batch, features)
            sigma: noise level tensor or scalar
        
        Returns:
            model output
        """
        return self.linear(x)

# Create a simple model instance
model = SimpleScoreModel()

ARGS = {
    "model": model,
    "train": False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_noise Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/noise_lib.py
pointer only (licence: MIT); the stored copy get_code serves, from Dongjae0324/infodis, is pointer only (licence: NONE) · get_code("c7a7325b30d3491b")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from Dongjae0324/infodis, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_optimizer Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/losses.py
pointer only (licence: MIT); the stored copy get_code serves, from Dongjae0324/infodis, is pointer only (licence: NONE) · get_code("32fa27b9da9341dc")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from Dongjae0324/infodis, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

gumbel_softmax Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/catsample.py
pointer only (licence: MIT); the stored copy get_code serves, from Dongjae0324/infodis, is pointer only (licence: NONE) · get_code("a017bf60b761f427")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from Dongjae0324/infodis, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

lm1b_detokenizer Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/data.py
pointer only (licence: MIT); the stored copy get_code serves, from jdeschena/blockgen, is pointer only (licence: NONE) · get_code("576e1b9b9bcae8ff")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from jdeschena/blockgen, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

modulate Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/model/transformer.py
code served (permissive licence) · get_code("03310bba324ae4fb")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small tensors for the modulate function
# x: input tensor with shape (batch_size, feature_dim)
x = torch.randn(2, 4)

# shift: tensor that will be unsqueezed to (batch_size, 1)
# so it should have shape (batch_size,)
shift = torch.randn(2)

# scale: tensor that will be unsqueezed to (batch_size, 1)
# so it should have shape (batch_size,)
scale = torch.randn(2)

ARGS = {
    "x": x,
    "shift": shift,
    "scale": scale,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
modulate Ran
ran, honoured the contract we drafted
louaaron/Score-Entropy-Discrete-Diffusion/model/fused_add_dropout_scale.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("819cf4771f4eebf0")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

optimization_manager Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/losses.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("9b714e281bb784b7")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

ptb_detokenizer Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/data.py
pointer only (licence: MIT); the stored copy get_code serves, from jdeschena/blockgen, is pointer only (licence: NONE) · get_code("9f7fbdbe7ca280e0")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from jdeschena/blockgen, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

residual_linear Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
louaaron/Score-Entropy-Discrete-Diffusion/model/transformer.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("e1d1b19d3f2e9f49")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

rotate_half Ran
ran, honoured the contract we drafted
louaaron/Score-Entropy-Discrete-Diffusion/model/rotary.py
pointer only (licence: MIT); the stored copy get_code serves, from hxixixh/gumbel-distill, is pointer only (licence: NONE) · get_code("8526ce179df04bd4")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from hxixixh/gumbel-distill, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

sample_categorical Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
louaaron/Score-Entropy-Discrete-Diffusion/catsample.py
pointer only (licence: MIT); the stored copy get_code serves, from chuwd19/Split-Gibbs-Discrete-Diffusion-Posterior-Sampling, is pointer only (licence: NONE) · get_code("172aa319a831b3ab")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from chuwd19/Split-Gibbs-Discrete-Diffusion-Posterior-Sampling, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

unsqueeze_as Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
louaaron/Score-Entropy-Discrete-Diffusion/graph_lib.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("f3598c5ced32bdac")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

wt_detokenizer Ran
ran; our contract draft was wrong, not the code
louaaron/Score-Entropy-Discrete-Diffusion/data.py
pointer only (licence: MIT); the stored copy get_code serves, from jdeschena/blockgen, is pointer only (licence: NONE) · get_code("46c10627206a7795")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from jdeschena/blockgen, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

apply_rotary_pos_emb Not yet run
unverified (harvested, no recorded run)
louaaron/Score-Entropy-Discrete-Diffusion/model/rotary.py
pointer only (licence: MIT); the stored copy get_code serves, from gfnorg/diffusion-finetuning, is pointer only (licence: NONE) · get_code("05816c8a9ef162b5")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from gfnorg/diffusion-finetuning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

get_score_fn Not yet run
unverified (harvested, no recorded run)
louaaron/Score-Entropy-Discrete-Diffusion/model/utils.py
code served (permissive licence) · get_code("660f0f7bb11e9f74")
How it ran

no invocation recorded.

Also present in other papers' code

Of 18 samples lifted from this paper's linked repositories, 18 carry a function identity and 0 do not. Of the 18 distinct functions with an identity, 16 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 1 the same month, 16 later) and 2 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
modulate 101 other papers
7 dated earlier, 2 the same month, 91 later, 1 undated · 29 only as an assembly brick
2202.04200 (2022-02)
MaskGIT: Masked Generative Image Transformer
2203.10897 (2022-03)
Unified Multivariate Gaussian Mixture for Efficient Neural Image Compression
2212.09748 (2022-12)
Scalable Diffusion Models with Transformers
and 98 more not named here
lm1b_detokenizer 11 other papers
11 later
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2412.10193 (2024-12)
Simple Guidance Mechanisms for Discrete Diffusion Models
2503.09573 (2025-03)
BLOCK DIFFUSION: INTERPOLATING BETWEEN AU-TOREGRESSIVE AND DIFFUSION LANGUAGE MODELS
and 8 more not named here
ptb_detokenizer 10 other papers
10 later
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2503.09573 (2025-03)
BLOCK DIFFUSION: INTERPOLATING BETWEEN AU-TOREGRESSIVE AND DIFFUSION LANGUAGE MODELS
2505.18883 (2025-05)
Partition Generative Modeling: Masked Modeling Without Masks
and 7 more not named here
wt_detokenizer 10 other papers
10 later
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2503.09573 (2025-03)
BLOCK DIFFUSION: INTERPOLATING BETWEEN AU-TOREGRESSIVE AND DIFFUSION LANGUAGE MODELS
2505.18883 (2025-05)
Partition Generative Modeling: Masked Modeling Without Masks
and 7 more not named here
get_bias_dropout_add_scale 8 other papers
8 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
2410.21035 (2024-10)
Beyond Autoregression: Fast LLMs via Self-Distillation Through Time
2412.10193 (2024-12)
Simple Guidance Mechanisms for Discrete Diffusion Models
and 5 more not named here
rotate_half 8 other papers
8 later · 1 only as an assembly brick
2401.12522 (2024-01)
BiTA: Bi-Directional Tuning for Lossless Acceleration in Large Language Models
2402.07754 (2024-02)
Diffusion of Thought: Chain-of-Thought Reasoning in Diffusion Language Models
2402.11809 (2024-02)
Generation Meets Verification: Accelerating Large Language Model Inference with Smart Parallel Auto-Correct Decoding
and 5 more not named here
gumbel_softmax 4 other papers
4 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2506.19935 (2025-06)
Any-Order GPT as Masked Diffusion Model: Decoupling Formulation and Architecture
and 1 more not named here
sample_categorical 4 other papers
4 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2503.01161 (2025-03)
Split Gibbs Discrete Diffusion Posterior Sampling
and 1 more not named here
get_optimizer 3 other papers
3 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2510.24088 (2025-10)
Information-Theoretic Discrete Diffusion
apply_rotary_pos_emb 2 other papers
2 later
2402.07754 (2024-02)
Diffusion of Thought: Chain-of-Thought Reasoning in Diffusion Language Models
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
get_noise 2 other papers
2 later
2406.03736 (2024-06)
Your Absorbing Discrete Diffusion Secretly Models the Conditional Distributions of Clean Data
2510.24088 (2025-10)
Information-Theoretic Discrete Diffusion
residual_linear 2 other papers
2 later
2402.07754 (2024-02)
Diffusion of Thought: Chain-of-Thought Reasoning in Diffusion Language Models
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
bias_dropout_add_scale 1 other paper
1 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
modulate 1 other paper
1 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
optimization_manager 1 other paper
1 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control
unsqueeze_as 1 other paper
1 later
2405.20971 (2024-05)
Amortizing intractable inference in diffusion models for vision, language, and control

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Despite their groundbreaking performance for many generative modeling tasks, diffusion models have fallen short on discrete data domains such as natural language. Crucially, standard diffusion models rely on the well-established theory of score matching, but efforts to generalize this to discrete structures have not yielded the same empirical gains. In this work, we bridge this gap by proposing score entropy, a novel loss that naturally extends score matching to discrete spaces, integrates seamlessly to build discrete diffusion models, and significantly boosts performance. Experimentally, we test our Score Entropy Discrete Diffusion models (SEDD) on standard language modeling tasks. For comparable model sizes, SEDD beats existing language diffusion paradigms (reducing perplexity by 25-75%) and is competitive with autoregressive models, in particular outperforming GPT-2. Furthermore, compared to autoregressive mdoels, SEDD generates faithful text without requiring distribution annealing techniques like temperature scaling (around 6-8× better generative perplexity than un-annealed GPT-2), can trade compute and quality (similar quality with 32× fewer network evaluations), and enables controllable infilling (matching nucleus sampling quality while enabling other strategies besides left to right prompting).

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2310.16834")
get_code_for_paper("2310.16834")
have("2310.16834")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2310.16834.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2310.16834.svg)](https://syntology.ai/paper/2310.16834)

Connect an agent — have() is free.