@gtrabanco/pi-agentic-workflow 0.13.3 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -9
- package/dist/conductor/closeout.d.ts +18 -0
- package/dist/conductor/closeout.js +24 -0
- package/dist/conductor/decide.d.ts +25 -0
- package/dist/conductor/decide.js +104 -0
- package/dist/conductor/index.d.ts +16 -0
- package/dist/conductor/index.js +15 -0
- package/dist/conductor/invoke.d.ts +15 -0
- package/dist/conductor/invoke.js +59 -0
- package/dist/conductor/loop.d.ts +25 -0
- package/dist/conductor/loop.js +236 -0
- package/dist/conductor/sensor.d.ts +12 -0
- package/dist/conductor/sensor.js +150 -0
- package/dist/conductor/snapshot.d.ts +13 -0
- package/dist/conductor/snapshot.js +60 -0
- package/dist/conductor/types.d.ts +248 -0
- package/dist/conductor/types.js +47 -0
- package/dist/conductor/urgency.d.ts +16 -0
- package/dist/conductor/urgency.js +70 -0
- package/dist/config/merge.js +21 -1
- package/dist/config/schema.js +45 -2
- package/dist/config/types.d.ts +22 -0
- package/dist/config/types.js +7 -0
- package/dist/extension/conductor-command.d.ts +23 -0
- package/dist/extension/conductor-command.js +93 -0
- package/dist/extension/factory.js +6 -1
- package/dist/routing/types.d.ts +2 -0
- package/dist/routing/types.js +2 -0
- package/dist/runtime.d.ts +45 -0
- package/dist/runtime.js +62 -0
- package/package.json +4 -2
- package/skills/audit-docs/SKILL.md +6 -5
- package/skills/audit-pr/SKILL.md +1 -1
- package/skills/audit-pr/references/PORTABILITY.md +1 -1
- package/skills/execute-phase/SKILL.md +207 -116
- package/skills/execute-phase/references/DESCOPE.md +22 -18
- package/skills/execute-phase/references/EXECUTION_CONTRACT.md +69 -77
- package/skills/execute-phase/references/FOLDING.md +34 -47
- package/skills/execute-phase/references/PREFLIGHT.md +103 -114
- package/skills/execute-phase/references/PRE_EXECUTION_GATE.md +53 -60
- package/skills/init-workspace/SKILL.md +35 -5
- package/skills/init-workspace/references/BOOTSTRAP_DISCOVERY.md +5 -5
- package/skills/init-workspace/references/BOOTSTRAP_WRITE.md +15 -8
- package/skills/init-workspace/references/PORTABILITY.md +1 -1
- package/skills/init-workspace/references/UPGRADE.md +17 -7
- package/skills/log-session/SKILL.md +4 -3
- package/skills/orchestration-envelope/references/TURN_CONTRACT.md +1 -1
- package/skills/pre-execution-review/references/LEDGERS.md +39 -39
- package/skills/pre-execution-review/references/POLICY.md +1 -0
- package/skills/review-change/SKILL.md +1 -1
- package/skills/review-change/references/PORTABILITY.md +1 -1
- package/skills/unit-lane/SKILL.md +154 -0
- package/skills/unit-lane/references/DESIGN.md +35 -0
- package/skills/unit-lane/references/DOCS.md +36 -0
- package/skills/unit-lane/references/EVIDENCE.md +34 -0
- package/skills/unit-lane/references/IMPLEMENT.md +45 -0
- package/skills/unit-lane/references/PLAN.md +38 -0
- package/skills/unit-lane/references/RELEASE.md +45 -0
- package/skills/unit-lane/references/RESEARCH.md +37 -0
- package/skills/unit-lane/references/REVIEW.md +45 -0
- package/skills/unit-lane/references/STEPS.md +23 -0
- package/skills/unit-lane/references/TESTS.md +32 -0
- package/skills/workflow-status/references/ENVELOPE_FIELDS.md +5 -6
- package/skills/workflow-status/references/SENSOR_CORE.md +16 -20
- package/skills/workflow-status/references/SENSOR_SIGNALS.md +5 -7
- package/skills/design-feature/SKILL.md +0 -231
- package/skills/design-feature/references/INTERVIEW.md +0 -74
- package/skills/design-feature/references/PORTABILITY.md +0 -15
- package/skills/design-feature/references/REPAIR.md +0 -88
- package/skills/design-feature/references/UPSERT_EXAMPLE.md +0 -8
- package/skills/design-feature/references/WRITE_AND_UPSERT.md +0 -115
- package/skills/evidence-grounding/SKILL.md +0 -174
- package/skills/evidence-grounding/references/DELEGATION.md +0 -131
- package/skills/evidence-grounding/references/READINESS.md +0 -130
- package/skills/evidence-grounding/references/ROWS.md +0 -93
- package/skills/execute-phase/references/BATCH_AND_PORTABILITY.md +0 -57
- package/skills/execute-phase/references/CLOSEOUT.md +0 -77
- package/skills/execute-phase/references/HANDOFF.md +0 -21
- package/skills/execute-phase/references/OPPORTUNISTIC_FINDING.md +0 -45
- package/skills/execute-phase/references/UNIT_LOOP.md +0 -88
- package/skills/execute-phase/references/WORKFLOWS_FEATURE.md +0 -37
- package/skills/execute-phase/references/WORKFLOWS_FIX.md +0 -43
- package/skills/execute-phase/references/WORKFLOWS_LEGACY.md +0 -26
- package/skills/execute-phase/references/WORKFLOWS_SMALL_PHASED.md +0 -38
- package/skills/generate-docs/SKILL.md +0 -145
- package/skills/generate-docs/references/ADAPTERS.md +0 -15
- package/skills/generate-docs/references/ADAPTER_DISCOVERY.md +0 -33
- package/skills/generate-docs/references/GENERATION_PROCESS.md +0 -90
- package/skills/implementation-discovery/SKILL.md +0 -209
- package/skills/plan-feature/SKILL.md +0 -208
- package/skills/plan-feature/references/ROUTING.md +0 -155
- package/skills/plan-feature-from-issue/SKILL.md +0 -162
- package/skills/plan-feature-scaffold/SKILL.md +0 -112
- package/skills/plan-feature-scaffold/references/SCAFFOLD_PROCESS.md +0 -122
- package/skills/plan-fix/SKILL.md +0 -161
- package/skills/plan-fix/references/PLANNING_PROCESS.md +0 -148
- package/skills/plan-fix/references/SPEC_CONTRACT.md +0 -22
- package/skills/planning-preflight/SKILL.md +0 -130
- package/skills/replan-findings/SKILL.md +0 -131
- package/skills/replan-findings/references/PHASE_APPEND.md +0 -89
- package/skills/review-plan/SKILL.md +0 -154
- package/skills/review-plan/references/CHECKS.md +0 -111
- package/skills/review-plan/references/ENG-CHECKS.md +0 -30
- package/skills/review-plan/references/OUTPUT.md +0 -166
- package/skills/review-spec/SKILL.md +0 -145
- package/skills/review-spec/references/CHECKS.md +0 -108
- package/skills/review-spec/references/OUTPUT.md +0 -160
- package/skills/ship-roadmap/SKILL.md +0 -120
- package/skills/ship-roadmap/references/ADVANCE.md +0 -117
- package/skills/ship-roadmap/references/AUDIT_AND_MERGE.md +0 -64
- package/skills/ship-roadmap/references/CLOSEOUT_AND_LOG.md +0 -27
- package/skills/ship-roadmap/references/FOUNDING.md +0 -101
- package/skills/ship-roadmap/references/GUARDRAILS.md +0 -56
- package/skills/ship-roadmap/references/MODEL_ROUTING.md +0 -16
- package/skills/ship-roadmap/references/PORTABILITY.md +0 -34
- package/skills/ship-roadmap/references/RECOVERY_AND_SELECTION.md +0 -94
- package/skills/ship-roadmap/references/STOP_CONDITIONS.md +0 -9
- package/skills/ship-roadmap/references/TERMINAL_REPORT.md +0 -34
|
@@ -1,89 +1,86 @@
|
|
|
1
|
-
## Review checkpoint triggers
|
|
1
|
+
## Review checkpoint triggers
|
|
2
2
|
|
|
3
3
|
The recommended, skippable checkpoint fires on **what accumulated since the
|
|
4
|
-
last checkpoint**, not on a
|
|
5
|
-
whenever
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
layer is a coherent reviewable unit.
|
|
4
|
+
last checkpoint**, not on a step count — a step-counter cadence re-miscalibrates
|
|
5
|
+
whenever step size changes. After each step commit, check all three; recommend
|
|
6
|
+
the checkpoint (naming which trigger fired) the moment any one does:
|
|
7
|
+
|
|
8
|
+
1. **Layer boundary** — the step about to start declares a different `Layer:`
|
|
9
|
+
(the phase-lint enum) than the step just committed. The just-closed layer is
|
|
10
|
+
a coherent reviewable unit.
|
|
12
11
|
2. **Accumulation** — the unreviewed diff since the last-reviewed marker
|
|
13
12
|
exceeds **> 400 changed lines (insertions + deletions) OR > 8 changed
|
|
14
|
-
files**, measured with `git diff --stat <baseline>..HEAD`.
|
|
15
|
-
|
|
16
|
-
3. **Sensitivity** — the phase just committed touches auth, payments,
|
|
13
|
+
files**, measured with `git diff --stat <baseline>..HEAD`.
|
|
14
|
+
3. **Sensitivity** — the step just committed touches auth, payments,
|
|
17
15
|
destructive migrations, secrets, or CI config → recommend an **immediate**
|
|
18
|
-
checkpoint on closing it
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
If the marker is absent (unit's first checkpoint, or a legacy `progress.md`
|
|
29
|
-
predating this rule), the baseline is `git merge-base <default-branch> HEAD` —
|
|
30
|
-
never treat a missing marker as a blocker or crash condition.
|
|
16
|
+
checkpoint on closing it. This is a single-reviewer recommendation and does
|
|
17
|
+
not change `review-change`'s own once-per-unit adversarial cadence — the two
|
|
18
|
+
are independent mechanisms.
|
|
19
|
+
|
|
20
|
+
**Last-reviewed marker.** Home: the unit doc's Evidence section header line
|
|
21
|
+
`Last reviewed: <sha>`. Sole writer: `execute-phase` — stamped after a checkpoint
|
|
22
|
+
is taken (the next step records the sha the user confirmed was reviewed). If
|
|
23
|
+
absent (unit's first checkpoint), the baseline is
|
|
24
|
+
`git merge-base <default-branch> HEAD` — never treat a missing marker as a
|
|
25
|
+
blocker or crash condition.
|
|
31
26
|
|
|
32
27
|
## Allowed & forbidden (fixed lists — no interpretation)
|
|
33
28
|
|
|
34
|
-
**Allowed changes in a
|
|
35
|
-
- The
|
|
36
|
-
- Tests for the behavior this
|
|
37
|
-
- The per-
|
|
29
|
+
**Allowed changes in a step:**
|
|
30
|
+
- The step's own tasks (from the unit doc's `Tasks` section)
|
|
31
|
+
- Tests for the behavior this step adds or alters
|
|
32
|
+
- The per-step doc updates listed in the step completion gate below
|
|
38
33
|
- The smallest refactor strictly required to land a task (state why in the commit)
|
|
39
34
|
- An `Autofix` or `Opportunistic Fix` that passes every box in the
|
|
40
35
|
*Opportunistic finding policy* below
|
|
41
36
|
|
|
42
37
|
**Forbidden — never, even if it "would help":**
|
|
43
|
-
- New abstractions beyond what the
|
|
44
|
-
|
|
45
|
-
-
|
|
46
|
-
- Public API / contract changes the SPEC doesn't name
|
|
38
|
+
- New abstractions beyond what the unit doc's Acceptance criteria name
|
|
39
|
+
- New dependencies not justified in the unit doc
|
|
40
|
+
- Public API / contract changes the unit doc doesn't name
|
|
47
41
|
- Architecture changes (layers, boundaries, patterns)
|
|
48
42
|
- Refactoring unrelated code
|
|
49
|
-
- Building future
|
|
43
|
+
- Building future steps or features early
|
|
50
44
|
- Folding a discovered finding into the branch before it passes the
|
|
51
45
|
*Opportunistic finding policy*
|
|
52
|
-
- Creating an issue that descopes
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
descope
|
|
46
|
+
- Creating an issue that descopes an acceptance criterion without explicit user
|
|
47
|
+
approval and a dated `## References` entry (see *Descope guard* below)
|
|
48
|
+
— an issue may never be the first record of a descope
|
|
56
49
|
|
|
57
50
|
Something forbidden looks necessary → stop, record it in `decisions.md` or
|
|
58
51
|
`known-issues.md`, and surface it — never do it silently.
|
|
59
52
|
|
|
60
|
-
##
|
|
53
|
+
## Step completion gate
|
|
61
54
|
|
|
62
|
-
The
|
|
63
|
-
|
|
64
|
-
ownership, and reuse rule are
|
|
55
|
+
The step completion gate verifies that Evidence rows are complete for the
|
|
56
|
+
step's acceptance criteria, the unit doc is committed clean, and the diff guard
|
|
57
|
+
(if applicable) passed. The mark's shape, ownership, and reuse rule are
|
|
58
|
+
declared in `LEDGERS.md` (§gate-ran@1).
|
|
65
59
|
|
|
66
|
-
```
|
|
60
|
+
```
|
|
67
61
|
GATE-RAN | HEAD <40-hex sha> | <cmds> | exit <code>
|
|
68
62
|
```
|
|
69
63
|
|
|
70
|
-
- **Record**: whoever runs the
|
|
71
|
-
actually ran. A
|
|
72
|
-
|
|
73
|
-
- **Consume**: any skill may consume a green run only at the identical HEAD.
|
|
74
|
-
changed head ⇒ re-run the gate.
|
|
75
|
-
- **Recorder column-sets**: `execute-phase:gate-ran-marks` (executor
|
|
76
|
-
and `review-change:review-gate-ran-marks` (reviewer
|
|
77
|
-
the
|
|
64
|
+
- **Record**: whoever runs the gate records a mark at the head the gate
|
|
65
|
+
actually ran (green or red). A red run (exit code ≠ 0) is recorded as
|
|
66
|
+
evidence, not silence.
|
|
67
|
+
- **Consume**: any skill may consume a green run only at the identical HEAD.
|
|
68
|
+
A changed head ⇒ re-run the gate.
|
|
69
|
+
- **Recorder column-sets**: `execute-phase:gate-ran-marks` (executor steps)
|
|
70
|
+
and `review-change:review-gate-ran-marks` (reviewer steps) are declared in
|
|
71
|
+
the Evidence truth-class row's owner cell.
|
|
78
72
|
|
|
79
|
-
##
|
|
73
|
+
## Step completion gate — pass only if (every box, every step)
|
|
80
74
|
|
|
81
75
|
```
|
|
82
76
|
✓ Verification gate green — type-check + tests + build actually RUN (paste exit
|
|
83
77
|
status), never assumed
|
|
84
|
-
✓ Every task of this
|
|
85
|
-
(code path or test name)
|
|
86
|
-
✓ Tests updated/added for every behavior this
|
|
78
|
+
✓ Every task of this step checked off in the unit doc's `Tasks` section, each
|
|
79
|
+
mapped to an Evidence row (code path or test name)
|
|
80
|
+
✓ Tests updated/added for every behavior this step changed
|
|
81
|
+
✓ Tests-first red run recorded (core/domain + orchestration steps, n/a for
|
|
82
|
+
test-after UI/adapter steps) — the failing first run's command, exit status,
|
|
83
|
+
and failing test names are in the unit doc's `Progress` log
|
|
87
84
|
✓ No TODO/FIXME/HACK markers left in the diff
|
|
88
85
|
✓ No duplicated logic (reuse the existing helper — cite it if one existed)
|
|
89
86
|
✓ No dead code introduced (unused imports, functions, unreachable branches)
|
|
@@ -91,30 +88,23 @@ GATE-RAN | HEAD <40-hex sha> | <cmds> | exit <code>
|
|
|
91
88
|
consumers)
|
|
92
89
|
✓ Architecture doc respected (dependency directions, layer boundaries)
|
|
93
90
|
✓ Architectural invariants preserved or backed by an explicit recorded decision
|
|
94
|
-
✓
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
change logged), docs/CAPABILITIES.md (only if this phase introduced a new
|
|
99
|
-
cross-cutting subsystem, role, or permission — append the row, additive,
|
|
100
|
-
never rewrite existing ones; explicitly n/a when the project has no
|
|
101
|
-
inventory file)
|
|
102
|
-
✓ Docs COMMITTED with the phase — after the phase commit,
|
|
103
|
-
`git status --porcelain -- docs/` returns nothing. Doc updates ride the
|
|
104
|
-
phase commit (same `git add`), never sit uncommitted "for later"
|
|
91
|
+
✓ Evidence rows complete for the step's ACs — unit doc committed clean
|
|
92
|
+
(one dated `YYYY-MM-DD HH:MM` Progress entry, all Evidence rows current)
|
|
93
|
+
✓ Docs COMMITTED with the step — the unit doc carries all required sections
|
|
94
|
+
(Tasks, Evidence, Progress, References); no orphan files remain
|
|
105
95
|
```
|
|
106
96
|
|
|
107
|
-
A
|
|
108
|
-
scope, or record the blocker in `
|
|
109
|
-
and stop with a clear report. Never commit red; never tick
|
|
110
|
-
verify.
|
|
97
|
+
A step that cannot tick every box is **not done**: fix within the step's
|
|
98
|
+
scope, or record the blocker in the unit doc's `Progress` log, leave the
|
|
99
|
+
work uncommitted, and stop with a clear report. Never commit red; never tick
|
|
100
|
+
a box you didn't verify.
|
|
111
101
|
|
|
112
102
|
## Branch
|
|
113
103
|
|
|
114
104
|
| Mode | Format |
|
|
115
105
|
|------|--------|
|
|
116
|
-
|
|
|
117
|
-
|
|
|
106
|
+
| unit step | `feat/<NN-slug>` |
|
|
107
|
+
| fix unit | `fix/<issue-number>-<topic>` |
|
|
118
108
|
|
|
119
109
|
Read the SPEC's `Branch` field; create with `git switch -c <name>`. If absent/ambiguous, ask. Never commit, amend, or force-push on `main`.
|
|
120
110
|
|
|
@@ -133,6 +123,8 @@ planned work, and inference never prove implementation. A present ledger whose
|
|
|
133
123
|
status is `draft`, `contradicted`, or `resolved` stops implementation and routes
|
|
134
124
|
to discovery or resolution first. If no ledger exists, inspect the repository
|
|
135
125
|
directly and record `n/a: no normalized repository state`; NRS is optional.
|
|
126
|
+
Unit doc evidence rows (Evidence, Progress) are the single source of truth
|
|
127
|
+
for step completion — no separate ACCEPTANCE.md, progress.md, or TASKS.md.
|
|
136
128
|
|
|
137
129
|
## Architectural invariants
|
|
138
130
|
|
|
@@ -140,7 +132,7 @@ Before any edit, discover the optional project invariant document declared in
|
|
|
140
132
|
the documentation map (normally
|
|
141
133
|
`docs/architecture/ARCHITECTURAL_INVARIANTS.md`). If absent, record
|
|
142
134
|
`n/a: no project invariants declared` and continue. For every applicable rule,
|
|
143
|
-
cite its ID and repository evidence and classify the
|
|
135
|
+
cite its ID and repository evidence and classify the step as `preserves`,
|
|
144
136
|
`violates`, `introduces`, or `changes`. Use frozen NRS facts when present, but
|
|
145
137
|
the repository remains authoritative and conflicting evidence routes to the
|
|
146
138
|
resolver.
|
|
@@ -151,16 +143,16 @@ project's declared authority. A decision record alone is not sufficient: the
|
|
|
151
143
|
declared authority must apply the decision to the invariant document, and the
|
|
152
144
|
resulting rule must be re-evaluated and evidenced as `preserves` before the
|
|
153
145
|
phase can resume. The executor does not edit the invariant document itself.
|
|
154
|
-
Do not alter the
|
|
155
|
-
decision into
|
|
146
|
+
Do not alter the unit doc or tests to make the step pass, and do not convert
|
|
147
|
+
the decision into step work. Return exactly:
|
|
156
148
|
|
|
157
149
|
```
|
|
158
|
-
ARCHITECTURAL INVARIANT GATE — <NN
|
|
150
|
+
ARCHITECTURAL INVARIANT GATE — <NN-slug> <P<k>> BLOCKED
|
|
159
151
|
Invariant: <ID> — <violates|introduces|changes>
|
|
160
152
|
Evidence: <repository path:line or command result>
|
|
161
153
|
Decision required: <project-declared architectural authority>
|
|
162
154
|
|
|
163
|
-
→ Next: <decision path> — record the explicit architectural decision, then re-run this
|
|
155
|
+
→ Next: <decision path> — record the explicit architectural decision, then re-run this step
|
|
164
156
|
· evidence conflict → /resolve-repository-state — reconcile the frozen fact first
|
|
165
157
|
· no invariant document → record n/a and continue only when no other rule applies
|
|
166
158
|
```
|
|
@@ -10,21 +10,20 @@ own turn (e.g. no slash-command menu, or an agent that folds without leaving
|
|
|
10
10
|
its current context).
|
|
11
11
|
|
|
12
12
|
When `review-change` findings (fix-now) or `audit-pr` blockers are folded back
|
|
13
|
-
into a branch that already has an open PR, the fold is complete **only**
|
|
14
|
-
every step below ran — fixing the code and stopping is the classic way
|
|
15
|
-
end up "solved" locally but absent from the merged PR:
|
|
13
|
+
into a unit branch that already has an open PR, the fold is complete **only**
|
|
14
|
+
when every step below ran — fixing the code and stopping is the classic way
|
|
15
|
+
findings end up "solved" locally but absent from the merged PR:
|
|
16
16
|
|
|
17
17
|
```
|
|
18
18
|
✓ Fixes implemented (scope: only the routed findings — nothing extra)
|
|
19
19
|
✓ Gate RUN and green (exit codes pasted)
|
|
20
20
|
✓ Never edit an existing test's expectation to match behaviour — a setup
|
|
21
21
|
repair keeps assertions at least as strong and never touches expectations
|
|
22
|
-
✓
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
`ledger-ownership@1` / `fold-findings:folded-flag` is the sole writer
|
|
22
|
+
✓ Evidence rows updated where the finding touched them (the finding's row
|
|
23
|
+
in the unit doc's Evidence ledger flipped `folded: no → yes` — the one and
|
|
24
|
+
only state transition, `ledger-ownership@1` / `fold-findings:folded-flag`
|
|
25
|
+
is the sole writer)
|
|
26
|
+
✓ Progress log advanced with a dated entry noting the fold
|
|
28
27
|
✓ `git add` + `git commit` RUN (sha pasted) — e.g.
|
|
29
28
|
`fix(<scope>): fold review findings — <summary>`
|
|
30
29
|
✓ `git push` RUN (PR is open → every commit pushes immediately)
|
|
@@ -35,48 +34,36 @@ Then hand back to the gate that sent you (`/review-change` re-review, or
|
|
|
35
34
|
`/audit-pr` re-audit). Never report findings as resolved while any box is
|
|
36
35
|
unchecked — an unpushed fix does not exist for CI, the reviewer, or the merge.
|
|
37
36
|
|
|
38
|
-
##
|
|
39
|
-
|
|
40
|
-
A `GATE-RAN` mark is appended to the unit's `review-findings.md` ledger at the
|
|
41
|
-
head the gate actually ran. The mark's shape and ownership rule are declared in
|
|
42
|
-
`LEDGERS.md` (§gate-ran@1). A green run is recorded; a red run is also recorded.
|
|
43
|
-
The identical-head reuse rule is documented in `EXECUTION_CONTRACT.md` (§gate-ran).
|
|
44
|
-
|
|
45
|
-
Final-phase / single-pass / fix hand-off:
|
|
37
|
+
## Closing recommendation (printed after step or unit complete)
|
|
46
38
|
|
|
47
39
|
```
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
→ Next: /review-change on the changed HEAD (the mandatory end review)
|
|
52
|
-
· REVIEW-FAIL → /fold-findings (only on a REVIEW-FAIL), then re-run /review-change (unresolved findings go to triage/replan)
|
|
53
|
-
· clean → /audit-pr (merge gate) → human merges
|
|
54
|
-
· findings → fold fix-now into this PR; independent work remains a proposal until user triage; re-review
|
|
55
|
-
· docs site declared (documentation map has a `Docs site` block) →
|
|
56
|
-
/generate-docs <unit> — document what this unit changed; the generated
|
|
57
|
-
pages ride this same PR (commit + push them before the merge gate)
|
|
58
|
-
```
|
|
40
|
+
✓ Step executed, Evidence rows updated, Progress log advanced
|
|
41
|
+
✓ Gate green (or red-gate repaired within --max-attempts)
|
|
42
|
+
✓ Unit doc committed clean
|
|
59
43
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
44
|
+
→ Next: /unit-lane <NN-slug> — the conductor continues
|
|
45
|
+
· all steps done → /review-change (mandatory end review)
|
|
46
|
+
· REVIEW-FAIL → /fold-findings repairs them; a fresh /review-change follows the fold
|
|
47
|
+
· merge gate after REVIEW-PASS → /audit-pr
|
|
48
|
+
```
|
|
63
49
|
|
|
64
|
-
|
|
65
|
-
|
|
50
|
+
No auto-merge. Explicit `P<k>` stops after one step; omitted-step mode gates
|
|
51
|
+
and commits every remaining step before the same final review.
|
|
52
|
+
## Gate-run marks (gate-ran@1)
|
|
66
53
|
|
|
67
|
-
|
|
54
|
+
Every verification gate this cycle runs records a `GATE-RAN` mark in the unit
|
|
55
|
+
doc's Evidence section at the head it actually ran:
|
|
56
|
+
`GATE-RAN | HEAD <40-hex sha> | <cmds> | exit <code>`. A green run is recorded;
|
|
57
|
+
a red run is also recorded (exit code ≠ 0 is evidence, not silence). Any skill
|
|
58
|
+
may consume a green mark only at the identical HEAD — a changed head re-runs
|
|
59
|
+
the gate. The recorders are `execute-phase:gate-ran-marks` and
|
|
60
|
+
`review-change:review-gate-ran-marks` (the shape and ownership live in
|
|
61
|
+
`pre-execution-review`'s `LEDGERS.md`, §gate-ran@1).
|
|
68
62
|
|
|
69
|
-
|
|
70
|
-
isn't merged yet.** `done` means *built and PR-open*; merge state lives in the forge
|
|
71
|
-
(the open/merged PR), not in the status. **A `done` row always carries its PR
|
|
72
|
-
reference** — `done · [#<pr>](<pr-url>)` — added right after `gh pr create`
|
|
73
|
-
returns the URL (follow-up `docs: link PR #<n>` commit on the same branch);
|
|
74
|
-
`done` without a PR link is the tell-tale of an unfinished close-out. The flip is a doc change, so it rides the
|
|
75
|
-
PR-bound commit (never a lone commit on the default branch). **Never merge with docs
|
|
76
|
-
still pending, and never drop the issue / fix-index entry before merge** — those are
|
|
77
|
-
`audit-pr`'s gates, not removed at done-time.
|
|
63
|
+
## Finishing the unit — the last step is always an open PR
|
|
78
64
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
65
|
+
When the final triaged step closes: mark the unit done, push the branch, and
|
|
66
|
+
open the PR with `gh pr create` (per the project's Workflow conventions) —
|
|
67
|
+
regardless of the review still to come. The PR body carries the unit doc's
|
|
68
|
+
Evidence section as its verification record and closes the unit's tracked
|
|
69
|
+
issues via `Closes #N`.
|