SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2404.16767 · 2024

REBEL: Reinforcement Learning via Regressing Relative Rewards

arXiv · PDF · Open in the Atlas

Code that ran

16 of 20 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, 1 violated it and 0 have no contract verdict; 13 failures of our instrument; 4 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.16767.json · badge: /api/ran/2404.16767.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
zhaolingao/rebel canonical (classifier label)
classifier basis: census
11 ran · 3 no recorded run
Owen-Oertell/rlcm canonical (classifier label)
classifier basis: census
5 ran · 1 no recorded run
FunctionStatusWhere it lives
betas_for_alpha_bar Ran
ran, honoured the contract we drafted
Owen-Oertell/rlcm/lcm_rl_pytorch/diffusers_patch/lcm_scheduler.py
pointer only (licence: NONE); the stored copy get_code serves, from jabir-zheng/TCD, is pointer only (licence: NONE) · get_code("f1e3f7493aad4745")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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.

compressibility Ran
ran; our contract draft was wrong, not the code
Owen-Oertell/rlcm/lcm_rl_pytorch/rewards/rewards.py
pointer only (licence: NONE) · get_code("1cf3d9a4597a653f")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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.

filter_same_responses Ran
ran, violated the contract we drafted
zhaolingao/rebel/src/ultrafeedback_largebatch/filter_tokenize.py
code served (permissive licence) · get_code("b44d4582c73da402")
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 torch
import numpy as np

torch.manual_seed(0)

# The function expects a dict-like row with 'chosen' and 'reject' keys
# It compares these two values for inequality

row = {
    'chosen': 'response_a',
    'reject': 'response_b'
}

ARGS = {
    'row': row
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — 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
first_true_indices Ran
ran, honoured the contract we drafted
zhaolingao/rebel/src/nectar/rebel.py
code served (permissive licence) · get_code("579f0202bb30e003")
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 Tensor, ndim 1, dtype family int, shape (2,) 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 a small 2D boolean tensor (batch_size=2, sequence_length=4)
# This will test the function's ability to find the first True in each row
bools = torch.tensor([
    [False, False, True, False],
    [False, True, False, False]
], dtype=torch.bool)

ARGS = {
    "bools": bools,
    "dtype": torch.long
}
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 Tensor, ndim 1, dtype family int, shape (2,) — shape (2,) 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
generate Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/tldr/sft.py
code served (permissive licence) · get_code("51062aca9db3f84c")
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 Tensor, ndim 2, dtype family int, shape (2, 8) 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
import torch.nn as nn

torch.manual_seed(0)

# Stand-in tokenizer with pad_token_id
class SimpleTokenizer:
    def __init__(self, pad_token_id=0):
        self.pad_token_id = pad_token_id

# Stand-in generation config
class SimpleGenerationConfig:
    def __init__(self):
        self.max_new_tokens = 5
        self.do_sample = False

# Minimal LM backbone that implements generate method
class SimpleLMBackbone(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 4)
    
    def generate(self, input_ids, attention_mask, generation_config, return_dict_in_generate=False):
        # Mock generate: return sequences of shape (batch_size, original_length + new_tokens)
        batch_size = input_ids.shape[0]
        context_length = input_ids.shape[1]
        new_length = 3  # Generate 3 new tokens
        
        # Create output sequences
        generated = torch.randint(1, 10, (batch_size, context_length + new_length))
        
        # Return object with sequences attribute
        class Output:
            def __init__(self, sequences):
                self.sequences = sequences
        
        return Output(generated)

# Create instances
tokenizer = SimpleTokenizer(pad_token_id=0)
generation_config = SimpleGenerationConfig()
lm_backbone = SimpleLMBackbone()

# Create queries tensor: batch_size=2, sequence_length=5, with some padding
queries = torch.tensor([
    [1, 2, 3, 0, 0],
    [4, 5, 0, 0, 0]
])

ARGS = {
    'lm_backbone': lm_backbone,
    'queries': queries,
    'tokenizer': tokenizer,
    'generation_config': generation_config
}
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 Tensor, ndim 2, dtype family int, shape (2, 8) — shape (2, 8) 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
get_cosine_schedule_with_warmup Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/ultrafeedback_largebatch/rebel.py
code served (permissive licence) · get_code("70c923c8290a4fcc")
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 LambdaLR. 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
from torch.optim import SGD

torch.manual_seed(0)

# Create a minimal model
model = nn.Linear(4, 3)

# Create an optimizer
optimizer = SGD(model.parameters(), lr=0.1)

# Define arguments for get_cosine_schedule_with_warmup
ARGS = {
    "optimizer": optimizer,
    "num_warmup_steps": 100,
    "num_training_steps": 1000,
    "num_cycles": 0.5,
    "last_epoch": -1,
}
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 LambdaLR — a LambdaLR output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a LambdaLR 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_message Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/ultrafeedback_largebatch/filter_tokenize.py
code served (permissive licence) · get_code("dc68fb166b4b7b89")
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 list, 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

torch.manual_seed(0)

# The function get_message takes instruction and/or response as strings
# and constructs a message list with role and content fields.
# At least one of instruction or response must be provided.

ARGS = {
    'instruction': 'What is the capital of France?',
    'response': 'The capital of France is Paris.'
}
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 list, ndim 1, dtype family float — a list 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
get_message Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/ultrafeedback_largebatch/generate.py
code served (permissive licence) · get_code("93805966dfd5681a")
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 list, 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

def get_message(instruction):
    message = [{'role': 'user', 'content': instruction}]
    return message

ARGS = {
    'instruction': 'What is the capital of France?'
}
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 list, ndim 1, dtype family float — a list 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
get_message Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/ultrafeedback_largebatch/rank.py
code served (permissive licence) · get_code("689d710104523822")
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 list, 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
import numpy as np

torch.manual_seed(0)

instruction = "What is 2+2?"
response = "The answer is 4."

ARGS = {
    'instruction': instruction,
    'response': response
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
get_model_prediction Ran
ran; our contract draft was wrong, not the code
Owen-Oertell/rlcm/lcm_rl_pytorch/util/model.py
pointer only (licence: NONE) · get_code("fc7498a95a58a987")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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_reward Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/tldr/rebel.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
get_reward Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/tldr/rm.py
code served (permissive licence) · get_code("c02add7716c931ba")
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 Tensor, ndim 1, dtype family float, shape (2,) 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
import torch.nn as nn

torch.manual_seed(0)

# Build a minimal model that satisfies the function's usage
class RewardModel(nn.Module):
    def __init__(self, hidden_size=4):
        super().__init__()
        self.hidden_size = hidden_size
        self.embedding = nn.Embedding(50, hidden_size)
        self.transformer = nn.TransformerEncoderLayer(d_model=hidden_size, nhead=1, batch_first=True, dim_feedforward=8)
        self.linear = nn.Linear(hidden_size, 1)
    
    def forward(self, input_ids, attention_mask, return_dict=True, output_hidden_states=True):
        # Embed input
        hidden_states = self.embedding(input_ids)
        # Apply transformer
        hidden_states = self.transformer(hidden_states, src_key_padding_mask=~attention_mask.bool())
        # Get logits (batch_size, seq_len, 1) -> reshape to (batch_size, seq_len)
        logits = self.linear(hidden_states).squeeze(-1)
        
        # Return as indexable object (tuple or dict-like)
        if return_dict:
            return logits
        return logits

# Build a minimal tokenizer
class SimpleTokenizer:
    def __init__(self, pad_token_id=0):
        self.pad_token_id = pad_token_id

# Create instances
model = RewardModel(hidden_size=4)
tokenizer = SimpleTokenizer(pad_token_id=0)

# Create query_responses tensor
# Shape: (batch_size=2, seq_len=5)
# Values should be token IDs in range [1, 49] (avoiding pad_token_id=0 at most positions)
query_responses = torch.tensor([
    [5, 10, 15, 20, 0],  # second token is end, pad token at end
    [3, 7, 12, 0, 0]     # third token is end, pads at end
], dtype=torch.long)

ARGS = {
    "model": model,
    "query_responses": query_responses,
    "tokenizer": tokenizer
}
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 Tensor, ndim 1, dtype family float, shape (2,) — shape (2,) 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
incompressibility Ran
ran; our contract draft was wrong, not the code
Owen-Oertell/rlcm/lcm_rl_pytorch/rewards/rewards.py
pointer only (licence: NONE) · get_code("11c329fa52d72b13")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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.

layer_init Ran
ran; our contract draft was wrong, not the code
zhaolingao/rebel/src/tldr/rebel.py
code served (permissive licence) · get_code("9ad5922df265477f")
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 Linear. 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 numpy as np
import torch
import torch.nn as nn

torch.manual_seed(0)

# Create a small linear layer with weight and bias attributes
# This is what layer_init expects to modify
layer = nn.Linear(in_features=3, out_features=4)

ARGS = {
    "layer": layer,
    "std": np.sqrt(2),
    "bias_const": 0.0
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Linear — a Linear output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Linear 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
rescale_zero_terminal_snr Ran
ran; our contract draft was wrong, not the code
Owen-Oertell/rlcm/lcm_rl_pytorch/diffusers_patch/lcm_scheduler.py
pointer only (licence: NONE); the stored copy get_code serves, from jabir-zheng/TCD, is pointer only (licence: NONE) · get_code("64b2196de5dcf1e5")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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.

whiten Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
zhaolingao/rebel/src/nectar/rebel.py
code served (permissive licence) · get_code("e78dac11b89dad63")
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 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 a small tensor for testing
values = torch.randn(2, 4)

# Define all parameters
ARGS = {
    "values": values,
    "shift_mean": True,
}
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 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
aesthetic Not yet run
unverified (harvested, no recorded run)
Owen-Oertell/rlcm/lcm_rl_pytorch/rewards/rewards.py
pointer only (licence: NONE) · get_code("44735222f08d757a")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Owen-Oertell/rlcm 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.

evaluate Not yet run
unverified (harvested, no recorded run)
zhaolingao/rebel/src/tldr/rm.py
code served (permissive licence) · get_code("d58b842cdc7fda2b")
How it ran

no invocation recorded.

gather_logprob Not yet run
unverified (harvested, no recorded run)
zhaolingao/rebel/src/ultrafeedback_largebatch/rebel.py
code served (permissive licence) · get_code("b45408e42f101791")
How it ran

no invocation recorded.

truncate_response Not yet run
unverified (harvested, no recorded run)
zhaolingao/rebel/src/nectar/rebel.py
code served (permissive licence) · get_code("62ece7427179dea2")
How it ran

no invocation recorded.

Also present in other papers' code

Of 20 samples lifted from this paper's linked repositories, 20 carry a function identity and 0 do not. Of the 20 distinct functions with an identity, 9 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 4 the same month, 7 later) and 11 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
betas_for_alpha_bar 14 other papers
4 dated earlier, 1 the same month, 8 later, 1 same year, order not determinable
2303.01469 (2023-03)
Consistency Models
2311.15908 (2023-11)
Enhancing Perceptual Quality in Video Super-Resolution through Temporally-Consistent Detail Synthesis using Diffusion Models
2311.18832 (2023-11)
Exploiting Diffusion Prior for Generalizable Dense Prediction
and 11 more not named here
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.08495 (2024-04)
Dataset Reset Policy Optimization for RLHF
2410.18870 (2024-10)
End-to-end Training for Recommendation with Language-based User Profiles
and 1 more not named here
first_true_indices 3 other papers
1 dated earlier, 2 later
2403.17031 (2024-03)
The N+ Implementation Details of RLHF with PPO: A Case Study on TL;DR Summarization
2410.04612 (2024-10)
Regressing the Relative Future: Efficient Policy Optimization for Multi-turn RLHF
2503.13538 (2025-03)
From Demonstrations to Rewards: Alignment Without Explicit Human Preferences
whiten 3 other papers
1 the same month, 2 later
2404.08495 (2024-04)
Dataset Reset Policy Optimization for RLHF
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
generate 2 other papers
1 dated earlier, 1 later
2403.17031 (2024-03)
The N+ Implementation Details of RLHF with PPO: A Case Study on TL;DR Summarization
2503.13538 (2025-03)
From Demonstrations to Rewards: Alignment Without Explicit Human Preferences
get_cosine_schedule_with_warmup 1 other paper
1 later
2410.04612 (2024-10)
Regressing the Relative Future: Efficient Policy Optimization for Multi-turn RLHF
get_reward 1 other paper
1 the same month
2404.08495 (2024-04)
Dataset Reset Policy Optimization for RLHF
rescale_zero_terminal_snr 1 other paper
1 dated earlier
2303.01469 (2023-03)
Consistency Models
truncate_response 1 other paper
1 later
2410.04612 (2024-10)
Regressing the Relative Future: Efficient Policy Optimization for Multi-turn RLHF

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

While originally developed for continuous control problems, Proximal Policy Optimization (PPO) has emerged as the work-horse of a variety of reinforcement learning (RL) applications, including the fine-tuning of generative models. Unfortunately, PPO requires multiple heuristics to enable stable convergence (e.g. value networks, clipping), and is notorious for its sensitivity to the precise implementation of these components. In response, we take a step back and ask what a minimalist RL algorithm for the era of generative models would look like. We propose REBEL, an algorithm that cleanly reduces the problem of policy optimization to regressing the relative reward between two completions to a prompt in terms of the policy, enabling strikingly lightweight implementation. In theory, we prove that fundamental RL algorithms like Natural Policy Gradient can be seen as variants of REBEL, which allows us to match the strongest known theoretical guarantees in terms of convergence and sample complexity in the RL literature. REBEL can also cleanly incorporate offline data and be extended to handle the intransitive preferences we frequently see in practice. Empirically, we find that REBEL provides a unified approach to language modeling and image generation with stronger or similar performance as PPO and DPO, all while being simpler to implement and more computationally efficient than PPO. When fine-tuning Llama-3-8B-Instruct, REBEL achieves strong performance in AlpacaEval 2.0, MT-Bench, and Open LLM Leaderboard.

For agents

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

get_harvested_code_for_paper("2404.16767")
get_code_for_paper("2404.16767")
have("2404.16767")

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

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

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

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

Connect an agent — have() is free.