@hegemonart/get-design-done 1.28.0 → 1.28.5

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 (98) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/CHANGELOG.md +78 -0
  4. package/SKILL.md +1 -1
  5. package/hooks/gdd-decision-injector.js +149 -3
  6. package/package.json +1 -1
  7. package/reference/adr-format.md +96 -0
  8. package/reference/apply-reflections-procedure.md +68 -0
  9. package/reference/architecture-vocabulary.md +102 -0
  10. package/reference/cache-policy.md +126 -0
  11. package/reference/compare-rubric.md +171 -0
  12. package/reference/connections-onboarding.md +417 -0
  13. package/reference/context-md-format.md +106 -0
  14. package/reference/darkmode-audit-procedure.md +258 -0
  15. package/reference/debug-feedback-loops.md +119 -0
  16. package/reference/design-procedure.md +304 -0
  17. package/reference/discover-procedure.md +204 -0
  18. package/reference/explore-procedure.md +267 -0
  19. package/reference/health-mcp-detection.md +44 -0
  20. package/reference/health-skill-length-report.md +69 -0
  21. package/reference/heuristics.md +84 -0
  22. package/reference/milestone-completeness-rubric.md +87 -0
  23. package/reference/peer-cli-protocol.md +161 -0
  24. package/reference/plan-procedure.md +278 -0
  25. package/reference/registry.json +169 -1
  26. package/reference/registry.schema.json +1 -1
  27. package/reference/router-rules.md +84 -0
  28. package/reference/scan-procedure.md +731 -0
  29. package/reference/shared-preamble.md +78 -6
  30. package/reference/skill-authoring-contract.md +128 -0
  31. package/reference/start-procedure.md +115 -0
  32. package/reference/style-doc-procedure.md +150 -0
  33. package/reference/threat-modeling.md +101 -0
  34. package/reference/verify-procedure.md +512 -0
  35. package/scripts/validate-skill-length.cjs +283 -0
  36. package/skills/add-backlog/SKILL.md +1 -0
  37. package/skills/analyze-dependencies/SKILL.md +33 -122
  38. package/skills/apply-reflections/SKILL.md +1 -40
  39. package/skills/audit/SKILL.md +3 -1
  40. package/skills/bandit-status/SKILL.md +31 -66
  41. package/skills/benchmark/SKILL.md +15 -55
  42. package/skills/brief/SKILL.md +12 -1
  43. package/skills/cache-manager/SKILL.md +3 -57
  44. package/skills/check-update/SKILL.md +38 -75
  45. package/skills/compare/SKILL.md +29 -269
  46. package/skills/complete-cycle/SKILL.md +1 -1
  47. package/skills/connections/SKILL.md +21 -427
  48. package/skills/continue/SKILL.md +1 -0
  49. package/skills/darkmode/SKILL.md +32 -287
  50. package/skills/debug/SKILL.md +11 -8
  51. package/skills/design/SKILL.md +27 -245
  52. package/skills/discover/SKILL.md +26 -133
  53. package/skills/discuss/SKILL.md +18 -2
  54. package/skills/explore/SKILL.md +40 -205
  55. package/skills/fast/SKILL.md +1 -0
  56. package/skills/figma-write/SKILL.md +2 -2
  57. package/skills/health/SKILL.md +11 -33
  58. package/skills/help/SKILL.md +1 -0
  59. package/skills/list-assumptions/SKILL.md +1 -0
  60. package/skills/map/SKILL.md +8 -31
  61. package/skills/new-cycle/SKILL.md +3 -1
  62. package/skills/next/SKILL.md +1 -0
  63. package/skills/note/SKILL.md +1 -0
  64. package/skills/optimize/SKILL.md +21 -44
  65. package/skills/pause/SKILL.md +1 -0
  66. package/skills/peer-cli-add/SKILL.md +26 -108
  67. package/skills/peer-cli-customize/SKILL.md +22 -42
  68. package/skills/peers/SKILL.md +33 -57
  69. package/skills/plan/SKILL.md +33 -220
  70. package/skills/plant-seed/SKILL.md +1 -0
  71. package/skills/pr-branch/SKILL.md +1 -0
  72. package/skills/progress/SKILL.md +1 -7
  73. package/skills/quality-gate/SKILL.md +34 -166
  74. package/skills/quick/SKILL.md +1 -0
  75. package/skills/reapply-patches/SKILL.md +1 -0
  76. package/skills/recall/SKILL.md +1 -0
  77. package/skills/resume/SKILL.md +1 -0
  78. package/skills/review-backlog/SKILL.md +1 -0
  79. package/skills/router/SKILL.md +3 -59
  80. package/skills/scan/SKILL.md +36 -675
  81. package/skills/settings/SKILL.md +1 -0
  82. package/skills/ship/SKILL.md +1 -0
  83. package/skills/sketch/SKILL.md +1 -1
  84. package/skills/sketch-wrap-up/SKILL.md +13 -54
  85. package/skills/spike/SKILL.md +1 -1
  86. package/skills/spike-wrap-up/SKILL.md +12 -46
  87. package/skills/start/SKILL.md +13 -112
  88. package/skills/stats/SKILL.md +1 -0
  89. package/skills/style/SKILL.md +18 -140
  90. package/skills/synthesize/SKILL.md +1 -0
  91. package/skills/timeline/SKILL.md +1 -0
  92. package/skills/todo/SKILL.md +1 -0
  93. package/skills/turn-closeout/SKILL.md +36 -56
  94. package/skills/undo/SKILL.md +1 -0
  95. package/skills/update/SKILL.md +1 -0
  96. package/skills/verify/SKILL.md +42 -457
  97. package/skills/warm-cache/SKILL.md +3 -35
  98. package/skills/zoom-out/SKILL.md +26 -0
@@ -10,61 +10,42 @@ tools: Read, Bash, Grep, Write
10
10
 
11
11
  ## Role
12
12
 
13
- You are the optimization advisor. You read the telemetry ledger (`.design/telemetry/costs.jsonl`) and the per-agent metrics aggregate (`.design/agent-metrics.json`), apply a fixed set of rule-based heuristics, and emit recommendations to `.design/OPTIMIZE-RECOMMENDATIONS.md`. You never modify agent files, budget config, or cache state. Your output is a markdown table of proposals the user reviews manually, mirroring the Phase 11 `/gdd:apply-reflections` discipline.
14
-
15
- This skill is **advisory only**. It never edits `agents/*.md`, `.design/budget.json`, `.design/cache-manifest.json`, or any other configuration. The skill never makes model calls — every rule is deterministic.
13
+ Read the telemetry ledger (`.design/telemetry/costs.jsonl`) and per-agent aggregate (`.design/agent-metrics.json`), apply a fixed set of rule-based heuristics, and emit recommendations to `.design/OPTIMIZE-RECOMMENDATIONS.md`. Never modify agent files, budget config, or cache state. Output is a markdown table of proposals the user reviews manually, mirroring Phase 11 `/gdd:apply-reflections`. **Advisory only**: never edits `agents/*.md`, `.design/budget.json`, `.design/cache-manifest.json`. Never makes model calls — every rule is deterministic. See `./reference/heuristics.md` §"Optimization rules" for the full rule catalog.
16
14
 
17
15
  ## Refresh Step
18
16
 
19
- Before analysis, invoke the aggregator to ensure metrics are current:
17
+ Before analysis, invoke the aggregator:
20
18
 
21
19
  ```bash
22
20
  node --experimental-strip-types scripts/aggregate-agent-metrics.ts
23
21
  ```
24
22
 
25
- This is idempotent. If `--refresh` flag is absent and `.design/agent-metrics.json` was generated within the last 60 seconds, the skill may skip this step.
23
+ Idempotent. If `--refresh` absent and `.design/agent-metrics.json` generated within 60s, skip.
26
24
 
27
25
  ## Inputs
28
26
 
29
- - `.design/telemetry/costs.jsonl` — append-only; skill reads tail. Tolerant of malformed lines.
30
- - `.design/agent-metrics.json` — per-agent aggregate produced by `scripts/aggregate-agent-metrics.ts`. Source of truth for `cache_hit_rate`, `lazy_skip_rate`, `total_cost_usd`, `total_spawns`.
31
- - `agents/*.md` — frontmatter cross-reference when checking tier override churn + typical-duration drift.
32
- - `.design/budget.json` — `tier_overrides` table for cross-check (optional; proceed if missing).
27
+ - `.design/telemetry/costs.jsonl` — append-only; tolerant of malformed lines.
28
+ - `.design/agent-metrics.json` — per-agent aggregate; source of truth for `cache_hit_rate`, `lazy_skip_rate`, `total_cost_usd`, `total_spawns`.
29
+ - `agents/*.md` — frontmatter cross-reference for tier override churn + typical-duration drift.
30
+ - `.design/budget.json` — `tier_overrides` table (optional).
33
31
 
34
32
  ## Optional Arguments
35
33
 
36
34
  - `--refresh` — force aggregator refresh even if metrics file is fresh.
37
- - `--min-spawns=N` — only emit recommendations for agents with ≥ N spawns (default: 5; raise for high-traffic projects to suppress noise).
35
+ - `--min-spawns=N` — only emit recommendations for agents with ≥ N spawns (default 5).
38
36
 
39
37
  ## Rules
40
38
 
41
- Rule-based analysis, applied in this order. Each rule inspects per-agent aggregates and emits zero or more rows to the recommendations table.
42
-
43
- **Rule R1 — Low cache hit rate.**
44
- > IF an agent has `total_spawns >= --min-spawns` AND `cache_hit_rate < 0.20`
45
- > THEN emit: `"Consider batching tasks for agent {agent} — cache hit rate is {rate*100}%. Investigate cache-aligned ordering (see reference/shared-preamble.md) and whether input paths can be normalized."`
46
- > PROPOSED: Batch similar tasks; confirm shared-preamble import ordering.
47
-
48
- **Rule R2 — Expensive and rarely lazy-skipped.**
49
- > IF an agent has `total_cost_usd > 0.50` AND `lazy_skip_rate < 0.10`
50
- > THEN emit: `"Agent {agent} is expensive (${cost}) and rarely skipped ({rate*100}% lazy-skip). Consider adding a lazy gate heuristic at agents/{agent}-gate.md (see plan 10.1-04 pattern)."`
51
- > PROPOSED: Add lazy-gate agent.
39
+ Rule-based analysis. Full thresholds + emission templates in `./reference/heuristics.md` §"Optimization rules"; here, the short rule catalog:
52
40
 
53
- **Rule R3 Tier override churn.**
54
- > IF for multiple telemetry rows an agent's recorded `tier` differs from its frontmatter `default-tier` (e.g., frontmatter says `opus` but measured rows consistently show `haiku` from budget.json override or soft-threshold downgrade)
55
- > THEN emit: `"Tier override churn detected for {agent}: frontmatter says {frontmatter-tier} but measured tier is {measured-tier} in {N} of last {M} rows. Consider updating frontmatter default-tier or removing the budget.json override."`
56
- > PROPOSED: Update frontmatter default-tier OR prune budget.json tier_overrides entry.
57
-
58
- **Rule R4 — Typical duration drift.**
59
- > IF measured `typical_duration_seconds` (computed as average wall-clock duration from telemetry `ts` deltas when paired spawn/complete rows exist; fall back to frontmatter value if pairing unavailable in v1) differs from frontmatter `typical-duration-seconds` by more than 50%
60
- > THEN emit: `"Typical duration for {agent} has drifted: frontmatter {old}s vs measured {new}s ({delta_pct}% drift). Update frontmatter typical-duration-seconds: {new}."`
61
- > PROPOSED: Edit agents/{agent}.md frontmatter.
62
-
63
- (Note: v1 only computes wall-clock duration if the telemetry ledger carries both spawn and complete rows with matching correlation IDs. If it doesn't — 10.1's PreToolUse-only writer doesn't — Rule R4 flags "insufficient data" for affected agents rather than emitting a false proposal. Phase 11 reflector can add a PostToolUse writer to close this gap; out of 10.1 scope.)
41
+ - **R1Low cache hit rate.** IF `total_spawns >= --min-spawns` AND `cache_hit_rate < 0.20` → propose batching + investigate shared-preamble ordering.
42
+ - **R2 Expensive + rarely lazy-skipped.** IF `total_cost_usd > 0.50` AND `lazy_skip_rate < 0.10` propose adding a lazy gate at `agents/{agent}-gate.md` (Plan 10.1-04 pattern).
43
+ - **R3 Tier override churn.** IF measured `tier` differs from frontmatter `default-tier` for multiple rows propose updating frontmatter or removing budget.json override.
44
+ - **R4 — Typical duration drift.** IF measured `typical_duration_seconds` differs from frontmatter by > 50% propose frontmatter update. (v1 only computes wall-clock duration if both spawn + complete rows have matching correlation IDs; otherwise flag "insufficient data".)
64
45
 
65
46
  ## Output Format
66
47
 
67
- Write `.design/OPTIMIZE-RECOMMENDATIONS.md` with this exact structure:
48
+ Write `.design/OPTIMIZE-RECOMMENDATIONS.md`:
68
49
 
69
50
  ```markdown
70
51
  # Optimization Recommendations
@@ -80,9 +61,7 @@ Write `.design/OPTIMIZE-RECOMMENDATIONS.md` with this exact structure:
80
61
 
81
62
  | Rule | Agent | Current | Proposed | Rationale |
82
63
  |------|-------|---------|----------|-----------|
83
- | R1 | design-verifier | cache_hit_rate: 8% | Batch tasks; audit shared-preamble ordering | Low cache reuse; likely causing 3× cost on repeated calls |
84
- | R2 | design-planner | $1.23 cost, 2% lazy-skip | Add agents/design-planner-gate.md | High spend with minimal gating |
85
- | R3 | design-verifier | frontmatter opus / measured haiku (9/12 rows) | Update frontmatter default-tier: haiku | budget.json overrides are effectively permanent |
64
+ | R1 | ... | ... | ... | ... |
86
65
 
87
66
  ## Summary
88
67
 
@@ -94,17 +73,15 @@ Write `.design/OPTIMIZE-RECOMMENDATIONS.md` with this exact structure:
94
73
  ## OPTIMIZE COMPLETE
95
74
  ```
96
75
 
97
- The `## OPTIMIZE COMPLETE` marker is the completion sentinel — automated graders and downstream tools detect completion by grepping for this exact line.
76
+ The `## OPTIMIZE COMPLETE` marker is the completion sentinel.
98
77
 
99
78
  ## No Auto-Apply
100
79
 
101
- This skill **never modifies** `agents/*.md`, `.design/budget.json`, `.design/cache-manifest.json`, or any other configuration. It **never auto-applies** proposals. It only writes `.design/OPTIMIZE-RECOMMENDATIONS.md`. If the user wants to act on a proposal, they do so manually (or via a future Phase 12 command that cross-references these proposals).
102
-
103
- The discipline mirrors `/gdd:apply-reflections` from Phase 11: advisory output, user review, manual application.
80
+ This skill **never modifies** `agents/*.md`, `.design/budget.json`, `.design/cache-manifest.json`, or any other configuration. **Never auto-applies** proposals. If the user wants to act, they do so manually. Discipline mirrors `/gdd:apply-reflections` from Phase 11.
104
81
 
105
82
  ## Integration with Phase 11 Reflector
106
83
 
107
- The Phase 11 reflector (`agents/design-reflector.md`) reads both `costs.jsonl` and `agent-metrics.json` on its own cadence. `/gdd:optimize` is the user-facing advisor; the reflector is the automation-facing one. Both output to different files (`.design/OPTIMIZE-RECOMMENDATIONS.md` vs `.design/reflections/*.md`) and never collide.
84
+ The Phase 11 reflector (`agents/design-reflector.md`) reads both `costs.jsonl` and `agent-metrics.json` on its own cadence. `/gdd:optimize` is user-facing; the reflector is automation-facing. Outputs land in different files (`.design/OPTIMIZE-RECOMMENDATIONS.md` vs `.design/reflections/*.md`) and never collide.
108
85
 
109
86
  ## Non-Goals
110
87
 
@@ -115,6 +92,6 @@ The Phase 11 reflector (`agents/design-reflector.md`) reads both `costs.jsonl` a
115
92
 
116
93
  ## Failure Modes
117
94
 
118
- - Missing `.design/telemetry/costs.jsonl` → emit a single line `"No telemetry data yet — run one or more /gdd:* commands to accumulate data, then retry."` and still write the `## OPTIMIZE COMPLETE` marker.
119
- - Missing `.design/agent-metrics.json` after refresh → emit `"Aggregator failed — check \`node --experimental-strip-types scripts/aggregate-agent-metrics.ts\` output manually."`.
120
- - Zero rules matched → still write the recommendations file with `"No recommendations — all agents within healthy thresholds."` and the `## OPTIMIZE COMPLETE` marker.
95
+ - Missing `.design/telemetry/costs.jsonl` → emit `No telemetry data yet — run /gdd:* commands to accumulate data, then retry.` + `## OPTIMIZE COMPLETE`.
96
+ - Missing `.design/agent-metrics.json` after refresh → emit `Aggregator failed — check node --experimental-strip-types scripts/aggregate-agent-metrics.ts output manually.`
97
+ - Zero rules matched → write `No recommendations — all agents within healthy thresholds.` + `## OPTIMIZE COMPLETE`.
@@ -3,6 +3,7 @@ name: gdd-pause
3
3
  description: "Write a numbered checkpoint so work can resume in a new session without re-running completed stages."
4
4
  argument-hint: "[context note]"
5
5
  tools: Read, Write, Bash, AskUserQuestion, mcp__gdd_state__get, mcp__gdd_state__set_status, mcp__gdd_state__add_blocker, mcp__gdd_state__checkpoint
6
+ disable-model-invocation: true
6
7
  ---
7
8
 
8
9
  @reference/retrieval-contract.md
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: peer-cli-add
3
- description: "Guided ladder for adding a brand-new peer (a peer not in the v1.27 capability matrix) to the gdd peer-CLI delegation layer. Verification ladder + adapter scaffolding + capability-matrix update + Windows quirks documented. Run when you discover a new peer CLI you want gdd to delegate to."
3
+ description: "Guided ladder for adding a brand-new peer (not in the v1.27 capability matrix) to gdd's peer-CLI delegation layer. Walks the verification ladder, scaffolds an adapter, updates the capability matrix, and handles Windows quirks. Run when you discover a new peer CLI you want gdd to delegate to."
4
4
  argument-hint: "<new-peer-id> <peer-binary> <protocol: acp|asp>"
5
5
  tools: Read, Edit, Write, Bash, Grep
6
6
  ---
@@ -11,118 +11,49 @@ tools: Read, Edit, Write, Bash, Grep
11
11
 
12
12
  ## Role
13
13
 
14
- You add a brand-new peer-CLI to gdd's delegation layer. v1.27.0 ships 5 peers (codex, gemini, cursor, copilot, qwen). When the user wants a 6th — a peer that exists in the wild but isn't in our capability matrix yet they run this skill. It walks them through a verification ladder (does the peer actually speak ACP or ASP?) and produces the 3-file footprint that integrates the peer cleanly.
14
+ You add a brand-new peer-CLI to gdd's delegation layer. v1.27.0 ships 5 peers (codex, gemini, cursor, copilot, qwen). When the user wants a 6th — a peer that exists in the wild but isn't in our capability matrix — you walk them through the verification ladder and produce the 3-file footprint that integrates the peer cleanly. The procedural ladder, adapter scaffold shape, and verification gate live in `./reference/peer-cli-protocol.md`.
15
15
 
16
16
  ## Invocation Contract
17
17
 
18
- - **Required input**: `<new-peer-id>` (lowercase identifier, e.g., `aider`), `<peer-binary>` (the executable name, e.g., `aider` or `aider.cmd`), `<protocol>` (`acp` or `asp`).
19
- - **Output**: a 3-file diff + a verification report.
18
+ - **Required input:** `<new-peer-id>` (lowercase, e.g. `aider`), `<peer-binary>` (executable, e.g. `aider` or `aider.cmd`), `<protocol>` (`acp` or `asp`).
19
+ - **Output:** a 3-file diff + a verification report.
20
20
 
21
21
  ## Procedure
22
22
 
23
23
  ### Step 1 — Verification ladder (no edits yet)
24
24
 
25
- Before touching any code, confirm the peer actually speaks the protocol it claims.
25
+ Walk the four-rung ladder in `./reference/peer-cli-protocol.md` §"Verification ladder":
26
26
 
27
- #### 1a. Binary on PATH
27
+ 1. Binary on PATH (`which` / `where`).
28
+ 2. Handshake test (`initialize` JSON-RPC over stdin; capture reply).
29
+ 3. Model-ID `-preview`-suffix trap (capture model list).
30
+ 4. Windows quirks (confirm `spawn-cmd.cjs` picks up `.cmd`).
28
31
 
29
- `which <peer-binary>` (POSIX) or `where <peer-binary>` (Windows). If exit non-zero, stop and ask user to install the peer first.
30
-
31
- #### 1b. Handshake test
32
-
33
- Spawn the peer with the appropriate protocol entry point:
34
- - ACP peers: `<peer-binary> acp` (or whatever the peer documents as its ACP entry — Gemini uses `gemini acp`; some peers use a flag).
35
- - ASP peers: `<peer-binary> app-server` (Codex's convention; other ASP peers may differ).
36
-
37
- Send an `initialize` JSON-RPC message over stdin with `protocolVersion: '2025-06-18'` (ACP) or `service_name: 'gdd_peer_delegation'` (ASP).
38
-
39
- Capture the reply on stdout. If the reply is a valid JSON-RPC response with `result.protocolVersion` (ACP) or `result.threadId` (ASP), the peer speaks the protocol.
40
-
41
- If no valid reply within 5 seconds, the peer either doesn't speak this protocol or uses a non-standard entry point. Stop and ask the user for the correct invocation.
42
-
43
- #### 1c. Model-ID `-preview`-suffix trap
44
-
45
- Many peers expose preview models with a `-preview` suffix (e.g., `gpt-5-preview` vs `gpt-5`). The suffix drifts: today's preview is tomorrow's GA. Capture the peer's current model list (most peers expose `<peer-binary> models` or similar). Note any model that has `-preview` in its name and document the parent name in the new entry's `provider_model_id` field — so the runtime-models.md entry can survive the suffix flipping.
46
-
47
- #### 1d. Windows quirks
48
-
49
- If the peer-binary ends in `.cmd` and the user is on Windows, confirm the spawn-cmd shell-escape logic from `scripts/lib/peer-cli/spawn-cmd.cjs` will pick it up (it should — that module already handles `.cmd` detection per Plan 27-03 / D-04). Document any other Windows-specific quirks in the new adapter's leading comment.
32
+ Stop at the first failing rung. Do not proceed to scaffold a broken adapter.
50
33
 
51
34
  ### Step 2 — Generate the adapter scaffold
52
35
 
53
- Use the existing 5 adapters at `scripts/lib/peer-cli/adapters/{codex,gemini,cursor,copilot,qwen}.cjs` as templates. Pick the closest match to your new peer's protocol (ASP if `<protocol> = asp`, otherwise ACP).
36
+ Copy one of `scripts/lib/peer-cli/adapters/{codex,gemini,cursor,copilot,qwen}.cjs` as the template (pick by protocol — ASP for `<protocol>=asp`, else ACP). Replace `ROLES_CLAIMED`, `ROLE_PREFIX`, `name`, `protocol` with the user's values from Step 1. The full adapter scaffold shape — `claims`, `dispatch`, exports — lives in `./reference/peer-cli-protocol.md` §"Adapter scaffold shape" so consumers (codex/gemini/cursor/copilot/qwen) stay byte-similar.
54
37
 
55
- Use the `Write` tool to create `scripts/lib/peer-cli/adapters/<new-peer-id>.cjs`:
38
+ Write the result to `scripts/lib/peer-cli/adapters/<new-peer-id>.cjs`.
56
39
 
57
- ```js
58
- 'use strict';
40
+ ### Step 3 — Three-file footprint
59
41
 
60
- const { createAcpClient } = require('../acp-client.cjs');
61
- // OR for ASP peers: const { createAspClient } = require('../asp-client.cjs');
42
+ Per `./reference/peer-cli-protocol.md` §"Three-file footprint":
62
43
 
63
- const ROLES_CLAIMED = ['<role-1>', '<role-2>']; // ASK USER which roles this peer claims
64
- const ROLE_PREFIX = {
65
- '<role-1>': '<prompt prefix or empty string>',
66
- '<role-2>': '<prompt prefix or empty string>',
67
- };
44
+ 1. New adapter at `scripts/lib/peer-cli/adapters/<new-peer-id>.cjs` (Step 2).
45
+ 2. Edit `scripts/lib/install/runtimes.cjs` — add `peerBinary` field (platform-aware: `<peer-binary>.cmd` on Windows, plain on POSIX).
46
+ 3. Edit `reference/peer-cli-capabilities.md` add matrix row + per-peer section citing the Step 1 verification evidence.
47
+ 4. Edit `scripts/lib/peer-cli/registry.cjs` append to `CAPABILITY_MATRIX` (and `KNOWN_PEERS` if separate).
68
48
 
69
- function claims(role) { return ROLES_CLAIMED.includes(role); }
49
+ ### Step 4 Verification gate
70
50
 
71
- async function dispatch({ command, args, cwd, env }, role, text, opts) {
72
- if (!claims(role)) {
73
- throw new Error(`<new-peer-id> does not claim role: ${role}`);
74
- }
75
- const client = createAcpClient({ command, args, cwd, env });
76
- try {
77
- await client.initialize({ protocolVersion: '2025-06-18' });
78
- const prompt = (ROLE_PREFIX[role] || '') + text;
79
- return await client.prompt(prompt, { onNotification: opts?.onNotification });
80
- } finally {
81
- await client.close();
82
- }
83
- }
84
-
85
- module.exports = { claims, dispatch, ROLES_CLAIMED, ROLE_PREFIX, name: '<new-peer-id>', protocol: '<protocol>' };
86
- ```
51
+ Run the four-check gate in `./reference/peer-cli-protocol.md` §"Verification gate": `tsc --noEmit`, peer-cli tests, reference-registry round-trip, frontmatter validator. Any failure — surface error + offer revert.
87
52
 
88
- Replace placeholders with the user's input from Step 1's verification.
89
-
90
- ### Step 3 — Add `peerBinary` to runtimes.cjs
91
-
92
- Edit `scripts/lib/install/runtimes.cjs` to add an entry for the new peer. Mirror the shape of the 5 existing peer entries. Add the `peerBinary` field with platform-aware resolution:
93
-
94
- ```js
95
- {
96
- id: '<new-peer-id>',
97
- // ... existing fields per Phase 24 runtime matrix shape ...
98
- peerBinary: process.platform === 'win32' ? '<peer-binary>.cmd' : '<peer-binary>',
99
- }
100
- ```
101
-
102
- ### Step 4 — Add the capability-matrix entry
103
-
104
- Edit `reference/peer-cli-capabilities.md`. Add a new row to the top capability matrix table AND a new per-peer section. Follow the existing format. Cite the verification evidence from Step 1.
105
-
106
- ### Step 5 — Update the registry capability matrix
107
-
108
- Edit `scripts/lib/peer-cli/registry.cjs`. Add the new peer to the `CAPABILITY_MATRIX` constant (and `KNOWN_PEERS` if that's a separate list). Mirror the shape of the 5 existing entries.
109
-
110
- ### Step 6 — Verify the integration
111
-
112
- Run, in this order, until each passes:
113
-
114
- 1. `npx tsc --noEmit` — clean.
115
- 2. `node --test tests/peer-cli-registry.test.cjs tests/peer-cli-adapters.test.cjs` — no regression on existing tests.
116
- 3. `node --test tests/reference-registry.test.cjs` — capability-matrix doc is in registry.json (if you added it).
117
- 4. `npm run validate:frontmatter` — no agent's `delegate_to:` field is broken by the new entry.
118
-
119
- If any step fails, surface the error and offer to revert the changes.
120
-
121
- ### Step 7 — Surface a 3-file footprint summary
53
+ ### Step 5 Surface the summary
122
54
 
123
55
  ```
124
56
  ## peer-cli-add summary
125
-
126
57
  Added peer: <new-peer-id> (protocol: <protocol>)
127
58
  Roles claimed: <role-1>, <role-2>
128
59
 
@@ -139,31 +70,18 @@ Verification:
139
70
  ✓ frontmatter validator: 0 violations
140
71
 
141
72
  Next steps:
142
- - Run /gdd:peers to confirm the new peer shows up in the capability matrix.
143
- - Run skills/peer-cli-customize/SKILL.md to wire delegate_to: <new-peer-id>-<role> on specific agents.
144
- - Phase 23.5 bandit will need ~5 cycles of data before the posterior surfaces a recommendation for this peer.
73
+ - /gdd:peers to confirm the new peer appears in the matrix.
74
+ - skills/peer-cli-customize/SKILL.md to wire delegate_to: <new-peer-id>-<role> on agents.
75
+ - Phase 23.5 bandit needs ~5 cycles of data before a posterior recommendation surfaces.
145
76
  ```
146
77
 
147
78
  ## Edge cases
148
79
 
149
- - **Peer speaks neither ACP nor ASP** — gdd v1.27 ships only those two protocols. Stop and document the gap in `.design/RESEARCH.md` for a future phase to consider adding a new protocol layer.
150
- - **Peer claims a role no existing peer claims** (e.g., `translate`) — fine, capability matrix is open. But document the role in `reference/peer-cli-capabilities.md` so future peers can compete on it.
151
- - **Peer claims ALL roles** (e.g., a generalist peer) — accept, but flag in the per-peer section. Generalist peers are usually weaker than specialist peers; the bandit will sort it out via measurement.
152
- - **Peer name conflicts with an existing peer-id** — fail. Peer-IDs must be globally unique. Suggest a disambiguating suffix.
153
- - **User wants to add a peer for testing only** — same flow, but suggest committing under a separate branch and not adding to the install-time detection nudge until the peer is production-ready.
154
-
155
- ## Cross-references
156
-
157
- - `scripts/lib/peer-cli/registry.cjs` (Plan 27-05) — capability matrix data.
158
- - `scripts/lib/peer-cli/adapters/*.cjs` (Plan 27-04) — adapter template.
159
- - `scripts/lib/peer-cli/spawn-cmd.cjs` (Plan 27-03) — Windows .cmd handling.
160
- - `reference/peer-cli-capabilities.md` (Plan 27-05) — capability-matrix doc.
161
- - `skills/peer-cli-customize/SKILL.md` — once new peer is added, use customize to wire it on specific agents.
162
- - `.planning/phases/27-peer-cli-delegation/CONTEXT.md` D-02, D-05 — decision lineage.
80
+ See `./reference/peer-cli-protocol.md` §"Edge cases" for: peer speaks neither protocol, claims unknown role, claims all roles (generalist), peer-ID conflicts, and testing-only peers.
163
81
 
164
82
  ## Record
165
83
 
166
- After execution, append one JSONL line to `.design/skill-records.jsonl`:
84
+ Append one JSONL line to `.design/skill-records.jsonl`:
167
85
 
168
86
  ```json
169
87
  {"skill": "peer-cli-add", "ts": "<ISO timestamp>", "new_peer": "<new-peer-id>", "protocol": "<protocol>", "roles_claimed": ["<role-1>"], "verification_passed": true}
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: peer-cli-customize
3
- description: "Rewire rolepeer mappings on a per-agent basis. File-edit-driven (touches frontmatter delegate_to: per agent), no runtime config layer. Run when you want a specific agent to delegate to a different peer than the default capability-matrix mapping suggests."
3
+ description: "Rewire role->peer mappings on a per-agent basis. File-edit-driven (touches frontmatter delegate_to: per agent), no runtime config layer. Run when you want a specific agent to delegate to a different peer than the default capability-matrix mapping suggests."
4
4
  argument-hint: "[<agent-name>] [<new-delegate-target>]"
5
5
  tools: Read, Edit, Bash, Grep
6
6
  ---
@@ -11,7 +11,7 @@ tools: Read, Edit, Bash, Grep
11
11
 
12
12
  ## Role
13
13
 
14
- You help the user rewire which peer-CLI delegate handles which agent's calls. The mechanism is direct file-edits to agent frontmatter (`delegate_to:` field added in Plan 27-06) — there is no runtime config layer. Your job is to make this safe and validatable.
14
+ You help the user rewire which peer-CLI delegate handles which agent's calls. The mechanism is direct file-edits to agent frontmatter (`delegate_to:` field added in Plan 27-06) — there is no runtime config layer. Your job is to make this safe and validatable. The rewire discipline (per-edit validation, three frontmatter cases, validator gate) lives in `./reference/peer-cli-protocol.md` §"Rewire discipline" so the procedure stays canonical across consumers.
15
15
 
16
16
  ## Invocation Contract
17
17
 
@@ -22,83 +22,63 @@ You help the user rewire which peer-CLI delegate handles which agent's calls. Th
22
22
 
23
23
  ### Step 1 — Show current state
24
24
 
25
- Read the capability matrix from `scripts/lib/peer-cli/registry.cjs#describeCapabilities()`. Surface the 5 peers and their claimed roles to the user.
26
-
27
- Then scan `agents/*.md` and grep for `delegate_to:` frontmatter values. Render a table:
28
-
29
- ```
30
- | Agent | delegate_to (current) |
31
- |----------------------------|------------------------|
32
- | design-reflector | none |
33
- | design-context-checker | (unset) |
34
- | design-verifier | gemini-research |
35
- | ... | ... |
36
- ```
25
+ Read the capability matrix from `scripts/lib/peer-cli/registry.cjs#describeCapabilities()`. Surface the 5 peers and their claimed roles to the user. Then scan `agents/*.md` and grep for `delegate_to:` frontmatter values. Render a two-column table (`Agent | delegate_to (current)`) listing every agent's current setting (or `(unset)` for absent fields).
37
26
 
38
27
  ### Step 2 — Confirm rewire intent
39
28
 
40
- Either accept the user's explicit `<agent-name> <new-delegate-target>` arguments OR ask: "Which agent do you want to rewire? What should `delegate_to:` become?"
29
+ Accept the user's explicit `<agent-name> <new-delegate-target>` arguments OR ask: "Which agent do you want to rewire? What should `delegate_to:` become?"
41
30
 
42
31
  Valid `<new-delegate-target>` values:
32
+
43
33
  - `<peer>-<role>` from the capability matrix (e.g., `gemini-research`, `codex-execute`, `cursor-debug`, `cursor-plan`, `copilot-review`, `copilot-research`, `qwen-write`).
44
- - `none` (explicit opt-out).
45
- - Empty / `(unset)` to remove the field entirely (revert to default behavior).
34
+ - `none` explicit opt-out.
35
+ - Empty / `(unset)` remove the field entirely; revert to default behavior.
46
36
 
47
37
  ### Step 3 — Validate the proposed rewire
48
38
 
49
- Cross-check the new value against the capability matrix:
39
+ Cross-check against the capability matrix per `./reference/peer-cli-protocol.md` §"Rewire discipline":
40
+
50
41
  1. The peer must exist in the matrix.
51
42
  2. The role must be in the peer's `claims` list.
52
- 3. The peer must (eventually, at runtime) be in `.design/config.json#peer_cli.enabled_peers` for dispatch to fire — but that's a runtime concern, not a frontmatter validation concern.
43
+ 3. Runtime allowlisting (`peer_cli.enabled_peers`) is a runtime concern, NOT a frontmatter validation concern.
53
44
 
54
45
  If validation fails, surface the error and stop. Do not edit the file.
55
46
 
56
47
  ### Step 4 — Apply the edit
57
48
 
58
- Use the `Edit` tool to modify the agent's frontmatter. Three cases:
59
-
60
- **Case A: Field is absent, user wants to add it.**
61
- Insert `delegate_to: <new-target>` into the frontmatter block (between the existing `default-tier:` and the next field, or at the end of frontmatter). Preserve YAML formatting.
62
-
63
- **Case B: Field is present, user wants to change the value.**
64
- Replace the existing value. If the existing value is `none` and the new value is `<peer>-<role>`, just swap. Mirror the existing indentation.
49
+ Use the `Edit` tool. Three cases (per `./reference/peer-cli-protocol.md` §"Rewire discipline"):
65
50
 
66
- **Case C: Field is present, user wants to remove it.**
67
- Delete the entire `delegate_to:` line. The field is optional absence === default behavior.
51
+ - **Field absent, user wants to add:** insert `delegate_to: <new-target>` into frontmatter (between `default-tier:` and the next field, or at the end of frontmatter).
52
+ - **Field present, user wants to change:** replace the value; preserve indentation.
53
+ - **Field present, user wants to remove:** delete the entire `delegate_to:` line.
68
54
 
69
- ### Step 5 — Re-validate via the frontmatter validator
55
+ ### Step 5 — Re-validate
70
56
 
71
- Run `npm run validate:frontmatter` (or whatever the project's frontmatter check is). Confirm the modified agent passes. If validation fails, surface the error and offer to revert.
57
+ Run `npm run validate:frontmatter`. Confirm the modified agent passes. If validation fails, surface the error and offer to revert (re-run `Edit` with inverse old/new strings).
72
58
 
73
59
  ### Step 6 — Surface a diff summary
74
60
 
75
- Report back:
76
-
77
61
  ```
78
62
  ## Rewire summary
79
-
80
63
  ✓ design-verifier: delegate_to: gemini-research → cursor-debug
81
64
  ✓ design-reflector: delegate_to (unset) → codex-execute
82
65
 
83
66
  frontmatter validator: 0 violations (40 files checked)
84
- next time these agents are spawned, session-runner will dispatch through the new peer.
67
+ Next time these agents are spawned, session-runner dispatches through the new peer.
85
68
 
86
- To verify: /gdd:peers (shows updated allowlist + capability matrix).
69
+ Verify: /gdd:peers (shows updated allowlist + capability matrix).
87
70
  ```
88
71
 
89
72
  ## Edge cases
90
73
 
91
- - **User asks to rewire to a peer not in the capability matrix** (e.g., a peer they want to add later): direct them to `skills/peer-cli-add/SKILL.md` first; do not allow the frontmatter edit until the peer exists in the matrix.
92
- - **User asks to rewire to a role the peer doesn't claim** (e.g., `codex-debug` — codex only claims `execute`): refuse with a helpful message listing what the peer DOES claim. Suggest a closer match if obvious.
93
- - **User asks to rewire ALL agents to a peer at once** (bulk operation): support but require explicit confirmation. Show the diff of all proposed edits before applying.
94
- - **Validator fails after edit**: revert the edit (re-run `Edit` with the inverse old/new strings). Surface the original error.
74
+ See `./reference/peer-cli-protocol.md` §"Edge cases" for: rewire-to-unmatrixed-peer (direct user to `peer-cli-add` first), rewire-to-unclaimed-role (refuse with helpful list), bulk-rewire (require explicit confirmation), validator-fails-post-edit (revert and surface).
95
75
 
96
76
  ## Cross-references
97
77
 
98
- - `scripts/validate-frontmatter.ts` (Plan 27-06) `delegate_to` field validation.
78
+ - `./reference/peer-cli-protocol.md` rewire discipline, three frontmatter cases, edge cases.
79
+ - `scripts/validate-frontmatter.ts` (Plan 27-06) — `delegate_to` validation.
99
80
  - `scripts/lib/peer-cli/registry.cjs` (Plan 27-05) — capability matrix.
100
- - `agents/README.md#peer-cli-delegation-delegate_to` — field documentation.
101
- - `skills/peer-cli-add/SKILL.md` — for adding a NEW peer (this skill is for rewiring among existing peers).
81
+ - `skills/peer-cli-add/SKILL.md` — for adding a NEW peer (this skill rewires among existing peers).
102
82
  - `.planning/phases/27-peer-cli-delegation/CONTEXT.md` D-06 — decision lineage.
103
83
 
104
84
  ## Record
@@ -9,24 +9,18 @@ tools: Read, Bash
9
9
 
10
10
  ## Role
11
11
 
12
- You are a deterministic discovery skill. You do not spawn agents and do not delegate to peers. You read `scripts/lib/install/runtimes.cjs`, `scripts/lib/peer-cli/registry.cjs`, `.design/config.json`, and (optionally) `.design/telemetry/posterior.json` (the canonical path declared by `scripts/lib/bandit-router.cjs`'s `DEFAULT_POSTERIOR_PATH`), then emit a single Markdown table summarizing peer-CLI status.
12
+ You are a deterministic discovery skill. You do not spawn agents and do not delegate to peers. You read `scripts/lib/install/runtimes.cjs`, `scripts/lib/peer-cli/registry.cjs`, `.design/config.json`, and (optionally) `.design/telemetry/posterior.json` (canonical path declared by `bandit-router.cjs`'s `DEFAULT_POSTERIOR_PATH`), then emit a single Markdown table summarizing peer-CLI status. Protocol-level handshake details live in `./reference/peer-cli-protocol.md`.
13
13
 
14
14
  ## Invocation Contract
15
15
 
16
16
  - **Input**: none. The skill takes no arguments.
17
- - **Output**: a Markdown capability-matrix table to stdout. No JSON wrapper. The table is the entire output.
17
+ - **Output**: a Markdown capability-matrix table to stdout. The table is the entire output.
18
18
 
19
19
  ## Procedure
20
20
 
21
- ### 1. Load runtime matrix
21
+ ### 1. Load runtime + capability matrix
22
22
 
23
- Read `scripts/lib/install/runtimes.cjs` and extract the 14 runtime entries. The 5 peer-capable entries (`codex`, `gemini`, `cursor`, `copilot`, `qwen`) carry a `peerBinary?` field (added in Plan 27-11). Collect their IDs and binary paths.
24
-
25
- ### 2. Load capability matrix
26
-
27
- Read `scripts/lib/peer-cli/registry.cjs`. The exported `describeCapabilities()` returns the per-peer claimed-roles map. The capability matrix is the source of truth for which roles each peer can take.
28
-
29
- Use the canonical declared matrix:
23
+ Read `scripts/lib/install/runtimes.cjs` (14 entries; 5 carry `peerBinary`) and `scripts/lib/peer-cli/registry.cjs#describeCapabilities()`. The canonical declared matrix:
30
24
 
31
25
  | Peer | Roles claimed | Protocol |
32
26
  |---------|--------------------------|----------|
@@ -36,41 +30,28 @@ Use the canonical declared matrix:
36
30
  | copilot | review, research | ACP |
37
31
  | qwen | write | ACP |
38
32
 
39
- ### 3. Detect installation
40
-
41
- For each peer, run `which <peerBinary>` (POSIX) or `where <peerBinary>` (Windows). If exit 0 → installed. If exit non-zero → not installed.
33
+ ### 2. Detect installation
42
34
 
43
- ### 4. Read allowlist
35
+ For each peer, run `which <peerBinary>` (POSIX) or `where <peerBinary>` (Windows). Exit 0 → installed; non-zero → not installed.
44
36
 
45
- Read `.design/config.json`. The path is `peer_cli.enabled_peers` — an array of peer-IDs. Default: `[]` (empty, opt-in required). If the file or path is missing, treat as empty.
37
+ ### 3. Read allowlist
46
38
 
47
- ### 5. (Optional) Read posterior reward-delta
39
+ Read `.design/config.json#peer_cli.enabled_peers` (array of peer-IDs). Default `[]` (opt-in required). Missing file or path = empty.
48
40
 
49
- Phase 27.5 (v1.27.5) wired the bandit posterior into production. Once 27.5-02 (budget-enforcer consultation) + 27.5-03 (session-runner outcome recording) have fired across enough spawns, the posterior at `.design/telemetry/posterior.json` (the canonical path declared by `bandit-router.cjs`'s `DEFAULT_POSTERIOR_PATH`) carries per-`(agent, bin, delegate, tier)` arms with measured reward.
41
+ ### 4. (Optional) Read posterior reward-delta
50
42
 
51
- For each peer-id in {gemini, codex, cursor, copilot, qwen}:
43
+ Once Phase 27.5 has fired across enough spawns, `.design/telemetry/posterior.json` carries per-`(agent, bin, delegate, tier)` arms with measured reward. For each peer-id:
52
44
 
53
- 1. Read `.design/telemetry/posterior.json`. If missing or malformed render "(no data yet)".
54
- 2. Filter the `arms` array into `peerArms` where `delegate === <peer-id>` and `localArms` where `delegate === 'none'` OR `delegate === undefined` (the Phase 23.5 legacy slice is treated as the local-call slice).
55
- 3. If `peerArms` is empty OR `localArms` is empty "(no data yet)".
56
- 4. Compute pooled posterior means:
57
- - `peerMean = sum(arm.alpha across peerArms) / (sum(arm.alpha across peerArms) + sum(arm.beta across peerArms))`
58
- - `localMean = sum(arm.alpha across localArms) / (sum(arm.alpha across localArms) + sum(arm.beta across localArms))`
59
- 5. Compute `delta_pct = (peerMean - localMean) / localMean`.
60
- 6. Require minimum sample evidence: `sum(arm.count)` for `peerArms` AND for `localArms` must each be `>= 3`. Else "(no data yet)".
61
- 7. Render delta as:
62
- - `+X% reward` when `delta_pct > 0.01`
63
- - `-X% reward` when `delta_pct < -0.01`
64
- - `~equal` when `abs(delta_pct) < 0.01`
65
- Where X = `Math.round(abs(delta_pct) * 100)`.
45
+ 1. Filter `arms` array: `peerArms` where `delegate === <peer-id>`; `localArms` where `delegate === 'none'` OR `delegate === undefined` (Phase 23.5 legacy slice treated as local-call).
46
+ 2. Require `peerArms` and `localArms` both non-empty. Else `(no data yet)`.
47
+ 3. Compute pooled means: `mean = sum(alpha) / (sum(alpha) + sum(beta))` over each slice.
48
+ 4. `delta_pct = (peerMean - localMean) / localMean`.
49
+ 5. Require `sum(arm.count)` 3 in each slice. Else `(no data yet)`.
50
+ 6. Render: `+X% reward` (delta > 0.01), `-X% reward` (delta < -0.01), or `~equal` (`abs(delta) < 0.01`), where `X = round(abs(delta_pct) * 100)`.
66
51
 
67
- The reward signal is the Phase 23.5 two-stage lexicographic (correctness first, cost as tiebreaker — see `scripts/lib/bandit-router.cjs` `computeReward()`). Cost-only deltas live in `scripts/lib/cost-arbitrage.cjs` (Phase 26-06) and are surfaced via the design-reflector.
52
+ Reward is the Phase 23.5 lexicographic (correctness first, cost tiebreaker — see `scripts/lib/bandit-router.cjs` `computeReward()`). Cost-only deltas live in `cost-arbitrage.cjs` (Phase 26-06).
68
53
 
69
- If the posterior file does not exist (e.g., fresh install with no spawns yet, or `adaptive_mode` is `static`/`hedge`), surface "(no data yet)" for every peer.
70
-
71
- ### 6. Render the table
72
-
73
- Emit the table in this exact shape:
54
+ ### 5. Render the table
74
55
 
75
56
  ```
76
57
  ## Peer-CLI Capability Matrix
@@ -85,36 +66,31 @@ Emit the table in this exact shape:
85
66
 
86
67
  > Tip: Enable peers via `.design/config.json#peer_cli.enabled_peers`.
87
68
  > See `reference/peer-cli-capabilities.md` for the full capability matrix.
88
- > See `skills/peer-cli-customize/SKILL.md` to rewire rolepeer mappings per agent.
69
+ > See `skills/peer-cli-customize/SKILL.md` to rewire role->peer mappings per agent.
89
70
  ```
90
71
 
91
- Rules for the third column ("Posterior delta vs local"):
92
- - If `Installed = ✗` → `(not installed)`.
93
- - Else if `Allowlisted = ✗` → `(opt-in disabled)`.
94
- - Else if `.design/telemetry/posterior.json` is missing → `(no data yet)`.
95
- - Else if either peer-side or local-side has fewer than 3 pulls → `(no data yet)`.
96
- - Else compute the reward-delta per Step 5 and render `+X% reward`, `-X% reward`, or `~equal`.
72
+ **Third-column rules** (top-down precedence):
73
+
74
+ - `Installed = ✗` → `(not installed)`.
75
+ - `Allowlisted = ✗` → `(opt-in disabled)`.
76
+ - Posterior missing → `(no data yet)`.
77
+ - < 3 pulls per side `(no data yet)`.
78
+ - Else compute the reward-delta per Step 4.
97
79
 
98
- ### 7. Done
80
+ ### 6. Done
99
81
 
100
- The table IS the output. No follow-up prose. Users can act on the data:
101
- - See "(opt-in disabled)" → enable in `.design/config.json`.
102
- - See "(not installed)" → install the peer CLI.
103
- - See concrete deltas → trust the bandit's recommendation, or override per-agent via `skills/peer-cli-customize`.
82
+ The table IS the output. No follow-up prose. Users act on it: `(opt-in disabled)` → enable in `.design/config.json`; `(not installed)` → install the peer CLI; concrete deltas → trust the bandit or override per-agent via `skills/peer-cli-customize`.
104
83
 
105
84
  ## Cross-references
106
85
 
107
- - `scripts/lib/peer-cli/registry.cjs` (Plan 27-05) capability matrix data source.
108
- - `scripts/lib/install/runtimes.cjs` (Plan 27-11) — `peerBinary` field per runtime.
109
- - `reference/peer-cli-capabilities.md` (Plan 27-05) full capability matrix doc.
110
- - `skills/peer-cli-customize/SKILL.md` (Plan 27-10) — rewire role→peer mappings.
111
- - `skills/peer-cli-add/SKILL.md` (Plan 27-10) — add a brand-new peer.
112
- - `.planning/phases/27-peer-cli-delegation/CONTEXT.md` D-10 — decision lineage.
86
+ - `./reference/peer-cli-protocol.md` ACP/ASP handshake + adapter scaffold (procedure ref shared with peer-cli-add/customize).
87
+ - `./reference/peer-cli-capabilities.md` (Plan 27-05) — full capability matrix doc.
88
+ - `scripts/lib/peer-cli/registry.cjs` (Plan 27-05), `scripts/lib/install/runtimes.cjs` (Plan 27-11), `skills/peer-cli-customize/SKILL.md`, `skills/peer-cli-add/SKILL.md`, `.planning/phases/27-peer-cli-delegation/CONTEXT.md` D-10.
113
89
 
114
90
  ## Record
115
91
 
116
- After execution, append one JSONL line to `.design/skill-records.jsonl`:
92
+ Append one JSONL line to `.design/skill-records.jsonl`:
117
93
 
118
94
  ```json
119
- {"skill": "gdd-peers", "ts": "<ISO timestamp>", "peers_detected": ["codex", "gemini"], "peers_allowlisted": ["codex"], "had_posterior": false}
95
+ {"skill": "gdd-peers", "ts": "<ISO timestamp>", "peers_detected": ["codex"], "peers_allowlisted": ["codex"], "had_posterior": false}
120
96
  ```