Papers › TTRL: Test-Time Reinforcement Learning

TTRL: Test-Time Reinforcement Learning

22 Apr 2025arXiv:2504.16084archive 2025-07-28

Yuxin Zuo, Kaiyan Zhang, Shang Qu, Li Sheng, Xuekai Zhu, Biqing Qi, Youbang Sun, Ganqu Cui, Ning Ding, BoWen Zhou

This paper investigates Reinforcement Learning (RL) on data without explicit labels for reasoning tasks in Large Language Models (LLMs). The core challenge of the problem is reward estimation during inference while not having access to ground-truth information. While this setting appears elusive, we find that common practices in Test-Time Scaling (TTS), such as majority voting, yield surprisingly effective rewards suitable for driving RL training. In this work, we introduce Test-Time Reinforcement Learning (TTRL), a novel method for training LLMs using RL on unlabeled data. TTRL enables self-evolution of LLMs by utilizing the priors in the pre-trained models. Our experiments demonstrate that TTRL consistently improves performance across a variety of tasks and models. Notably, TTRL boosts the pass@1 performance of Qwen-2.5-Math-7B by approximately 159% on the AIME 2024 with only unlabeled test data. Furthermore, although TTRL is only supervised by the Maj@N metric, TTRL has demonstrated performance to consistently surpass the upper limit of the initial model, and approach the performance of models trained directly on test data with ground-truth labels. Our experimental findings validate the general effectiveness of TTRL across various tasks, and highlight TTRL's potential for broader tasks and domains. GitHub: https://github.com/PRIME-RL/TTRL

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2504.16084")

Code

Syntology Ran 7 of 16 code samples harvested from 1 repository linked to this paper; 9 have no recorded run. Of those that ran: 7 ran with no contract checked.

By repository: official repository: 16 samples from 1 repository, 7 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

prime-rl/ttrl officialmentioned in papermentioned on GitHubpytorchMIT report
tsinghuac3i/awesome-rl-reasoning-recipes officialmentioned in papermentioned on GitHubMIT report
qingyangzhang/empo mentioned on GitHubpytorch report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

16 samples harvested; 7 ran; 0 honoured the contract we drafted; 9 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

7ran
9unverified

Licence: 0 of the 16 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from prime-rl/ttrl. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

compute_ce_dpo_loss_rm prime-rl/ttrl/verl/recipe/prime/prime_core_algos.py official repository ran MIT (permissive) · f220595adfc5e83c · report
compute_detach_dpo_loss_rm prime-rl/ttrl/verl/recipe/prime/prime_core_algos.py official repository ran MIT (permissive) · 4d91e4383716e42c · report
compute_online_dpo_loss prime-rl/ttrl/verl/recipe/spin/core_algos.py official repository ran MIT (permissive) · f19825983a523003 · report
compute_onlinedpo_pref prime-rl/ttrl/verl/recipe/spin/core_algos.py official repository ran MIT (permissive) · 41b6e81dc3ecba79 · report
generate_config_from_args prime-rl/ttrl/verl/verl/model_merger/base_model_merger.py official repository ran MIT (permissive) · 9c496dae615ba2a8 · report
get_kl_controller prime-rl/ttrl/verl/recipe/spin/core_algos.py official repository ran MIT (permissive) · 757d109d90121142 · report
reward_func prime-rl/ttrl/verl/recipe/r1/reward_score.py official repository ran MIT (permissive) · c30b2a96103abd2c · report
apply_original_gt prime-rl/ttrl/verl/verl/trainer/ppo/ttrl_utils.py official repository unverified MIT (permissive) · a5a4390c25526df6 · report
handle_base prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/grader.py official repository unverified MIT (permissive) · bb175bff1060d928 · report
is_digit prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/grader.py official repository unverified MIT (permissive) · 2a180d3156997924 · report
mathd_normalize_answer prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/math_utils.py official repository unverified MIT (permissive) · 3f78ce44e20c50d1 · report
normalize prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/grader.py official repository unverified MIT (permissive) · 1e5adbd8b9d51c04 · report
normalize_answer prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/math_normalize.py official repository unverified MIT (permissive) · 31113f93a6e0e98a · report
normalize_final_answer prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/math_utils.py official repository unverified MIT (permissive) · 5662e5ee755b541c · report
select_top_k_per_prompt prime-rl/ttrl/verl/verl/trainer/ppo/ttrl_utils.py official repository unverified MIT (permissive) · 50e288f719695c06 · report
timeout_ours prime-rl/ttrl/verl/verl/utils/reward_score/ttrl_math/math_utils.py official repository unverified MIT (permissive) · bc7d12a7bef2d7e8 · report

Tasks

MathReinforcement LearningReinforcement Learning (RL)reinforcement-learning

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections