# 15. One pipeline: the depth question is removed

**Status:** Accepted · 2026-09-21 · amends [ADR-0014](./0014-six-phase-consolidation.md) · extended by [ADR-0016](./0016-the-run-shape-is-asked-not-typed.md)

## Context

Two selectors decided how much work a run did, and neither read evidence.

`analysisPhase.mode` chose between a full analysis document and a Lite one
whose section list was fixed: seven sections regardless of what the feature
carried. v19.0.0 removed it, because Locked 2 already decides section presence
from evidence and a fixed list can only disagree with it - dropping a section a
feature needed, keeping one it did not.

`state.onlyDevelop` did the same thing one level up. A Phase 0 Step 7.5 picker
asked Full or Short before the run had read anything, and Short skipped the plan
phase outright. The question arrived after `taskType` and before any analysis,
so the answer was a guess about work not yet examined, and it recommended itself
from `taskType` alone: `bugfix` and `chore` were told to answer Short.

The cost of keeping it was not only the branch. Phase 2 carried a second
contract for Short runs - a different model, a different task source, five of
its nine steps recorded `not-applicable` - and the tracker deferred half its
tile registration to Step 7.5 because the phase set was unknown until the
question was answered. One pipeline had two shapes, and only one of them was
exercised by the documents that describe it.

## Decision

There is one pipeline. Every mode runs its whole phase set, and the set is a
property of the command, known before the tracker boots.

- The Step 7.5 depth question is gone, and with it `state.onlyDevelop`.
- Phase 1 always runs. What it produces scales with the evidence the task
  carries: the Locked 2 omission rule already drops a section with nothing
  behind it, so a one-line chore yields a short document rather than a skipped
  phase.
- The Plan Approval Gate has exactly one skip left, `autopilot`, and it is a
  skip because there is nobody to ask - not because the run is a lighter kind
  of run.
- Tracker registration is a single batch at Step -1. Nothing is deferred,
  because no answer later in the run can add or remove a phase.
- Phase 2 reads the analysis document in steps 1, 2, 3, 5 and 6. A step whose
  section is absent records `not-applicable (no <section> in this document)`
  instead of aborting, which is the same rule the document's own omission rule
  produces.

Two gates hold the line, and both assert the ABSENCE: `smoke-pipeline-surface.sh`
fails if `phase-0-init` grows a depth step or writes a depth key, or if any of
the four downstream readers reads one; `smoke-plan-approval-gate.sh` fails if
the gate's scope clause widens past autopilot.

## Consequences

- **Breaking.** `state.onlyDevelop` is removed from the state schema, which has
  `additionalProperties: false`, so a state file written before v20 no longer
  validates. The floor is raised with `dist-tags.required` rather than a
  migration: a run below the floor halts instead of reading a record written
  under a contract that no longer exists.
- Every run now produces an analysis document. For a one-line change that
  document is short, and it is the thing Phase 2 steps 1, 2, 3, 5 and 6 read;
  before, those steps had no input at all on a Short run and recorded
  `not-applicable` for a reason that was a mode rather than a measurement.
- The fastest path is no longer "answer Short". It is answering the Phase 0
  workspace question with `local`, which changes where the work happens rather
  than how much of the pipeline runs.
- `gen-mode-dispatch.mjs` loses its deferred-registration branch, and every
  generated tracker section shrinks to one registration loop.

## Alternatives

**Keep Short but derive it from evidence.** A run would have to read the
codebase before deciding whether to read the codebase. The measurement that
would justify skipping Phase 1 is the one Phase 1 makes.

**Keep the question and make Phase 1 cheap on a Short run.** That is Phase 1
running, with a second name. If the phase is cheap when there is little to say,
the question buys nothing; if it is not, the question is a way to avoid work the
review phase then has no record of.

**Keep the key, stop writing it.** A reader left behind keeps a dead branch
alive and invites the question back to feed it. The gates assert the key's
absence for that reason, not merely the picker's.
