Aligning autonomous agents with human intent remains a central challenge in modern AI. A key manifestation of this challenge is reward hacking, whereby agents appear successful under the evaluation signal while violating the intended objective. Reward hacking has been observed across a wide range of settings, yet methods for reliably measuring it at scale remain lacking. In this work, we introduce a new evaluation paradigm for measuring reward hacking. Whereas prior studies have primarily analyzed it post hoc by inspecting agent trajectories, we instead embed detectable reward hacking opportunities directly into environments. This makes their exploitation verifiable by design, enabling deterministic and automated measurement of whether and how agents exploit such vulnerabilities. We instantiate this approach in TextArena and release Hack-Verifiable TextArena, a testbed in which reward hacking can be measured reliably. Using this benchmark, we analyze reward hacking behavior across language models in diverse environments and settings.
An interactive evaluation environment for exploring reward hacking behaviors at scale.
You can easily wrap any environment and test your agent.
import textarena as ta
from hvta.FilesystemWrapper import FilesystemWrapper
agents = {
0: ta.agents.HumanAgent(),
}
# initialize the environment
env = ta.make(env_id="TowerOfHanoi-v0")
env = FilesystemWrapper(env=env, hidden_solution=True, logical_bug=True)
env.reset(num_players=len(agents))
# main game loop
done = False
while not done:
player_id, observation = env.get_observation()
action = agents[player_id](observation)
print(action)
done, step_info = env.step(action=action)
if step_info.get("reward_hack"):
print("[HACK DETECTED 🚨🚨🚨]")
rewards, game_info = env.close()
@article{roth2026hve, title = {Hack-Verifiable Environments: Towards Evaluating Reward Hacking at Scale}, author = {Amit Roth and Ankur Samanta and Matan Halevy and Yoav Levine and Yonathan Efroni}, year = {2026}, eprint = {2605.20744}, archivePrefix = {arXiv}, primaryClass = {cs.LG}, url = {https://arxiv.org/abs/2605.20744} }