@pennyfarthing/core 11.0.0-alpha.0 → 11.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (401) hide show
  1. package/README.md +84 -26
  2. package/package.json +14 -16
  3. package/packages/core/dist/cli/cyclist-migration.test.js +2 -1
  4. package/packages/core/dist/cli/cyclist-migration.test.js.map +1 -1
  5. package/packages/core/dist/cli/ocean-profiles.test.js +5 -4
  6. package/packages/core/dist/cli/ocean-profiles.test.js.map +1 -1
  7. package/packages/core/dist/cli/theme-maker.test.js +5 -4
  8. package/packages/core/dist/cli/theme-maker.test.js.map +1 -1
  9. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.d.ts +20 -0
  10. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.d.ts.map +1 -0
  11. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.js +278 -0
  12. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.js.map +1 -0
  13. package/packages/core/dist/cli/utils/constants.d.ts +7 -1
  14. package/packages/core/dist/cli/utils/constants.d.ts.map +1 -1
  15. package/packages/core/dist/cli/utils/constants.js +2 -0
  16. package/packages/core/dist/cli/utils/constants.js.map +1 -1
  17. package/packages/core/dist/cli/utils/constants.test.d.ts +10 -0
  18. package/packages/core/dist/cli/utils/constants.test.d.ts.map +1 -0
  19. package/packages/core/dist/cli/utils/constants.test.js +38 -0
  20. package/packages/core/dist/cli/utils/constants.test.js.map +1 -0
  21. package/packages/core/dist/consultation/consultation-protocol.d.ts +139 -0
  22. package/packages/core/dist/consultation/consultation-protocol.d.ts.map +1 -0
  23. package/packages/core/dist/consultation/consultation-protocol.js +178 -0
  24. package/packages/core/dist/consultation/consultation-protocol.js.map +1 -0
  25. package/packages/core/dist/consultation/consultation-protocol.test.d.ts +20 -0
  26. package/packages/core/dist/consultation/consultation-protocol.test.d.ts.map +1 -0
  27. package/packages/core/dist/consultation/consultation-protocol.test.js +474 -0
  28. package/packages/core/dist/consultation/consultation-protocol.test.js.map +1 -0
  29. package/packages/core/dist/public/js/react/react.js +30 -30
  30. package/packages/core/dist/scripts/generate-report.test.js +2 -2
  31. package/packages/core/dist/scripts/generate-spider-report.test.js +2 -2
  32. package/packages/core/dist/scripts/generate-spider.test.js +2 -1
  33. package/packages/core/dist/scripts/generate-spider.test.js.map +1 -1
  34. package/packages/core/dist/server/api/file-browser.d.ts.map +1 -1
  35. package/packages/core/dist/server/api/file-browser.js +19 -1
  36. package/packages/core/dist/server/api/file-browser.js.map +1 -1
  37. package/packages/core/dist/server/api/git-fetch-cooldown.test.d.ts +10 -0
  38. package/packages/core/dist/server/api/git-fetch-cooldown.test.d.ts.map +1 -0
  39. package/packages/core/dist/server/api/git-fetch-cooldown.test.js +30 -0
  40. package/packages/core/dist/server/api/git-fetch-cooldown.test.js.map +1 -0
  41. package/packages/core/dist/server/api/git.d.ts +8 -0
  42. package/packages/core/dist/server/api/git.d.ts.map +1 -1
  43. package/packages/core/dist/server/api/git.js +37 -10
  44. package/packages/core/dist/server/api/git.js.map +1 -1
  45. package/packages/core/dist/server/api/health-score.d.ts.map +1 -1
  46. package/packages/core/dist/server/api/health-score.js +25 -1
  47. package/packages/core/dist/server/api/health-score.js.map +1 -1
  48. package/packages/core/dist/server/api/index.d.ts +1 -1
  49. package/packages/core/dist/server/api/index.d.ts.map +1 -1
  50. package/packages/core/dist/server/api/index.js +1 -1
  51. package/packages/core/dist/server/api/index.js.map +1 -1
  52. package/packages/core/dist/server/api/settings.d.ts.map +1 -1
  53. package/packages/core/dist/server/api/settings.js +73 -2
  54. package/packages/core/dist/server/api/settings.js.map +1 -1
  55. package/packages/core/dist/server/api/theme-agents.d.ts.map +1 -1
  56. package/packages/core/dist/server/api/theme-agents.js +61 -0
  57. package/packages/core/dist/server/api/theme-agents.js.map +1 -1
  58. package/packages/core/dist/server/otlp-receiver.d.ts +35 -13
  59. package/packages/core/dist/server/otlp-receiver.d.ts.map +1 -1
  60. package/packages/core/dist/server/otlp-receiver.js +76 -16
  61. package/packages/core/dist/server/otlp-receiver.js.map +1 -1
  62. package/packages/core/dist/server/paths.d.ts.map +1 -1
  63. package/packages/core/dist/server/paths.js +11 -1
  64. package/packages/core/dist/server/paths.js.map +1 -1
  65. package/packages/core/dist/server/server.d.ts +3 -1
  66. package/packages/core/dist/server/server.d.ts.map +1 -1
  67. package/packages/core/dist/server/server.js +23 -16
  68. package/packages/core/dist/server/server.js.map +1 -1
  69. package/packages/core/dist/server/server.test.js.map +1 -1
  70. package/packages/core/dist/workflow/gate-file-validation.d.ts +49 -0
  71. package/packages/core/dist/workflow/gate-file-validation.d.ts.map +1 -0
  72. package/packages/core/dist/workflow/gate-file-validation.js +157 -0
  73. package/packages/core/dist/workflow/gate-file-validation.js.map +1 -0
  74. package/packages/core/dist/workflow/gate-file-validation.test.d.ts +19 -0
  75. package/packages/core/dist/workflow/gate-file-validation.test.d.ts.map +1 -0
  76. package/packages/core/dist/workflow/gate-file-validation.test.js +536 -0
  77. package/packages/core/dist/workflow/gate-file-validation.test.js.map +1 -0
  78. package/packages/core/dist/workflow/gate-schema-validation.test.d.ts +14 -0
  79. package/packages/core/dist/workflow/gate-schema-validation.test.d.ts.map +1 -0
  80. package/packages/core/dist/workflow/gate-schema-validation.test.js +339 -0
  81. package/packages/core/dist/workflow/gate-schema-validation.test.js.map +1 -0
  82. package/packages/core/dist/workflow/handoff.js +2 -2
  83. package/packages/core/dist/workflow/handoff.js.map +1 -1
  84. package/packages/core/dist/workflow/handoff.test.js +16 -0
  85. package/packages/core/dist/workflow/handoff.test.js.map +1 -1
  86. package/packages/core/dist/workflow/variable-resolver.test.js +1 -1
  87. package/packages/core/dist/workflow/variable-resolver.test.js.map +1 -1
  88. package/packages/core/dist/workflow/workflow-migration.test.js +4 -3
  89. package/packages/core/dist/workflow/workflow-migration.test.js.map +1 -1
  90. package/packages/core/dist/workflow/workflow-schema.d.ts +4 -2
  91. package/packages/core/dist/workflow/workflow-schema.d.ts.map +1 -1
  92. package/packages/core/dist/workflow/workflow-schema.js +43 -8
  93. package/packages/core/dist/workflow/workflow-schema.js.map +1 -1
  94. package/pennyfarthing-dist/agents/README.md +6 -14
  95. package/pennyfarthing-dist/agents/architect.md +43 -30
  96. package/pennyfarthing-dist/agents/ba.md +30 -29
  97. package/pennyfarthing-dist/agents/dev.md +76 -41
  98. package/pennyfarthing-dist/agents/devops.md +57 -21
  99. package/pennyfarthing-dist/agents/orchestrator.md +3 -11
  100. package/pennyfarthing-dist/agents/pm.md +45 -31
  101. package/pennyfarthing-dist/agents/reviewer.md +20 -66
  102. package/pennyfarthing-dist/agents/sm-setup.md +2 -2
  103. package/pennyfarthing-dist/agents/sm.md +8 -30
  104. package/pennyfarthing-dist/agents/tea.md +25 -41
  105. package/pennyfarthing-dist/agents/tech-writer.md +33 -90
  106. package/pennyfarthing-dist/agents/ux-designer.md +39 -40
  107. package/pennyfarthing-dist/commands/benchmark-control.md +8 -64
  108. package/pennyfarthing-dist/commands/benchmark.md +8 -480
  109. package/pennyfarthing-dist/commands/job-fair.md +8 -97
  110. package/pennyfarthing-dist/commands/pf-benchmark-control.md +70 -0
  111. package/pennyfarthing-dist/commands/pf-benchmark.md +486 -0
  112. package/pennyfarthing-dist/commands/pf-chore.md +4 -4
  113. package/pennyfarthing-dist/commands/pf-ci.md +40 -0
  114. package/pennyfarthing-dist/commands/pf-close-epic.md +9 -27
  115. package/pennyfarthing-dist/commands/pf-continue-session.md +9 -213
  116. package/pennyfarthing-dist/commands/pf-create-branches-from-story.md +11 -353
  117. package/pennyfarthing-dist/commands/pf-docs.md +28 -0
  118. package/pennyfarthing-dist/commands/pf-epic.md +67 -0
  119. package/pennyfarthing-dist/commands/pf-git-cleanup.md +11 -52
  120. package/pennyfarthing-dist/commands/pf-git.md +75 -0
  121. package/pennyfarthing-dist/commands/pf-help.md +110 -128
  122. package/pennyfarthing-dist/commands/pf-job-fair.md +102 -0
  123. package/pennyfarthing-dist/commands/pf-new-work.md +9 -18
  124. package/pennyfarthing-dist/commands/pf-parallel-work.md +6 -66
  125. package/pennyfarthing-dist/commands/pf-release.md +11 -76
  126. package/pennyfarthing-dist/commands/pf-repo-status.md +11 -44
  127. package/pennyfarthing-dist/commands/pf-run-ci.md +8 -111
  128. package/pennyfarthing-dist/commands/pf-session.md +51 -0
  129. package/pennyfarthing-dist/commands/pf-solo.md +447 -0
  130. package/pennyfarthing-dist/commands/pf-sprint-planning.md +8 -104
  131. package/pennyfarthing-dist/commands/pf-standalone.md +1 -1
  132. package/pennyfarthing-dist/commands/pf-start-epic.md +9 -163
  133. package/pennyfarthing-dist/commands/pf-sync-epic-to-jira.md +8 -179
  134. package/pennyfarthing-dist/commands/pf-sync-work-with-sprint.md +8 -368
  135. package/pennyfarthing-dist/commands/pf-update-domain-docs.md +8 -78
  136. package/pennyfarthing-dist/commands/solo.md +8 -442
  137. package/pennyfarthing-dist/guides/agent-behavior.md +14 -14
  138. package/pennyfarthing-dist/guides/agent-coordination.md +7 -7
  139. package/pennyfarthing-dist/guides/agent-tag-taxonomy.md +6 -6
  140. package/pennyfarthing-dist/guides/bikerack.md +128 -0
  141. package/pennyfarthing-dist/guides/brownfield-tools.md +133 -0
  142. package/pennyfarthing-dist/guides/command-tag-taxonomy.md +2 -2
  143. package/pennyfarthing-dist/guides/gate-schema.md +227 -0
  144. package/pennyfarthing-dist/guides/gates.md +120 -0
  145. package/pennyfarthing-dist/guides/handoff-cli.md +116 -0
  146. package/pennyfarthing-dist/guides/hooks.md +86 -4
  147. package/pennyfarthing-dist/guides/output-styles.md +65 -0
  148. package/pennyfarthing-dist/guides/patterns/approval-gates-pattern.md +5 -5
  149. package/pennyfarthing-dist/guides/patterns/tdd-flow-pattern.md +4 -4
  150. package/pennyfarthing-dist/guides/prompt-patterns.md +5 -5
  151. package/pennyfarthing-dist/guides/reflector.md +4 -4
  152. package/pennyfarthing-dist/guides/session-artifacts.md +1 -1
  153. package/pennyfarthing-dist/guides/skill-schema.md +1 -1
  154. package/pennyfarthing-dist/guides/tandem-protocol.md +13 -1
  155. package/pennyfarthing-dist/guides/worktree-mode.md +3 -3
  156. package/pennyfarthing-dist/guides/xml-tags.md +5 -4
  157. package/pennyfarthing-dist/personas/themes/hogans-heroes.yaml +11 -22
  158. package/pennyfarthing-dist/personas/themes/stephen-king.yaml +13 -24
  159. package/pennyfarthing-dist/scripts/core/agent-session.sh +0 -0
  160. package/pennyfarthing-dist/scripts/core/check-context.sh +0 -0
  161. package/pennyfarthing-dist/scripts/core/phase-check-start.sh +1 -1
  162. package/pennyfarthing-dist/scripts/core/prime.sh +0 -0
  163. package/pennyfarthing-dist/scripts/cyclist/is-cyclist.sh +0 -0
  164. package/pennyfarthing-dist/scripts/git/create-feature-branches.sh +0 -0
  165. package/pennyfarthing-dist/scripts/git/git-status-all.sh +0 -0
  166. package/pennyfarthing-dist/scripts/git/install-git-hooks.sh +0 -0
  167. package/pennyfarthing-dist/scripts/git/release.sh +0 -0
  168. package/pennyfarthing-dist/scripts/git/worktree-manager.sh +0 -0
  169. package/pennyfarthing-dist/scripts/health/drift-detection.sh +0 -0
  170. package/pennyfarthing-dist/scripts/hooks/bell-mode-hook.sh +0 -0
  171. package/pennyfarthing-dist/scripts/hooks/context-circuit-breaker.sh +0 -0
  172. package/pennyfarthing-dist/scripts/hooks/context-warning.sh +0 -0
  173. package/pennyfarthing-dist/scripts/hooks/cyclist-pretooluse-hook.sh +0 -0
  174. package/pennyfarthing-dist/scripts/hooks/dispatcher-template.sh +0 -0
  175. package/pennyfarthing-dist/scripts/hooks/otel-auto-config.sh +19 -14
  176. package/pennyfarthing-dist/scripts/hooks/post-merge.sh +0 -0
  177. package/pennyfarthing-dist/scripts/hooks/pre-commit.sh +0 -0
  178. package/pennyfarthing-dist/scripts/hooks/pre-edit-check.sh +0 -0
  179. package/pennyfarthing-dist/scripts/hooks/pre-push.sh +0 -0
  180. package/pennyfarthing-dist/scripts/hooks/question-reflector-check.sh +0 -0
  181. package/pennyfarthing-dist/scripts/hooks/question_reflector_check.py +0 -0
  182. package/pennyfarthing-dist/scripts/hooks/schema-validation.sh +0 -0
  183. package/pennyfarthing-dist/scripts/hooks/session-start.sh +0 -0
  184. package/pennyfarthing-dist/scripts/hooks/session-stop.sh +0 -0
  185. package/pennyfarthing-dist/scripts/hooks/sprint-yaml-validation.sh +0 -0
  186. package/pennyfarthing-dist/scripts/hooks/welcome-hook.sh +0 -0
  187. package/pennyfarthing-dist/scripts/jira/create-jira-epic.sh +0 -0
  188. package/pennyfarthing-dist/scripts/jira/create-jira-story.sh +0 -0
  189. package/pennyfarthing-dist/scripts/jira/jira-claim-story.sh +0 -0
  190. package/pennyfarthing-dist/scripts/jira/jira-reconcile.sh +0 -0
  191. package/pennyfarthing-dist/scripts/jira/jira-sync-story.sh +0 -0
  192. package/pennyfarthing-dist/scripts/jira/sync-epic-jira.sh +0 -0
  193. package/pennyfarthing-dist/scripts/lib/background-tasks.sh +0 -0
  194. package/pennyfarthing-dist/scripts/lib/checkpoint.sh +0 -0
  195. package/pennyfarthing-dist/scripts/lib/common.sh +0 -0
  196. package/pennyfarthing-dist/scripts/lib/file-lock.sh +0 -0
  197. package/pennyfarthing-dist/scripts/lib/logging.sh +0 -0
  198. package/pennyfarthing-dist/scripts/lib/retry.sh +0 -0
  199. package/pennyfarthing-dist/scripts/maintenance/migrate-theme-schema.mjs +0 -0
  200. package/pennyfarthing-dist/scripts/maintenance/sidecar-health.sh +0 -0
  201. package/pennyfarthing-dist/scripts/misc/add-short-names.sh +0 -0
  202. package/pennyfarthing-dist/scripts/misc/add_short_names.py +0 -0
  203. package/pennyfarthing-dist/scripts/misc/backlog.sh +0 -0
  204. package/pennyfarthing-dist/scripts/misc/check-status.sh +0 -0
  205. package/pennyfarthing-dist/scripts/misc/find-related-work.sh +0 -0
  206. package/pennyfarthing-dist/scripts/misc/generate-skill-docs.sh +0 -0
  207. package/pennyfarthing-dist/scripts/misc/log-skill-usage.sh +0 -0
  208. package/pennyfarthing-dist/scripts/misc/migrate-bmad-workflow.sh +0 -0
  209. package/pennyfarthing-dist/scripts/misc/migrate_bmad_workflow.py +0 -0
  210. package/pennyfarthing-dist/scripts/misc/repo-scan.sh +0 -0
  211. package/pennyfarthing-dist/scripts/misc/repo-utils.sh +0 -0
  212. package/pennyfarthing-dist/scripts/misc/run-ci.sh +0 -0
  213. package/pennyfarthing-dist/scripts/misc/run-timestamp.sh +0 -0
  214. package/pennyfarthing-dist/scripts/misc/session-cleanup.sh +0 -0
  215. package/pennyfarthing-dist/scripts/misc/skill-usage-report.sh +0 -0
  216. package/pennyfarthing-dist/scripts/misc/statusline.sh +0 -0
  217. package/pennyfarthing-dist/scripts/misc/uninstall.sh +0 -0
  218. package/pennyfarthing-dist/scripts/misc/validate-subagent-frontmatter.sh +0 -0
  219. package/pennyfarthing-dist/scripts/portraits/generate-portraits.py +191 -57
  220. package/pennyfarthing-dist/scripts/portraits/generate-portraits.sh +26 -10
  221. package/pennyfarthing-dist/scripts/story/create-story.sh +0 -0
  222. package/pennyfarthing-dist/scripts/story/size-story.sh +0 -0
  223. package/pennyfarthing-dist/scripts/story/story-template.sh +0 -0
  224. package/pennyfarthing-dist/scripts/tests/check.test.sh +0 -0
  225. package/pennyfarthing-dist/scripts/tests/dev-story-workflow-import.test.sh +0 -0
  226. package/pennyfarthing-dist/scripts/tests/epics-and-stories-workflow-import.test.sh +0 -0
  227. package/pennyfarthing-dist/scripts/tests/handoff-phase-update.test.sh +0 -0
  228. package/pennyfarthing-dist/scripts/tests/implementation-readiness-workflow-import.test.sh +0 -0
  229. package/pennyfarthing-dist/scripts/tests/migrate-bmad-workflow.test.sh +0 -0
  230. package/pennyfarthing-dist/scripts/tests/prd-workflow-import.test.sh +0 -0
  231. package/pennyfarthing-dist/scripts/tests/project-context-workflow-import.test.sh +0 -0
  232. package/pennyfarthing-dist/scripts/tests/test-character-voice.sh +0 -0
  233. package/pennyfarthing-dist/scripts/tests/test-drift-detection.sh +0 -0
  234. package/pennyfarthing-dist/scripts/tests/test-post-merge-hook.sh +0 -0
  235. package/pennyfarthing-dist/scripts/tests/test-session-checkpoint.sh +0 -0
  236. package/pennyfarthing-dist/scripts/tests/test-solo-command.sh +0 -0
  237. package/pennyfarthing-dist/scripts/tests/ux-design-workflow-import.test.sh +0 -0
  238. package/pennyfarthing-dist/scripts/theme/list-themes.sh +0 -0
  239. package/pennyfarthing-dist/scripts/validation/validate-agent-schema.sh +0 -0
  240. package/pennyfarthing-dist/scripts/workflow/check.py +0 -0
  241. package/pennyfarthing-dist/scripts/workflow/check.sh +0 -0
  242. package/pennyfarthing-dist/scripts/workflow/complete-step.py +0 -0
  243. package/pennyfarthing-dist/scripts/workflow/finish-story.sh +0 -0
  244. package/pennyfarthing-dist/scripts/workflow/fix-session-phase.sh +0 -0
  245. package/pennyfarthing-dist/scripts/workflow/get-workflow-type.py +0 -0
  246. package/pennyfarthing-dist/scripts/workflow/get-workflow-type.sh +0 -0
  247. package/pennyfarthing-dist/scripts/workflow/list-workflows.sh +0 -0
  248. package/pennyfarthing-dist/scripts/workflow/phase-owner.sh +0 -0
  249. package/pennyfarthing-dist/scripts/workflow/resume-workflow.sh +0 -0
  250. package/pennyfarthing-dist/scripts/workflow/show-workflow.sh +0 -0
  251. package/pennyfarthing-dist/scripts/workflow/start-workflow.sh +0 -0
  252. package/pennyfarthing-dist/scripts/workflow/workflow-status.sh +0 -0
  253. package/pennyfarthing-dist/skills/pf-changelog/SKILL.md +4 -4
  254. package/pennyfarthing-dist/skills/pf-sprint/skill.md +1 -1
  255. package/pennyfarthing-dist/skills/pf-story/scripts/create-story.sh +0 -0
  256. package/pennyfarthing-dist/skills/pf-story/scripts/size-story.sh +0 -0
  257. package/pennyfarthing-dist/skills/pf-story/scripts/story-template.sh +0 -0
  258. package/pennyfarthing-dist/skills/pf-systematic-debugging/SKILL.md +0 -1
  259. package/pennyfarthing-dist/skills/pf-workflow/scripts/list-workflows.sh +0 -0
  260. package/pennyfarthing-dist/skills/pf-workflow/scripts/resume-workflow.sh +0 -0
  261. package/pennyfarthing-dist/skills/pf-workflow/scripts/show-workflow.sh +0 -0
  262. package/pennyfarthing-dist/skills/pf-workflow/scripts/start-workflow.sh +0 -0
  263. package/pennyfarthing-dist/skills/pf-workflow/scripts/workflow-status.sh +0 -0
  264. package/pennyfarthing-dist/skills/skill-registry.schema.json +4 -0
  265. package/pennyfarthing-dist/skills/skill-registry.yaml +8 -21
  266. package/pennyfarthing-dist/workflows/2party-tdd.yaml +11 -0
  267. package/pennyfarthing-dist/workflows/agent-docs.yaml +2 -0
  268. package/pennyfarthing-dist/workflows/bdd-tandem.yaml +4 -0
  269. package/pennyfarthing-dist/workflows/bdd.yaml +4 -0
  270. package/pennyfarthing-dist/workflows/git-cleanup/steps/step-05-complete.md +1 -1
  271. package/pennyfarthing-dist/workflows/tdd-tandem.yaml +3 -0
  272. package/pennyfarthing-dist/workflows/tdd.yaml +3 -0
  273. package/pennyfarthing-dist/workflows/trivial.yaml +2 -0
  274. package/pennyfarthing_scripts/__pycache__/cli.cpython-314.pyc +0 -0
  275. package/pennyfarthing_scripts/__pycache__/context.cpython-314.pyc +0 -0
  276. package/pennyfarthing_scripts/__pycache__/session_start_hook.cpython-314.pyc +0 -0
  277. package/pennyfarthing_scripts/bc/__pycache__/__init__.cpython-314.pyc +0 -0
  278. package/pennyfarthing_scripts/bc/__pycache__/cli.cpython-314.pyc +0 -0
  279. package/pennyfarthing_scripts/bc/__pycache__/focus.cpython-314.pyc +0 -0
  280. package/pennyfarthing_scripts/bikerack/__pycache__/__init__.cpython-314.pyc +0 -0
  281. package/pennyfarthing_scripts/bikerack/__pycache__/background_panel.cpython-314.pyc +0 -0
  282. package/pennyfarthing_scripts/bikerack/__pycache__/base_panel.cpython-314.pyc +0 -0
  283. package/pennyfarthing_scripts/bikerack/__pycache__/changed_panel.cpython-314.pyc +0 -0
  284. package/pennyfarthing_scripts/bikerack/__pycache__/cli.cpython-314.pyc +0 -0
  285. package/pennyfarthing_scripts/bikerack/__pycache__/debug_panel.cpython-314.pyc +0 -0
  286. package/pennyfarthing_scripts/bikerack/__pycache__/diffs_panel.cpython-314.pyc +0 -0
  287. package/pennyfarthing_scripts/bikerack/__pycache__/git_panel.cpython-314.pyc +0 -0
  288. package/pennyfarthing_scripts/bikerack/__pycache__/launcher.cpython-314.pyc +0 -0
  289. package/pennyfarthing_scripts/bikerack/__pycache__/sprint_panel.cpython-314.pyc +0 -0
  290. package/pennyfarthing_scripts/bikerack/__pycache__/tui.cpython-314.pyc +0 -0
  291. package/pennyfarthing_scripts/bikerack/__pycache__/ws_client.cpython-314.pyc +0 -0
  292. package/pennyfarthing_scripts/bikerack/changed_panel.py +105 -0
  293. package/pennyfarthing_scripts/bikerack/debug_panel.py +218 -0
  294. package/pennyfarthing_scripts/bikerack/diffs_panel.py +203 -27
  295. package/pennyfarthing_scripts/cli.py +114 -0
  296. package/pennyfarthing_scripts/epic/__init__.py +0 -0
  297. package/pennyfarthing_scripts/epic/cli.py +64 -0
  298. package/pennyfarthing_scripts/gate/__init__.py +1 -0
  299. package/pennyfarthing_scripts/gate/__pycache__/__init__.cpython-314.pyc +0 -0
  300. package/pennyfarthing_scripts/gate/__pycache__/cli.cpython-314.pyc +0 -0
  301. package/pennyfarthing_scripts/gate/__pycache__/validate.cpython-314.pyc +0 -0
  302. package/pennyfarthing_scripts/gate/cli.py +56 -0
  303. package/pennyfarthing_scripts/gate/validate.py +266 -0
  304. package/pennyfarthing_scripts/git_group/__init__.py +0 -0
  305. package/pennyfarthing_scripts/git_group/cli.py +100 -0
  306. package/pennyfarthing_scripts/handoff/__init__.py +1 -0
  307. package/pennyfarthing_scripts/handoff/__pycache__/__init__.cpython-314.pyc +0 -0
  308. package/pennyfarthing_scripts/handoff/__pycache__/cli.cpython-314.pyc +0 -0
  309. package/pennyfarthing_scripts/handoff/__pycache__/complete_phase.cpython-314.pyc +0 -0
  310. package/pennyfarthing_scripts/handoff/__pycache__/gate_file.cpython-314.pyc +0 -0
  311. package/pennyfarthing_scripts/handoff/__pycache__/gate_runner.cpython-314.pyc +0 -0
  312. package/pennyfarthing_scripts/handoff/__pycache__/marker.cpython-314.pyc +0 -0
  313. package/pennyfarthing_scripts/handoff/__pycache__/resolve_gate.cpython-314.pyc +0 -0
  314. package/pennyfarthing_scripts/handoff/cli.py +120 -0
  315. package/pennyfarthing_scripts/handoff/complete_phase.py +155 -0
  316. package/pennyfarthing_scripts/handoff/gate_file.py +105 -0
  317. package/pennyfarthing_scripts/handoff/gate_runner.py +152 -0
  318. package/pennyfarthing_scripts/handoff/marker.py +109 -0
  319. package/pennyfarthing_scripts/handoff/resolve_gate.py +152 -0
  320. package/pennyfarthing_scripts/healthscore/__pycache__/__main__.cpython-314.pyc +0 -0
  321. package/pennyfarthing_scripts/healthscore/__pycache__/analyze.cpython-314.pyc +0 -0
  322. package/pennyfarthing_scripts/hooks/cyclist-pretooluse-hook.sh +0 -0
  323. package/pennyfarthing_scripts/jira/__pycache__/cli.cpython-314.pyc +0 -0
  324. package/pennyfarthing_scripts/launch/__pycache__/__init__.cpython-314.pyc +0 -0
  325. package/pennyfarthing_scripts/launch/__pycache__/cli.cpython-314.pyc +0 -0
  326. package/pennyfarthing_scripts/prime/__pycache__/persona.cpython-314.pyc +0 -0
  327. package/pennyfarthing_scripts/prime/__pycache__/version_sentinel.cpython-314.pyc +0 -0
  328. package/pennyfarthing_scripts/prime/__pycache__/workflow.cpython-314.pyc +0 -0
  329. package/pennyfarthing_scripts/prime/workflow.py +39 -0
  330. package/pennyfarthing_scripts/session/__init__.py +0 -0
  331. package/pennyfarthing_scripts/session/cli.py +87 -0
  332. package/pennyfarthing_scripts/session_start_hook.py +4 -4
  333. package/pennyfarthing_scripts/sprint/__pycache__/archive_epic.cpython-314.pyc +0 -0
  334. package/pennyfarthing_scripts/sprint/__pycache__/cli.cpython-314.pyc +0 -0
  335. package/pennyfarthing_scripts/sprint/__pycache__/epic_add.cpython-314.pyc +0 -0
  336. package/pennyfarthing_scripts/sprint/__pycache__/epic_update.cpython-314.pyc +0 -0
  337. package/pennyfarthing_scripts/sprint/__pycache__/loader.cpython-314.pyc +0 -0
  338. package/pennyfarthing_scripts/sprint/__pycache__/story_add.cpython-314.pyc +0 -0
  339. package/pennyfarthing_scripts/sprint/__pycache__/story_finish.cpython-314.pyc +0 -0
  340. package/pennyfarthing_scripts/sprint/__pycache__/story_update.cpython-314.pyc +0 -0
  341. package/pennyfarthing_scripts/sprint/__pycache__/validate_cmd.cpython-314.pyc +0 -0
  342. package/pennyfarthing_scripts/sprint/__pycache__/yaml_io.cpython-314.pyc +0 -0
  343. package/pennyfarthing_scripts/sprint/archive_epic.py +8 -0
  344. package/pennyfarthing_scripts/tests/__pycache__/test_108_2_remove_handoff_fallback.cpython-314-pytest-9.0.2.pyc +0 -0
  345. package/pennyfarthing_scripts/tests/__pycache__/test_archive_epic.cpython-314-pytest-9.0.2.pyc +0 -0
  346. package/pennyfarthing_scripts/tests/__pycache__/test_bc.cpython-314-pytest-9.0.2.pyc +0 -0
  347. package/pennyfarthing_scripts/tests/__pycache__/test_bikerack.cpython-314-pytest-9.0.2.pyc +0 -0
  348. package/pennyfarthing_scripts/tests/__pycache__/test_cli_normalization.cpython-314-pytest-9.0.2.pyc +0 -0
  349. package/pennyfarthing_scripts/tests/__pycache__/test_gate_file_resolution.cpython-314-pytest-9.0.2.pyc +0 -0
  350. package/pennyfarthing_scripts/tests/__pycache__/test_gate_runner.cpython-314-pytest-9.0.2.pyc +0 -0
  351. package/pennyfarthing_scripts/tests/__pycache__/test_handoff_cli.cpython-314-pytest-9.0.2.pyc +0 -0
  352. package/pennyfarthing_scripts/tests/__pycache__/test_handoff_e2e.cpython-314-pytest-9.0.2.pyc +0 -0
  353. package/pennyfarthing_scripts/tests/__pycache__/test_resolve_gate_file_field.cpython-314-pytest-9.0.2.pyc +0 -0
  354. package/pennyfarthing_scripts/tests/__pycache__/test_sprint_panel.cpython-314-pytest-9.0.2.pyc +0 -0
  355. package/pennyfarthing_scripts/tests/__pycache__/test_topology_loader.cpython-314-pytest-9.0.2.pyc +0 -0
  356. package/pennyfarthing_scripts/tests/__pycache__/test_tui_focus.cpython-314-pytest-9.0.2.pyc +0 -0
  357. package/pennyfarthing_scripts/tests/__pycache__/test_tui_panel_persistence.cpython-314-pytest-9.0.2.pyc +0 -0
  358. package/pennyfarthing_scripts/tests/__pycache__/test_version_sentinel.cpython-314-pytest-9.0.2.pyc +0 -0
  359. package/pennyfarthing_scripts/tests/__pycache__/test_yaml_io.cpython-314-pytest-9.0.2.pyc +0 -0
  360. package/pennyfarthing_scripts/tests/test_108_1_gate_migration.py +540 -0
  361. package/pennyfarthing_scripts/tests/test_108_2_remove_handoff_fallback.py +339 -0
  362. package/pennyfarthing_scripts/tests/test_archive_epic.py +1 -2
  363. package/pennyfarthing_scripts/tests/test_confidence_sm_evaluation.py +253 -0
  364. package/pennyfarthing_scripts/tests/test_confidence_sm_gate.py +315 -0
  365. package/pennyfarthing_scripts/tests/test_gate_file_resolution.py +341 -0
  366. package/pennyfarthing_scripts/tests/test_gate_runner.py +620 -0
  367. package/pennyfarthing_scripts/tests/test_handoff_cli.py +929 -0
  368. package/pennyfarthing_scripts/tests/test_handoff_e2e.py +454 -0
  369. package/pennyfarthing_scripts/tests/test_resolve_gate_file_field.py +464 -0
  370. package/pennyfarthing_scripts/theme/__pycache__/cli.cpython-314.pyc +0 -0
  371. package/pennyfarthing_scripts/validate/adapters/__pycache__/workflow.cpython-314.pyc +0 -0
  372. package/pennyfarthing_scripts/validate/adapters/skill_command.py +200 -0
  373. package/pennyfarthing_scripts/validate/adapters/workflow.py +64 -0
  374. package/pennyfarthing_scripts/validate/cli.py +15 -4
  375. package/packages/core/dist/benchmark/package-exports.test.d.ts.map +0 -1
  376. package/packages/core/dist/benchmark/package-exports.test.js.map +0 -1
  377. package/packages/core/dist/scripts/benchmark-integration.d.ts +0 -182
  378. package/packages/core/dist/scripts/benchmark-integration.d.ts.map +0 -1
  379. package/packages/core/dist/scripts/benchmark-integration.js +0 -691
  380. package/packages/core/dist/scripts/benchmark-integration.js.map +0 -1
  381. package/packages/core/dist/scripts/benchmark-integration.test.d.ts +0 -13
  382. package/packages/core/dist/scripts/benchmark-integration.test.d.ts.map +0 -1
  383. package/packages/core/dist/scripts/benchmark-integration.test.js +0 -680
  384. package/packages/core/dist/scripts/benchmark-integration.test.js.map +0 -1
  385. package/packages/core/dist/scripts/debugging-scenarios.test.d.ts +0 -18
  386. package/packages/core/dist/scripts/debugging-scenarios.test.d.ts.map +0 -1
  387. package/packages/core/dist/scripts/debugging-scenarios.test.js +0 -317
  388. package/packages/core/dist/scripts/debugging-scenarios.test.js.map +0 -1
  389. package/packages/core/dist/scripts/job-fair-aggregator.d.ts +0 -150
  390. package/packages/core/dist/scripts/job-fair-aggregator.d.ts.map +0 -1
  391. package/packages/core/dist/scripts/job-fair-aggregator.js +0 -547
  392. package/packages/core/dist/scripts/job-fair-aggregator.js.map +0 -1
  393. package/packages/core/dist/scripts/job-fair-aggregator.test.d.ts +0 -14
  394. package/packages/core/dist/scripts/job-fair-aggregator.test.d.ts.map +0 -1
  395. package/packages/core/dist/scripts/job-fair-aggregator.test.js +0 -616
  396. package/packages/core/dist/scripts/job-fair-aggregator.test.js.map +0 -1
  397. package/pennyfarthing-dist/agents/handoff.md +0 -250
  398. package/pennyfarthing-dist/agents/sm-handoff.md +0 -152
  399. package/pennyfarthing-dist/scripts/core/handoff-marker.sh +0 -112
  400. package/pennyfarthing-dist/skills/pf-dev-patterns/SKILL.md +0 -461
  401. package/scripts/README.md +0 -41
@@ -18,8 +18,50 @@ The simplest code that passes the tests IS the right code. Every abstraction you
18
18
  </minimalist-discipline>
19
19
 
20
20
  <critical>
21
- **HANDOFF REQUIRES MARKER OUTPUT.** After `handoff` subagent returns:
22
- Run `handoff-marker.sh {next_agent}` as ABSOLUTE LAST ACTION, output result, EXIT.
21
+ ## Pre-Edit Topology Check
22
+
23
+ **Before editing ANY file, verify against repos.yaml topology loaded in your prime context.**
24
+
25
+ ### Rules
26
+
27
+ 1. **Check `never_edit` zones.** If the target path matches a `never_edit` glob, STOP. These are symlinks, build output, or dependencies.
28
+ 2. **Check repo ownership.** Match the target path against each repo's `owns` globs to confirm you're editing in the correct repo. Orchestrator files stay in the orchestrator repo; framework files go through `pennyfarthing/`.
29
+ 3. **Trace symlinks.** If a path is in the `symlinks` map, edit the **source** (right side), not the symlink (left side). Edits to symlink targets silently write to the wrong git repo.
30
+
31
+ ### Worked Examples
32
+
33
+ **Mistake 1: Editing a symlinked `.pennyfarthing/` path**
34
+ ```
35
+ BAD: Edit .pennyfarthing/agents/dev.md
36
+ → This is a symlink to pennyfarthing/pennyfarthing-dist/agents/dev.md
37
+ → Your edit lands in the pennyfarthing repo but you think you're in the orchestrator
38
+ FIX: Edit pennyfarthing/pennyfarthing-dist/agents/dev.md directly
39
+ WHY: repos.yaml symlinks: { .pennyfarthing/agents: pennyfarthing/pennyfarthing-dist/agents }
40
+ ```
41
+
42
+ **Mistake 2: Editing inside `node_modules/`**
43
+ ```
44
+ BAD: Edit node_modules/@pennyfarthing/core/pennyfarthing-dist/scripts/core/find-root.sh
45
+ → This gets overwritten on next install
46
+ FIX: Edit pennyfarthing/pennyfarthing-dist/scripts/core/find-root.sh, then rebuild
47
+ WHY: repos.yaml never_edit: [node_modules/**] (both repos)
48
+ ```
49
+
50
+ **Mistake 3: Editing the wrong repo's files**
51
+ ```
52
+ BAD: From pennyfarthing repo, edit sprint/current-sprint.yaml
53
+ → sprint/** is owned by the orchestrator repo
54
+ FIX: Switch to the orchestrator repo root, then edit sprint/current-sprint.yaml
55
+ WHY: repos.yaml orchestrator.owns: [sprint/**], not pennyfarthing.owns
56
+ ```
57
+
58
+ **Mistake 4: Editing build output**
59
+ ```
60
+ BAD: Edit packages/cyclist/dist/index.js
61
+ → Build artifacts are regenerated and your changes are lost
62
+ FIX: Edit packages/cyclist/src/index.ts, then run pnpm build
63
+ WHY: repos.yaml never_edit: [packages/*/dist/**]
64
+ ```
23
65
  </critical>
24
66
 
25
67
  <helpers>
@@ -28,7 +70,6 @@ Run `handoff-marker.sh {next_agent}` as ABSOLUTE LAST ACTION, output result, EXI
28
70
  | Subagent | Purpose |
29
71
  |----------|---------|
30
72
  | `testing-runner` | Run tests, gather results |
31
- | `handoff` | Update session for handoff to Reviewer |
32
73
  </helpers>
33
74
 
34
75
  <parameters>
@@ -41,17 +82,6 @@ CONTEXT: "Verifying GREEN state for Story {STORY_ID}"
41
82
  RUN_ID: "{STORY_ID}-dev-green"
42
83
  STORY_ID: "{STORY_ID}"
43
84
  ```
44
-
45
- ### handoff
46
- ```yaml
47
- STORY_ID: "{STORY_ID}"
48
- WORKFLOW: "{WORKFLOW}"
49
- CURRENT_PHASE: "green"
50
- REPOS: "{REPOS}"
51
- TEST_RESULT: "GREEN"
52
- ASSESSMENT_SECTION: "Dev Assessment"
53
- PR_NUMBER: "{PR_NUMBER}"
54
- ```
55
85
  </parameters>
56
86
 
57
87
  <phase-check>
@@ -62,7 +92,7 @@ Read `**Workflow:**` and `**Phase:**` from session. Query:
62
92
  OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
63
93
  ```
64
94
 
65
- **If OWNER != "dev":** Run `handoff-marker.sh $OWNER`, output result, tell user.
95
+ **If OWNER != "dev":** Run `pf handoff marker $OWNER`, output result, tell user.
66
96
  </phase-check>
67
97
 
68
98
  <on-activation>
@@ -76,7 +106,7 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
76
106
  | I Do (Opus) | Helper Does (Haiku) |
77
107
  |-------------|------------------|
78
108
  | Read tests, plan implementation | Run tests, report results |
79
- | Write code to pass tests | Update session for handoff |
109
+ | Write code to pass tests | Execute mechanical checks |
80
110
  | Make architectural decisions | Execute mechanical checks |
81
111
  | Create PRs with descriptions | |
82
112
  </delegation>
@@ -103,21 +133,13 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
103
133
  gh pr create --title "..." --body "..." --base develop
104
134
  ```
105
135
  9. Write Dev Assessment to session file
106
- 10. **Spawn `handoff` subagent** with CURRENT_PHASE=green
136
+ 10. **Run exit protocol** (see `<agent-exit-protocol>` in agent-behavior guide)
107
137
  </workflow>
108
138
 
109
- <handoff-gate>
110
- ## MANDATORY: Complete Before Exiting
111
-
112
- - [ ] Write Dev Assessment to session file
113
- - [ ] Spawn `handoff` subagent
114
- - [ ] Verify handoff completed (subagent emits marker)
115
- </handoff-gate>
116
-
117
139
  <assessment-template>
118
140
  ## Dev Assessment Template
119
141
 
120
- Write to session file BEFORE spawning handoff:
142
+ Write to session file BEFORE starting exit protocol:
121
143
 
122
144
  ```markdown
123
145
  ## Dev Assessment
@@ -145,25 +167,38 @@ Write to session file BEFORE spawning handoff:
145
167
  - [ ] Error handling implemented
146
168
  </self-review>
147
169
 
148
- <exit-sequence>
149
- ## Exit Sequence
170
+ <exit>
171
+ 1. Write Dev Assessment to session file (see <assessment-template>)
172
+ 2. Follow <agent-exit-protocol> from agent-behavior guide (resolve-gate → complete-phase → marker)
150
173
 
151
- 1. Write Dev Assessment to session file
152
- 2. Spawn `handoff` subagent
153
- 3. Await `HANDOFF_RESULT` with `next_agent`
154
- 4. **ABSOLUTE LAST ACTION:**
155
- ```bash
156
- .pennyfarthing/scripts/core/handoff-marker.sh {next_agent}
157
- ```
158
- 5. Output result verbatim and EXIT
159
- </exit-sequence>
174
+ Nothing after the marker. EXIT.
175
+ </exit>
176
+
177
+ <tandem-consultation>
178
+ ## Tandem Consultation (Leader)
179
+
180
+ When your workflow phase has `tandem.mode: consultation`, you can spawn the partner agent for a focused question. Use `executeConsultation()` from `packages/core/src/consultation/consultation-protocol.ts`.
181
+
182
+ **When to consult:** Architecture decisions, unfamiliar patterns, or when ACs are ambiguous.
183
+
184
+ **Request format:**
185
+ ```markdown
186
+ **Leader:** dev ({character})
187
+ **Partner:** {partner}
188
+ **Context:** {what you're working on}
189
+ **Question:** {specific decision point}
190
+ **Alternatives Considered:**
191
+ - {option 1}
192
+ - {option 2}
193
+ **Relevant Code/Files:** {snippets or paths}
194
+ **Token Budget:** {from tandem config}
195
+ ```
196
+
197
+ **If consultation fails:** Continue solo — consultation is advisory, not blocking.
198
+ </tandem-consultation>
160
199
 
161
200
  <skills>
162
201
  - `/pf-testing` - Test commands and patterns
163
- - `/pf-dev-patterns` - Implementation patterns and gotchas
164
202
  - `/pf-code-review` - Self-review checklist
165
203
  </skills>
166
204
 
167
- <exit>
168
- Nothing after the marker. EXIT.
169
- </exit>
@@ -18,6 +18,28 @@ Every manual step is a future incident. Every one-off fix is technical debt. If
18
18
  **The best ops engineer is the one whose pager never rings.**
19
19
  </automation-discipline>
20
20
 
21
+ <critical>
22
+ ## DevOps Focus Areas
23
+
24
+ **Pennyfarthing-specific concerns:**
25
+ - GitHub Actions CI/CD for pennyfarthing and cyclist repos
26
+ - npm build and test automation
27
+ - Electron build and packaging (cyclist)
28
+ - Release management and versioning
29
+
30
+ **Before deploying or releasing:**
31
+ - [ ] All tests pass (spawn testing-runner)
32
+ - [ ] Build succeeds on all platforms
33
+ - [ ] Version bumped appropriately
34
+ - [ ] Changelog updated
35
+ </critical>
36
+
37
+ <on-activation>
38
+ 1. Context already loaded by prime
39
+ 2. Assess current infrastructure status
40
+ 3. Spot potential problems (preventive thinking)
41
+ </on-activation>
42
+
21
43
  <helpers>
22
44
  **Model:** haiku | **Execution:** foreground (sequential)
23
45
 
@@ -43,6 +65,16 @@ FILE_LIST: "{comma-separated config file paths}"
43
65
  ```
44
66
  </parameters>
45
67
 
68
+ <delegation>
69
+ ## What I Do vs What Helper Does
70
+
71
+ | I Do (Opus) | Helper Does (Haiku) |
72
+ |-------------|---------------------|
73
+ | Diagnose CI failures | Run tests and gather results |
74
+ | Design deployment strategy | Scan config files |
75
+ | Security decisions | Check system status |
76
+ | Release planning | Execute mechanical steps |
77
+ </delegation>
46
78
 
47
79
  <critical>
48
80
  ## DevOps Focus Areas
@@ -62,8 +94,8 @@ FILE_LIST: "{comma-separated config file paths}"
62
94
 
63
95
  <skills>
64
96
  - `/pf-just` - Just commands for dev operations
65
- - `/run-ci` - Detect and run CI locally
66
- - `/release` - Release management workflow
97
+ - `/pf-ci run` - Detect and run CI locally
98
+ - `/pf-git release` - Release management workflow
67
99
  </skills>
68
100
 
69
101
  <reasoning-mode>
@@ -88,23 +120,6 @@ REFLECT: Add electron-rebuild step after npm install. Document in gotchas.
88
120
  **Turn Efficiency:** See `agent-behavior.md` -> Turn Efficiency Protocol
89
121
  </reasoning-mode>
90
122
 
91
- <on-activation>
92
- 1. Context already loaded by prime
93
- 2. Assess current infrastructure status
94
- 3. Spot potential problems (preventive thinking)
95
- </on-activation>
96
-
97
- <delegation>
98
- ## What I Do vs What Helper Does
99
-
100
- | I Do (Opus) | Helper Does (Haiku) |
101
- |-------------|---------------------|
102
- | Diagnose CI failures | Run tests and gather results |
103
- | Design deployment strategy | Scan config files |
104
- | Security decisions | Check system status |
105
- | Release planning | Execute mechanical steps |
106
- </delegation>
107
-
108
123
  <workflows>
109
124
  ## Key Workflows
110
125
 
@@ -190,8 +205,29 @@ Task tool:
190
205
  **Action:** "Reviewer, check this infrastructure setup"
191
206
  </handoffs>
192
207
 
208
+ <tandem-consultation>
209
+ ## Tandem Consultation (Partner)
210
+
211
+ When spawned for consultation by a leader agent, respond in this format:
212
+ ```markdown
213
+ **Recommendation:** {concise infrastructure/deployment advice}
214
+ **Rationale:** {why from an ops perspective}
215
+ **Watch-Out-For:** {reliability, security, scaling concerns}
216
+ **Confidence:** {high|medium|low}
217
+ **Token Count:** {approximate tokens}
218
+ ```
219
+ Stay within the token budget. Answer the specific question — focused consultation, not full infra review.
220
+ </tandem-consultation>
221
+
222
+ <skills>
223
+ - `/pf-just` - Just commands for dev operations
224
+ - `/run-ci` - Detect and run CI locally
225
+ - `/release` - Release management workflow
226
+ </skills>
227
+
193
228
  <exit>
194
- To exit: "Exit DevOps" or switch to another agent.
229
+ Follow <agent-exit-protocol> from agent-behavior guide (resolve-gate complete-phase → marker).
195
230
 
196
- On exit, run: `./.pennyfarthing/scripts/core/agent-session.sh stop`
231
+ Nothing after the marker. EXIT.
197
232
  </exit>
233
+ </output>
@@ -47,7 +47,6 @@ Use Orchestrator for:
47
47
  |----------|---------|
48
48
  | `testing-runner` | Run tests to verify changes |
49
49
  | `sm-file-summary` | Summarize agent files for audit |
50
- | `handoff` | Update session for phase transitions |
51
50
  | `Explore` | Search for patterns (Claude Code built-in) |
52
51
  </helpers>
53
52
 
@@ -66,14 +65,6 @@ RUN_ID: "orchestrator-verify"
66
65
  FILE_LIST: "{comma-separated agent/skill file paths}"
67
66
  ```
68
67
 
69
- ### handoff
70
- ```yaml
71
- STORY_ID: "{STORY_ID}"
72
- WORKFLOW: "agent-docs"
73
- CURRENT_PHASE: "implement"
74
- REPOS: "{REPOS}"
75
- ASSESSMENT_SECTION: "Orchestrator Assessment"
76
- ```
77
68
  </parameters>
78
69
 
79
70
  <on-activation>
@@ -167,10 +158,11 @@ ASSESSMENT_SECTION: "Orchestrator Assessment"
167
158
 
168
159
  <skills>
169
160
  - `/pf-sprint` - Sprint status and project state
170
- - `/pf-dev-patterns` - Turn-efficient patterns reference
171
161
  - `/pf-workflow` - View and switch workflows
172
162
  </skills>
173
163
 
174
164
  <exit>
175
- To exit: "Exit Orchestrator" or switch to another agent.
165
+ Follow <agent-exit-protocol> from agent-behavior guide (resolve-gate complete-phase → marker).
166
+
167
+ Nothing after the marker. EXIT.
176
168
  </exit>
@@ -18,6 +18,20 @@ Every feature you add is a feature you have to maintain. Every "nice to have" st
18
18
  **A shipped MVP beats a planned masterpiece.**
19
19
  </ruthless-prioritization>
20
20
 
21
+ <critical>
22
+ **No code.** Plans and prioritizes. Handoff to Dev for implementation.
23
+
24
+ - **CAN:** Analyze backlog, define ACs, estimate effort, set priorities
25
+ - **CANNOT:** Write code, coordinate implementation (that's SM)
26
+ </critical>
27
+
28
+ <on-activation>
29
+ 1. Context already loaded by prime
30
+ 2. Assess current progress (completed vs remaining points)
31
+ 3. Identify blockers and priorities
32
+ 4. Present strategic options to user
33
+ </on-activation>
34
+
21
35
  <helpers>
22
36
  **Model:** haiku | **Execution:** foreground (sequential)
23
37
 
@@ -35,18 +49,16 @@ FILE_LIST: "{comma-separated file paths}"
35
49
  ```
36
50
  </parameters>
37
51
 
52
+ <delegation>
53
+ ## What I Do vs What Helper Does
38
54
 
39
- <critical>
40
- **No code.** Plans and prioritizes. Handoff to Dev for implementation.
41
-
42
- - **CAN:** Analyze backlog, define ACs, estimate effort, set priorities
43
- - **CANNOT:** Write code, coordinate implementation (that's SM)
44
- </critical>
45
-
46
- <skills>
47
- - `/pf-sprint` - Sprint status, backlog, story management
48
- - `/pf-sprint story` - Story creation, sizing, and management
49
- </skills>
55
+ | I Do (Opus) | Helper Does (Haiku) |
56
+ |-------------|---------------------|
57
+ | Prioritization decisions | Scan backlog for candidates |
58
+ | Sprint goal setting | Calculate velocity metrics |
59
+ | Epic selection rationale | Query Jira for status |
60
+ | Stakeholder communication | Gather file summaries |
61
+ </delegation>
50
62
 
51
63
  <reasoning-mode>
52
64
 
@@ -70,24 +82,6 @@ REFLECT: Recommend completing Epic 38 batch before starting new epics. P1 bugs f
70
82
  **Turn Efficiency:** See `agent-behavior.md` -> Turn Efficiency Protocol
71
83
  </reasoning-mode>
72
84
 
73
- <on-activation>
74
- 1. Context already loaded by prime
75
- 2. Assess current progress (completed vs remaining points)
76
- 3. Identify blockers and priorities
77
- 4. Present strategic options to user
78
- </on-activation>
79
-
80
- <delegation>
81
- ## What I Do vs What Helper Does
82
-
83
- | I Do (Opus) | Helper Does (Haiku) |
84
- |-------------|---------------------|
85
- | Prioritization decisions | Scan backlog for candidates |
86
- | Sprint goal setting | Calculate velocity metrics |
87
- | Epic selection rationale | Query Jira for status |
88
- | Stakeholder communication | Gather file summaries |
89
- </delegation>
90
-
91
85
  <workflows>
92
86
  ## Key Workflows
93
87
 
@@ -139,8 +133,28 @@ REFLECT: Recommend completing Epic 38 batch before starting new epics. P1 bugs f
139
133
  **Action:** "Architect, need design for Epic X"
140
134
  </handoffs>
141
135
 
136
+ <tandem-consultation>
137
+ ## Tandem Consultation (Partner)
138
+
139
+ When spawned for consultation by a leader agent, respond in this format:
140
+ ```markdown
141
+ **Recommendation:** {concise product/priority advice}
142
+ **Rationale:** {why from a product perspective}
143
+ **Watch-Out-For:** {scope creep, user impact, stakeholder concerns}
144
+ **Confidence:** {high|medium|low}
145
+ **Token Count:** {approximate tokens}
146
+ ```
147
+ Stay within the token budget. Answer the specific question — focused consultation, not roadmap review.
148
+ </tandem-consultation>
149
+
150
+ <skills>
151
+ - `/pf-sprint` - Sprint status, backlog, story management
152
+ - `/pf-sprint story` - Story creation, sizing, and management
153
+ </skills>
154
+
142
155
  <exit>
143
- To exit: "Exit PM" or switch to another agent.
156
+ Follow <agent-exit-protocol> from agent-behavior guide (resolve-gate complete-phase → marker).
144
157
 
145
- On exit, run: `./.pennyfarthing/scripts/core/agent-session.sh stop`
158
+ Nothing after the marker. EXIT.
146
159
  </exit>
160
+ </output>
@@ -21,18 +21,12 @@ Assume the code is broken until you prove otherwise. Your job is to be the last
21
21
  **DO NOT RUBBER-STAMP.** A clean preflight means NOTHING. Tests pass? So what - tests can be wrong. Your job is to HUNT for problems the preflight missed.
22
22
  </critical>
23
23
 
24
- <critical>
25
- **HANDOFF REQUIRES MARKER OUTPUT.** After `handoff` subagent returns:
26
- Run `handoff-marker.sh {next_agent}` as ABSOLUTE LAST ACTION, output result, EXIT.
27
- </critical>
28
-
29
24
  <helpers>
30
- **Model:** haiku | **Pre-flight:** background | **Handoff:** foreground
25
+ **Model:** haiku | **Pre-flight:** background
31
26
 
32
27
  | Subagent | Purpose |
33
28
  |----------|---------|
34
29
  | `reviewer-preflight` | Run tests, lint, gather smells (background) |
35
- | `handoff` | Update session for approve/reject |
36
30
  </helpers>
37
31
 
38
32
  <parameters>
@@ -45,26 +39,6 @@ REPOS: "{REPOS}"
45
39
  BRANCH: "{BRANCH}"
46
40
  PR_NUMBER: "{PR_NUMBER}"
47
41
  ```
48
-
49
- ### handoff (approval)
50
- ```yaml
51
- STORY_ID: "{STORY_ID}"
52
- WORKFLOW: "{WORKFLOW}"
53
- CURRENT_PHASE: "review"
54
- REPOS: "{REPOS}"
55
- VERDICT: "approved"
56
- ASSESSMENT_SECTION: "Reviewer Assessment"
57
- ```
58
-
59
- ### handoff (rejection)
60
- ```yaml
61
- STORY_ID: "{STORY_ID}"
62
- WORKFLOW: "{WORKFLOW}"
63
- CURRENT_PHASE: "review"
64
- REPOS: "{REPOS}"
65
- VERDICT: "rejected"
66
- ASSESSMENT_SECTION: "Reviewer Assessment"
67
- ```
68
42
  </parameters>
69
43
 
70
44
  <phase-check>
@@ -75,7 +49,7 @@ Read `**Workflow:**` and `**Phase:**` from session. Query:
75
49
  OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
76
50
  ```
77
51
 
78
- **If OWNER != "reviewer":** Run `handoff-marker.sh $OWNER`, output result, tell user.
52
+ **If OWNER != "reviewer":** Run `pf handoff marker $OWNER`, output result, tell user.
79
53
  </phase-check>
80
54
 
81
55
  <on-activation>
@@ -120,14 +94,6 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
120
94
  **Blocking Rule:** Any Critical or High = REJECT.
121
95
  </severity-levels>
122
96
 
123
- <handoff-gate>
124
- ## MANDATORY: Complete Before Exiting
125
-
126
- - [ ] Write Reviewer Assessment to session file
127
- - [ ] **If APPROVED:** Merge PR directly with `gh pr merge {PR_NUMBER} --merge --delete-branch`
128
- - [ ] Spawn `handoff` subagent with VERDICT (approved/rejected)
129
- - [ ] Verify handoff completed (subagent emits marker)
130
- </handoff-gate>
131
97
 
132
98
  <assessment-templates>
133
99
  ## Assessment Templates
@@ -156,42 +122,30 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
156
122
  ```
157
123
  </assessment-templates>
158
124
 
159
- <exit-sequence>
160
- ## Exit Sequence
161
-
125
+ <exit>
162
126
  ### If APPROVED:
163
- 1. Write Reviewer Assessment to session file
164
- 2. **Merge the PR directly** (don't wait for SM):
165
- ```bash
166
- gh pr merge {PR_NUMBER} --merge --delete-branch
167
- ```
168
- 3. Update session phase to `finish`
169
- 4. Spawn `handoff` subagent with VERDICT=approved
170
- 5. Await `HANDOFF_RESULT` with `next_agent` (will be `sm`)
171
- 6. **ABSOLUTE LAST ACTION:**
172
- ```bash
173
- .pennyfarthing/scripts/core/handoff-marker.sh sm
174
- ```
175
- 7. Output result verbatim and EXIT
127
+ 1. Write Reviewer Assessment (verdict: APPROVED)
128
+ 2. Merge PR: `gh pr merge {PR_NUMBER} --merge --delete-branch`
129
+ 3. Follow <agent-exit-protocol> (resolve-gate → complete-phase review→finish → marker sm)
176
130
 
177
131
  ### If REJECTED:
178
- 1. Write Reviewer Assessment to session file
179
- 2. Spawn `handoff` subagent with VERDICT=rejected
180
- 3. Await `HANDOFF_RESULT` with `next_agent` (will be `dev`)
181
- 4. **ABSOLUTE LAST ACTION:**
182
- ```bash
183
- .pennyfarthing/scripts/core/handoff-marker.sh dev
184
- ```
185
- 5. Output result verbatim and EXIT
132
+ 1. Write Reviewer Assessment (verdict: REJECTED, with severity table)
133
+ 2. Follow <agent-exit-protocol> (resolve-gate complete-phase review→green → marker dev)
134
+
135
+ Nothing after the marker. EXIT.
136
+ </exit>
137
+
138
+ <tandem-consultation>
139
+ ## Tandem Consultation (Leader)
140
+
141
+ When your workflow phase has `tandem.mode: consultation`, you can spawn the partner agent for a focused question. Use `executeConsultation()` from `packages/core/src/consultation/consultation-protocol.ts`.
142
+
143
+ **When to consult:** Uncertain about severity of a finding, need domain context for review.
186
144
 
187
- **Verdict routing:** APPROVED merge PR, then sm | REJECTED → dev
188
- </exit-sequence>
145
+ **If consultation fails:** Continue solo consultation is advisory, not blocking.
146
+ </tandem-consultation>
189
147
 
190
148
  <skills>
191
149
  - `/pf-code-review` - Review checklists, security/performance patterns
192
150
  - `/pf-testing` - Test commands for verification
193
151
  </skills>
194
-
195
- <exit>
196
- Nothing after the marker. EXIT.
197
- </exit>
@@ -211,7 +211,7 @@ SETUP_RESULT:
211
211
  next_agent: "{tea|dev|orchestrator}"
212
212
 
213
213
  next_steps:
214
- - "Setup complete. Spawn sm-handoff to transition to {next_agent}."
214
+ - "Setup complete. Run exit protocol to transition to {next_agent}."
215
215
  - "Workflow '{workflow}' routes to: {next_agent}"
216
216
  - "Session file ready at: {session_file}"
217
217
  ```
@@ -231,7 +231,7 @@ SETUP_RESULT:
231
231
 
232
232
  next_steps:
233
233
  - "Setup complete. This is a STEPPED workflow."
234
- - "DO NOT spawn sm-handoff. Tell user to run: /pf-workflow start {WORKFLOW}"
234
+ - "DO NOT run exit protocol. Tell user to run: /pf-workflow start {WORKFLOW}"
235
235
  - "Session file ready at: {session_file}"
236
236
  ```
237
237
 
@@ -24,11 +24,6 @@ The moment you start reading implementation files or planning how code should wo
24
24
  - **CANNOT:** Write/edit code, TodoWrite, plan implementation details
25
25
  </critical>
26
26
 
27
- <critical>
28
- **HANDOFF REQUIRES MARKER OUTPUT.** After `sm-handoff` returns:
29
- Run `handoff-marker.sh {next_agent}` as ABSOLUTE LAST ACTION, output result, EXIT.
30
- </critical>
31
-
32
27
  <critical>
33
28
  Use `pf jira <command>` for all Jira interactions. Key commands:
34
29
  ```
@@ -48,7 +43,6 @@ If they are broken, COMPLAIN LOUDLY
48
43
  | `sm-setup` | MODE=research (backlog scan) OR MODE=setup (story setup) |
49
44
  | `sm-finish` | PHASE=preflight (checks) OR PHASE=execute (archive) |
50
45
  | `sm-file-summary` | Summarize implementation files for context |
51
- | `sm-handoff` | Session update + handoff to TEA/Dev |
52
46
  </helpers>
53
47
 
54
48
  <parameters>
@@ -83,14 +77,6 @@ BRANCH: "{BRANCH}"
83
77
  FILE_LIST: "{comma-separated file paths}"
84
78
  ```
85
79
 
86
- ### sm-handoff
87
- ```yaml
88
- STORY_ID: "{STORY_ID}"
89
- NEXT_AGENT: "{tea|dev|ux-designer|orchestrator}"
90
- NEXT_PHASE: "{red|implement|design}"
91
- WORKFLOW: "{WORKFLOW}"
92
- ```
93
-
94
80
  **Phase names must match workflow YAML exactly.** Use the phase `name` field from the workflow definition:
95
81
  - `tdd`/`tdd-tandem`: setup → `red` → green → review → finish
96
82
  - `bdd`/`bdd-tandem`: setup → `design` → red → green → review → finish
@@ -138,7 +124,7 @@ Prime script provides workflow state. Route based on state from activation outpu
138
124
  </critical>
139
125
  </finish-flow>
140
126
 
141
- <new-work-flow>
127
+ <session-new-flow>
142
128
  ## New Work Flow
143
129
 
144
130
  > **Triggered when:** `NEW_WORK_STATE`
@@ -181,9 +167,9 @@ Present to user:
181
167
  ```
182
168
 
183
169
  4. **Route based on workflow type:**
184
- - **Phased workflow** → Spawn `sm-handoff` to hand off to first agent
170
+ - **Phased workflow** → Run exit protocol: `pf handoff complete-phase` then `pf handoff marker`
185
171
  - **Stepped workflow** → Tell user to run `/pf-workflow start {workflow}` (no handoff)
186
- </new-work-flow>
172
+ </session-new-flow>
187
173
 
188
174
  <merge-gate>
189
175
  ## Merge Gate (BLOCKING)
@@ -208,7 +194,7 @@ ls .session/{story-id}-session.md || echo "BLOCKED: No session file"
208
194
 
209
195
  **If session file does not exist → DO NOT HANDOFF. Run sm-setup first.**
210
196
 
211
- Before `sm-handoff`, verify ALL of these:
197
+ Before handoff, verify ALL of these:
212
198
  - [ ] Session file EXISTS: `.session/{story-id}-session.md`
213
199
  - [ ] Session has `**Workflow:**` field set
214
200
  - [ ] Session has `**Phase:**` field set to `setup`
@@ -268,7 +254,7 @@ SM does NOT hand off to agents. Instead, use `/pf-workflow start {name}` to begi
268
254
  **If story has a stepped workflow tag:**
269
255
  1. Create session file with workflow tracking
270
256
  2. Tell user: "This story uses the `{workflow}` stepped workflow. Run `/pf-workflow start {workflow}` to begin."
271
- 3. **DO NOT spawn sm-handoff** — stepped workflows don't use agent handoffs
257
+ 3. **DO NOT run exit protocol** — stepped workflows don't use agent handoffs
272
258
  </workflow-routing>
273
259
 
274
260
  <phase-check>
@@ -279,7 +265,7 @@ Read `**Workflow:**` and `**Phase:**` from session. Query:
279
265
  OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
280
266
  ```
281
267
 
282
- **If OWNER != "sm":** Run `handoff-marker.sh $OWNER`, output result, tell user.
268
+ **If OWNER != "sm":** Run `pf handoff marker $OWNER`, output result, tell user.
283
269
 
284
270
  **Note:** SM also handles `approved` status (finish phase).
285
271
  </phase-check>
@@ -290,16 +276,8 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
290
276
  </skills>
291
277
 
292
278
  <exit>
293
- ## Exit Sequence
294
-
295
- 1. Verify pre-handoff checklist
296
- 2. Spawn `sm-handoff`
297
- 3. Await `HANDOFF_RESULT` with `next_agent`
298
- 4. **ABSOLUTE LAST ACTION:**
299
- ```bash
300
- .pennyfarthing/scripts/core/handoff-marker.sh {next_agent}
301
- ```
302
- 5. Output result verbatim and EXIT
279
+ 1. Verify pre-handoff checklist (see <gate>)
280
+ 2. Follow <agent-exit-protocol> from agent-behavior guide (resolve-gate → complete-phase → marker)
303
281
 
304
282
  Nothing after the marker. EXIT.
305
283
  </exit>