SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2607.15161 · 2026

On-Policy Delta Distillation

Sangdoo Yun, Dongyoon Han, Byeongho Heo, Jaehui Hwang

arXiv · PDF · Open in the Atlas

Code that ran

7 of 7 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; 0 honoured the contract we drafted, 3 violated it and 0 have no contract verdict; 4 failures of our instrument; 0 no recorded run), measured 2026-11-23; 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/2607.15161.json · badge: /api/ran/2607.15161.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
naver-ai/opd2 canonical (classifier label)
classifier basis: census
7 ran · 0 no recorded run
FunctionStatusWhere it lives
load_chat_template Ran
ran; our contract draft was wrong, not the code
naver-ai/opd2/evaluation/patch_gemma_tokenizer.py
code served (permissive licence) · get_code("6e8ed1c38a0f37ef")
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 str. 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 tempfile
import json
from pathlib import Path

# Create a temporary directory for testing
temp_dir = tempfile.mkdtemp()
output_dir = Path(temp_dir)

# Test case 1: chat_template.jinja exists
jinja_file = output_dir / 'chat_template.jinja'
jinja_file.write_text('{% for message in messages %}{{ message.content }}{% endfor %}', encoding='utf-8')

ARGS = {
    'output_dir': output_dir,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str 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
load_name_to_id Ran
ran; our contract draft was wrong, not the code
naver-ai/opd2/evaluation/patch_gemma_tokenizer.py
code served (permissive licence) · get_code("ce8ce48730952985")
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 dict. 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 json
import tempfile
from pathlib import Path

# Create a temporary directory to serve as output_dir
temp_dir = tempfile.TemporaryDirectory()
output_dir = Path(temp_dir.name)

# Create tokenizer.json with added_tokens
tokenizer_json = {
    "added_tokens": [
        {"content": "<special_token_1>", "id": 50256},
        {"content": "<special_token_2>", "id": 50257},
        {"content": "<pad>", "id": 50258}
    ]
}
(output_dir / "tokenizer.json").write_text(json.dumps(tokenizer_json), encoding='utf-8')

# Create tokenizer_config.json with added_tokens_decoder
tokenizer_config_json = {
    "added_tokens_decoder": {
        "50256": {"content": "<special_token_1>", "lstrip": False, "normalized": False, "rstrip": False, "single_word": False},
        "50259": {"content": "<custom_token>", "lstrip": False, "normalized": False, "rstrip": False, "single_word": False}
    }
}
(output_dir / "tokenizer_config.json").write_text(json.dumps(tokenizer_config_json), encoding='utf-8')

ARGS = {
    "output_dir": output_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
patch_benchmark Ran
ran, violated the contract we drafted
naver-ai/opd2/evaluation/extended_eval_setting.py
code served (permissive licence) · get_code("4d15f61745a192de")
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 bool, ndim 0, dtype family float, shape () 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 os
import re
import tempfile
import shutil

# Create a temporary directory structure to simulate the benchmarks directory
temp_benchmarks_dir = tempfile.mkdtemp()

# Create a test benchmark directory with a mock eval_instruct.py file
test_benchmark_name = 'test_benchmark'
test_benchmark_path = os.path.join(temp_benchmarks_dir, test_benchmark_name)
os.makedirs(test_benchmark_path, exist_ok=True)

# Create a mock eval_instruct.py file with the expected structure
mock_eval_instruct = '''class SomeBenchmark:
    def __init__(self, logger=None, system_instruction=None):
        super().__init__(logger=logger, system_instruction=system_instruction)
        self.n_repeat = 1
'''

eval_instruct_path = os.path.join(test_benchmark_path, 'eval_instruct.py')
with open(eval_instruct_path, 'w') as f:
    f.write(mock_eval_instruct)

# Patch the BENCHMARKS_DIR in the module context
import sys
sys.modules['__main__'].BENCHMARKS_DIR = temp_benchmarks_dir

ARGS = {
    'name': test_benchmark_name,
    'n_repeat': 5
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () 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
patch_file Ran
ran, violated the contract we drafted
naver-ai/opd2/evaluation/extended_eval_setting.py
code served (permissive licence) · get_code("a6b119664ef50a21")
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 bool, ndim 0, dtype family float, shape () 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 os
import re
import tempfile

# Create a temporary file with content that matches the function's expectations
temp_dir = tempfile.mkdtemp()
temp_filepath = os.path.join(temp_dir, "test_eval_instruct.py")

# Write test content with the pattern the function looks for
test_content = """class EvalInstruct:
    def __init__(self, logger=None, system_instruction=None):
        super().__init__(logger=logger, system_instruction=system_instruction)
        self.some_attr = 42
"""

with open(temp_filepath, 'w') as f:
    f.write(test_content)

# Define the arguments dictionary
ARGS = {
    'filepath': temp_filepath,
    'n_repeat': 5,
    'label': 'test_benchmark'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () 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
patch_rg_common Ran
ran, violated the contract we drafted
naver-ai/opd2/evaluation/extended_eval_setting.py
code served (permissive licence) · get_code("39bdeb0a1b0bc974")
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 bool, ndim 0, dtype family float, shape () 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 os
import tempfile
import shutil

# Create a temporary directory to act as our mock BENCHMARKS_DIR
temp_dir = tempfile.mkdtemp()

# Create a mock _rg_common.py file with RGBenchmarkBase that has n_repeat
rg_common_content = '''
class RGBenchmarkBase:
    def __init__(self, logger=None, system_instruction=None):
        self.n_repeat = 1
'''

rg_common_path = os.path.join(temp_dir, '_rg_common.py')
with open(rg_common_path, 'w') as f:
    f.write(rg_common_content)

# Temporarily override BENCHMARKS_DIR for this test
import sys
sys.modules['evalchemy'] = type(sys)('evalchemy')
sys.modules['evalchemy.eval'] = type(sys)('evalchemy.eval')
sys.modules['evalchemy.eval.chat_benchmarks'] = type(sys)('evalchemy.eval.chat_benchmarks')

# Patch the module-level constant in the function's module context
# We'll do this by importing and modifying globals
original_benchmarks_dir = '/workspace/evalchemy/eval/chat_benchmarks'

# Create the necessary directory structure for the mock
os.makedirs(temp_dir, exist_ok=True)

ARGS = {
    'n_repeat': 5
}

# Store temp_dir reference for cleanup if needed
_MOCK_BENCHMARKS_DIR = temp_dir
_ORIGINAL_BENCHMARKS_DIR = original_benchmarks_dir
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () 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
patch_template Ran
ran; our contract draft was wrong, not the code
naver-ai/opd2/evaluation/patch_no_think_tokenizer.py
code served (permissive licence) · get_code("bc4e91faa880741a")
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 tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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.

def patch_template(tpl: str) -> tuple[str | None, str]:
    """Return (patched_template, family). family is 'unknown' on failure."""
    QWEN3_OLD = "{%- if enable_thinking is defined and enable_thinking is false %}\n        {{- '<think>\\n\\n</think>\\n\\n' }}\n    {%- endif %}"
    QWEN3_NEW = "{{- '<think>\\n\\n</think>\\n\\n' }}"
    DSR1_OLD = "<|Assistant|><think>\\n'}}"
    DSR1_NEW = "<|Assistant|><think>\\n\\n</think>\\n\\n'}}"
    QWEN25_OLD = "{%- if add_generation_prompt %}\n    {{- '<|im_start|>assistant\\n' }}\n{%- endif %}"
    QWEN25_NEW = "{%- if add_generation_prompt %}\n    {{- '<|im_start|>assistant\\n<think>\\n\\n</think>\\n\\n' }}\n{%- endif %}"
    
    if QWEN3_OLD in tpl:
        return (tpl.replace(QWEN3_OLD, QWEN3_NEW), 'qwen3')
    if DSR1_OLD in tpl:
        return (tpl.replace(DSR1_OLD, DSR1_NEW), 'dsr1')
    if QWEN25_OLD in tpl:
        return (tpl.replace(QWEN25_OLD, QWEN25_NEW), 'qwen25')
    return (None, 'unknown')


ARGS = {
    'tpl': "{%- if enable_thinking is defined and enable_thinking is false %}\n        {{- '<think>\\n\\n</think>\\n\\n' }}\n    {%- endif %}"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
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
patch_template Ran
ran; our contract draft was wrong, not the code
naver-ai/opd2/evaluation/patch_only_think_tokenizer.py
code served (permissive licence) · get_code("3e727f24b0062b25")
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 tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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

ARGS = {
    'tpl': "{%- if enable_thinking is defined and enable_thinking is false %}\n        {{- '<think>\\n\\n</think>\\n\\n' }}\n    {%- endif %}"
}
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 tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
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

Also present in other papers' code

Of 7 samples lifted from this paper's linked repositories, 7 carry a function identity and 0 do not. Of the 7 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 7 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.

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

On-policy distillation is an alternative post-training method in reinforcement learning that alleviates the constraints imposed by reward models by providing tokenlevel supervision from a teacher model. Although on-policy distillation has been studied and applied across various settings, its fundamental design remains underexplored. In this paper, we introduce a new distillation reward, termed delta signal, instead of directly imitating the teacher's output distribution. The delta signal is defined as the difference between the teacher model and its base model prior to instruction tuning for reasoning capability. It therefore captures the changes induced by reasoning tuning and provides a more direct signal for transferring reasoning capabilities. Using extensive empirical evidence, we show that the delta signal substantially improves on-policy distillation and refer to the new distillation method as On-Policy Delta Distillation (OPD 2 ). Experiments across mathematics, science, and code-reasoning benchmarks demonstrate that OPD 2 consistently outperforms conventional on-policy distillation, enabling reasoning LLMs to achieve strong performance with only a short post-training period. Code will be available at https://github.com/naver-ai/opd2.

For agents

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

get_harvested_code_for_paper("2607.15161")
get_code_for_paper("2607.15161")
have("2607.15161")

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

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

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

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

Connect an agent — have() is free.