@chankov/agent-fleet 1.0.2 → 1.0.3

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 (325) hide show
  1. package/.pi/harnesses/agent-hub/README.md +60 -60
  2. package/.pi/harnesses/agent-hub/context-window.js +1 -1
  3. package/.pi/harnesses/agent-hub/drift-watchdog.js +11 -4
  4. package/.pi/harnesses/agent-hub/execution-profile.ts +69 -0
  5. package/.pi/harnesses/agent-hub/footer.ts +3 -2
  6. package/.pi/harnesses/agent-hub/hub-state-audit.js +0 -14
  7. package/.pi/harnesses/agent-hub/index.ts +351 -261
  8. package/.pi/harnesses/agent-hub/package.json +1 -1
  9. package/.pi/harnesses/agent-hub/provider-semaphore.js +1 -1
  10. package/.pi/harnesses/agent-hub/run-budget.js +67 -69
  11. package/.pi/harnesses/coms/package.json +1 -1
  12. package/.pi/harnesses/damage-control-continue/package.json +1 -1
  13. package/.pi/harnesses/lib/fleet-dashboard-view.ts +3 -1
  14. package/.pi/harnesses/lib/fleet-detail-view.ts +39 -4
  15. package/.versions/1.0.3/.pi/agents/dispatch-policy.yaml +32 -0
  16. package/.versions/1.0.3/.pi/agents/model-profiles.yaml +27 -0
  17. package/.versions/1.0.3/.pi/agents/peers.yaml +142 -0
  18. package/.versions/1.0.3/.pi/agents/teams.yaml +41 -0
  19. package/.versions/1.0.3/.pi/damage-control-rules.yaml +297 -0
  20. package/.versions/1.0.3/.pi/extensions/agent-fleet-update-check/README.md +57 -0
  21. package/.versions/1.0.3/.pi/extensions/agent-fleet-update-check/index.ts +161 -0
  22. package/.versions/1.0.3/.pi/extensions/agent-fleet-update-check/package.json +6 -0
  23. package/.versions/1.0.3/.pi/extensions/btw/README.md +120 -0
  24. package/.versions/1.0.3/.pi/extensions/btw/index.ts +914 -0
  25. package/.versions/1.0.3/.pi/extensions/btw/package.json +6 -0
  26. package/.versions/1.0.3/.pi/extensions/btw/state.js +179 -0
  27. package/.versions/1.0.3/.pi/extensions/chrome-devtools-mcp/README.md +55 -0
  28. package/.versions/1.0.3/.pi/extensions/chrome-devtools-mcp/index.ts +93 -0
  29. package/.versions/1.0.3/.pi/extensions/chrome-devtools-mcp/package.json +6 -0
  30. package/.versions/1.0.3/.pi/extensions/compact-and-continue/README.md +42 -0
  31. package/.versions/1.0.3/.pi/extensions/compact-and-continue/index.ts +120 -0
  32. package/.versions/1.0.3/.pi/extensions/compact-and-continue/package.json +6 -0
  33. package/.versions/1.0.3/.pi/extensions/mcp-bridge/README.md +46 -0
  34. package/.versions/1.0.3/.pi/extensions/mcp-bridge/index.ts +206 -0
  35. package/.versions/1.0.3/.pi/extensions/mcp-bridge/package.json +6 -0
  36. package/.versions/1.0.3/.pi/extensions/package-lock.json +1175 -0
  37. package/.versions/1.0.3/.pi/extensions/package.json +9 -0
  38. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/README.md +205 -0
  39. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/config.ts +198 -0
  40. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/examples/stt.json +35 -0
  41. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/index.ts +248 -0
  42. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/package.json +6 -0
  43. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/providers.ts +214 -0
  44. package/.versions/1.0.3/.pi/extensions/pi-voice-stt/recorder.ts +158 -0
  45. package/.versions/1.0.3/.pi/harnesses/agent-hub/README.md +1156 -0
  46. package/.versions/1.0.3/.pi/harnesses/agent-hub/access-approval.ts +135 -0
  47. package/.versions/1.0.3/.pi/harnesses/agent-hub/artifacts.js +146 -0
  48. package/.versions/1.0.3/.pi/harnesses/agent-hub/assertion-ledger.js +58 -0
  49. package/.versions/1.0.3/.pi/harnesses/agent-hub/backend-policy.js +174 -0
  50. package/.versions/1.0.3/.pi/harnesses/agent-hub/budget-continuation.ts +73 -0
  51. package/.versions/1.0.3/.pi/harnesses/agent-hub/capability-confirmation.ts +47 -0
  52. package/.versions/1.0.3/.pi/harnesses/agent-hub/capability-packs.ts +180 -0
  53. package/.versions/1.0.3/.pi/harnesses/agent-hub/context-budget-snapshot.ts +105 -0
  54. package/.versions/1.0.3/.pi/harnesses/agent-hub/context-pressure.ts +191 -0
  55. package/.versions/1.0.3/.pi/harnesses/agent-hub/context-window.js +106 -0
  56. package/.versions/1.0.3/.pi/harnesses/agent-hub/delegate.ts +435 -0
  57. package/.versions/1.0.3/.pi/harnesses/agent-hub/docs-lane.js +122 -0
  58. package/.versions/1.0.3/.pi/harnesses/agent-hub/drift-watchdog.js +218 -0
  59. package/.versions/1.0.3/.pi/harnesses/agent-hub/evidence-rules.js +96 -0
  60. package/.versions/1.0.3/.pi/harnesses/agent-hub/execution-profile.ts +69 -0
  61. package/.versions/1.0.3/.pi/harnesses/agent-hub/external-blocker.js +85 -0
  62. package/.versions/1.0.3/.pi/harnesses/agent-hub/footer.ts +36 -0
  63. package/.versions/1.0.3/.pi/harnesses/agent-hub/helpers.ts +266 -0
  64. package/.versions/1.0.3/.pi/harnesses/agent-hub/hub-state-audit.js +59 -0
  65. package/.versions/1.0.3/.pi/harnesses/agent-hub/index.ts +9999 -0
  66. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-control.ts +9 -0
  67. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-invoke-journal.ts +131 -0
  68. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-invoke.ts +92 -0
  69. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-lifecycle.ts +13 -0
  70. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-publisher.ts +59 -0
  71. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-recovery.ts +3 -0
  72. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-runtime.ts +3 -0
  73. package/.versions/1.0.3/.pi/harnesses/agent-hub/monitor-session-bridge.ts +266 -0
  74. package/.versions/1.0.3/.pi/harnesses/agent-hub/package.json +7 -0
  75. package/.versions/1.0.3/.pi/harnesses/agent-hub/peer-spawn-plan.ts +116 -0
  76. package/.versions/1.0.3/.pi/harnesses/agent-hub/posture.ts +158 -0
  77. package/.versions/1.0.3/.pi/harnesses/agent-hub/provider-semaphore.js +138 -0
  78. package/.versions/1.0.3/.pi/harnesses/agent-hub/research-retention.js +34 -0
  79. package/.versions/1.0.3/.pi/harnesses/agent-hub/research-watchdog.ts +40 -0
  80. package/.versions/1.0.3/.pi/harnesses/agent-hub/return-contract.js +293 -0
  81. package/.versions/1.0.3/.pi/harnesses/agent-hub/return-extract.js +75 -0
  82. package/.versions/1.0.3/.pi/harnesses/agent-hub/review-findings.js +102 -0
  83. package/.versions/1.0.3/.pi/harnesses/agent-hub/run-budget.js +537 -0
  84. package/.versions/1.0.3/.pi/harnesses/agent-hub/run-namespace.js +87 -0
  85. package/.versions/1.0.3/.pi/harnesses/agent-hub/safety-routing.ts +22 -0
  86. package/.versions/1.0.3/.pi/harnesses/agent-hub/scope-gate.js +103 -0
  87. package/.versions/1.0.3/.pi/harnesses/agent-hub/session-health.js +110 -0
  88. package/.versions/1.0.3/.pi/harnesses/agent-hub/spawn.ts +366 -0
  89. package/.versions/1.0.3/.pi/harnesses/agent-hub/version.ts +42 -0
  90. package/.versions/1.0.3/.pi/harnesses/ask-user-remote/README.md +53 -0
  91. package/.versions/1.0.3/.pi/harnesses/ask-user-remote/index.ts +532 -0
  92. package/.versions/1.0.3/.pi/harnesses/ask-user-remote/race-core.js +106 -0
  93. package/.versions/1.0.3/.pi/harnesses/coms/README.md +100 -0
  94. package/.versions/1.0.3/.pi/harnesses/coms/index.ts +1767 -0
  95. package/.versions/1.0.3/.pi/harnesses/coms/package.json +7 -0
  96. package/.versions/1.0.3/.pi/harnesses/coms/version.ts +42 -0
  97. package/.versions/1.0.3/.pi/harnesses/damage-control-continue/README.md +124 -0
  98. package/.versions/1.0.3/.pi/harnesses/damage-control-continue/index.ts +536 -0
  99. package/.versions/1.0.3/.pi/harnesses/damage-control-continue/package.json +7 -0
  100. package/.versions/1.0.3/.pi/harnesses/damage-control-continue/version.ts +42 -0
  101. package/.versions/1.0.3/.pi/harnesses/lib/coms-registry-entry.ts +94 -0
  102. package/.versions/1.0.3/.pi/harnesses/lib/context-budget-child-prompt.ts +179 -0
  103. package/.versions/1.0.3/.pi/harnesses/lib/context-budget-hub-prompt.ts +116 -0
  104. package/.versions/1.0.3/.pi/harnesses/lib/context-budget-view.ts +107 -0
  105. package/.versions/1.0.3/.pi/harnesses/lib/context-budget.ts +114 -0
  106. package/.versions/1.0.3/.pi/harnesses/lib/damage-control-shared.ts +197 -0
  107. package/.versions/1.0.3/.pi/harnesses/lib/fixtures/context-budget-profiles.json +11 -0
  108. package/.versions/1.0.3/.pi/harnesses/lib/fixtures/hub-prompt-operator.legacy.txt +73 -0
  109. package/.versions/1.0.3/.pi/harnesses/lib/fixtures/hub-prompt-orchestrator.legacy.txt +73 -0
  110. package/.versions/1.0.3/.pi/harnesses/lib/fleet-dashboard-ops.ts +155 -0
  111. package/.versions/1.0.3/.pi/harnesses/lib/fleet-dashboard-view.ts +142 -0
  112. package/.versions/1.0.3/.pi/harnesses/lib/fleet-detail-view.ts +168 -0
  113. package/.versions/1.0.3/.pi/harnesses/lib/fleet-overlay.ts +26 -0
  114. package/.versions/1.0.3/.pi/harnesses/lib/fleet-panel.ts +34 -0
  115. package/.versions/1.0.3/.pi/harnesses/lib/fleet-read-model.ts +131 -0
  116. package/.versions/1.0.3/.pi/harnesses/lib/fleet-selection.ts +24 -0
  117. package/.versions/1.0.3/.pi/harnesses/lib/herdr-client.ts +472 -0
  118. package/.versions/1.0.3/.pi/harnesses/lib/herdr-presence.ts +399 -0
  119. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-events.ts +136 -0
  120. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
  121. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-model.ts +18 -0
  122. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
  123. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-socket.ts +163 -0
  124. package/.versions/1.0.3/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
  125. package/.versions/1.0.3/.pi/harnesses/lib/spawned-peers.js +190 -0
  126. package/.versions/1.0.3/.pi/harnesses/package-lock.json +2039 -0
  127. package/.versions/1.0.3/.pi/harnesses/package.json +10 -0
  128. package/.versions/1.0.3/.pi/prompts/af-build.md +24 -0
  129. package/.versions/1.0.3/.pi/prompts/af-code-simplify.md +22 -0
  130. package/.versions/1.0.3/.pi/prompts/af-plan.md +16 -0
  131. package/.versions/1.0.3/.pi/prompts/af-review.md +16 -0
  132. package/.versions/1.0.3/.pi/prompts/af-set-hermes-telegram.md +15 -0
  133. package/.versions/1.0.3/.pi/prompts/af-set-hermes-watchdog.md +6 -0
  134. package/.versions/1.0.3/.pi/prompts/af-ship.md +17 -0
  135. package/.versions/1.0.3/.pi/prompts/af-spec.md +15 -0
  136. package/.versions/1.0.3/.pi/prompts/af-test.md +19 -0
  137. package/.versions/1.0.3/.pi/skills/bowser/SKILL.md +145 -0
  138. package/.versions/1.0.3/.version +1 -0
  139. package/.versions/1.0.3/agents/architect.md +25 -0
  140. package/.versions/1.0.3/agents/bowser.md +28 -0
  141. package/.versions/1.0.3/agents/builder.md +55 -0
  142. package/.versions/1.0.3/agents/code-reviewer.md +209 -0
  143. package/.versions/1.0.3/agents/deep-researcher.md +33 -0
  144. package/.versions/1.0.3/agents/documenter.md +19 -0
  145. package/.versions/1.0.3/agents/orchestrator.md +21 -0
  146. package/.versions/1.0.3/agents/plan-reviewer.md +84 -0
  147. package/.versions/1.0.3/agents/planner.md +71 -0
  148. package/.versions/1.0.3/agents/releaser.md +25 -0
  149. package/.versions/1.0.3/agents/researcher.md +29 -0
  150. package/.versions/1.0.3/agents/security-auditor.md +168 -0
  151. package/.versions/1.0.3/agents/test-engineer.md +154 -0
  152. package/.versions/1.0.3/agents/web-debugger.md +44 -0
  153. package/.versions/1.0.3/agents/web-performance-auditor.md +194 -0
  154. package/.versions/1.0.3/bin/catalog/harness-runtime-closure.json +38 -0
  155. package/.versions/1.0.3/codex/CONDUCTOR.md +148 -0
  156. package/.versions/1.0.3/docs/ARCHITECTURE.md +375 -0
  157. package/.versions/1.0.3/docs/agent-fleet-setup.md +468 -0
  158. package/.versions/1.0.3/docs/claude-code-coms-bridge.md +128 -0
  159. package/.versions/1.0.3/docs/codex-remote-conductor.md +170 -0
  160. package/.versions/1.0.3/docs/coms-hermes-bridge.md +189 -0
  161. package/.versions/1.0.3/docs/getting-started.md +98 -0
  162. package/.versions/1.0.3/docs/npm-install.md +292 -0
  163. package/.versions/1.0.3/docs/pi-extensions.md +441 -0
  164. package/.versions/1.0.3/docs/pi-setup.md +74 -0
  165. package/.versions/1.0.3/docs/skill-anatomy.md +150 -0
  166. package/.versions/1.0.3/hermes/README.md +347 -0
  167. package/.versions/1.0.3/hermes/desktop-plugins/agent-fleet-herdr/plugin.js +1291 -0
  168. package/.versions/1.0.3/hermes/desktop-plugins/agent-fleet-herdr/presentation.js +672 -0
  169. package/.versions/1.0.3/hermes/desktop-plugins/agent-fleet-monitor/plugin.js +19 -0
  170. package/.versions/1.0.3/hermes/desktop-plugins/agent-fleet-monitor/state.js +10 -0
  171. package/.versions/1.0.3/hermes/gates/gate-o-capability.md +8 -0
  172. package/.versions/1.0.3/hermes/gates/gate-o-validator-fixtures.json +1 -0
  173. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/activity.py +770 -0
  174. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/coms_registry.py +134 -0
  175. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/coms_send.py +350 -0
  176. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/herdr_source.py +193 -0
  177. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/manifest.json +4 -0
  178. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/plugin_api.py +444 -0
  179. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/sessions.py +205 -0
  180. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/tasks.py +300 -0
  181. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/dashboard/watch.py +819 -0
  182. package/.versions/1.0.3/hermes/plugins/agent-fleet-herdr/plugin.yaml +8 -0
  183. package/.versions/1.0.3/hermes/plugins/agent-fleet-monitor/dashboard/adapter.py +139 -0
  184. package/.versions/1.0.3/hermes/plugins/agent-fleet-monitor/dashboard/manifest.json +11 -0
  185. package/.versions/1.0.3/hermes/plugins/agent-fleet-monitor/dashboard/plugin_api.py +50 -0
  186. package/.versions/1.0.3/hermes/skills/hub-conductor/SKILL.md +84 -0
  187. package/.versions/1.0.3/hermes/skills/hub-liaison/SKILL.md +84 -0
  188. package/.versions/1.0.3/hermes/skills/hub-watchdog/SKILL.md +76 -0
  189. package/.versions/1.0.3/hermes/skills/hub-watchdog/manifest.json +1 -0
  190. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog.py +249 -0
  191. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_actions.py +124 -0
  192. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_contract.py +76 -0
  193. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_delivery.py +10 -0
  194. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_engine.py +128 -0
  195. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_judgment.py +41 -0
  196. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_recovery.py +103 -0
  197. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_state.py +163 -0
  198. package/.versions/1.0.3/hermes/skills/hub-watchdog/scripts/watchdog_transport.py +138 -0
  199. package/.versions/1.0.3/hermes/watchdog-tests/__init__.py +0 -0
  200. package/.versions/1.0.3/hooks/coms-stop-hook.mjs +84 -0
  201. package/.versions/1.0.3/install-manifest.json +2745 -0
  202. package/.versions/1.0.3/justfile +272 -0
  203. package/.versions/1.0.3/manifest-meta.json +882 -0
  204. package/.versions/1.0.3/references/accessibility-checklist.md +160 -0
  205. package/.versions/1.0.3/references/definition-of-done.md +67 -0
  206. package/.versions/1.0.3/references/fleet-coordination-patterns.md +151 -0
  207. package/.versions/1.0.3/references/observability-checklist.md +91 -0
  208. package/.versions/1.0.3/references/orchestration-patterns.md +370 -0
  209. package/.versions/1.0.3/references/performance-checklist.md +153 -0
  210. package/.versions/1.0.3/references/prompting-patterns.md +380 -0
  211. package/.versions/1.0.3/references/security-checklist.md +179 -0
  212. package/.versions/1.0.3/references/testing-patterns.md +236 -0
  213. package/.versions/1.0.3/scripts/codex-conductor.ts +41 -0
  214. package/.versions/1.0.3/scripts/codex-remote-control.ts +167 -0
  215. package/.versions/1.0.3/scripts/coms-claude-bridge.ts +411 -0
  216. package/.versions/1.0.3/scripts/coms-cli.ts +484 -0
  217. package/.versions/1.0.3/scripts/coms-hermes-bridge.ts +413 -0
  218. package/.versions/1.0.3/scripts/fleet.ts +185 -0
  219. package/.versions/1.0.3/scripts/hermes-monitor-capability-runner.ts +25 -0
  220. package/.versions/1.0.3/scripts/hermes-monitor-scenario.ts +474 -0
  221. package/.versions/1.0.3/scripts/hermes-watchdog-capability-probe.ts +45 -0
  222. package/.versions/1.0.3/scripts/install-hermes-plugin.sh +180 -0
  223. package/.versions/1.0.3/scripts/lib/claude-bridge-core.ts +210 -0
  224. package/.versions/1.0.3/scripts/lib/codex-conductor.ts +88 -0
  225. package/.versions/1.0.3/scripts/lib/codex-remote-control.ts +480 -0
  226. package/.versions/1.0.3/scripts/lib/coms-envelope.ts +582 -0
  227. package/.versions/1.0.3/scripts/lib/fake-herdr-server.ts +88 -0
  228. package/.versions/1.0.3/scripts/lib/fleet-command.ts +266 -0
  229. package/.versions/1.0.3/scripts/lib/herdr-layout.ts +281 -0
  230. package/.versions/1.0.3/scripts/lib/hermes-bridge-core.ts +241 -0
  231. package/.versions/1.0.3/scripts/lib/hermes-monitor-events.ts +1 -0
  232. package/.versions/1.0.3/scripts/lib/hermes-monitor-herdr.ts +2 -0
  233. package/.versions/1.0.3/scripts/lib/hermes-monitor-model.ts +3 -0
  234. package/.versions/1.0.3/scripts/lib/hermes-monitor-registry.ts +2 -0
  235. package/.versions/1.0.3/scripts/lib/hermes-monitor-socket.ts +2 -0
  236. package/.versions/1.0.3/scripts/lib/hermes-monitor-store.ts +2 -0
  237. package/.versions/1.0.3/scripts/lib/monitor-env.ts +146 -0
  238. package/.versions/1.0.3/scripts/lib/peer-launch.ts +318 -0
  239. package/.versions/1.0.3/scripts/lib/persona-banner.ts +62 -0
  240. package/.versions/1.0.3/scripts/lib/spawn-stagger.ts +101 -0
  241. package/.versions/1.0.3/scripts/lib/team-project.ts +213 -0
  242. package/.versions/1.0.3/scripts/lib/team-snapshot.ts +147 -0
  243. package/.versions/1.0.3/scripts/peer-banner.ts +40 -0
  244. package/.versions/1.0.3/scripts/peer-launch.ts +259 -0
  245. package/.versions/1.0.3/scripts/team-snapshot.ts +237 -0
  246. package/.versions/1.0.3/scripts/team-up.ts +406 -0
  247. package/.versions/1.0.3/skills/_internal/grilling.md +11 -0
  248. package/.versions/1.0.3/skills/browser-testing-with-devtools/SKILL.md +351 -0
  249. package/.versions/1.0.3/skills/code-review-and-quality/SKILL.md +381 -0
  250. package/.versions/1.0.3/skills/compound-learning/SKILL.md +137 -0
  251. package/.versions/1.0.3/skills/context-engineering/SKILL.md +291 -0
  252. package/.versions/1.0.3/skills/deprecation-and-migration/SKILL.md +206 -0
  253. package/.versions/1.0.3/skills/designing-agents/SKILL.md +394 -0
  254. package/.versions/1.0.3/skills/designing-agents/pi-harness-authoring.md +222 -0
  255. package/.versions/1.0.3/skills/frontend-ui-engineering/SKILL.md +328 -0
  256. package/.versions/1.0.3/skills/git-workflow-and-versioning/SKILL.md +316 -0
  257. package/.versions/1.0.3/skills/idea-refine/SKILL.md +182 -0
  258. package/.versions/1.0.3/skills/idea-refine/examples.md +238 -0
  259. package/.versions/1.0.3/skills/idea-refine/frameworks.md +99 -0
  260. package/.versions/1.0.3/skills/idea-refine/refinement-criteria.md +113 -0
  261. package/.versions/1.0.3/skills/idea-refine/scripts/idea-refine.sh +15 -0
  262. package/.versions/1.0.3/skills/incremental-implementation/SKILL.md +287 -0
  263. package/.versions/1.0.3/skills/interview-me/SKILL.md +226 -0
  264. package/.versions/1.0.3/skills/orchestration-verification/SKILL.md +181 -0
  265. package/.versions/1.0.3/skills/peer-coms/SKILL.md +90 -0
  266. package/.versions/1.0.3/skills/performance-optimization/SKILL.md +350 -0
  267. package/.versions/1.0.3/skills/planning-and-task-breakdown/SKILL.md +254 -0
  268. package/.versions/1.0.3/skills/security-and-hardening/SKILL.md +461 -0
  269. package/.versions/1.0.3/skills/spec-driven-development/SKILL.md +257 -0
  270. package/.versions/1.0.3/skills/using-agent-skills/SKILL.md +199 -0
  271. package/.versions/1.0.3/systemd/user/agent-fleet-codex-remote-control.service.in +23 -0
  272. package/.versions/1.0.3/vendor/agent-skills-upstream/LICENSE +21 -0
  273. package/.versions/1.0.3/vendor/agent-skills-upstream/README.md +11 -0
  274. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/api-and-interface-design/SKILL.md +294 -0
  275. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/browser-testing-with-devtools/SKILL.md +317 -0
  276. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/ci-cd-and-automation/SKILL.md +390 -0
  277. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/code-review-and-quality/SKILL.md +396 -0
  278. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/code-simplification/SKILL.md +331 -0
  279. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/context-engineering/SKILL.md +289 -0
  280. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/debugging-and-error-recovery/SKILL.md +300 -0
  281. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/deprecation-and-migration/SKILL.md +247 -0
  282. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/documentation-and-adrs/SKILL.md +278 -0
  283. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/doubt-driven-development/SKILL.md +243 -0
  284. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/frontend-ui-engineering/SKILL.md +328 -0
  285. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/git-workflow-and-versioning/SKILL.md +355 -0
  286. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/idea-refine/SKILL.md +178 -0
  287. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/idea-refine/examples.md +238 -0
  288. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/idea-refine/frameworks.md +99 -0
  289. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/idea-refine/refinement-criteria.md +113 -0
  290. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/idea-refine/scripts/idea-refine.sh +15 -0
  291. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/incremental-implementation/SKILL.md +249 -0
  292. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/interview-me/SKILL.md +225 -0
  293. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/observability-and-instrumentation/SKILL.md +203 -0
  294. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/performance-optimization/SKILL.md +350 -0
  295. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/planning-and-task-breakdown/SKILL.md +234 -0
  296. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/security-and-hardening/SKILL.md +467 -0
  297. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/shipping-and-launch/SKILL.md +310 -0
  298. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/source-driven-development/SKILL.md +194 -0
  299. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/spec-driven-development/SKILL.md +206 -0
  300. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/test-driven-development/SKILL.md +383 -0
  301. package/.versions/1.0.3/vendor/agent-skills-upstream/skills/using-agent-skills/SKILL.md +191 -0
  302. package/CHANGELOG.md +6 -0
  303. package/README.md +5 -4
  304. package/agents/architect.md +1 -0
  305. package/agents/bowser.md +1 -0
  306. package/agents/builder.md +1 -0
  307. package/agents/code-reviewer.md +1 -0
  308. package/agents/deep-researcher.md +1 -0
  309. package/agents/documenter.md +1 -0
  310. package/agents/orchestrator.md +1 -0
  311. package/agents/plan-reviewer.md +1 -0
  312. package/agents/planner.md +1 -0
  313. package/agents/releaser.md +1 -0
  314. package/agents/researcher.md +1 -0
  315. package/agents/security-auditor.md +1 -0
  316. package/agents/test-engineer.md +1 -0
  317. package/agents/web-debugger.md +1 -0
  318. package/agents/web-performance-auditor.md +1 -0
  319. package/bin/lib/validate-overrides.js +1 -1
  320. package/docs/ARCHITECTURE.md +25 -19
  321. package/docs/agent-fleet-setup.md +8 -8
  322. package/docs/pi-extensions.md +4 -2
  323. package/install-manifest.json +1 -1
  324. package/package.json +2 -2
  325. package/scripts/fleet.ts +1 -1
@@ -26,14 +26,16 @@ These are independent runtime axes:
26
26
  extension tools, and orchestration. Orchestrator withholds direct coding tools but keeps
27
27
  dispatch, research, assertions, roster controls, `ask_user`, ready coms, and ready Herdr tools.
28
28
  In orchestrator posture, raw Herdr panes are auxiliary-process orchestration—not a route around
29
- delegation for reading, editing, testing, or implementing code.
29
+ delegation for reading, editing, testing, or implementing code. With no argument, `/af-posture`
30
+ opens a two-option picker.
30
31
  - **Native roster** — local headless Pi specialists from `.pi/agents/teams.yaml`. Bare Fleet starts
31
32
  empty; select one with `--agents frontend` or add one live with `/af-agents-add code-reviewer`.
32
33
  - **Peer topology** — separate long-lived Pi or Claude Code processes from `peers.yaml`, connected
33
34
  by coms and optionally placed in sibling Herdr panes. `--peers frontend` selects a standing
34
35
  preset; `--herdr` creates a Hub-only workspace through the empty `base` preset.
35
- - **Hub mode** — `/af-hub-mode` controls orchestration strictness and budgets; it does not change
36
- posture, roster, or topology.
36
+ - **Posture shortcuts** — `/af-work-mode` and **Alt+M** switch operator vs orchestrator. Orchestrator
37
+ still requires a native roster. Budgets, nested delegation, and Verification Contract rigor follow
38
+ the **task tier**, not a session execution mode.
37
39
 
38
40
  All Hub slash commands, including `/af-handoff`, are registered in both postures. A command whose
39
41
  runtime capability is unavailable refuses with remediation rather than disappearing. `--no-coms`
@@ -99,6 +101,7 @@ Recover with one of these explicit choices:
99
101
  ```text
100
102
  /af-agents-team # select a currently valid team in the live session
101
103
  /af-posture operator # explicitly leave delegate-only posture
104
+ /af-work-mode operator # restore direct tools
102
105
  just fleet --agents <name> # restart through the public Fleet CLI
103
106
  just fleet --posture operator # restart explicitly as an operator
104
107
  ```
@@ -247,8 +250,9 @@ Every borrowed idea from another harness passes one test before it lands: *does
247
250
  children inherit it). `/af-models [profile]` applies a named profile
248
251
  from `.pi/agents/model-profiles.yaml` — a macro over the same declared candidates, validated at
249
252
  session start (a profile with any entry outside a persona's candidates is dropped whole, with an
250
- error); profiles never touch sub-role models — only `/af-agent-model` reaches those. Nothing
251
- outside the declared lists is ever selectable. When an effective project or session override
253
+ error); profiles never touch sub-role models — only `/af-agent-model` reaches those. Those
254
+ declared-candidate commands stay within their lists; Fleet Detail and the session-wide
255
+ substitution target picker intentionally use Pi's currently available registry. When an effective project or session override
252
256
  fails with a model/provider error or aborted request before work begins (including local-model
253
257
  memory-limit failures), the hub retries once with the model originally declared in the persona
254
258
  frontmatter. For **write-capable** runs this is pre-work only: no fallback occurs after text
@@ -265,12 +269,14 @@ Every borrowed idea from another harness passes one test before it lands: *does
265
269
  way — `/af-agent-model <persona>` and `/af-agent-model-thinking <persona>` accept them alongside team
266
270
  members. Since research helpers are spawned fresh on each `/af-research` / `spawn_research`, the
267
271
  switch lands on their next spawn (there is no running instance to `/af-agents-restart`).
268
- `/af-agent-models-substitute <source> <target>` is the global one-shot form: walks every loaded
269
- persona (team + research + orchestrator), and for each whose **current effective model** is
270
- `<source>` and whose declared candidates include `<target>`, sets the session override to
271
- `<target>`. One-step flow — the dry-run summary (affected vs skipped, with reasons) is shown
272
- inline, then the swap is applied immediately and takes effect on each persona's next dispatch
273
- (`/af-agents-restart` to apply now). It never touches the dispatcher or delegate sub-roles.
272
+ `/af-agent-models-substitute [<source> <target>]` saves a runtime source → target mapping for
273
+ the current session. With no arguments it opens the same two-step visual picker as `m` in Fleet
274
+ Dashboard: first choose a source from every model configured across persona defaults, candidates,
275
+ fallbacks, and delegate sub-roles; then choose a target from Pi's currently available models. The
276
+ two-argument form performs the same operation directly. The mapping is resolved when work is
277
+ spawned rather than eagerly copied into today's roster, so team members, research personas, and
278
+ delegate sub-roles activated or created later in the session inherit it automatically. Existing
279
+ runs are not interrupted, and all mappings reset at the next `session_start`.
274
280
  - **Thinking levels** — each persona's frontmatter `thinking:` sets its pi `--thinking`
275
281
  reasoning effort (`off` · `minimal` · `low` · `medium` · `high` · `xhigh`). `/af-agent-model-thinking
276
282
  <persona>` switches it among those six levels for the session; like a model switch it takes effect
@@ -373,7 +379,14 @@ The agent view starts with the **compact widget** enabled: one line per *running
373
379
  `name · context% · state` — *below* the input box, just above pi's status bar. Idle and done agents
374
380
  are hidden, and the coms pool widget collapses too, so an idle session collapses to just the prompt
375
381
  and footer. **`Alt+Shift+A`** toggles that widget on or off; the footer reports
376
- `Alt+A fleet · Alt+Shift+A widget:compact|off`.
382
+ `Alt+A fleet · Alt+M Operator · Alt+Shift+A widget:compact|off`.
383
+
384
+ ### Posture picker
385
+
386
+ Press **`Alt+M`** or run **`/af-work-mode`** / **`/af-posture`** to open the posture picker:
387
+ **operator** (direct tools) or **orchestrator** (delegate-only). Arrow keys move, Enter applies,
388
+ and Esc cancels with no change. Orchestrator requires a native roster. On macOS, the outer
389
+ terminal must send Option as Meta or Alt+M will not reach the Hub.
377
390
 
378
391
  ### Fleet Dashboard and detail
379
392
 
@@ -533,50 +546,36 @@ and forward parent cancellation, avoiding detached-orphan processes. Caller
533
546
  cancellation follows the same bounded cleanup path but is reported as `cancelled`, not
534
547
  `tool_timeout`.
535
548
 
536
- ### Execution modes & turn budgets
537
-
538
- The hub runs one of three **execution modes** — `fast`, `standard` (default), `strict` —
539
- with **per-user-turn budgets enforced in code**, not prose. This is the guardrail against
540
- runaway orchestration (the observed failure mode: 100+ dispatches and 100M+ tokens for one
541
- task, most of it re-billed stale specialist context).
542
-
543
- | Budget (per user turn) | fast | standard | strict |
544
- |-----------------------------------|--------|----------|---------|
545
- | `dispatch_agent` calls | 2 | 8 | 24 |
546
- | `spawn_research` calls | 1 | 4 | 12 |
547
- | Turn wall clock | 15 min | 60 min | 240 min |
548
- | Per-run deadline (specialist/research/delegate) | 10 min | 30 min | off |
549
- | Specialist session recycled after | 3 runs | 5 runs | 5 runs |
550
- | Nested delegation | off | on | on |
551
-
552
- - **fast** — single-specialist path for small, low-risk asks; assertion ledger optional,
553
- no nested delegation.
554
- - **standard** — batched execution: one recon max, builder batches of 4–6 plan tasks with
555
- one gate each, one review gate at the end.
556
- - **strict** — the full Verification Contract (parity inventories, per-batch gates,
557
- second confirming reads); use for production migrations and security-sensitive work.
549
+ ### Task-tier budgets
550
+
551
+ The hub runs **per-user-turn budgets enforced in code**, not prose, keyed off the current
552
+ **task tier**. This is the guardrail against runaway orchestration (the observed failure
553
+ mode: 100+ dispatches and 100M+ tokens for one task, most of it re-billed stale specialist
554
+ context).
555
+
556
+ | Budget (per user turn) | trivial | small | feature | project |
557
+ |-----------------------------------|---------|-------|---------|---------|
558
+ | `dispatch_agent` calls | 1 | 2 | 8 | 12 |
559
+ | `spawn_research` calls | 1 | 2 | 4 | 6 |
560
+ | Turn wall clock | 15 min | 15 min| 60 min | 90 min |
561
+ | Per-run deadline (specialist/research/delegate) | 10 min | 10 min | 30 min | 30 min |
562
+ | Specialist session recycled after | 3 runs | 3 runs| 5 runs | 5 runs |
563
+ | Nested delegation | off | off | on | on |
558
564
 
559
565
  When a budget is exhausted, `dispatch_agent`/`spawn_research` **refuse** with instructions
560
566
  to summarize and ask one localized Yes/No `ask_user` question. **Yes** renews the turn budget
561
567
  inside the same tool loop; the user does not type `continue` or run a slash command. A normal
562
568
  new user message still opens a fresh turn window. Time blocked in any `ask_user` question is
563
569
  excluded from the turn wall clock, so a slow human answer cannot exhaust the next dispatch.
564
- Switch modes live with `/af-hub-mode fast|standard|strict` (no argument shows the current mode
565
- and usage).
566
- The live switch is deliberately **process/session-local**: it does not mutate another repository,
567
- another pane, or the project's override file. A later `session_start` reapplies that repository's
568
- configured default. Successful live switches and session-start default application append
569
- `agent-hub-mode` entries to the Pi session record with an allowlisted identity (`cwd`, PID, Hub
570
- session/project, and Herdr workspace/pane when available), so a mode change can be attributed to
571
- the process that actually handled it. Set the project default and per-axis overrides in the
572
- overrides file:
570
+ Raise the task with `set_task_tier` when the work outgrew the current envelope. Override keys
571
+ in `.ai/agent-fleet-overrides.md` are a **ceiling** (`min` with the tier); `off` stays at the
572
+ tier rather than lifting the cap. A leftover `mode:` key is ignored with a warning.
573
573
 
574
574
  ```markdown
575
575
  ## agent-hub
576
- mode: standard # fast|standard|strict
577
- max-dispatches-per-turn: 8 # integer or off
578
- max-research-per-turn: 4 # integer or off
579
- turn-wall-time-s: 3600 # integer or off
576
+ max-dispatches-per-turn: 8 # integer ceiling, or off (stays at the tier)
577
+ max-research-per-turn: 4 # integer ceiling, or off (stays at the tier)
578
+ turn-wall-time-s: 3600 # integer ceiling, or off (stays at the tier)
580
579
  agent-turn-timeout-s: 1800 # whole-run deadline per spawned run; integer or off
581
580
  session-recycle-runs: 5 # recycle a specialist session after N resumed runs; integer or off
582
581
  run-history-keep: 10 # previous sessions' artifact archives to retain; integer or off
@@ -592,9 +591,9 @@ workspace took **13 minutes**.
592
591
  So there is a second envelope, **`TASK_BUDGET_MULTIPLIER` (3) × the turn envelope**, whose
593
592
  counters are **not** reset by a user message:
594
593
 
595
- | | per turn (standard, `feature`) | per task |
594
+ | | per turn (`feature`) | per task |
596
595
  |---|---|---|
597
- | `dispatch_agent` | 6 | 18 |
596
+ | `dispatch_agent` | 8 | 24 |
598
597
  | `spawn_research` | 4 | 12 |
599
598
  | clock | 60 min wall | 180 min **active** |
600
599
 
@@ -675,11 +674,9 @@ can no longer hold its parent for hours.
675
674
  ### Task triage (complexity tiers)
676
675
 
677
676
  The dispatcher classifies the current TASK with the `set_task_tier` tool BEFORE its first
678
- dispatch — `trivial` / `small` / `feature` / `project` — and the hub lowers the enforced
679
- dispatch/research caps to **min(mode, tier)**: trivial = 1 dispatch / 1 research,
680
- small = 2 / 2, feature = 6 / 4, `project` defers to the mode. The tier shows in the
681
- `hub-mode` status chip (`Mode: standard·small · …`), with a trailing `?` while it is only
682
- assumed.
677
+ dispatch — `trivial` / `small` / `feature` / `project` — and that classification *is* the
678
+ budget envelope (see the table above). The tier shows in the `hub-tier` status chip
679
+ (`Tier: small · …`), with a trailing `?` while it is only assumed.
683
680
 
684
681
  Skipping the call makes the hub assume **`small`**, not `feature`. Because the tier is
685
682
  task-scoped, a skipped triage latches for the whole task — and skipped triage is precisely
@@ -788,11 +785,14 @@ drives the cards — not post-hoc:
788
785
  partial output preserved) and the dispatch result instructs: re-dispatch ONCE with a
789
786
  corrected, narrowed task — never the same task unchanged.
790
787
 
791
- Enablement is dynamic, precedence top to bottom: the `watchdog: true|false` param on a
792
- single `dispatch_agent` call → a per-agent override (`/af-watchdog builder on|off|clear`) →
793
- the hub-wide setting (`/af-watchdog on|off|auto`, default `auto`, project default via the
794
- `watchdog:` overrides key). Read-only research helpers are not monitored — they already
795
- run under the per-tool watchdog + turn deadline and cannot write.
788
+ Enablement is dynamic. In **operator** posture, precedence is the `watchdog: true|false`
789
+ param on a single `dispatch_agent` call → a per-agent override (`/af-watchdog builder
790
+ on|off|clear`) → the hub-wide setting (`/af-watchdog on|off|auto`, default `auto`, project
791
+ default via the `watchdog:` overrides key): `on`/`auto` arm and `off` disarms. In
792
+ **orchestrator** posture, hub `auto`/`on` auto-arms; dispatch `watchdog: false` cannot
793
+ disarm it. Opt out with hub `/af-watchdog off` (or override `watchdog: off`), or a per-agent
794
+ `off`. Read-only research helpers are not monitored — they already run under the per-tool
795
+ watchdog + turn deadline and cannot write.
796
796
 
797
797
  ### Dynamic teams
798
798
 
@@ -803,7 +803,7 @@ Rosters start from `.pi/agents/teams.yaml` but are not frozen there:
803
803
  - `/af-agents-save <name>` — persist the current roster as a named team back into
804
804
  `teams.yaml` (targeted block upsert; comments and other teams untouched).
805
805
  - `team_adjust` — the dispatcher itself may add/drop a persona **with a stated reason**;
806
- disabled in fast mode, capped at 8 roster members, and every change is notified to the
806
+ disabled at trivial/small tiers, capped at 8 roster members, and every change is notified to the
807
807
  human. The system prompt is rebuilt each turn, so changes take effect immediately.
808
808
 
809
809
  ### `/af-hub-report`
@@ -2,7 +2,7 @@
2
2
  //
3
3
  // The bug this fixes: the hub measured EVERY specialist and research helper
4
4
  // against `ctx.model.contextWindow` — the DISPATCHER's window. A specialist on
5
- // custom/Qwen3.6-35B-A3B-4bit (49152) and one on a 400k hosted model were
5
+ // custom/Qwen3.8-27B-Uncensored-MLX-4bit (49152) and one on a 400k hosted model were
6
6
  // divided by the same number, so `⚠ Planner context at 315%` could mean either
7
7
  // "the window is wrong for that provider" or "the run really did run 3× over",
8
8
  // and nothing in the output told them apart.
@@ -18,11 +18,18 @@ export function normalizeWatchdogSetting(value) {
18
18
  }
19
19
 
20
20
  /**
21
- * Is the watchdog armed for one dispatch? Precedence: the dispatch_agent
22
- * `watchdog` param (boolean) > the per-agent /af-watchdog override ("on"/"off")
23
- * > the hub-wide setting ("on"/"auto" arm, "off" disarms).
21
+ * Is the watchdog armed for one dispatch?
22
+ * Operator (or omitted posture): dispatch param > per-agent /af-watchdog
23
+ * override ("on"/"off") > hub-wide setting ("on"/"auto" arm, "off" disarms).
24
+ * Orchestrator: hub `off` or per-agent `off` still disarms; otherwise armed.
25
+ * A specialist cannot pass `watchdog: false` to sneak around orchestrator.
24
26
  */
25
- export function resolveWatchdogActive(dispatchParam, agentOverride, hubSetting) {
27
+ export function resolveWatchdogActive(dispatchParam, agentOverride, hubSetting, posture) {
28
+ if (posture === "orchestrator") {
29
+ if (normalizeWatchdogSetting(hubSetting) === "off") return false;
30
+ if (agentOverride === "off") return false;
31
+ return true;
32
+ }
26
33
  if (dispatchParam === true) return true;
27
34
  if (dispatchParam === false) return false;
28
35
  if (agentOverride === "on") return true;
@@ -0,0 +1,69 @@
1
+ import { orchestratorNeedsRoster } from "./helpers.ts";
2
+ import { parsePosture, POSTURES, type Posture } from "./posture.ts";
3
+
4
+ export type WorkModeParse =
5
+ | { ok: true; action: "picker" }
6
+ | { ok: true; action: "apply"; posture: Posture; deprecatedFrom?: string }
7
+ | { ok: false; error: string };
8
+
9
+ function titleCase(value: string): string {
10
+ const trimmed = String(value ?? "").trim();
11
+ if (!trimmed) return "";
12
+ return trimmed.charAt(0).toUpperCase() + trimmed.slice(1).toLowerCase();
13
+ }
14
+
15
+ function formatPickerOption(selected: boolean, label: string, description: string): string {
16
+ return `${selected ? "✓ " : " "}${label} — ${description}`;
17
+ }
18
+
19
+ const DEPRECATED_WORK_MODE: Record<string, Posture> = {
20
+ fast: "operator",
21
+ standard: "orchestrator",
22
+ strict: "orchestrator",
23
+ };
24
+
25
+ export function compactPosture(posture: string): string {
26
+ return titleCase(posture) || "Posture";
27
+ }
28
+
29
+ export function parseWorkModeArgs(args: string | undefined | null): WorkModeParse {
30
+ const tokens = String(args ?? "").trim().split(/\s+/).filter(Boolean);
31
+ if (tokens.length === 0) return { ok: true, action: "picker" };
32
+ if (tokens.length === 1) {
33
+ const token = tokens[0].toLowerCase();
34
+ const posture = parsePosture(token);
35
+ if (posture) return { ok: true, action: "apply", posture };
36
+ const mapped = DEPRECATED_WORK_MODE[token];
37
+ if (mapped) return { ok: true, action: "apply", posture: mapped, deprecatedFrom: token };
38
+ return {
39
+ ok: false,
40
+ error: `Unknown work mode "${tokens[0]}" — expected operator or orchestrator.`,
41
+ };
42
+ }
43
+ return {
44
+ ok: false,
45
+ error: `Unknown work mode "${tokens.join(" ")}" — expected operator or orchestrator.`,
46
+ };
47
+ }
48
+
49
+ export function posturePickerOptions(current: Posture): { title: string; options: string[]; postures: Posture[] } {
50
+ const postures = [...POSTURES];
51
+ const options = postures.map(posture => formatPickerOption(
52
+ posture === current,
53
+ posture,
54
+ posture === "operator" ? "Direct tools enabled" : "Delegate-only; requires a native roster",
55
+ ));
56
+ return { title: `Fleet posture — Alt+M · current ${current}`, options, postures };
57
+ }
58
+
59
+ export function executionPairBlockedByRoster(current: Posture, next: Posture, rosterSize: number): boolean {
60
+ if (next === current) return false;
61
+ return orchestratorNeedsRoster(next, rosterSize);
62
+ }
63
+
64
+ export function selectedPickerValue<T>(options: readonly string[], choice: string | undefined, values: readonly T[]): T | undefined {
65
+ if (choice === undefined) return undefined;
66
+ const index = options.indexOf(choice);
67
+ if (index < 0) return undefined;
68
+ return values[index];
69
+ }
@@ -15,8 +15,9 @@ export function composeHubFooterLeft(
15
15
  .join(" · ");
16
16
  }
17
17
 
18
- export function composeFleetFooterHint(viewMode: "compact" | "off"): string {
19
- return `Alt+A fleet · Alt+Shift+A widget:${viewMode}`;
18
+ export function composeFleetFooterHint(viewMode: "compact" | "off", executionPair?: string): string {
19
+ const work = executionPair ? ` · Alt+M ${executionPair}` : "";
20
+ return `Alt+A fleet${work} · Alt+Shift+A widget:${viewMode}`;
20
21
  }
21
22
 
22
23
  export function renderHubFooterLeft(
@@ -23,20 +23,6 @@ export function buildHubAuditIdentity(input = {}) {
23
23
  };
24
24
  }
25
25
 
26
- export function buildHubModeAudit(input = {}) {
27
- return {
28
- schema_version: 1,
29
- previous_mode: text(input.previousMode, 32),
30
- mode: text(input.mode, 32),
31
- source: text(input.source, 64),
32
- override_file: text(input.overrideFile),
33
- task_tier: text(input.taskTier, 32),
34
- turn_dispatches: count(input.turnDispatches),
35
- turn_research: count(input.turnResearch),
36
- identity: buildHubAuditIdentity(input.identity),
37
- };
38
- }
39
-
40
26
  export function buildTaskResetAudit(input = {}) {
41
27
  const prior = input.prior ?? {};
42
28
  return {