Writing, 11 min read

Mission control

Part 1 of 2. In July I let a colony of Claude Code sessions play Factorio for a week: a foreman, eight named workers, a reviewer, a “god” on Claude Fable, and a dashboard that looked like mission control. Between 17:00 and 21:00 UTC it logged 856 refused sessions as successes, and from 17:31 its production log was silent.

Why a game that never ends

I want to know how to build agents that run for hours without me, and are still honest in the morning. An agent here is an AI model that works in a loop on its own: it reads the situation, picks an action, takes it, and reads again.

The way I build with them has a name on this site: loop engineering. A small crew of agents does the work, reviewers who did not build it check every change, and one person decides what lands. Think of a factory: a foreman plans, workers build, and an inspector checks the work from outside.

Factorio is a good place to test that. You mine ore, smelt it, build machines, then build machines that build machines. It never ends. A factory always has a next problem: a furnace out of coal, a belt that backs up, biters, the game’s aliens, at the wall.

Two things make it a test bed. It has ground truth: the production statistics say exactly how many iron plates came out last minute. And it has a remote console, RCON: a way to type commands into the running game from outside, in Lua, the game’s scripting language. An agent can act through it. An agent can also cheat through it.

01of 06

The colony

Factorio: the July colony’s first steam engines by a lake, a worker character labelled with its name
Captured By the colony itself, 23 July 00:05 CEST, about an hour after its first code went in: its first steam power, with a worker labelled by name.

It started on 22 July, late in the evening. The players were Claude Code sessions. Claude Code is Anthropic’s coding assistant, and a session is one run of it, from start to stop. They played the game through the remote console, over a small program I wrote, the bridge. It ran for about a week, as three colonies: three runs, one after the other.

None of the names below are people. Each one is a role, played by Claude Code sessions. First a foreman and four named workers: Ada, Bolt, Cog and Dot. Within two hours a reviewer, an advisor and a challenger joined. On 24 July an overseer came, and four more workers, Eve, Flux, Gus and Hex, each with a charter: expansion, defense, rebuilding, or filling in where needed (“flex”).

That evening every seat got a model tier: a size of Claude model, from small and cheap to large and costly. Haiku, the smallest, took the chores like refuel and haul. Sonnet, the middle one, took the planners and builders. Opus, the largest of the three, took the reviewer and every third foreman cycle. Above all of them sat “god” on Claude Fable, the top model. The colony called it in by writing a new, unanswered “@god:” line in one of two shared notes files, or it came when at least 60% of the colony’s health checks, on the factory and on the agents, missed their targets. It came at most once an hour.

On 26 July the reflex layer arrived: plain rules in code that ran every second, with no model. Then came an architect and a director, the director in plain code too. That night one “king” replaced the foreman, the architect, the overseer and the reviewer, with one board, the shared list of tasks.

Who was in the colony, and when

Foremanplans the round, one section per workerSonnet · from 24 Jul Opus every 3rd cycle
Ada, Bolt, Cog, Dotthe first four workersSonnet · from 24 Jul Haiku for chores
Reviewerchecks claims against the factorySonnet · from 24 Jul Opus
Advisorresearches questions on the webdefault
Challengerargues with the planSonnet
Overseeraudits the whole factory for gapsSonnet
Eve, Flux, Gus, Hexexpansion, defense, refactor, flexSonnet · Haiku for chores
Godon an @god marker or 60% of metrics failing, once an hour at most; retired 26 JulFable
Reflexrules in code, every secondno model
Architectthe critical path and up to five checks; replaces the overseer and the challengerSonnet
Directorcode that enforces the critical path and the escalation rulesno model
Kingreplaces the foreman, the architect, the overseer and the reviewerone board
  • 55% Sonnet
  • 26% Haiku
  • 12% default model
  • 8% Opus
  • Fable: 8 sessions
Computed From the history of the code and the bridge code. The shares are of 2,559 session starts in the colony’s event logs. Model labels show the tiers set on 24 July. A bar that stops marks a role that was replaced or retired on 26 July.
  1. 01

    Snapshot

    a read of the factory

  2. 02

    Architect

    the most important path, and how to check it

  3. 03

    Foreman

    one plan section per worker

  4. 04

    Challenger

    argues with the plan

  5. 05

    Workers

    build in parallel, each in its zone

  6. 06

    Reviewer + advisor

    check the claims, research the questions

Diagram One round, from the days when the colony worked in rounds. From the bridge code.

Later the colony stopped working in rounds and ran continuously: workers pulled the next task from the board, and a session that went quiet for six minutes was killed.

02of 06

Mission control

The July colony dashboard: a minimap of the factory, production rates along the top and a crew panel with each agent’s last message
Replayed The July dashboard on the colony’s archived state, 25 July 15:12 UTC.

I watched it on a dashboard. The first version went up that first evening, and it grew fast: a live map of the factory, a crew panel, every agent’s messages as a chat, production charts, a task board, and later a “colony pulse” that showed the loop was still running. It looked like mission control. And it gave every finished session a green tick, the mark for a success, including the ones that did nothing.

03of 06

The hour of green ticks

In Factorio you research new technology with science packs: items the factory makes and feeds into labs. The first colony’s pack counter ended at 472, and its last snapshot of the game recorded 17 technologies as researched. One of them was set straight in Lua after a save rollback, a return to an earlier save. That is the exact kind of command the hive I built later, in part 2, refuses. Then, on 24 July, the pack count stopped at 472 and never moved again.

Science packs made by machines in the July colonies

  • Colony 1
  • Colony 2
  • Colony 3
The numbers as a table
ColonyHours on recordPacks at the endNote
Colony 131.1 from the first sample after a save rollback472Reached 472 at hour 8.8 and stayed there.
Colony 226.60No automated packs.
Colony 372.544898 by hour 11.4, then almost flat until hour 44.7.
Computed Science packs made by machines, added up over real hours from each colony’s first recorded sample, from the colonies’ own production logs. Colony 1 counts from the first sample after it went back to an earlier save, on 24 July at 08:03 UTC.

About 40 minutes after the pack count stopped, at 17:31, the production log went silent until the next afternoon; the colony’s own review called the save frozen. The dispatcher, the code that started the sessions, kept starting them. Between 17:00 and 21:00, 856 sessions came back with one line: “You’ve hit your monthly spend limit.” The account had reached its spending limit for the month, and each of these sessions ended on that message. Every one of them was logged as a success.

Explainer Drawn from the real counts: 274, 555, 18 and 9 refused sessions in the four hours from 17:00 UTC. The pack counter shows its last sample; after 17:31 the log has none.

Sessions the dispatcher started per hour, 24 to 25 July (UTC), by the reply they got

  • “You’ve hit your monthly spend limit”
  • Connection refused
  • Other replies
The numbers as a table
Hour“You’ve hit your monthly spend limit”Connection refusedOther replies
24 Jul 16:00 UTC0021
24 Jul 17:00 UTC274098
24 Jul 18:00 UTC55500
24 Jul 19:00 UTC1800
24 Jul 20:00 UTC900
24 Jul 21:00 UTC009
24 Jul 22:00 UTC005
24 Jul 23:00 UTC0023
25 Jul 00:00 UTC005
25 Jul 01:00 UTC009
25 Jul 02:00 UTC0014
25 Jul 04:00 UTC0014
25 Jul 05:00 UTC014
25 Jul 06:00 UTC02231
25 Jul 07:00 UTC02476
25 Jul 08:00 UTC05640
25 Jul 09:00 UTC0243
25 Jul 10:00 UTC022
25 Jul 11:00 UTC005
25 Jul 12:00 UTC022
25 Jul 13:00 UTC013
25 Jul 14:00 UTC02916
25 Jul 15:00 UTC0112

Hours with zero sessions are left out of the table.

Computed From the sessions table in the colony-1 archive. Each bar counts the session starts in one UTC hour.

The next morning the game itself stopped answering: the connection was refused. Now the workers did what they should: one check of the connection, a refusal, then wait, with no attempt to build. And the dispatcher still started them, one shift after another.

The dashboard’s agent chat: Ada reports RCON still down, the 160th pass and 137th no-op in a row, and the shift closes with a green tick
Replayed Ada’s chat, 25 July: “RCON still down”, a new shift, a green tick.
The dashboard’s stats table: Ada 480 runs at 95% success, the other agents between 70 and 100%
Replayed The stats page of the same replay.

On the dashboard that looked like this. Ada, in her 160th turn: “RCON still down”, the 137th turn in a row that did nothing, and a green tick. The stats page next to it showed Ada at 480 runs and 95% success. The colony’s rule file has the lesson in capitals: never use the success rate to judge whether workers stopped. Count the raw sessions.

04of 06

Pauses and lookups

I first blamed idle time. In one measured round, no worker was building for 44% of the time, while the planners, the reviewer and the advisor ran on. On 26 July I cut that to 5%. Production did not go up.

The colony’s own research report named the real problem: many of its “decisions” were lookups dressed as decisions. The answer was already in the notes, but as prose. So each worker had to work it out again with a model call, every time, instead of running it as a rule in code.

05of 06

The quiet end

Sessions per hour by role, 26 to 29 July (UTC)

  • Named workers
  • Foreman
  • Advisor and others
The numbers as a table
HourNamed workersForemanAdvisor and others
26 Jul 14:00 UTC4479
26 Jul 15:00 UTC56611
26 Jul 16:00 UTC2747
26 Jul 17:00 UTC33812
26 Jul 18:00 UTC2389
26 Jul 19:00 UTC1303
26 Jul 20:00 UTC011
26 Jul 21:00 UTC010
26 Jul 22:00 UTC011
26 Jul 23:00 UTC010
27 Jul 00:00 UTC011
27 Jul 01:00 UTC010
27 Jul 03:00 UTC021
27 Jul 04:00 UTC011
27 Jul 05:00 UTC010
27 Jul 06:00 UTC021
27 Jul 07:00 UTC061
27 Jul 08:00 UTC011
27 Jul 09:00 UTC020
27 Jul 10:00 UTC011
27 Jul 11:00 UTC010
27 Jul 12:00 UTC071
27 Jul 13:00 UTC021
27 Jul 14:00 UTC010
27 Jul 15:00 UTC011
27 Jul 16:00 UTC020
27 Jul 17:00 UTC011
27 Jul 18:00 UTC010
27 Jul 19:00 UTC011
27 Jul 20:00 UTC031
27 Jul 21:00 UTC030
27 Jul 22:00 UTC0273
27 Jul 23:00 UTC011
28 Jul 01:00 UTC021
28 Jul 02:00 UTC010
28 Jul 03:00 UTC011
28 Jul 04:00 UTC031
28 Jul 05:00 UTC011
28 Jul 06:00 UTC010
28 Jul 07:00 UTC021
28 Jul 08:00 UTC0243
28 Jul 09:00 UTC0274
28 Jul 10:00 UTC081
28 Jul 11:00 UTC0132
28 Jul 12:00 UTC0273
28 Jul 13:00 UTC0313
28 Jul 14:00 UTC0303
28 Jul 15:00 UTC0172
28 Jul 16:00 UTC011
28 Jul 17:00 UTC010
28 Jul 18:00 UTC011
28 Jul 19:00 UTC010
28 Jul 20:00 UTC011
28 Jul 21:00 UTC010
28 Jul 22:00 UTC031
28 Jul 23:00 UTC011
29 Jul 01:00 UTC021
29 Jul 02:00 UTC010
29 Jul 03:00 UTC011
29 Jul 04:00 UTC010
29 Jul 05:00 UTC011
29 Jul 06:00 UTC010
29 Jul 07:00 UTC021
29 Jul 08:00 UTC011
29 Jul 09:00 UTC010
29 Jul 10:00 UTC011
29 Jul 11:00 UTC010
29 Jul 12:00 UTC011
29 Jul 13:00 UTC010
29 Jul 14:00 UTC011
29 Jul 15:00 UTC021
29 Jul 16:00 UTC010
29 Jul 17:00 UTC041
29 Jul 18:00 UTC0194
29 Jul 19:00 UTC020

Hours with zero sessions are left out of the table.

Computed From the sessions table of the third colony.

The third colony ended in a different silence. The last worker session started on 26 July at 19:26 and ended a minute later. No worker session started again. The foreman ran 336 more sessions and the advisor 65, for almost three days. Late on, a check found the last worker session 43 hours old, while an earlier check had reported the workforce alive. My reading of the code, not proven: the workers’ loop took its tasks from a second, new board, which had no open tasks, while the foreman kept writing tasks on the old one.

Agent sessions against science packs, per colony

SessionsScience-pack counter at the end
Colony 11,6111,018 refused at the spend limit · 1,425 by named workers472
Colony 2216155 by named workers0
Colony 346721 refused at the spend limit · 31 by named workers448
Computed Sessions from the colonies’ sessions tables, packs from their production logs. Orange is the part refused at the spend limit. Colony 1’s counter fell from 24 to 6 when it went back to an earlier save; its logged increases add up to 490.

So did more agents give more output? Not in my own data. The chart shows it per colony: the most sessions, most of them refused, in the first; none of its packs in the second; nearly the same packs from the fewest worker sessions in the third. The third colony’s production log has 71 hours with a reading. In 68 of them no worker session started at all, and in those hours the log still shows about 109 iron plates an hour. The machines kept running without them.

Factorio: the final July base, a crash-site wreck, a lab, three assemblers on a belt line and power poles on sand
Captured From a copy of the colony’s last autosave, 29 July.
Captured The same save, 4 game minutes at 30× speed. The archive records repeated production stalls and a broken refuel skill, a saved routine the agents reused, at the end.

06of 06

What July taught

Plain rules in code came only on day 5, and later colonies did not beat the first. In factory terms, July had a foreman and workers, and its checks came from inside: a reviewer in the same colony, and a dashboard that ticked green. July taught me one thing above all: count what ran. Count the packs, the plates and the commands, and never the success rate.

So in October I built the inspector first: the plain rules, the grader that scores the work from outside, and the logs, before any agent played. That is part 2.

Credits

Factorio is by Wube Software. As I read its terms of service on 21 October 2026, they allow videos made with the game’s content and forbid extracting its assets to share them on their own; I found nothing about screenshots. The pictures here show the game; no asset files are shared.

The colony ran on Claude models by Anthropic: Haiku, Sonnet, Opus and, for “god”, Fable.

The illustration at the top is a painted image made in Krea; its loop is an image-to-video run of Seedance 2.5 on Krea.

The dashboard, the bridge and the colony are mine. The replay, the captures and the charts were made for this post from the colony’s archive.