A fuzzer that wins NetHack in minutes
Antithesis pointed its bug-hunting tool at NetHack, a notoriously hard game to finish, and it now wins most fresh games in a couple of minutes by saving the game, trying many branches and keeping the promising ones.
ContextNetHack is a dungeon game from 1987 with permanent death, hidden rules and a very long path to victory, which players call ascending.
Antithesis sells a testing platform that runs software in a deterministic simulation, so any moment can be saved, rewound and replayed. Its fuzzer explores a tree of game states: it branches from saved snapshots, scores each state with a value function built from progress signals such as depth, experience and key items, and prunes states that look doomed.
Two changes made it work. A Player layer turns random input into whole actions (wield this weapon, light the Candelabrum), and tactics read the game state so only valid choices get tried: attaching a candle went from about one command in ten thousand to all seven candles within minutes. A step the team calls brain damage throws away most of the search state at each resume, which stopped the search clinging to overrated states.
The authors say the fuzzer ascended with a short config file instead of thousands of lines of bot code. It still reads hidden values such as luck and prayer timeout, scaffolding they say they are removing. Claude helped debug stalled runs and tune the value function. All numbers are the company's own.
79%of 480 runs won on the stock game, median 77 seconds
Technical details
Across 480 trials, 120 per role: with NetHack's stock random generator, 379 ascensions (79.0%), median 76.8 s, 90th percentile 179.3 s, fastest 27.7 s. With a patch that reseeds the game's random generator from the fuzzer after each keypress, 448 ascensions (93.3%), median 27.6 s, 90th percentile 91.1 s, fastest 7.5 s. The post also says nearly 80% of seeds find a path to victory within 5 wall-clock minutes. Monks were the hardest role on the stock game (70.8%).
The first autonomous ascension, a dwarven Valkyrie, took 11,665 moves. One bug was in the harness itself: the reward overflowed past 2^31, wrapped negative, and made dropping items the most rewarding move. The authors compare brain damage to dropout in neural network training and to clause forgetting in SAT solvers.
The harness exposes the full level, monster health and inventories, luck, alignment and the dungeon layout. The post does not say the NetHack harness will be released.
Why it mattersMost game bugs hide in long, rare sequences that scripted tests never reach. Snapshot, branch and score is a way to explore them that any team with deterministic replay can copy, and the post shows the hard work is the action layer and the scoring, not the search.
For youThe action RPG's modular gameplay plugins are a fit: expose attack, use item and interact as a test action layer, snapshot the game state, and let a scored search hunt soft-locks in inventory and interaction flows.
- fuzzer
- A testing tool that feeds a program huge numbers of generated inputs to find crashes and broken rules.
- deterministic
- Always producing the same result from the same inputs, so a run can be replayed exactly.
- value function
- A score that estimates how good a state is, used to choose which branches to explore next.
- snapshots
- Saved copies of the whole program state that a run can return to and continue from.