@mmerterden/multi-agent-pipeline 20.12.0 → 20.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (183) hide show
  1. package/CHANGELOG.md +97 -0
  2. package/README.md +8 -6
  3. package/README.tr.md +8 -6
  4. package/docs/architecture.md +3 -3
  5. package/docs/ecosystem.md +5 -5
  6. package/docs/facts.json +4 -4
  7. package/install/_common.mjs +1 -1
  8. package/install/_plugin-skills.mjs +13 -9
  9. package/install/catalog-history.json +1 -1
  10. package/install/codex.mjs +12 -12
  11. package/manifest.json +186 -120
  12. package/package.json +1 -1
  13. package/pipeline/commands/multi-agent/SKILL.md +1 -0
  14. package/pipeline/commands/multi-agent/analysis/SKILL.md +17 -82
  15. package/pipeline/commands/multi-agent/analysis-jira/SKILL.md +57 -7
  16. package/pipeline/commands/multi-agent/analysis-resolve/SKILL.md +2 -2
  17. package/pipeline/commands/multi-agent/autopilot/SKILL.md +8 -23
  18. package/pipeline/commands/multi-agent/autopilot-off/SKILL.md +25 -45
  19. package/pipeline/commands/multi-agent/channels/SKILL.md +11 -63
  20. package/pipeline/commands/multi-agent/design-check/SKILL.md +43 -178
  21. package/pipeline/commands/multi-agent/diff-explain/SKILL.md +2 -0
  22. package/pipeline/commands/multi-agent/doctor/SKILL.md +6 -0
  23. package/pipeline/commands/multi-agent/estimate/SKILL.md +65 -0
  24. package/pipeline/commands/multi-agent/feedback/SKILL.md +2 -2
  25. package/pipeline/commands/multi-agent/forget/SKILL.md +1 -0
  26. package/pipeline/commands/multi-agent/garbage-collect/SKILL.md +1 -0
  27. package/pipeline/commands/multi-agent/help/SKILL.md +5 -546
  28. package/pipeline/commands/multi-agent/kill/SKILL.md +14 -18
  29. package/pipeline/commands/multi-agent/prune-logs/SKILL.md +1 -0
  30. package/pipeline/commands/multi-agent/prune-prompts/SKILL.md +1 -0
  31. package/pipeline/commands/multi-agent/refactor/SKILL.md +7 -76
  32. package/pipeline/commands/multi-agent/review/SKILL.md +5 -0
  33. package/pipeline/commands/multi-agent/review-analysis/SKILL.md +8 -3
  34. package/pipeline/commands/multi-agent/scenario-audit/SKILL.md +79 -0
  35. package/pipeline/commands/multi-agent/serve/SKILL.md +6 -3
  36. package/pipeline/commands/multi-agent/setup/SKILL.md +12 -365
  37. package/pipeline/commands/multi-agent/status/SKILL.md +2 -0
  38. package/pipeline/commands/multi-agent/store-ready/SKILL.md +56 -184
  39. package/pipeline/commands/multi-agent/sync/SKILL.md +14 -267
  40. package/pipeline/contract/CHANGELOG.md +52 -0
  41. package/pipeline/contract/README.md +41 -1
  42. package/pipeline/contract/build.mjs +49 -7
  43. package/pipeline/contract/fixtures/error-invalid-request.json +1 -1
  44. package/pipeline/contract/fixtures/error-unauthorized.json +1 -1
  45. package/pipeline/contract/fixtures/error-unsigned.json +1 -1
  46. package/pipeline/contract/fixtures/launch-plan.json +1 -2
  47. package/pipeline/contract/fixtures/runs-awaiting-question.json +10 -3
  48. package/pipeline/contract/fixtures/runs-empty.json +1 -1
  49. package/pipeline/contract/fixtures/runs-failed.json +19 -6
  50. package/pipeline/contract/fixtures/runs-pr-opened-redacted.json +25 -8
  51. package/pipeline/contract/fixtures/runs-pr-opened.json +25 -8
  52. package/pipeline/contract/fixtures/runs-running.json +31 -4
  53. package/pipeline/contract/frozen/toolbox.json +13 -0
  54. package/pipeline/contract/manifest.json +112 -10
  55. package/pipeline/contract/types/index.d.ts +186 -17
  56. package/pipeline/lib/analysis-jira-write.sh +81 -27
  57. package/pipeline/lib/analysis-quality.mjs +261 -0
  58. package/pipeline/lib/analysis-sections.mjs +105 -0
  59. package/pipeline/lib/claude-sessions.mjs +93 -0
  60. package/pipeline/lib/credential-resolve.mjs +39 -0
  61. package/pipeline/lib/gc-report.sh +64 -0
  62. package/pipeline/lib/jira-epic-link.sh +54 -0
  63. package/pipeline/lib/unattended-settings-location.mjs +4 -0
  64. package/pipeline/lib/workspace-trust.mjs +73 -0
  65. package/pipeline/multi-agent-refs/analysis/intake.md +5 -3
  66. package/pipeline/multi-agent-refs/analysis/locked.md +12 -11
  67. package/pipeline/multi-agent-refs/analysis/redesign.md +3 -1
  68. package/pipeline/multi-agent-refs/analysis/render.md +24 -24
  69. package/pipeline/multi-agent-refs/analysis/resolve.md +1 -1
  70. package/pipeline/multi-agent-refs/analysis/resume.md +37 -0
  71. package/pipeline/multi-agent-refs/analysis/reusable-refs.md +25 -0
  72. package/pipeline/multi-agent-refs/analysis/review.md +16 -3
  73. package/pipeline/multi-agent-refs/analysis/synthesis.md +10 -2
  74. package/pipeline/multi-agent-refs/analysis-template-corporate.md +44 -9
  75. package/pipeline/multi-agent-refs/analysis-template.md +21 -14
  76. package/pipeline/multi-agent-refs/channels/board.md +17 -0
  77. package/pipeline/multi-agent-refs/channels/multi-repo.md +15 -0
  78. package/pipeline/multi-agent-refs/cross-cli-contract.md +8 -4
  79. package/pipeline/multi-agent-refs/design-check/build-launch.md +14 -0
  80. package/pipeline/multi-agent-refs/design-check/compare.md +44 -0
  81. package/pipeline/multi-agent-refs/design-check/drive-capture.md +35 -0
  82. package/pipeline/multi-agent-refs/design-check/export.md +37 -0
  83. package/pipeline/multi-agent-refs/design-check/figma-mapping.md +11 -0
  84. package/pipeline/multi-agent-refs/design-check/init-inventory.md +56 -0
  85. package/pipeline/multi-agent-refs/design-check/mcp-currency-gate.md +41 -0
  86. package/pipeline/multi-agent-refs/features/analysis-jira.md +69 -19
  87. package/pipeline/multi-agent-refs/features/analysis-outline.md +55 -0
  88. package/pipeline/multi-agent-refs/features/analysis-sources.md +60 -0
  89. package/pipeline/multi-agent-refs/help/en.md +273 -0
  90. package/pipeline/multi-agent-refs/help/tr.md +271 -0
  91. package/pipeline/multi-agent-refs/orchestrator/operations.md +99 -0
  92. package/pipeline/multi-agent-refs/orchestrator/phase-0-projects.md +72 -0
  93. package/pipeline/multi-agent-refs/orchestrator/phase-3-user-test.md +40 -0
  94. package/pipeline/multi-agent-refs/orchestrator/phase-4-5-projects.md +68 -0
  95. package/pipeline/multi-agent-refs/orchestrator/skill-loading.md +99 -0
  96. package/pipeline/multi-agent-refs/phases/phase-0-init.md +3 -2
  97. package/pipeline/multi-agent-refs/phases/phase-1-plan.md +1 -1
  98. package/pipeline/multi-agent-refs/phases/phase-2-dev.md +1 -1
  99. package/pipeline/multi-agent-refs/picker-contract.md +29 -0
  100. package/pipeline/multi-agent-refs/refactor/drift.md +49 -0
  101. package/pipeline/multi-agent-refs/refactor/run-errors.md +46 -0
  102. package/pipeline/multi-agent-refs/setup/discovery.md +84 -0
  103. package/pipeline/multi-agent-refs/setup/figma.md +27 -0
  104. package/pipeline/multi-agent-refs/setup/identity-routing.md +60 -0
  105. package/pipeline/multi-agent-refs/setup/token-save-flow.md +201 -0
  106. package/pipeline/multi-agent-refs/store-ready/build.md +49 -0
  107. package/pipeline/multi-agent-refs/store-ready/gate-1-static.md +37 -0
  108. package/pipeline/multi-agent-refs/store-ready/gate-3-policy.md +31 -0
  109. package/pipeline/multi-agent-refs/store-ready/preflight.md +50 -0
  110. package/pipeline/multi-agent-refs/store-ready/report.md +40 -0
  111. package/pipeline/multi-agent-refs/sync/codex.md +43 -0
  112. package/pipeline/multi-agent-refs/sync/dev-toolkit.md +174 -0
  113. package/pipeline/multi-agent-refs/sync/stack-plugins.md +51 -0
  114. package/pipeline/multi-agent-refs/tracker-contract.md +29 -4
  115. package/pipeline/schemas/agent-state.schema.json +13 -4
  116. package/pipeline/schemas/analysis-spec.schema.json +76 -2
  117. package/pipeline/schemas/autopilot-off-request.schema.json +20 -0
  118. package/pipeline/schemas/autopilot-off.schema.json +24 -0
  119. package/pipeline/schemas/autopilot-status.schema.json +63 -0
  120. package/pipeline/schemas/contract-error.schema.json +13 -2
  121. package/pipeline/schemas/gc-request.schema.json +31 -0
  122. package/pipeline/schemas/gc.schema.json +116 -0
  123. package/pipeline/schemas/kill-request.schema.json +22 -0
  124. package/pipeline/schemas/kill.schema.json +118 -0
  125. package/pipeline/schemas/launch-plan.schema.json +11 -2
  126. package/pipeline/schemas/launch-request.schema.json +7 -2
  127. package/pipeline/schemas/launch.json +65 -4
  128. package/pipeline/schemas/launch.schema.json +23 -8
  129. package/pipeline/schemas/prefs.schema.json +25 -4
  130. package/pipeline/schemas/repos.schema.json +39 -0
  131. package/pipeline/schemas/resume-request.schema.json +37 -0
  132. package/pipeline/schemas/run-log.schema.json +32 -0
  133. package/pipeline/schemas/run-questions.json +5 -1
  134. package/pipeline/schemas/run-questions.schema.json +1 -1
  135. package/pipeline/schemas/runs-index.schema.json +59 -3
  136. package/pipeline/scripts/_run-paths.mjs +8 -2
  137. package/pipeline/scripts/analysis-conform-coverage.mjs +96 -0
  138. package/pipeline/scripts/analysis-sources.mjs +264 -0
  139. package/pipeline/scripts/analysis-story-body.mjs +210 -0
  140. package/pipeline/scripts/analysis-story-tree.mjs +73 -12
  141. package/pipeline/scripts/analysis-tickets-writeback.mjs +101 -0
  142. package/pipeline/scripts/autopilot-control.mjs +223 -0
  143. package/pipeline/scripts/autopilot-runner.mjs +14 -39
  144. package/pipeline/scripts/build-references.mjs +19 -2
  145. package/pipeline/scripts/confluence-readback.mjs +129 -0
  146. package/pipeline/scripts/contract-server.mjs +373 -7
  147. package/pipeline/scripts/doctor.mjs +5 -2
  148. package/pipeline/scripts/estimate.mjs +223 -0
  149. package/pipeline/scripts/gate-ledger.mjs +64 -3
  150. package/pipeline/scripts/gc-plan.mjs +288 -0
  151. package/pipeline/scripts/gc-refs.sh +33 -2
  152. package/pipeline/scripts/gc-tmp.sh +33 -2
  153. package/pipeline/scripts/gc-worktrees.sh +42 -3
  154. package/pipeline/scripts/gen-mode-dispatch.mjs +3 -24
  155. package/pipeline/scripts/jira-wiki-escape.mjs +40 -0
  156. package/pipeline/scripts/launch-request.mjs +182 -10
  157. package/pipeline/scripts/phase-tracker.sh +62 -1
  158. package/pipeline/scripts/run-kill.mjs +232 -0
  159. package/pipeline/scripts/run-log.mjs +111 -0
  160. package/pipeline/scripts/runs-index.mjs +177 -11
  161. package/pipeline/scripts/scenario-audit.mjs +245 -0
  162. package/pipeline/scripts/validate-analysis-doc.mjs +204 -76
  163. package/pipeline/skills/.skill-manifest.json +27 -19
  164. package/pipeline/skills/shared/README.md +5 -3
  165. package/pipeline/skills/shared/core/multi-agent/SKILL.md +51 -450
  166. package/pipeline/skills/shared/core/multi-agent-analysis/SKILL.md +13 -2
  167. package/pipeline/skills/shared/core/multi-agent-analysis-jira/SKILL.md +56 -6
  168. package/pipeline/skills/shared/core/multi-agent-autopilot/SKILL.md +6 -0
  169. package/pipeline/skills/shared/core/multi-agent-autopilot-off/SKILL.md +26 -44
  170. package/pipeline/skills/shared/core/multi-agent-design-check/SKILL.md +31 -127
  171. package/pipeline/skills/shared/core/multi-agent-doctor/SKILL.md +6 -0
  172. package/pipeline/skills/shared/core/multi-agent-estimate/SKILL.md +61 -0
  173. package/pipeline/skills/shared/core/multi-agent-kill/SKILL.md +14 -19
  174. package/pipeline/skills/shared/core/multi-agent-refactor/SKILL.md +7 -76
  175. package/pipeline/skills/shared/core/multi-agent-review/SKILL.md +6 -1
  176. package/pipeline/skills/shared/core/multi-agent-review-analysis/SKILL.md +6 -1
  177. package/pipeline/skills/shared/core/multi-agent-review-issue/SKILL.md +1 -1
  178. package/pipeline/skills/shared/core/multi-agent-review-jira/SKILL.md +1 -1
  179. package/pipeline/skills/shared/core/multi-agent-scenario-audit/SKILL.md +77 -0
  180. package/pipeline/skills/shared/core/multi-agent-serve/SKILL.md +6 -3
  181. package/pipeline/skills/shared/core/multi-agent-setup/SKILL.md +206 -324
  182. package/pipeline/skills/shared/core/multi-agent-store-ready/SKILL.md +5 -0
  183. package/pipeline/skills/shared/core/multi-agent-sync/SKILL.md +4 -4
package/CHANGELOG.md CHANGED
@@ -16,6 +16,103 @@ Internal file-layout changes that don't affect the slash-command surface are sti
16
16
 
17
17
  ## [Unreleased]
18
18
 
19
+ ## [20.15.0] - 2026-10-02
20
+
21
+ ### Added
22
+
23
+ - `phase-tracker.sh task <phase> <taskId> <status> [--subject S] [--active-form A]` records one entry of the host's native task list under the phase it belongs to (pending, in_progress, completed), so a reader that is not the host sees the same list. The tracker contract asks for one `task` call per `TaskCreate` / `TaskUpdate`, `update_plan` step or card row, on every host.
24
+
25
+ - `runs-index.mjs` 1.2.0: each run carries `runType`, `title`, `progress` and `currentTask`, and each phase `progress` and `tasks[]`, so a client shows how far a run is and what it is doing without reading tracker files. The index reads the unattended log root (`~/.multi-agent-unattended/logs`) beside `LOGS_ROOT`, one record per task id, so a run launched in the background is listed. Each run also carries `processAlive`, from `claude agents --json` through `lib/claude-sessions.mjs`, which the autopilot runner, `run-kill.mjs` and the index now share. Phase 0 records the fetched issue title as `agent-state.json` `title`.
26
+
27
+ - Launch request `mode: background` with `kind: development | analysis`: an unattended run of `/multi-agent` (without autopilot) or `/multi-agent:analysis`, in the same background shape as autopilot (`launch.json` `hosts.claude.background`). A picker the request did not answer parks the run on a `pendingQuestion` (`picker-contract.md`, Background) instead of being defaulted, and a background run never takes `workspace: local`. `launch.json` `hosts.claude.resume` and `launch-request.mjs` `planResume` give the background shape of `/multi-agent:resume <taskId>`.
28
+ - `gate-ledger.mjs park --waiting-for question --question-file <path>` parks a run on a question from the command line; the question is held to the shape a client answers before anything is written.
29
+
30
+ - `run-kill.mjs preview|apply <taskId>`: what a kill touches (worktree, branch, size, uncommitted files, commits on no remote, whether the session is alive), and the kill itself: `claude stop` for a live session, `git worktree remove --force` for a linked worktree inside its repository, the local branch deleted unless it is the base, the main checkout's branch or main / master / develop, and the run marked `abandoned` with `abandonedBy: "kill"`. `/multi-agent:kill` runs it.
31
+
32
+ - `gc-tmp.sh`, `gc-refs.sh` and `gc-worktrees.sh` take `--report <file>` (one JSON line per candidate, as `gc-abandoned.sh` writes) and `--only <file>` (only the listed paths), through `lib/gc-report.sh`. `gc-plan.mjs preview` runs all four collectors as dry runs and lists every candidate as `{kind, path, sizeKb, reason}`; `gc-plan.mjs apply` runs each with `--yes --only` over exactly those paths, so nothing the preview did not show is removed.
33
+
34
+ - `autopilot-control.mjs status | off [--now]`: continuous mode's status document with its contract version, and the off switch `/multi-agent:autopilot-off` describes (schedule and awake agent removed, a stale sleep lock released, the selection kept; with `--now` the in-flight item's session stopped and its run marked `abandoned` with `abandonedBy: "autopilot-off"`, its worktree stashed when it holds work and removed when clean).
35
+
36
+ - Contract server routes (contract 1.3.0): `GET /v1/repos` (`launch-request.mjs repos`: the configured and registered repositories a launch may name), `GET /v1/runs/{id}/log`, `POST /v1/runs/{id}/resume`, `POST /v1/runs/{id}/kill`, `POST /v1/gc`, `GET /v1/autopilot` and `POST /v1/autopilot/off`, each a call into the script the CLI runs. Kill and gc take a preview request and a confirming one; the confirm token is random, single use, valid for 120 seconds, bound to the route and run, and held only in the server's memory. New error codes: `run-active`, `not-resumable`, `confirm-expired`, `confirm-mismatch`.
37
+
38
+ ### Changed
39
+
40
+ - `/multi-agent:kill` keeps the remote branch and the run's logs, and no longer offers to delete the remote branch. A remote branch is deleted on the host, by hand, when that is wanted.
41
+ - `/multi-agent:analysis` states the background rule: a run launched in the background never asks or defaults a picker, it parks on the question (`picker-contract.md`, Background).
42
+ - `/multi-agent:autopilot-off` runs `autopilot-control.mjs off [--now]`, the script `POST /v1/autopilot/off` runs, instead of its own launchctl, awake-agent and indicator steps.
43
+ - The plan's steps attach to Dev (phase 2), the phase that executes them: Phase 1 calls `phase-tracker.sh plan 2`, and Phase 2 moves each step with `sub 2 <task_id>` as it starts and finishes it. `smoke-phase-contract.sh` holds both calls to the Dev id in `phases.json`.
44
+
45
+ ### Fixed
46
+
47
+ - Every background launch passes its prompt as claude's positional argument instead of `-p`, because `claude --bg` refuses `--print`; this covers the autopilot runner's launch, research and resume children and every plan from `launch.json`. The research child's `--disallowedTools` list now sits before another flag, so its variadic value cannot take the prompt.
48
+ - `POST /v1/launch` and `POST /v1/runs/{id}/resume` answer `409 unattended-profile-missing`, with a `remedy` naming the install command, when `~/.claude/multi-agent-unattended.settings.json` is absent, instead of returning a plan whose session stops at its first tool call. They answer `409 workspace-not-trusted` when Claude Code's config (`~/.claude.json` `projects[<repo root>].hasTrustDialogAccepted`) records the repository as not trusted, read through `lib/workspace-trust.mjs`, which never writes it; a config that cannot be read lets the launch proceed.
49
+ - `runs-index.mjs` reads a phase's `now` from `meta.Now`, where `phase-tracker.sh now` writes it, so the live line reaches the index and every client.
50
+
51
+ ## [20.14.0] - 2026-10-02
52
+
53
+ ### Added
54
+
55
+ - `/multi-agent:scenario-audit <scenarios.csv>` checks test scenarios against the code: `scenario-audit.mjs` reads the CSV (comma or semicolon, quoted cells, matched by header), searches HEAD for the code-level terms proposed per scenario, and holds each verdict to its evidence. PRESENT and PARTIAL need a `file:line` that resolves at HEAD and ABSENT needs the searched terms; anything else becomes UNCLEAR with the reason. Read-only; Turkish labels VAR / KISMEN / YOK / BELİRSİZ.
56
+ - `/multi-agent:analysis check <doc>` and `refresh <doc>`. `analysis-sources.mjs fingerprint` records each source's version and a hash of the part the document uses (the Figma node, the page body, the operations of the cited endpoints) and writes `<doc>.sources.json` beside the document; `check` compares and gives each source `unchanged`, `no-effect`, `update-doc`, `retest` or `unchecked`, and resolves the document's citations at HEAD. `refresh` redrafts from the stale sources into a new draft with a changelog row; replacing the document is a separate approval.
57
+ - Section 21 shows the Figma file version and date beside the node id. `analysisSpec.sourceVersions`, Figma `version` / `lastModified` and Confluence `version` are part of the schema.
58
+ - `pipeline/lib/credential-resolve.mjs`: one token resolution (credential store, then an environment variable) for Node scripts; `confluence-readback.mjs` uses it.
59
+ - `profile: custom` (Locked 37): an analysis laid out in a team's own outline (`outline: <path>`, copied beside the document). Its headings are the required sections; the universal validator checks still run and every template-specific check reports `skipped: custom profile`. Intake offers it as a third profile; `prefs.global.analysisProfiles` accepts `custom`.
60
+ - `/multi-agent:analysis conform <doc>` maps an existing document onto a template without changing what it says; unmapped content goes to an appendix and uncovered sections become Section 20 rows. `analysis-conform-coverage.mjs` checks that every source sentence of three words or more is still in the draft, whatever markup it moved into.
61
+ - `/multi-agent:estimate <doc|text>` gives an effort range from similar closed Jira work: `estimate.mjs` reads the finished issues a `statusCategory = Done` query names, their role sub-tasks and logged time, and reports P25-P75, the median and the issues behind each row. No number below three samples; story points come from the field the site names "Story Points".
62
+
63
+ ### Changed
64
+
65
+ - `/multi-agent:help` reads one catalog, `multi-agent-refs/help/en.md` or `help/tr.md`, for the user's language instead of carrying both; the command file drops from about 8,500 tokens to about 300.
66
+ - `sync` moves its Codex, stack-plugin and dev-toolkit steps to `multi-agent-refs/sync/`, read when that step runs (about 7,500 to 3,800 tokens). `setup` moves the Token Save Flow with its host prompt, credential discovery, identity routing and Figma MCP setup to `multi-agent-refs/setup/` (about 11,400 to 6,500). `channels` moves the Board adapter and the multi-repo dispatch table to `multi-agent-refs/channels/` (about 9,500 to 8,400). The token ceilings in `lint-skills.mjs` move down with them.
67
+ - `channels`, `design-check`, `setup`, `store-ready` and `sync` carry a `## Gotchas` section near the top.
68
+ - `status` and `diff-explain` run as a forked read-only Explore context (`context: fork`), so their reads stay out of the calling conversation.
69
+ - `design-check` (about 8,000 to 5,000 tokens), `store-ready` (6,000 to 4,400), `refactor` (5,750 to 4,300) and `analysis` (5,600 to 4,400) move their long procedures into `multi-agent-refs/{design-check,store-ready,refactor,analysis}/`, read at the step that needs them; every binding rule stays in the command. The Copilot orchestrator skill drops from 713 lines and about 9,150 tokens to 313 lines and 4,850, with its operations, skill loading and per-project phase blocks in `multi-agent-refs/orchestrator/`. The grace entries for `design-check` and the orchestrator are gone.
70
+ - The Copilot `multi-agent-setup` skill carries every step of the Claude command and points at the same `setup/` refs.
71
+ - `smoke-context-budget.sh` counts the analysis command file together with the refs it names, so moving text from the command into one of its refs leaves the per-run total unchanged.
72
+
73
+ ### Fixed
74
+
75
+ - Copilot skills name `$HOME/.claude/multi-agent-refs/...`, where the refs are installed, instead of `~/.copilot/multi-agent-refs/`, which no install creates (`review`, `review-jira`, `review-issue`, `review-analysis`, `design-check`, `store-ready`). `test/copilot-ref-paths.test.mjs` holds the rule.
76
+ - The Copilot `design-check` skill offers the snapshot lane before halting on a module without mock mode, as the command does.
77
+ - The Copilot orchestrator's kill keeps the task logs and reads the task counter from the shared log root, as `phases/operations.md` specifies; an autopilot blocking finding returns to Phase 2.
78
+ - `estimate` cites the picker contract.
79
+
80
+ ## [20.13.0] - 2026-10-01
81
+
82
+ ### Added
83
+
84
+ - Every destructive command (`kill`, `forget`, `garbage-collect`, `prune-logs`, `prune-prompts`, `autopilot-off`, alongside `purge` and `uninstall`) carries `disable-model-invocation: true`, so it runs only when the user types it. Confirm-only commands such as `sync` stay model-invocable. `test/command-contract.test.mjs` holds the rule, and `cross-cli-contract.md` records it with the decision to keep command-only frontmatter keys at the top level.
85
+ - `lint-skills.mjs` requires a routing clause ("use when ...") in every command description, as it already did for skills, and warns when a command on its Gotchas list has no `## Gotchas` section.
86
+ - `## Gotchas` sections near the top of `analysis`, `analysis-jira`, `autopilot`, `doctor`, `review` and `review-analysis`, mirrored into their Copilot skills.
87
+ - `validate-analysis-doc.mjs` warns on vague wording (`fast`, `appropriately`, `etc.`, `gerektiğinde`, `vb.` and similar) in id-bearing requirement rows (`BR-`, `IG-`, `FG-`); `--strict` turns it into a failure. Code spans and summary prose are not read.
88
+ - `smoke-personal-data.sh` also reads a machine-local pattern list (`~/.claude/personal-data-patterns.txt`, or `MA_PERSONAL_DATA_PATTERNS`), so names that must never ship are guarded without being written into the shipped tree.
89
+ - `pipeline/lib/analysis-sections.mjs` holds the section and table-row readers the validator uses, plus the per-profile location of the redesign artefacts.
90
+ - `argument-hint` on the root `/multi-agent` command and on the Copilot `multi-agent-setup` skill.
91
+ - `/multi-agent:analysis-jira` writes a full story description built from the document: the user story, up to 8 acceptance criteria (the G/W/T column or the rule; functional requirements plus alternative and exception flows on the corporate profile), redesign rows for the story's section, and links to the analysis page, the design and the API spec. Missing parts become body warnings and are never filled in. The preview shows every body in full; `--brief` keeps the one-line view.
92
+ - `escapeJiraWiki()` and `wikiLink()` in `jira-wiki-escape.mjs`: document text is escaped before it reaches wiki markup, and links accept http and https only.
93
+ - `--epic KEY` links the stories to an existing epic: `parent` on Cloud, the discovered Epic Link field on Server and Data Center (`issueTree.epicLinkMode`, `issueTree.epicLinkFieldId`). With no field found, the stories are created unlinked and the writer warns.
94
+ - `issueTree.cloneByChannel` creates one linked clone per channel in `channelComponents`, with its own label and component; `cloneLinkType` names the link.
95
+ - `analysis-tickets-writeback.mjs` writes a `## Tickets` table (story, key, sources, channel) into the analysis document between markers, idempotently; updating the Confluence page is a separate approval.
96
+ - `analysis-story-tree.mjs --page-url URL` links the published analysis page from every story.
97
+ - `validate-analysis-doc.mjs` gains six document-quality checks, in `pipeline/lib/analysis-quality.mjs`: `exception-flow` (a corporate use case with a main flow states its exception flow; missing warns on a draft and fails a final document, `Yok: <reason>` is an accepted answer), `scope-overlap` (an item both goal and non-goal fails), `cited-undefined` (a `BR`/`CB`/`IG`/`UC`/`FG` id the text cites but no table row or heading defines fails), `design-frame-unmapped` (a Figma frame outside every corporate use case warns), `business-layer-technical` (a file path or endpoint in global Part A warns; `<details>` blocks and redesign evidence tables are not read) and `missing-inputs` (a final document with a non-empty missing-inputs panel warns).
98
+ - `build-references.mjs --missing-panel` prints the sources the run could not read as the panel at the top of the document; the render places it above Section 1.
99
+ - `confluence-readback.mjs` reads a published page back and reports each document heading missing from the page and each embedded image that is not attached. The analysis render runs it after every publish and reports a mismatch without republishing.
100
+ - Draft pages carry `[TASLAK]` / `[DRAFT]` in their title until the document is final; the corporate `titleFormat` accepts a `{status}` placeholder.
101
+ - The corporate use-case table has an `İstisna Akışı / Exception Flow` row, the traceability matrix gains `Ekran` and `Test` columns, and Section 20 gains `Kategori` and `Karar` columns with one row per question. Multi-service use cases also get a sequence diagram.
102
+ - Synthesis proposes edge-case candidates from the evidence (`state.analysisSpec.edgeCandidates[]`); only accepted ones enter the document. The global API request body shows types instead of sample values and names each field's source, and the document head carries an "at a glance" line of counts.
103
+ - The analysis review verdict ends with `Publish ready`, an ordered `Fix first` list and a `Verified OK` line.
104
+
105
+ ### Fixed
106
+
107
+ - The corporate profile has a layout for redesign documents: `2.1.1` current behaviour, `2.3.1` difference list and `5.(N+4).1` endpoint mapping, and the validator looks the artefacts up by profile. A corporate document with `redesign: true` previously had no sections the validator would accept.
108
+ - The analysis refs agree with each other: 36 Locked decisions everywhere (the command and `resolve.md` said 35 and 31); section numbers are canonical and keep gaps everywhere (the command and `render.md` said numbering re-flows); the `review.md` verdict example uses the rubric's own class names. `test/analysis-refs-consistency.test.mjs` keeps them aligned.
109
+ - The global Section 20 table carries an `ID` column with `AS-NN` values, which the closure gate pairs on.
110
+ - `feedback` and `review-analysis` descriptions say when to use them.
111
+ - The analysis-jira writer searches for clone labels before creating, so a re-run with `cloneByChannel` no longer creates the clones again. A node found on the site is recorded in the ledger as `exists`.
112
+ - Codex receives stack-plugin skills with their `$HOME/.claude/...` paths retargeted, like the pipeline's own skills.
113
+ - The analysis render resolves `CONFLUENCE_BASE_URL` from `prefs.global.hosts.confluence` before publishing.
114
+ - No analysis file says section numbers re-flow: the global template's omission rule, `synthesis.md`, `analysis-resolve` and the validator all state canonical numbers with gaps, and the consistency test also matches "re-flowed".
115
+
19
116
  ## [20.12.0] - 2026-10-01
20
117
 
21
118
  ### Added
package/README.md CHANGED
@@ -17,7 +17,7 @@ Runs natively on Claude Code, Copilot CLI and Codex CLI. macOS only. Zero runtim
17
17
  ### Prerequisites
18
18
 
19
19
  - **Node.js >= 20.11** - required; the pipeline's own tooling runs on it.
20
- - **`jq`** - required for nine paths, optional for the rest. 89 shell files call it. The nine that publish or decide - the autopilot queue, Jira comments, PR reviews, issue updates, the plan file, both Figma fetchers, log search and Jira auth - refuse with exit 3 rather than run, because a missing `jq` renders as empty DATA and the work carries on with it. Everywhere else it still degrades. The install prints a note when it is missing.
20
+ - **`jq`** - required for nine paths, optional for the rest. 91 shell files call it. The nine that publish or decide - the autopilot queue, Jira comments, PR reviews, issue updates, the plan file, both Figma fetchers, log search and Jira auth - refuse with exit 3 rather than run, because a missing `jq` renders as empty DATA and the work carries on with it. Everywhere else it still degrades. The install prints a note when it is missing.
21
21
  - **`gh`** - for GitHub issue and PR work. Its built-in `--jq` is independent of the `jq` binary.
22
22
 
23
23
  ## Quick Start
@@ -158,7 +158,7 @@ The discipline behind all of this - bounded loops, evidence gates, token-budgete
158
158
 
159
159
  ## Commands
160
160
 
161
- `/multi-agent` plus 61 sub-commands. `/multi-agent:help` renders the same catalog in your terminal, in your `outputLanguage`.
161
+ `/multi-agent` plus 63 sub-commands. `/multi-agent:help` renders the same catalog in your terminal, in your `outputLanguage`.
162
162
 
163
163
  ### Pipeline entries
164
164
 
@@ -191,6 +191,8 @@ The discipline behind all of this - bounded loops, evidence gates, token-budgete
191
191
  | `/multi-agent:review-issue` | Same grading for a GitHub issue |
192
192
  | `/multi-agent:review-analysis` | Review a written analysis document; findings cite the Locked rule they break |
193
193
  | `/multi-agent:diff-explain` | Map a Phase 3 triage finding back to the diff lines that caused it |
194
+ | `/multi-agent:estimate` | Effort range from similar closed work: P25-P75 per role, with the tickets behind it |
195
+ | `/multi-agent:scenario-audit` | Check test scenarios against the code; each PRESENT on a resolving file:line |
194
196
  | `/multi-agent:refactor` | Best-practice extraction + bug hunt + derived-skill drift + toolkit MCP research → one plan |
195
197
  | `/multi-agent:scan` | Skill security scan of local skill directories against a tiered pattern catalog |
196
198
  | `/multi-agent:prune-prompts` | Zero-base review of the always-on instruction footprint; keep / trial / delete per rule |
@@ -392,17 +394,17 @@ This enables the matching plugin (+ the shared `ai-common` plugin) in the repo's
392
394
 
393
395
  ## Tool support
394
396
 
395
- The pipeline runs natively on **Claude Code**, **Copilot CLI** and **Codex CLI** - all three install from the same `pipeline/` source and get the same 61 commands.
397
+ The pipeline runs natively on **Claude Code**, **Copilot CLI** and **Codex CLI** - all three install from the same `pipeline/` source and get the same 63 commands.
396
398
 
397
399
  | Tool | Flag | What it installs |
398
400
  | ----------- | -------------------- | ------------------------------------------------------------------------------------------------------ |
399
401
  | Claude Code | `--claude` (default) | slash commands + skills + agents + three `PreToolUse` hooks (secret scan, agent-guard, read-size gate) |
400
- | Copilot CLI | `--copilot` | instructions + 61 sub-command skills + scripts |
401
- | Codex CLI | `--codex` | one router skill + 61 specs as refs + 10 agent TOML + `AGENTS.md` block + `codex mcp add` |
402
+ | Copilot CLI | `--copilot` | instructions + 63 sub-command skills + scripts |
403
+ | Codex CLI | `--codex` | one router skill + 63 specs as refs + 10 agent TOML + `AGENTS.md` block + `codex mcp add` |
402
404
 
403
405
  Filter skills by stack with `--platform=ios\|android\|all`.
404
406
 
405
- **Why Codex gets one skill and not 61.** Codex assembles every discovered skill's name
407
+ **Why Codex gets one skill and not 63.** Codex assembles every discovered skill's name
406
408
  and description into a single prompt block and drops entries when it overflows, with no
407
409
  error. Measured on 0.145: installing one plugin that declares 142 skills surfaced only
408
410
  75 of them and evicted an unrelated user skill. So on Codex the pipeline ships a single
package/README.tr.md CHANGED
@@ -17,7 +17,7 @@ Claude Code, Copilot CLI ve Codex CLI üzerinde native çalışır. Yalnızca ma
17
17
  ### Önkoşullar
18
18
 
19
19
  - **Node.js >= 20.11** - zorunlu; pipeline'ın kendi araçları bunun üzerinde koşuyor.
20
- - **`jq`** - dokuz yol için zorunlu, geri kalanı için opsiyonel. 89 kabuk dosyası ona başvuruyor. Yayınlayan ya da karar veren dokuzu - autopilot kuyruğu, Jira yorumları, PR review'ları, issue güncellemeleri, plan dosyası, iki Figma fetcher'ı, log araması ve Jira auth - `jq` yokken çalışmak yerine exit 3 ile reddediyor, çünkü eksik bir `jq` boş VERİ olarak görünür ve iş onunla devam eder. Diğer yerlerde `jq` olmadan da çalışıyor, yalnızca daha az şey yapıyor. Kurulum, eksikse bir not basıyor.
20
+ - **`jq`** - dokuz yol için zorunlu, geri kalanı için opsiyonel. 90 kabuk dosyası ona başvuruyor. Yayınlayan ya da karar veren dokuzu - autopilot kuyruğu, Jira yorumları, PR review'ları, issue güncellemeleri, plan dosyası, iki Figma fetcher'ı, log araması ve Jira auth - `jq` yokken çalışmak yerine exit 3 ile reddediyor, çünkü eksik bir `jq` boş VERİ olarak görünür ve iş onunla devam eder. Diğer yerlerde `jq` olmadan da çalışıyor, yalnızca daha az şey yapıyor. Kurulum, eksikse bir not basıyor.
21
21
  - **`gh`** - GitHub issue ve PR işleri için. Kendi dahili `--jq`'su, `jq` ikilisinden bağımsız.
22
22
 
23
23
  ## Hızlı Başlangıç
@@ -157,7 +157,7 @@ Koşunun kendisinde ayarlanabilen tek şey autopilot; geri kalan her şey kendi
157
157
 
158
158
  ## Komutlar
159
159
 
160
- `/multi-agent` ve 61 alt komut. `/multi-agent:help` aynı katalogu terminalde, `outputLanguage` ayarına göre gösterir.
160
+ `/multi-agent` ve 63 alt komut. `/multi-agent:help` aynı katalogu terminalde, `outputLanguage` ayarına göre gösterir.
161
161
 
162
162
  ### Pipeline girişleri
163
163
 
@@ -190,6 +190,8 @@ Koşunun kendisinde ayarlanabilen tek şey autopilot; geri kalan her şey kendi
190
190
  | `/multi-agent:review-issue` | Aynı puanlama, GitHub issue'su için |
191
191
  | `/multi-agent:review-analysis` | Yazılmış analiz dokümanını review eder; bulgular ihlal edilen Locked kuralını gösterir |
192
192
  | `/multi-agent:diff-explain` | Faz 4 triyaj bulgusunu onu doğuran diff satırlarına eşler |
193
+ | `/multi-agent:estimate` | Benzer kapanmış işlerden efor aralığı: rol başına P25-P75, dayandığı ticket'larla |
194
+ | `/multi-agent:scenario-audit` | Test senaryolarını koda karşı denetler; her VAR çözülen bir dosya:satıra dayanır |
193
195
  | `/multi-agent:refactor` | Best-practice çıkarımı + bug avı + türetilmiş skill drift'i + toolkit MCP araştırması → tek plan |
194
196
  | `/multi-agent:scan` | Yerel skill dizinlerini kademeli desen kataloğuna göre güvenlik taraması |
195
197
  | `/multi-agent:prune-prompts` | Sürekli yüklü talimat yükünün sıfır-tabanlı incelemesi; kural başına tut / dene / sil |
@@ -391,17 +393,17 @@ Bu, ilgili plugin'i (+ ortak `ai-common` plugin'ini) repo'nun `.claude/settings.
391
393
 
392
394
  ## Araç desteği
393
395
 
394
- Pipeline **Claude Code**, **Copilot CLI** ve **Codex CLI** üzerinde native çalışır - üçü de aynı `pipeline/` kaynağından kurulur ve aynı 61 komutu alır.
396
+ Pipeline **Claude Code**, **Copilot CLI** ve **Codex CLI** üzerinde native çalışır - üçü de aynı `pipeline/` kaynağından kurulur ve aynı 63 komutu alır.
395
397
 
396
398
  | Araç | Bayrak | Ne kurar |
397
399
  | ----------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------- |
398
400
  | Claude Code | `--claude` (varsayılan) | slash komutları + skill'ler + agent'lar + üç `PreToolUse` hook'u (secret scan, agent-guard, okuma-boyutu geçidi) |
399
- | Copilot CLI | `--copilot` | talimatlar + 61 alt-komut skill'i + script'ler |
400
- | Codex CLI | `--codex` | bir router skill + ref olarak 61 spec + 10 agent TOML + `AGENTS.md` bloğu + `codex mcp add` |
401
+ | Copilot CLI | `--copilot` | talimatlar + 63 alt-komut skill'i + script'ler |
402
+ | Codex CLI | `--codex` | bir router skill + ref olarak 63 spec + 10 agent TOML + `AGENTS.md` bloğu + `codex mcp add` |
401
403
 
402
404
  Skill'leri stack'e göre filtrele: `--platform=ios\|android\|all`.
403
405
 
404
- **Codex neden 61 değil de tek bir skill alıyor.** Codex, keşfettiği her skill'in adını
406
+ **Codex neden 63 değil de tek bir skill alıyor.** Codex, keşfettiği her skill'in adını
405
407
  ve açıklamasını tek bir prompt bloğuna toplar ve blok taştığında girdileri hatasızca
406
408
  düşürür. 0.145 üzerinde ölçüldü: 142 skill deklare eden bir plugin kurulduğunda sadece
407
409
  75'i yüzeye çıktı ve alakasız bir kullanıcı skill'i tahliye edildi. Bu yüzden Codex'te
@@ -113,7 +113,7 @@ graph TB
113
113
  end
114
114
 
115
115
  subgraph "Pipeline Specs"
116
- CMD[commands/<br/>61 command files]
116
+ CMD[commands/<br/>63 command files]
117
117
  AGT[agents/<br/>10 agent personas]
118
118
  RUL[rules/<br/>13 domain rules]
119
119
  PHS[multi-agent-refs/phases/<br/>phase specs + contracts]
@@ -204,8 +204,8 @@ repo and the website, plus the two independently shipped repos
204
204
  ```mermaid
205
205
  graph TD
206
206
  CC["Claude Code<br/>(source of truth)"]
207
- COP["Copilot CLI<br/>(instructions + 61 sub-command skills)"]
208
- COD["Codex CLI<br/>(1 router skill + 61 refs)"]
207
+ COP["Copilot CLI<br/>(instructions + 63 sub-command skills)"]
208
+ COD["Codex CLI<br/>(1 router skill + 63 refs)"]
209
209
  REPO["Pipeline Repo<br/>(npm package)"]
210
210
  WEB["Website"]
211
211
  PLUGREPO["multi-agent-plugins<br/>(6 plugins, own repo)"]
package/docs/ecosystem.md CHANGED
@@ -5,7 +5,7 @@ separately, wired together at install time and at run time:
5
5
 
6
6
  | Repo | What it owns | Ships as |
7
7
  |---|---|---|
8
- | **`multi-agent-pipeline`** (this repo) | Orchestration: the 6-phase flow, the 61 slash commands, quality gates, review/triage, cross-CLI parity | npm package (`@mmerterden/multi-agent-pipeline`), installs itself onto Claude Code / Copilot CLI / Codex CLI |
8
+ | **`multi-agent-pipeline`** (this repo) | Orchestration: the 6-phase flow, the 63 slash commands, quality gates, review/triage, cross-CLI parity | npm package (`@mmerterden/multi-agent-pipeline`), installs itself onto Claude Code / Copilot CLI / Codex CLI |
9
9
  | **`multi-agent-plugins`** | Stack knowledge: per-platform component/lifecycle skills (iOS, Android, Frontend, Backend) + shared knowledge | Claude Code marketplace, 6 independently-versioned plugins |
10
10
  | **`multi-agent-toolkit-mcp`** | The pipeline's hands on devices and browsers: 118 MCP tools across 14 categories (simulator/emulator control, memory, crash diagnostics, accessibility audit, store compliance, web automation, Figma-vs-mock design audit, code intelligence, wallet passes, an agent-DSL batch runner, a full-text context index, provider-backed research, video key frames, offline security scoring) | npm package, registered as a standard stdio MCP server on every host |
11
11
 
@@ -18,7 +18,7 @@ Either can be swapped or removed without touching the other two's source.
18
18
  graph LR
19
19
  subgraph PIPE ["multi-agent-pipeline (orchestrator)"]
20
20
  direction TB
21
- PHASES["6 phases · 61 commands"]
21
+ PHASES["6 phases · 63 commands"]
22
22
  GATES["deterministic gates + review triage"]
23
23
  end
24
24
 
@@ -68,8 +68,8 @@ only those:
68
68
  graph TD
69
69
  CC["Claude Code<br/>~/.claude/commands/multi-agent/<br/>(source of truth)"]
70
70
 
71
- CC -->|"Step 2: copy + reformat<br/>61 sub-command skills"| COP["Copilot CLI<br/>~/.copilot/skills/"]
72
- CC -->|"Step 2b: transform<br/>(install.js --codex)"| COD["Codex CLI<br/>1 router skill + 61 refs<br/>+ 10 agent TOML"]
71
+ CC -->|"Step 2: copy + reformat<br/>63 sub-command skills"| COP["Copilot CLI<br/>~/.copilot/skills/"]
72
+ CC -->|"Step 2b: transform<br/>(install.js --codex)"| COD["Codex CLI<br/>1 router skill + 63 refs<br/>+ 10 agent TOML"]
73
73
  CC -->|"Step 3: genericize<br/>(strip personal data)"| REPO["multi-agent-pipeline repo<br/>pipeline/"]
74
74
  CC -->|"Step 4: version + feature sync"| WEB["Website<br/>projects.ts / i18n.tsx"]
75
75
 
@@ -161,7 +161,7 @@ measurements behind this table):
161
161
 
162
162
  | | Claude Code | Copilot CLI | Codex CLI |
163
163
  |---|---|---|---|
164
- | **Pipeline commands** | 61 slash-command skills, native | 61 sub-command skills, `multi-agent-{cmd}` naming, copied in | 1 router skill (`multi-agent`) + 61 command specs as reference files - Codex silently truncates its skills block past a few dozen entries, so sub-commands are not peer skills here |
164
+ | **Pipeline commands** | 63 slash-command skills, native | 63 sub-command skills, `multi-agent-{cmd}` naming, copied in | 1 router skill (`multi-agent`) + 63 command specs as reference files - Codex silently truncates its skills block past a few dozen entries, so sub-commands are not peer skills here |
165
165
  | **Stack plugins** | Marketplace plugin, loaded natively, resolved by `.claude/settings.json` enabled-list | Enabled plugin's authored skills copied flat into `~/.copilot/skills/`; `knowledge/` **not** re-copied (already delivered via `shared/external`) | Copied as reference files under `~/.codex/multi-agent-refs/skills/`, plugin-prefixed on name clash (e.g. `architecture` → `ai-ios-toolkit-architecture`) |
166
166
  | **Component dispatch (Phase 3)** | Marketplace plugin's `create-component`/`create-screen` skill via the Skill tool | No plugin loader - the enabled stack plugin's authored skills (incl. `create-component`) are copied flat into `~/.copilot/skills/` at install time (the old frozen `figma-*` copies are pruned, they were never a fallback) | Not part of the enforced parity axis; classification + state-shape must match, skill *inventory* does not |
167
167
  | **multi-agent-toolkit-mcp** | `claude mcp add multi-agent-toolkit -- npx -y @mmerterden/multi-agent-toolkit-mcp` | `copilot mcp add multi-agent-toolkit -- npx -y @mmerterden/multi-agent-toolkit-mcp` | `codex mcp add multi-agent-toolkit -- npx -y @mmerterden/multi-agent-toolkit-mcp` (skipped with a warning if `codex` isn't on `PATH`) |
package/docs/facts.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$comment": "Generated by pipeline/scripts/gen-facts.mjs. Do not hand-edit: the site reads this, and a number edited here instead of at its source is the drift this file removes.",
3
- "generatedAt": "2026-10-01",
4
- "version": "20.12.0",
3
+ "generatedAt": "2026-10-02",
4
+ "version": "20.15.0",
5
5
  "phaseSchema": 2,
6
6
  "phases": [
7
7
  {
@@ -35,9 +35,9 @@
35
35
  "autopilot": [0, 1, 2, 3, 4, 5],
36
36
  "analysis": [0, 1, 3, 4, 5]
37
37
  },
38
- "commandCount": 61,
38
+ "commandCount": 63,
39
39
  "skillCount": 154,
40
- "skillCountAll": 218,
40
+ "skillCountAll": 220,
41
41
  "agentCount": 10,
42
42
  "hosts": ["Claude Code", "Codex CLI", "Copilot CLI"],
43
43
  "toolCount": 154,
@@ -591,7 +591,7 @@ export function removePipelineAgentFiles(destDir, agentsSrc) {
591
591
  * @param {string} rel path relative to the copy root, posix-separated
592
592
  * @returns {boolean}
593
593
  */
594
- function isCopyJunk(rel) {
594
+ export function isCopyJunk(rel) {
595
595
  return (
596
596
  rel === ".DS_Store" ||
597
597
  rel.endsWith("/.DS_Store") ||
@@ -182,10 +182,18 @@ export function pluginsToDeliver(home, platformFlag) {
182
182
  * @param {"ios"|"android"|"all"} opts.platformFlag
183
183
  * @param {string} opts.label - host label for log lines
184
184
  * @param {Set<string>} [opts.skipNames] - PIPELINE-owned skill names; a plugin skill matching one is delivered plugin-prefixed rather than dropped
185
+ * @param {(from: string, to: string) => void} [opts.copy] - copies one skill directory; a host whose paths differ from Claude Code's passes a rewriting copy
185
186
  * @returns {{copied: number, renamed: string[], collided: number, plugins: string[], missing: string[]}}
186
187
  */
187
188
  export function installAuthoredPluginSkills(opts) {
188
- const { home, dest, platformFlag, label, skipNames = new Set() } = opts;
189
+ const {
190
+ home,
191
+ dest,
192
+ platformFlag,
193
+ label,
194
+ skipNames = new Set(),
195
+ copy = (from, to) => copyDir(from, to, {}),
196
+ } = opts;
189
197
  const { names: wanted, source: selectionSource } = pluginsToDeliver(home, platformFlag);
190
198
 
191
199
  let copied = 0;
@@ -257,7 +265,7 @@ export function installAuthoredPluginSkills(opts) {
257
265
  // Wipe before copy: `copyDir` only adds, so a file the plugin dropped upstream
258
266
  // would linger in the installed skill and keep being read as current.
259
267
  wipeDir(to);
260
- copyDir(from, to, {});
268
+ copy(from, to);
261
269
  copied += countFiles(from);
262
270
  perPlugin++;
263
271
  }
@@ -315,13 +323,9 @@ export function installAuthoredPluginSkills(opts) {
315
323
  /**
316
324
  * Skill names the PIPELINE owns, derived from its source tree.
317
325
  *
318
- * This is what `skipNames` should be. Callers used to pass a snapshot of
319
- * whatever was already installed (a now-deleted `existingSkillNames(dest)`) - which
320
- * did protect pipeline skills from being shadowed by a plugin, but also meant a
321
- * plugin skill was copied exactly once and then frozen: on the second install its
322
- * own name was "already there", so it was skipped, forever. A stale plugin skill
323
- * then outlives every upstream fix in it, which is how a reference to a path the
324
- * plugin no longer names survived in an installed tree.
326
+ * This is what `skipNames` should be. A snapshot of the destination would also
327
+ * match plugin skills from a previous install, so each would be copied once and
328
+ * then skipped on every later install, frozen against upstream fixes.
325
329
  *
326
330
  * Deriving from the source keeps the shadowing protection (a plugin still cannot
327
331
  * overwrite a pipeline skill) while letting plugin skills refresh on every install.