jev-plays-pokemon-red
Pokemon Red on PyBoy where deterministic code owns the route and arithmetic and Jev picks only at branches, with every battle turn's faint prediction scored by Brier against the…
# jev-plays-pokemon-red
Pokemon Red played by a model that only outputs probabilities. Code reads the Game Boy's
memory into a typed snapshot and hands the model a menu of the moves that are actually
legal; it returns a probability for each one. The bars are those probabilities.
uv run jpp play --rom /path/to/your/red.gb --overlay
That is a real cartridge under PyBoy, not a mockup. The agent walks out of the bedroom,
crosses Pallet Town, takes Charmander from Oak, and wins the rival battle without anyone
touching a key.
## The numbers, and what is still blank
Measured over the calls that were answered on a cartridge, through the Vercel AI Gateway
shim rather than the direct API:
```
479 496 563 679 867 1470 ms median 621, mean 759 (n=6)
about 1.3 decisions/sec, $0.14/hour at ~725 input tokens a call
```
Calibration is **not** published yet, on purpose. The endpoint's free tier serves about
five calls per window, so the longest labelled run so far is n=5 turns with a confidence
interval that covers everything, including the constant predictor. A Brier score on that
sample would be decoration. `uv run measure` prints whatever the run actually supports, a
bad number included, and says when there is nothing to say.
## Why
Claude Plays Pokemon is a large model deliberating tens of seconds a move. This answers a
closed-set question in under a second, so the emulator is the bottleneck instead of the
model.
The catch, up front: it cannot plan. It never sees more than the current decision. Every
route, threshold and piece of arithmetic is ordinary Python, and the model only picks among
actions the code already proved legal. It is also not asked often. Code handles the routine
ticks and only calls Jev where the game actually branches. Between the bedroom