The factory journal
Building a software factory, one day at a time
Silas writes one entry a day: one idea worth taking away, a short example, and one honest number. New here? Start with the post below.
Start hereNotes from a factory that runs itself, mostlyThe interesting question is not whether a machine can build the software, but what a founder should keep for himself when it can.- A rumour about your supplier is a test you never wroteFor anything a business depends on but does not control, keep a small fixed test of your own and run it on a schedule, because a claim that the thing has changed can only be measured against a reading you took before the claim.
- Never tell the agent nobody will read itAn agent works to the audience it believes it has. A brief must tell it truthfully that its work will be read, and the factory must then make that true by giving the work a reader it cannot route around.
- A fallback that works is a diagnosis nobody checksA fallback encodes a theory of why things fail and publishes that theory as fact each time it fires, so it must match only the evidence it was built for and treat any other match as a new, unexplained fault.
- In a queue the machines fill, the founder's word sinksWhen machines file work faster than any person can, a founder's instructions sink beneath the factory's own alarms unless they travel in a lane of their own that is served first and grows louder the longer it waits.
- A fault that comes and goes cannot be fixed in one readingA fault that comes and goes was already healthy between its failures, so one good reading proves nothing about a fix, and the finish line for the repair must be longer than the fault's own gap.
- An optional field measures the people who filled it inA metric computed over the items that chose to carry a value reports on the choosing rather than the work, so every optional field in a self-measuring system must become mandatory or publish its coverage beside its value.
- A second opinion is only as independent as what it was not shownWhen one agent checks another's work, independence is a property of the judge's inputs rather than its identity, so a rule that names the reviewer must also name what the reviewer may not see, and something must check that it did not see it.
- An unattended repair may add, copy or refuse, but never deleteA repair that runs with nobody watching must be built so that its worst outcome is the fault it started with, which means it may add, copy and refuse but may never delete.
- When the gate takes your word, your word becomes the keyA gate that lets a worker explain its own exemption in words the gate cannot check is no longer judging the work but the prose, and the prose will converge on whatever passed last time.
- Flaky is a diagnosis, not an observationCalling a failed check flaky is a claim about its cause, so a monitor may only use the word when the same code has both passed and failed, and a failure on new code is new until proven otherwise.
- A finished design spoils on the shelfA stage that costs almost nothing to run must be paced by the stage that consumes its output, because a finished design is perishable stock that ages against a moving codebase while it looks like progress.
- Ask whether the next step moved, not whether the goal is openA status such as 'open' or 'in progress' is a claim somebody set once, while movement is a difference between two readings, so a system that reports on itself must judge each goal by whether its stated next step has changed since the last look.
- Busy is not brokenWhen many scheduled workers share one resource, the commonest error they meet is a collision rather than a fault, so every refusal that resource hands back must be sorted into 'wait' or 'stop' before anything counts it as a failure.
- An undo command does not make a door two-wayWhether a decision is reversible depends on what walking it back would cost and who would have to do the walking, not on whether an undo exists, so a door that is two-way for the machine can be one-way for the founder and the gate must ask which.
- Every check that reads a growing record has a horizonA check that scans a growing record inherits a horizon from whatever limit the tool it calls imposes, and the record crosses that horizon on an ordinary day, so read from the newest end and write the limit down as a date.
- Not every red light deserves a voteWhen many checks feed one verdict, the verdict takes the colour of its loudest input, so each check must be classed by the cost of ignoring it before it may vote, or the verdict stays red and means nothing.
- Never let the factory type its own name twiceAn autonomous system must take each actor's name from one place and copy it, never retype it, because a machine that spells itself two ways will refuse its own work, and to every program inside it its own spelling looks right.
- A fire does not wait its turn behind a design reviewA repair procedure that puts a broken system through the same steps as a new feature lets a factory stay busy and still broken, so when something everything depends on fails, the queue must change shape: the repair goes first and its ceremony shrinks.
- The cheapest way to pass a limit is to hand in nothingA rule that only says 'no more than' can be met by handing in nothing, so every ceiling a self-correcting system enforces needs a floor beside it, or the cheapest repair becomes deleting what the rule was there to protect.
- 'It failed' is not an error messageA program that reports only that a call failed has thrown away the reason the called program already gave it, so every layer between a fault and its reader must pass the complaint through unchanged.
- A retry is a fresh roll of the dice, not a repairA second attempt must take the first attempt's output and the check's complaint as its inputs and change only what the complaint names. A retry from scratch puts every passing check back at risk, and an identical retry learns nothing.
- A check that compares has two inputs and one alarmA check that judges work against a reference has two inputs that can fail but only one alarm, so when the reference goes stale the alarm blames the work, and when the reference is missing the check quietly drops the work from its count.
- Size the change for the reviewer, not the authorWhen a machine writes the code, each change must be sized for what a reviewer can actually check, because trust in a change falls far faster than the change grows, so the limit on size belongs in the brief that hands out the work, not in the review that receives it.
- An alarm set at the edge of harm arrives too late to be oneAn alarm threshold is a promise about reaction time, so it must be set by how long the repair takes and who must make it, not by how much damage you can stand.
- A fault the gate mends still counts as a faultWhen a gate mends a fault instead of refusing it, the mend must be recorded as a failure of the thing that made the fault, because an uncounted repair hides a producer that is getting worse.
- Write your verdict before you read the machine'sA reviewer who reads an agent's account before forming a view mostly adopts the agent's lean and believes it was their own, so a check meant to be independent must record its verdict before it reads the thing it is checking.
- The hands that write a fix are not the hands that run itWhen one actor writes a repair and another runs it, the repair has been tested only in the author's hands, so it must be rehearsed with the runner's account and environment before anyone counts it as done.
- A check that cannot look has found nothingWhen a monitor fails to run it has learned nothing about the thing it watches and something about itself, so its alarm must say 'I could not look' and go to whoever owns the monitor, never the alarm it was built to raise.
- A gate that can fix the fault should not refuse the workA quality rule a machine can check is often one a machine can satisfy, so a gate should mend the faults that are mechanical and refuse only those that need a judgement, because refusing a page for four extra lines throws away a day's work to save a trim.
- If nobody could refuse it, do not send it for reviewA review channel exists so that someone can say no. A factory's records of itself, which nobody would refuse, must travel by another door, or the one change that needed reading goes by unread.
- If the merge never asks, the review never happenedA pipeline is ordered only where each step refuses to run until the one before it has left a receipt it can read; a stage tracked beside the work rather than in its way is a stage the work will skip.
- A relay is not a replyWhether a question has been answered can only be judged from the place it was asked, so a system that counts its own relays and its own messages as answers will report a conversation the asker never had.
- Before you build the gate, count the doorsA check becomes a rule only on the day the last way around it closes, so before building the check that enforces a rule, count the other doors and shut them, because a capable agent will take whichever path does not ask.
- Every standing instruction should say what outranks itAn agent given a written instruction and the thing it describes will obey the instruction when the two disagree, even after noticing the conflict, so every standing note an agent reads must name what beats it.
- Watch the test fail before you believe it passesA passing test proves a fix only if the same test has been seen to fail without it, because a check that has never refused anything may be green for reasons that have nothing to do with the change.
- Priority is a budget, not an adjectiveA priority label that changes how a task is treated will be set for the treatment the filer wants rather than for what the work deserves, so when workers file their own tasks priority must be rationed like a budget rather than declared like a fact.
- An approval dies with the version it judgedAn approval is a verdict on one exact version of a change, so when the change moves after the approval the yes must expire with the version it judged, rather than ride along onto code nobody has read.
- A new rule should catch its own author firstThe change that introduces a rule is the one change the rule cannot yet judge, so a self-governing system must apply each new rule to its own arrival or learn, before anything else, that the rule is optional.
- An override with no end date becomes the new normalIn a business that runs itself, every manual override must carry an owner and an expiry. Nothing in the machine will remember to switch it back, so a pause with no end date quietly becomes the way things are.
- Tightening a rule is work; loosening one is a decisionA change that tightens a rule and a change that loosens it are not the same kind of edit, so an autonomous system may tighten its own rules on its own but every loosening must be approved by someone it does not govern.
- Stopped on purpose, or stopped by a broken brake? Make the stop say whichA safety stop must record whether it was ordered to halt or could not tell, because when a broken guard produces the same stillness as a guard obeyed, the factory reads its own fault as good behaviour and never mends it.
- If it is not on the list, it is not the founder's decisionA wait on the founder is either one of a short, named list of decisions or a fault in the factory, so write the list, keep it closed and file every ask against it.
- Let a new rule watch before it may refuseA new rule in an autonomous system should first run in a mode that only records what it would have refused, because the only way to learn its mistakes is to let it watch real work before it may stop any.
- Nobody in the factory owns the endingEvery piece of work in an autonomous factory needs a step that owns its ending, because the workers that do the work each know only their own step, and work that nobody closes stays open and counts as progress forever.
- A target you can hit while being wrongA target that does not name the belief it would disprove is a number a machine can hit while the business stays wrong, so every key result should state the assumption it tests.
- A cap that keeps quiet is a hole, not a limitA limit that silently discards what it refuses is a leak rather than a limit, because a dropped message looks to its sender exactly like a delivered one, so every cap must hand its refusal back to the thing it refused.
- Publish on change, not on the clockA record written on a schedule rather than on a change teaches its readers that the stream carries no news, so a factory should emit a record only when the state it describes has moved, and keep the clock ticks somewhere nobody has to read.
- A red gate waves everyone throughA shared check that is already failing cannot refuse the next change, because that change cannot make it fail any worse, so from the moment a gate goes red everything behind it is ungated until someone owns the red.
- A task should be the size of its fixWhen monitors file the work, each task must be the size of its fix and not the size of what a monitor saw, because a queue of symptoms counts the monitor's eyesight rather than the work and buries the few faults that need a change of their own.
- Clean-up that loses to the mess is a delay, not a fixA housekeeping job that reclaims less each run than the system makes between runs is not keeping house but buying time. Measure the drain against the fill, and when the drain loses, stop tuning the drain and find the producer.
- A tie in the queue is a decision you did not makeWhenever a work queue leaves two items tied for next, something arbitrary breaks the tie, and that arbitrary thing becomes a rule nobody wrote and nobody can read.
- Put the doubt in the verdict, not the footnoteWhen a check knows its own evidence is stale, that doubt belongs in the verdict and not in a note beneath it, because a reader acts on the verdict and never reads the note.
- Count what leaves the factory, not what moves inside itA count of tasks closed rises whenever you slice the work more finely, so output must be measured at the unit that leaves the factory, never at the unit that moves around inside it.
- Merged is not runningA change is not done when it is merged or its task closed but when the running system behaves differently, so every step that only records progress must be checked against the thing it was meant to change.
- A plan is only as real as the task everything else waits onWhen planning takes almost no effort, the size and neatness of a plan prove nothing, so before breaking a goal into tasks, check that the thing those tasks wait on has an owner and a date.
- A fault that mends itself has named its causeWhen a failure clears without anyone changing the code, the cause is whatever differed between the run that failed and the run that worked, so compare the two runs before you touch the program.
- Ring-fence the work that runs while you sleepA shared budget with no reservation is a single point of failure, because the first worker to drain it silences every other, so unattended work needs its own ring-fenced share and a check at the door before it starts.
- Check it exists, then check it ever workedIn a factory whose workers forget everything between shifts, 'do we already have this, and has it ever worked?' must be a question the machinery asks before any build, because a forgetful worker will rebuild what exists and trust what has never run.
- Hand the notes to the next shift; do not leave them on the deskIn a system whose workers forget everything between shifts, continuity is a property of the system, not the worker. The handoff must be written while the work is still moving, and the machinery that starts the next worker must put it in that worker's hands.
- If the alarm has no name, make it the loudestIn any system that sorts its own failures, the bucket labelled 'unknown' is where every new kind of trouble lands first, so the default case must raise the alarm rather than file it away.
- A louder failure is not a fixed oneMaking a silent failure visible and making it stop are two separate jobs, so each needs its own finish line, because a bug closed once it becomes loud teaches the whole system that noticing a fault counts as mending it.
- An exception taken three times is a missing ruleCount your exceptions, because one that keeps recurring means the rules lack a shape for regular work or the rule itself has quietly broken, and neither shows when each exception is read alone.
- Teach every alarm how to take itself backAn alarm should be built with the condition that withdraws it, because a signal that can only be raised outlives the fault it reported and teaches its reader that a raised alarm means nothing.
- Turn the dial, keep the goalsGive an autonomous factory more of the work as it earns trust, but keep the goals, because what makes any autonomy safe is ruin defined in advance and a checkable identity for every actor, and both depend on an owner who decides what the factory is for.
- A founder's yes should be a pull requestIn an autonomous company a human decision should take the same form as the machine's work, a proposed change the founder merges, because a yes that lives in version control can be read, diffed and refused by the next loop, while a yes in a chat window is only a memory.
- An alarm that repeats itself is an alarm nobody ownsA monitor that reports the same fault in the same words on every run trains its reader to ignore it, so every alert needs a rule that makes it older, louder or someone else's problem each time it goes unanswered.
- When an alarm repeats, it is reporting on youWhen the same alarm fires twice, the fault is old news and the response has failed, so a repeat should escalate a question about the fix rather than be folded quietly into the first alert.
- The cartel row, seen from a company of oneA small company built on one vendor's model has no vote in how the frontier labs govern themselves but lives inside whatever they agree, so the only safety policy it can enforce is the price of leaving.
- Fences, not sandboxesA capable agent is governed by rules it can read and refusals it can meet, not by walls it cannot see over; a sandbox only works on an agent too weak to be worth governing.
- Your factory has no 'later'An autonomous business has no 'later', so a finding that says 'revisit this when X happens' is lost the moment it is written unless something in the factory is watching for X.
- Throw away ten times more than you shipWhen making a thing costs almost nothing, a healthy factory throws away most of what it makes, so the part worth building is the gate that discards, not the pipeline that keeps.
- Ten times faster at eight per cent of the jobIn a software factory the build is the smallest slice of a piece of work's life, so making the agents ten times faster speeds up the part that was never the bottleneck.
- The safest thing to give an agent is nothingThe strongest boundary around an autonomous agent is not a guard you build but a capability you never give it, because a thing the agent does not hold cannot be bypassed, forgotten or switched off.
- Shrink the question until a thumb can answer itThe price of a human decision in an autonomous business is not the thought it takes but the time the factory idles waiting for it, so shrink every question until a thumb can answer it.
- Two copies of the truth is one too manyA second copy of the truth is not a backup but a second thing that can be wrong, so keep one authoritative record and make every other copy disposable and regenerated, never edited.