@mmerterden/multi-agent-pipeline 20.36.0 → 20.37.1

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.
Files changed (222) hide show
  1. package/CHANGELOG.md +37 -0
  2. package/docs/facts.json +2 -2
  3. package/docs/features.md +1 -1
  4. package/docs/recovery-guide.md +1 -1
  5. package/install/catalog-history.json +1 -1
  6. package/manifest.json +225 -148
  7. package/package.json +1 -1
  8. package/pipeline/commands/multi-agent/SKILL.md +33 -154
  9. package/pipeline/commands/multi-agent/analysis/SKILL.md +14 -68
  10. package/pipeline/commands/multi-agent/analysis-jira/SKILL.md +5 -8
  11. package/pipeline/commands/multi-agent/autopilot-on/SKILL.md +38 -109
  12. package/pipeline/commands/multi-agent/channels/SKILL.md +38 -167
  13. package/pipeline/commands/multi-agent/complaint-analysis/SKILL.md +37 -144
  14. package/pipeline/commands/multi-agent/design-check/SKILL.md +27 -131
  15. package/pipeline/commands/multi-agent/garbage-collect/SKILL.md +22 -48
  16. package/pipeline/commands/multi-agent/ios-coding-standard/SKILL.md +37 -180
  17. package/pipeline/commands/multi-agent/jira/SKILL.md +16 -46
  18. package/pipeline/commands/multi-agent/manual-test/SKILL.md +12 -7
  19. package/pipeline/commands/multi-agent/refactor/SKILL.md +23 -184
  20. package/pipeline/commands/multi-agent/resume/SKILL.md +30 -136
  21. package/pipeline/commands/multi-agent/review/SKILL.md +24 -199
  22. package/pipeline/commands/multi-agent/setup/SKILL.md +25 -181
  23. package/pipeline/commands/multi-agent/stack/SKILL.md +9 -53
  24. package/pipeline/commands/multi-agent/status/SKILL.md +13 -2
  25. package/pipeline/commands/multi-agent/store-ready/SKILL.md +27 -226
  26. package/pipeline/commands/multi-agent/sync/SKILL.md +35 -164
  27. package/pipeline/commands/multi-agent/test-gen/SKILL.md +2 -4
  28. package/pipeline/commands/multi-agent/update/SKILL.md +18 -60
  29. package/pipeline/contract/CHANGELOG.md +9 -0
  30. package/pipeline/contract/fixtures/error-invalid-request.json +1 -1
  31. package/pipeline/contract/fixtures/error-unauthorized.json +1 -1
  32. package/pipeline/contract/fixtures/error-unsigned.json +1 -1
  33. package/pipeline/contract/fixtures/runs-awaiting-question.json +1 -1
  34. package/pipeline/contract/fixtures/runs-empty.json +1 -1
  35. package/pipeline/contract/fixtures/runs-failed.json +1 -1
  36. package/pipeline/contract/fixtures/runs-pr-opened-redacted.json +1 -1
  37. package/pipeline/contract/fixtures/runs-pr-opened.json +1 -1
  38. package/pipeline/contract/fixtures/runs-running.json +1 -1
  39. package/pipeline/contract/manifest.json +5 -5
  40. package/pipeline/contract/types/index.d.ts +3 -2
  41. package/pipeline/multi-agent-refs/audit-guide.md +20 -0
  42. package/pipeline/multi-agent-refs/autopilot-on/details.md +148 -0
  43. package/pipeline/multi-agent-refs/channels/generator.md +14 -0
  44. package/pipeline/multi-agent-refs/channels/preview.md +13 -0
  45. package/pipeline/multi-agent-refs/channels/reference.md +46 -0
  46. package/pipeline/multi-agent-refs/complaint-analysis/phases.md +159 -0
  47. package/pipeline/multi-agent-refs/design-check/export.md +1 -0
  48. package/pipeline/multi-agent-refs/design-check/init-inventory.md +1 -1
  49. package/pipeline/multi-agent-refs/design-check/scope-and-ledger.md +64 -0
  50. package/pipeline/multi-agent-refs/features/analysis-command-notes.md +53 -0
  51. package/pipeline/multi-agent-refs/features/commit-multi-repo.md +63 -0
  52. package/pipeline/multi-agent-refs/features/dev-multi-repo.md +51 -0
  53. package/pipeline/multi-agent-refs/features/test-gap.md +40 -0
  54. package/pipeline/multi-agent-refs/features/worktree-finalize.md +1 -1
  55. package/pipeline/multi-agent-refs/garbage-collect/phases.md +60 -0
  56. package/pipeline/multi-agent-refs/ios-coding-standard/plan.md +71 -0
  57. package/pipeline/multi-agent-refs/ios-coding-standard/resolve-and-scan.md +135 -0
  58. package/pipeline/multi-agent-refs/jira/picker-detail.md +71 -0
  59. package/pipeline/multi-agent-refs/orchestrator/copilot-pipeline.md +88 -0
  60. package/pipeline/multi-agent-refs/orchestrator/dispatcher.md +96 -1
  61. package/pipeline/multi-agent-refs/orchestrator/phase-3-user-test.md +12 -9
  62. package/pipeline/multi-agent-refs/phases/phase-1-plan.md +4 -4
  63. package/pipeline/multi-agent-refs/phases/phase-2-dev.md +8 -47
  64. package/pipeline/multi-agent-refs/phases/phase-3-review.md +21 -65
  65. package/pipeline/multi-agent-refs/phases/phase-4-commit.md +9 -59
  66. package/pipeline/multi-agent-refs/phases/phase-5-report.md +0 -31
  67. package/pipeline/multi-agent-refs/refactor/sweep.md +190 -0
  68. package/pipeline/multi-agent-refs/resume/details.md +115 -2
  69. package/pipeline/multi-agent-refs/review/inputs.md +33 -1
  70. package/pipeline/multi-agent-refs/review/module-guides.md +9 -1
  71. package/pipeline/multi-agent-refs/review/panel.md +75 -0
  72. package/pipeline/multi-agent-refs/review/valven.md +5 -1
  73. package/pipeline/multi-agent-refs/rules.md +1 -1
  74. package/pipeline/multi-agent-refs/setup/hooks-and-plugins.md +4 -0
  75. package/pipeline/multi-agent-refs/setup/token-save-flow.md +13 -0
  76. package/pipeline/multi-agent-refs/stack/background.md +72 -0
  77. package/pipeline/multi-agent-refs/store-ready/gates.md +139 -0
  78. package/pipeline/multi-agent-refs/store-ready/report.md +40 -2
  79. package/pipeline/multi-agent-refs/sync/office.md +10 -0
  80. package/pipeline/multi-agent-refs/sync/overview.md +61 -0
  81. package/pipeline/multi-agent-refs/sync/repo.md +91 -0
  82. package/pipeline/multi-agent-refs/update/details.md +83 -0
  83. package/pipeline/office/index.html +6 -3
  84. package/pipeline/office/toolkit.json +1 -1
  85. package/pipeline/rules/figma-pipeline.md +6 -3
  86. package/pipeline/schemas/prefs.schema.json +1 -1
  87. package/pipeline/schemas/runs-index.schema.json +2 -1
  88. package/pipeline/scripts/_memory-policy.mjs +27 -5
  89. package/pipeline/scripts/checkpoint-fold.sh +59 -0
  90. package/pipeline/scripts/contract-server.mjs +1 -1
  91. package/pipeline/scripts/gate-ledger.mjs +1 -1
  92. package/pipeline/scripts/office-control.mjs +41 -15
  93. package/pipeline/scripts/offload-ref.sh +1 -1
  94. package/pipeline/scripts/rework-rulings.mjs +5 -3
  95. package/pipeline/scripts/runs-index.mjs +34 -7
  96. package/pipeline/scripts/scope-check-gate.mjs +15 -2
  97. package/pipeline/scripts/status-overview.mjs +401 -0
  98. package/pipeline/scripts/user-test-handoff.sh +203 -0
  99. package/pipeline/scripts/validate-planning.mjs +5 -3
  100. package/pipeline/scripts/validate-triage.mjs +2 -1
  101. package/pipeline/scripts/write-state.mjs +13 -4
  102. package/pipeline/skills/.skill-manifest.json +64 -64
  103. package/pipeline/skills/shared/core/apple-archive-compliance/SKILL.md +7 -70
  104. package/pipeline/skills/shared/core/apple-archive-compliance/references/examples.md +67 -0
  105. package/pipeline/skills/shared/core/apple-archive-compliance/references/version-history.md +8 -0
  106. package/pipeline/skills/shared/core/google-play-compliance/SKILL.md +10 -72
  107. package/pipeline/skills/shared/core/google-play-compliance/references/examples.md +69 -0
  108. package/pipeline/skills/shared/core/google-play-compliance/references/notes.md +7 -0
  109. package/pipeline/skills/shared/core/google-play-compliance/references/version-history.md +5 -0
  110. package/pipeline/skills/shared/core/multi-agent/SKILL.md +39 -262
  111. package/pipeline/skills/shared/core/multi-agent-autopilot-on/SKILL.md +35 -73
  112. package/pipeline/skills/shared/core/multi-agent-channels/SKILL.md +37 -337
  113. package/pipeline/skills/shared/core/multi-agent-design-check/SKILL.md +27 -122
  114. package/pipeline/skills/shared/core/multi-agent-help/SKILL.md +8 -340
  115. package/pipeline/skills/shared/core/multi-agent-ios-coding-standard/SKILL.md +37 -180
  116. package/pipeline/skills/shared/core/multi-agent-manual-test/SKILL.md +12 -7
  117. package/pipeline/skills/shared/core/multi-agent-refactor/SKILL.md +23 -184
  118. package/pipeline/skills/shared/core/multi-agent-review/SKILL.md +14 -82
  119. package/pipeline/skills/shared/core/multi-agent-setup/SKILL.md +25 -277
  120. package/pipeline/skills/shared/core/multi-agent-status/SKILL.md +13 -2
  121. package/pipeline/skills/shared/core/multi-agent-sync/SKILL.md +73 -217
  122. package/pipeline/skills/shared/external/alarmkit/SKILL.md +11 -162
  123. package/pipeline/skills/shared/external/alarmkit/references/alarmkit-code.md +257 -0
  124. package/pipeline/skills/shared/external/android-architecture/SKILL.md +7 -58
  125. package/pipeline/skills/shared/external/android-architecture/references/code-examples.md +68 -0
  126. package/pipeline/skills/shared/external/app-intents/SKILL.md +3 -45
  127. package/pipeline/skills/shared/external/app-intents/references/code-examples.md +54 -0
  128. package/pipeline/skills/shared/external/app-store-optimization/SKILL.md +5 -81
  129. package/pipeline/skills/shared/external/app-store-optimization/references/engagement-and-localization.md +96 -0
  130. package/pipeline/skills/shared/external/app-store-review/SKILL.md +6 -112
  131. package/pipeline/skills/shared/external/app-store-review/references/monetization-and-submission.md +138 -0
  132. package/pipeline/skills/shared/external/apple-on-device-ai/SKILL.md +10 -117
  133. package/pipeline/skills/shared/external/apple-on-device-ai/references/foundation-models-code.md +186 -0
  134. package/pipeline/skills/shared/external/authentication/SKILL.md +3 -50
  135. package/pipeline/skills/shared/external/authentication/references/code-examples.md +59 -0
  136. package/pipeline/skills/shared/external/callkit-voip/SKILL.md +3 -84
  137. package/pipeline/skills/shared/external/callkit-voip/references/code-examples.md +93 -0
  138. package/pipeline/skills/shared/external/ci-cd-pipelines/SKILL.md +7 -263
  139. package/pipeline/skills/shared/external/ci-cd-pipelines/references/pipeline-examples.md +281 -0
  140. package/pipeline/skills/shared/external/clean-code/SKILL.md +8 -41
  141. package/pipeline/skills/shared/external/clean-code/references/code-examples.md +56 -0
  142. package/pipeline/skills/shared/external/cloudkit-sync/SKILL.md +8 -146
  143. package/pipeline/skills/shared/external/cloudkit-sync/references/cloudkit-code.md +214 -0
  144. package/pipeline/skills/shared/external/compose-components/SKILL.md +6 -80
  145. package/pipeline/skills/shared/external/compose-components/references/code-examples.md +89 -0
  146. package/pipeline/skills/shared/external/compose-navigation/SKILL.md +5 -64
  147. package/pipeline/skills/shared/external/compose-navigation/references/code-examples.md +70 -0
  148. package/pipeline/skills/shared/external/core-data/SKILL.md +9 -157
  149. package/pipeline/skills/shared/external/core-data/references/core-data-code.md +221 -0
  150. package/pipeline/skills/shared/external/core-nfc/SKILL.md +3 -89
  151. package/pipeline/skills/shared/external/core-nfc/references/code-examples.md +98 -0
  152. package/pipeline/skills/shared/external/coreml/SKILL.md +17 -133
  153. package/pipeline/skills/shared/external/coreml/references/coreml-code.md +208 -0
  154. package/pipeline/skills/shared/external/css-modern/SKILL.md +8 -131
  155. package/pipeline/skills/shared/external/css-modern/references/code-examples.md +142 -0
  156. package/pipeline/skills/shared/external/database-patterns/SKILL.md +6 -103
  157. package/pipeline/skills/shared/external/database-patterns/references/orm-examples.md +112 -0
  158. package/pipeline/skills/shared/external/html-semantic/SKILL.md +7 -48
  159. package/pipeline/skills/shared/external/html-semantic/references/code-examples.md +54 -0
  160. package/pipeline/skills/shared/external/humanizer/SKILL.md +6 -19
  161. package/pipeline/skills/shared/external/humanizer/references/voice.md +24 -0
  162. package/pipeline/skills/shared/external/ios-accessibility/SKILL.md +13 -170
  163. package/pipeline/skills/shared/external/ios-accessibility/references/assistive-tech-review.md +224 -0
  164. package/pipeline/skills/shared/external/ios-localization/SKILL.md +2 -24
  165. package/pipeline/skills/shared/external/ios-localization/references/code-examples.md +30 -0
  166. package/pipeline/skills/shared/external/ios-networking/SKILL.md +3 -58
  167. package/pipeline/skills/shared/external/ios-networking/references/code-examples.md +67 -0
  168. package/pipeline/skills/shared/external/ios-security/SKILL.md +4 -64
  169. package/pipeline/skills/shared/external/ios-security/references/code-examples.md +74 -0
  170. package/pipeline/skills/shared/external/live-activities/SKILL.md +4 -90
  171. package/pipeline/skills/shared/external/live-activities/references/code-examples.md +108 -0
  172. package/pipeline/skills/shared/external/localization-reuse-map/SKILL.md +9 -23
  173. package/pipeline/skills/shared/external/localization-reuse-map/references/project-settings.md +22 -0
  174. package/pipeline/skills/shared/external/mapkit-location/SKILL.md +5 -95
  175. package/pipeline/skills/shared/external/mapkit-location/references/code-examples.md +117 -0
  176. package/pipeline/skills/shared/external/nextjs-app-router/SKILL.md +7 -106
  177. package/pipeline/skills/shared/external/nextjs-app-router/references/app-router-examples.md +124 -0
  178. package/pipeline/skills/shared/external/permissionkit/SKILL.md +2 -31
  179. package/pipeline/skills/shared/external/permissionkit/references/code-examples.md +37 -0
  180. package/pipeline/skills/shared/external/play-store-review/SKILL.md +6 -74
  181. package/pipeline/skills/shared/external/play-store-review/references/signing-and-policies.md +83 -0
  182. package/pipeline/skills/shared/external/push-notifications/SKILL.md +8 -125
  183. package/pipeline/skills/shared/external/push-notifications/references/notification-code.md +176 -0
  184. package/pipeline/skills/shared/external/python-patterns/SKILL.md +7 -158
  185. package/pipeline/skills/shared/external/python-patterns/references/python-examples.md +176 -0
  186. package/pipeline/skills/shared/external/rest-api-design/SKILL.md +7 -157
  187. package/pipeline/skills/shared/external/rest-api-design/references/api-examples.md +175 -0
  188. package/pipeline/skills/shared/external/swift-architecture/SKILL.md +11 -230
  189. package/pipeline/skills/shared/external/swift-architecture/references/pattern-examples.md +295 -0
  190. package/pipeline/skills/shared/external/swift-codable/SKILL.md +17 -149
  191. package/pipeline/skills/shared/external/swift-codable/references/codable-recipes.md +207 -0
  192. package/pipeline/skills/shared/external/swift-concurrency/SKILL.md +12 -99
  193. package/pipeline/skills/shared/external/swift-concurrency/references/code-examples.md +100 -0
  194. package/pipeline/skills/shared/external/swift-concurrency/references/swift-6-2-additions.md +18 -0
  195. package/pipeline/skills/shared/external/swift-formatstyle/SKILL.md +9 -78
  196. package/pipeline/skills/shared/external/swift-formatstyle/references/formatstyle-examples.md +113 -0
  197. package/pipeline/skills/shared/external/swift-language/SKILL.md +3 -56
  198. package/pipeline/skills/shared/external/swift-language/references/code-examples.md +65 -0
  199. package/pipeline/skills/shared/external/swift-testing-pro/SKILL.md +1 -0
  200. package/pipeline/skills/shared/external/swiftdata/SKILL.md +6 -122
  201. package/pipeline/skills/shared/external/swiftdata/references/code-examples.md +140 -0
  202. package/pipeline/skills/shared/external/swiftui-uikit-interop/SKILL.md +12 -139
  203. package/pipeline/skills/shared/external/swiftui-uikit-interop/references/interop-code.md +198 -0
  204. package/pipeline/skills/shared/external/tailwind-css/SKILL.md +9 -81
  205. package/pipeline/skills/shared/external/tailwind-css/references/code-examples.md +91 -0
  206. package/pipeline/skills/shared/external/testing-backend/SKILL.md +7 -207
  207. package/pipeline/skills/shared/external/testing-backend/references/testing-examples.md +225 -0
  208. package/pipeline/skills/shared/external/typescript-patterns/SKILL.md +8 -89
  209. package/pipeline/skills/shared/external/typescript-patterns/references/code-examples.md +100 -0
  210. package/pipeline/skills/shared/external/vision-framework/SKILL.md +2 -20
  211. package/pipeline/skills/shared/external/vision-framework/references/code-examples.md +26 -0
  212. package/pipeline/skills/shared/external/vue-composition/SKILL.md +7 -169
  213. package/pipeline/skills/shared/external/vue-composition/references/vue-examples.md +187 -0
  214. package/pipeline/skills/shared/external/web-accessibility/SKILL.md +7 -174
  215. package/pipeline/skills/shared/external/web-accessibility/references/a11y-examples.md +192 -0
  216. package/pipeline/skills/shared/external/web-performance/SKILL.md +8 -66
  217. package/pipeline/skills/shared/external/web-performance/references/code-examples.md +77 -0
  218. package/pipeline/skills/shared/external/web-testing/SKILL.md +11 -186
  219. package/pipeline/skills/shared/external/web-testing/references/testing-examples.md +213 -0
  220. /package/pipeline/skills/shared/external/localization-reuse-map/{reference → references}/format-and-output.md +0 -0
  221. /package/pipeline/skills/shared/external/localization-reuse-map/{reference → references}/publish-and-snapshot.md +0 -0
  222. /package/pipeline/skills/shared/external/localization-reuse-map/{reference → references}/sources-and-recipes.md +0 -0
@@ -44,89 +44,21 @@ Skip Phase 0-3 and review a diff only. Input shapes: a PR (`#N`, `repo#N`, GitHu
44
44
  - branch name -> `kind=branch` (local).
45
45
  - **empty + interactive** -> `kind=pick` (Step 1a picker); **empty + autopilot** -> current branch.
46
46
 
47
- 1a. **No-input PR picker** (interactive only): list open PRs across both providers and multi-select which to review.
48
- - GitHub: `gh pr list --state open --json number,title,url,headRefName,updatedAt` (current repo) plus `gh search prs --state open --review-requested=@me`/`--author=@me`.
49
- - Bitbucket Server: for each configured repo, `GET /rest/api/1.0/projects/{KEY}/repos/{slug}/pull-requests?state=OPEN` (creds via `credential-store`).
50
- - Merge + label each row `(github)`/`(bitbucket)`, then AskUserQuestion `multiSelect: true` (breadcrumb per `multi-agent-refs/picker-contract.md`). Review each selected PR (loop steps 2-6). Empty list or none selected -> fall back to the current branch.
47
+ 1a. **No-input PR picker** (interactive only): list open PRs across both providers (a missing token or CLI contributes nothing), AskUserQuestion `multiSelect: true` (breadcrumb per `multi-agent-refs/picker-contract.md`), and review each selected PR (loop steps 2-6). Empty list or none selected -> fall back to the current branch. List commands and picker fields: `$HOME/.claude/multi-agent-refs/review/inputs.md` "Step 1a".
51
48
 
52
- 2. **Get the diff** - kind-aware:
53
- ```bash
54
- # branch: git diff origin/develop...HEAD
55
- # github PR: gh pr diff "$N" --repo "$org/$repo" (+ head SHA for inline anchors)
56
- # bitbucket PR: curl -u "$BB_USER:$BB_TOKEN" .../pull-requests/$N/diff?contextLines=10
57
- ```
49
+ 2. **Get the diff** - kind-aware (branch `git diff origin/develop...HEAD`; GitHub `gh pr diff` + head SHA for inline anchors; Bitbucket the REST diff with credentials via `credential-store`, never on argv). Exact commands: `review/inputs.md` "Step 2".
58
50
 
59
- 2c. **Valven delivery rules** - required on every input. Run `node "$HOME/.claude/scripts/valven-gate.mjs" --mode review --out "$VG_FILE"` plus the input's sources: a branch adds `--repo . --base origin/develop --head <ref>`; a PR adds `--branch <headRef> --pr-body-file <body> --commits-file <one subject per line> --pr-meta-file <timeline>` (GitHub: `node "$HOME/.claude/scripts/pr-timeline.mjs" --repo <owner/repo> --pr <N> --out <file>` writes the PR with its ready-for-review time and bot-typed reviews; read the head ref, body and commits from it and pass it as the timeline. Bitbucket `fromRef.displayId`, `description`, `/commits`, and a timeline written as `{createdAt, readyAt, isDraft, reviewerCount, firstReviewAt, approvedAt, mergedAt, closedAt}` from the PR and `/activities`, reviews by the author left out) and either `--repo . --base origin/<baseRef> --head FETCH_HEAD` after `git fetch origin <headRef>` when the cwd is that repo, or `--diff-file <patch>` (rework then reports `not-measured`). Exit 0 clean, 1 findings, 2 could not run: print `Valven: not measured (<reason>)`, never "passed". `findings[]` (`tag: valven`) join the reviewer findings at step 5 and are accepted unless the task is exempt, so an `important` one makes step 7 NEEDS WORK. Old-work findings (`VLV-AGE-01`, `VLV-BEHIND-01`, `VLV-TRACE-03`; commit lines are `<ISO author date>\t<subject>`) get the `valven-port.mjs` plan in their fix: new branch, dropped commits, then "open the new PR, close this one". When `splitRequired`, run `valven-split.mjs` with the same base and head (no `--apply`) and add its slice table to the `VLV-SIZE-01` fix. The duration rules (`VLV-CYCLE-01..03`) are `suggestion` findings with a Valven score and never set NEEDS WORK on their own; `VLV-PICKUP-01` is `important` for no reviewer and a `suggestion` for a draft older than 3 hours. Step 6 adds `Valven scores: churn · coding · pickup · review` from the report's `scores`, `-` where one is missing. The registry's judgement rules (`VLV-SCOPE-02`, `VLV-PRDESC-02`, from the `valven-rules` skill's `references/rules.yml`) go into every reviewer prompt in step 3. Contract: the `valven-rules` skill.
60
-
61
- 3. **Start parallel reviewers** - three on every host; only the second slot differs, because GPT-5.4 exists on Copilot and Codex but not on Claude Code, where Opus fills it:
62
-
63
- **Claude Code (3 in parallel while the fable rung is on, 2 while it is off).** Resolve the fable slots first; this command has no Phase 0:
64
- `REVIEW_RUNG=$(bash "$HOME/.claude/lib/model-dispatch.sh" subagent --persona reviewer --default fable)` and the same with `--persona triage` for `TRIAGE_RUNG`. Anything but `fable` drops Agent 1 and runs triage on `TRIAGE_RUNG`.
65
- - Agent 1: `claude-fable-5-1` → security + architecture (only when `REVIEW_RUNG` is `fable`)
66
- - Agent 2: `claude-opus-5-5` → edge cases, different perspective
67
- - Agent 3: `claude-sonnet-5-5` → general quality
68
-
69
- **Copilot CLI (3 in parallel):**
70
- - Agent 1: `claude-opus-4.7` → security + architecture (Fable is not offered on Copilot CLI)
71
- - Agent 2: `gpt-5.4` → edge cases, different perspective
72
- - Agent 3: `claude-sonnet-4.6` → general quality
73
-
74
- **Codex CLI (3 in parallel, single vendor):**
75
- - Agent 1: `gpt-5.6` @ `xhigh` → security + architecture
76
- - Agent 2: `gpt-5.4` @ `high` → edge cases, different perspective
77
- - Agent 3: `gpt-5.6` @ `medium` → general quality
78
-
79
- The rung switch and its resolution: `multi-agent-refs/features/model-fallback.md`.
80
-
81
- 4. **Store-compliance cross-reference** - if iOS/Android release-relevant files changed, the matching catalog is loaded:
82
-
83
- | Platform | Trigger files | Catalog to load |
84
- |---|---|---|
85
- | iOS | `**/Info.plist`, `**/PrivacyInfo.xcprivacy`, `**/*.entitlements`, `**/*App.swift`, `**/AppDelegate*.swift`, `**/SceneDelegate*.swift`, `**/project.pbxproj` | `$HOME/.claude/skills/apple-archive-compliance/SKILL.md` - 18 rules + ITMS refs |
86
- | Android | `**/AndroidManifest.xml`, `**/build.gradle(.kts)`, `**/proguard-rules.pro`, `**/network_security_config.xml` | `$HOME/.claude/skills/google-play-compliance/SKILL.md` - 21 rules + Play policy refs |
87
-
88
- It appends the catalog's `ruleID` + the Apple ITMS / Play policy ref to each finding:
89
- - iOS example: `(apple-archive-compliance / info-plist - Guideline 5.1.1)`
90
- - Android example: `(google-play-compliance / dangerous-permissions - Policy - Permissions)`
91
-
92
- It does NOT invoke any binary/tool - the review stage only uses the catalog. For a full scan use `multi-agent-test "store-ready"`.
93
-
94
- 4b. **Platform parity cross-check** (advisory, read-only) - when a counterpart repo
95
- resolves whose `stack` is the other mobile platform and the diff touches a screen, a
96
- service, a request model or a localization file, compare the change against that repo
97
- on four axes: endpoints called, parameters sent, business rules around the call,
98
- localization keys used. When the project belongs to a product
99
- (`prefs.global.products`), the counterparts are the product's other repositories,
100
- resolved with `product-context.mjs refs` and compared at their latest integration
101
- branch through the toolkit's `repo_*` tools, pinned to a sha
102
- (`features/product-context.md`). Otherwise the counterpart is resolved automatically and in both
103
- directions (ios ↔ android) from four sources in this order, first hit wins:
104
- `--with <path|owner/repo>` (a one-off override, remembered like any other resolution),
105
- then a remembered `prefs.projects[<slug>].counterpartRoots[]`, then the primary
106
- checkout's sibling directories, then `state.siblings[]` from the Phase 0 dev-context
107
- picker. None of them is a precondition for the others. One match is used and
108
- remembered; several are asked about interactively and skipped in autopilot; none
109
- skips silently. Stack comes from marker files, never from the repo name.
110
-
111
- The counterpart is located through the code graph, capped at 8 files, and is **read
112
- only** - never edited, staged, committed, pushed or built. Output is its own
113
- `Platform parity` section; findings are advisory and never blocking. No counterpart
114
- repo, or nothing comparable in the diff → skipped silently.
115
-
116
- Contract: `$HOME/.claude/multi-agent-refs/platform-parity.md`.
117
-
118
- 5. **Triage** - classify the findings:
119
- - 🔴 **Blocking** → must fix
120
- - 🟡 **Important** → fix recommended
121
- - 🟢 **Suggestion** → optional
122
-
123
- Triage also settles every reviewer `cannotVerify` row: `verified` with the file:line read, `finding` with the file:line of the accepted or deferred finding, or `out-of-scope`. Unsettled rows are listed in the summary.
124
-
125
- 6. **Show a summary** (always prints, any mode):
126
- ```
127
- 🔍 Review Complete
128
- | Model | Verdict | Blocking | Important | Suggestion |
129
- Consensus: ✅ APPROVED
130
- ```
51
+ 2c. **Valven delivery rules** - required on every input. Read `$HOME/.claude/multi-agent-refs/review/valven.md` before this step: gate arguments per input (branch, GitHub with `pr-timeline.mjs`, Bitbucket), checkout vs `--diff-file`, old-work port plans, split plans, cycle and pickup severities, and the judgement rules (`VLV-SCOPE-02`, `VLV-PRDESC-02`) that go into every reviewer prompt in step 3. Two rules always hold: exit 2 prints `Valven: not measured (<reason>)`, never "passed"; `findings[]` (`tag: valven`) join at step 5 and are accepted unless the task is exempt, so an `important` one makes step 7 NEEDS WORK.
52
+
53
+ 3. **Start parallel reviewers** - three on every host. On Claude Code resolve the fable slots first (this command has no Phase 0):
54
+ `REVIEW_RUNG=$(bash "$HOME/.claude/lib/model-dispatch.sh" subagent --persona reviewer --default fable)` and the same with `--persona triage` for `TRIAGE_RUNG`. Anything but `fable` drops Agent 1 and runs triage on `TRIAGE_RUNG`. Read `$HOME/.claude/multi-agent-refs/review/panel.md` "Reviewers" before dispatch: the Claude Code, Copilot CLI (Opus + GPT-5.4 + Sonnet, no Fable) and Codex CLI panels. The rung switch: `multi-agent-refs/features/model-fallback.md`.
55
+
56
+ 4. **Store-compliance cross-reference** - if iOS/Android release-relevant files changed, load the matching catalog (`$HOME/.claude/skills/apple-archive-compliance/SKILL.md` or `$HOME/.claude/skills/google-play-compliance/SKILL.md`) and append its `ruleID` + the Apple ITMS / Play policy ref to each finding. Catalog only, never a binary; a full scan is `multi-agent-test "store-ready"`. Trigger files and citation format: `review/panel.md` "Store compliance".
57
+
58
+ 4b. **Platform parity cross-check** (advisory, read-only) - when a counterpart repo on the other mobile platform resolves and the diff touches a screen, service, request model or localization file, compare endpoints, parameters, business rules and localization keys. In a product (`prefs.global.products`) the counterparts come from `product-context.mjs refs` and the toolkit's `repo_*` tools, pinned to a sha; otherwise from `--with`, a remembered `counterpartRoots[]`, sibling checkouts, then `state.siblings[]`, first hit wins. Several are asked about interactively and skipped in autopilot; none skips silently. The counterpart is **read only** - never edited, staged, committed, pushed or built; findings are advisory, in their own `Platform parity` section. Contract: `$HOME/.claude/multi-agent-refs/platform-parity.md`.
59
+
60
+ 5. **Triage** - classify 🔴 **Blocking** / 🟡 **Important** / 🟢 **Suggestion**, and settle every reviewer `cannotVerify` row: `verified` with the file:line read, `finding` with the file:line of the accepted or deferred finding, or `out-of-scope`. Unsettled rows are listed in the summary.
61
+
62
+ 6. **Show a summary** (always prints, any mode): one row per reviewer, then consensus (`review/panel.md` "Summary").
131
63
 
132
64
  7. **Post to PR** - only when `kind=pr` (full contract: `$HOME/.claude/multi-agent-refs/channels/pr-review-actions.md`). Decision from accepted findings: 0 accepted blocking AND 0 accepted important -> APPROVE, else NEEDS WORK. Posts one inline comment per accepted blocking/important finding (in `outputLanguage`), then sets the review state via the provider API. Interactive prompts to post (default yes); autopilot auto-posts; `--no-post` skips. Entry point: `bash $HOME/.copilot/lib/post-pr-review.sh "$TASK_ID"`. No monolithic advisory comment. Branch/pick-fallback runs stay chat-only.
@@ -18,11 +18,7 @@ metadata:
18
18
 
19
19
  ## Step 0 - What is actually wrong
20
20
 
21
- ```bash
22
- node "$HOME/.copilot/scripts/doctor.mjs"
23
- ```
24
-
25
- Run it before the first question and again at the end. The first run makes setup targeted: never ask for a token that is already mapped and answering. The second run is how setup ends - "setup complete" is a claim, and the doctor's exit code is the evidence. Report both in `outputLanguage`; if the second run still shows a BLOCK, say so plainly rather than closing on the word "complete".
21
+ Run `node "$HOME/.copilot/scripts/doctor.mjs"` before the first question (never ask for a token that is already mapped and answering) and again at the end: its exit code, not the word "complete", decides how setup ends. Report both in `outputLanguage`; a remaining BLOCK is said plainly.
26
22
 
27
23
  ## Sections
28
24
 
@@ -30,318 +26,77 @@ Run it before the first question and again at the end. The first run makes setup
30
26
 
31
27
  ## Setup (Credential Store + Git Identity Onboarding)
32
28
 
33
- Uses `~/.copilot/lib/credential-store.sh` to read/write secrets in the macOS Keychain (`security`, built in); the pipeline is macOS only (ADR-0012). Run `~/.copilot/lib/credential-store.sh doctor` first - it prints the platform and whether the backend is usable. The shell driver auto-delegates `get`/`set`/`delete` to the deterministic Python helper at `$HOME/.copilot/scripts/keychain.py` (Python 3 stdlib only, no external deps). The Python path writes both `-l` (label) and `-s` (service) attributes so items are findable regardless of how callers look them up. Set `KEYCHAIN_DELEGATE=0` to force the raw shell path.
34
-
35
29
  ### Step 0 - Language Selection
36
30
 
37
- Ask BEFORE anything else, so every subsequent setup prompt and the rest of the pipeline honour the choice. The pipeline has two language axes:
38
-
39
- - `promptLanguage`: picker chrome only (the `AskUserQuestion` `header` chip, host error UI, internal contract identifiers). **Not configurable - fixed to `en`**; the chip is capped at 12 chars, which most Turkish equivalents overflow.
40
- - `outputLanguage`: the assistant's non-interactive explanations, status updates, error messages and pipeline-generated reports. Set here, changeable later via `/multi-agent-language <en|tr>`.
41
-
42
- `promptLanguage` is seeded as `"en"` and never offered to the user. Language matrix: `multi-agent-refs/rules.md`.
43
-
44
- The wizard asks one question (English UI per skill-prompt rules):
45
-
46
- ```
47
- Which language should the assistant use for ITS OWN explanations,
48
- status updates, and pipeline-generated reports?
49
- 1) English
50
- 2) Türkçe
51
- Select (1-2):
52
- ```
53
-
54
- **Rules:**
55
-
56
- - **Already set in prefs** → skip silently. User can change later with `/multi-agent-language <en|tr>` or `/multi-agent-language output <en|tr>`.
57
- - **New value** → validate against the schema enum (`en`, `tr`), write `prefs.global.outputLanguage` via atomic rename, force `prefs.global.promptLanguage = "en"`, then echo a confirmation in the just-chosen `outputLanguage`:
58
- - `en`: `outputLanguage=<Y>. promptLanguage stays "en". Commits stay English; PR/Jira/wiki bodies follow it.`
59
- - `tr`: `outputLanguage=<Y>. promptLanguage "en" sabit. Commit'ler İngilizce; PR/Jira/wiki metinleri onu izler.`
60
- - **Unknown input** → re-ask once, then abort setup with a hint pointing to `/multi-agent-language`.
61
-
62
- From here on, every prompt in Steps 1-6 follows the per-field matrix in
63
- `$HOME/.claude/multi-agent-refs/rules.md` ("Language Application"): `question`, `label`
64
- and `description` render in `outputLanguage`, `header` stays English; wizard status and
65
- the post-setup summary follow `outputLanguage`. `promptLanguage` governs only the button
66
- and chip chrome, never the question a user reads.
31
+ Ask BEFORE anything else: one question, `outputLanguage` (`en` / `tr`); already set: skip silently. `promptLanguage` is fixed to `"en"` and never offered. From here on `question`, `label` and `description` render in `outputLanguage`; `header` stays English. Read `$HOME/.claude/multi-agent-refs/setup/language.md` before Step 0.
67
32
 
68
33
  ### Step 0.5 - Dependency check
69
34
 
70
- ```bash
71
- ~/.copilot/lib/credential-store.sh doctor
72
- command -v pdftotext >/dev/null 2>&1 || echo "pdftotext: MISSING"
73
- ```
74
-
75
- | Output | Action |
76
- |--------|--------|
77
- | `Backend: ✓` | Continue to Step 1 |
78
- | Platform `unknown` or `ERR: macOS only` | Halt - the pipeline runs on macOS only (ADR-0012). |
79
- | `pdftotext: MISSING` | Advisory. Print `brew install poppler`, continue. `.docx` needs nothing. |
35
+ Run `~/.copilot/lib/credential-store.sh doctor` and `command -v pdftotext`. `Backend: ✓`: continue. Platform `unknown` or `ERR: macOS only`: **halt**. `pdftotext` missing: advise `brew install poppler`, continue.
80
36
 
81
37
  ### Credential Key Naming Rule
82
38
 
83
- - **New token** (first-time creation in Step 3): ALWAYS use the standard key name (`${USER}_Jira_Access_Token`, etc.). This ensures cross-machine consistency.
84
- - **Existing token** (discovered in Step 1): NEVER rename or migrate. Map the discovered key name as-is into `keychainMapping`. The mapping layer abstracts the actual key name - the pipeline never reads the credential store directly by standard name.
39
+ - **New token** (Step 3): ALWAYS the standard key name (`${USER}_Jira_Access_Token`, etc.).
40
+ - **Existing token** (Step 1): NEVER rename or migrate; map the discovered name as-is into `keychainMapping`.
85
41
 
86
42
  ### Step 1 - Dynamic Credential Discovery
87
43
 
88
- Full procedure: `$HOME/.claude/multi-agent-refs/setup/discovery.md`. Read it for Step 1.
44
+ Read `$HOME/.claude/multi-agent-refs/setup/discovery.md` for Step 1.
89
45
 
90
46
  ### Step 2 - Show Discovery Summary + Save Mapping
91
47
 
92
- Show results grouped by status:
93
-
94
- ```
95
- Keychain Token Discovery (${USER}):
96
-
97
- Jira -> ${USER}_Jira_Access_Token
98
- GitHub -> ${USER}_Github
99
- Figma -> ${USER}_Figma_Access_Token
100
- Firebase -> ${USER}_Firebase_Access_Json
101
- Confluence -> MISSING
102
- Jenkins -> MISSING
103
- ---
104
- Git identities: check preferences file (see Step 3)
105
-
106
- Mapped: 8 | Missing: 4
107
- ```
108
-
109
- Save the resolved mapping to `prefs.global.keychainMapping` - every service ID gets an entry, the discovered key name verbatim or `null` when nothing was found:
110
-
111
- ```json
112
- { "jira": "${USER}_Jira_Access_Token", "github": "${USER}_Github", "confluence": null, "...": "..." }
113
- ```
114
-
115
- Full key list and shape: `$HOME/.claude/multi-agent-refs/keychain.md`.
116
-
117
- `null` = not mapped (missing or skipped). Pipeline phases read this mapping to retrieve tokens dynamically - never hardcoded key names.
48
+ Show one line per service with its key or `MISSING`, then the counts (`$HOME/.claude/multi-agent-refs/setup/summaries.md`). Save every service ID to `prefs.global.keychainMapping`, the discovered key name verbatim or `null` (key list: `$HOME/.claude/multi-agent-refs/keychain.md`). Phases read this mapping, never hardcoded key names.
118
49
 
119
50
  ### Step 2.7 - Operational reporting
120
51
 
121
- Ask (in `outputLanguage`), and proceed only on an explicit yes:
122
-
123
- ```
124
- Do you have an operational-reporting token from your admin?
125
- [ Paste token / Skip ]
126
- ```
127
-
128
- On paste, store it in the credential store ONLY - never in a file, prefs value,
129
- git or any synced tree - under the standard per-user name, so it is revocable on
130
- its own:
52
+ Ask whether the user has an operational-reporting token; proceed only on an explicit yes. On paste, store it in the credential store ONLY (never a file, prefs value, git or synced tree): `pbpaste | ~/.copilot/lib/credential-store.sh set "${USER}_Usage_Ingest_Token" -` then `pbcopy < /dev/null`. Pasted or skipped, run `node "$HOME/.copilot/scripts/usage-register.mjs" --json`; on `"needsPersonalAccount":true` ask once for a GitHub username (Skip leaves reporting off) and re-run with `--login <name>`. What is sent: `$HOME/.claude/multi-agent-refs/features/usage-reporting.md`.
131
53
 
132
- ```bash
133
- pbpaste | ~/.copilot/lib/credential-store.sh set "${USER}_Usage_Ingest_Token" -
134
- pbcopy < /dev/null
135
- ```
136
-
137
- Then, **whether they pasted or skipped**, run:
138
-
139
- ```bash
140
- node "$HOME/.copilot/scripts/usage-register.mjs" --json
141
- ```
142
-
143
- If its JSON line says `"needsPersonalAccount":true`, ask once for the person's
144
- GitHub username (free text; Skip leaves reporting off) and run
145
- `node "$HOME/.copilot/scripts/usage-register.mjs" --login <name> --json`.
146
-
147
- It maps whatever token exists and switches reporting on, and requests a
148
- per-machine write-only one when none resolves. Setup is a registration entry point
149
- in its own right, so a machine that runs setup and never runs update still reports.
150
- What is sent, what never is, and `usageLog.optOut`:
151
- `$HOME/.claude/multi-agent-refs/features/usage-reporting.md`.
152
-
153
- ### Auto-learned fields (no setup step needed)
154
-
155
- **Jira Project Key**: auto-learned from pipeline usage. User runs `/multi-agent ABC-123` → `ABC` is extracted and saved to `prefs.global.defaultJiraKey` (first ever) and `prefs.projects[{project}].jiraProjectKeys` (per-project). Multiple keys accumulate over time - most recent first, deduped. Phase 0 Step 1 (Parse Input) handles extraction.
156
-
157
- **Git Identity**: auto-learned from token onboarding. Each token saved in Step 3 triggers an identity prompt (see Token Save Flow Step C). No separate identity setup step.
54
+ The Jira project key and git identity are learned from use, never asked (`$HOME/.claude/multi-agent-refs/setup/accounts.md` "Auto-learned fields").
158
55
 
159
56
  ### Step 3 - Interactive token onboarding (for missing tokens)
160
57
 
161
- Git identities are NOT asked as a separate step. They are learned when tokens are added via the Token Save Flow below. Each token save triggers an identity prompt:
162
-
163
- ```
164
- Token saved. Which git identity uses this token?
165
- 1. Ada Lovelace <ada@example.com>
166
- 2. Ada Lovelace <ada@personal.com>
167
- n. Create new identity
168
- Select:
169
- ```
170
-
171
- - First token ever → no existing identities → asks name + email → creates identity → maps token
172
- - Subsequent tokens → pick existing or create new → maps token to that identity's `servicePatMap`
173
- - Multiple accounts per platform supported (e.g. two GitHub tokens, each mapped to a different identity)
174
- - Identity is stored in `prefs.global.identities[]`, token-to-identity binding in `identity.servicePatMap`
175
-
176
- **Legacy compatibility**: If `prefs.global.gitIdentities` (deprecated) is present, `migrate-prefs.mjs` renames it to `identities` automatically.
177
-
178
- For each MISSING service, run the **Token Save Flow** below. When creating new tokens, use the **standard key name** from Step 1b table.
179
-
180
- #### Sequential onboarding loop (strict)
181
-
182
- The Step 2 discovery summary is never the end of setup. Immediately after showing it, walk the missing services ONE BY ONE in this fixed order and run the Token Save Flow for each:
183
-
184
- 1. `jira`
185
- 2. `bitbucket_token` (then `bitbucket_user` right after, if missing)
186
- 3. `github`
187
- 4. `confluence`
188
- 5. `figma` - Figma Personal Access Token (Tier 2, REST)
189
- 6. `figma_mcp` - Figma MCP auth (Tier 1); its own prompt, never folded into the PAT prompt
190
- 7. `fortify`
191
- 8. `graylog`
192
- 9. `firebase`
193
- 10. `jenkins`
194
- 11. App Store Connect block (Step 3b; only when the target repo is iOS)
195
- 12. Google Play block (Step 3d; only when the target repo is Android)
196
- 13. Free-model keys `llm-<id>` (only after `route-on --free`): `$HOME/.claude/multi-agent-refs/setup/free-models.md`
197
-
198
- Loop rules:
199
-
200
- - **One prompt per service.** Never collapse the list into a single "add missing tokens now?" yes/no, and never offer one multi-select covering all services: each service has its own source URL, key name, identity binding and host prompt, so each gets its own Token Save Flow pass.
201
- - **Each service pass asks, in order: token → author → host → read binding (GitHub, Bitbucket; Token Save Flow Step 3.7).** Step A/B collect the secret, Step C binds the git identity (author) - Bitbucket and GitHub included; every saved token gets an author - and Step 3.5 asks the host domain inline for hosted services (jira, confluence, bitbucket, fortify, graylog) - plus the Fortify project versions and the optional Graylog test instance. GitHub and Figma skip the host question (fixed domains); `bitbucket_user` skips author binding (username, not a PAT). Never end a service pass with the token saved but the author or a required host unasked.
202
- - **Skip is per-service.** A Skip answer leaves that service's `keychainMapping` at `null` and the loop continues with the next service. Skips never abort the loop.
203
- - **`figma` and `figma_mcp` are distinct credentials for distinct tiers - ask both.** Skipping the PAT does not imply skipping MCP, and vice versa. The `figma_mcp` pass opens with a Remote / Local mode question instead of a clipboard paste (see "Figma MCP Setup" below): Remote generates a `figu_` OAuth token for the current user, Local wires the PAT-based local server.
204
- - The loop ends only when every missing service has been asked exactly once; then continue to Step 4 (Verify all).
205
-
206
- ---
207
-
208
- ### Token Save Flow (reusable)
58
+ Identities are learned in the Token Save Flow (Step C), never asked separately.
209
59
 
210
- Full procedure: `$HOME/.claude/multi-agent-refs/setup/token-save-flow.md`. Read it for every token prompt (Steps 3, 3b, 3c and any command that saves a token).
60
+ Walk the missing services ONE BY ONE, in this order: `jira`, `bitbucket_token` (then `bitbucket_user`), `github`, `confluence`, `figma` (PAT), `figma_mcp` (its own prompt), `fortify`, `graylog`, `firebase`, `jenkins`, App Store Connect (3b, iOS), Google Play (3d, Android), free-model keys `llm-<id>` (only after `route-on --free`: `$HOME/.claude/multi-agent-refs/setup/free-models.md`). One prompt per service, never one yes/no or multi-select for all; each pass asks token, author, host, read binding; Skip is per-service and never aborts the loop. Read `$HOME/.claude/multi-agent-refs/setup/token-save-flow.md` before the loop and for every token prompt: the loop rules, Steps 3.5 / 3.7 and identity learning.
211
61
 
212
- ### Step 3b - App Store Connect onboarding (iOS only, optional)
62
+ ### Steps 3b-3d - Store and Firebase onboarding (optional)
213
63
 
214
- Runs inside Step 3. Every part of the API key lives in the Keychain, the `.p8` included: ask for the `.p8` as a path, validate it BEFORE saving with `node "$HOME/.copilot/scripts/probe-store-key.mjs" --asc ...` (exit 0 only), map `appstore_connect_private_key`, store it from the file with `credential-store.sh set appstore_connect_private_key - < <AuthKey_<keyId>.p8>`, run `node "$HOME/.copilot/scripts/write-store-config.mjs"`, then offer (picker, default keep) to delete the file. `store_asc_*` and `ios_testflight_validate` then read the key from the Keychain. The five entries, the tier picker and the probes: `$HOME/.claude/multi-agent-refs/setup/app-store-connect.md`. On Skip, nothing is written.
215
-
216
- ### Step 3c - Firebase / Crashlytics onboarding (optional)
217
-
218
- Runs inside Step 3. Measure first - `bash "$HOME/.copilot/lib/fetch-crashlytics.sh" --probe` answers `tier-1-ready` / `tier-1-no-grant` / `malformed` / `unreachable` - then ask by that answer, never blind. Store the Firebase service-account JSON as issued; never base64 it. Skip writes nothing. Then offer appId discovery: `bash "$HOME/.copilot/scripts/firebase-app-discovery.sh" <repo> --json` reads the pairs the repo already carries, for `firebase.accounts[].apps[]` - it saves a round trip per run; skipping costs nothing. The picker, both tiers, the role-request wording and the v1alpha caveat: `$HOME/.claude/multi-agent-refs/setup/firebase.md`.
219
-
220
- ### Step 3d - Google Play onboarding (Android only, optional)
221
-
222
- Runs inside Step 3, only when the target repo is Android. One entry, `google_play`: the service-account JSON the toolkit's `store_play_*` tools use, which lets `/multi-agent-store-ready` run Android Gate 2. Ask for the JSON's path, validate BEFORE saving with `node "$HOME/.copilot/scripts/probe-store-key.mjs" --play --service-account <path>`, map `google_play`, then `credential-store.sh set google_play - < <path>` and `write-store-config.mjs`. Account prerequisites, the picker and the probe hints: `$HOME/.claude/multi-agent-refs/setup/google-play.md`. Skip writes nothing.
223
-
224
- ### Step 3.5 - Host Prompt (embedded in Token Save Flow)
225
-
226
- Part of the Token Save Flow reference above.
64
+ Each key is validated BEFORE it is saved and lives only in the Keychain; Skip writes nothing. Read the matching file under `$HOME/.claude/multi-agent-refs/setup/` first: `app-store-connect.md` (3b, iOS, `.p8` included), `firebase.md` (3c: probe with `fetch-crashlytics.sh --probe` before asking; store the Firebase service-account JSON as issued), `google-play.md` (3d, Android).
227
65
 
228
66
  ### Step 3.6 - Per-account host overrides (optional)
229
67
 
230
- **Runs only when** `~/.copilot/lib/account-resolver.sh` returns **more than one** account AND at least one account has Jira or Bitbucket tokens.
231
-
232
- For each non-default account (two identities, each with its own Jira host), ask once: "Account {label} has Jira/Bitbucket tokens but no host override yet. Use the global default ({hosts.jira}) or set a per-account host?" with options **1) Use global default** / **2) Set per-account host**. On `2`, prompt for `jiraHost` / `bitbucketHost` / `confluenceHost` (each optional) and save to `prefs.global.accounts[]`, e.g. `{ "id": "client-x", "jiraHost": "jira.client-x.example.com", "bitbucketHost": "bitbucket.client-x.example.com" }`.
233
-
234
- `account-resolver.sh` reads this on every invocation; per-account override wins over `global.hosts.*`. Skip this step on autopilot; `/multi-agent-setup accounts` opens it later.
235
-
236
- ---
68
+ Only when `~/.copilot/lib/account-resolver.sh` returns more than one account and one has Jira or Bitbucket tokens. Read `accounts.md` "Per-account host overrides (Step 3.6)" (setup refs). Skipped on autopilot; `/multi-agent-setup accounts` opens it later.
237
69
 
238
70
  ### Step 4 - Verify all
239
71
 
240
- Re-run scan from Step 1. Show final status:
241
- `All tokens present. Pipeline ready to use.` Then list the optional per-project features (configured on first use, nothing to do now): **Phase 5 Report Step 2 Wiki** (component wiki pages + Figma screenshots; activates when the task is a component AND a Figma token is in Keychain; adapters submodule / in-repo / github-wiki / separate-repo; first run asks: auto-detected path, custom path, skip once, or disable for this project, persisted); **channels** (post-hoc multi-channel reporter for Jira/Confluence/Wiki/PR, any branch with an open PR); **Default reviewers** (auto-fetched from the Bitbucket default-reviewers endpoint or GitHub CODEOWNERS on first PR). Next step: `/multi-agent "PROJ-12345"` to start a first task, `/multi-agent-help` for the full usage guide.
242
-
243
- If still missing, show which ones and let user skip (pipeline will re-ask for any needed token at Phase 0).
244
-
245
- ### Step 5 - Repo Discovery (optional)
246
-
247
- Pre-populates the Phase 0 project picker with repos the user is active in, merging three independent sources: local `$HOME` scan (depth 3, repo markers), Bitbucket (last 90 days, token-gated), GitHub (owner + collaborator, push in last 90 days, token-gated). A failing source skips only itself and is reported (never swallowed); discovery is idempotent and never destructive.
248
-
249
- ```
250
- Step 5 - Repo Discovery (optional)
251
- Scan for recent repos now to pre-populate the Phase 0 picker?
252
-
253
- y - all three (local + Bitbucket + GitHub, ~10-30s)
254
- l - local scan only (fastest, no network)
255
- n - skip (Phase 0 will prompt for repo path manually)
256
- ```
257
-
258
- The scan commands, merge-by-origin dedup, the multi-select picker, the `recentProjects` / `serviceStatus` prefs shapes and the skip / degrade rules live in `$HOME/.claude/multi-agent-refs/setup/repo-discovery.md` - read that file when the user opts in.
259
-
260
- ### Step 6 - Remember as Multi-Repo Group (optional)
261
-
262
- After Step 5, if the user picked **2 or more** repos, offer to remember the combination as a named group; Phase 0's project picker surfaces saved groups at the top, so a multi-repo task becomes a single keypress next time. Auto-skipped if Step 5 was skipped or fewer than 2 repos were selected (single-repo selection is a no-op).
263
-
264
- ```
265
- Step 6 - Remember as a multi-repo group (optional)
266
- You picked 2 repos: Checkout, UIComponents.
267
- Save this combo for one-tap selection in Phase 0?
268
- Group name (Enter for auto): [Checkout + UIComponents]
269
- Skip with 'n'.
270
- ```
72
+ Re-run the Step 1 scan and show the final status (`summaries.md` "Step 4 final status"). Still missing: show which and let the user skip; Phase 0 re-asks.
271
73
 
272
- - **Auto-name** (suggested, editable): 2 repos `"<repoA> + <repoB>"`; 3-4 repos `"<repoA>, <repoB>, <repoC>(+1)"`; 5+ repos `"<repoA> + <count-1> more"`. Labels use the human label from `recentProjects` (path basename, not the full path).
273
- - **Save** to schema `global.recentGroups[]` (`repos` required, `label` / `count` / `lastUsed` optional), e.g. `{ "label": "Checkout + UIComponents", "repos": ["~/dev/Checkout", "~/dev/UIComponents"], "count": 1, "lastUsed": "2026-04-15T21:08:00Z" }`.
274
- - **LRU + dedup**: a new group is unshifted to the front. The same set of `repos` (order-independent compare) bumps the existing entry to the front, increments `count`, updates `lastUsed`; do NOT create a duplicate. Schema cap is 10 entries; the oldest past the cap are dropped.
275
- - **`n`** → not saved; the picker still works for one-time use, and a future Phase 0 selection of the same combo re-prompts.
74
+ ### Steps 5-7 - Repo discovery, groups, identity routing (optional)
276
75
 
277
- ### Step 7 - Platform Identity Routing (optional)
76
+ Read the file under `$HOME/.claude/multi-agent-refs/setup/` for each step the user opts into: `repo-discovery.md` (5: local, Bitbucket, GitHub; a failing source skips only itself and is reported), `multi-repo-group.md` (6: only after 2+ repos), `identity-routing.md` (7).
278
77
 
279
- Full procedure: `$HOME/.claude/multi-agent-refs/setup/identity-routing.md`. Read it for Step 7.
78
+ ### Credential store, token sources, Figma MCP
280
79
 
281
- ### Cross-Platform Notes (Step 1-9) and Token -> Source Mapping
282
-
283
- Every read and write goes through `~/.copilot/lib/credential-store.sh`, which wraps the macOS Keychain; stay on the helper rather than calling `security` directly. Clipboard handling and the no-backend case: `$HOME/.claude/multi-agent-refs/keychain.md` "Credential store mechanics". Standard key names are a convention for NEW tokens; the key names, token types and where to generate each one live in `$HOME/.claude/multi-agent-refs/keychain.md` "Standard key names". Git identities are stored in preferences, never in the credential store.
284
-
285
- ### Inline Token Save Pattern
286
-
287
- All tokens go through `~/.copilot/lib/credential-store.sh` (auto-delegates to `~/.copilot/scripts/keychain.py`, see Setup above).
288
-
289
- ```bash
290
- # PAT / API Key / JSON contents (from clipboard)
291
- pbpaste | ~/.copilot/lib/credential-store.sh set "<SERVICE_NAME>" -
292
- pbcopy < /dev/null # clear clipboard
293
-
294
- # Non-secret value typed inline (a secret on argv is visible to ps and lands in shell history)
295
- ~/.copilot/lib/credential-store.sh set "<SERVICE_NAME>" "<VALUE>"
296
-
297
- # Key file from disk (the .p8, the Google Play JSON; or when the clipboard is unavailable)
298
- ~/.copilot/lib/credential-store.sh set "<SERVICE_NAME>" - < /path/to/file.json
299
-
300
- # Read - a JSON value comes back exactly as it was stored, newlines included
301
- ~/.copilot/lib/credential-store.sh get "<SERVICE_NAME>"
302
-
303
- # Maximum stdin hygiene (the secret never lands on argv / shell history): the Python helper with the - sentinel
304
- pbpaste | ~/.copilot/scripts/keychain.py set "<SERVICE_NAME>" -
305
- ```
306
-
307
- ### Figma MCP Setup (Remote / Local question)
308
-
309
- Full procedure: `$HOME/.claude/multi-agent-refs/setup/figma.md`. Read it for the Figma MCP question.
80
+ Always `~/.copilot/lib/credential-store.sh` (macOS Keychain, macOS only, ADR-0012), never `security` directly; secrets from the clipboard or a file, never argv. Key names, token sources and store mechanics: `$HOME/.claude/multi-agent-refs/keychain.md`. Identities live in preferences. Figma MCP Remote / Local: `$HOME/.claude/multi-agent-refs/setup/figma.md`.
310
81
 
311
82
  ### Security Rules
312
83
 
313
- - Never paste tokens into terminal or chat - use `pbpaste` for input
84
+ - Never paste tokens into terminal or chat - use `pbpaste` for input
314
85
  - Never hardcode tokens in source code
315
86
  - Never commit tokens to git history
316
87
  - Clear clipboard immediately: `pbcopy < /dev/null`
317
88
  - `2>/dev/null` suppresses stderr (prevents metadata leakage)
318
89
 
319
- ### Setup from Scratch Summary
320
-
321
- On a new machine: (1) `npx @{npm-scope}/multi-agent-pipeline install`; (2) `/multi-agent-setup`; (3) the interactive flow: token scan (shows what is missing) -> Git Identity creation (name + email) -> inline commands for missing tokens -> final verification; (4) ready: `/multi-agent "PROJ-12345"`, `/multi-agent "https://github.com/.../issues/42"` or `/multi-agent "bug description"`.
322
-
323
- All tokens are optional in the sense that every service can be answered with Skip - but the ASKING is not optional: the Step 3 sequential loop still walks every missing service one by one (token → author → host). Phase 0 re-asks at runtime only for tokens the user skipped here.
90
+ From scratch: `npx @{npm-scope}/multi-agent-pipeline install`, `/multi-agent-setup`, then a task (`summaries.md` "Setup from scratch").
324
91
 
325
92
  ### Step 8 - Enforcement hooks (optional)
326
93
 
327
- On Claude Code, offer to merge `$HOME/.claude/templates/claude-hooks.json`: three blocking `PreToolUse` gates (secret scan, agent-guard, read-size) plus non-blocking hooks on `PreCompact`, `SessionEnd`, `SessionStart` and `PostToolUse`, and a blocking `Stop` hook (`run-stop-guard.sh`). What each does: `$HOME/.claude/multi-agent-refs/picker-contract.md`.
328
-
329
- - Ask (picker): "Install the pipeline's hooks into `~/.claude/settings.json`?" Default Yes.
330
- - On Yes, deep-merge EVERY event in the template's `hooks` object (merging `PreToolUse` alone drops the capture hooks); keep existing hooks, never duplicate a matcher calling the same script.
331
- - Say only the three gates are hookable (no run-specific arguments); the rest are phase-enforced.
332
- - Say the read-size gate stays inert until `prefs.global.bulkRead.mode` is set; recommend `observe` first (why, and the Phase 3 exemption: `picker-contract.md`).
333
-
334
- Codex: offer only the syntax gate, then run `node "$HOME/.codex/scripts/host-hooks.mjs" install --host codex`. Copilot CLI: offer no hook (it discards `postToolUse` output as of 1.0.45).
94
+ Claude Code: offer (picker, default Yes) to merge `$HOME/.claude/templates/claude-hooks.json` into `~/.claude/settings.json`; deep-merge EVERY event, never duplicate a matcher. Read `$HOME/.claude/multi-agent-refs/setup/hooks-and-plugins.md` before Step 8. Codex: only the syntax gate, via `node "$HOME/.codex/scripts/host-hooks.mjs" install --host codex`. Copilot CLI: no hook.
335
95
 
336
96
  ### Step 9 - Default stack plugin enablement
337
97
 
338
- Stack skills ship as versioned plugins in the `{owner}/multi-agent-plugins` marketplace. On first setup, wire the stack so the pipeline works out of the box.
339
-
340
- 1. Ensure the marketplace is known (idempotent):
341
- ```bash
342
- bash "$HOME/.copilot/scripts/plugin-refresh.sh" {owner} --add-only
343
- ```
344
- 2. Ask the detector, then derive (no marker list here; a second list would drift from the detector):
98
+ 1. `bash "$HOME/.copilot/scripts/plugin-refresh.sh" {owner} --add-only` (idempotent).
99
+ 2. Ask the detector, then derive; no marker list here:
345
100
 
346
101
  ```bash
347
102
  eval "$(bash $HOME/.copilot/lib/stack-detect.sh "$PROJECT_ROOT")" # MA_STACKS, MA_STACK_WHY
@@ -349,11 +104,4 @@ Stack skills ship as versioned plugins in the `{owner}/multi-agent-plugins` mark
349
104
  console.log(m.pluginsForStacks(process.argv[1].split(" ").filter(Boolean)).plugins.join(" ")))' "$MA_STACKS"
350
105
  ```
351
106
 
352
- Report `MA_STACK_WHY` with the result. `ai-common-toolkit` and
353
- `ai-analyst-toolkit` are in every answer, the empty one included: neither is
354
- stack-specific. **No marker matched is an answer** - those two, not a guess.
355
- A name the marketplace does not carry is dropped with `dropped[]` naming it,
356
- so a toolkit that was never shipped is caught before it fails to load.
357
- 3. Report the enabled set. To change later, run `/multi-agent-stack <ios|android|web|backend|...>` in the repo. Pipeline Phase 1 auto-detects the stack for its own routing regardless of enablement.
358
-
359
- The marketplace name (`multi-agent-plugins`) is generic; a different org points `{owner}` at its own fork.
107
+ 3. Report `MA_STACK_WHY` and the enabled set (`hooks-and-plugins.md` "Step 9"); change later with `/multi-agent-stack <stack>`.
@@ -16,10 +16,20 @@ Show every active and completed task as a table.
16
16
  question:
17
17
 
18
18
  ```bash
19
- node "$HOME/.claude/scripts/runs-index.mjs" # grouped table
20
- node "$HOME/.claude/scripts/runs-index.mjs" --json # the same records
19
+ node "$HOME/.claude/scripts/status-overview.mjs" # live sessions, tokens, accounts, runs
20
+ node "$HOME/.claude/scripts/status-overview.mjs" --json # the same document
21
+ node "$HOME/.claude/scripts/runs-index.mjs" [--all] # the full run table
21
22
  ```
22
23
 
24
+ `status-overview.mjs` answers "what is happening right now": each live
25
+ Claude Code session with the run it drives and its token spend (subagents
26
+ included), the tokens of the last 24 hours, the github.com accounts gh holds
27
+ with the active one marked, the git author, and which logical credentials
28
+ from `keychainMapping` are registered. It reads credential names only and
29
+ never a value; never run `credential-store.sh get` to "check" one. Show its
30
+ sections as they come, then the run table below. Token figures are list-price
31
+ estimates, not a bill.
32
+
23
33
  `runs-index.mjs` resolves through `lib/run-paths.sh` / `scripts/_run-paths.mjs`,
24
34
  so it sees both directory layouts (`<project>/<id>/` and the flat `<id>/`),
25
35
  the salvaged `artifacts/` copy Phase 4 leaves behind, and every spelling of a
@@ -42,6 +52,7 @@ Show every active and completed task as a table.
42
52
  | `stopped` - Stopped mid-development | anything else past phase 0 | `resume #N` or `kill #N` |
43
53
  | `question` - Left at a question | phase 0, nothing pending | `garbage-collect --abandoned` - nothing was built |
44
54
  | `unknown` - Status not recorded | no `status` field | say so; offer nothing |
55
+ | `done` - Finished | `status` is `complete`, `completed`, `done`, `abandoned` or `cancelled`, checked first | nothing; the table folds it into a count unless `--all` |
45
56
 
46
57
  A run with no `status` is **not** placed in an actionable group. Unknown is
47
58
  not a finding, and calling it dead is the same false claim in the other