SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2404.08495 · 2024

Dataset Reset Policy Optimization for RLHF

arXiv · PDF · Open in the Atlas

Code that ran

3 of 3 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, 0 violated it and 0 have no contract verdict; 3 failures of our instrument; 0 no recorded run), measured 2026-11-22; 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/2404.08495.json · badge: /api/ran/2404.08495.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
cornell-rl/drpo canonical (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
copy not recorded community
not in the paper's declared repositories
2 ran · 0 no recorded run
FunctionStatusWhere it lives
get_reward Ran
ran; our contract draft was wrong, not the code
cornell-rl/drpo/src/tldr/drpo.py
code served (permissive licence) · get_code("724222affceacea6")
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. 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)

# Smallest model that satisfies the function's usage
class SimpleRewardModel(nn.Module):
    def __init__(self, vocab_size, hidden_dim):
        super().__init__()
        self.embedding = nn.Embedding(vocab_size, hidden_dim)
        self.linear = nn.Linear(hidden_dim, 1)
    
    def forward(self, input_ids, attention_mask, return_dict=True, output_hidden_states=True):
        # The function uses reward_logits as a tensor with shape (batch_size, seq_len)
        # and indexes it with [batch_idx, seq_len_idx]
        batch_size = input_ids.size(0)
        seq_len = input_ids.size(1)
        embedded = self.embedding(input_ids)
        logits = self.linear(embedded).squeeze(-1)  # Shape: (batch_size, seq_len)
        return logits

# Tokenizer stand-in
class SimpleTokenizer:
    def __init__(self, pad_token_id=0):
        self.pad_token_id = pad_token_id

# Create arguments
batch_size = 2
seq_len = 8
vocab_size = 10
context_length = 3
hidden_dim = 4

model = SimpleRewardModel(vocab_size=vocab_size, hidden_dim=hidden_dim)

# Create query_responses tensor with some pad tokens
# Shape: (batch_size, seq_len)
query_responses = torch.randint(1, vocab_size, (batch_size, seq_len))
# Add some pad tokens at the end to make first_true_indices meaningful
query_responses[0, 5:] = 0  # pad_token_id
query_responses[1, 6:] = 0  # pad_token_id

tokenizer = SimpleTokenizer(pad_token_id=0)

ARGS = {
    "model": model,
    "query_responses": query_responses,
    "tokenizer": tokenizer,
    "context_length": context_length,
}
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 — a tuple output has no array shape of its own; none is 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
layer_init Ran
ran; our contract draft was wrong, not the code
this paper's copy was not recorded; identical code first harvested from zhaolingao/langptune
pointer only · get_code("9ad5922df265477f")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. 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.

whiten Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
this paper's copy was not recorded; identical code first harvested from zhaolingao/langptune
pointer only · get_code("e78dac11b89dad63")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. 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.

Also present in other papers' code

Of 3 samples lifted from this paper's linked repositories, 3 carry a function identity and 0 do not. Of the 3 distinct functions with an identity, 3 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 3 the same month, 2 later) and 0 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
layer_init 4 other papers
1 dated earlier, 1 the same month, 2 later
2403.17031 (2024-03)
The N+ Implementation Details of RLHF with PPO: A Case Study on TL;DR Summarization
2404.16767 (2024-04)
REBEL: Reinforcement Learning via Regressing Relative Rewards
2410.18870 (2024-10)
End-to-end Training for Recommendation with Language-based User Profiles
and 1 more not named here
whiten 3 other papers
1 the same month, 2 later
2404.16767 (2024-04)
REBEL: Reinforcement Learning via Regressing Relative Rewards
2410.04612 (2024-10)
Regressing the Relative Future: Efficient Policy Optimization for Multi-turn RLHF
2410.18870 (2024-10)
End-to-end Training for Recommendation with Language-based User Profiles
get_reward 1 other paper
1 the same month
2404.16767 (2024-04)
REBEL: Reinforcement Learning via Regressing Relative Rewards

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-22.

Repositories linked to this paper

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

Abstract

Reinforcement Learning (RL) from Human Preference-based feedback is a popular paradigm for fine-tuning generative models, which has produced impressive models such as GPT-4 and Claude3 Opus. This framework often consists of two steps: learning a reward model from an offline preference dataset followed by running online RL to optimize the learned reward model. In this work, leveraging the idea of reset, we propose a new RLHF algorithm with provable guarantees. Motivated by the fact that offline preference dataset provides informative states (i.e., data that is preferred by the labelers), our new algorithm, Dataset Reset Policy Optimization (DR-PO), integrates the existing offline preference dataset into the online policy training procedure via dataset reset: it directly resets the policy optimizer to the states in the offline dataset, instead of always starting from the initial state distribution. In theory, we show that DR-PO learns to perform at least as good as any policy that is covered by the offline dataset under general function approximation with finite sample complexity. In experiments, we demonstrate that on both the TL;DR summarization and the Anthropic Helpful Harmful (HH) dataset, the generation from DR-PO is better than that from Proximal Policy Optimization (PPO) and Direction Preference Optimization (DPO), under the metric of GPT4 win-rate. Code for this work can be found at https://github.com/Cornell-RL/drpo.

For agents

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

get_harvested_code_for_paper("2404.08495")
get_code_for_paper("2404.08495")
have("2404.08495")

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

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

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

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

Connect an agent — have() is free.