Skip to content

Autopilot

The autopilot is the repo shipping without its architect in the room: a scheduled Routine fires a fresh agent session each morning, the session runs the /autopilot skill end to end, and the day ends as one reviewable PR plus a set of filed issues. The slice workflow is unchanged inside the day; what changes is where its one human gate is paid (ADR-0138).

The slice workflow’s Define stage is a hard gate: no branch until the issue exists and the architect has approved its scope. That gate assumed a present architect; unattended, it deadlocks. ADR-0138 resolves it without weakening the boundary:

  • For a slice the autopilot scopes itself, it files the definition issue in the /define-work shape, marks it Mode: autopilot (ADR-0138), and proceeds. The architect’s approval moves to the PR: approving and merging is the accept, closing is the veto, a review comment is the redirect (the autopilot answers and pushes).
  • The ship-review stays the approval artifact, front-loading the two lines the architect reads first (Decisions I need from you; Risk), so the veto window is real, not ceremonial.
  • The autopilot never merges. Merge is the architect’s, always.
  1. Reconcile. Open autopilot PRs (found by their marker line) are driven back to green first: conflicts merged out, red CI root-caused, review comments implemented or answered. A green PR waiting only on the architect is left alone. PRs without the marker belong to the architect and are never touched, with one exception: a PR or epic the architect has explicitly handed over (the direction recorded as a marker comment on it) is adopted, and the autopilot drives it like its own from then on. Two or more autopilot PRs still open means today is a maintenance day: drive them, triage the issue list, file what the sweep finds, no new branch.

  2. Choose. The first rung that applies: an in-progress feature loop resumes; an architect-approved definition starts its loop; an open Bug by board priority gets its fix, regression test first; else the autopilot scopes the next thin cut itself and files the marked definition. Approved definitions always outrank self-scoping, which is the main steering lever.

    A branch another session owns is skipped, never adopted. An idle session (a rate limit, a long review) can leave an unpushed branch that looks abandoned; once the autopilot copied one, shipped it, and opened a second PR for the same issue while the original session opened a third. So before it resumes or adopts any existing branch or worktree, it runs scripts/branch-owned.sh <branch>, which prints owned <reason> or free. A branch is owned when it is checked out in a locked worktree (the harness locks a live session’s), when a claim file sits beside its worktree (the hook for a harness that exposes session claims; a missing file is no claim), or when its tip commit or any file in its worktree changed inside the window (24 hours; AUTOPILOT_OWNED_WINDOW_HOURS overrides). An owned candidate is passed over and the next rung fires. When the autopilot does adopt a free branch it did not create, it comments on the issue first and says so in the PR body. The day report names every branch skipped as owned and why.

  3. Build. The normal lifecycle: worktree off origin/main, the failing test first, green commits, docs with everything, primitive first. Any operator surface takes the /assess-ui visual gate (the state matrix captured against the real console and graded, not glanced at). Anything found out of scope becomes an issue via /file-bug, never a TODO or a drive-by fix. The slice goes In Progress on the board as its worktree is cut.

  4. Ship. The full /ship-slice pass, then the PR: conventional title, the ship-review as the body, closes #NNN, and the marker line last. The session subscribes to the PR’s activity and arms an hourly check-in until merge or close. It never enables auto-merge or queues its own PR: the architect’s merge, made by putting the PR in the merge queue, is the approval (ADR-0859). The slice’s issue goes In Review on the board as the PR opens.

  5. Report. A closing comment on the slice issue and a day report: what shipped, what needs a decision, every issue filed, the day’s board moves, what tomorrow will likely pick.

Self-scoping excludes the sharp edges: the two authorization layers, the migration rules, the audit contract, breaking API changes, dependency majors. Wanting one of those, the autopilot files the definition, leaves it awaiting a human approval comment, and picks something else for the day. Red gates are never bypassed and never shipped: a day that cannot go green ends as a pushed branch, an annotated issue, and an honest report.

The architect steers without attending:

  • Pre-approve definitions. An approval comment on a /define-work issue makes it tomorrow’s work, ahead of anything the autopilot would choose.
  • Set board priority on Bug issues; the autopilot takes High before Medium.
  • Review the PRs. Comments are implemented or answered; a close is a respected veto.
  • Hand it existing work. A direction on a PR or epic (given in session and recorded there as a marker comment) makes that work autopilot-driven until it merges or closes.
  • Find its work by searching issues and PRs for ADR-0138 (the marker line).
  • Pause or retime it by disabling or editing the Routine; delete it and the autopilot simply never wakes again.

One scheduled trigger, owned by the architect’s Claude account: daily at 11:00 UTC (early morning Mountain time), each firing a fresh session with completion notifications on. The session runs on the architect’s own worker machine, reached through a Remote Control bridge environment, rather than in a cloud sandbox: the gates (Docker for the testcontainers, the pinned protoc pair, the Playwright browser for /assess-ui) run on a host the architect provisions once, and the session works in the machine’s standing clone of the repo. The worker has to be up, with the bridge connected, when the Routine fires; a day it is not is a day the autopilot does not wake.

The worker needs, beyond Go, Outpost, and Docker: an authenticated gh with the gh image extension (a bridge session reaches GitHub through gh, not the cloud sandbox’s MCP tools), the d2 binary for any docs diagram, and the Playwright Chromium (cd web && pnpm exec playwright install chromium).

The prompt is intentionally thin, so the behavior lives in the versioned skill rather than in trigger config:

Omniglass autopilot: ship today's slice. Work in the hyperscaleav/omniglass clone in
this environment. Read CLAUDE.md, then invoke the /autopilot skill and follow it end
to end: reconcile the standing autopilot PRs, select one thin slice by the ADR-0138
order, build it through the full gates (test-first, docs-with-everything, /assess-ui
for any operator surface, /adversarial-review, /ship-slice), open the PR with the
ship-review as its body, subscribe to its activity, file an issue for every defect or
deferral met along the way, and end with the day's report. Never merge to main; the
architect approves PRs.

Changing what the autopilot does is a PR against the skill; changing when it runs is a Routine edit. That split is deliberate: the contract is reviewable history, the schedule is a dial.