@mmerterden/multi-agent-pipeline 23.6.0 → 24.0.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/CHANGELOG.md +56 -1
- package/README.md +61 -27
- package/README.tr.md +46 -12
- package/SECURITY.md +3 -3
- package/docs/architecture.md +47 -8
- package/docs/ecosystem.md +20 -18
- package/docs/engineering.md +1 -1
- package/docs/facts.json +8 -6
- package/docs/features.md +59 -15
- package/install/_codex-agents.mjs +13 -8
- package/install/_common.mjs +24 -0
- package/install/_dev-only-files.mjs +4 -0
- package/install/_mcp-register.mjs +6 -2
- package/install/_rewrite-tree.mjs +197 -0
- package/install/codex.mjs +96 -180
- package/install/copilot.mjs +24 -54
- package/install/index.mjs +29 -11
- package/install/templates/codex-instructions.md +21 -5
- package/install/templates/copilot-instructions.md +21 -14
- package/manifest.json +2082 -0
- package/package.json +6 -2
- package/pipeline/commands/multi-agent/SKILL.md +7 -5
- package/pipeline/commands/multi-agent/analysis/SKILL.md +4 -0
- package/pipeline/commands/multi-agent/autopilot-on/SKILL.md +31 -3
- package/pipeline/commands/multi-agent/autopilot-status/SKILL.md +5 -1
- package/pipeline/commands/multi-agent/channels/SKILL.md +16 -8
- package/pipeline/commands/multi-agent/log/SKILL.md +2 -0
- package/pipeline/commands/multi-agent/resume/SKILL.md +2 -0
- package/pipeline/commands/multi-agent/review-rounds/SKILL.md +94 -0
- package/pipeline/commands/multi-agent/stack/SKILL.md +1 -1
- package/pipeline/commands/multi-agent/sync/SKILL.md +3 -3
- package/pipeline/contract/manifest.json +1 -1
- package/pipeline/contract/types/index.d.ts +1 -0
- package/pipeline/lib/_jira-auth.sh +50 -78
- package/pipeline/lib/_service-account.sh +191 -0
- package/pipeline/lib/credential-inventory.sh +49 -37
- package/pipeline/lib/credential-store.sh +48 -3
- package/pipeline/lib/fetch-confluence.sh +76 -92
- package/pipeline/lib/fetch-crashlytics.sh +30 -59
- package/pipeline/lib/fetch-figma-annotations.sh +9 -9
- package/pipeline/lib/fetch-fortify.sh +77 -81
- package/pipeline/lib/fetch-graylog.sh +38 -77
- package/pipeline/lib/figma-mcp-refresh.sh +23 -4
- package/pipeline/lib/figma-screenshot.sh +7 -8
- package/pipeline/lib/figma-token.sh +39 -46
- package/pipeline/lib/host.mjs +138 -0
- package/pipeline/lib/host.sh +48 -0
- package/pipeline/lib/issue-fetcher.sh +25 -41
- package/pipeline/lib/jira-publish.sh +23 -21
- package/pipeline/lib/local-model.mjs +93 -0
- package/pipeline/lib/md2confluence-v3.py +37 -30
- package/pipeline/lib/model-dispatch.sh +41 -4
- package/pipeline/lib/model-resolve.mjs +58 -0
- package/pipeline/lib/post-pr-review.sh +38 -53
- package/pipeline/lib/reviewer-families.mjs +70 -0
- package/pipeline/lib/service-account.mjs +2131 -0
- package/pipeline/lib/service-account.sh +35 -0
- package/pipeline/lib/usage-names.generated.mjs +3 -0
- package/pipeline/lib/usage-token.mjs +64 -24
- package/pipeline/lib/usage-vocab.mjs +1 -1
- package/pipeline/lib/user-facing.mjs +11 -3
- package/pipeline/lib/vercel-deploy.sh +17 -26
- package/pipeline/multi-agent-refs/_entry-picker.md +62 -0
- package/pipeline/multi-agent-refs/_input-parser.md +1 -1
- package/pipeline/multi-agent-refs/analysis/intake.md +2 -0
- package/pipeline/multi-agent-refs/analysis/reusable-refs.md +1 -0
- package/pipeline/multi-agent-refs/analysis/unattended.md +135 -0
- package/pipeline/multi-agent-refs/autopilot-on/details.md +16 -0
- package/pipeline/multi-agent-refs/channels/generator.md +10 -2
- package/pipeline/multi-agent-refs/channels/menu.md +3 -1
- package/pipeline/multi-agent-refs/channels/preview.md +3 -1
- package/pipeline/multi-agent-refs/channels/reference.md +16 -2
- package/pipeline/multi-agent-refs/channels/report-file.md +188 -0
- package/pipeline/multi-agent-refs/component-dispatch.md +2 -2
- package/pipeline/multi-agent-refs/cross-cli-contract.md +38 -30
- package/pipeline/multi-agent-refs/features/autopilot-circuit-breaker.md +4 -4
- package/pipeline/multi-agent-refs/features/doctor.md +37 -11
- package/pipeline/multi-agent-refs/features/free-models.md +3 -3
- package/pipeline/multi-agent-refs/features/local-model.md +87 -0
- package/pipeline/multi-agent-refs/features/model-fallback.md +25 -10
- package/pipeline/multi-agent-refs/features/product-context.md +6 -5
- package/pipeline/multi-agent-refs/features/review-delta.md +1 -1
- package/pipeline/multi-agent-refs/features/review-rounds.md +40 -0
- package/pipeline/multi-agent-refs/features/rework-escalation.md +5 -4
- package/pipeline/multi-agent-refs/features/service-accounts.md +233 -0
- package/pipeline/multi-agent-refs/features/unattended-security.md +10 -1
- package/pipeline/multi-agent-refs/help/en.md +31 -2
- package/pipeline/multi-agent-refs/help/tr.md +31 -2
- package/pipeline/multi-agent-refs/orchestrator/copilot-pipeline.md +3 -2
- package/pipeline/multi-agent-refs/orchestrator/dispatcher.md +2 -1
- package/pipeline/multi-agent-refs/phases/modes.md +20 -1
- package/pipeline/multi-agent-refs/phases/operations.md +1 -1
- package/pipeline/multi-agent-refs/phases/phase-0-init.md +1 -1
- package/pipeline/multi-agent-refs/phases/phase-2-dev.md +4 -4
- package/pipeline/multi-agent-refs/phases/phase-3-review.md +7 -3
- package/pipeline/multi-agent-refs/phases/phase-5-report.md +12 -10
- package/pipeline/multi-agent-refs/phases.md +4 -3
- package/pipeline/multi-agent-refs/resume/details.md +2 -0
- package/pipeline/multi-agent-refs/review/panel.md +30 -18
- package/pipeline/multi-agent-refs/setup/discovery.md +17 -5
- package/pipeline/multi-agent-refs/setup/token-save-flow.md +21 -2
- package/pipeline/multi-agent-refs/sync/overview.md +11 -5
- package/pipeline/multi-agent-refs/tracker-contract.md +28 -10
- package/pipeline/office/index.html +4 -4
- package/pipeline/schemas/agent-state.schema.json +19 -1
- package/pipeline/schemas/autopilot-config.schema.json +29 -4
- package/pipeline/schemas/hosts.json +512 -0
- package/pipeline/schemas/hosts.schema.json +310 -0
- package/pipeline/schemas/launch.json +22 -2
- package/pipeline/schemas/launch.schema.json +2 -1
- package/pipeline/schemas/phases.json +21 -3
- package/pipeline/schemas/phases.schema.json +8 -0
- package/pipeline/schemas/prefs.schema.json +346 -7
- package/pipeline/schemas/token-budget.json +2 -2
- package/pipeline/scripts/.doctor-mut.47076.mjs +2253 -0
- package/pipeline/scripts/_autopilot-config.mjs +67 -4
- package/pipeline/scripts/_autopilot-item.mjs +67 -0
- package/pipeline/scripts/_autopilot-outcomes.mjs +6 -0
- package/pipeline/scripts/_cost.mjs +75 -3
- package/pipeline/scripts/analysis-sources.mjs +22 -5
- package/pipeline/scripts/analysis-unattended.mjs +360 -0
- package/pipeline/scripts/anonymize-findings.mjs +3 -7
- package/pipeline/scripts/autopilot-arming.mjs +19 -10
- package/pipeline/scripts/autopilot-intake.mjs +124 -27
- package/pipeline/scripts/autopilot-menubar.swift +7 -0
- package/pipeline/scripts/autopilot-runner.mjs +77 -48
- package/pipeline/scripts/autopilot-status.sh +32 -9
- package/pipeline/scripts/bulk-read.sh +37 -5
- package/pipeline/scripts/confluence-readback.mjs +15 -7
- package/pipeline/scripts/cost-table.json +65 -25
- package/pipeline/scripts/doctor.mjs +119 -32
- package/pipeline/scripts/entry-mode.mjs +101 -0
- package/pipeline/scripts/estimate.mjs +30 -16
- package/pipeline/scripts/feedback-send.mjs +11 -8
- package/pipeline/scripts/gen-facts.mjs +16 -13
- package/pipeline/scripts/jira-attach.sh +23 -28
- package/pipeline/scripts/jira-search.sh +5 -21
- package/pipeline/scripts/launch-request.mjs +15 -9
- package/pipeline/scripts/migrate-prefs.mjs +56 -0
- package/pipeline/scripts/phase-tracker.sh +146 -38
- package/pipeline/scripts/priority-review.mjs +14 -7
- package/pipeline/scripts/product-context.mjs +26 -7
- package/pipeline/scripts/prune-logs.sh +4 -2
- package/pipeline/scripts/report-file.mjs +285 -0
- package/pipeline/scripts/review-rounds.mjs +592 -0
- package/pipeline/scripts/rework-escalation.mjs +26 -7
- package/pipeline/scripts/service-read.mjs +19 -17
- package/pipeline/scripts/skill-siblings.mjs +17 -1
- package/pipeline/scripts/status-overview.mjs +20 -10
- package/pipeline/scripts/uninstall.mjs +145 -57
- package/pipeline/scripts/usage-register.mjs +34 -11
- package/pipeline/scripts/usage-report.mjs +31 -26
- package/pipeline/scripts/validate-state.mjs +19 -11
- package/pipeline/scripts/validate-triage.mjs +11 -1
- package/pipeline/scripts/work-items.mjs +25 -28
- package/pipeline/scripts/write-store-config.mjs +37 -11
- package/pipeline/skills/.skill-manifest.json +11 -7
- package/pipeline/skills/.skills-index.json +13 -2
- package/pipeline/skills/shared/README.md +4 -3
- package/pipeline/skills/shared/core/multi-agent/SKILL.md +14 -6
- package/pipeline/skills/shared/core/multi-agent-analysis/SKILL.md +2 -0
- package/pipeline/skills/shared/core/multi-agent-channels/SKILL.md +11 -8
- package/pipeline/skills/shared/core/multi-agent-resume/SKILL.md +1 -1
- package/pipeline/skills/shared/core/multi-agent-review-rounds/SKILL.md +92 -0
- package/pipeline/skills/shared/core/multi-agent-sync/SKILL.md +3 -3
- package/pipeline/skills/skills-index.md +2 -1
- package/pipeline/lib/credential-resolve.mjs +0 -75
|
@@ -41,7 +41,8 @@
|
|
|
41
41
|
| `--message "..."` | Manual mode - use user text as source, no diff read. Forces `content=note`. |
|
|
42
42
|
| `--message-file path` | Manual mode, long message from file. |
|
|
43
43
|
| `--append` | PR description: append instead of replace. |
|
|
44
|
-
| `--dry-run` | Generate, print to stdout, do not POST. |
|
|
44
|
+
| `--dry-run` | Generate, print to stdout, do not POST. Does not write the report file; prints the path it would write. |
|
|
45
|
+
| `--file-only` | No menu, no approval gate, no dispatch: compose the `Report` body and write the report file only. Content from `--content`, else from prefs. Used by the Phase 5 offline short-circuit, unattended Phase 5, the autopilot timeout, and a menu resolved with zero channels. |
|
|
45
46
|
| `--lang=tr\|en\|both` | Output language override (default: `en`; `promptLanguage` is locked to `en`). |
|
|
46
47
|
| `--ready` | If PR draft, promote to READY after channels dispatch. |
|
|
47
48
|
|
|
@@ -65,6 +66,7 @@ Non-interactive in three cases; the menu is skipped and flag values or prefs are
|
|
|
65
66
|
| `--channels X,Y` + `--content A,B` flags | Exact flag values, no menu. |
|
|
66
67
|
| `autopilot` (Phase 5 delegate) | Reads `prefs.global.reportChannels` + `prefs.global.reportContent`. Per the Phase 5 autopilot-pause contract, Phase 5 still pauses before calling channels but pre-fills the menu from prefs. A post-hoc call in autopilot mode uses prefs directly. |
|
|
67
68
|
| `--dry-run` | Runs the menu, generates output, prints to stdout, does not post. |
|
|
69
|
+
| `--file-only` | Skips the menu, the gate and the dispatch; composes one body and writes the report file. |
|
|
68
70
|
|
|
69
71
|
## Step 8 summary format
|
|
70
72
|
|
|
@@ -75,8 +77,14 @@ channels dispatch complete
|
|
|
75
77
|
Confluence - skipped: user declined
|
|
76
78
|
Wiki ✓ 3 files via github-wiki adapter
|
|
77
79
|
Board ✓ In Develop → In Review (project #4)
|
|
80
|
+
Report file ✓ $HOME/.claude/logs/multi-agent/app/PROJ-12/task-report.md
|
|
78
81
|
```
|
|
79
82
|
|
|
83
|
+
The `Report file` row is always last and always present: `✓` with the absolute
|
|
84
|
+
path (and `(previous kept in report-history/)` when a previous run's file was
|
|
85
|
+
rotated), `-` for a dry run or when there was no content source at all, `✗` with
|
|
86
|
+
the reason when the writer refused.
|
|
87
|
+
|
|
80
88
|
## Error handling
|
|
81
89
|
|
|
82
90
|
| Condition | Behavior |
|
|
@@ -90,6 +98,9 @@ channels dispatch complete
|
|
|
90
98
|
| Bitbucket PR version mismatch | Refetch once, retry; fail on second mismatch |
|
|
91
99
|
| Jira token missing/expired | Token Save Flow inline; skip on user-skip |
|
|
92
100
|
| Wiki preconditions not met | Case B menu per `$HOME/.claude/multi-agent-refs/wiki-capture.md` |
|
|
101
|
+
| No external channel available or selected | Not an error: file-only. Bodies are composed and written to disk, nothing is posted |
|
|
102
|
+
| Report file refused (writer exit 7 or 2) | The `Report file` row carries the reason; dispatch continues unaffected |
|
|
103
|
+
| No content source at all | Nothing is written and Step 8 says so. A pipeline run always has a log, so this is the post-hoc case |
|
|
93
104
|
|
|
94
105
|
## Cross-CLI parity
|
|
95
106
|
|
|
@@ -122,6 +133,7 @@ Progress emission on Copilot (no native TaskCreate UI): `bash ~/.copilot/scripts
|
|
|
122
133
|
→ page created → https://<host>/pages/12345
|
|
123
134
|
|
|
124
135
|
/multi-agent:channels https://<bitbucket>/.../pull-requests/42 --dry-run
|
|
136
|
+
/multi-agent:channels PROJ-12345 --file-only # local-only repo: compose and write, post nothing
|
|
125
137
|
→ resolves → PROJ-67890
|
|
126
138
|
→ prints Jira + PR body preview to stdout, no POST
|
|
127
139
|
|
|
@@ -137,8 +149,10 @@ Phase 5 invokes channels internally instead of running its own Jira / Confluence
|
|
|
137
149
|
| Who | What |
|
|
138
150
|
|---|---|
|
|
139
151
|
| Phase 5 | Progress tracker (sub-steps 1-3), agent-log finalization (step 4), knowledge + memory capture (step 5), telemetry emission |
|
|
140
|
-
| `channels` | All external delivery: PR description update, Jira comment, Confluence page, Wiki pages |
|
|
152
|
+
| `channels` | All external delivery: PR description update, Jira comment, Confluence page, Wiki pages. Plus the local report file, which is not delivery and is written whatever the channels do |
|
|
141
153
|
|
|
142
154
|
Phase 5 passes a runtime state bundle: `{jiraId, prUrl, remoteType, taskType, figmaConfig, agentState, pipelineLogPath, flowRuns}`. Channels reads these directly and skips Step 1 target resolution.
|
|
143
155
|
|
|
156
|
+
On the three paths where nothing is posted - the offline short-circuit, an unattended run, and the autopilot timeout - Phase 5 calls channels with `--file-only` rather than skipping it. That is the whole reason the report file exists: those are the paths that used to end with the summary composed and then dropped. The channels return carries `reportFile: {status, path}`, which is not written to `channelResults`: that object records what was posted, and this was not.
|
|
157
|
+
|
|
144
158
|
Autopilot: Phase 5 always pauses at the channels menu, the one exception to the autopilot zero-interaction contract. A 30-min timeout ends the session cleanly and the task stays resumable via `/multi-agent:resume`; full contract in `$HOME/.claude/multi-agent-refs/phases/modes.md`. The Step 6 approval gate follows the same split: interactive runs approve the composed bodies before dispatch, autopilot posts directly after the menu resolves.
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
# Channels - the report file
|
|
2
|
+
|
|
3
|
+
<!-- toc -->
|
|
4
|
+
- [Why it is not a channel](#why-it-is-not-a-channel)
|
|
5
|
+
- [Path](#path)
|
|
6
|
+
- [The file](#the-file)
|
|
7
|
+
- [When it is written](#when-it-is-written)
|
|
8
|
+
- [Rotation](#rotation)
|
|
9
|
+
- [Writer](#writer)
|
|
10
|
+
- [Step 8 row](#step-8-row)
|
|
11
|
+
<!-- /toc -->
|
|
12
|
+
|
|
13
|
+
> Loaded by `channels/SKILL.md` Step 5. The SKILL keeps the one-line rule; this
|
|
14
|
+
> file carries the path, the envelope, the write moments, `--file-only`,
|
|
15
|
+
> rotation and the writer's interface.
|
|
16
|
+
|
|
17
|
+
## Why it is not a channel
|
|
18
|
+
|
|
19
|
+
Every channel is an external write, and three ordinary paths end with nothing
|
|
20
|
+
written at all:
|
|
21
|
+
|
|
22
|
+
- a local-only repo short-circuits Phase 5 before the menu (`phases/phase-5-report.md`);
|
|
23
|
+
- an unattended run defers delivery to the runner and posts nothing;
|
|
24
|
+
- a cancelled menu, the autopilot timeout, and a menu with every row unticked
|
|
25
|
+
all end after Step 5.
|
|
26
|
+
|
|
27
|
+
On a machine with no tracker the development summary and the test scenarios were
|
|
28
|
+
composed, shown once in the preview, and lost.
|
|
29
|
+
|
|
30
|
+
A fifth channel would not fix that. A channel is selectable, waits for the Step 6
|
|
31
|
+
gate, and is skipped unattended and offline - each of which reintroduces one of
|
|
32
|
+
the three losses. So the report file is internal capture, like `agent-log.md`:
|
|
33
|
+
unconditional, local, and with no preference to get wrong. It is not a post, and
|
|
34
|
+
no rule about posting applies to it.
|
|
35
|
+
|
|
36
|
+
## Path
|
|
37
|
+
|
|
38
|
+
```
|
|
39
|
+
${LOGS_ROOT:-$HOME/.claude/logs/multi-agent}/<project>/<task-id>/task-report.md
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Beside `agent-log.md`. Not the repo or the worktree, which Phase 4 removes and
|
|
43
|
+
where a stray file invites an accidental commit; not the Desktop, which is
|
|
44
|
+
presumptuous on a shipped product and outside the unattended write scope. The
|
|
45
|
+
log directory survives the worktree, `/multi-agent:log` already looks there,
|
|
46
|
+
`prune-logs` already owns its lifetime, and an unattended run may write to it.
|
|
47
|
+
|
|
48
|
+
`task-report.md`, not `report.md`: store-ready, bug-bash and complaint-analysis
|
|
49
|
+
already write a `report.md` and mean something else by it.
|
|
50
|
+
|
|
51
|
+
The task directory is `dirname` of the pipeline log when there is one. For a
|
|
52
|
+
post-hoc call on a task that never ran through the pipeline, it is
|
|
53
|
+
`<LOGS_ROOT>/<project>/<key>/` with the key being the Jira id, else `GH<n>`,
|
|
54
|
+
else `PR<n>`.
|
|
55
|
+
|
|
56
|
+
How someone who never read this finds it: the Step 8 row prints the absolute
|
|
57
|
+
path, the Phase 5 closing block carries `Report file:`, the Step 3 menu says in
|
|
58
|
+
one line that it is always written, `/multi-agent:log` prints it, and the `Logs:`
|
|
59
|
+
line of `/multi-agent:help` names it.
|
|
60
|
+
|
|
61
|
+
## The file
|
|
62
|
+
|
|
63
|
+
```markdown
|
|
64
|
+
# {taskKey} - {title}
|
|
65
|
+
|
|
66
|
+
- Branch: `{head}` -> `{base}`
|
|
67
|
+
- PR: {url | none}
|
|
68
|
+
- Tracker: {jira id or issue url | none}
|
|
69
|
+
- Written: {YYYY-MM-DD HH:mm} by /multi-agent:channels (run {runId})
|
|
70
|
+
- Delivery: {not sent | pr posted · jira skipped: declined | ...}
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
# Report
|
|
75
|
+
|
|
76
|
+
{body}
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
# Jira comment
|
|
81
|
+
|
|
82
|
+
{body}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
Envelope labels are fixed English so the file stays parseable; the bodies are in
|
|
86
|
+
`outputLanguage`. Block headings are `Report`, `PR description (<repo>#<n>)`,
|
|
87
|
+
`Jira comment` and `Confluence page`, in that order whatever order they were
|
|
88
|
+
handed over in.
|
|
89
|
+
|
|
90
|
+
**The file always carries one PR-shaped body.** When `pr` is selected that block
|
|
91
|
+
is the PR body, copied. When it is not, the generator composes one body in the
|
|
92
|
+
`channels/pr.md` section order, with the PR tone, labelled `Report`. The PR shape
|
|
93
|
+
is the superset, so `Geliştirme Özeti` and `Test Senaryoları` are on disk in
|
|
94
|
+
every case. The cost is one extra composition when `pr` is not selected.
|
|
95
|
+
|
|
96
|
+
`technicalAnalysis` renders in the PR-shaped block, always, and never in the
|
|
97
|
+
`Jira comment` block, which is a copy of the Jira body. The "never Jira" rule is
|
|
98
|
+
about the Jira reader and is untouched.
|
|
99
|
+
|
|
100
|
+
Bodies are copied byte for byte. Nothing is merged, converted or run through the
|
|
101
|
+
humanizer a second time: a second pass would break byte-identity with what the
|
|
102
|
+
adapters post.
|
|
103
|
+
|
|
104
|
+
## When it is written
|
|
105
|
+
|
|
106
|
+
Whenever Step 5 composed at least one body.
|
|
107
|
+
|
|
108
|
+
- **Right after the humanizer, before Step 6.** Cancel, the timeout and a crash
|
|
109
|
+
therefore all leave it behind.
|
|
110
|
+
- Rewritten after each `Edit` re-render, and once more at Step 8 with
|
|
111
|
+
`--delivery` to stamp the outcomes.
|
|
112
|
+
- **No approval gate.** The gate protects an audience from unreviewed text. This
|
|
113
|
+
file has no audience but the machine's owner, is replaceable, and holds less
|
|
114
|
+
than `agent-log.md` already does.
|
|
115
|
+
- `--dry-run` writes nothing and prints the path it would write.
|
|
116
|
+
- If the access check stops channels inside Phase 5, Phase 5 records
|
|
117
|
+
`report file not written` and continues its internal capture. It never halts
|
|
118
|
+
on it.
|
|
119
|
+
- No content source at all - no log, no PR diff, no `--message`, no state - and
|
|
120
|
+
nothing is written. Step 8 says so. A pipeline run always has a log.
|
|
121
|
+
|
|
122
|
+
### `--file-only`
|
|
123
|
+
|
|
124
|
+
No menu, no Step 6, no Step 7. Content comes from `--content`, else from
|
|
125
|
+
`prefs.global.reportContent` filtered by the availability rules. Only the
|
|
126
|
+
`Report` body is composed.
|
|
127
|
+
|
|
128
|
+
Used by the Phase 5 offline short-circuit, unattended Phase 5, the autopilot
|
|
129
|
+
30-minute timeout, and a menu resolved with zero channels, which is a valid
|
|
130
|
+
selection meaning file-only.
|
|
131
|
+
|
|
132
|
+
## Rotation
|
|
133
|
+
|
|
134
|
+
- `task-report.md` is always the latest.
|
|
135
|
+
- Same `runId` as the file already there (the Edit loop, the delivery stamp):
|
|
136
|
+
replaced in place.
|
|
137
|
+
- A different `runId`: the previous file moves to
|
|
138
|
+
`report-history/task-report-<stamp>-<runId>.md` first. The newest 5 are kept.
|
|
139
|
+
- The run id is in the name because the stamp is minute-resolution: two runs
|
|
140
|
+
inside one minute would otherwise share a name, the second quietly replacing
|
|
141
|
+
the first in the very place that exists to not lose it.
|
|
142
|
+
- Not appended, because one unreadable file is not a report. Not
|
|
143
|
+
timestamp-only-named, because then nobody can tell which one is current.
|
|
144
|
+
|
|
145
|
+
## Writer
|
|
146
|
+
|
|
147
|
+
`$HOME/.claude/scripts/report-file.mjs`. Zero dependencies beyond the outbound gate.
|
|
148
|
+
|
|
149
|
+
```
|
|
150
|
+
report-file.mjs write --dir <task-dir> --run <id> --meta <meta.json>
|
|
151
|
+
--body <name>=<file> [--body ...] [--delivery <json>]
|
|
152
|
+
report-file.mjs path --dir <task-dir>
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
`meta.json` carries `{taskKey, title, branch, base, prUrl, tracker}`; a missing
|
|
156
|
+
value renders as `none`. `--delivery` takes the dispatch result object. stdout is
|
|
157
|
+
the absolute path.
|
|
158
|
+
|
|
159
|
+
| Exit | Meaning |
|
|
160
|
+
|---|---|
|
|
161
|
+
| 0 | written |
|
|
162
|
+
| 2 | usage, no body, an empty body, or a path that is not inside the logs root |
|
|
163
|
+
| 7 | a body carries credential-shaped text |
|
|
164
|
+
|
|
165
|
+
What it refuses, and why each one is a refusal rather than a repair:
|
|
166
|
+
|
|
167
|
+
- a `--dir` whose realpath is outside `LOGS_ROOT`, including one reached through
|
|
168
|
+
a symlink or `..`;
|
|
169
|
+
- a symlink at `task-report.md` or at `report-history/`, which would point the
|
|
170
|
+
write somewhere else;
|
|
171
|
+
- a body that the outbound gate matches with certainty. Nothing is written, the
|
|
172
|
+
existing file and its history are untouched, and the message names the rule
|
|
173
|
+
and the line but never the matched value.
|
|
174
|
+
|
|
175
|
+
It writes to a temp file in the same directory and renames, mode 0600, so a
|
|
176
|
+
reader never sees a half-written report and a crash leaves the previous one
|
|
177
|
+
intact.
|
|
178
|
+
|
|
179
|
+
## Step 8 row
|
|
180
|
+
|
|
181
|
+
Always present, last row of the block.
|
|
182
|
+
|
|
183
|
+
```
|
|
184
|
+
Report file ✓ /Users/me/.claude/logs/multi-agent/app/PROJ-12/task-report.md (previous kept in report-history/)
|
|
185
|
+
Report file - dry run: would write <path>
|
|
186
|
+
Report file - nothing to write: no content source
|
|
187
|
+
Report file ✗ not written: credential-shaped text in the Jira comment body
|
|
188
|
+
```
|
|
@@ -114,9 +114,9 @@ Multi-agent does **not** split the component task into per-repo Phase 2 runs -
|
|
|
114
114
|
On failure (the plugin skill returns an unrecoverable build/test error, or the dispatch hits retry cap):
|
|
115
115
|
|
|
116
116
|
1. The dispatch layer persists `{error, buildLog, testLog}` to `state.phases["2"].errors[]`.
|
|
117
|
-
2. Multi-agent increments `state.phases["2"].retryCount
|
|
117
|
+
2. Multi-agent increments `state.phases["2"].retryCount` (the build-retry counter; review reworks are counted separately in `reworkCount`).
|
|
118
118
|
3. Retry re-invokes the plugin skill (it is idempotent on an existing component; it reconciles rather than duplicating). There is no bundled `phase-<N>` resume anymore.
|
|
119
|
-
4. Hard kill
|
|
119
|
+
4. Hard kill when `retryCount` reaches the build-retry cap (3, unrelated to the review limit) → surface the errors to the user, halt Phase 2. Do not loop indefinitely.
|
|
120
120
|
|
|
121
121
|
## Cross-CLI behaviour (intentional divergence)
|
|
122
122
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Cross-CLI Contract (Claude Code · Copilot CLI · Codex CLI)
|
|
2
2
|
|
|
3
3
|
<!-- toc -->
|
|
4
|
-
- [1. Command Inventory (
|
|
4
|
+
- [1. Command Inventory (81 commands)](#1-command-inventory-81-commands)
|
|
5
5
|
- [2. Canonical Placeholder Vocabulary](#2-canonical-placeholder-vocabulary)
|
|
6
6
|
- [2.6 Intentional structural divergence - two entry files over one set of refs](#26-intentional-structural-divergence---two-entry-files-over-one-set-of-refs)
|
|
7
7
|
- [2.7 One switch, three different meanings: `fable-on` / `fable-off`](#27-one-switch-three-different-meanings-fable-on-fable-off)
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
|
|
21
21
|
---
|
|
22
22
|
|
|
23
|
-
## 1. Command Inventory (
|
|
23
|
+
## 1. Command Inventory (81 commands)
|
|
24
24
|
|
|
25
25
|
```
|
|
26
26
|
address-review, analysis, analysis-jira, analysis-resolve, autopilot-off,
|
|
@@ -31,7 +31,7 @@ garbage-collect, graph, health, help, ios-coding-standard, issue, jira, kill,
|
|
|
31
31
|
language, log, manual-test, office-off, office-on, office-status, pair,
|
|
32
32
|
postmortem, prune-logs,
|
|
33
33
|
prune-prompts, purge, refactor, research, resume, review,
|
|
34
|
-
review-analysis, review-issue, review-jira, review-priority, route-off, route-on,
|
|
34
|
+
review-analysis, review-issue, review-jira, review-priority, review-rounds, route-off, route-on,
|
|
35
35
|
route-status, routines, routines-browse, routines-delete, routines-import,
|
|
36
36
|
routines-share, routines-update, save, scaffold, scan, scenario-audit, search,
|
|
37
37
|
security-review, serve, setup, stack, status, steer, store-ready, sync, test, test-accessibility,
|
|
@@ -61,7 +61,7 @@ plugin natively. The other two are served by the installer, so all three end up
|
|
|
61
61
|
same active skill set:
|
|
62
62
|
|
|
63
63
|
| Host | Delivery | Discovery |
|
|
64
|
-
|
|
64
|
+
| ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
|
|
65
65
|
| Claude Code | the marketplace plugin, loaded natively | matched on description |
|
|
66
66
|
| Copilot CLI | `install/copilot.mjs` copies the **enabled** stack plugin's authored skills (`index`, `reference/`, `workflow/`, `tools/`) into `~/.copilot/skills/` | matched on description |
|
|
67
67
|
| Codex CLI | `install/codex.mjs` copies the same set **plus** `skills/shared/external` into `~/.codex/multi-agent-refs/skills/` as reference files | located by path; the AGENTS.md block carries the `ls` / `grep` recipe |
|
|
@@ -89,7 +89,7 @@ What still MUST match across CLIs for component tasks: the `taskType === "compon
|
|
|
89
89
|
Two parallel shared/core skills under `pipeline/skills/shared/core/` wrap external tooling for pre-submission store compliance:
|
|
90
90
|
|
|
91
91
|
| Skill | Path | Tool wrapper | Rules |
|
|
92
|
-
|
|
92
|
+
| -------------------------- | ------------------------------------------------------- | -------------------------------------------------------------------------- | ----------------------------------------------------------- |
|
|
93
93
|
| `apple-archive-compliance` | `pipeline/skills/shared/core/apple-archive-compliance/` | `ios_app_store_audit` MCP tool (in `@mmerterden/multi-agent-mcp` ≥ v3.0.0) | 18 (Apple ITMS + App Store Review Guidelines) |
|
|
94
94
|
| `google-play-compliance` | `pipeline/skills/shared/core/google-play-compliance/` | bundletool + aapt2 + apksigner | 21 (4 categories: Technical / Security / Privacy / Hygiene) |
|
|
95
95
|
|
|
@@ -111,7 +111,7 @@ list once and names the fallback it takes (`test-gen/stages.md`,
|
|
|
111
111
|
`features/test-classification.md`).
|
|
112
112
|
|
|
113
113
|
| Capability | Tools / fields | Minimum |
|
|
114
|
-
|
|
114
|
+
| -------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------- |
|
|
115
115
|
| Element locators | `ui_locate`, `ios_tap_element`, `android_tap_element`; codes `LOCATOR_NOT_FOUND`, `LOCATOR_AMBIGUOUS` | `@mmerterden/multi-agent-mcp` ≥ v3.19.0 |
|
|
116
116
|
| Assertion steps and verdicts | `agent_run_steps` steps `expect_text`, `expect_element`, `expect_url`; `verdict: passed / failed / blocked` with `ASSERTION_FAILED`, `CREDENTIAL_MISSING`, `ENVIRONMENT_UNAVAILABLE`, `SEED_DATA_MISSING`, `BUDGET_EXCEEDED`, `REPLAY_DIVERGED`; failure `trace.md` | ≥ v3.19.0 |
|
|
117
117
|
| Secrets by reference | `secret_ref` on the type tools | ≥ v3.19.0 |
|
|
@@ -137,7 +137,7 @@ list once and names the fallback it takes (`test-gen/stages.md`,
|
|
|
137
137
|
### 2.1 Identity / account placeholders
|
|
138
138
|
|
|
139
139
|
| Placeholder | Meaning | Example real value |
|
|
140
|
-
|
|
140
|
+
| ---------------- | ---------------------------------------------------------- | ----------------------- |
|
|
141
141
|
| `{owner}` | Public GitHub org/user owning the pipeline repo | `multi-agent-ecosystem` |
|
|
142
142
|
| `{npm-scope}` | npm scope for publishing | `@mmerterden` |
|
|
143
143
|
| `${USER}` | Local OS username, used for per-user keychain keys | `alice` |
|
|
@@ -147,7 +147,7 @@ list once and names the fallback it takes (`test-gen/stages.md`,
|
|
|
147
147
|
### 2.2 Host / URL placeholders
|
|
148
148
|
|
|
149
149
|
| Placeholder | Meaning | Example |
|
|
150
|
-
|
|
150
|
+
| ------------------- | -------------------------- | ------------------------ |
|
|
151
151
|
| `{jira-host}` | Jira server hostname | `jira.company.com` |
|
|
152
152
|
| `{bitbucket-host}` | Bitbucket server hostname | `bitbucket.company.com` |
|
|
153
153
|
| `{confluence-host}` | Confluence server hostname | `confluence.company.com` |
|
|
@@ -159,7 +159,7 @@ list once and names the fallback it takes (`test-gen/stages.md`,
|
|
|
159
159
|
Use these specific names (from the Copilot set) - **never invent new ones**. They correspond to realistic example project types.
|
|
160
160
|
|
|
161
161
|
| Placeholder | Represents |
|
|
162
|
-
|
|
162
|
+
| ------------------ | ------------------------------------------------ |
|
|
163
163
|
| `my-ios-app` | An iOS native project |
|
|
164
164
|
| `my-figma-app` | A figma-driven SwiftUI component project |
|
|
165
165
|
| `my-ui-components` | A UI component library (cross-platform possible) |
|
|
@@ -167,7 +167,7 @@ Use these specific names (from the Copilot set) - **never invent new ones**. T
|
|
|
167
167
|
### 2.4 Task / tracker placeholders
|
|
168
168
|
|
|
169
169
|
| Placeholder | Meaning |
|
|
170
|
-
|
|
170
|
+
| ------------ | ---------------------------------------------------------------------- |
|
|
171
171
|
| `{JIRA_KEY}` | Jira project key (e.g., `PROJ`, `MOBILE`) |
|
|
172
172
|
| `PROJ-12345` | Example Jira issue (placeholder, always use `PROJ-12345` for examples) |
|
|
173
173
|
| `#N` | GitHub issue number placeholder |
|
|
@@ -177,7 +177,7 @@ Use these specific names (from the Copilot set) - **never invent new ones**. T
|
|
|
177
177
|
Legacy names found during the v3.7 audit - replaced per this contract.
|
|
178
178
|
|
|
179
179
|
| Deprecated | Replace with | Reason |
|
|
180
|
-
|
|
180
|
+
| ------------------------------------------------- | --------------------------------------------------------------------- | ----------------------------------------------------------------- |
|
|
181
181
|
| `{github-username}` | `{owner}` | Shorter, consistent with `{owner}` pattern |
|
|
182
182
|
| `{website-repo}` | `website` (literal, since the repo name IS "website" under `{owner}`) | Hardcoding the repo name inside `{owner}` scope is fine |
|
|
183
183
|
| `{your-website}` | `{website-host}` | Match `{*-host}` convention |
|
|
@@ -189,15 +189,19 @@ Legacy names found during the v3.7 audit - replaced per this contract.
|
|
|
189
189
|
## 2.6 Intentional structural divergence - two entry files over one set of refs
|
|
190
190
|
|
|
191
191
|
Both top-level orchestrators are short entry files that read the phase contracts
|
|
192
|
-
from
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
192
|
+
from the refs tree when a phase starts; neither embeds the phase specs. Every
|
|
193
|
+
host installs that tree under its own root (`~/.claude/multi-agent-refs/`,
|
|
194
|
+
`~/.copilot/multi-agent-refs/`, `~/.codex/multi-agent-refs/`), and the installer
|
|
195
|
+
retargets the `$HOME/.claude/...` paths the sources are authored against as the
|
|
196
|
+
files land, so each install resolves a ref inside its own tree. They are still
|
|
197
|
+
two different files on purpose, and auditors must not flag the difference in
|
|
198
|
+
their text as a parity violation: each routes the way its host dispatches, and
|
|
199
|
+
the phase refs they both read are the contract.
|
|
196
200
|
|
|
197
201
|
| Surface | File | Shape | Why |
|
|
198
|
-
|
|
202
|
+
| ------------------------ | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
199
203
|
| Claude Code (colon-form) | `pipeline/commands/multi-agent/SKILL.md` | thin dispatcher: input classification and the routing table, then `$HOME/.claude/multi-agent-refs/orchestrator/dispatcher.md` for the full rows and `phases/phase-N-*.md` for the phase that starts | Each sub-command is its own `/multi-agent:<name>` entry, so the dispatcher only routes task input and loads the one ref the action needs. |
|
|
200
|
-
| Copilot CLI (dash-form)
|
|
204
|
+
| Copilot CLI (dash-form) | `pipeline/skills/shared/core/multi-agent/SKILL.md` | entry skill with the routing, task-operation, autopilot, persona-dispatch and phase-label rules inline, which reads `$HOME/.claude/multi-agent-refs/orchestrator/copilot-pipeline.md` before routing and `phases/phase-N-*.md` when each phase starts | Copilot installs its own `multi-agent-refs` tree and retargets every ref path into it, so a Copilot-only machine resolves them without a second CLI. The sub-command specs are not copied there: this host already carries each one as its own skill, and the rewrite points at those. |
|
|
201
205
|
| Codex CLI | installed as `~/.codex/skills/multi-agent/SKILL.md`, generated from the Claude dispatcher | thin dispatcher, refs under `~/.codex/multi-agent-refs/` | Codex reads files on demand, so it takes the Claude shape - **and it has to.** See below. |
|
|
202
206
|
|
|
203
207
|
### Why Codex takes the thin-dispatcher shape, and must keep it
|
|
@@ -255,7 +259,7 @@ borderline finding.
|
|
|
255
259
|
Where the budget goes instead, when vendor diversity is unavailable:
|
|
256
260
|
|
|
257
261
|
| Host | Reviewer 1 | Reviewer 2 | Reviewer 3 |
|
|
258
|
-
|
|
262
|
+
| ----------- | ----------------------------------- | ------------------------------------- | ----------------- |
|
|
259
263
|
| Copilot CLI | Fable/Opus, security + architecture | GPT-5.4, edge cases (cross-vendor) | Sonnet, quality |
|
|
260
264
|
| Claude Code | Fable, security + architecture | Opus, edge cases | Sonnet, quality |
|
|
261
265
|
| Codex | `xhigh`, security + architecture | a different family member, edge cases | `medium`, quality |
|
|
@@ -277,7 +281,7 @@ they are `/multi-agent:fable-on`, `/multi-agent:fable-off` and
|
|
|
277
281
|
via the router skill.
|
|
278
282
|
|
|
279
283
|
| Host | What `fable-on` / `fable-off` does | Why |
|
|
280
|
-
|
|
284
|
+
| ----------- | -------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
281
285
|
| Claude Code | live switch: flips `modelFallback.fableEnabled` and realigns `costBudget.pricingModel` | the only host where the `fable` rung is Fable 5.2 |
|
|
282
286
|
| Copilot CLI | writes the preference, changes no dispatch | Fable is not offered there; its personas never sat on this rung |
|
|
283
287
|
| Codex CLI | writes the preference, changes no dispatch, **deliberately** | the `fable` rung on Codex means `gpt-5.6 @ xhigh` - a different model on a different account. A knob named after an Anthropic model must not silently retune a Codex run |
|
|
@@ -291,10 +295,12 @@ host's actual behaviour, never claim a change that did not happen.
|
|
|
291
295
|
|
|
292
296
|
The routing trio (`route-on`, `route-off`, `route-status`) has no such split -
|
|
293
297
|
it writes `prefs.global.modelRouting` identically everywhere. Its honest limit is
|
|
294
|
-
different and applies on every host:
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
+
different and applies on every host: subagent dispatch belongs to the host, so
|
|
299
|
+
a rung that host does not offer, or whose model belongs to a provider it does
|
|
300
|
+
not dispatch, is refused and the rule's next rung answers. `model-dispatch.sh`
|
|
301
|
+
reads both facts from `schemas/hosts.json` and prints the reason it skipped a
|
|
302
|
+
rung on stderr. The `free` rung (`route-on --free`) is reachable only where the
|
|
303
|
+
pipeline makes the call itself: `bulk-read.sh` and the `delegate` call site, where a skill asks
|
|
298
304
|
`model-dispatch.sh delegate --default host` and calls `llm_delegate` on `free`.
|
|
299
305
|
The toolkit and its CLI are the same on all three hosts, so the free chain
|
|
300
306
|
behaves identically everywhere. `route-status` prints the limit on every run.
|
|
@@ -327,7 +333,7 @@ argument-hint: "<input hint>"
|
|
|
327
333
|
### 3.3 Transform Contract
|
|
328
334
|
|
|
329
335
|
| Direction | Action |
|
|
330
|
-
|
|
336
|
+
| ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
331
337
|
| Claude → Copilot | Add `name`, `user-invocable: true`, `argument-hint`; remove `allowed-tools`; `description` stays English (localization happens only in the installed Claude tree via `description-tr` + `localize-commands.mjs`, never in repo or Copilot files) |
|
|
332
338
|
| Copilot → Claude | Remove `name`, `user-invocable`, `argument-hint`; add `allowed-tools` (inferred from command's actual tool calls) |
|
|
333
339
|
| Both directions | `not-for: <sibling>` carries across with the same value: top-level in the command, under `metadata:` in the skill, where every key no host reads lives (`language` too) |
|
|
@@ -347,13 +353,14 @@ argument-hint: "<input hint>"
|
|
|
347
353
|
### 4.1 TaskCreate ↔ phase-tracker.sh
|
|
348
354
|
|
|
349
355
|
| Concept | Claude Code | Copilot CLI | Codex CLI |
|
|
350
|
-
|
|
356
|
+
| ---------------------------- | ----------------------------------------------------- | -------------------------------------------------------- | --------------------------------------------------------- |
|
|
351
357
|
| Print the registration calls | `phase-tracker.sh tiles` (emits the TaskCreate list) | `phase-tracker.sh tiles` (emits the reprint instruction) | `phase-tracker.sh tiles` (emits the update_plan payload) |
|
|
352
358
|
| Register a phase | `TaskCreate` tool call with subject/description | `phase-tracker.sh add <N> <name>` | `update_plan` step, `status: pending` |
|
|
353
359
|
| Mark a phase in-progress | `TaskUpdate` → `in_progress` | `phase-tracker.sh update <N> in_progress` | `update_plan` step → `in_progress` |
|
|
354
360
|
| Mark a phase complete | `TaskUpdate` → `completed` | `phase-tracker.sh update <N> completed` | `update_plan` step → `completed` |
|
|
355
361
|
| Mark a phase failed | `TaskUpdate` → `completed` + log failure in agent-log | `phase-tracker.sh update <N> failed` | `update_plan` step → `completed` + failure in agent-log |
|
|
356
|
-
|
|
|
362
|
+
| Register a phase's sub-steps | `add` does it from `schemas/phases.json`; one `TaskCreate` per indented row `tiles` prints | `add` does it; the card draws the rows | `add` does it; `tiles` puts the rows in the `update_plan` payload |
|
|
363
|
+
| Sub-step progress | `phase-tracker.sh sub <N> <sub> <name> <status>`, then the `TaskUpdate` its NEXT block prints | `phase-tracker.sh sub ...`, then `render` | `phase-tracker.sh sub ...`, then the `update_plan` its NEXT block prints (the plan tool has no nesting, so `<N>.<sub>` inside the step text is the hierarchy) |
|
|
357
364
|
|
|
358
365
|
`update_plan` takes the FULL step list, not a delta, so each boundary rewrites the
|
|
359
366
|
whole plan. It must never be called in parallel with another tool, and it is
|
|
@@ -377,7 +384,7 @@ which CLI you typed the command in. Continuous mode therefore requires the
|
|
|
377
384
|
no Copilot or Codex equivalent of the child.
|
|
378
385
|
|
|
379
386
|
| Concept | Claude Code | Copilot CLI | Codex CLI |
|
|
380
|
-
|
|
387
|
+
| ---------------------------- | ---------------------------------------------------------------------------- | --------------------------- | ----------------------------------------------- |
|
|
381
388
|
| Turn the mode on | `/multi-agent:autopilot-on` | `/multi-agent-autopilot-on` | `multi-agent autopilot-on` via the router skill |
|
|
382
389
|
| Scripts, libs, templates | `~/.claude/{scripts,lib,templates}` | `~/.copilot/...` | `~/.codex/...` |
|
|
383
390
|
| Which one is read | `ma_ap_asset <rel>` resolves the caller's own tree first, then the other two | same | same |
|
|
@@ -403,7 +410,7 @@ Codex-only machine rendered a launchd job from a file the host did not have.
|
|
|
403
410
|
Given the same user input, both CLIs must produce identical parsed state:
|
|
404
411
|
|
|
405
412
|
| Input pattern | Parsed as |
|
|
406
|
-
|
|
413
|
+
| --------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
|
|
407
414
|
| `PROJ-12345` (bare Jira ID) | `input.type = "jira-id"`, `input.jiraId = "PROJ-12345"` |
|
|
408
415
|
| `https://{jira-host}/browse/PROJ-12345` | `input.type = "jira-url"`, `input.jiraId = "PROJ-12345"` |
|
|
409
416
|
| `https://github.com/{owner}/{repo}/issues/42` | `input.type = "github-issue-url"`, `input.issueNo = 42`, `input.owner = "{owner}"`, `input.repo = "{repo}"` |
|
|
@@ -411,6 +418,7 @@ Given the same user input, both CLIs must produce identical parsed state:
|
|
|
411
418
|
| Any other string | `input.type = "free-text"`, `input.summary = <string>` |
|
|
412
419
|
|
|
413
420
|
One modifier exists:
|
|
421
|
+
|
|
414
422
|
- `autopilot` - skip confirmations, and resolve the workspace to a worktree without asking.
|
|
415
423
|
|
|
416
424
|
The workspace is not a flag. Where the branch lives is a Phase 0 Step 5b question on attended runs.
|
|
@@ -420,7 +428,7 @@ The workspace is not a flag. Where the branch lives is a Phase 0 Step 5b questio
|
|
|
420
428
|
## 6. Output Format Expectations
|
|
421
429
|
|
|
422
430
|
| Artifact | Both CLIs must produce |
|
|
423
|
-
|
|
431
|
+
| ------------------ | ------------------------------------------------------------------------------------------------------------------------ |
|
|
424
432
|
| `agent-state.json` | Same JSON schema (see `~/.claude/schemas/agent-state.schema.json`); same field names; same values for identical input |
|
|
425
433
|
| `agent-log.md` | Same section order, same phase headers (`📊 Phase 1`, `🧠 Phase 2`, etc.), same timeline columns |
|
|
426
434
|
| PR body | Same template; no CLI-specific headers |
|
|
@@ -443,7 +451,7 @@ those installs). Call sites never invoke `security` themselves - the wrapper is
|
|
|
443
451
|
what keeps a secret off argv and what writes the audit entry.
|
|
444
452
|
|
|
445
453
|
| Purpose | Canonical | Underlying backend (for debugging only) |
|
|
446
|
-
|
|
454
|
+
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------- |
|
|
447
455
|
| Keychain read | `~/.claude/lib/credential-store.sh get <key>` | `security find-generic-password -a "$USER" -s <key> -w` |
|
|
448
456
|
| Keychain write | `~/.claude/lib/credential-store.sh set <key> -` (the secret streams over stdin and stays off argv; `set <key> <value>` is for non-secret values) | `security add-generic-password -a "$USER" -s <key> -w` |
|
|
449
457
|
| Clipboard read | `pbpaste` | - |
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
|
|
12
12
|
**Pattern**: autopilot runs with zero interaction, which is exactly when a silent failure loop is most expensive - an agent can burn a budget re-attempting the same broken fix, or thrash between two phases, with nobody watching. A circuit-breaker converts "keep going no matter what" into "keep going until a defined unsafe condition, then halt and hand back to the user." This is the sanctioned autopilot pause (same class as the Phase 5 channels pause): the run stops, records why, and waits for an explicit `resume`.
|
|
13
13
|
|
|
14
|
-
**Gated by `prefs.global.autopilotCircuitBreaker`** (`enabled` default true, `identicalFindingCycles` default 2, `maxReworkCycles` default
|
|
14
|
+
**Gated by `prefs.global.autopilotCircuitBreaker`** (`enabled` default true, `identicalFindingCycles` default 2, `maxReworkCycles` optional, no default; `schemas/prefs.schema.json`). Halting is always safe, so the breaker itself defaults on. Disable per-run only with an explicit override. Complements, does not replace, the existing autopilot safety rules (build-fail max 3 retries, Phase 4 blocking-finding rework, destructive-op confirmations).
|
|
15
15
|
|
|
16
16
|
## Trip conditions
|
|
17
17
|
|
|
@@ -19,9 +19,9 @@ Any one trips the breaker. All are evaluated from `agent-state.json` + telemetry
|
|
|
19
19
|
|
|
20
20
|
| # | Trigger | Detection | Default threshold |
|
|
21
21
|
|---|---|---|---|
|
|
22
|
-
| 1 | **No-progress stall** | two consecutive phase checkpoints with no forward transition (same `phase` + `step` + `reworkCount`, no new artifact/commit) | 2 checkpoints |
|
|
22
|
+
| 1 | **No-progress stall** | two consecutive phase checkpoints with no forward transition (same `phase` + `step` + `phases["2"].reworkCount`, no new artifact/commit) | 2 checkpoints |
|
|
23
23
|
| 2 | **Identical repeated failure** | same normalized build-error signature, or the same Phase 4 finding fingerprint, recurs across consecutive Phase 3 rework cycles | 2 cycles |
|
|
24
|
-
| 3 | **Rework storm** |
|
|
24
|
+
| 3 | **Rework storm** | `phases["2"].reworkCount` reaches the review limit with accepted findings still open (distinct from the build-retry cap, `retryCount`) | the review rework limit (`features/review-rounds.md`, default 2, 1 to 3), lowered in autopilot by `maxReworkCycles` when that is set |
|
|
25
25
|
| 4 | **Cost drift** | cumulative spend crosses the `costBudget` ceiling, or the projected next-phase spend would exceed it, after model-fallback has already downgraded | `costBudget` ceiling |
|
|
26
26
|
| 5 | **Merge/rebase conflict** | Phase 4 push blocked by a conflict that requires history reconciliation | any conflict |
|
|
27
27
|
|
|
@@ -32,7 +32,7 @@ Trigger 2 is the key addition over the plain build-retry cap: a build can "fail
|
|
|
32
32
|
| Trigger | Evaluated by | Status |
|
|
33
33
|
|---|---|---|
|
|
34
34
|
| 2, finding half | `review-delta.mjs` exit 3 at Phase 3 Step 3.8: a blocking/important finding whose `fingerprint` (finding-fingerprint.mjs) stays in the accepted set for `identicalFindingCycles` consecutive rounds | **code** (v16.20.0) |
|
|
35
|
-
| 3 | Phase 3
|
|
35
|
+
| 3 | Phase 3 Step 4: `review-rounds.mjs next` answers `rule` once `reworkCount >= limit`, the limit being lowered by `maxReworkCycles` in an autopilot run; then `rework-rulings.mjs` rules on every open finding of the current triage; the hard-kill, and the trip, happen only when a ruling is `escalate`. All parked: no trip, the run continues to Phase 4 with them as follow-ups | **code** (v16.20.0, rulings 20.34.0) |
|
|
36
36
|
| 2, build-error half | needs a build-log signature normaliser | documented behaviour, no script yet |
|
|
37
37
|
| 1 | needs checkpoint-to-checkpoint artifact diffing | documented behaviour, no script yet |
|
|
38
38
|
| 4 | belongs to `cost-budget-check.mjs` | documented behaviour, no script yet |
|