peaks-loop 3.1.2 → 4.0.0-beta.2

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 (344) hide show
  1. package/.claude-plugin/marketplace.json +62 -12
  2. package/CHANGELOG.md +148 -116
  3. package/README-en.md +58 -240
  4. package/README.md +49 -325
  5. package/agents/karpathy-reviewer.md +3 -3
  6. package/dist/src/cli/cli-helpers.d.ts +18 -0
  7. package/dist/src/cli/cli-helpers.js +8 -0
  8. package/dist/src/cli/commands/adapter-commands.d.ts +30 -0
  9. package/dist/src/cli/commands/adapter-commands.js +35 -0
  10. package/dist/src/cli/commands/{solo-commands.d.ts → code-commands.d.ts} +25 -25
  11. package/dist/src/cli/commands/{solo-commands.js → code-commands.js} +82 -82
  12. package/dist/src/cli/commands/context-commands.d.ts +1 -1
  13. package/dist/src/cli/commands/context-commands.js +1 -1
  14. package/dist/src/cli/commands/contract-commands.d.ts +1 -1
  15. package/dist/src/cli/commands/contract-commands.js +1 -1
  16. package/dist/src/cli/commands/core/session-command.js +12 -0
  17. package/dist/src/cli/commands/core/skill-command.js +4 -4
  18. package/dist/src/cli/commands/dispatch-commands.js +2 -2
  19. package/dist/src/cli/commands/dispatch-from-dag.js +1 -1
  20. package/dist/src/cli/commands/hook-handle.js +7 -7
  21. package/dist/src/cli/commands/job-commands.js +7 -7
  22. package/dist/src/cli/commands/observability-commands.js +1 -1
  23. package/dist/src/cli/commands/perf-audit-commands.js +2 -2
  24. package/dist/src/cli/commands/security-audit-commands.js +2 -2
  25. package/dist/src/cli/commands/sediment-commands.d.ts +80 -0
  26. package/dist/src/cli/commands/sediment-commands.js +640 -0
  27. package/dist/src/cli/commands/session-auto-compact-hook-command.js +2 -2
  28. package/dist/src/cli/commands/session-migrate-skill-name.d.ts +17 -0
  29. package/dist/src/cli/commands/session-migrate-skill-name.js +41 -0
  30. package/dist/src/cli/commands/skill-visibility.d.ts +8 -0
  31. package/dist/src/cli/commands/skill-visibility.js +63 -0
  32. package/dist/src/cli/commands/slice-commands.js +2 -2
  33. package/dist/src/cli/commands/sub-agent-commands.d.ts +1 -1
  34. package/dist/src/cli/commands/sub-agent-commands.js +1 -1
  35. package/dist/src/cli/commands/sub-agent-shared.d.ts +1 -1
  36. package/dist/src/cli/commands/understand-commands.js +1 -1
  37. package/dist/src/cli/commands/upgrade-commands.d.ts +1 -1
  38. package/dist/src/cli/commands/upgrade-commands.js +3 -3
  39. package/dist/src/cli/commands/user-touchpoint-commands.d.ts +4 -4
  40. package/dist/src/cli/commands/user-touchpoint-commands.js +15 -15
  41. package/dist/src/cli/commands/verdict-aggregate-command.d.ts +1 -1
  42. package/dist/src/cli/commands/verdict-aggregate-command.js +2 -2
  43. package/dist/src/cli/commands/workflow-commands.js +23 -23
  44. package/dist/src/cli/commands/workspace/init-command.d.ts +3 -3
  45. package/dist/src/cli/commands/workspace/init-command.js +7 -7
  46. package/dist/src/cli/program.js +24 -7
  47. package/dist/src/services/adapter/adapter.d.ts +27 -0
  48. package/dist/src/services/adapter/adapter.js +5 -0
  49. package/dist/src/services/adapter/auto-adapter.d.ts +11 -0
  50. package/dist/src/services/adapter/auto-adapter.js +15 -0
  51. package/dist/src/services/adapter/claude-adapter.d.ts +14 -0
  52. package/dist/src/services/adapter/claude-adapter.js +40 -0
  53. package/dist/src/services/adapter/codex-adapter.d.ts +14 -0
  54. package/dist/src/services/adapter/codex-adapter.js +14 -0
  55. package/dist/src/services/adapter/copilot-adapter.d.ts +14 -0
  56. package/dist/src/services/adapter/copilot-adapter.js +14 -0
  57. package/dist/src/services/artifacts/repair-cycle-service.js +1 -1
  58. package/dist/src/services/audit/enforcers/active-skill-resolver.d.ts +1 -1
  59. package/dist/src/services/audit/enforcers/active-skill-resolver.js +1 -1
  60. package/dist/src/services/audit/enforcers/{solo-code-ban.d.ts → code-ban.d.ts} +6 -6
  61. package/dist/src/services/audit/enforcers/{solo-code-ban.js → code-ban.js} +6 -6
  62. package/dist/src/services/audit/red-line-catalog.d.ts +2 -2
  63. package/dist/src/services/audit/red-line-catalog.js +6 -6
  64. package/dist/src/services/audit/scanners/skills-tree-scanner.js +22 -0
  65. package/dist/src/services/audit/types.d.ts +2 -2
  66. package/dist/src/services/{solo → code}/auto-compact-orchestrator.d.ts +2 -2
  67. package/dist/src/services/{solo → code}/auto-compact-orchestrator.js +5 -5
  68. package/dist/src/services/{solo → code}/dag-orchestrator.d.ts +4 -4
  69. package/dist/src/services/{solo → code}/dag-orchestrator.js +5 -5
  70. package/dist/src/services/{solo → code}/emit-handoff.d.ts +1 -1
  71. package/dist/src/services/{solo → code}/emit-handoff.js +1 -1
  72. package/dist/src/services/{solo → code}/job-shape-decision.d.ts +1 -1
  73. package/dist/src/services/{solo → code}/job-shape-decision.js +5 -5
  74. package/dist/src/services/{solo → code}/mode-gate.d.ts +11 -11
  75. package/dist/src/services/{solo → code}/mode-gate.js +5 -5
  76. package/dist/src/services/{solo → code}/post-compact-detector.d.ts +3 -3
  77. package/dist/src/services/{solo → code}/post-compact-detector.js +6 -6
  78. package/dist/src/services/{solo → code}/status-line-renderer.d.ts +4 -4
  79. package/dist/src/services/{solo → code}/step-08-gate.d.ts +4 -4
  80. package/dist/src/services/{solo → code}/step-08-gate.js +4 -4
  81. package/dist/src/services/{solo → code}/user-touchpoint-classifier.d.ts +1 -1
  82. package/dist/src/services/{solo → code}/user-touchpoint-classifier.js +1 -1
  83. package/dist/src/services/context/auto-compact-dispatcher.d.ts +3 -3
  84. package/dist/src/services/context/auto-compact-dispatcher.js +2 -2
  85. package/dist/src/services/context/auto-compact-types.d.ts +1 -1
  86. package/dist/src/services/dispatch/batch-counter.js +1 -1
  87. package/dist/src/services/dispatch/leak-detector.js +1 -1
  88. package/dist/src/services/dispatch/slice-dag.d.ts +2 -2
  89. package/dist/src/services/dispatch/test-tool-detection.d.ts +1 -1
  90. package/dist/src/services/dispatch/test-tool-detection.js +1 -1
  91. package/dist/src/services/doctor/doctor-service.js +2 -2
  92. package/dist/src/services/feedback/feedback-promotion-service.js +2 -2
  93. package/dist/src/services/job/job-progress-store.d.ts +1 -1
  94. package/dist/src/services/job/job-progress-store.js +1 -1
  95. package/dist/src/services/job/job-resource-snapshot.js +29 -1
  96. package/dist/src/services/memory/project-memory-service.js +1 -1
  97. package/dist/src/services/migrate-skill-name/migrate.d.ts +17 -0
  98. package/dist/src/services/migrate-skill-name/migrate.js +152 -0
  99. package/dist/src/services/migrate-skill-name/schema.d.ts +42 -0
  100. package/dist/src/services/migrate-skill-name/schema.js +25 -0
  101. package/dist/src/services/observability/aggregation.d.ts +1 -1
  102. package/dist/src/services/observability/aggregation.js +1 -1
  103. package/dist/src/services/perf/perf-baseline-service.d.ts +1 -1
  104. package/dist/src/services/perf/perf-baseline-service.js +1 -1
  105. package/dist/src/services/prd/handoff-types.d.ts +1 -1
  106. package/dist/src/services/prd/handoff-types.js +1 -1
  107. package/dist/src/services/preferences/preferences-service.d.ts +1 -1
  108. package/dist/src/services/preferences/preferences-types.d.ts +1 -1
  109. package/dist/src/services/progress/progress-service.d.ts +1 -1
  110. package/dist/src/services/progress/progress-service.js +1 -1
  111. package/dist/src/services/rd/standards-diagnostic.d.ts +1 -1
  112. package/dist/src/services/rd/standards-diagnostic.js +3 -3
  113. package/dist/src/services/recommendations/capability-seed-items.js +1 -1
  114. package/dist/src/services/recommendations/capability-seed-mappings.js +1 -1
  115. package/dist/src/services/recommendations/recommendation-service.js +1 -1
  116. package/dist/src/services/refactor/refactor-service.d.ts +1 -1
  117. package/dist/src/services/sc/sc-service.js +1 -1
  118. package/dist/src/services/sediment/dispose-confirm.d.ts +9 -0
  119. package/dist/src/services/sediment/dispose-confirm.js +5 -0
  120. package/dist/src/services/sediment/json-schema.d.ts +247 -0
  121. package/dist/src/services/sediment/json-schema.js +26 -0
  122. package/dist/src/services/sediment/manifest-lint.d.ts +13 -0
  123. package/dist/src/services/sediment/manifest-lint.js +11 -0
  124. package/dist/src/services/sediment/pool-paths.d.ts +22 -0
  125. package/dist/src/services/sediment/pool-paths.js +25 -0
  126. package/dist/src/services/sediment/pool-read.d.ts +20 -0
  127. package/dist/src/services/sediment/pool-read.js +73 -0
  128. package/dist/src/services/sediment/pool-rebuild-index.d.ts +15 -0
  129. package/dist/src/services/sediment/pool-rebuild-index.js +28 -0
  130. package/dist/src/services/sediment/pool-write.d.ts +14 -0
  131. package/dist/src/services/sediment/pool-write.js +25 -0
  132. package/dist/src/services/sediment/promotion-gate.d.ts +12 -0
  133. package/dist/src/services/sediment/promotion-gate.js +20 -0
  134. package/dist/src/services/sediment/types.d.ts +52 -0
  135. package/dist/src/services/sediment/types.js +1 -0
  136. package/dist/src/services/session/binding-store.d.ts +1 -1
  137. package/dist/src/services/session/binding-store.js +1 -1
  138. package/dist/src/services/session/caller-id-types.d.ts +1 -1
  139. package/dist/src/services/session/session-manager.d.ts +1 -1
  140. package/dist/src/services/session/session-manager.js +1 -1
  141. package/dist/src/services/signal/cancel-handler.js +3 -3
  142. package/dist/src/services/skill/resume-detector.js +2 -2
  143. package/dist/src/services/skill/skill-scheduler.d.ts +1 -1
  144. package/dist/src/services/skill/skill-scheduler.js +1 -1
  145. package/dist/src/services/skillhub/release-diff.d.ts +18 -0
  146. package/dist/src/services/skillhub/release-diff.js +38 -0
  147. package/dist/src/services/skillhub/release-export.d.ts +8 -0
  148. package/dist/src/services/skillhub/release-export.js +31 -0
  149. package/dist/src/services/skillhub/release-gc-blobs.d.ts +13 -0
  150. package/dist/src/services/skillhub/release-gc-blobs.js +32 -0
  151. package/dist/src/services/skillhub/release-import.d.ts +7 -0
  152. package/dist/src/services/skillhub/release-import.js +59 -0
  153. package/dist/src/services/skillhub/release-retain.d.ts +23 -0
  154. package/dist/src/services/skillhub/release-retain.js +89 -0
  155. package/dist/src/services/skillhub/sqlite-store.d.ts +22 -0
  156. package/dist/src/services/skillhub/sqlite-store.js +47 -0
  157. package/dist/src/services/skillhub/tar-runtime.d.ts +21 -0
  158. package/dist/src/services/skillhub/tar-runtime.js +91 -0
  159. package/dist/src/services/skillhub/types.d.ts +105 -0
  160. package/dist/src/services/skillhub/types.js +1 -0
  161. package/dist/src/services/skills/skill-conformance-service.js +8 -5
  162. package/dist/src/services/skills/skill-presence-service.d.ts +5 -5
  163. package/dist/src/services/skills/skill-presence-service.js +2 -2
  164. package/dist/src/services/skills/skill-registry.js +27 -0
  165. package/dist/src/services/skills/skill-runbook-service.js +2 -2
  166. package/dist/src/services/slice/slice-check-service.js +1 -1
  167. package/dist/src/services/slice/slice-check-types.d.ts +1 -1
  168. package/dist/src/services/slice/slice-check-types.js +1 -1
  169. package/dist/src/services/slice/slice-decompose-types.d.ts +1 -1
  170. package/dist/src/services/slice/slice-decompose-types.js +1 -1
  171. package/dist/src/services/standards/missing-standards-detector.d.ts +1 -1
  172. package/dist/src/services/standards/missing-standards-detector.js +1 -1
  173. package/dist/src/services/standards/project-standards-service.d.ts +1 -1
  174. package/dist/src/services/standards/project-standards-service.js +4 -4
  175. package/dist/src/services/understand/understand-types.d.ts +1 -1
  176. package/dist/src/services/upgrade/1x-detector-service.js +2 -2
  177. package/dist/src/services/upgrade/upgrade-service.d.ts +34 -0
  178. package/dist/src/services/upgrade/upgrade-service.js +52 -30
  179. package/dist/src/services/verdict/verdict-aggregator.d.ts +1 -1
  180. package/dist/src/services/workflow/pipeline-verify-service.d.ts +1 -1
  181. package/dist/src/services/workflow/pipeline-verify-service.js +3 -3
  182. package/dist/src/services/workflow/workflow-autonomous-service.d.ts +3 -3
  183. package/dist/src/services/workflow/workflow-autonomous-service.js +2 -2
  184. package/dist/src/services/workflow/workflow-router-service.d.ts +7 -7
  185. package/dist/src/services/workflow/workflow-router-service.js +33 -33
  186. package/dist/src/services/workspace/claude-settings-template.d.ts +2 -2
  187. package/dist/src/services/workspace/claude-settings-template.js +7 -7
  188. package/dist/src/services/workspace/workspace-claude-settings-materializer.d.ts +1 -1
  189. package/dist/src/services/workspace/workspace-claude-settings-materializer.js +1 -1
  190. package/dist/src/services/workspace/workspace-service.d.ts +4 -4
  191. package/dist/src/services/workspace/workspace-service.js +2 -2
  192. package/dist/src/shared/paths.d.ts +1 -1
  193. package/dist/src/shared/paths.js +1 -1
  194. package/dist/src/shared/version.d.ts +1 -1
  195. package/dist/src/shared/version.js +1 -1
  196. package/dist/src/skills/peaks-maker/index.d.ts +5 -0
  197. package/dist/src/skills/peaks-maker/index.js +32 -0
  198. package/output-styles/peaks-skill-swarm.md +3 -3
  199. package/package.json +8 -3
  200. package/scripts/install-skills.mjs +29 -4
  201. package/skills/{peaks-prd → bee/peaks-prd}/SKILL.md +8 -2
  202. package/skills/{peaks-prd → bee/peaks-prd}/references/workflow.md +1 -1
  203. package/skills/{peaks-qa → bee/peaks-qa}/SKILL.md +10 -4
  204. package/skills/{peaks-qa → bee/peaks-qa}/references/artifact-per-request.md +3 -3
  205. package/skills/{peaks-qa → bee/peaks-qa}/references/browser-validation-contracts.md +2 -2
  206. package/skills/{peaks-qa → bee/peaks-qa}/references/external-capability-guidance.md +1 -1
  207. package/skills/{peaks-qa → bee/peaks-qa}/references/qa-fanout-contract.md +3 -3
  208. package/skills/{peaks-qa → bee/peaks-qa}/references/qa-sub-agent-dispatch.md +7 -7
  209. package/skills/{peaks-rd → bee/peaks-rd}/SKILL.md +13 -6
  210. package/skills/{peaks-rd → bee/peaks-rd}/references/browser-self-test-contracts.md +1 -1
  211. package/skills/{peaks-rd → bee/peaks-rd}/references/mock-data-placement.md +1 -1
  212. package/skills/{peaks-rd → bee/peaks-rd}/references/parallel-review-fanout.md +1 -1
  213. package/skills/{peaks-rd → bee/peaks-rd}/references/rd-fanout-contracts.md +1 -1
  214. package/skills/{peaks-rd → bee/peaks-rd}/references/rd-runbook.md +2 -2
  215. package/skills/{peaks-rd → bee/peaks-rd}/references/rd-sub-agent-dispatch.md +13 -13
  216. package/skills/{peaks-rd → bee/peaks-rd}/references/rd-transition-gates.md +2 -2
  217. package/skills/{peaks-rd → bee/peaks-rd}/references/skill-presence-and-title.md +1 -1
  218. package/skills/{peaks-reviewer → bee/peaks-reviewer}/SKILL.md +2 -2
  219. package/skills/{peaks-sc → bee/peaks-sc}/SKILL.md +8 -2
  220. package/skills/{peaks-txt → bee/peaks-txt}/SKILL.md +11 -5
  221. package/skills/{peaks-ui → bee/peaks-ui}/SKILL.md +19 -13
  222. package/skills/peaks-audit/SKILL.md +1 -1
  223. package/skills/{peaks-solo → peaks-code}/SKILL.md +29 -29
  224. package/skills/{peaks-solo → peaks-code}/references/a2a-artifact-mapping.md +2 -2
  225. package/skills/{peaks-solo → peaks-code}/references/anchoring-and-session-info.md +6 -6
  226. package/skills/{peaks-solo → peaks-code}/references/artifact-contracts.md +3 -3
  227. package/skills/{peaks-solo → peaks-code}/references/boundaries.md +3 -3
  228. package/skills/{peaks-solo → peaks-code}/references/browser-workflow.md +1 -1
  229. package/skills/{peaks-solo → peaks-code}/references/codegraph-orchestration.md +1 -1
  230. package/skills/peaks-code/references/command-migration.md +3 -0
  231. package/skills/{peaks-solo → peaks-code}/references/completion-handoff.md +2 -2
  232. package/skills/{peaks-solo → peaks-code}/references/context-governance.md +2 -2
  233. package/skills/{peaks-solo → peaks-code}/references/dag-orchestrator.md +7 -7
  234. package/skills/{peaks-solo → peaks-code}/references/external-references.md +2 -2
  235. package/skills/{peaks-solo → peaks-code}/references/fanout-mandatory.md +3 -3
  236. package/skills/{peaks-solo → peaks-code}/references/fast-mode.md +2 -2
  237. package/skills/{peaks-solo → peaks-code}/references/frontend-only-mode.md +10 -10
  238. package/skills/{peaks-solo → peaks-code}/references/job-loop.md +1 -1
  239. package/skills/{peaks-solo → peaks-code}/references/local-artifact-workspace.md +3 -3
  240. package/skills/{peaks-solo → peaks-code}/references/micro-cycle.md +23 -23
  241. package/skills/{peaks-solo → peaks-code}/references/mode-selection-with-stale-presence.md +16 -16
  242. package/skills/{peaks-solo → peaks-code}/references/mode-selection.md +4 -4
  243. package/skills/{peaks-solo → peaks-code}/references/openspec-workflow.md +17 -17
  244. package/skills/{peaks-solo → peaks-code}/references/periodic-checkpoint.md +4 -4
  245. package/skills/{peaks-solo → peaks-code}/references/project-scan-checklist.md +1 -1
  246. package/skills/{peaks-solo → peaks-code}/references/quality-gate-cheatsheet.md +1 -1
  247. package/skills/{peaks-solo → peaks-code}/references/refactor-mode.md +2 -2
  248. package/skills/{peaks-solo → peaks-code}/references/resume-detection.md +1 -1
  249. package/skills/{peaks-solo → peaks-code}/references/runbook.md +20 -20
  250. package/skills/{peaks-solo → peaks-code}/references/skill-presence-and-title.md +3 -3
  251. package/skills/{peaks-solo → peaks-code}/references/standards-preflight.md +1 -1
  252. package/skills/{peaks-solo → peaks-code}/references/step-0-55-1x-detection.md +6 -6
  253. package/skills/{peaks-solo → peaks-code}/references/step-0-8-gate.md +11 -11
  254. package/skills/{peaks-solo → peaks-code}/references/sub-agent-dispatch.md +17 -17
  255. package/skills/{peaks-solo → peaks-code}/references/swarm-dispatch-contract.md +22 -22
  256. package/skills/{peaks-solo → peaks-code}/references/workflow-gates-and-types.md +4 -4
  257. package/skills/{peaks-solo → peaks-code}/references/workflow.md +5 -5
  258. package/skills/peaks-doctor/SKILL.md +1 -1
  259. package/skills/peaks-doctor/references/doctor-check-catalog.md +1 -1
  260. package/skills/peaks-final-review/SKILL.md +3 -3
  261. package/skills/peaks-final-review/references/4-dimensions.md +1 -1
  262. package/skills/peaks-ide/SKILL.md +1 -1
  263. package/skills/{peaks-solo-resume → peaks-resume}/SKILL.md +15 -15
  264. package/skills/peaks-sop/SKILL.md +1 -1
  265. package/skills/{peaks-solo-status → peaks-status}/SKILL.md +14 -14
  266. package/skills/{peaks-solo-test → peaks-test}/SKILL.md +12 -12
  267. package/skills/peaks-solo/references/command-migration.md +0 -3
  268. /package/dist/src/services/{solo → code}/batch-heartbeat-poller.d.ts +0 -0
  269. /package/dist/src/services/{solo → code}/batch-heartbeat-poller.js +0 -0
  270. /package/dist/src/services/{solo → code}/status-line-renderer.js +0 -0
  271. /package/skills/{peaks-perf-audit → bee/peaks-perf-audit}/SKILL.md +0 -0
  272. /package/skills/{peaks-perf-audit → bee/peaks-perf-audit}/references/audit-protocol.md +0 -0
  273. /package/skills/{peaks-prd → bee/peaks-prd}/references/artifact-contracts.md +0 -0
  274. /package/skills/{peaks-prd → bee/peaks-prd}/references/artifact-per-request.md +0 -0
  275. /package/skills/{peaks-prd → bee/peaks-prd}/references/command-migration.md +0 -0
  276. /package/skills/{peaks-prd → bee/peaks-prd}/references/prd-for-multi-pass.md +0 -0
  277. /package/skills/{peaks-qa → bee/peaks-qa}/references/artifact-contracts.md +0 -0
  278. /package/skills/{peaks-qa → bee/peaks-qa}/references/codegraph-regression-focus.md +0 -0
  279. /package/skills/{peaks-qa → bee/peaks-qa}/references/command-migration.md +0 -0
  280. /package/skills/{peaks-qa → bee/peaks-qa}/references/openspec-validation-gate.md +0 -0
  281. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-compact-handoff.md +0 -0
  282. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-context-governance.md +0 -0
  283. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-gstack-integration.md +0 -0
  284. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-local-artifacts.md +0 -0
  285. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-matt-pocock-integration.md +0 -0
  286. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-perf-test-plan.md +0 -0
  287. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-refactor-role.md +0 -0
  288. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-runbook.md +0 -0
  289. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-security-test-plan.md +0 -0
  290. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-skill-presence.md +0 -0
  291. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-standards-preflight.md +0 -0
  292. /package/skills/{peaks-qa → bee/peaks-qa}/references/qa-transition-gates.md +0 -0
  293. /package/skills/{peaks-qa → bee/peaks-qa}/references/reading-handoff-frontmatter.md +0 -0
  294. /package/skills/{peaks-qa → bee/peaks-qa}/references/regression-gates.md +0 -0
  295. /package/skills/{peaks-qa → bee/peaks-qa}/references/requirement-boundary-recheck.md +0 -0
  296. /package/skills/{peaks-qa → bee/peaks-qa}/references/test-case-generation.md +0 -0
  297. /package/skills/{peaks-qa → bee/peaks-qa}/references/test-report-output.md +0 -0
  298. /package/skills/{peaks-rd → bee/peaks-rd}/references/artifact-and-standards-output.md +0 -0
  299. /package/skills/{peaks-rd → bee/peaks-rd}/references/artifact-contracts.md +0 -0
  300. /package/skills/{peaks-rd → bee/peaks-rd}/references/artifact-per-request.md +0 -0
  301. /package/skills/{peaks-rd → bee/peaks-rd}/references/browser-action-wrapper.md +0 -0
  302. /package/skills/{peaks-rd → bee/peaks-rd}/references/code-reviewer-4dim-hint.md +0 -0
  303. /package/skills/{peaks-rd → bee/peaks-rd}/references/codegraph-project-analysis.md +0 -0
  304. /package/skills/{peaks-rd → bee/peaks-rd}/references/command-migration.md +0 -0
  305. /package/skills/{peaks-rd → bee/peaks-rd}/references/compact-handoff.md +0 -0
  306. /package/skills/{peaks-rd → bee/peaks-rd}/references/external-references.md +0 -0
  307. /package/skills/{peaks-rd → bee/peaks-rd}/references/frontend-project-generation.md +0 -0
  308. /package/skills/{peaks-rd → bee/peaks-rd}/references/karpathy-reviewer-prompt.md +0 -0
  309. /package/skills/{peaks-rd → bee/peaks-rd}/references/library-version-awareness.md +0 -0
  310. /package/skills/{peaks-rd → bee/peaks-rd}/references/mandatory-perf-baseline.md +0 -0
  311. /package/skills/{peaks-rd → bee/peaks-rd}/references/matt-pocock-integration.md +0 -0
  312. /package/skills/{peaks-rd → bee/peaks-rd}/references/ocr-integration.md +0 -0
  313. /package/skills/{peaks-rd → bee/peaks-rd}/references/openspec-cli.md +0 -0
  314. /package/skills/{peaks-rd → bee/peaks-rd}/references/rd-context-governance.md +0 -0
  315. /package/skills/{peaks-rd → bee/peaks-rd}/references/rd-gstack-integration.md +0 -0
  316. /package/skills/{peaks-rd → bee/peaks-rd}/references/rd-standards-preflight.md +0 -0
  317. /package/skills/{peaks-rd → bee/peaks-rd}/references/reading-v2-slice-results.md +0 -0
  318. /package/skills/{peaks-rd → bee/peaks-rd}/references/refactor-workflow.md +0 -0
  319. /package/skills/{peaks-rd → bee/peaks-rd}/references/v2-12-fanout-collapse.md +0 -0
  320. /package/skills/{peaks-rd → bee/peaks-rd}/references/writing-handoff-frontmatter.md +0 -0
  321. /package/skills/{peaks-reviewer → bee/peaks-reviewer}/references/reviewer-prompt.md +0 -0
  322. /package/skills/{peaks-reviewer → bee/peaks-reviewer}/references/reviewer-schema.md +0 -0
  323. /package/skills/{peaks-sc → bee/peaks-sc}/references/artifact-contracts.md +0 -0
  324. /package/skills/{peaks-sc → bee/peaks-sc}/references/artifact-retention.md +0 -0
  325. /package/skills/{peaks-sc → bee/peaks-sc}/references/command-migration.md +0 -0
  326. /package/skills/{peaks-sc → bee/peaks-sc}/references/openspec-commit-boundaries.md +0 -0
  327. /package/skills/{peaks-security-audit → bee/peaks-security-audit}/SKILL.md +0 -0
  328. /package/skills/{peaks-security-audit → bee/peaks-security-audit}/references/audit-protocol.md +0 -0
  329. /package/skills/{peaks-txt → bee/peaks-txt}/references/artifact-contracts.md +0 -0
  330. /package/skills/{peaks-txt → bee/peaks-txt}/references/command-migration.md +0 -0
  331. /package/skills/{peaks-txt → bee/peaks-txt}/references/context-capsule.md +0 -0
  332. /package/skills/{peaks-ui → bee/peaks-ui}/references/artifact-contracts.md +0 -0
  333. /package/skills/{peaks-ui → bee/peaks-ui}/references/artifact-per-request.md +0 -0
  334. /package/skills/{peaks-ui → bee/peaks-ui}/references/command-migration.md +0 -0
  335. /package/skills/{peaks-ui → bee/peaks-ui}/references/workflow.md +0 -0
  336. /package/skills/{peaks-solo → peaks-code}/references/checkpoint-resume.md +0 -0
  337. /package/skills/{peaks-solo → peaks-code}/references/cross-date-session-check.md +0 -0
  338. /package/skills/{peaks-solo → peaks-code}/references/envelope-contract.md +0 -0
  339. /package/skills/{peaks-solo → peaks-code}/references/existing-system-extraction.md +0 -0
  340. /package/skills/{peaks-solo → peaks-code}/references/external-skill-invocation.md +0 -0
  341. /package/skills/{peaks-solo → peaks-code}/references/gstack-integration.md +0 -0
  342. /package/skills/{peaks-solo → peaks-code}/references/headroom-integration.md +0 -0
  343. /package/skills/{peaks-solo → peaks-code}/references/playwright-mcp-multi-terminal.md +0 -0
  344. /package/skills/{peaks-solo → peaks-code}/references/project-memory-loading.md +0 -0
@@ -0,0 +1,5 @@
1
+ export declare const peaksMakerManifest: {
2
+ name: string;
3
+ description: string;
4
+ body: string;
5
+ };
@@ -0,0 +1,32 @@
1
+ // src/skills/peaks-maker/index.ts
2
+ import { readFileSync } from "node:fs";
3
+ import { fileURLToPath } from "node:url";
4
+ import { dirname, join } from "node:path";
5
+ function parseFrontmatter(md) {
6
+ const m = md.match(/^---\n([\s\S]+?)\n---\n([\s\S]*)$/);
7
+ if (!m)
8
+ throw new Error("peaks-maker SKILL.md is missing YAML frontmatter");
9
+ const fm = {};
10
+ for (const line of m[1].split("\n")) {
11
+ const i = line.indexOf(":");
12
+ if (i > 0)
13
+ fm[line.slice(0, i).trim()] = line.slice(i + 1).trim();
14
+ }
15
+ // The non-null assertions below were unsafe: if `name:` or `description:`
16
+ // was absent from the frontmatter, `fm[name]` would be `undefined`, which
17
+ // violates the declared return type and silently leaks a malformed
18
+ // manifest to every consumer of `peaksMakerManifest`. Validate explicitly
19
+ // so a missing/empty key surfaces as a clear error at module-load time.
20
+ const name = fm.name;
21
+ const description = fm.description;
22
+ if (typeof name !== "string" || name.length === 0) {
23
+ throw new Error("peaks-maker SKILL.md is missing name or description in frontmatter");
24
+ }
25
+ if (typeof description !== "string" || description.length === 0) {
26
+ throw new Error("peaks-maker SKILL.md is missing name or description in frontmatter");
27
+ }
28
+ return { name, description, body: m[2] };
29
+ }
30
+ const here = dirname(fileURLToPath(import.meta.url));
31
+ const md = readFileSync(join(here, "SKILL.md"), "utf-8");
32
+ export const peaksMakerManifest = parseFrontmatter(md);
@@ -4,7 +4,7 @@ description: Peaks 专用输出风格:仅在 peaks skills 工作流中用东
4
4
  keep-coding-instructions: true
5
5
  ---
6
6
 
7
- This output style is self-gated. Apply the sections below only when the current task explicitly invokes or continues a Peaks-Loop skill workflow, including `/peaks-*`, `skills/peaks-*`, Peaks-Loop PRD/RD/QA/UI/SC/TXT/Solo work, or edits to this repository's `skills/` directory. For unrelated tasks, preserve the default Claude Code behavior and keep responses concise.
7
+ This output style is self-gated. Apply the sections below only when the current task explicitly invokes or continues a Peaks-Loop skill workflow, including `/peaks-*`, `skills/peaks-*`, Peaks-Loop PRD/RD/QA/UI/SC/TXT/Code work, or edits to this repository's `skills/` directory. For unrelated tasks, preserve the default Claude Code behavior and keep responses concise.
8
8
 
9
9
  ## Peaks-Loop response contract
10
10
 
@@ -14,7 +14,7 @@ When active, make the skill transition visually obvious with a light Northeaster
14
14
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
15
15
  Peaks-Loop Skill Active: <skill-name> — 整活开工,但不整虚的
16
16
  Peaks-Loop Role Chain: <PRD → RD → QA → SC, or single role>
17
- Peaks-Loop Mode: <Solo | Assisted | Swarm | Strict | Economy>
17
+ Peaks-Loop Mode: <Code | Assisted | Swarm | Strict | Economy>
18
18
  Peaks-Loop Current Gate: <confirmation | dry-run | coverage | QA | commit boundary | handoff>
19
19
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
20
20
  ```
@@ -54,7 +54,7 @@ Peaks-Loop Skill: <skill-name> | Peaks-Loop Gate: <current gate> | Next: <one sh
54
54
  Structure active Peaks-Loop responses around:
55
55
 
56
56
  1. **Peaks-Loop Role** — name the active Peaks-Loop role or role chain, for example PRD → RD → QA → SC.
57
- 2. **Peaks-Loop Mode** — state whether the workflow is Solo, Assisted, Swarm, Strict, or Economy.
57
+ 2. **Peaks-Loop Mode** — state whether the workflow is Code, Assisted, Swarm, Strict, or Economy.
58
58
  3. **Peaks-Loop Current Gate** — show the current required gate: product confirmation, RD dry-run, coverage, QA acceptance, commit boundary, or handoff.
59
59
  4. **Action** — describe the immediate next action in one short sentence before tool use.
60
60
  5. **Peaks-Loop Evidence** — end with only the evidence that matters: commands, artifacts, changed files, blockers, and next action.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "peaks-loop",
3
- "version": "3.1.2",
3
+ "version": "4.0.0-beta.2",
4
4
  "description": "Loop Engineering CLI — workflow primitive / loop guards / evaluators / slice orchestration",
5
5
  "author": "SquabbyZ",
6
6
  "license": "MIT",
@@ -63,16 +63,20 @@
63
63
  "typecheck": "tsc -p tsconfig.json --noEmit && vitest run --coverage --coverage.include='src/services/workflow/plan-*.ts' tests/unit/services/workflow/",
64
64
  "mut:run": "peaks mut run --project . --out mut-report.json",
65
65
  "mut:scan": "peaks mut asserts --in mut-report.json",
66
- "audit:prose-ratio": "peaks audit prose-ratio --project ."
66
+ "audit:prose-ratio": "peaks audit prose-ratio --project .",
67
+ "dogfood:sediment": "bash scripts/dogfood-sediment-cycle.sh"
67
68
  },
68
69
  "engines": {
69
70
  "node": ">=20.0.0"
70
71
  },
71
72
  "pnpm": {
72
- "onlyBuiltDependencies": []
73
+ "onlyBuiltDependencies": [
74
+ "better-sqlite3"
75
+ ]
73
76
  },
74
77
  "dependencies": {
75
78
  "@colbymchenry/codegraph": "0.7.10",
79
+ "better-sqlite3": "^12.11.1",
76
80
  "commander": "^12.1.0",
77
81
  "fzf": "^0.5.2",
78
82
  "headroom-ai": "0.22.4",
@@ -92,6 +96,7 @@
92
96
  "@stryker-mutator/core": "^8.7.1",
93
97
  "@stryker-mutator/typescript-checker": "^8.7.1",
94
98
  "@stryker-mutator/vitest-runner": "^8.7.1",
99
+ "@types/better-sqlite3": "^7.6.13",
95
100
  "@types/node": "^22.10.2",
96
101
  "@vitest/coverage-v8": "^2.1.8",
97
102
  "tsx": "^4.19.2",
@@ -600,14 +600,39 @@ export function installBundledSkills(options = {}) {
600
600
  mkdirSync(targetRoot, { recursive: true });
601
601
  const validateSkillsRoot = createInstallRootValidator(targetRoot, 'Peaks skills');
602
602
 
603
+ // After the v2.13.0 bee-demote (commit de0872b), the role skills
604
+ // (peaks-prd, peaks-rd, peaks-qa, peaks-ui, peaks-sc, peaks-txt)
605
+ // moved under `skills/bee/<role>/` while user-facing helpers stayed
606
+ // at `skills/<name>/`. Build the install candidate list by walking
607
+ // top-level entries (user-facing helpers) AND `skills/bee/<role>`
608
+ // (demoted role skills). Each candidate is installed under its
609
+ // basename so the postinstall links `~/.claude/skills/peaks-rd`
610
+ // to `skills/bee/peaks-rd` (rather than `skills/bee`).
611
+ const beeRoot = join(skillsRoot, 'bee');
612
+ /** @type {Array<{ skillName: string, sourcePath: string }>} */
613
+ const candidates = [];
603
614
  for (const skillName of readdirSync(skillsRoot)) {
615
+ if (skillName === 'bee') continue;
604
616
  const sourcePath = join(skillsRoot, skillName);
605
617
  const skillFile = join(sourcePath, 'SKILL.md');
606
- const targetPath = join(targetRoot, skillName);
607
-
608
- if (!lstatSync(sourcePath).isDirectory() || !existsSync(skillFile)) {
609
- continue;
618
+ if (!lstatSync(sourcePath).isDirectory() || !existsSync(skillFile)) continue;
619
+ candidates.push({ skillName, sourcePath });
620
+ }
621
+ if (existsSync(beeRoot) && lstatSync(beeRoot).isDirectory()) {
622
+ for (const skillName of readdirSync(beeRoot)) {
623
+ const sourcePath = join(beeRoot, skillName);
624
+ const skillFile = join(sourcePath, 'SKILL.md');
625
+ if (!lstatSync(sourcePath).isDirectory() || !existsSync(skillFile)) continue;
626
+ // De-dupe: a top-level helper with the same name wins (preserves
627
+ // the existing install contract for any helper that shares a name
628
+ // with a demoted role skill, e.g. legacy overlap).
629
+ if (candidates.some((c) => c.skillName === skillName)) continue;
630
+ candidates.push({ skillName, sourcePath });
610
631
  }
632
+ }
633
+
634
+ for (const { skillName, sourcePath } of candidates) {
635
+ const targetPath = join(targetRoot, skillName);
611
636
 
612
637
  const current = getPathStats(targetPath);
613
638
  if (current) {
@@ -1,6 +1,12 @@
1
1
  ---
2
2
  name: peaks-prd
3
- description: Product and requirement skill for Peaks. Use when a workflow needs PRD, refactor goals, non-goals, behavior preservation, acceptance criteria, product change proposals, or user-confirmable product artifacts.
3
+ description: |
4
+ Product and requirement role for Peaks-Loop (LLM-only internal role; not user-invocable.
5
+ Triggered by peaks-code via `peaks sub-agent dispatch --role prd`.)
6
+ Use when a workflow needs PRD, refactor goals, non-goals, behavior preservation,
7
+ acceptance criteria, product change proposals, or user-confirmable product artifacts.
8
+ visibility: internal
9
+ ---
4
10
  ---
5
11
 
6
12
  # Peaks-Loop PRD
@@ -223,7 +229,7 @@ Use gstack as a concrete workflow reference for the product-facing parts of `Thi
223
229
 
224
230
  ## Authenticated product document workflow
225
231
 
226
- When the source PRD is an authenticated web document such as Feishu/Lark, use the Playwright MCP headed-browser surface rather than unauthenticated fetch tools. Chrome DevTools MCP is a secondary surface that only connects to an already-running Chrome (`--remote-debugging-port=9222`); it does not launch a browser on its own. The canonical browser workflow lives in `peaks-solo/references/browser-workflow.md`; the rules below are the PRD-specific application.
232
+ When the source PRD is an authenticated web document such as Feishu/Lark, use the Playwright MCP headed-browser surface rather than unauthenticated fetch tools. Chrome DevTools MCP is a secondary surface that only connects to an already-running Chrome (`--remote-debugging-port=9222`); it does not launch a browser on its own. The canonical browser workflow lives in `peaks-code/references/browser-workflow.md`; the rules below are the PRD-specific application.
227
233
 
228
234
  1. Confirm Playwright MCP is installed: check the LLM tool list for any Playwright MCP entry in the LLM tool list. If absent, the user installs via `claude mcp add playwright -- npx @playwright/mcp@latest` (Claude Code) or the IDE-native install command. Do not hand-edit `.claude/settings.json`.
229
235
  2. Before navigation, verify the user-provided document URL uses `https:` and belongs to an approved Feishu/Lark tenant domain such as `*.feishu.cn`, `*.larksuite.com`, `*.larksuite.com.cn`, or a project-configured tenant. Reject `file:`, `data:`, `javascript:`, `http:`, localhost, loopback, link-local, private IP, and raw IP hosts unless the user explicitly approves a controlled local test target.
@@ -15,7 +15,7 @@ When the product source is an authenticated Feishu/Lark/wiki document:
15
15
  7. Do not persist login URLs, redirect URLs, cookies, request or response headers, session tokens, tokens, storage state, QR payloads, raw browser state, raw network logs, browser traces, or screenshots/logs containing PII or SSO/MFA material into artifacts; redact sensitive evidence before writing `.peaks` outputs.
16
16
  8. If access remains blocked, record only a redacted document identifier, a sanitized state category such as `login-required`, `mfa-required`, or `access-denied`, and the exact user action needed.
17
17
 
18
- Canonical browser workflow: `../../peaks-solo/references/browser-workflow.md`.
18
+ Canonical browser workflow: `../../peaks-code/references/browser-workflow.md`.
19
19
 
20
20
  ## Implementation-oriented analysis
21
21
 
@@ -1,6 +1,12 @@
1
1
  ---
2
2
  name: peaks-qa
3
- description: QA and verification skill for Peaks. Use when a workflow needs unit-test coverage evidence, regression matrices, baseline reports, validation reports, acceptance checks, or refactor verification gates.
3
+ description: |
4
+ QA and verification role for Peaks-Loop (LLM-only internal role; not user-invocable.
5
+ Triggered by peaks-code via `peaks sub-agent dispatch --role qa`.)
6
+ Use when a workflow needs unit-test coverage evidence, regression matrices,
7
+ baseline reports, validation reports, acceptance checks, or refactor verification gates.
8
+ visibility: internal
9
+ ---
4
10
  ---
5
11
 
6
12
  ## Single-scope-axis naming convention
@@ -48,9 +54,9 @@ These two contracts are non-negotiable. The previous prose-only phrasing let the
48
54
 
49
55
  The canonical scope dir for this request is provided as `envelope.data.scopeDir` (absolute path). Write all session-id-scoped files under that path. **NEVER** construct paths like `.peaks/_runtime/<scope>/...` from frontmatter (where `<scope>` is a date-stamped session id, NOT a peaks-loop change-id — the change-id axis was removed in slice `2026-06-29-change-id-root-removal`). The path has already been resolved by the CLI.
50
56
 
51
- ## Sub-agent dispatch (when launched by peaks-solo swarm)
57
+ ## Sub-agent dispatch (when launched by peaks-code swarm)
52
58
 
53
- When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-solo`, the following sections of THIS skill are **suspended** for the sub-agent run: Session id, Skill presence, Workspace initialization, Mode selection, Statusline install. The sub-agent must NOT call `peaks request init` (Solo already initialised the slot), and must write `.peaks/_runtime/<sessionId>/qa/test-cases/<rid>.md` with test cases that link to PRD acceptance items. Return only a compact JSON envelope.
59
+ When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-code`, the following sections of THIS skill are **suspended** for the sub-agent run: Session id, Skill presence, Workspace initialization, Mode selection, Statusline install. The sub-agent must NOT call `peaks request init` (Code already initialised the slot), and must write `.peaks/_runtime/<sessionId>/qa/test-cases/<rid>.md` with test cases that link to PRD acceptance items. Return only a compact JSON envelope.
54
60
 
55
61
  > **v2.15.0+ 校准:** 每个 slice 完成,user 必介入做**业务审阅**(4-5 项业务/产品清单:业务流程 / 需求覆盖 / 边界 case / UI 装配 / 能合入下版吗),**不是技术审阅**。业务审过 → 进 final;业务不通过 → 返工。详见 `.peaks/memory/peaks-loop-slice-review-and-qa-perspective.md`。
56
62
 
@@ -202,7 +208,7 @@ Do not own product scope or implementation. Do not modify runtime configuration.
202
208
 
203
209
  ## Sub-agent context governance (G7 + G7.7 + G8 + G9 — slice #010)
204
210
 
205
- QA sub-agents (qa / qa-business / qa-perf / qa-security) follow the same G7 metadata-only + G8.6 share protocol as RD. Detailed: `skills/peaks-solo/references/context-governance.md`.
211
+ QA sub-agents (qa / qa-business / qa-perf / qa-security) follow the same G7 metadata-only + G8.6 share protocol as RD. Detailed: `skills/peaks-code/references/context-governance.md`.
206
212
 
207
213
  → see `references/qa-context-governance.md` for the full G7 / G8.6 / G9 protocol + QA sub-agent prompt template.
208
214
 
@@ -9,12 +9,12 @@ The three files for any QA invocation land under the active session's `qa/` work
9
9
  | # | File | Path | Reader | Content |
10
10
  |---|------|------|--------|---------|
11
11
  | 1 | Test cases | `.peaks/_runtime/<session-id>/qa/test-cases/<request-id>.md` | RD (before impl), QA | Generated test scenarios with status |
12
- | 2 | Test report | `.peaks/_runtime/<session-id>/qa/test-reports/<request-id>.md` | QA, SC, Solo | Summary, coverage%, security, perf, risks |
13
- | 3 | Request artifact | `.peaks/_runtime/<session-id>/qa/requests/<request-id>.md` | Solo, RD↔QA loop | Verdict, boundary check, links to #1 and #2 |
12
+ | 2 | Test report | `.peaks/_runtime/<session-id>/qa/test-reports/<request-id>.md` | QA, SC, Code | Summary, coverage%, security, perf, risks |
13
+ | 3 | Request artifact | `.peaks/_runtime/<session-id>/qa/requests/<request-id>.md` | Code, RD↔QA loop | Verdict, boundary check, links to #1 and #2 |
14
14
 
15
15
  ## Required content
16
16
 
17
- The request artifact is the **verdict carrier** — it must include: QA verdict (`pass` / `return-to-rd` / `blocked`), the red-line audit outcome, links to the test-cases and test-report, the boundary check (acceptance items covered, gaps), and any cross-skill handoff notes for Solo. The test cases file enumerates every scenario with status; the test report summarises execution and links the security / performance / regression companion files.
17
+ The request artifact is the **verdict carrier** — it must include: QA verdict (`pass` / `return-to-rd` / `blocked`), the red-line audit outcome, links to the test-cases and test-report, the boundary check (acceptance items covered, gaps), and any cross-skill handoff notes for Code. The test cases file enumerates every scenario with status; the test report summarises execution and links the security / performance / regression companion files.
18
18
 
19
19
  ## Rules
20
20
 
@@ -39,9 +39,9 @@ AskUserQuestion({
39
39
  { label: "I am logged in / I'll log in now",
40
40
  description: "Pause QA. The visible browser is already open; the user completes login in-place, then types 'logged in' or equivalent. QA then resumes browser_navigate + browser_snapshot from the post-login page." },
41
41
  { label: "Skip browser validation for this slice",
42
- description: "Mark the affected acceptance items as unverified in the test report. Do NOT issue a pass verdict. The slice stays in qa-running with the browser gate marked blocked, reason=login-required. peaks-solo's repair loop will surface this on the next cycle." },
42
+ description: "Mark the affected acceptance items as unverified in the test report. Do NOT issue a pass verdict. The slice stays in qa-running with the browser gate marked blocked, reason=login-required. peaks-code's repair loop will surface this on the next cycle." },
43
43
  { label: "Cancel the workflow",
44
- description: "Stop QA immediately. Emit a blocked TXT handoff so peaks-solo can surface the auth wall to the user. Do not mark any acceptance items as accepted." }
44
+ description: "Stop QA immediately. Emit a blocked TXT handoff so peaks-code can surface the auth wall to the user. Do not mark any acceptance items as accepted." }
45
45
  ]
46
46
  })
47
47
  ```
@@ -5,5 +5,5 @@
5
5
  - Playwright MCP is the required path for controlled headed browser and E2E validation (it launches a headed browser on demand). The LLM runtime exposes the Playwright tools under its own server-and-tool namespace (the Playwright MCP); QA invokes them by name from the LLM's tool list. (peaks-loop no longer auto-installs MCPs as of slice #016; the user runs `claude mcp add playwright -- npx @playwright/mcp@latest` themselves when the tool list is empty.)
6
6
  - Chrome DevTools MCP is an optional secondary surface for CDP inspection (console, network, performance) of an already-running Chrome started with `--remote-debugging-port=9222`; it does NOT launch a browser on its own. The LLM invokes Chrome DevTools MCP tools directly when present in the tool list.
7
7
  - Agent Browser can support browser walkthroughs, but never submit forms, purchase, delete, or mutate authenticated state without explicit confirmation.
8
- - Canonical browser workflow (URL allow-list, login handoff, sanitization rules, tool mapping): `peaks-solo/references/browser-workflow.md`.
8
+ - Canonical browser workflow (URL allow-list, login handoff, sanitization rules, tool mapping): `peaks-code/references/browser-workflow.md`.
9
9
  - If Playwright MCP is not installed and the user does not authorize installation, mark frontend browser validation blocked; screenshots, logs, manual steps, or other tools must not substitute for the mandatory headed browser gate.
@@ -142,9 +142,9 @@ envelope and into the slice's `reducerReport`.
142
142
 
143
143
  ## Cross-reference
144
144
 
145
- - `skills/peaks-solo/references/sub-agent-dispatch.md` — orchestrator
145
+ - `skills/peaks-code/references/sub-agent-dispatch.md` — orchestrator
146
146
  contract for all Dispatchers
147
- - `skills/peaks-solo/SKILL.md` "Peaks-Loop Swarm parallel phase" — sibling
147
+ - `skills/peaks-code/SKILL.md` "Peaks-Loop Swarm parallel phase" — sibling
148
148
  fan-out pattern
149
149
  - `.peaks/memory/sub-agent-resource-lifecycle-red-line.md` — G5 red line
150
150
  - `.peaks/memory/sub-agent-heartbeat-progress-red-line.md` — G6 red line
@@ -155,4 +155,4 @@ envelope and into the slice's `reducerReport`.
155
155
 
156
156
  > Body of `## 业务测试细分 (optional)`. If the PRD or project warrants it, subdivide `qa-business` further into roles like `qa-business-api` / `qa-business-frontend` / `qa-business-regression`; each gets its own `peaks sub-agent dispatch` call. Names are convention not contract — the dispatcher accepts any non-empty string. **Subdivision must stay ≤ 2 levels deep** (RL-4): `qa-business-api` is fine, `qa-business-api-user` is not. Two levels of depth is the empirical sweet spot — past that, the reducer cannot audit the boundaries between sub-agents, and prompts start overlapping.
157
157
 
158
- For the full contract (heartbeat instructions for each sub-agent, batch-id discipline, 30s cadence, 100-truncation, 5min stale) see `skills/peaks-qa/references/qa-fanout-contract.md` and `skills/peaks-solo/references/sub-agent-dispatch.md` §G6.
158
+ For the full contract (heartbeat instructions for each sub-agent, batch-id discipline, 30s cadence, 100-truncation, 5min stale) see `skills/peaks-qa/references/qa-fanout-contract.md` and `skills/peaks-code/references/sub-agent-dispatch.md` §G6.
@@ -1,16 +1,16 @@
1
1
  # Sub-agent dispatch (QA)
2
2
 
3
- > Body of `## Sub-agent dispatch`. When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-solo`, the following sections of THIS skill are **suspended** for the sub-agent run:
3
+ > Body of `## Sub-agent dispatch`. When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-code`, the following sections of THIS skill are **suspended** for the sub-agent run:
4
4
 
5
5
  - **Session id** — use the parent's sid (read `.peaks/_runtime/session.json` or pass `--session-id <parent-sid>` to any session-creating CLI). Do NOT spawn your own session. The new `peaks session info --active` reads the canonical binding for you.
6
- - **Skill presence (MANDATORY first action)** — do NOT call `peaks skill presence:set peaks-qa`. The sub-agent must not overwrite `.peaks/.active-skill.json`; the main Solo loop owns that file. If you need to mark your own state, write a marker file at `.peaks/_runtime/<sessionId>/system/sub-agent-qa.json` and only that.
7
- - **Workspace initialization** — Solo has already run `peaks workspace init` before fan-out. Do not re-run it.
8
- - **Mode selection** — Solo has already chosen the mode.
9
- - **Statusline install** — already done by Solo at session startup.
6
+ - **Skill presence (MANDATORY first action)** — do NOT call `peaks skill presence:set peaks-qa`. The sub-agent must not overwrite `.peaks/.active-skill.json`; the main Code loop owns that file. If you need to mark your own state, write a marker file at `.peaks/_runtime/<sessionId>/system/sub-agent-qa.json` and only that.
7
+ - **Workspace initialization** — Code has already run `peaks workspace init` before fan-out. Do not re-run it.
8
+ - **Mode selection** — Code has already chosen the mode.
9
+ - **Statusline install** — already done by Code at session startup.
10
10
 
11
11
  What the sub-agent **MUST** still do:
12
12
 
13
- 0. **Do NOT call `peaks request init`** — Solo has already initialised the request artefact slot in the main loop before fan-out. The sub-agent reads it via `peaks request show <rid> --role qa --project <repo> --json` if it needs to.
13
+ 0. **Do NOT call `peaks request init`** — Code has already initialised the request artefact slot in the main loop before fan-out. The sub-agent reads it via `peaks request show <rid> --role qa --project <repo> --json` if it needs to.
14
14
  2. `peaks request show <rid> --role prd --project <repo> --json` (and `--role rd`, `--role ui` if UI is in the swarm plan).
15
15
  3. Standards preflight (dry-run only).
16
16
  4. Write `.peaks/_runtime/<sessionId>/qa/test-cases/<rid>.md` with test cases that link to PRD acceptance items.
@@ -30,7 +30,7 @@ What the sub-agent **MUST** still do:
30
30
  **Hard prohibitions** (sub-agent context):
31
31
 
32
32
  - Do NOT call `Skill(skill="...")`.
33
- - Do NOT call `peaks skill presence:set` — Solo owns the active-skill file.
33
+ - Do NOT call `peaks skill presence:set` — Code owns the active-skill file.
34
34
  - Do NOT run the actual test suite, do NOT execute security/perf tools, do NOT open a browser — those are the **QA validation** phase, not the Swarm planning phase.
35
35
  - Do NOT commit, push, install hooks, or apply settings.json mutations.
36
36
  - Do NOT ask the user interactive questions. If you need clarification, return `{"status":"blocked","blockedReason":"<text>"}`.
@@ -1,6 +1,13 @@
1
1
  ---
2
2
  name: peaks-rd
3
- description: Research and development skill for Peaks. Use for engineering analysis, refactor planning, project scanning, code standards, unit-test coverage gates, implementation contracts, task graphs, and RD handoffs. Always use this for Peaks-Loop refactor workflows.
3
+ description: |
4
+ Research and development role for Peaks-Loop (LLM-only internal role; not user-invocable.
5
+ Triggered by peaks-code via `peaks sub-agent dispatch --role rd`.)
6
+ Use for engineering analysis, refactor planning, project scanning, code standards,
7
+ unit-test coverage gates, implementation contracts, task graphs, and RD handoffs.
8
+ Always use this for Peaks-Loop refactor workflows.
9
+ visibility: internal
10
+ ---
4
11
  ---
5
12
 
6
13
  ## Single-scope-axis naming convention
@@ -17,7 +24,7 @@ RD workflow automatically runs `peaks context build --audience peaks-rd` before
17
24
 
18
25
  > **Read once per RD invocation; RD is built around these 4 guidelines.**
19
26
 
20
- Every RD action (planning, implementation, sub-agent dispatch, fan-out) MUST align with the 4 Karpathy guidelines. The full text lives at `andrej-karpathy-skills:karpathy-guidelines` (reference material only — do not execute upstream / run installer / persist sensitive examples). RD sub-agents receive the full text via `references/rd-sub-agent-dispatch.md` (see "Karpathy-guidelines context"). The 4 guidelines are:
27
+ Every RD action MUST align with the 4 Karpathy guidelines (full text at `andrej-karpathy-skills:karpathy-guidelines` — reference only, do not execute upstream). RD sub-agents receive the full text via `references/rd-sub-agent-dispatch.md`. The 4 guidelines are:
21
28
 
22
29
  1. **Think Before Coding** — surface assumptions, name tradeoffs, ask when unclear. State red-line scope in `## Red-line scope` before any code change.
23
30
  2. **Simplicity First** — minimum code that solves the problem. No speculative features, no abstractions for single-use code, no error handling for impossible scenarios. If 200 lines could be 50, rewrite it. The 800-line file cap and `peaks scan file-size` gate enforce this mechanically.
@@ -40,9 +47,9 @@ For frontend / UI-affecting slices, RD's self-test uses the Playwright MCP heade
40
47
 
41
48
  → see `references/browser-self-test-contracts.md` and `references/browser-action-wrapper.md` (slice 3 thin wrapper).
42
49
 
43
- ## Sub-agent dispatch (when launched by peaks-solo swarm)
50
+ ## Sub-agent dispatch (when launched by peaks-code swarm)
44
51
 
45
- When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-solo`, the following sections of THIS skill are **suspended** for the sub-agent run: Session id (use parent's), Skill presence, Workspace initialization, Mode selection, Statusline install.
52
+ When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-code`, the following sections of THIS skill are **suspended** for the sub-agent run: Session id (use parent's), Skill presence, Workspace initialization, Mode selection, Statusline install.
46
53
 
47
54
  What the sub-agent MUST still do: read PRD via `peaks request show`, run standards preflight (dry-run only), write planning artefact (`rd/tech-doc.md` for feature/refactor; `rd/bug-analysis.md` for bugfix; skip for config/docs/chore), return compact JSON envelope.
48
55
 
@@ -50,7 +57,7 @@ What the sub-agent MUST still do: read PRD via `peaks request show`, run standar
50
57
 
51
58
  ## Skill presence (MANDATORY first action — main-loop context only)
52
59
 
53
- When this skill is running in the main Claude session (not as a sub-agent — i.e. user invoked `peaks-rd` directly, or `peaks-solo` is executing the role inline in assisted/strict mode), before any analysis or tool call, immediately run `peaks skill presence:set peaks-rd --project <repo> --mode <mode> --gate startup`. Install statusline on first run. Read durable project memory via `peaks project memories --project <repo> --json`.
60
+ When this skill is running in the main Claude session (not as a sub-agent — i.e. user invoked `peaks-rd` directly, or `peaks-code` is executing the role inline in assisted/strict mode), before any analysis or tool call, immediately run `peaks skill presence:set peaks-rd --project <repo> --mode <mode> --gate startup`. Install statusline on first run. Read durable project memory via `peaks project memories --project <repo> --json`.
54
61
 
55
62
  → see `references/skill-presence-and-title.md` for the full contract.
56
63
 
@@ -224,7 +231,7 @@ Do not bypass the parallel review fan-out when the slice has a code-review / qa-
224
231
 
225
232
  ## Sub-agent context governance (G7 + G7.7 + G8 + G9 — slice #010)
226
233
 
227
- RD sub-agent prompt template MUST include the G7 path convention + G8.6 share protocol. Detailed protocol: `skills/peaks-solo/references/context-governance.md` + `skills/peaks-solo/references/headroom-integration.md`.
234
+ RD sub-agent prompt template MUST include the G7 path convention + G8.6 share protocol. Detailed protocol: `skills/peaks-code/references/context-governance.md` + `skills/peaks-code/references/headroom-integration.md`.
228
235
 
229
236
  → see `references/rd-context-governance.md` for the full G7 / G8.6 / G9 protocol + RD sub-agent prompt template.
230
237
 
@@ -21,7 +21,7 @@ AskUserQuestion({
21
21
  { label: "Skip browser self-test, hand off to QA",
22
22
  description: "Mark the slice's browser self-test as deferred. Do NOT mark the slice as RD-done; transition to qa-handoff with browser-gate=blocked reason=login-required, and let QA's gate machinery surface the wall to the user again." },
23
23
  { label: "Cancel the workflow",
24
- description: "Stop RD. Emit a blocked TXT handoff so peaks-solo can surface the auth wall to the user. Do not modify code paths that the browser gate would have covered." }
24
+ description: "Stop RD. Emit a blocked TXT handoff so peaks-code can surface the auth wall to the user. Do not modify code paths that the browser gate would have covered." }
25
25
  ]
26
26
  })
27
27
  ```
@@ -19,7 +19,7 @@ When the project-scan in `.peaks/_runtime/<sessionId>/rd/project-scan.md` identi
19
19
 
20
20
  2. **Never inline mock data in component files**: Mock data, fixture objects, and stub responses belong in dedicated mock files. Components should receive data through their normal channels (props, API calls via services). Writing `const mockData = [...]` inside a `.tsx` file is prohibited.
21
21
 
22
- 3. **Mock files must export TypeScript interfaces**: Every mock response type must be exported so RD implementation and QA test-cases can import the same contract. See peaks-solo's "Frontend-only development mode" for the full mock-to-real migration pattern.
22
+ 3. **Mock files must export TypeScript interfaces**: Every mock response type must be exported so RD implementation and QA test-cases can import the same contract. See peaks-code's "Frontend-only development mode" for the full mock-to-real migration pattern.
23
23
 
24
24
  4. **Every mock file must be marked**: Add `// MOCK: Replace with real API call when swagger.json is available` at the top of every mock file.
25
25
 
@@ -1,6 +1,6 @@
1
1
  # Parallel review fan-out (RD)
2
2
 
3
- > Body of `## Parallel review fan-out`. **When RD reaches the end of implementation, the three review activities (code review, QA test-cases draft, AND karpathy review) run in parallel via `peaks sub-agent dispatch <role>` (then executing the returned toolCall), not sequentially.** This is the same fan-out pattern peaks-solo uses for the post-PRD swarm. RD itself, when it is the main loop, behaves as a sub-agent orchestrator: it issues 3 `peaks sub-agent dispatch` calls in a single message and waits for all to return before aggregating findings and transitioning to `qa-handoff`.
3
+ > Body of `## Parallel review fan-out`. **When RD reaches the end of implementation, the three review activities (code review, QA test-cases draft, AND karpathy review) run in parallel via `peaks sub-agent dispatch <role>` (then executing the returned toolCall), not sequentially.** This is the same fan-out pattern peaks-code uses for the post-PRD swarm. RD itself, when it is the main loop, behaves as a sub-agent orchestrator: it issues 3 `peaks sub-agent dispatch` calls in a single message and waits for all to return before aggregating findings and transitioning to `qa-handoff`.
4
4
 
5
5
  **v2.12.0 collapse (Group A — Tier 1+2+3):** the previous 4-way fan-out (slice 004) plus the appended `karpathy-reviewer` (slice 5/6) totalled **5 sub-agents**. The `security-reviewer` and `perf-baseline-reviewer` slots moved out of the RD fan-out into two new standalone audit skills:
6
6
 
@@ -73,7 +73,7 @@ end of implementation, RD fires 3 sub-agents in parallel via
73
73
  conversation context. They MUST NOT mutate parent settings
74
74
  (`peaks skill presence:set`, hooks install, `.claude/settings.json`).
75
75
  - Sub-agents MUST NOT call `peaks workflow verify-pipeline` — that is
76
- Solo's responsibility.
76
+ Code's responsibility.
77
77
  - Sub-agents MUST NOT modify the request artifact body — they only
78
78
  write their respective review artifact.
79
79
  - Sub-agents MUST NOT install or persist external material (no
@@ -28,7 +28,7 @@ peaks understand show --project <repo> --json # when UA artifac
28
28
  peaks codegraph context --project <repo> "<task>"
29
29
  peaks codegraph affected --project <repo> <changed-files...> --json
30
30
 
31
- # 4.1 read project-scan from Solo's pre-RD scan — BLOCKING if missing
31
+ # 4.1 read project-scan from Code's pre-RD scan — BLOCKING if missing
32
32
  # **STOP if .peaks/_runtime/<sessionId>/rd/project-scan.md does not exist.**
33
33
  # **Do not write any code, do not plan any implementation, do not pass go.**
34
34
  # **Create the project-scan first, then proceed.**
@@ -164,7 +164,7 @@ peaks codegraph affected --project <repo> <changed-files...> --json
164
164
  # Without project rules, security review and code review triggers won't fire.
165
165
 
166
166
  # 7. AFTER implementation, BEFORE QA handoff — RUN THESE GATES:
167
- # Peaks-Loop Gate B2: unit tests exist and pass for the changed surface → npx vitest run --changed (or project equivalent; the changed-only mode is the peaks slice check default as of run 017; use --run-tests for the full suite, or invoke /peaks-solo-test to run the full suite standalone)
167
+ # Peaks-Loop Gate B2: unit tests exist and pass for the changed surface → npx vitest run --changed (or project equivalent; the changed-only mode is the peaks slice check default as of run 017; use --run-tests for the full suite, or invoke /peaks-code-test to run the full suite standalone)
168
168
  # Peaks-Loop Gate B3: code review evidence → .peaks/_runtime/<sessionId>/rd/code-review.md
169
169
  # Peaks-Loop Gate B4: security review evidence → .peaks/_runtime/<sessionId>/rd/security-review.md
170
170
  # Peaks-Loop Gate B5 (NEW): RD artifact body has no unfilled placeholders.
@@ -1,6 +1,6 @@
1
1
  # Sub-agent dispatch (RD)
2
2
 
3
- > Body of `## Sub-agent dispatch`. When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-solo`, the following sections of THIS skill are **suspended** for the sub-agent run:
3
+ > Body of `## Sub-agent dispatch`. When this skill is launched as a sub-agent via `peaks sub-agent dispatch <role>` (then the LLM executes the returned toolCall) from `peaks-code`, the following sections of THIS skill are **suspended** for the sub-agent run:
4
4
 
5
5
  ## Default `--from-dag` is mandatory (slice 2026-06-24-efficiency-4p-bundle / G2 / P0.3)
6
6
 
@@ -32,26 +32,26 @@
32
32
  > `tests/unit/dispatch/dispatch-fanout-mandatory.test.ts` (≥ 8 cases
33
33
  > covering 1-leaf, 2-leaf, 3+-leaf, config/docs/chore type-bypass, and
34
34
  > the preferences-with-serial-default fan-out escape hatch). See also
35
- > `skills/peaks-solo/references/fanout-mandatory.md` for the
35
+ > `skills/peaks-code/references/fanout-mandatory.md` for the
36
36
  > orchestrator-side rationale; the two files share the same wording by
37
37
  > design — if either changes, update the other.
38
38
 
39
39
  - **Session id** — use the parent's sid (read `.peaks/_runtime/session.json` or pass `--session-id <parent-sid>` to any session-creating CLI). Do NOT spawn your own session. The new `peaks session info --active` reads the canonical binding for you.
40
- - **Skill presence (MANDATORY first action)** — do NOT call `peaks skill presence:set peaks-rd`. The sub-agent must not overwrite `.peaks/.active-skill.json`; the main Solo loop owns that file. If you need to mark your own state, write a marker file at `.peaks/_runtime/<sessionId>/system/sub-agent-rd.json` and only that.
41
- - **Workspace initialization** — Solo has already run `peaks workspace init` before fan-out. Do not re-run it.
42
- - **Mode selection** — Solo has already chosen the mode. Read it from the prompt arguments (or from `.peaks/.active-skill.json` if you can, but do not write it).
43
- - **Statusline install** — already done by Solo at session startup; do not re-run.
40
+ - **Skill presence (MANDATORY first action)** — do NOT call `peaks skill presence:set peaks-rd`. The sub-agent must not overwrite `.peaks/.active-skill.json`; the main Code loop owns that file. If you need to mark your own state, write a marker file at `.peaks/_runtime/<sessionId>/system/sub-agent-rd.json` and only that.
41
+ - **Workspace initialization** — Code has already run `peaks workspace init` before fan-out. Do not re-run it.
42
+ - **Mode selection** — Code has already chosen the mode. Read it from the prompt arguments (or from `.peaks/.active-skill.json` if you can, but do not write it).
43
+ - **Statusline install** — already done by Code at session startup; do not re-run.
44
44
 
45
45
  What the sub-agent **MUST** still do, from this skill's contract:
46
46
 
47
- 0. **Do NOT call `peaks request init`** — Solo has already initialised the request artefact slot in the main loop before fan-out (the runbook has the exact `peaks request init --role rd --id <rid> --project <repo> --apply --type <type> --json` call). The sub-agent reads the slot via `peaks request show <rid> --role rd --project <repo> --json` if it needs to. Note: `peaks request init` is **dry-run by default**. Pass `--apply` to actually create the artifact.
47
+ 0. **Do NOT call `peaks request init`** — Code has already initialised the request artefact slot in the main loop before fan-out (the runbook has the exact `peaks request init --role rd --id <rid> --project <repo> --apply --type <type> --json` call). The sub-agent reads the slot via `peaks request show <rid> --role rd --project <repo> --json` if it needs to. Note: `peaks request init` is **dry-run by default**. Pass `--apply` to actually create the artifact.
48
48
  2. `peaks request show <rid> --role prd --project <repo> --json` (and `--role ui` if UI is in the swarm plan).
49
- 3. Standards preflight (dry-run only; Solo owns the apply step).
50
- 4. Project-scan read; create `rd/project-scan.md` only if Solo flagged it missing in the dispatch prompt.
49
+ 3. Standards preflight (dry-run only; Code owns the apply step).
50
+ 4. Project-scan read; create `rd/project-scan.md` only if Code flagged it missing in the dispatch prompt.
51
51
  5. Write the planning artefact: `rd/requests/<rid>.md` (feature/refactor, per the `artifact-per-request.md` contract) or `rd/bug-analysis.md` (bugfix). If `--type` is `config|docs|chore`, **no planning artefact is required** — return immediately with `{"role":"rd-planning","status":"skipped","reason":"type=<type>"}`.
52
52
 
53
53
  > **v2.11.0 change (Group A):** `rd/tech-doc.md` is removed. The per-slice planning record is the per-request artefact at `rd/requests/<rid>.md`; the slice's source-of-truth architecture is the immutable peaks-prd handoff at `prd/handoff.md` (verify handoff hash = `<dispatched value>` before reading).
54
- 6. Return only a compact JSON envelope — Solo will run the convergence gate (`ls` checks):
54
+ 6. Return only a compact JSON envelope — Code will run the convergence gate (`ls` checks):
55
55
 
56
56
  ```json
57
57
  {
@@ -67,12 +67,12 @@ What the sub-agent **MUST** still do, from this skill's contract:
67
67
  **Hard prohibitions** (sub-agent context, in addition to general red lines):
68
68
 
69
69
  - Do NOT call `Skill(skill="...")` from inside the sub-agent — that defeats the fan-out.
70
- - Do NOT call `peaks skill presence:set` — Solo owns the active-skill file.
70
+ - Do NOT call `peaks skill presence:set` — Code owns the active-skill file.
71
71
  - Do NOT commit, push, install hooks, or apply settings.json mutations.
72
- - Do NOT ask the user interactive questions. If you need clarification, return `{"status":"blocked","blockedReason":"<text>"}` and let Solo handle the user message.
72
+ - Do NOT ask the user interactive questions. If you need clarification, return `{"status":"blocked","blockedReason":"<text>"}` and let Code handle the user message.
73
73
  - Do NOT modify code (the Swarm phase is planning only; code edits happen in the RD implementation phase, which is a separate sub-agent or inline run after Gate B).
74
74
 
75
- After returning, Solo re-checks Gate B (`ls .peaks/_runtime/<sessionId>/rd/requests/<rid>.md` etc.) and proceeds to RD implementation, which is a different sub-agent or inline run.
75
+ After returning, Code re-checks Gate B (`ls .peaks/_runtime/<sessionId>/rd/requests/<rid>.md` etc.) and proceeds to RD implementation, which is a different sub-agent or inline run.
76
76
 
77
77
  ## Test Tool Detection (mandatory)
78
78
 
@@ -61,7 +61,7 @@ npx vitest run --changed --reporter=verbose 2>&1 | tail -20
61
61
  # Any failing test or zero tests for new code → BLOCKED. Write tests, then re-run.
62
62
  #
63
63
  # To run the FULL suite (slower; not the default for `peaks slice check`),
64
- # drop `--changed` or use `npx vitest run --reporter=verbose`. The peaks-solo-test
64
+ # drop `--changed` or use `npx vitest run --reporter=verbose`. The peaks-code-test
65
65
  # skill is the user-facing wrapper for the full suite; the slice check's
66
66
  # `--run-tests` flag is the CLI opt-in.
67
67
  ```
@@ -104,7 +104,7 @@ peaks scan request-type-sanity --project <repo> --type <type> --json
104
104
  peaks request repair-status <rid> --project <repo> --session-id <session-id> --json
105
105
  # Expected: atCap=false. exit 0.
106
106
  # atCap=true → BLOCKED. Three repair cycles already attempted; emit a blocked TXT
107
- # handoff via Solo rather than entering a fourth cycle.
107
+ # handoff via Code rather than entering a fourth cycle.
108
108
  ```
109
109
 
110
110
  **Peaks-Loop Gate B8 — Diff stays inside the declared red-line scope:**
@@ -1,6 +1,6 @@
1
1
  # Skill presence (RD)
2
2
 
3
- > Body of `## Skill presence (MANDATORY first action — main-loop context only)`. When this skill is running in the main Claude session (not as a sub-agent — i.e. user invoked `peaks-rd` directly, or `peaks-solo` is executing the role inline in assisted/strict mode), before any analysis or tool call, immediately run:
3
+ > Body of `## Skill presence (MANDATORY first action — main-loop context only)`. When this skill is running in the main Claude session (not as a sub-agent — i.e. user invoked `peaks-rd` directly, or `peaks-code` is executing the role inline in assisted/strict mode), before any analysis or tool call, immediately run:
4
4
 
5
5
  ```bash
6
6
  peaks skill presence:set peaks-rd --project <repo> --mode <mode> --gate startup
@@ -71,6 +71,6 @@ Missing section: reviewer is skipped (transition still passes; envelope records
71
71
  - DO NOT silently prompt users for API keys. Missing env vars surface as `providerUnavailable` and the `fallbackOnError` policy decides skip vs throw.
72
72
  - DO NOT change the schema for the 5 existing envelope parsers (v2.13.3 territory). The ReviewerEnvelope schema is additive.
73
73
 
74
- ## Sub-agent dispatch (when launched by peaks-solo swarm)
74
+ ## Sub-agent dispatch (when launched by peaks-code swarm)
75
75
 
76
- When this skill runs as a sub-agent dispatched by peaks-solo, the sub-agent receives the parent session id and change-id via envelope. It MUST write its output to `.peaks/_runtime/<sessionId>/rd/third-party-review.json` + `.md` and return a compact JSON envelope.
76
+ When this skill runs as a sub-agent dispatched by peaks-code, the sub-agent receives the parent session id and change-id via envelope. It MUST write its output to `.peaks/_runtime/<sessionId>/rd/third-party-review.json` + `.md` and return a compact JSON envelope.
@@ -1,6 +1,12 @@
1
1
  ---
2
2
  name: peaks-sc
3
- description: Source control, sync, and change-control skill for Peaks. Use when a workflow needs change impact, artifact retention, commit boundaries, GitHub artifact repository pointers, sync state, or rollback evidence.
3
+ description: |
4
+ Source control, sync, and change-control role for Peaks-Loop (LLM-only internal role;
5
+ not user-invocable. Triggered by peaks-code via `peaks sub-agent dispatch --role sc`.)
6
+ Use when a workflow needs change impact, artifact retention, commit boundaries,
7
+ GitHub artifact repository pointers, sync state, or rollback evidence.
8
+ visibility: internal
9
+ ---
4
10
  ---
5
11
 
6
12
  # Peaks-Loop SC
@@ -55,7 +61,7 @@ Every SC invocation must write a change-control record at `.peaks/_runtime/<sess
55
61
  - validation result (`peaks sc validate` output);
56
62
  - boundary record (`peaks sc boundary` output).
57
63
 
58
- Solo reads this record before declaring the workflow complete.
64
+ Code reads this record before declaring the workflow complete.
59
65
 
60
66
  ## Refactor role
61
67