How it's built
- A Rust daemon supervises the Factorio server, talks to it over RCON and serves a versioned JSON-lines protocol on two Unix sockets, one for the agent and one for the harness.
- The agent reaches the game only through the fac CLI. It runs inside bubblewrap with its own PID and network namespaces and every capability dropped, so it can't see the harness, the repo or the host.
- A Lua mod holds the agent to what a player can do: walking time, reach and the explored map. The game keeps running while the model thinks.
- The harness reads milestones from the game in ticks and scores them against human reference times.
Why
The game runs at normal speed and never pauses for the agent, so time spent thinking is game time lost. An early version paused between commands, which made thinking free and the times unrealistic. Results record game ticks and wall-clock time separately.