jig-harness/jig
Jig as a software factory · FACTORY.md

One line for every change, kept moving when nobody is there.

Agents open pull requests faster than a team can review them. Each agent session starts cold, forgets what it learned when it ends, and stops only at the checks that exist. When nobody is at the keyboard, the work waits: an assigned item, a review that hit a usage limit, the follow-up a merge owes.

A software factory holds the work. Work enters in a standard form and passes through the same stations and the same checks every time. It comes out measured, so the output stays predictable as the volume grows. This page follows one work item along the line first. Then it shows what runs the line with nobody at the keyboard, how a team decides what to build, and what every station stands on.

The detailed contracts are in the modules: the feature pipeline is M6, the pull-request loop is M7 and the learning loop is M8. The mechanism map says which parts of each station are scripts with no model in them and which are a model deciding. Every term of art is in the glossary.

The same skills, sorted by what a team gets from each: What you get →

a skillan agenta toola personon the roadmap
Stations · the plugin's skillsDeciding what to build
  1. 1Research
  2. 2Requirements
  3. 3Architecture
  4. 4Prototype
  5. 5Plan and file
an epic of planned work items, its ready ones in parallel
The line
  1. 1Pick up
  2. 2Build
  3. 3Open
  4. 4Drive
  5. 5Repair
  6. 6Merge
  7. 7Follow up

The dispatcherstarts stations 1, 4 and 7 when nobody is at the keyboard · a person merges

↺ the learning loop wraps both parts · follow-ups re-enter at 1

Scaffolding · in the repositorywhat every station runs on · most of what Jig provides
ContextWhat an agent knows as it starts and worksM0M3M4M9
VerificationGuides that steer an agent before it acts, and catches that stop what slips throughGuides · before an agent actsM0M6M5M3Catches · what slips throughM1M2M5M7M10
KnowledgeDecisions, facts and lessons kept explicit, versioned and findable, so the next session starts where the last one endedM5M4M8M9M0+ the glossary
Many agents at onceM12M11workspaces that do not collide · measurement of the process
↑ In the repository · JigUnderneath · your platform ↓
  • Parallel workspacesneeds stated inM12
  • Environments and deploymentneeds stated inM10
  • Measurementneeds stated inM11
  • Supply chainneeds stated inM1M7
Figure 1: what a factory of agents runs on. The plugin's skills run the stations at the top, and figure 2 has each one. Under the line runs the dispatcher, which starts a station when nobody does. The stations stand on the scaffolding, whose three jobs Jig's modules build. Jig ends at the solid line: below it, each module states what the repository needs from your platform, so any platform can supply it. The scaffolding in full.

The factory, page by page

  1. 1The linethe stations one work item passes from pickup to follow-up, who runs each and what each hands on, and the pull-request loop they run
  2. 2With nobody at the keyboardthe dispatcher: what it starts every few minutes, what reaches a person, the outcome log and its dashboard, accounts and their usage limits, and what it never does
  3. 3Deciding what to buildthe feature pipeline, from research to an epic of planned work items
  4. 4What it stands onthe jobs a repository's scaffolding does, the modules that build each, and what Jig provides
  5. 5The loop that sharpens ithow a miss a station should have caught becomes a proven check
Every station, and who runs itdeciding what to build, then the line, inside the learning loop
a skillan agent, called by skillsa tool, outside the agenta personon the roadmap · its itemhover any chip for what it does
↻ The loop that sharpens it · M8 · around both parts
Deciding what to build a feature or an epic · the feature pipelineM5M6
On the roadmap: roadmap 3the greenfield kickoff
  1. 1ResearchRun by a skill: explainhands ona dated research note
  2. 2RequirementsRun by a persona personhands onthe PRD
  3. 3ArchitectureRun by a skill: adrhands onthe architecture, with its ADRs
  4. 4PrototypeUI work onlyRun by a skill: design-brief-builderhands onthe accepted prototype
  5. 5Plan and fileRun by a persona personOn the roadmap: roadmap, Laterepic planning on the trackerhands onan epic of planned work items
At every stageadversarial review → iterate until cleared → de-scarRun by a skill: reviewagainst the repository's decisionsRun by a skill: decidea dilemma: ruled, or escalatedRun by a skill: red-teamrequirements and architecture, by personaRun by a persona personaccepts each stage's artifact
hands on an epic of planned work items · each work item enters the line below on its own
The line one work item, from pickup to follow-upM7M9
  1. 1Pick upRun by a skill: do-itemRun by a tool: launcherthe “open in coding agent” button in Linearhands ona branch, a workspace and a plan
  2. 2BuildRun by a skill: do-itemRun by a skill: reviewhands onthe change, reviewed before its first push
  3. 6MergeRun by a persona personOn the roadmap: roadmap 9a converged drive arming the merge it certifiedwould change “a person merges”; decided on its ownhands ona merged pull request
  4. 7Follow upRun by a tool: repository follow-upthe plugin's followup skill unless the repository names its own; started by a person or the dispatcherRun by a skill: followupRun by a persona personStarted by a tool: dispatcherstarts the repository's follow-up commandhands onfollow-up items, back to station 1

The upper rail, at station 6, Merge: a person merges

  • 1Pick up: pickup
  • 4Drive: re-arm · re-drive
  • 7Follow up: follow-up

The dispatcher starts these stations when nobody does, every few minutes. It never merges. ↺ Follow-up items enter the line again at station 1.

↺ misses → lensesevery miss becomes a new check; Run by a skill: reflect records what a session learned, Run by a skill: review-reflections turns it into changes a person approves, Run by a skill: promote-memory promotes session memoryAuditRun by a skill: audit inspects the factory itself: scores every module and, run again, reports what drifted
Figure 2: every station, who runs it and what it hands on, inside the learning loop. Work on the roadmap stays in the figure as a dashed chip with its item. The tinted station is a person's. Under the line run two rails: on the upper one a person merges, and the lower one is the dispatcher, which starts a station when nobody does. Every station stands on the scaffolding in figure 1. Deciding what to build, the line and the dispatcher each have a page.
Deciding what to buildThe line
Who1Research2Requirements3Architecture4Prototype5Plan and file·every stage1Pick up2Build3Open4Drive5Repair6Merge7Follow up
Run by a skill: explainexplain at Research
Run by a skill: adradr at Architecture
Run by a skill: design-brief-builderdesign-brief-builder at Prototype
Run by a skill: reviewreview at every stagereview at Build
Run by a skill: decidedecide at every stage
Run by a skill: red-teamred-team at every stage
Run by a skill: do-itemdo-item at Pick updo-item at Builddo-item at Open
Run by a skill: work-batchwork-batch at Open
Run by a skill: drive-prdrive-pr at Drivedrive-pr at Repair
Run by a skill: resolve-review-commentsresolve-review-comments at Drive
Run by a skill: resolve-conflictsresolve-conflicts at Repair
Run by a skill: fix-cifix-ci at Repair
Run by a skill: followupfollowup at Follow up
Run by an agent: review-arbiterreview-arbiter at Drive
Run by a tool: launcherlauncher at Pick up
Started by a tool: dispatcherthe dispatcher starts Pick upthe dispatcher starts Drivethe dispatcher starts Follow up
Run by a tool: repository follow-uprepository follow-up at Follow up
Run by a persona persona person at Requirementsa person at Plan and filea person at every stagea person at Mergea person at Follow up
on the roadmapLon the roadmap: epic planning on the tracker at Plan and file9on the roadmap: a converged drive arming the merge it certified at Merge
Figure 3: who works where. A row per skill, agent, tool and person, and a column per station. The dispatcher's row marks the stations it starts when nobody does. A dashed cell holds the roadmap item of work to build. Only a person works the Merge column, and delegating that merge is on the roadmap.

This part of the factory hands the line its work:

Deciding what to builda feature or an epicwhat to build, and howaccepted requirements and architecture, decision records, an accepted design, an epic of planned work itemsM5M6
The lineone work itemhow this item gets built and mergeda merged pull request, and filed follow-upsM7M9
The loop that sharpens it, around both parts

A significant miss, one an automated step should have caught, becomes a check (M8). The team classifies the miss, rebuilds it as a test case that replays it, and answers it with an added check. The check gates only once it catches its test cases. Its recall, precision and cost then decide whether it is kept, promoted or removed. So the line gets sharper without anyone watching harder.

The miss → lens flywheel, step by step →

What stays with a person

Jig automates the stations and keeps these decisions with people:

  • Stays with a person: The intent: what to build, and the acceptance of each design stage.
  • Stays with a person: The dilemmas decide escalates, and the review findings a drive marks for a person.
  • Stays with a person: The answer to a parked question, and what to do about a stage that drifts.
  • Stays with a person: The merge. Delegating it, for a repository that chooses to, is on the roadmap.
  • Stays with a person: Promotion to production (M10).
  • Stays with a person: Changes to the scaffolding that agents propose from their own sessions (M8).
What the platform supplies

The machines, environments, deployment and monitoring a factory runs on are not Jig’s. Each module states what the repository needs from them, so any platform can supply it:

  • Parallel workspaces: many agents on one machine without colliding (M12). A team installs the plugin once per machine. It needs no setup per workspace in a tool that starts sessions with the user’s own agent configuration: Herdr, Orca, Conductor and others. A runner with its own configuration directory, a container, or a tool without plugin support needs the setup the plugin describes.
  • Environments and deployment: verify what merged, ship only what was verified, promote by hand, and use disposable preview environments (M10).
  • Measurement: the delivery process emits typed events, so review quality, gate health and cycle time are measured rather than assumed (M11).
  • Supply chain: third-party automation pinned and updated, and dependencies held back by a release cooldown and an install-script allowlist. Secrets are scanned in layers, and reviewers are wired so the change under review cannot alter them (M1, M7).

Each item is a requirement a module states, not a missing feature: Jig names what the repository needs from the platform and stops there.