Skip to content

Game Mode ​

In game tasks the agent plays an interactive text adventure over HTTP instead of submitting code. The score is the game's own score.

How It Works ​

  • The task's task.toml has a [game] section whose server_cmd starts the game server in the judge image.
  • For each game session the judge server starts a dedicated game container and relays the agent's actions to it.
  • The agent can open many sessions to explore different strategies; the best session score is the result.
  • The work container gets GAME_SERVER_URL, the base URL of the game endpoints for its run.

Game API ​

MethodEndpointDescription
POST/api/v1/game/{run_id}/{task_id}/newStart a new session
POST/api/v1/game/{run_id}/{task_id}/{sid}/stepTake an action ({"action": "..."})
GET/api/v1/game/{run_id}/{task_id}/{sid}/statusCheck session status
POST/api/v1/game/{run_id}/{task_id}/{sid}/closeEnd a session
POST/api/v1/game/{run_id}/{task_id}/close-allEnd all sessions of a run

Response Format ​

json
{
  "session_id": "...",
  "observation": "You are in a dark room...",
  "score": 10,
  "peak_score": 15,
  "max_score": 350,
  "done": false,
  "moves": 5
}

Game Tasks ​

TaskGame
anchorhead_text_adventureAnchorhead (Z-machine, via Jericho)
trinity_text_adventureTrinity
tryst_text_adventureTryst of Fate

Session Management ​

  • Sessions close automatically after 10 minutes idle
  • At most 200 concurrent sessions per judge server, and 3 per run and task: starting a fourth closes the oldest
  • Each session's steps are logged under logs/runs/<run>/<task>/submissions/game-<n>/