Examples/air hockey

air hockey

Created from a prompt

OpenCode (DeepSeek V4 Pro via OpenRouter) in a Vercel Sandbox. Starter only (AGENTS.md, serve.py, player/, helpers/dom/view_kit). No hardcoded demo code. The host keyboard now reads observation.inputs; this snapshot declares those keys and no longer captures the keyboard itself.

2026-10-15 · task UPxovTkU3sCG · opencode · openrouter/deepseek/deepseek-v4-pro-0813

The prompt

Build an air hockey table I can play with the keyboard. I push my mallet with the usual movement keys, and I can hold still. The point is to get the puck into the other slot and keep it out of mine.

The other mallet is not a copy of mine. Different rounds change the table. One has a single big block I have to go around or bank past. One has several circles and boxes in the way. One has a smaller mallet that tries to score on me. One is defense: several pucks, and I have to keep them out of my slot. Sometimes the table is turned, so my goal is not always at the bottom.

Show the rink, the pieces, which slot is mine, and the score. The same round should start the same way every time.

Live environment

Running the prompt-created workspace on this machine — not a mock. Save an episode, then open Replay below to scrub the timeline.

opening · 0 ms

Generated workspace

Exact files the agent wrote — not rewritten by hand.

# AI : shared Action contract — the page posts {"move": "..."}; keep this shape.
from pydantic import BaseModel


class Action(BaseModel):
    move: str