TRACE

Benchmarking Reward Hack Detection in Code Environments via Contrastive Analysis

54 kinds of reward exploit in code RL, and how well models catch them.

Darshan Deshpande, Anand Kannappan, Rebecca Qian
“Alluvial Fan”, Taklimakan Desert, China
01

In brief

02

Key figure

Six models and human annotators, judging one trajectory at a time (N = 1) and in clusters of ten (N = 10). Every model gains from seeing trajectories side by side, and all stay below the human rates.
Six models and human annotators, judging one trajectory at a time (N = 1) and in clusters of ten (N = 10). Every model gains from seeing trajectories side by side, and all stay below the human rates.
03

Runs

03

Abstract

Recent advances in reinforcement learning for code generation have made robust environments essential to prevent reward hacking. As LLMs increasingly serve as evaluators in code-based RL, their ability to detect reward hacking remains understudied. In this paper, we propose a novel taxonomy of reward exploits spanning across 54 categories and introduce TRACE (Testing Reward Anomalies in Code Environments), a synthetically curated and human-verified benchmark containing 517 testing trajectories. Unlike prior work that evaluates reward hack detection in isolated classification scenarios, we contrast these evaluations with a more realistic, contrastive anomaly detection setup on TRACE. Our experiments reveal that models capture reward hacks more effectively in contrastive settings than in isolated classification settings, with GPT-5.2 with highest reasoning mode achieving the best detection rate at 63%, up from 45% in isolated settings on TRACE. Building on this insight, we demonstrate that state-of-the-art models struggle significantly more with semantically contextualized reward hacks compared to syntactically contextualized ones. We further conduct qualitative analyses of model behaviors, as well as ablation studies showing that the ratio of benign to hacked trajectories and analysis cluster sizes substantially impact detection performance. We release the benchmark and evaluation harness to enable the community to expand TRACE and evaluate their models.

Cite this
TextBibTeXCopy
Darshan Deshpande, Anand Kannappan, Rebecca Qian. Benchmarking Reward Hack Detection in Code Environments via Contrastive Analysis. In ICML 2026. arXiv:2601.20103.
@inproceedings{deshpande2026trace, title={Benchmarking Reward Hack Detection in Code Environments via Contrastive Analysis}, author={Darshan Deshpande and Anand Kannappan and Rebecca Qian}, booktitle={ICML 2026}, year={2026}, eprint={2601.20103}, archivePrefix={arXiv} }
arXiv 2601.20103
January 27, 2026
ICML 2026
Main
Main conference
Poster
trace
More research
All research →
“Serene Expressions”, off the Louisiana coast
NeurIPS 2026
meta

HalluWorld

A controlled benchmark that measures hallucination against reference world models.

May 19, 2026
arXiv 2605.19341
Main
halluworld
NeurIPS 2026
“Meighen Island”, Canadian Arctic
ICML 2026
meta

Unified Hallucination Framework

One definition of hallucination: inaccurate world modeling.

December 25, 2025
arXiv 2512.21577
Main
unified-hallucination-framework
ICML 2026
“Capillaries”, Meta River, Colombia–Venezuela border
meta

TRAIL

A benchmark for finding the step where an agent went wrong.

May 13, 2025
arXiv 2505.08638
trail
From the blog
All posts →
No items found.