Trevor PaughSystems engineer
Trevor PaughProject Chronicles

Chronicles / The Factory

One feature in, one pull request out

Design

The Factory was written as a fixed pipeline: a spec-writer, a builder in its own worktree, four reviewers reading in parallel, up to two fix rounds, an approver, then auto-merge or a hold for the owner. The owner decided six rules up front, from which models do which job to the one rule that only they can clear a hold.

Until this week every project’s manager dispatched its own builder and its own reviewers by hand, slice by slice. The Factory replaces that with one fixed pipeline that any manager can hand a feature to.

The line

A feature goes in as a sentence or two. A spec-writer, running on the larger model, turns it into a spec the manager reads and approves. A builder, also on the larger model, works in a worktree of its own and opens the pull request. Then four reviewers read it at once: security and code on the larger model, user experience and visual design on the smaller one, and the last two only when the change touches a screen. Whatever they find goes back to the builder for at most two rounds. An approver checks that the continuous-integration run is green and that the diff stays off a short list of guarded paths each project declares. If everything holds, the pull request merges itself. If not, the job stops and waits.

Six rules the owner set

The owner decided these before the first job ran, and the skill treats them as fixed:

  1. Approval means merge. No one else is asked.
  2. The models are fixed per role. Managers do not pick.
  3. The spec-writer always runs, even for a one-line feature.
  4. Every project’s slices go through it. Hand-dispatch is for spikes and chores only.
  5. A hold is mandatory, not optional, whenever reviews are still open after round two, the integration run is red or still pending, a guarded path is touched, or the approver is unsure.
  6. Only the owner clears a hold, by approving the job as it stands or sending it back with instructions.

What stays with the people

The manager still writes the feature and approves the spec. The owner still clears every hold. Everything between those two points is the machine’s.