@pennyfarthing/core 11.0.0 → 11.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (401) hide show
  1. package/README.md +81 -23
  2. package/package.json +1 -1
  3. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.d.ts +20 -0
  4. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.d.ts.map +1 -0
  5. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.js +278 -0
  6. package/packages/core/dist/cli/utils/010-detect-remove-old-packages.test.js.map +1 -0
  7. package/packages/core/dist/cli/utils/constants.d.ts +8 -2
  8. package/packages/core/dist/cli/utils/constants.d.ts.map +1 -1
  9. package/packages/core/dist/cli/utils/constants.js +4 -1
  10. package/packages/core/dist/cli/utils/constants.js.map +1 -1
  11. package/packages/core/dist/cli/utils/constants.test.d.ts +10 -0
  12. package/packages/core/dist/cli/utils/constants.test.d.ts.map +1 -0
  13. package/packages/core/dist/cli/utils/constants.test.js +38 -0
  14. package/packages/core/dist/cli/utils/constants.test.js.map +1 -0
  15. package/packages/core/dist/consultation/consultation-protocol.d.ts +139 -0
  16. package/packages/core/dist/consultation/consultation-protocol.d.ts.map +1 -0
  17. package/packages/core/dist/consultation/consultation-protocol.js +178 -0
  18. package/packages/core/dist/consultation/consultation-protocol.js.map +1 -0
  19. package/packages/core/dist/consultation/consultation-protocol.test.d.ts +20 -0
  20. package/packages/core/dist/consultation/consultation-protocol.test.d.ts.map +1 -0
  21. package/packages/core/dist/consultation/consultation-protocol.test.js +474 -0
  22. package/packages/core/dist/consultation/consultation-protocol.test.js.map +1 -0
  23. package/packages/core/dist/consultation/dialogue-manager.d.ts +75 -0
  24. package/packages/core/dist/consultation/dialogue-manager.d.ts.map +1 -0
  25. package/packages/core/dist/consultation/dialogue-manager.js +334 -0
  26. package/packages/core/dist/consultation/dialogue-manager.js.map +1 -0
  27. package/packages/core/dist/consultation/dialogue-manager.test.d.ts +19 -0
  28. package/packages/core/dist/consultation/dialogue-manager.test.d.ts.map +1 -0
  29. package/packages/core/dist/consultation/dialogue-manager.test.js +444 -0
  30. package/packages/core/dist/consultation/dialogue-manager.test.js.map +1 -0
  31. package/packages/core/dist/public/js/react/react.js +3 -3
  32. package/packages/core/dist/scripts/theme-detail.test.d.ts +10 -0
  33. package/packages/core/dist/scripts/theme-detail.test.js +199 -0
  34. package/packages/core/dist/server/api/git.d.ts +13 -1
  35. package/packages/core/dist/server/api/git.d.ts.map +1 -1
  36. package/packages/core/dist/server/api/git.js +53 -34
  37. package/packages/core/dist/server/api/git.js.map +1 -1
  38. package/packages/core/dist/server/api/health-score.d.ts.map +1 -1
  39. package/packages/core/dist/server/api/health-score.js +25 -1
  40. package/packages/core/dist/server/api/health-score.js.map +1 -1
  41. package/packages/core/dist/server/api/settings.d.ts.map +1 -1
  42. package/packages/core/dist/server/api/settings.js +63 -1
  43. package/packages/core/dist/server/api/settings.js.map +1 -1
  44. package/packages/core/dist/server/api/theme-agents.d.ts.map +1 -1
  45. package/packages/core/dist/server/api/theme-agents.js +61 -0
  46. package/packages/core/dist/server/api/theme-agents.js.map +1 -1
  47. package/packages/core/dist/server/server.d.ts.map +1 -1
  48. package/packages/core/dist/server/server.js +17 -12
  49. package/packages/core/dist/server/server.js.map +1 -1
  50. package/packages/core/dist/shared/skill-search.test.js +2 -2
  51. package/packages/core/dist/workflow/gate-file-validation.d.ts +49 -0
  52. package/packages/core/dist/workflow/gate-file-validation.d.ts.map +1 -0
  53. package/packages/core/dist/workflow/gate-file-validation.js +157 -0
  54. package/packages/core/dist/workflow/gate-file-validation.js.map +1 -0
  55. package/packages/core/dist/workflow/gate-file-validation.test.d.ts +19 -0
  56. package/packages/core/dist/workflow/gate-file-validation.test.d.ts.map +1 -0
  57. package/packages/core/dist/workflow/gate-file-validation.test.js +536 -0
  58. package/packages/core/dist/workflow/gate-file-validation.test.js.map +1 -0
  59. package/packages/core/dist/workflow/gate-schema-validation.test.d.ts +14 -0
  60. package/packages/core/dist/workflow/gate-schema-validation.test.d.ts.map +1 -0
  61. package/packages/core/dist/workflow/gate-schema-validation.test.js +339 -0
  62. package/packages/core/dist/workflow/gate-schema-validation.test.js.map +1 -0
  63. package/packages/core/dist/workflow/handoff.js +2 -2
  64. package/packages/core/dist/workflow/handoff.js.map +1 -1
  65. package/packages/core/dist/workflow/handoff.test.js +16 -0
  66. package/packages/core/dist/workflow/handoff.test.js.map +1 -1
  67. package/packages/core/dist/workflow/workflow-schema.d.ts +4 -2
  68. package/packages/core/dist/workflow/workflow-schema.d.ts.map +1 -1
  69. package/packages/core/dist/workflow/workflow-schema.js +43 -8
  70. package/packages/core/dist/workflow/workflow-schema.js.map +1 -1
  71. package/pennyfarthing-dist/agents/README.md +6 -14
  72. package/pennyfarthing-dist/agents/architect.md +43 -29
  73. package/pennyfarthing-dist/agents/ba.md +30 -29
  74. package/pennyfarthing-dist/agents/dev.md +32 -43
  75. package/pennyfarthing-dist/agents/devops.md +57 -21
  76. package/pennyfarthing-dist/agents/orchestrator.md +3 -10
  77. package/pennyfarthing-dist/agents/pm.md +45 -31
  78. package/pennyfarthing-dist/agents/reviewer.md +20 -66
  79. package/pennyfarthing-dist/agents/sm-setup.md +2 -2
  80. package/pennyfarthing-dist/agents/sm.md +8 -30
  81. package/pennyfarthing-dist/agents/tea.md +25 -41
  82. package/pennyfarthing-dist/agents/tech-writer.md +33 -90
  83. package/pennyfarthing-dist/agents/ux-designer.md +39 -39
  84. package/pennyfarthing-dist/commands/benchmark-control.md +8 -64
  85. package/pennyfarthing-dist/commands/benchmark.md +8 -480
  86. package/pennyfarthing-dist/commands/job-fair.md +8 -97
  87. package/pennyfarthing-dist/commands/pf-benchmark-control.md +70 -0
  88. package/pennyfarthing-dist/commands/pf-benchmark.md +486 -0
  89. package/pennyfarthing-dist/commands/pf-chore.md +4 -4
  90. package/pennyfarthing-dist/commands/pf-ci.md +40 -0
  91. package/pennyfarthing-dist/commands/pf-close-epic.md +9 -27
  92. package/pennyfarthing-dist/commands/pf-continue-session.md +9 -213
  93. package/pennyfarthing-dist/commands/pf-create-branches-from-story.md +11 -353
  94. package/pennyfarthing-dist/commands/pf-docs.md +28 -0
  95. package/pennyfarthing-dist/commands/pf-epic.md +67 -0
  96. package/pennyfarthing-dist/commands/pf-git-cleanup.md +11 -52
  97. package/pennyfarthing-dist/commands/pf-git.md +75 -0
  98. package/pennyfarthing-dist/commands/pf-help.md +110 -128
  99. package/pennyfarthing-dist/commands/pf-job-fair.md +102 -0
  100. package/pennyfarthing-dist/commands/pf-new-work.md +9 -18
  101. package/pennyfarthing-dist/commands/pf-parallel-work.md +6 -66
  102. package/pennyfarthing-dist/commands/pf-release.md +11 -76
  103. package/pennyfarthing-dist/commands/pf-repo-status.md +11 -44
  104. package/pennyfarthing-dist/commands/pf-run-ci.md +8 -111
  105. package/pennyfarthing-dist/commands/pf-session.md +51 -0
  106. package/pennyfarthing-dist/commands/pf-solo.md +447 -0
  107. package/pennyfarthing-dist/commands/pf-sprint-planning.md +8 -104
  108. package/pennyfarthing-dist/commands/pf-standalone.md +1 -1
  109. package/pennyfarthing-dist/commands/pf-start-epic.md +9 -163
  110. package/pennyfarthing-dist/commands/pf-sync-epic-to-jira.md +8 -179
  111. package/pennyfarthing-dist/commands/pf-sync-work-with-sprint.md +8 -368
  112. package/pennyfarthing-dist/commands/pf-update-domain-docs.md +8 -78
  113. package/pennyfarthing-dist/commands/solo.md +8 -442
  114. package/pennyfarthing-dist/guides/agent-behavior.md +13 -13
  115. package/pennyfarthing-dist/guides/agent-coordination.md +7 -7
  116. package/pennyfarthing-dist/guides/agent-tag-taxonomy.md +6 -5
  117. package/pennyfarthing-dist/guides/bikerack.md +128 -0
  118. package/pennyfarthing-dist/guides/brownfield-tools.md +133 -0
  119. package/pennyfarthing-dist/guides/command-tag-taxonomy.md +2 -2
  120. package/pennyfarthing-dist/guides/gate-schema.md +227 -0
  121. package/pennyfarthing-dist/guides/gates.md +120 -0
  122. package/pennyfarthing-dist/guides/handoff-cli.md +116 -0
  123. package/pennyfarthing-dist/guides/hooks.md +86 -4
  124. package/pennyfarthing-dist/guides/output-styles.md +65 -0
  125. package/pennyfarthing-dist/guides/patterns/approval-gates-pattern.md +5 -5
  126. package/pennyfarthing-dist/guides/patterns/tdd-flow-pattern.md +4 -4
  127. package/pennyfarthing-dist/guides/prompt-patterns.md +5 -5
  128. package/pennyfarthing-dist/guides/reflector.md +4 -4
  129. package/pennyfarthing-dist/guides/session-artifacts.md +1 -1
  130. package/pennyfarthing-dist/guides/skill-schema.md +1 -1
  131. package/pennyfarthing-dist/guides/tandem-protocol.md +13 -1
  132. package/pennyfarthing-dist/guides/worktree-mode.md +3 -3
  133. package/pennyfarthing-dist/guides/xml-tags.md +5 -4
  134. package/pennyfarthing-dist/personas/themes/hogans-heroes.yaml +11 -22
  135. package/pennyfarthing-dist/personas/themes/stephen-king.yaml +13 -24
  136. package/pennyfarthing-dist/scripts/core/dialogue-manager.sh +322 -0
  137. package/pennyfarthing-dist/scripts/core/phase-check-start.sh +1 -1
  138. package/pennyfarthing-dist/scripts/hooks/otel-auto-config.sh +19 -14
  139. package/pennyfarthing-dist/scripts/portraits/generate-portraits.py +191 -57
  140. package/pennyfarthing-dist/scripts/portraits/generate-portraits.sh +26 -10
  141. package/pennyfarthing-dist/skills/pf-changelog/SKILL.md +4 -4
  142. package/pennyfarthing-dist/skills/pf-sprint/skill.md +1 -1
  143. package/pennyfarthing-dist/skills/skill-registry.schema.json +4 -0
  144. package/pennyfarthing-dist/skills/skill-registry.yaml +5 -0
  145. package/pennyfarthing-dist/workflows/2party-tdd.yaml +11 -0
  146. package/pennyfarthing-dist/workflows/agent-docs.yaml +2 -0
  147. package/pennyfarthing-dist/workflows/bdd-tandem.yaml +4 -0
  148. package/pennyfarthing-dist/workflows/bdd.yaml +4 -0
  149. package/pennyfarthing-dist/workflows/git-cleanup/steps/step-05-complete.md +1 -1
  150. package/pennyfarthing-dist/workflows/tdd-tandem.yaml +3 -0
  151. package/pennyfarthing-dist/workflows/tdd.yaml +3 -0
  152. package/pennyfarthing-dist/workflows/trivial.yaml +2 -0
  153. package/pennyfarthing_scripts/__pycache__/__init__.cpython-314.pyc +0 -0
  154. package/pennyfarthing_scripts/__pycache__/bellmode_hook.cpython-314.pyc +0 -0
  155. package/pennyfarthing_scripts/__pycache__/cli.cpython-314.pyc +0 -0
  156. package/pennyfarthing_scripts/__pycache__/config.cpython-314.pyc +0 -0
  157. package/pennyfarthing_scripts/__pycache__/context.cpython-314.pyc +0 -0
  158. package/pennyfarthing_scripts/__pycache__/hooks.cpython-314.pyc +0 -0
  159. package/pennyfarthing_scripts/__pycache__/jira_bidirectional_sync.cpython-314.pyc +0 -0
  160. package/pennyfarthing_scripts/__pycache__/jira_epic_creation.cpython-314.pyc +0 -0
  161. package/pennyfarthing_scripts/__pycache__/jira_sync.cpython-314.pyc +0 -0
  162. package/pennyfarthing_scripts/__pycache__/jira_sync_story.cpython-314.pyc +0 -0
  163. package/pennyfarthing_scripts/__pycache__/output.cpython-314.pyc +0 -0
  164. package/pennyfarthing_scripts/__pycache__/patch_mode.cpython-314.pyc +0 -0
  165. package/pennyfarthing_scripts/__pycache__/pretooluse_hook.cpython-314.pyc +0 -0
  166. package/pennyfarthing_scripts/__pycache__/schema_validation_hook.cpython-314.pyc +0 -0
  167. package/pennyfarthing_scripts/__pycache__/session_start_hook.cpython-314.pyc +0 -0
  168. package/pennyfarthing_scripts/__pycache__/workflow.cpython-314.pyc +0 -0
  169. package/pennyfarthing_scripts/bc/__pycache__/__init__.cpython-314.pyc +0 -0
  170. package/pennyfarthing_scripts/bc/__pycache__/cli.cpython-314.pyc +0 -0
  171. package/pennyfarthing_scripts/bc/__pycache__/focus.cpython-314.pyc +0 -0
  172. package/pennyfarthing_scripts/bikerack/__pycache__/__init__.cpython-314.pyc +0 -0
  173. package/pennyfarthing_scripts/bikerack/__pycache__/__main__.cpython-314.pyc +0 -0
  174. package/pennyfarthing_scripts/bikerack/__pycache__/background_panel.cpython-314.pyc +0 -0
  175. package/pennyfarthing_scripts/bikerack/__pycache__/base_panel.cpython-314.pyc +0 -0
  176. package/pennyfarthing_scripts/bikerack/__pycache__/changed_panel.cpython-314.pyc +0 -0
  177. package/pennyfarthing_scripts/bikerack/__pycache__/cli.cpython-314.pyc +0 -0
  178. package/pennyfarthing_scripts/bikerack/__pycache__/debug_panel.cpython-314.pyc +0 -0
  179. package/pennyfarthing_scripts/bikerack/__pycache__/diffs_panel.cpython-314.pyc +0 -0
  180. package/pennyfarthing_scripts/bikerack/__pycache__/git_panel.cpython-314.pyc +0 -0
  181. package/pennyfarthing_scripts/bikerack/__pycache__/launcher.cpython-314.pyc +0 -0
  182. package/pennyfarthing_scripts/bikerack/__pycache__/sprint_panel.cpython-314.pyc +0 -0
  183. package/pennyfarthing_scripts/bikerack/__pycache__/tui.cpython-314.pyc +0 -0
  184. package/pennyfarthing_scripts/bikerack/__pycache__/ws_client.cpython-314.pyc +0 -0
  185. package/pennyfarthing_scripts/bikerack/cli.py +10 -11
  186. package/pennyfarthing_scripts/bikerack/debug_panel.py +218 -0
  187. package/pennyfarthing_scripts/bikerack/diffs_panel.py +203 -27
  188. package/pennyfarthing_scripts/brownfield/__pycache__/__init__.cpython-314.pyc +0 -0
  189. package/pennyfarthing_scripts/brownfield/__pycache__/__main__.cpython-314.pyc +0 -0
  190. package/pennyfarthing_scripts/brownfield/__pycache__/cli.cpython-314.pyc +0 -0
  191. package/pennyfarthing_scripts/brownfield/__pycache__/discover.cpython-314.pyc +0 -0
  192. package/pennyfarthing_scripts/cli.py +114 -0
  193. package/pennyfarthing_scripts/codemarkers/__pycache__/__init__.cpython-314.pyc +0 -0
  194. package/pennyfarthing_scripts/codemarkers/__pycache__/__main__.cpython-314.pyc +0 -0
  195. package/pennyfarthing_scripts/codemarkers/__pycache__/analyze.cpython-314.pyc +0 -0
  196. package/pennyfarthing_scripts/codemarkers/__pycache__/cli.cpython-314.pyc +0 -0
  197. package/pennyfarthing_scripts/codemarkers/__pycache__/formatters.cpython-314.pyc +0 -0
  198. package/pennyfarthing_scripts/codemarkers/__pycache__/models.cpython-314.pyc +0 -0
  199. package/pennyfarthing_scripts/common/__pycache__/__init__.cpython-314.pyc +0 -0
  200. package/pennyfarthing_scripts/common/__pycache__/config.cpython-314.pyc +0 -0
  201. package/pennyfarthing_scripts/common/__pycache__/output.cpython-314.pyc +0 -0
  202. package/pennyfarthing_scripts/common/__pycache__/themes.cpython-314.pyc +0 -0
  203. package/pennyfarthing_scripts/complexity/__pycache__/__init__.cpython-314.pyc +0 -0
  204. package/pennyfarthing_scripts/complexity/__pycache__/__main__.cpython-314.pyc +0 -0
  205. package/pennyfarthing_scripts/complexity/__pycache__/analyze.cpython-314.pyc +0 -0
  206. package/pennyfarthing_scripts/complexity/__pycache__/cli.cpython-314.pyc +0 -0
  207. package/pennyfarthing_scripts/complexity/__pycache__/formatters.cpython-314.pyc +0 -0
  208. package/pennyfarthing_scripts/complexity/__pycache__/models.cpython-314.pyc +0 -0
  209. package/pennyfarthing_scripts/deadcode/__pycache__/__init__.cpython-314.pyc +0 -0
  210. package/pennyfarthing_scripts/deadcode/__pycache__/__main__.cpython-314.pyc +0 -0
  211. package/pennyfarthing_scripts/deadcode/__pycache__/analyze.cpython-314.pyc +0 -0
  212. package/pennyfarthing_scripts/deadcode/__pycache__/cli.cpython-314.pyc +0 -0
  213. package/pennyfarthing_scripts/deadcode/__pycache__/formatters.cpython-314.pyc +0 -0
  214. package/pennyfarthing_scripts/deadcode/__pycache__/models.cpython-314.pyc +0 -0
  215. package/pennyfarthing_scripts/dependencies/__pycache__/__init__.cpython-314.pyc +0 -0
  216. package/pennyfarthing_scripts/dependencies/__pycache__/__main__.cpython-314.pyc +0 -0
  217. package/pennyfarthing_scripts/dependencies/__pycache__/analyze.cpython-314.pyc +0 -0
  218. package/pennyfarthing_scripts/dependencies/__pycache__/cli.cpython-314.pyc +0 -0
  219. package/pennyfarthing_scripts/dependencies/__pycache__/formatters.cpython-314.pyc +0 -0
  220. package/pennyfarthing_scripts/dependencies/__pycache__/models.cpython-314.pyc +0 -0
  221. package/pennyfarthing_scripts/epic/__init__.py +0 -0
  222. package/pennyfarthing_scripts/epic/cli.py +64 -0
  223. package/pennyfarthing_scripts/gate/__init__.py +1 -0
  224. package/pennyfarthing_scripts/gate/__pycache__/__init__.cpython-314.pyc +0 -0
  225. package/pennyfarthing_scripts/gate/__pycache__/cli.cpython-314.pyc +0 -0
  226. package/pennyfarthing_scripts/gate/__pycache__/validate.cpython-314.pyc +0 -0
  227. package/pennyfarthing_scripts/gate/cli.py +56 -0
  228. package/pennyfarthing_scripts/gate/validate.py +266 -0
  229. package/pennyfarthing_scripts/git/__pycache__/__init__.cpython-314.pyc +0 -0
  230. package/pennyfarthing_scripts/git/__pycache__/create_branches.cpython-314.pyc +0 -0
  231. package/pennyfarthing_scripts/git/__pycache__/status_all.cpython-314.pyc +0 -0
  232. package/pennyfarthing_scripts/git_group/__init__.py +0 -0
  233. package/pennyfarthing_scripts/git_group/cli.py +100 -0
  234. package/pennyfarthing_scripts/handoff/__init__.py +1 -0
  235. package/pennyfarthing_scripts/handoff/__pycache__/__init__.cpython-314.pyc +0 -0
  236. package/pennyfarthing_scripts/handoff/__pycache__/cli.cpython-314.pyc +0 -0
  237. package/pennyfarthing_scripts/handoff/__pycache__/complete_phase.cpython-314.pyc +0 -0
  238. package/pennyfarthing_scripts/handoff/__pycache__/gate_file.cpython-314.pyc +0 -0
  239. package/pennyfarthing_scripts/handoff/__pycache__/gate_runner.cpython-314.pyc +0 -0
  240. package/pennyfarthing_scripts/handoff/__pycache__/marker.cpython-314.pyc +0 -0
  241. package/pennyfarthing_scripts/handoff/__pycache__/resolve_gate.cpython-314.pyc +0 -0
  242. package/pennyfarthing_scripts/handoff/cli.py +120 -0
  243. package/pennyfarthing_scripts/handoff/complete_phase.py +155 -0
  244. package/pennyfarthing_scripts/handoff/gate_file.py +105 -0
  245. package/pennyfarthing_scripts/handoff/gate_runner.py +152 -0
  246. package/pennyfarthing_scripts/handoff/marker.py +109 -0
  247. package/pennyfarthing_scripts/handoff/resolve_gate.py +152 -0
  248. package/pennyfarthing_scripts/healthscore/__pycache__/__init__.cpython-314.pyc +0 -0
  249. package/pennyfarthing_scripts/healthscore/__pycache__/__main__.cpython-314.pyc +0 -0
  250. package/pennyfarthing_scripts/healthscore/__pycache__/analyze.cpython-314.pyc +0 -0
  251. package/pennyfarthing_scripts/healthscore/__pycache__/cli.cpython-314.pyc +0 -0
  252. package/pennyfarthing_scripts/healthscore/__pycache__/formatters.cpython-314.pyc +0 -0
  253. package/pennyfarthing_scripts/healthscore/__pycache__/models.cpython-314.pyc +0 -0
  254. package/pennyfarthing_scripts/hotspots/__pycache__/__init__.cpython-314.pyc +0 -0
  255. package/pennyfarthing_scripts/hotspots/__pycache__/__main__.cpython-314.pyc +0 -0
  256. package/pennyfarthing_scripts/hotspots/__pycache__/analyze.cpython-314.pyc +0 -0
  257. package/pennyfarthing_scripts/hotspots/__pycache__/cli.cpython-314.pyc +0 -0
  258. package/pennyfarthing_scripts/hotspots/__pycache__/formatters.cpython-314.pyc +0 -0
  259. package/pennyfarthing_scripts/hotspots/__pycache__/models.cpython-314.pyc +0 -0
  260. package/pennyfarthing_scripts/jira/__pycache__/__init__.cpython-314.pyc +0 -0
  261. package/pennyfarthing_scripts/jira/__pycache__/__main__.cpython-314.pyc +0 -0
  262. package/pennyfarthing_scripts/jira/__pycache__/bidirectional.cpython-314.pyc +0 -0
  263. package/pennyfarthing_scripts/jira/__pycache__/claim.cpython-314.pyc +0 -0
  264. package/pennyfarthing_scripts/jira/__pycache__/cli.cpython-314.pyc +0 -0
  265. package/pennyfarthing_scripts/jira/__pycache__/client.cpython-314.pyc +0 -0
  266. package/pennyfarthing_scripts/jira/__pycache__/create.cpython-314.pyc +0 -0
  267. package/pennyfarthing_scripts/jira/__pycache__/epic.cpython-314.pyc +0 -0
  268. package/pennyfarthing_scripts/jira/__pycache__/operations.cpython-314.pyc +0 -0
  269. package/pennyfarthing_scripts/jira/__pycache__/reconcile.cpython-314.pyc +0 -0
  270. package/pennyfarthing_scripts/jira/__pycache__/story.cpython-314.pyc +0 -0
  271. package/pennyfarthing_scripts/jira/__pycache__/sync.cpython-314.pyc +0 -0
  272. package/pennyfarthing_scripts/launch/__pycache__/__init__.cpython-314.pyc +0 -0
  273. package/pennyfarthing_scripts/launch/__pycache__/cli.cpython-314.pyc +0 -0
  274. package/pennyfarthing_scripts/migration/__pycache__/__init__.cpython-314.pyc +0 -0
  275. package/pennyfarthing_scripts/migration/__pycache__/session.cpython-314.pyc +0 -0
  276. package/pennyfarthing_scripts/migration/__pycache__/skill.cpython-314.pyc +0 -0
  277. package/pennyfarthing_scripts/migration/__pycache__/step.cpython-314.pyc +0 -0
  278. package/pennyfarthing_scripts/migration/__pycache__/validate.cpython-314.pyc +0 -0
  279. package/pennyfarthing_scripts/preflight/__pycache__/__init__.cpython-314.pyc +0 -0
  280. package/pennyfarthing_scripts/preflight/__pycache__/__main__.cpython-314.pyc +0 -0
  281. package/pennyfarthing_scripts/preflight/__pycache__/cli.cpython-314.pyc +0 -0
  282. package/pennyfarthing_scripts/preflight/__pycache__/finish.cpython-314.pyc +0 -0
  283. package/pennyfarthing_scripts/prime/__pycache__/__init__.cpython-314.pyc +0 -0
  284. package/pennyfarthing_scripts/prime/__pycache__/cli.cpython-314.pyc +0 -0
  285. package/pennyfarthing_scripts/prime/__pycache__/loader.cpython-314.pyc +0 -0
  286. package/pennyfarthing_scripts/prime/__pycache__/models.cpython-314.pyc +0 -0
  287. package/pennyfarthing_scripts/prime/__pycache__/persona.cpython-314.pyc +0 -0
  288. package/pennyfarthing_scripts/prime/__pycache__/session.cpython-314.pyc +0 -0
  289. package/pennyfarthing_scripts/prime/__pycache__/tiers.cpython-314.pyc +0 -0
  290. package/pennyfarthing_scripts/prime/__pycache__/version_sentinel.cpython-314.pyc +0 -0
  291. package/pennyfarthing_scripts/prime/__pycache__/workflow.cpython-314.pyc +0 -0
  292. package/pennyfarthing_scripts/prime/workflow.py +39 -0
  293. package/pennyfarthing_scripts/session/__init__.py +0 -0
  294. package/pennyfarthing_scripts/session/cli.py +87 -0
  295. package/pennyfarthing_scripts/sprint/__pycache__/__init__.cpython-314.pyc +0 -0
  296. package/pennyfarthing_scripts/sprint/__pycache__/__main__.cpython-314.pyc +0 -0
  297. package/pennyfarthing_scripts/sprint/__pycache__/archive.cpython-314.pyc +0 -0
  298. package/pennyfarthing_scripts/sprint/__pycache__/archive_epic.cpython-314.pyc +0 -0
  299. package/pennyfarthing_scripts/sprint/__pycache__/cli.cpython-314.pyc +0 -0
  300. package/pennyfarthing_scripts/sprint/__pycache__/epic_add.cpython-314.pyc +0 -0
  301. package/pennyfarthing_scripts/sprint/__pycache__/epic_update.cpython-314.pyc +0 -0
  302. package/pennyfarthing_scripts/sprint/__pycache__/import_epic.cpython-314.pyc +0 -0
  303. package/pennyfarthing_scripts/sprint/__pycache__/loader.cpython-314.pyc +0 -0
  304. package/pennyfarthing_scripts/sprint/__pycache__/status.cpython-314.pyc +0 -0
  305. package/pennyfarthing_scripts/sprint/__pycache__/story_add.cpython-314.pyc +0 -0
  306. package/pennyfarthing_scripts/sprint/__pycache__/story_finish.cpython-314.pyc +0 -0
  307. package/pennyfarthing_scripts/sprint/__pycache__/story_update.cpython-314.pyc +0 -0
  308. package/pennyfarthing_scripts/sprint/__pycache__/validate_cmd.cpython-314.pyc +0 -0
  309. package/pennyfarthing_scripts/sprint/__pycache__/validator.cpython-314.pyc +0 -0
  310. package/pennyfarthing_scripts/sprint/__pycache__/work.cpython-314.pyc +0 -0
  311. package/pennyfarthing_scripts/sprint/__pycache__/yaml_io.cpython-314.pyc +0 -0
  312. package/pennyfarthing_scripts/sprint/story_finish.py +14 -0
  313. package/pennyfarthing_scripts/story/__pycache__/__init__.cpython-314.pyc +0 -0
  314. package/pennyfarthing_scripts/story/__pycache__/__main__.cpython-314.pyc +0 -0
  315. package/pennyfarthing_scripts/story/__pycache__/cli.cpython-314.pyc +0 -0
  316. package/pennyfarthing_scripts/story/__pycache__/create.cpython-314.pyc +0 -0
  317. package/pennyfarthing_scripts/story/__pycache__/size.cpython-314.pyc +0 -0
  318. package/pennyfarthing_scripts/story/__pycache__/template.cpython-314.pyc +0 -0
  319. package/pennyfarthing_scripts/tests/__pycache__/__init__.cpython-314.pyc +0 -0
  320. package/pennyfarthing_scripts/tests/__pycache__/conftest.cpython-314-pytest-9.0.2.pyc +0 -0
  321. package/pennyfarthing_scripts/tests/__pycache__/test_108_2_remove_handoff_fallback.cpython-314-pytest-9.0.2.pyc +0 -0
  322. package/pennyfarthing_scripts/tests/__pycache__/test_archive_epic.cpython-314-pytest-9.0.2.pyc +0 -0
  323. package/pennyfarthing_scripts/tests/__pycache__/test_bc.cpython-314-pytest-9.0.2.pyc +0 -0
  324. package/pennyfarthing_scripts/tests/__pycache__/test_bikerack.cpython-314-pytest-9.0.2.pyc +0 -0
  325. package/pennyfarthing_scripts/tests/__pycache__/test_brownfield.cpython-314-pytest-9.0.2.pyc +0 -0
  326. package/pennyfarthing_scripts/tests/__pycache__/test_cli_modules.cpython-314-pytest-9.0.2.pyc +0 -0
  327. package/pennyfarthing_scripts/tests/__pycache__/test_cli_normalization.cpython-314-pytest-9.0.2.pyc +0 -0
  328. package/pennyfarthing_scripts/tests/__pycache__/test_codemarkers.cpython-314-pytest-9.0.2.pyc +0 -0
  329. package/pennyfarthing_scripts/tests/__pycache__/test_common.cpython-314-pytest-9.0.2.pyc +0 -0
  330. package/pennyfarthing_scripts/tests/__pycache__/test_epic_shard_validation.cpython-314-pytest-9.0.2.pyc +0 -0
  331. package/pennyfarthing_scripts/tests/__pycache__/test_gate_file_resolution.cpython-314-pytest-9.0.2.pyc +0 -0
  332. package/pennyfarthing_scripts/tests/__pycache__/test_gate_runner.cpython-314-pytest-9.0.2.pyc +0 -0
  333. package/pennyfarthing_scripts/tests/__pycache__/test_git_utils.cpython-314-pytest-9.0.2.pyc +0 -0
  334. package/pennyfarthing_scripts/tests/__pycache__/test_handoff_cli.cpython-314-pytest-9.0.2.pyc +0 -0
  335. package/pennyfarthing_scripts/tests/__pycache__/test_handoff_e2e.cpython-314-pytest-9.0.2.pyc +0 -0
  336. package/pennyfarthing_scripts/tests/__pycache__/test_healthscore.cpython-314-pytest-9.0.2.pyc +0 -0
  337. package/pennyfarthing_scripts/tests/__pycache__/test_jira_package.cpython-314-pytest-9.0.2.pyc +0 -0
  338. package/pennyfarthing_scripts/tests/__pycache__/test_package_structure.cpython-314-pytest-9.0.2.pyc +0 -0
  339. package/pennyfarthing_scripts/tests/__pycache__/test_patch_mode.cpython-314-pytest-9.0.2.pyc +0 -0
  340. package/pennyfarthing_scripts/tests/__pycache__/test_prime.cpython-314-pytest-9.0.2.pyc +0 -0
  341. package/pennyfarthing_scripts/tests/__pycache__/test_resolve_gate_file_field.cpython-314-pytest-9.0.2.pyc +0 -0
  342. package/pennyfarthing_scripts/tests/__pycache__/test_sprint_package.cpython-314-pytest-9.0.2.pyc +0 -0
  343. package/pennyfarthing_scripts/tests/__pycache__/test_sprint_panel.cpython-314-pytest-9.0.2.pyc +0 -0
  344. package/pennyfarthing_scripts/tests/__pycache__/test_sprint_validator.cpython-314-pytest-9.0.2.pyc +0 -0
  345. package/pennyfarthing_scripts/tests/__pycache__/test_story_add.cpython-314-pytest-9.0.2.pyc +0 -0
  346. package/pennyfarthing_scripts/tests/__pycache__/test_story_package.cpython-314-pytest-9.0.2.pyc +0 -0
  347. package/pennyfarthing_scripts/tests/__pycache__/test_story_update.cpython-314-pytest-9.0.2.pyc +0 -0
  348. package/pennyfarthing_scripts/tests/__pycache__/test_tiers.cpython-314-pytest-9.0.2.pyc +0 -0
  349. package/pennyfarthing_scripts/tests/__pycache__/test_token_counting.cpython-314-pytest-9.0.2.pyc +0 -0
  350. package/pennyfarthing_scripts/tests/__pycache__/test_topology_loader.cpython-314-pytest-9.0.2.pyc +0 -0
  351. package/pennyfarthing_scripts/tests/__pycache__/test_tui_focus.cpython-314-pytest-9.0.2.pyc +0 -0
  352. package/pennyfarthing_scripts/tests/__pycache__/test_tui_panel_persistence.cpython-314-pytest-9.0.2.pyc +0 -0
  353. package/pennyfarthing_scripts/tests/__pycache__/test_validate_cmd.cpython-314-pytest-9.0.2.pyc +0 -0
  354. package/pennyfarthing_scripts/tests/__pycache__/test_version_sentinel.cpython-314-pytest-9.0.2.pyc +0 -0
  355. package/pennyfarthing_scripts/tests/__pycache__/test_workflow_check.cpython-314-pytest-9.0.2.pyc +0 -0
  356. package/pennyfarthing_scripts/tests/__pycache__/test_yaml_io.cpython-314-pytest-9.0.2.pyc +0 -0
  357. package/pennyfarthing_scripts/tests/test_108_1_gate_migration.py +540 -0
  358. package/pennyfarthing_scripts/tests/test_108_2_remove_handoff_fallback.py +339 -0
  359. package/pennyfarthing_scripts/tests/test_confidence_sm_evaluation.py +253 -0
  360. package/pennyfarthing_scripts/tests/test_confidence_sm_gate.py +315 -0
  361. package/pennyfarthing_scripts/tests/test_gate_file_resolution.py +341 -0
  362. package/pennyfarthing_scripts/tests/test_gate_runner.py +620 -0
  363. package/pennyfarthing_scripts/tests/test_handoff_cli.py +929 -0
  364. package/pennyfarthing_scripts/tests/test_handoff_e2e.py +454 -0
  365. package/pennyfarthing_scripts/tests/test_resolve_gate_file_field.py +464 -0
  366. package/pennyfarthing_scripts/theme/__pycache__/__init__.cpython-314.pyc +0 -0
  367. package/pennyfarthing_scripts/theme/__pycache__/cli.cpython-314.pyc +0 -0
  368. package/pennyfarthing_scripts/validate/__pycache__/__init__.cpython-314.pyc +0 -0
  369. package/pennyfarthing_scripts/validate/__pycache__/cli.cpython-314.pyc +0 -0
  370. package/pennyfarthing_scripts/validate/adapters/__pycache__/__init__.cpython-314.pyc +0 -0
  371. package/pennyfarthing_scripts/validate/adapters/__pycache__/agent.cpython-314.pyc +0 -0
  372. package/pennyfarthing_scripts/validate/adapters/__pycache__/schema.cpython-314.pyc +0 -0
  373. package/pennyfarthing_scripts/validate/adapters/__pycache__/skill_command.cpython-314.pyc +0 -0
  374. package/pennyfarthing_scripts/validate/adapters/__pycache__/sprint.cpython-314.pyc +0 -0
  375. package/pennyfarthing_scripts/validate/adapters/__pycache__/workflow.cpython-314.pyc +0 -0
  376. package/pennyfarthing_scripts/validate/adapters/skill_command.py +200 -0
  377. package/pennyfarthing_scripts/validate/adapters/workflow.py +64 -0
  378. package/pennyfarthing_scripts/validate/cli.py +15 -4
  379. package/packages/core/dist/scripts/benchmark-integration.d.ts +0 -182
  380. package/packages/core/dist/scripts/benchmark-integration.d.ts.map +0 -1
  381. package/packages/core/dist/scripts/benchmark-integration.js +0 -691
  382. package/packages/core/dist/scripts/benchmark-integration.js.map +0 -1
  383. package/packages/core/dist/scripts/job-fair-aggregator.d.ts +0 -150
  384. package/packages/core/dist/scripts/job-fair-aggregator.d.ts.map +0 -1
  385. package/packages/core/dist/scripts/job-fair-aggregator.js +0 -547
  386. package/packages/core/dist/scripts/job-fair-aggregator.js.map +0 -1
  387. package/pennyfarthing-dist/agents/handoff.md +0 -250
  388. package/pennyfarthing-dist/agents/sm-handoff.md +0 -152
  389. package/pennyfarthing-dist/scripts/core/handoff-marker.sh +0 -112
  390. package/pennyfarthing-dist/scripts/hooks/__pycache__/question_reflector_check.cpython-314.pyc +0 -0
  391. package/pennyfarthing_scripts/__pycache__/__init__.cpython-311.pyc +0 -0
  392. package/pennyfarthing_scripts/__pycache__/jira.cpython-314.pyc +0 -0
  393. package/pennyfarthing_scripts/__pycache__/sprint.cpython-314.pyc +0 -0
  394. package/pennyfarthing_scripts/__pycache__/workflow.cpython-311.pyc +0 -0
  395. package/pennyfarthing_scripts/jira/__pycache__/compat.cpython-314.pyc +0 -0
  396. package/pennyfarthing_scripts/jira/__pycache__/mappings.cpython-314.pyc +0 -0
  397. package/pennyfarthing_scripts/jira/__pycache__/models.cpython-314.pyc +0 -0
  398. package/pennyfarthing_scripts/migration/__pycache__/__main__.cpython-314.pyc +0 -0
  399. package/pennyfarthing_scripts/migration/__pycache__/cli.cpython-314.pyc +0 -0
  400. package/pennyfarthing_scripts/prime/__pycache__/__main__.cpython-314.pyc +0 -0
  401. package/pennyfarthing_scripts/tests/__pycache__/test_workflow_cli.cpython-314-pytest-9.0.2.pyc +0 -0
@@ -0,0 +1,116 @@
1
+ # Handoff CLI
2
+
3
+ <info>
4
+ Python CLI for managing workflow phase transitions. Agents use `pf handoff` to resolve gates, complete phase transitions, and generate handoff markers during their exit protocol.
5
+ </info>
6
+
7
+ ## Commands
8
+
9
+ ### resolve-gate
10
+
11
+ Check whether the current phase has a gate and what state it's in.
12
+
13
+ ```bash
14
+ pf handoff resolve-gate STORY_ID WORKFLOW PHASE
15
+ ```
16
+
17
+ **Arguments:**
18
+ - `STORY_ID` — Story identifier (e.g., `105-1`)
19
+ - `WORKFLOW` — Workflow name (e.g., `tdd`, `trivial`, `patch`)
20
+ - `PHASE` — Current phase name (e.g., `green`, `implement`, `fix`)
21
+
22
+ **Output:** YAML `RESOLVE_RESULT` block:
23
+
24
+ ```yaml
25
+ RESOLVE_RESULT:
26
+ status: ready | skip | blocked
27
+ gate_file: tests-pass # Only when status=ready
28
+ reason: "..." # Human-readable explanation
29
+ ```
30
+
31
+ | Status | Meaning |
32
+ |--------|---------|
33
+ | `ready` | Gate exists, subagent should evaluate it |
34
+ | `skip` | No gate defined for this phase, proceed directly |
35
+ | `blocked` | Phase cannot transition (exits with code 1) |
36
+
37
+ ### complete-phase
38
+
39
+ Atomically update the session file to record a phase transition.
40
+
41
+ ```bash
42
+ pf handoff complete-phase STORY_ID WORKFLOW FROM_PHASE TO_PHASE GATE_TYPE
43
+ ```
44
+
45
+ **Arguments:**
46
+ - `STORY_ID` — Story identifier
47
+ - `WORKFLOW` — Workflow name
48
+ - `FROM_PHASE` — Phase being completed (e.g., `green`)
49
+ - `TO_PHASE` — Phase being entered (e.g., `review`)
50
+ - `GATE_TYPE` — Gate that was passed (e.g., `tests_pass`, `skip`, `none`)
51
+
52
+ **Output:** YAML `COMPLETE_RESULT` block:
53
+
54
+ ```yaml
55
+ COMPLETE_RESULT:
56
+ status: success | error
57
+ from_phase: green
58
+ to_phase: review
59
+ gate_type: tests_pass
60
+ ```
61
+
62
+ Updates the session file: `**Phase:**` line, timestamps, and phase history table.
63
+
64
+ ### marker
65
+
66
+ Generate an environment-aware handoff marker block.
67
+
68
+ ```bash
69
+ pf handoff marker NEXT_AGENT
70
+ pf handoff marker --error "Tests failing"
71
+ ```
72
+
73
+ **Arguments:**
74
+ - `NEXT_AGENT` — Agent to hand off to (e.g., `dev`, `tea`, `reviewer`)
75
+
76
+ **Options:**
77
+ - `--error MSG` — Generate an error marker instead of a handoff
78
+
79
+ The marker generator detects the current environment (Cyclist, relay mode, context usage) and produces the appropriate marker type:
80
+
81
+ - **Cyclist + relay mode:** `<!-- CYCLIST:HANDOFF:/agent -->` (auto-executed)
82
+ - **Cyclist + high context:** `<!-- CYCLIST:CONTEXT_CLEAR:/agent -->` (clears context first)
83
+ - **CLI mode:** Plain text `AGENT_COMMAND` block
84
+
85
+ ## Agent Exit Protocol
86
+
87
+ The handoff CLI is used in sequence during agent exit:
88
+
89
+ ```
90
+ 1. Write assessment to session file
91
+ 2. pf handoff resolve-gate {story-id} {workflow} {phase}
92
+ ├── blocked → report error, STOP
93
+ ├── skip → jump to step 4
94
+ └── ready → spawn gate subagent → GATE_RESULT
95
+ ├── fail → fix issues, retry (max 3)
96
+ └── pass → continue
97
+ 3. pf handoff complete-phase {story-id} {workflow} {from} {to} {gate-type}
98
+ 4. pf handoff marker {next-agent} → emit marker → EXIT
99
+ ```
100
+
101
+ See `guides/gates.md` for gate file format and evaluation details.
102
+
103
+ ## Key Files
104
+
105
+ | File | Purpose |
106
+ |------|---------|
107
+ | `pennyfarthing_scripts/handoff/cli.py` | Click command definitions |
108
+ | `pennyfarthing_scripts/handoff/resolve_gate.py` | Gate resolution logic |
109
+ | `pennyfarthing_scripts/handoff/complete_phase.py` | Session file atomic updates |
110
+ | `pennyfarthing_scripts/handoff/marker.py` | Environment-aware marker generation |
111
+ | `pennyfarthing_scripts/handoff/gate_runner.py` | Gate subagent spawner |
112
+ | `pennyfarthing_scripts/handoff/gate_file.py` | Gate file discovery |
113
+
114
+ <info>
115
+ **Related:** `guides/gates.md` (gate system), `agents/agent-behavior.md` (exit protocol), `guides/reflector.md` (marker types)
116
+ </info>
@@ -14,7 +14,9 @@ Hooks are shell scripts that Claude Code runs at specific events:
14
14
 
15
15
  ## Pennyfarthing Default Hooks
16
16
 
17
- ### SessionStart: session-start.sh
17
+ ### SessionStart Hooks
18
+
19
+ #### session-start.sh
18
20
 
19
21
  **Location:** `.pennyfarthing/scripts/hooks/session-start.sh`
20
22
 
@@ -23,7 +25,13 @@ Initializes the Pennyfarthing environment:
23
25
  - Clears stale agent state from previous sessions
24
26
  - Sets `PROJECT_ROOT` and `SESSION_ID` environment variables
25
27
 
26
- ### SessionStart: setup-env.sh
28
+ #### session-stop.sh
29
+
30
+ **Location:** `.pennyfarthing/scripts/hooks/session-stop.sh`
31
+
32
+ Cleans up session state when Claude Code exits.
33
+
34
+ #### setup-env.sh
27
35
 
28
36
  **Location:** `.pennyfarthing/project/hooks/setup-env.sh`
29
37
 
@@ -32,7 +40,21 @@ Project-specific environment setup. Edit this file to:
32
40
  - Configure project-specific paths
33
41
  - Initialize project dependencies
34
42
 
35
- ### PreToolUse: pre-edit-check.sh
43
+ #### otel-auto-config.sh
44
+
45
+ **Location:** `.pennyfarthing/scripts/hooks/otel-auto-config.sh`
46
+
47
+ Auto-configures OTEL telemetry for Cyclist web mode. Checks for a `.cyclist-port` file and sets `OTEL_EXPORTER_OTLP_PROTOCOL` and `OTEL_EXPORTER_OTLP_ENDPOINT` to route Claude Code telemetry to the running Cyclist/BikeRack server.
48
+
49
+ #### welcome-hook.sh
50
+
51
+ **Location:** `.pennyfarthing/scripts/hooks/welcome-hook.sh`
52
+
53
+ Displays a welcome message on session start. In CLI mode, shows ASCII art. In Cyclist mode, sends a WebSocket message to display the logo. Runs once per session (lock file guard).
54
+
55
+ ### PreToolUse Hooks
56
+
57
+ #### pre-edit-check.sh
36
58
 
37
59
  **Location:** `.pennyfarthing/scripts/hooks/pre-edit-check.sh`
38
60
 
@@ -41,6 +63,64 @@ Protects sensitive files from accidental edits:
41
63
  - Blocks: `.git/`, `node_modules/`, `vendor/`
42
64
  - Blocks: `.pennyfarthing/*` (managed files)
43
65
 
66
+ #### cyclist-pretooluse-hook.sh
67
+
68
+ **Location:** `.pennyfarthing/scripts/hooks/cyclist-pretooluse-hook.sh`
69
+
70
+ Cyclist-specific pre-tool validation. Runs additional safety checks when operating inside Cyclist.
71
+
72
+ #### context-warning.sh
73
+
74
+ **Location:** `.pennyfarthing/scripts/hooks/context-warning.sh`
75
+
76
+ Warns agents when context usage is high. Outputs a warning at 60% usage and a critical warning at 85%. Never blocks — warning only (always exits 0).
77
+
78
+ #### context-circuit-breaker.sh
79
+
80
+ **Location:** `.pennyfarthing/scripts/hooks/context-circuit-breaker.sh`
81
+
82
+ Hard stop when context reaches 80% (configurable via `CRITICAL_THRESHOLD`). Unlike `context-warning.sh`, this **blocks tool execution** (exit 2). Auto-saves the active agent to a checkpoint so `/pf-session continue` can restore it with FULL tier context.
83
+
84
+ #### schema-validation.sh
85
+
86
+ **Location:** `.pennyfarthing/scripts/hooks/schema-validation.sh`
87
+
88
+ Validates file writes against XML schema rules for agent definitions, workflow files, and other structured content.
89
+
90
+ #### sprint-yaml-validation.sh
91
+
92
+ **Location:** `.pennyfarthing/scripts/hooks/sprint-yaml-validation.sh`
93
+
94
+ Validates sprint YAML files on write to prevent structural corruption.
95
+
96
+ ### PostToolUse Hooks
97
+
98
+ #### bell-mode-hook.sh
99
+
100
+ **Location:** `.pennyfarthing/scripts/hooks/bell-mode-hook.sh`
101
+
102
+ Bell mode message injection. Checks the bell mode queue and injects queued messages into the agent's context at the next tool execution. Also handles tandem observation injection.
103
+
104
+ #### question-reflector-check.sh / question_reflector_check.py
105
+
106
+ **Location:** `.pennyfarthing/scripts/hooks/question-reflector-check.sh`
107
+
108
+ Stop hook enforcing that every agent turn ends with a CYCLIST marker. Detects questions, handoff phrases, and validates marker presence. Blocks turns without valid markers in Cyclist mode. The `.sh` file wraps the Python implementation.
109
+
110
+ ### Git Hooks
111
+
112
+ #### dispatcher-template.sh
113
+
114
+ **Location:** `.pennyfarthing/scripts/hooks/dispatcher-template.sh`
115
+
116
+ Template for git hook dispatchers. Installs as `.git/hooks/{hook-name}` and runs all executable scripts in `.git/hooks/{hook-name}.d/` in sorted order. This enables hook chaining — multiple tools can add hooks without overwriting each other.
117
+
118
+ #### pre-commit.sh / pre-push.sh / post-merge.sh
119
+
120
+ **Location:** `.pennyfarthing/scripts/hooks/`
121
+
122
+ Standard git hooks installed into the dispatcher `.d/` directories. Handle linting, validation, and post-merge cleanup.
123
+
44
124
  ## Configuration Schema
45
125
 
46
126
  Hooks are configured in `.claude/settings.local.json`:
@@ -225,6 +305,8 @@ If a hook fails or behaves unexpectedly:
225
305
 
226
306
  | Type | Location | Editable |
227
307
  |------|----------|----------|
228
- | Managed hooks | `.pennyfarthing/scripts/hooks/` | No (use pennyfarthing repo) |
308
+ | Managed hooks | `.pennyfarthing/scripts/hooks/` | No (symlinked — edit in `pennyfarthing-dist/`) |
229
309
  | Project hooks | `.claude/project/hooks/` | Yes |
230
310
  | Settings | `.claude/settings.local.json` | Yes |
311
+ | Git hook dispatchers | `.git/hooks/{name}` | No (installed by `pennyfarthing init`) |
312
+ | Git hook scripts | `.git/hooks/{name}.d/` | Yes (add scripts to `.d/` directories) |
@@ -0,0 +1,65 @@
1
+ # Output Styles
2
+
3
+ <info>
4
+ Configurable response styles that control how agents communicate. Output styles adjust verbosity, tone, and formatting without changing agent behavior or capabilities.
5
+ </info>
6
+
7
+ ## Overview
8
+
9
+ Output styles are markdown files in `pennyfarthing-dist/output-styles/` that agents load to adjust their communication style. They don't change what agents do — they change how they talk about it.
10
+
11
+ ## Available Styles
12
+
13
+ ### Terse
14
+
15
+ Minimal, efficient output for experienced users.
16
+
17
+ - Brief responses — only what's necessary
18
+ - Skip explanations, assume context
19
+ - Bullet points over paragraphs
20
+ - Code output without commentary
21
+
22
+ ### Verbose
23
+
24
+ Detailed, educational explanations throughout.
25
+
26
+ - Walk through reasoning step by step
27
+ - Explain context and trade-offs
28
+ - Document decisions and alternatives
29
+ - Cover edge cases and related considerations
30
+
31
+ ### Teaching
32
+
33
+ Explain reasoning and teach as you go.
34
+
35
+ - Show your work — explain decisions
36
+ - Point out reusable patterns and principles
37
+ - Suggest alternatives with trade-offs
38
+ - Build understanding by connecting concepts
39
+ - Collaborative tone, not lecturing
40
+
41
+ ## Configuration
42
+
43
+ Set the output style in `.pennyfarthing/config.local.yaml`:
44
+
45
+ ```yaml
46
+ output_style: terse # terse | verbose | teaching
47
+ ```
48
+
49
+ When no style is configured, agents use their default communication patterns.
50
+
51
+ ## How It Works
52
+
53
+ During prime activation, the output style file is loaded and injected into the agent's system prompt alongside the agent definition and persona. The style acts as a behavioral modifier — it constrains how the agent formats and presents its output.
54
+
55
+ ## Key Files
56
+
57
+ | File | Purpose |
58
+ |------|---------|
59
+ | `pennyfarthing-dist/output-styles/terse.md` | Minimal output style |
60
+ | `pennyfarthing-dist/output-styles/verbose.md` | Detailed output style |
61
+ | `pennyfarthing-dist/output-styles/teaching.md` | Educational output style |
62
+
63
+ ## Creating Custom Styles
64
+
65
+ Add a markdown file to `pennyfarthing-dist/output-styles/` with guidelines for the agent to follow. The file name (without `.md`) becomes the style identifier used in config.
@@ -322,7 +322,7 @@ EnterPlanMode:
322
322
 
323
323
  ### The Assessment-First Protocol
324
324
 
325
- **Critical Pattern:** All agents must write their assessment BEFORE spawning the handoff subagent.
325
+ **Critical Pattern:** All agents must write their assessment BEFORE starting the exit protocol.
326
326
 
327
327
  ```
328
328
  ┌─────────────────────────────────────────────────────────────────────────┐
@@ -569,9 +569,9 @@ Gate BLOCKED. Address security issue before proceeding.
569
569
  ```
570
570
  Agent completes work
571
571
 
572
- Spawns handoff subagent immediately
572
+ Runs exit protocol immediately
573
573
 
574
- Subagent has no assessment to verify
574
+ resolve-gate finds no assessment
575
575
 
576
576
  Gate is effectively bypassed
577
577
  ```
@@ -582,9 +582,9 @@ Agent completes work
582
582
 
583
583
  Writes assessment to session file
584
584
 
585
- Spawns handoff subagent
585
+ Runs exit protocol (resolve-gate → complete-phase → marker)
586
586
 
587
- Subagent verifies assessment exists
587
+ resolve-gate verifies assessment exists
588
588
 
589
589
  Gate functions properly
590
590
  ```
@@ -36,7 +36,7 @@ Each transition is mediated by a **handoff subagent** that updates the session f
36
36
 
37
37
  ```mermaid
38
38
  stateDiagram-v2
39
- [*] --> NEW_WORK: /new-work invoked
39
+ [*] --> NEW_WORK: /pf-session new invoked
40
40
 
41
41
  NEW_WORK --> SM_SETUP: User selects story
42
42
  SM_SETUP --> TEA_RED: Standard story (3+ pts)
@@ -153,7 +153,7 @@ The session file (`.session/{story-id}-session.md`) tracks state:
153
153
  ### Agent Responsibilities
154
154
 
155
155
  #### SM (Scrum Master)
156
- **Entry:** `/new-work` command
156
+ **Entry:** `/pf-session new` command
157
157
  **Role:** Story selection, context creation, finish workflow
158
158
  **Files:** `agents/sm.md`
159
159
 
@@ -291,9 +291,9 @@ Session file tracks rejection count and issues.
291
291
  ### Missing Epic Context
292
292
 
293
293
  ```
294
- User runs /new-work → prime detects no epic context
294
+ User runs /pf-session new → prime detects no epic context
295
295
  → Returns MISSING_EPIC_CONTEXT state
296
- → Blocks until user runs /start-epic
296
+ → Blocks until user runs /pf-epic start
297
297
  ```
298
298
 
299
299
  ### Context Overflow
@@ -141,7 +141,7 @@ Load this agent's persona before activation:
141
141
 
142
142
  Explains the primary "happy path" workflow for tactical agents.
143
143
 
144
- **Purpose:** Guides users to use `/new-work` rather than invoking agents directly.
144
+ **Purpose:** Guides users to use `/pf-session new` rather than invoking agents directly.
145
145
 
146
146
  **Structure:**
147
147
  ```xml
@@ -152,9 +152,9 @@ Explains the primary "happy path" workflow for tactical agents.
152
152
 
153
153
  | Command | When to Use |
154
154
  |---------|-------------|
155
- | `/new-work` | Start a NEW story from the backlog |
155
+ | `/pf-session new` | Start a NEW story from the backlog |
156
156
 
157
- **The TDD Flow:** `/new-work` -> SM -> TEA -> Dev -> Reviewer -> SM (finish)
157
+ **The TDD Flow:** `/pf-session new` -> SM -> TEA -> Dev -> Reviewer -> SM (finish)
158
158
 
159
159
  **Other commands exist** but are not part of the main dev loop.
160
160
  </blessed-path-guidance>
@@ -171,13 +171,13 @@ Clarifies that an agent is outside the core TDD loop.
171
171
 
172
172
  This agent supports the development process but is **not part of the core TDD loop**.
173
173
 
174
- **The Core TDD Loop:** `/new-work` -> SM -> TEA -> Dev -> Reviewer -> SM
174
+ **The Core TDD Loop:** `/pf-session new` -> SM -> TEA -> Dev -> Reviewer -> SM
175
175
 
176
176
  **When to use {Agent}:**
177
177
  - {Use case 1}
178
178
  - {Use case 2}
179
179
 
180
- **To start story-based development work,** use `/new-work` instead.
180
+ **To start story-based development work,** use `/pf-session new` instead.
181
181
  </support-agent-guidance>
182
182
  ```
183
183
 
@@ -34,10 +34,10 @@ Marker pattern: /<!--\s*CYCLIST:(\w+)(?::([^>]+?))?\s*-->/gi
34
34
 
35
35
  | File | Purpose |
36
36
  |------|---------|
37
- | `packages/shared/src/marker/detect.ts` | `detectMarkers()` — parses markers from text |
38
- | `packages/shared/src/marker/strip.ts` | `stripMarkers()`, `stripCodeBlocks()` |
39
- | `packages/shared/src/marker/types.ts` | `MarkerType`, `Marker` interface |
40
- | `packages/shared/src/marker/constants.ts` | `MARKER_PATTERN`, `MARKER_TYPES` |
37
+ | `packages/core/src/shared/marker/detect.ts` | `detectMarkers()` — parses markers from text |
38
+ | `packages/core/src/shared/marker/strip.ts` | `stripMarkers()`, `stripCodeBlocks()` |
39
+ | `packages/core/src/shared/marker/types.ts` | `MarkerType`, `Marker` interface |
40
+ | `packages/core/src/shared/marker/constants.ts` | `MARKER_PATTERN`, `MARKER_TYPES` |
41
41
  | `packages/cyclist/src/public/components/QuickActions.tsx` | Renders action buttons from detected markers |
42
42
  | `packages/cyclist/src/public/hooks/useMarkerActions.ts` | Detects markers, builds action metadata |
43
43
  | `pennyfarthing-dist/scripts/hooks/question_reflector_check.py` | Stop hook — enforces marker presence |
@@ -52,7 +52,7 @@ context-epic-{EPIC_NUM}.md
52
52
  - `context-epic-10.md`
53
53
 
54
54
  **Created by:** SM (epic-tech-context task)
55
- **Archived by:** `sm-finish PHASE=execute` (story), `/start-epic` or `/retro` (epic)
55
+ **Archived by:** `sm-finish PHASE=execute` (story), `/pf-epic start` or `/retro` (epic)
56
56
 
57
57
  ---
58
58
 
@@ -237,7 +237,7 @@ When filtered, only shows epics with matching stories.
237
237
  ```xml
238
238
  <when>
239
239
  - Starting new development work
240
- - `/new-work` is an alias for this command
240
+ - `/pf-session new` is an alias for this command
241
241
  Next steps after promote:
242
242
  - Review appended YAML in current-sprint.yaml
243
243
  - Create Jira epic: `/pf-jira create epic <epic-id>`
@@ -102,7 +102,7 @@ When the primary agent receives a tandem injection, it surfaces the observation
102
102
 
103
103
  ### 7. Cleanup
104
104
 
105
- Before handoff, the primary agent terminates the backseat background task. This must happen before spawning the handoff subagent.
105
+ Before handoff, the primary agent terminates the backseat background task. This must happen before starting the exit protocol.
106
106
 
107
107
  ## Observation Scopes
108
108
 
@@ -143,6 +143,18 @@ From `bdd-tandem.yaml`:
143
143
  | green | Dev | UX Designer | file-watch |
144
144
  | review | Reviewer | PM | file-watch |
145
145
 
146
+ ## Tandem Consultation Protocol
147
+
148
+ For active, synchronous agent-to-agent questions (as opposed to passive observation), see `protocols/tandem-consultation.md`. Key differences:
149
+
150
+ | Aspect | Backseat (this guide) | Consultation |
151
+ |--------|----------------------|--------------|
152
+ | Mode | Passive observer | Active request/response |
153
+ | Trigger | Phase start (automatic) | Leader-initiated (on demand) |
154
+ | Model | Haiku | Sonnet |
155
+ | Output | Observation file | Structured recommendation |
156
+ | Lifecycle | Background process | Synchronous spawn |
157
+
146
158
  ## Related Infrastructure
147
159
 
148
160
  | Component | Status | Purpose |
@@ -11,7 +11,7 @@ Work on multiple stories in parallel using git worktrees.
11
11
  ## Quick Start
12
12
 
13
13
  ```
14
- /parallel-work
14
+ /pf-session parallel
15
15
  ```
16
16
 
17
17
  This creates a worktree, sets up the session, and starts the TDD flow.
@@ -85,7 +85,7 @@ Ports are stored in the session file and passed to agents.
85
85
 
86
86
  | Command | Purpose |
87
87
  |---------|---------|
88
- | `/parallel-work` | Start a new parallel work session |
88
+ | `/pf-session parallel` | Start a new parallel work session |
89
89
  | `.pennyfarthing/scripts/git/worktree-manager.sh list` | Show active worktrees |
90
90
  | `.pennyfarthing/scripts/git/worktree-manager.sh remove <name>` | Clean up a worktree |
91
91
 
@@ -94,7 +94,7 @@ Ports are stored in the session file and passed to agents.
94
94
  Same flow as main checkout:
95
95
 
96
96
  ```
97
- /parallel-work → SM → TEA → Dev → Reviewer → SM (finish)
97
+ /pf-session parallel → SM → TEA → Dev → Reviewer → SM (finish)
98
98
  ```
99
99
 
100
100
  Agents use worktree paths from session file for all operations.
@@ -21,7 +21,7 @@ Tags that affect LLM behavior and attention.
21
21
  **Examples:**
22
22
  - "Subagent output is NOT visible to Cyclist"
23
23
  - "NEVER mark acceptance criteria as complete" (for subagents)
24
- - "Write assessment BEFORE spawning handoff subagent"
24
+ - "Write assessment BEFORE starting exit protocol"
25
25
 
26
26
  ### `<gate>`
27
27
 
@@ -135,7 +135,7 @@ Read `**Workflow:**` and `**Phase:**` from session. Query:
135
135
  OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
136
136
  ```
137
137
 
138
- **If OWNER != "dev":** Run `handoff-marker.sh $OWNER`, output result, tell user.
138
+ **If OWNER != "dev":** Run `pf handoff marker $OWNER`, output result, tell user.
139
139
  </phase-check>
140
140
  ```
141
141
 
@@ -150,8 +150,9 @@ OWNER=$(.pennyfarthing/scripts/workflow/phase-owner.sh {workflow} {phase})
150
150
  ## MANDATORY: Complete Before Exiting
151
151
 
152
152
  - [ ] Write Assessment to session file
153
- - [ ] Spawn `handoff` subagent
154
- - [ ] Verify handoff completed (subagent emits marker)
153
+ - [ ] Run `pf handoff resolve-gate` — verify gate status
154
+ - [ ] Run `pf handoff complete-phase` atomic session update
155
+ - [ ] Run `pf handoff marker {next_agent}` — emit marker and EXIT
155
156
  </handoff-gate>
156
157
  ```
157
158