@chankov/agent-fleet 0.0.6 → 0.0.8

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 (717) hide show
  1. package/.claude/commands/set-hermes-watchdog.md +6 -0
  2. package/.opencode/commands/af-set-hermes-watchdog.md +6 -0
  3. package/.pi/harnesses/agent-hub/README.md +75 -16
  4. package/.pi/harnesses/agent-hub/artifacts.js +56 -2
  5. package/.pi/harnesses/agent-hub/assertion-ledger.js +58 -0
  6. package/.pi/harnesses/agent-hub/context-window.js +106 -0
  7. package/.pi/harnesses/agent-hub/delegate.ts +58 -9
  8. package/.pi/harnesses/agent-hub/drift-watchdog.js +54 -8
  9. package/.pi/harnesses/agent-hub/helpers.ts +34 -0
  10. package/.pi/harnesses/agent-hub/index.ts +723 -159
  11. package/.pi/harnesses/agent-hub/monitor-invoke-journal.ts +131 -0
  12. package/.pi/harnesses/agent-hub/monitor-invoke.ts +92 -0
  13. package/.pi/harnesses/agent-hub/monitor-lifecycle.ts +2 -2
  14. package/.pi/harnesses/agent-hub/monitor-session-bridge.ts +257 -11
  15. package/.pi/harnesses/agent-hub/package.json +1 -1
  16. package/.pi/harnesses/agent-hub/provider-semaphore.js +138 -0
  17. package/.pi/harnesses/agent-hub/return-contract.js +78 -0
  18. package/.pi/harnesses/agent-hub/return-extract.js +75 -0
  19. package/.pi/harnesses/agent-hub/run-budget.js +29 -3
  20. package/.pi/harnesses/agent-hub/session-health.js +110 -0
  21. package/.pi/harnesses/agent-hub/spawn.ts +109 -1
  22. package/.pi/harnesses/agent-hub/spawned-peers.js +74 -0
  23. package/.pi/harnesses/coms/README.md +4 -3
  24. package/.pi/harnesses/coms/index.ts +80 -58
  25. package/.pi/harnesses/coms/package.json +1 -1
  26. package/.pi/harnesses/damage-control-continue/package.json +1 -1
  27. package/.pi/harnesses/lib/coms-registry-entry.ts +94 -0
  28. package/.pi/harnesses/lib/herdr-client.ts +7 -2
  29. package/.pi/harnesses/lib/herdr-presence.ts +141 -30
  30. package/.pi/harnesses/lib/hermes-monitor-events.ts +136 -0
  31. package/.pi/harnesses/lib/hermes-monitor-model.ts +9 -0
  32. package/.pi/harnesses/lib/hermes-monitor-registry.ts +1 -1
  33. package/.pi/harnesses/lib/hermes-monitor-socket.ts +47 -2
  34. package/.pi/prompts/af-set-hermes-watchdog.md +6 -0
  35. package/.versions/0.0.7/.claude/commands/build.md +44 -0
  36. package/.versions/0.0.7/.claude/commands/code-simplify.md +22 -0
  37. package/.versions/0.0.7/.claude/commands/design-agent.md +14 -0
  38. package/.versions/0.0.7/.claude/commands/doctor-agent-fleet.md +17 -0
  39. package/.versions/0.0.7/.claude/commands/orchestrate.md +112 -0
  40. package/.versions/0.0.7/.claude/commands/plan.md +16 -0
  41. package/.versions/0.0.7/.claude/commands/prime.md +22 -0
  42. package/.versions/0.0.7/.claude/commands/review.md +16 -0
  43. package/.versions/0.0.7/.claude/commands/set-hermes-telegram.md +15 -0
  44. package/.versions/0.0.7/.claude/commands/set-hermes-watchdog.md +6 -0
  45. package/.versions/0.0.7/.claude/commands/setup-agent-fleet.md +25 -0
  46. package/.versions/0.0.7/.claude/commands/ship.md +72 -0
  47. package/.versions/0.0.7/.claude/commands/spec.md +15 -0
  48. package/.versions/0.0.7/.claude/commands/test.md +19 -0
  49. package/.versions/0.0.7/.claude/commands/webperf.md +32 -0
  50. package/.versions/0.0.7/.claude/orchestrate-teams.yaml +24 -0
  51. package/.versions/0.0.7/.opencode/commands/af-build.md +17 -0
  52. package/.versions/0.0.7/.opencode/commands/af-code-simplify.md +16 -0
  53. package/.versions/0.0.7/.opencode/commands/af-compound.md +16 -0
  54. package/.versions/0.0.7/.opencode/commands/af-design-agent.md +15 -0
  55. package/.versions/0.0.7/.opencode/commands/af-doctor-agent-fleet.md +17 -0
  56. package/.versions/0.0.7/.opencode/commands/af-orchestrate.md +112 -0
  57. package/.versions/0.0.7/.opencode/commands/af-plan.md +16 -0
  58. package/.versions/0.0.7/.opencode/commands/af-prime.md +22 -0
  59. package/.versions/0.0.7/.opencode/commands/af-review.md +15 -0
  60. package/.versions/0.0.7/.opencode/commands/af-set-hermes-telegram.md +15 -0
  61. package/.versions/0.0.7/.opencode/commands/af-set-hermes-watchdog.md +6 -0
  62. package/.versions/0.0.7/.opencode/commands/af-setup-agent-fleet.md +15 -0
  63. package/.versions/0.0.7/.opencode/commands/af-ship.md +16 -0
  64. package/.versions/0.0.7/.opencode/commands/af-spec.md +16 -0
  65. package/.versions/0.0.7/.opencode/commands/af-test.md +21 -0
  66. package/.versions/0.0.7/.opencode/commands/af-webperf.md +32 -0
  67. package/.versions/0.0.7/.opencode/orchestrate-teams.yaml +24 -0
  68. package/.versions/0.0.7/.pi/agents/dispatch-policy.yaml +32 -0
  69. package/.versions/0.0.7/.pi/agents/model-profiles.yaml +20 -0
  70. package/.versions/0.0.7/.pi/agents/peers.yaml +146 -0
  71. package/.versions/0.0.7/.pi/agents/teams.yaml +39 -0
  72. package/.versions/0.0.7/.pi/damage-control-rules.yaml +297 -0
  73. package/.versions/0.0.7/.pi/extensions/agent-fleet-update-check/README.md +58 -0
  74. package/.versions/0.0.7/.pi/extensions/agent-fleet-update-check/index.ts +161 -0
  75. package/.versions/0.0.7/.pi/extensions/agent-fleet-update-check/package.json +6 -0
  76. package/.versions/0.0.7/.pi/extensions/btw/README.md +118 -0
  77. package/.versions/0.0.7/.pi/extensions/btw/index.ts +917 -0
  78. package/.versions/0.0.7/.pi/extensions/btw/package.json +6 -0
  79. package/.versions/0.0.7/.pi/extensions/btw/state.js +179 -0
  80. package/.versions/0.0.7/.pi/extensions/chrome-devtools-mcp/README.md +58 -0
  81. package/.versions/0.0.7/.pi/extensions/chrome-devtools-mcp/index.ts +93 -0
  82. package/.versions/0.0.7/.pi/extensions/chrome-devtools-mcp/package.json +6 -0
  83. package/.versions/0.0.7/.pi/extensions/compact-and-continue/README.md +42 -0
  84. package/.versions/0.0.7/.pi/extensions/compact-and-continue/index.ts +120 -0
  85. package/.versions/0.0.7/.pi/extensions/compact-and-continue/package.json +6 -0
  86. package/.versions/0.0.7/.pi/extensions/mcp-bridge/README.md +46 -0
  87. package/.versions/0.0.7/.pi/extensions/mcp-bridge/index.ts +206 -0
  88. package/.versions/0.0.7/.pi/extensions/mcp-bridge/package.json +6 -0
  89. package/.versions/0.0.7/.pi/extensions/package-lock.json +1143 -0
  90. package/.versions/0.0.7/.pi/extensions/package.json +9 -0
  91. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/README.md +201 -0
  92. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/config.ts +198 -0
  93. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/examples/stt.json +35 -0
  94. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/index.ts +248 -0
  95. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/package.json +6 -0
  96. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/providers.ts +214 -0
  97. package/.versions/0.0.7/.pi/extensions/pi-voice-stt/recorder.ts +158 -0
  98. package/.versions/0.0.7/.pi/harnesses/agent-hub/README.md +857 -0
  99. package/.versions/0.0.7/.pi/harnesses/agent-hub/access-approval.ts +135 -0
  100. package/.versions/0.0.7/.pi/harnesses/agent-hub/artifacts.js +146 -0
  101. package/.versions/0.0.7/.pi/harnesses/agent-hub/assertion-ledger.js +58 -0
  102. package/.versions/0.0.7/.pi/harnesses/agent-hub/backend-policy.js +153 -0
  103. package/.versions/0.0.7/.pi/harnesses/agent-hub/context-window.js +106 -0
  104. package/.versions/0.0.7/.pi/harnesses/agent-hub/delegate.ts +435 -0
  105. package/.versions/0.0.7/.pi/harnesses/agent-hub/drift-watchdog.js +211 -0
  106. package/.versions/0.0.7/.pi/harnesses/agent-hub/evidence-rules.js +96 -0
  107. package/.versions/0.0.7/.pi/harnesses/agent-hub/footer.ts +29 -0
  108. package/.versions/0.0.7/.pi/harnesses/agent-hub/helpers.ts +248 -0
  109. package/.versions/0.0.7/.pi/harnesses/agent-hub/index.ts +8609 -0
  110. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-control.ts +9 -0
  111. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-invoke-journal.ts +131 -0
  112. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-invoke.ts +92 -0
  113. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-lifecycle.ts +13 -0
  114. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-publisher.ts +59 -0
  115. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-recovery.ts +3 -0
  116. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-runtime.ts +3 -0
  117. package/.versions/0.0.7/.pi/harnesses/agent-hub/monitor-session-bridge.ts +257 -0
  118. package/.versions/0.0.7/.pi/harnesses/agent-hub/package.json +7 -0
  119. package/.versions/0.0.7/.pi/harnesses/agent-hub/provider-semaphore.js +138 -0
  120. package/.versions/0.0.7/.pi/harnesses/agent-hub/research-retention.js +34 -0
  121. package/.versions/0.0.7/.pi/harnesses/agent-hub/research-watchdog.ts +40 -0
  122. package/.versions/0.0.7/.pi/harnesses/agent-hub/return-contract.js +293 -0
  123. package/.versions/0.0.7/.pi/harnesses/agent-hub/return-extract.js +75 -0
  124. package/.versions/0.0.7/.pi/harnesses/agent-hub/run-budget.js +181 -0
  125. package/.versions/0.0.7/.pi/harnesses/agent-hub/safety-routing.ts +22 -0
  126. package/.versions/0.0.7/.pi/harnesses/agent-hub/scope-gate.js +103 -0
  127. package/.versions/0.0.7/.pi/harnesses/agent-hub/session-health.js +110 -0
  128. package/.versions/0.0.7/.pi/harnesses/agent-hub/spawn.ts +354 -0
  129. package/.versions/0.0.7/.pi/harnesses/agent-hub/spawned-peers.js +74 -0
  130. package/.versions/0.0.7/.pi/harnesses/agent-hub/version.ts +18 -0
  131. package/.versions/0.0.7/.pi/harnesses/ask-user-remote/README.md +19 -0
  132. package/.versions/0.0.7/.pi/harnesses/ask-user-remote/index.ts +321 -0
  133. package/.versions/0.0.7/.pi/harnesses/ask-user-remote/race-core.js +106 -0
  134. package/.versions/0.0.7/.pi/harnesses/coms/README.md +93 -0
  135. package/.versions/0.0.7/.pi/harnesses/coms/index.ts +1767 -0
  136. package/.versions/0.0.7/.pi/harnesses/coms/package.json +7 -0
  137. package/.versions/0.0.7/.pi/harnesses/coms/version.ts +18 -0
  138. package/.versions/0.0.7/.pi/harnesses/damage-control-continue/README.md +117 -0
  139. package/.versions/0.0.7/.pi/harnesses/damage-control-continue/index.ts +536 -0
  140. package/.versions/0.0.7/.pi/harnesses/damage-control-continue/package.json +7 -0
  141. package/.versions/0.0.7/.pi/harnesses/damage-control-continue/version.ts +18 -0
  142. package/.versions/0.0.7/.pi/harnesses/lib/coms-registry-entry.ts +94 -0
  143. package/.versions/0.0.7/.pi/harnesses/lib/damage-control-shared.ts +197 -0
  144. package/.versions/0.0.7/.pi/harnesses/lib/herdr-client.ts +463 -0
  145. package/.versions/0.0.7/.pi/harnesses/lib/herdr-presence.ts +399 -0
  146. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-events.ts +136 -0
  147. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
  148. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-model.ts +18 -0
  149. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
  150. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-socket.ts +163 -0
  151. package/.versions/0.0.7/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
  152. package/.versions/0.0.7/.pi/harnesses/package-lock.json +35 -0
  153. package/.versions/0.0.7/.pi/harnesses/package.json +9 -0
  154. package/.versions/0.0.7/.pi/prompts/af-build.md +24 -0
  155. package/.versions/0.0.7/.pi/prompts/af-code-simplify.md +22 -0
  156. package/.versions/0.0.7/.pi/prompts/af-doctor-agent-fleet.md +15 -0
  157. package/.versions/0.0.7/.pi/prompts/af-plan.md +16 -0
  158. package/.versions/0.0.7/.pi/prompts/af-review.md +16 -0
  159. package/.versions/0.0.7/.pi/prompts/af-set-hermes-telegram.md +15 -0
  160. package/.versions/0.0.7/.pi/prompts/af-set-hermes-watchdog.md +6 -0
  161. package/.versions/0.0.7/.pi/prompts/af-setup-agent-fleet.md +27 -0
  162. package/.versions/0.0.7/.pi/prompts/af-ship.md +17 -0
  163. package/.versions/0.0.7/.pi/prompts/af-spec.md +15 -0
  164. package/.versions/0.0.7/.pi/prompts/af-test.md +19 -0
  165. package/.versions/0.0.7/.pi/skills/bowser/SKILL.md +145 -0
  166. package/.versions/0.0.7/.version +1 -0
  167. package/.versions/0.0.7/agents/architect.md +23 -0
  168. package/.versions/0.0.7/agents/bowser.md +26 -0
  169. package/.versions/0.0.7/agents/builder.md +53 -0
  170. package/.versions/0.0.7/agents/code-reviewer.md +205 -0
  171. package/.versions/0.0.7/agents/deep-researcher.md +31 -0
  172. package/.versions/0.0.7/agents/documenter.md +18 -0
  173. package/.versions/0.0.7/agents/orchestrator.md +65 -0
  174. package/.versions/0.0.7/agents/plan-reviewer.md +60 -0
  175. package/.versions/0.0.7/agents/planner.md +69 -0
  176. package/.versions/0.0.7/agents/releaser.md +24 -0
  177. package/.versions/0.0.7/agents/researcher.md +28 -0
  178. package/.versions/0.0.7/agents/security-auditor.md +166 -0
  179. package/.versions/0.0.7/agents/test-engineer.md +151 -0
  180. package/.versions/0.0.7/agents/web-debugger.md +42 -0
  181. package/.versions/0.0.7/agents/web-performance-auditor.md +192 -0
  182. package/.versions/0.0.7/codex/CONDUCTOR.md +148 -0
  183. package/.versions/0.0.7/docs/ARCHITECTURE.md +262 -0
  184. package/.versions/0.0.7/docs/agent-fleet-setup.md +366 -0
  185. package/.versions/0.0.7/docs/claude-code-coms-bridge.md +109 -0
  186. package/.versions/0.0.7/docs/codex-remote-conductor.md +170 -0
  187. package/.versions/0.0.7/docs/coms-hermes-bridge.md +189 -0
  188. package/.versions/0.0.7/docs/getting-started.md +231 -0
  189. package/.versions/0.0.7/docs/npm-install.md +337 -0
  190. package/.versions/0.0.7/docs/opencode-setup.md +249 -0
  191. package/.versions/0.0.7/docs/pi-extensions.md +293 -0
  192. package/.versions/0.0.7/docs/pi-setup.md +476 -0
  193. package/.versions/0.0.7/docs/skill-anatomy.md +150 -0
  194. package/.versions/0.0.7/hermes/README.md +347 -0
  195. package/.versions/0.0.7/hermes/desktop-plugins/agent-fleet-herdr/plugin.js +1291 -0
  196. package/.versions/0.0.7/hermes/desktop-plugins/agent-fleet-herdr/presentation.js +672 -0
  197. package/.versions/0.0.7/hermes/desktop-plugins/agent-fleet-monitor/plugin.js +19 -0
  198. package/.versions/0.0.7/hermes/desktop-plugins/agent-fleet-monitor/state.js +10 -0
  199. package/.versions/0.0.7/hermes/gates/gate-o-capability.md +8 -0
  200. package/.versions/0.0.7/hermes/gates/gate-o-validator-fixtures.json +1 -0
  201. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/activity.py +770 -0
  202. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/coms_registry.py +134 -0
  203. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/coms_send.py +350 -0
  204. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/herdr_source.py +193 -0
  205. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/manifest.json +4 -0
  206. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/plugin_api.py +444 -0
  207. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/sessions.py +205 -0
  208. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/tasks.py +300 -0
  209. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/dashboard/watch.py +819 -0
  210. package/.versions/0.0.7/hermes/plugins/agent-fleet-herdr/plugin.yaml +8 -0
  211. package/.versions/0.0.7/hermes/plugins/agent-fleet-monitor/dashboard/adapter.py +139 -0
  212. package/.versions/0.0.7/hermes/plugins/agent-fleet-monitor/dashboard/manifest.json +11 -0
  213. package/.versions/0.0.7/hermes/plugins/agent-fleet-monitor/dashboard/plugin_api.py +50 -0
  214. package/.versions/0.0.7/hermes/skills/hub-conductor/SKILL.md +84 -0
  215. package/.versions/0.0.7/hermes/skills/hub-liaison/SKILL.md +84 -0
  216. package/.versions/0.0.7/hermes/skills/hub-watchdog/SKILL.md +76 -0
  217. package/.versions/0.0.7/hermes/skills/hub-watchdog/manifest.json +1 -0
  218. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog.py +249 -0
  219. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_actions.py +124 -0
  220. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_contract.py +76 -0
  221. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_delivery.py +10 -0
  222. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_engine.py +128 -0
  223. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_judgment.py +41 -0
  224. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_recovery.py +103 -0
  225. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_state.py +163 -0
  226. package/.versions/0.0.7/hermes/skills/hub-watchdog/scripts/watchdog_transport.py +138 -0
  227. package/.versions/0.0.7/hermes/watchdog-tests/__init__.py +0 -0
  228. package/.versions/0.0.7/hooks/SIMPLIFY-IGNORE.md +90 -0
  229. package/.versions/0.0.7/hooks/coms-stop-hook.mjs +84 -0
  230. package/.versions/0.0.7/hooks/hooks.json +14 -0
  231. package/.versions/0.0.7/hooks/session-start.sh +74 -0
  232. package/.versions/0.0.7/hooks/simplify-ignore.sh +302 -0
  233. package/.versions/0.0.7/justfile +245 -0
  234. package/.versions/0.0.7/references/accessibility-checklist.md +160 -0
  235. package/.versions/0.0.7/references/definition-of-done.md +67 -0
  236. package/.versions/0.0.7/references/fleet-coordination-patterns.md +151 -0
  237. package/.versions/0.0.7/references/observability-checklist.md +91 -0
  238. package/.versions/0.0.7/references/orchestration-patterns.md +370 -0
  239. package/.versions/0.0.7/references/performance-checklist.md +153 -0
  240. package/.versions/0.0.7/references/prompting-patterns.md +380 -0
  241. package/.versions/0.0.7/references/security-checklist.md +179 -0
  242. package/.versions/0.0.7/references/testing-patterns.md +236 -0
  243. package/.versions/0.0.7/scripts/codex-conductor.ts +41 -0
  244. package/.versions/0.0.7/scripts/codex-remote-control.ts +167 -0
  245. package/.versions/0.0.7/scripts/coms-claude-bridge.ts +401 -0
  246. package/.versions/0.0.7/scripts/coms-cli.ts +484 -0
  247. package/.versions/0.0.7/scripts/coms-hermes-bridge.ts +413 -0
  248. package/.versions/0.0.7/scripts/fleet.ts +149 -0
  249. package/.versions/0.0.7/scripts/hermes-monitor-capability-runner.ts +25 -0
  250. package/.versions/0.0.7/scripts/hermes-monitor-scenario.ts +474 -0
  251. package/.versions/0.0.7/scripts/hermes-watchdog-capability-probe.ts +45 -0
  252. package/.versions/0.0.7/scripts/install-hermes-plugin.sh +180 -0
  253. package/.versions/0.0.7/scripts/lib/claude-bridge-core.ts +165 -0
  254. package/.versions/0.0.7/scripts/lib/codex-conductor.ts +88 -0
  255. package/.versions/0.0.7/scripts/lib/codex-remote-control.ts +480 -0
  256. package/.versions/0.0.7/scripts/lib/coms-envelope.ts +582 -0
  257. package/.versions/0.0.7/scripts/lib/fake-herdr-server.ts +88 -0
  258. package/.versions/0.0.7/scripts/lib/fleet-command.ts +109 -0
  259. package/.versions/0.0.7/scripts/lib/herdr-layout.ts +263 -0
  260. package/.versions/0.0.7/scripts/lib/hermes-bridge-core.ts +241 -0
  261. package/.versions/0.0.7/scripts/lib/hermes-monitor-events.ts +1 -0
  262. package/.versions/0.0.7/scripts/lib/hermes-monitor-herdr.ts +2 -0
  263. package/.versions/0.0.7/scripts/lib/hermes-monitor-model.ts +3 -0
  264. package/.versions/0.0.7/scripts/lib/hermes-monitor-registry.ts +2 -0
  265. package/.versions/0.0.7/scripts/lib/hermes-monitor-socket.ts +2 -0
  266. package/.versions/0.0.7/scripts/lib/hermes-monitor-store.ts +2 -0
  267. package/.versions/0.0.7/scripts/lib/monitor-env.ts +120 -0
  268. package/.versions/0.0.7/scripts/lib/persona-banner.ts +62 -0
  269. package/.versions/0.0.7/scripts/lib/spawn-stagger.ts +101 -0
  270. package/.versions/0.0.7/scripts/lib/team-project.ts +191 -0
  271. package/.versions/0.0.7/scripts/lib/team-snapshot.ts +147 -0
  272. package/.versions/0.0.7/scripts/peer-banner.ts +40 -0
  273. package/.versions/0.0.7/scripts/team-snapshot.ts +237 -0
  274. package/.versions/0.0.7/scripts/team-up.ts +360 -0
  275. package/.versions/0.0.7/skills/_internal/grilling.md +11 -0
  276. package/.versions/0.0.7/skills/browser-testing-with-devtools/SKILL.md +352 -0
  277. package/.versions/0.0.7/skills/code-review-and-quality/SKILL.md +381 -0
  278. package/.versions/0.0.7/skills/compound-learning/SKILL.md +137 -0
  279. package/.versions/0.0.7/skills/context-engineering/SKILL.md +291 -0
  280. package/.versions/0.0.7/skills/deprecation-and-migration/SKILL.md +206 -0
  281. package/.versions/0.0.7/skills/designing-agents/SKILL.md +394 -0
  282. package/.versions/0.0.7/skills/designing-agents/pi-harness-authoring.md +222 -0
  283. package/.versions/0.0.7/skills/frontend-ui-engineering/SKILL.md +328 -0
  284. package/.versions/0.0.7/skills/git-workflow-and-versioning/SKILL.md +316 -0
  285. package/.versions/0.0.7/skills/guided-workspace-setup/SKILL.md +544 -0
  286. package/.versions/0.0.7/skills/guided-workspace-setup/companion-manifest.json +35 -0
  287. package/.versions/0.0.7/skills/idea-refine/SKILL.md +182 -0
  288. package/.versions/0.0.7/skills/idea-refine/examples.md +238 -0
  289. package/.versions/0.0.7/skills/idea-refine/frameworks.md +99 -0
  290. package/.versions/0.0.7/skills/idea-refine/refinement-criteria.md +113 -0
  291. package/.versions/0.0.7/skills/idea-refine/scripts/idea-refine.sh +15 -0
  292. package/.versions/0.0.7/skills/incremental-implementation/SKILL.md +287 -0
  293. package/.versions/0.0.7/skills/interview-me/SKILL.md +226 -0
  294. package/.versions/0.0.7/skills/orchestration-verification/SKILL.md +181 -0
  295. package/.versions/0.0.7/skills/peer-coms/SKILL.md +90 -0
  296. package/.versions/0.0.7/skills/performance-optimization/SKILL.md +350 -0
  297. package/.versions/0.0.7/skills/planning-and-task-breakdown/SKILL.md +236 -0
  298. package/.versions/0.0.7/skills/security-and-hardening/SKILL.md +461 -0
  299. package/.versions/0.0.7/skills/spec-driven-development/SKILL.md +245 -0
  300. package/.versions/0.0.7/skills/using-agent-skills/SKILL.md +199 -0
  301. package/.versions/0.0.7/systemd/user/agent-fleet-codex-remote-control.service.in +23 -0
  302. package/.versions/0.0.7/vendor/agent-skills-upstream/LICENSE +21 -0
  303. package/.versions/0.0.7/vendor/agent-skills-upstream/README.md +11 -0
  304. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/api-and-interface-design/SKILL.md +294 -0
  305. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/browser-testing-with-devtools/SKILL.md +317 -0
  306. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/ci-cd-and-automation/SKILL.md +390 -0
  307. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/code-review-and-quality/SKILL.md +396 -0
  308. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/code-simplification/SKILL.md +331 -0
  309. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/context-engineering/SKILL.md +289 -0
  310. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/debugging-and-error-recovery/SKILL.md +300 -0
  311. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/deprecation-and-migration/SKILL.md +247 -0
  312. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/documentation-and-adrs/SKILL.md +278 -0
  313. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/doubt-driven-development/SKILL.md +243 -0
  314. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/frontend-ui-engineering/SKILL.md +328 -0
  315. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/git-workflow-and-versioning/SKILL.md +355 -0
  316. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/idea-refine/SKILL.md +178 -0
  317. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/idea-refine/examples.md +238 -0
  318. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/idea-refine/frameworks.md +99 -0
  319. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/idea-refine/refinement-criteria.md +113 -0
  320. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/idea-refine/scripts/idea-refine.sh +15 -0
  321. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/incremental-implementation/SKILL.md +249 -0
  322. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/interview-me/SKILL.md +225 -0
  323. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/observability-and-instrumentation/SKILL.md +203 -0
  324. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/performance-optimization/SKILL.md +350 -0
  325. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/planning-and-task-breakdown/SKILL.md +234 -0
  326. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/security-and-hardening/SKILL.md +467 -0
  327. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/shipping-and-launch/SKILL.md +310 -0
  328. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/source-driven-development/SKILL.md +194 -0
  329. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/spec-driven-development/SKILL.md +206 -0
  330. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/test-driven-development/SKILL.md +383 -0
  331. package/.versions/0.0.7/vendor/agent-skills-upstream/skills/using-agent-skills/SKILL.md +191 -0
  332. package/.versions/0.0.8/.claude/commands/build.md +44 -0
  333. package/.versions/0.0.8/.claude/commands/code-simplify.md +22 -0
  334. package/.versions/0.0.8/.claude/commands/design-agent.md +14 -0
  335. package/.versions/0.0.8/.claude/commands/doctor-agent-fleet.md +17 -0
  336. package/.versions/0.0.8/.claude/commands/orchestrate.md +112 -0
  337. package/.versions/0.0.8/.claude/commands/plan.md +16 -0
  338. package/.versions/0.0.8/.claude/commands/prime.md +22 -0
  339. package/.versions/0.0.8/.claude/commands/review.md +16 -0
  340. package/.versions/0.0.8/.claude/commands/set-hermes-telegram.md +15 -0
  341. package/.versions/0.0.8/.claude/commands/set-hermes-watchdog.md +6 -0
  342. package/.versions/0.0.8/.claude/commands/setup-agent-fleet.md +25 -0
  343. package/.versions/0.0.8/.claude/commands/ship.md +72 -0
  344. package/.versions/0.0.8/.claude/commands/spec.md +15 -0
  345. package/.versions/0.0.8/.claude/commands/test.md +19 -0
  346. package/.versions/0.0.8/.claude/commands/webperf.md +32 -0
  347. package/.versions/0.0.8/.claude/orchestrate-teams.yaml +24 -0
  348. package/.versions/0.0.8/.opencode/commands/af-build.md +17 -0
  349. package/.versions/0.0.8/.opencode/commands/af-code-simplify.md +16 -0
  350. package/.versions/0.0.8/.opencode/commands/af-compound.md +16 -0
  351. package/.versions/0.0.8/.opencode/commands/af-design-agent.md +15 -0
  352. package/.versions/0.0.8/.opencode/commands/af-doctor-agent-fleet.md +17 -0
  353. package/.versions/0.0.8/.opencode/commands/af-orchestrate.md +112 -0
  354. package/.versions/0.0.8/.opencode/commands/af-plan.md +16 -0
  355. package/.versions/0.0.8/.opencode/commands/af-prime.md +22 -0
  356. package/.versions/0.0.8/.opencode/commands/af-review.md +15 -0
  357. package/.versions/0.0.8/.opencode/commands/af-set-hermes-telegram.md +15 -0
  358. package/.versions/0.0.8/.opencode/commands/af-set-hermes-watchdog.md +6 -0
  359. package/.versions/0.0.8/.opencode/commands/af-setup-agent-fleet.md +15 -0
  360. package/.versions/0.0.8/.opencode/commands/af-ship.md +16 -0
  361. package/.versions/0.0.8/.opencode/commands/af-spec.md +16 -0
  362. package/.versions/0.0.8/.opencode/commands/af-test.md +21 -0
  363. package/.versions/0.0.8/.opencode/commands/af-webperf.md +32 -0
  364. package/.versions/0.0.8/.opencode/orchestrate-teams.yaml +24 -0
  365. package/.versions/0.0.8/.pi/agents/dispatch-policy.yaml +32 -0
  366. package/.versions/0.0.8/.pi/agents/model-profiles.yaml +20 -0
  367. package/.versions/0.0.8/.pi/agents/peers.yaml +146 -0
  368. package/.versions/0.0.8/.pi/agents/teams.yaml +39 -0
  369. package/.versions/0.0.8/.pi/damage-control-rules.yaml +297 -0
  370. package/.versions/0.0.8/.pi/extensions/agent-fleet-update-check/README.md +58 -0
  371. package/.versions/0.0.8/.pi/extensions/agent-fleet-update-check/index.ts +161 -0
  372. package/.versions/0.0.8/.pi/extensions/agent-fleet-update-check/package.json +6 -0
  373. package/.versions/0.0.8/.pi/extensions/btw/README.md +118 -0
  374. package/.versions/0.0.8/.pi/extensions/btw/index.ts +917 -0
  375. package/.versions/0.0.8/.pi/extensions/btw/package.json +6 -0
  376. package/.versions/0.0.8/.pi/extensions/btw/state.js +179 -0
  377. package/.versions/0.0.8/.pi/extensions/chrome-devtools-mcp/README.md +58 -0
  378. package/.versions/0.0.8/.pi/extensions/chrome-devtools-mcp/index.ts +93 -0
  379. package/.versions/0.0.8/.pi/extensions/chrome-devtools-mcp/package.json +6 -0
  380. package/.versions/0.0.8/.pi/extensions/compact-and-continue/README.md +42 -0
  381. package/.versions/0.0.8/.pi/extensions/compact-and-continue/index.ts +120 -0
  382. package/.versions/0.0.8/.pi/extensions/compact-and-continue/package.json +6 -0
  383. package/.versions/0.0.8/.pi/extensions/mcp-bridge/README.md +46 -0
  384. package/.versions/0.0.8/.pi/extensions/mcp-bridge/index.ts +206 -0
  385. package/.versions/0.0.8/.pi/extensions/mcp-bridge/package.json +6 -0
  386. package/.versions/0.0.8/.pi/extensions/package-lock.json +1143 -0
  387. package/.versions/0.0.8/.pi/extensions/package.json +9 -0
  388. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/README.md +201 -0
  389. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/config.ts +198 -0
  390. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/examples/stt.json +35 -0
  391. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/index.ts +248 -0
  392. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/package.json +6 -0
  393. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/providers.ts +214 -0
  394. package/.versions/0.0.8/.pi/extensions/pi-voice-stt/recorder.ts +158 -0
  395. package/.versions/0.0.8/.pi/harnesses/agent-hub/README.md +857 -0
  396. package/.versions/0.0.8/.pi/harnesses/agent-hub/access-approval.ts +135 -0
  397. package/.versions/0.0.8/.pi/harnesses/agent-hub/artifacts.js +146 -0
  398. package/.versions/0.0.8/.pi/harnesses/agent-hub/assertion-ledger.js +58 -0
  399. package/.versions/0.0.8/.pi/harnesses/agent-hub/backend-policy.js +153 -0
  400. package/.versions/0.0.8/.pi/harnesses/agent-hub/context-window.js +106 -0
  401. package/.versions/0.0.8/.pi/harnesses/agent-hub/delegate.ts +435 -0
  402. package/.versions/0.0.8/.pi/harnesses/agent-hub/drift-watchdog.js +211 -0
  403. package/.versions/0.0.8/.pi/harnesses/agent-hub/evidence-rules.js +96 -0
  404. package/.versions/0.0.8/.pi/harnesses/agent-hub/footer.ts +29 -0
  405. package/.versions/0.0.8/.pi/harnesses/agent-hub/helpers.ts +248 -0
  406. package/.versions/0.0.8/.pi/harnesses/agent-hub/index.ts +8609 -0
  407. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-control.ts +9 -0
  408. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-invoke-journal.ts +131 -0
  409. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-invoke.ts +92 -0
  410. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-lifecycle.ts +13 -0
  411. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-publisher.ts +59 -0
  412. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-recovery.ts +3 -0
  413. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-runtime.ts +3 -0
  414. package/.versions/0.0.8/.pi/harnesses/agent-hub/monitor-session-bridge.ts +257 -0
  415. package/.versions/0.0.8/.pi/harnesses/agent-hub/package.json +7 -0
  416. package/.versions/0.0.8/.pi/harnesses/agent-hub/provider-semaphore.js +138 -0
  417. package/.versions/0.0.8/.pi/harnesses/agent-hub/research-retention.js +34 -0
  418. package/.versions/0.0.8/.pi/harnesses/agent-hub/research-watchdog.ts +40 -0
  419. package/.versions/0.0.8/.pi/harnesses/agent-hub/return-contract.js +293 -0
  420. package/.versions/0.0.8/.pi/harnesses/agent-hub/return-extract.js +75 -0
  421. package/.versions/0.0.8/.pi/harnesses/agent-hub/run-budget.js +181 -0
  422. package/.versions/0.0.8/.pi/harnesses/agent-hub/safety-routing.ts +22 -0
  423. package/.versions/0.0.8/.pi/harnesses/agent-hub/scope-gate.js +103 -0
  424. package/.versions/0.0.8/.pi/harnesses/agent-hub/session-health.js +110 -0
  425. package/.versions/0.0.8/.pi/harnesses/agent-hub/spawn.ts +354 -0
  426. package/.versions/0.0.8/.pi/harnesses/agent-hub/spawned-peers.js +74 -0
  427. package/.versions/0.0.8/.pi/harnesses/agent-hub/version.ts +18 -0
  428. package/.versions/0.0.8/.pi/harnesses/ask-user-remote/README.md +19 -0
  429. package/.versions/0.0.8/.pi/harnesses/ask-user-remote/index.ts +321 -0
  430. package/.versions/0.0.8/.pi/harnesses/ask-user-remote/race-core.js +106 -0
  431. package/.versions/0.0.8/.pi/harnesses/coms/README.md +93 -0
  432. package/.versions/0.0.8/.pi/harnesses/coms/index.ts +1767 -0
  433. package/.versions/0.0.8/.pi/harnesses/coms/package.json +7 -0
  434. package/.versions/0.0.8/.pi/harnesses/coms/version.ts +18 -0
  435. package/.versions/0.0.8/.pi/harnesses/damage-control-continue/README.md +117 -0
  436. package/.versions/0.0.8/.pi/harnesses/damage-control-continue/index.ts +536 -0
  437. package/.versions/0.0.8/.pi/harnesses/damage-control-continue/package.json +7 -0
  438. package/.versions/0.0.8/.pi/harnesses/damage-control-continue/version.ts +18 -0
  439. package/.versions/0.0.8/.pi/harnesses/lib/coms-registry-entry.ts +94 -0
  440. package/.versions/0.0.8/.pi/harnesses/lib/damage-control-shared.ts +197 -0
  441. package/.versions/0.0.8/.pi/harnesses/lib/herdr-client.ts +463 -0
  442. package/.versions/0.0.8/.pi/harnesses/lib/herdr-presence.ts +399 -0
  443. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-events.ts +136 -0
  444. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
  445. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-model.ts +18 -0
  446. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
  447. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-socket.ts +163 -0
  448. package/.versions/0.0.8/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
  449. package/.versions/0.0.8/.pi/harnesses/package-lock.json +35 -0
  450. package/.versions/0.0.8/.pi/harnesses/package.json +9 -0
  451. package/.versions/0.0.8/.pi/prompts/af-build.md +24 -0
  452. package/.versions/0.0.8/.pi/prompts/af-code-simplify.md +22 -0
  453. package/.versions/0.0.8/.pi/prompts/af-doctor-agent-fleet.md +15 -0
  454. package/.versions/0.0.8/.pi/prompts/af-plan.md +16 -0
  455. package/.versions/0.0.8/.pi/prompts/af-review.md +16 -0
  456. package/.versions/0.0.8/.pi/prompts/af-set-hermes-telegram.md +15 -0
  457. package/.versions/0.0.8/.pi/prompts/af-set-hermes-watchdog.md +6 -0
  458. package/.versions/0.0.8/.pi/prompts/af-setup-agent-fleet.md +27 -0
  459. package/.versions/0.0.8/.pi/prompts/af-ship.md +17 -0
  460. package/.versions/0.0.8/.pi/prompts/af-spec.md +15 -0
  461. package/.versions/0.0.8/.pi/prompts/af-test.md +19 -0
  462. package/.versions/0.0.8/.pi/skills/bowser/SKILL.md +145 -0
  463. package/.versions/0.0.8/.version +1 -0
  464. package/.versions/0.0.8/agents/architect.md +23 -0
  465. package/.versions/0.0.8/agents/bowser.md +26 -0
  466. package/.versions/0.0.8/agents/builder.md +53 -0
  467. package/.versions/0.0.8/agents/code-reviewer.md +205 -0
  468. package/.versions/0.0.8/agents/deep-researcher.md +31 -0
  469. package/.versions/0.0.8/agents/documenter.md +18 -0
  470. package/.versions/0.0.8/agents/orchestrator.md +65 -0
  471. package/.versions/0.0.8/agents/plan-reviewer.md +60 -0
  472. package/.versions/0.0.8/agents/planner.md +69 -0
  473. package/.versions/0.0.8/agents/releaser.md +24 -0
  474. package/.versions/0.0.8/agents/researcher.md +28 -0
  475. package/.versions/0.0.8/agents/security-auditor.md +166 -0
  476. package/.versions/0.0.8/agents/test-engineer.md +151 -0
  477. package/.versions/0.0.8/agents/web-debugger.md +42 -0
  478. package/.versions/0.0.8/agents/web-performance-auditor.md +192 -0
  479. package/.versions/0.0.8/codex/CONDUCTOR.md +148 -0
  480. package/.versions/0.0.8/docs/ARCHITECTURE.md +262 -0
  481. package/.versions/0.0.8/docs/agent-fleet-setup.md +366 -0
  482. package/.versions/0.0.8/docs/claude-code-coms-bridge.md +109 -0
  483. package/.versions/0.0.8/docs/codex-remote-conductor.md +170 -0
  484. package/.versions/0.0.8/docs/coms-hermes-bridge.md +189 -0
  485. package/.versions/0.0.8/docs/getting-started.md +231 -0
  486. package/.versions/0.0.8/docs/npm-install.md +337 -0
  487. package/.versions/0.0.8/docs/opencode-setup.md +249 -0
  488. package/.versions/0.0.8/docs/pi-extensions.md +293 -0
  489. package/.versions/0.0.8/docs/pi-setup.md +476 -0
  490. package/.versions/0.0.8/docs/skill-anatomy.md +150 -0
  491. package/.versions/0.0.8/hermes/README.md +347 -0
  492. package/.versions/0.0.8/hermes/desktop-plugins/agent-fleet-herdr/plugin.js +1291 -0
  493. package/.versions/0.0.8/hermes/desktop-plugins/agent-fleet-herdr/presentation.js +672 -0
  494. package/.versions/0.0.8/hermes/desktop-plugins/agent-fleet-monitor/plugin.js +19 -0
  495. package/.versions/0.0.8/hermes/desktop-plugins/agent-fleet-monitor/state.js +10 -0
  496. package/.versions/0.0.8/hermes/gates/gate-o-capability.md +8 -0
  497. package/.versions/0.0.8/hermes/gates/gate-o-validator-fixtures.json +1 -0
  498. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/activity.py +770 -0
  499. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/coms_registry.py +134 -0
  500. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/coms_send.py +350 -0
  501. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/herdr_source.py +193 -0
  502. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/manifest.json +4 -0
  503. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/plugin_api.py +444 -0
  504. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/sessions.py +205 -0
  505. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/tasks.py +300 -0
  506. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/dashboard/watch.py +819 -0
  507. package/.versions/0.0.8/hermes/plugins/agent-fleet-herdr/plugin.yaml +8 -0
  508. package/.versions/0.0.8/hermes/plugins/agent-fleet-monitor/dashboard/adapter.py +139 -0
  509. package/.versions/0.0.8/hermes/plugins/agent-fleet-monitor/dashboard/manifest.json +11 -0
  510. package/.versions/0.0.8/hermes/plugins/agent-fleet-monitor/dashboard/plugin_api.py +50 -0
  511. package/.versions/0.0.8/hermes/skills/hub-conductor/SKILL.md +84 -0
  512. package/.versions/0.0.8/hermes/skills/hub-liaison/SKILL.md +84 -0
  513. package/.versions/0.0.8/hermes/skills/hub-watchdog/SKILL.md +76 -0
  514. package/.versions/0.0.8/hermes/skills/hub-watchdog/manifest.json +1 -0
  515. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog.py +249 -0
  516. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_actions.py +124 -0
  517. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_contract.py +76 -0
  518. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_delivery.py +10 -0
  519. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_engine.py +128 -0
  520. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_judgment.py +41 -0
  521. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_recovery.py +103 -0
  522. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_state.py +163 -0
  523. package/.versions/0.0.8/hermes/skills/hub-watchdog/scripts/watchdog_transport.py +138 -0
  524. package/.versions/0.0.8/hermes/watchdog-tests/__init__.py +0 -0
  525. package/.versions/0.0.8/hooks/SIMPLIFY-IGNORE.md +90 -0
  526. package/.versions/0.0.8/hooks/coms-stop-hook.mjs +84 -0
  527. package/.versions/0.0.8/hooks/hooks.json +14 -0
  528. package/.versions/0.0.8/hooks/session-start.sh +74 -0
  529. package/.versions/0.0.8/hooks/simplify-ignore.sh +302 -0
  530. package/.versions/0.0.8/justfile +245 -0
  531. package/.versions/0.0.8/references/accessibility-checklist.md +160 -0
  532. package/.versions/0.0.8/references/definition-of-done.md +67 -0
  533. package/.versions/0.0.8/references/fleet-coordination-patterns.md +151 -0
  534. package/.versions/0.0.8/references/observability-checklist.md +91 -0
  535. package/.versions/0.0.8/references/orchestration-patterns.md +370 -0
  536. package/.versions/0.0.8/references/performance-checklist.md +153 -0
  537. package/.versions/0.0.8/references/prompting-patterns.md +380 -0
  538. package/.versions/0.0.8/references/security-checklist.md +179 -0
  539. package/.versions/0.0.8/references/testing-patterns.md +236 -0
  540. package/.versions/0.0.8/scripts/codex-conductor.ts +41 -0
  541. package/.versions/0.0.8/scripts/codex-remote-control.ts +167 -0
  542. package/.versions/0.0.8/scripts/coms-claude-bridge.ts +401 -0
  543. package/.versions/0.0.8/scripts/coms-cli.ts +484 -0
  544. package/.versions/0.0.8/scripts/coms-hermes-bridge.ts +413 -0
  545. package/.versions/0.0.8/scripts/fleet.ts +149 -0
  546. package/.versions/0.0.8/scripts/hermes-monitor-capability-runner.ts +25 -0
  547. package/.versions/0.0.8/scripts/hermes-monitor-scenario.ts +474 -0
  548. package/.versions/0.0.8/scripts/hermes-watchdog-capability-probe.ts +45 -0
  549. package/.versions/0.0.8/scripts/install-hermes-plugin.sh +180 -0
  550. package/.versions/0.0.8/scripts/lib/claude-bridge-core.ts +165 -0
  551. package/.versions/0.0.8/scripts/lib/codex-conductor.ts +88 -0
  552. package/.versions/0.0.8/scripts/lib/codex-remote-control.ts +480 -0
  553. package/.versions/0.0.8/scripts/lib/coms-envelope.ts +582 -0
  554. package/.versions/0.0.8/scripts/lib/fake-herdr-server.ts +88 -0
  555. package/.versions/0.0.8/scripts/lib/fleet-command.ts +109 -0
  556. package/.versions/0.0.8/scripts/lib/herdr-layout.ts +263 -0
  557. package/.versions/0.0.8/scripts/lib/hermes-bridge-core.ts +241 -0
  558. package/.versions/0.0.8/scripts/lib/hermes-monitor-events.ts +1 -0
  559. package/.versions/0.0.8/scripts/lib/hermes-monitor-herdr.ts +2 -0
  560. package/.versions/0.0.8/scripts/lib/hermes-monitor-model.ts +3 -0
  561. package/.versions/0.0.8/scripts/lib/hermes-monitor-registry.ts +2 -0
  562. package/.versions/0.0.8/scripts/lib/hermes-monitor-socket.ts +2 -0
  563. package/.versions/0.0.8/scripts/lib/hermes-monitor-store.ts +2 -0
  564. package/.versions/0.0.8/scripts/lib/monitor-env.ts +120 -0
  565. package/.versions/0.0.8/scripts/lib/persona-banner.ts +62 -0
  566. package/.versions/0.0.8/scripts/lib/spawn-stagger.ts +101 -0
  567. package/.versions/0.0.8/scripts/lib/team-project.ts +191 -0
  568. package/.versions/0.0.8/scripts/lib/team-snapshot.ts +147 -0
  569. package/.versions/0.0.8/scripts/peer-banner.ts +40 -0
  570. package/.versions/0.0.8/scripts/team-snapshot.ts +237 -0
  571. package/.versions/0.0.8/scripts/team-up.ts +360 -0
  572. package/.versions/0.0.8/skills/_internal/grilling.md +11 -0
  573. package/.versions/0.0.8/skills/browser-testing-with-devtools/SKILL.md +352 -0
  574. package/.versions/0.0.8/skills/code-review-and-quality/SKILL.md +381 -0
  575. package/.versions/0.0.8/skills/compound-learning/SKILL.md +137 -0
  576. package/.versions/0.0.8/skills/context-engineering/SKILL.md +291 -0
  577. package/.versions/0.0.8/skills/deprecation-and-migration/SKILL.md +206 -0
  578. package/.versions/0.0.8/skills/designing-agents/SKILL.md +394 -0
  579. package/.versions/0.0.8/skills/designing-agents/pi-harness-authoring.md +222 -0
  580. package/.versions/0.0.8/skills/frontend-ui-engineering/SKILL.md +328 -0
  581. package/.versions/0.0.8/skills/git-workflow-and-versioning/SKILL.md +316 -0
  582. package/.versions/0.0.8/skills/guided-workspace-setup/SKILL.md +544 -0
  583. package/.versions/0.0.8/skills/guided-workspace-setup/companion-manifest.json +36 -0
  584. package/.versions/0.0.8/skills/idea-refine/SKILL.md +182 -0
  585. package/.versions/0.0.8/skills/idea-refine/examples.md +238 -0
  586. package/.versions/0.0.8/skills/idea-refine/frameworks.md +99 -0
  587. package/.versions/0.0.8/skills/idea-refine/refinement-criteria.md +113 -0
  588. package/.versions/0.0.8/skills/idea-refine/scripts/idea-refine.sh +15 -0
  589. package/.versions/0.0.8/skills/incremental-implementation/SKILL.md +287 -0
  590. package/.versions/0.0.8/skills/interview-me/SKILL.md +226 -0
  591. package/.versions/0.0.8/skills/orchestration-verification/SKILL.md +181 -0
  592. package/.versions/0.0.8/skills/peer-coms/SKILL.md +90 -0
  593. package/.versions/0.0.8/skills/performance-optimization/SKILL.md +350 -0
  594. package/.versions/0.0.8/skills/planning-and-task-breakdown/SKILL.md +236 -0
  595. package/.versions/0.0.8/skills/security-and-hardening/SKILL.md +461 -0
  596. package/.versions/0.0.8/skills/spec-driven-development/SKILL.md +245 -0
  597. package/.versions/0.0.8/skills/using-agent-skills/SKILL.md +199 -0
  598. package/.versions/0.0.8/systemd/user/agent-fleet-codex-remote-control.service.in +23 -0
  599. package/.versions/0.0.8/vendor/agent-skills-upstream/LICENSE +21 -0
  600. package/.versions/0.0.8/vendor/agent-skills-upstream/README.md +11 -0
  601. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/api-and-interface-design/SKILL.md +294 -0
  602. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/browser-testing-with-devtools/SKILL.md +317 -0
  603. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/ci-cd-and-automation/SKILL.md +390 -0
  604. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/code-review-and-quality/SKILL.md +396 -0
  605. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/code-simplification/SKILL.md +331 -0
  606. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/context-engineering/SKILL.md +289 -0
  607. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/debugging-and-error-recovery/SKILL.md +300 -0
  608. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/deprecation-and-migration/SKILL.md +247 -0
  609. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/documentation-and-adrs/SKILL.md +278 -0
  610. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/doubt-driven-development/SKILL.md +243 -0
  611. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/frontend-ui-engineering/SKILL.md +328 -0
  612. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/git-workflow-and-versioning/SKILL.md +355 -0
  613. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/idea-refine/SKILL.md +178 -0
  614. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/idea-refine/examples.md +238 -0
  615. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/idea-refine/frameworks.md +99 -0
  616. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/idea-refine/refinement-criteria.md +113 -0
  617. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/idea-refine/scripts/idea-refine.sh +15 -0
  618. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/incremental-implementation/SKILL.md +249 -0
  619. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/interview-me/SKILL.md +225 -0
  620. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/observability-and-instrumentation/SKILL.md +203 -0
  621. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/performance-optimization/SKILL.md +350 -0
  622. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/planning-and-task-breakdown/SKILL.md +234 -0
  623. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/security-and-hardening/SKILL.md +467 -0
  624. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/shipping-and-launch/SKILL.md +310 -0
  625. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/source-driven-development/SKILL.md +194 -0
  626. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/spec-driven-development/SKILL.md +206 -0
  627. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/test-driven-development/SKILL.md +383 -0
  628. package/.versions/0.0.8/vendor/agent-skills-upstream/skills/using-agent-skills/SKILL.md +191 -0
  629. package/CHANGELOG.md +140 -0
  630. package/README.md +175 -18
  631. package/agents/code-reviewer.md +2 -2
  632. package/agents/orchestrator.md +11 -0
  633. package/agents/plan-reviewer.md +1 -1
  634. package/agents/planner.md +1 -1
  635. package/agents/security-auditor.md +1 -1
  636. package/bin/cli.js +40 -1
  637. package/bin/lib/hermes-profile-artifact.js +144 -0
  638. package/bin/lib/set-hermes-watchdog.js +173 -0
  639. package/bin/set-hermes-watchdog.js +26 -0
  640. package/docs/ARCHITECTURE.md +64 -12
  641. package/docs/agent-fleet-setup.md +2 -2
  642. package/docs/claude-code-coms-bridge.md +7 -1
  643. package/docs/coms-hermes-bridge.md +10 -0
  644. package/docs/getting-started.md +48 -0
  645. package/docs/hermes-watchdog-supervisor.md +140 -0
  646. package/hermes/README.md +135 -19
  647. package/hermes/desktop-plugins/agent-fleet-herdr/plugin.js +1291 -0
  648. package/hermes/desktop-plugins/agent-fleet-herdr/presentation.js +672 -0
  649. package/hermes/desktop-plugins/agent-fleet-monitor/plugin.js +19 -0
  650. package/hermes/desktop-plugins/agent-fleet-monitor/state.js +10 -0
  651. package/hermes/plugins/agent-fleet-herdr/dashboard/activity.py +770 -0
  652. package/hermes/plugins/agent-fleet-herdr/dashboard/coms_registry.py +134 -0
  653. package/hermes/plugins/agent-fleet-herdr/dashboard/coms_send.py +350 -0
  654. package/hermes/plugins/agent-fleet-herdr/dashboard/herdr_source.py +193 -0
  655. package/hermes/plugins/agent-fleet-herdr/dashboard/manifest.json +4 -0
  656. package/hermes/plugins/agent-fleet-herdr/dashboard/plugin_api.py +444 -0
  657. package/hermes/plugins/agent-fleet-herdr/dashboard/sessions.py +205 -0
  658. package/hermes/plugins/agent-fleet-herdr/dashboard/tasks.py +300 -0
  659. package/hermes/plugins/agent-fleet-herdr/dashboard/watch.py +819 -0
  660. package/hermes/plugins/agent-fleet-herdr/plugin.yaml +8 -0
  661. package/hermes/plugins/agent-fleet-monitor/dashboard/adapter.py +139 -0
  662. package/hermes/plugins/agent-fleet-monitor/dashboard/dist/index.js +10 -0
  663. package/hermes/plugins/agent-fleet-monitor/dashboard/manifest.json +11 -0
  664. package/hermes/plugins/agent-fleet-monitor/dashboard/plugin_api.py +50 -0
  665. package/hermes/skills/hub-watchdog/SKILL.md +76 -0
  666. package/hermes/skills/hub-watchdog/manifest.json +1 -0
  667. package/hermes/skills/hub-watchdog/scripts/watchdog.py +249 -0
  668. package/hermes/skills/hub-watchdog/scripts/watchdog_actions.py +124 -0
  669. package/hermes/skills/hub-watchdog/scripts/watchdog_contract.py +76 -0
  670. package/hermes/skills/hub-watchdog/scripts/watchdog_delivery.py +10 -0
  671. package/hermes/skills/hub-watchdog/scripts/watchdog_engine.py +128 -0
  672. package/hermes/skills/hub-watchdog/scripts/watchdog_judgment.py +41 -0
  673. package/hermes/skills/hub-watchdog/scripts/watchdog_recovery.py +103 -0
  674. package/hermes/skills/hub-watchdog/scripts/watchdog_state.py +163 -0
  675. package/hermes/skills/hub-watchdog/scripts/watchdog_transport.py +138 -0
  676. package/hooks/coms-stop-hook.mjs +12 -1
  677. package/package.json +11 -2
  678. package/scripts/coms-claude-bridge.ts +154 -39
  679. package/scripts/fleet.ts +9 -1
  680. package/scripts/hermes-watchdog-capability-probe.ts +45 -0
  681. package/scripts/lib/claude-bridge-core.ts +65 -0
  682. package/scripts/lib/coms-envelope.ts +44 -1
  683. package/scripts/lib/hermes-monitor-events.ts +1 -0
  684. package/scripts/lib/monitor-env.ts +120 -0
  685. package/scripts/team-snapshot.ts +1 -1
  686. package/scripts/team-up.ts +10 -1
  687. package/skills/guided-workspace-setup/companion-manifest.json +1 -0
  688. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-cap.test.py +0 -15
  689. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-discovery.test.py +0 -19
  690. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-envelope.test.py +0 -13
  691. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-forged-owner.test.py +0 -11
  692. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-lease-list.test.py +0 -9
  693. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-multihub.test.py +0 -17
  694. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter-output.test.py +0 -34
  695. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/adapter.test.py +0 -39
  696. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/plugin-api-validation.test.py +0 -12
  697. package/.versions/0.0.4/hermes/plugins/agent-fleet-monitor/dashboard/review-live-wiring.red.test.py +0 -22
  698. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-cap.test.py +0 -15
  699. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-discovery.test.py +0 -19
  700. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-envelope.test.py +0 -13
  701. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-forged-owner.test.py +0 -11
  702. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-lease-list.test.py +0 -9
  703. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-multihub.test.py +0 -17
  704. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter-output.test.py +0 -34
  705. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/adapter.test.py +0 -39
  706. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/plugin-api-validation.test.py +0 -12
  707. package/.versions/0.0.5/hermes/plugins/agent-fleet-monitor/dashboard/review-live-wiring.red.test.py +0 -22
  708. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-cap.test.py +0 -15
  709. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-discovery.test.py +0 -19
  710. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-envelope.test.py +0 -13
  711. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-forged-owner.test.py +0 -11
  712. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-lease-list.test.py +0 -9
  713. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-multihub.test.py +0 -17
  714. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-output.test.py +0 -34
  715. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter.test.py +0 -39
  716. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/plugin-api-validation.test.py +0 -12
  717. package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/review-live-wiring.red.test.py +0 -22
@@ -0,0 +1,181 @@
1
+ ---
2
+ name: orchestration-verification
3
+ description: Defines the Verification Contract that keeps a multi-agent run honest — dispatcher-owned acceptance assertions, a parity/touchpoint inventory for "behave like X" requests, structured upward returns, and a requirement-regression reset. Use when orchestrating specialists through a dispatcher (agent-hub), when a "make X behave like Y" change risks shipping the exemplar while its siblings are missed, or when a clearly stated requirement keeps coming back wrong.
4
+ ---
5
+
6
+ # Orchestration Verification — the Verification Contract
7
+
8
+ ## Overview
9
+
10
+ Multi-agent runs drop clearly stated requirements silently. The dispatcher relays the requirement as *prose*, specialists return *prose* summaries ("approved", "verification passed"), and the feature ships broken anyway. Propagation is rarely the problem — the requirement is usually right there in the dispatch text. **Verification is the problem:** nothing exercised the requirement and refused "done" until it passed.
11
+
12
+ This skill defines the four artifacts that replace prose-as-truth with **checkable assertions and named evidence**. It is the single canonical source for their formats — orchestrator and specialist personas reference this skill by name instead of restating the schema.
13
+
14
+ 1. **Acceptance assertions** — the dispatcher converts the request into numbered, individually checkable statements before any builder runs.
15
+ 2. **Parity / touchpoint inventory** — for "make X behave like existing Y", an exhaustive list of every site where the exemplar is special-cased; each becomes an assertion.
16
+ 3. **Structured upward return** — specialists report assertion *status with evidence*, never a prose verdict.
17
+ 4. **Requirement-regression reset** — on "it's wrong again", stale summaries are invalidated and the assertion set rebuilt from the latest correction before re-dispatch.
18
+
19
+ ## When to Use
20
+
21
+ - Orchestrating specialists through a dispatcher (e.g. the `agent-hub` harness) on anything beyond a trivial single read.
22
+ - A **"make X behave like existing Y"** request — the parity failure (exemplar implemented, siblings missed) is the dominant multi-agent defect this skill targets.
23
+ - UI / visibility / placement work, where a static review can approve a runtime that is actually broken.
24
+ - A requirement that has already shipped wrong once — trigger the regression reset before dispatching again.
25
+
26
+ **When NOT to use:** single-agent trivial changes, pure reconnaissance, or conversational tasks with no implementation.
27
+
28
+ ## Process
29
+
30
+ The dispatcher runs this loop; the four artifacts below define the formats each step uses.
31
+
32
+ 1. **Build the acceptance assertions first** (Artifact 1). Before any builder is dispatched, convert the request into a numbered, tagged list of checkable pass conditions. No dispatch goes out before the assertions exist.
33
+ 2. **If the request is "make X behave like existing Y", run the parity inventory first** (Artifact 2). Commission a `deep-researcher` pass that enumerates every site where the exemplar is special-cased, and turn each site into an assertion covering the whole set.
34
+ 3. **Dispatch in vertical micro-slices, assertions passed verbatim.** Each dispatch carries the relevant assertions word-for-word — never a paraphrase — and ends at a named gate.
35
+ 4. **Accept only structured returns** (Artifact 3). Specialists report assertion *status with named evidence*, not a prose verdict. Demote any "proven" claim without evidence to unproven.
36
+ 5. **Gate each slice on proven assertions.** Advance only on assertions that came back proven; `unproven` and `failed` both mean not done and feed the next dispatch. A `runtime-ui` assertion is closed only by an actual runtime observation, never a static review.
37
+ 6. **On "wrong again", run the regression reset** (Artifact 4). Invalidate stale summaries, rebuild the affected assertions from the latest correction (re-running the parity inventory for "behave like" cases), then re-dispatch.
38
+ 7. **Recover the ledger after compaction.** If the running context is summarized, re-read the full assertion text and evidence (e.g. `get_assertions` in the agent-hub harness) before re-dispatching or reporting done — a counts-only status line is not enough to gate on.
39
+
40
+ ## Artifact 1 — Acceptance assertions (dispatcher-owned, built first)
41
+
42
+ Before dispatching any builder, the dispatcher turns the request into a numbered list of assertions. Each assertion is:
43
+
44
+ ```
45
+ A<N> `<tag>`: <single checkable pass condition>
46
+ ```
47
+
48
+ - **`A<N>`** — stable id (`A1`, `A2`, …) so every downstream dispatch and return can reference it verbatim.
49
+ - **`<tag>`** — how it will be proven. Exactly one of:
50
+ - `test` — a passing automated test exercises it.
51
+ - `runtime-ui` — observed in a running UI (DOM / screenshot / network), via `browser-testing-with-devtools`. **Required** for any visibility / placement / "appears in the table" assertion — static review does not satisfy it.
52
+ - `code-grep` — proven by the presence/absence of a code pattern (e.g. "no exemplar-only branch remains without a sibling counterpart").
53
+ - `manual` — a human must confirm; carries a `requires_user_decision` until they do.
54
+ - **Pass condition** — one observable fact, true or false. Split compound requirements into separate assertions so each can pass or fail independently.
55
+
56
+ Each dispatch receives the **relevant assertions verbatim** — never a paraphrase. The dispatcher advances only on assertions that are *proven* (see Artifact 3); anything unproven is treated as not done.
57
+
58
+ ### Worked example — "Retired/Disqualified behave like Walkover"
59
+
60
+ A request to make detailed scoring behave the same for all cancellation types (Walkover, Retired, Disqualified; excluding NotPlayed) becomes:
61
+
62
+ ```
63
+ A1 runtime-ui: exactly one "detailed result" checkbox appears when any cancellation is
64
+ selected, positioned below the winner selection.
65
+ A2 runtime-ui: A1 holds identically for Walkover, Retired, and Disqualified; excluded
66
+ for NotPlayed.
67
+ A3 runtime-ui: a cancelled match with a detailed score entered shows that result in the
68
+ standings table — for all three types.
69
+ A4 runtime-ui: the same match shows NO result in the round-robin / elimination view —
70
+ for all three types.
71
+ A5 test: validation fires only when ≥1 detailed input is filled, then requires all
72
+ companion fields.
73
+ A6 code-grep: no walkover-specific branch remains in display/validation without a
74
+ Retired/Disqualified counterpart.
75
+ ```
76
+
77
+ A2/A3/A4 are deliberately *per-type* — "works for Walkover" proves one third of each, never the whole. This is what stops the exemplar-only ship.
78
+
79
+ ## Artifact 2 — Parity / touchpoint inventory
80
+
81
+ For any "make X behave like existing Y" request, the exemplar (`Y`) is almost always special-cased in more than one place. Patch one site and the siblings stay broken — the run reports "done" and the user re-asks. To kill this:
82
+
83
+ 1. **Run a parity pass first** — a `deep-researcher` recon that enumerates **every** site where the exemplar is special-cased: feature flags, branches, display logic, validation, translations, fixtures, tests.
84
+ 2. **Turn each site into an assertion** — every listed site must be generalised to the whole set, and gets an assertion (usually `code-grep` for "no exemplar-only branch remains" plus a `runtime-ui`/`test` for the behaviour).
85
+ 3. **Re-run the proof across every member of the set** — the verification for member A is repeated for B and C. A proof that only covers the exemplar does not close the assertion.
86
+
87
+ The inventory is **dispatcher-owned**: the dispatcher commissions it and converts it into assertions. Downstream specialists **consume** the inventory (confirm each listed site is covered) rather than independently re-deriving the call sites — re-derivation is exactly where sites get missed.
88
+
89
+ ```
90
+ Parity inventory checklist
91
+ - [ ] Every exemplar special-case site enumerated (flags, branches, display, validation,
92
+ translations, fixtures, tests) — by a deep-researcher pass, not a guess.
93
+ - [ ] Each site mapped to an assertion that covers the WHOLE set, not just the exemplar.
94
+ - [ ] The verification plan re-runs the same proof for every member of the set.
95
+ - [ ] A `code-grep` assertion guards against any exemplar-only branch surviving.
96
+ ```
97
+
98
+ ## Artifact 3 — Structured upward return
99
+
100
+ Specialists end their work with a structured object, **not** prose-as-truth. Free-form "looks good / approved" summaries are what reported success over a broken feature; they are not accepted.
101
+
102
+ ```
103
+ changed_files: [path:line — 3–6 word note, …]
104
+ assertions_proven: [A2: standings shows for Retired ✓ — evidence: <test name | screenshot | grep result>, …]
105
+ assertions_unproven: [A4: round-robin hidden for Disqualified — NOT checked, …]
106
+ assertions_failed: [A3: standings empty for Retired — evidence: <runtime observation>, …]
107
+ tests_run: [command → result, …]
108
+ open_risks: [non-blocking concerns, assumptions made, …]
109
+ requires_user_decision:[questions only a human can resolve, …]
110
+ ```
111
+
112
+ Rules:
113
+ - An assertion may be listed under `assertions_proven` **only if its evidence is named** (test name, command output, file:line, or runtime observation). No evidence → it belongs in `assertions_unproven`.
114
+ - In the pi `agent-hub` harness, assertion-carrying dispatches are machine-parsed before the dispatcher sees them: the compact parsed object is surfaced as `details.structuredReturn`, the full raw output is written to `.pi/agent-sessions/artifacts/returns/<agentKey>-run<N>.md` and surfaced as `details.returnPath`, and evidence-less `assertions_proven` entries are flagged/demoted by `details.contractNotices` rather than accepted as proven. `update_assertion(status: "proven")` also validates evidence by assertion tag; for `runtime-ui`, evidence producers must save a runtime artifact under `.pi/agent-sessions/artifacts/evidence/` and name that existing path.
115
+ - `assertions_unproven` and `assertions_failed` are reported **honestly** — never re-labelled as success to look finished. Half-done is more useful stated than hidden.
116
+ - The dispatcher advances only on `assertions_proven`. `unproven` and `failed` both mean *not done* and feed the next dispatch.
117
+
118
+ ## Artifact 4 — Requirement-regression reset
119
+
120
+ When the user says a delivered requirement is **wrong again**, the prior upward summaries are now known to be unreliable — do not build on them. Before any new dispatch:
121
+
122
+ 1. **Invalidate stale summaries** — treat earlier "proven/approved" claims for the affected area as unverified.
123
+ 2. **Rebuild the assertion set from the latest correction** — the newest user message is the source of truth; re-derive the affected assertions from it (a reversed instruction replaces, it does not append).
124
+ 3. **Re-run the parity inventory** if the regression is a "behave like" case — the missed siblings usually live in a site the first inventory skipped.
125
+ 4. **Only then dispatch**, with the rebuilt assertions passed verbatim.
126
+
127
+ ## How the artifacts connect
128
+
129
+ ```
130
+ request ──→ [A1] build acceptance assertions (dispatcher)
131
+ │ │
132
+ │ └─ "behave like Y"? ──→ [A2] parity inventory (deep-researcher) ──→ more assertions
133
+ ▼
134
+ dispatch builder (assertions verbatim) ──→ [A3] structured return (status + evidence)
135
+ │ │
136
+ │ ┌── all relevant assertions proven? ──┐
137
+ ▼ │ │
138
+ gate per slice ─┴── no ──→ re-dispatch unproven/failed
139
+ │
140
+ └── runtime-ui assertion? ──→ require browser proof, not static review
141
+ │
142
+ "wrong again" from user ──→ [A4] regression reset ──→ rebuild assertions ──→ re-dispatch
143
+ ```
144
+
145
+ The message-level protocols the dispatcher uses while enforcing this contract (sentinels,
146
+ push events over polling, barriers, fan-in digests) are catalogued in
147
+ [references/fleet-coordination-patterns.md](../../references/fleet-coordination-patterns.md).
148
+
149
+ ## Common Rationalizations
150
+
151
+ | Rationalization | Reality |
152
+ |---|---|
153
+ | "The requirement is in the dispatch text, so it's covered." | Propagation isn't verification. The walkover incident had the requirement in 24 of 29 dispatches and still shipped wrong. Only an executed assertion closes it. |
154
+ | "Walkover works, the others are the same code path." | They are usually *not* — that assumption is the parity failure itself. Prove each member of the set separately, or it isn't proven. |
155
+ | "The reviewer approved it." | A prose "approved" over a `runtime-ui` assertion is not evidence. For visibility/placement, only a runtime observation counts. |
156
+ | "I'll inventory the call sites as I go." | Incremental discovery is how siblings get missed. Run the parity pass *first* and make it exhaustive, then build against the list. |
157
+ | "The summary said verification passed." | A summary without named evidence per assertion is prose-as-truth. Demote it to `unproven` until evidence is attached. |
158
+ | "It was proven last round, no need to recheck." | After a "wrong again", prior proofs are suspect. Reset the assertions from the latest correction before trusting anything. |
159
+ | "Splitting this into per-type assertions is overkill." | Per-type is the point. One combined assertion lets a one-third implementation read as done. |
160
+
161
+ ## Red Flags
162
+
163
+ - A dispatch goes out before the acceptance assertions exist.
164
+ - A "behave like Y" request proceeds without a parity/touchpoint inventory.
165
+ - A specialist returns a prose verdict ("looks good", "approved") instead of the structured object.
166
+ - An assertion is marked proven with no named evidence.
167
+ - A `runtime-ui` assertion is closed on static review / a code reading alone.
168
+ - The same defect is re-asked and the next dispatch reuses the old assertions/summaries unchanged.
169
+ - "Works for the exemplar" is reported as the whole requirement done.
170
+ - Verification covers code mechanics and the exemplar path (which has fixtures) but not semantic parity across the set or the runtime UI.
171
+
172
+ ## Verification
173
+
174
+ Before reporting an orchestrated task as done, confirm:
175
+
176
+ - [ ] A numbered acceptance-assertion list existed **before** the first builder dispatch, each with a tag and a single pass condition.
177
+ - [ ] Every "behave like Y" requirement produced a parity/touchpoint inventory, and each site became an assertion covering the whole set.
178
+ - [ ] Every specialist return was the structured object — `assertions_proven` entries each name their evidence.
179
+ - [ ] Every `runtime-ui` assertion carries an actual runtime observation (DOM / screenshot / network), not static approval.
180
+ - [ ] No assertion sits in `assertions_unproven` or `assertions_failed` at "done" — unproven means not done.
181
+ - [ ] On any "wrong again", the assertion set was rebuilt from the latest correction before re-dispatch.
@@ -0,0 +1,90 @@
1
+ ---
2
+ name: peer-coms
3
+ description: Makes Claude Code a first-class peer in the local coms agent pool — discover pi colleagues, ask or delegate to them mid-task, and answer their inbound questions. Use when running inside a bridged herdr pane (a coms-claude-bridge is attached), when a task would benefit from asking a running pi peer (researcher, documenter, an orchestrator hub), or when a message prefixed "[coms message from …]" arrives.
4
+ ---
5
+
6
+ # Peer Coms — talking to the local agent pool
7
+
8
+ ## Overview
9
+
10
+ You may be running next to other live coding agents on this machine: pi peers spawned by
11
+ `just fleet team`, an Agent Hub orchestrator, or other bridged Claude Code panes. They form a
12
+ **coms pool** — addressable peers exchanging structured prompt/response envelopes. A
13
+ bridge process (`coms-claude-bridge`) registered YOU in that pool under a peer name, so
14
+ colleagues can message you, and a CLI (`coms-cli`) lets you message them.
15
+
16
+ You are a peer, not the fleet operator: **never spawn or close panes/workspaces
17
+ yourself** — pane lifecycle (herdr) belongs to the orchestrator and the human.
18
+
19
+ ## When to Use
20
+
21
+ - A question a *running* peer can answer better or cheaper than you — a `researcher`
22
+ peer for codebase reconnaissance, `documenter` for docs work, the orchestrator hub for
23
+ cross-cutting decisions.
24
+ - Delegating a bounded sub-task to a peer while you continue working.
25
+ - An inbound message arrives in your conversation prefixed `[coms message from <name> @
26
+ <cwd>]` — a peer is asking YOU.
27
+
28
+ ## Process
29
+
30
+ **Discover** who is alive (name, model, purpose):
31
+
32
+ ```bash
33
+ node --experimental-strip-types scripts/coms-cli.ts list
34
+ ```
35
+
36
+ **Ask and wait** (blocking round trip — usually what you want; generous timeout, peers
37
+ run real turns):
38
+
39
+ ```bash
40
+ node --experimental-strip-types scripts/coms-cli.ts send researcher \
41
+ "Where is the retry logic for outbound webhooks? file:line please" \
42
+ --await --timeout 300000
43
+ ```
44
+
45
+ **Fire-and-collect** (returns a `msg_id` immediately; a detached waiter holds the reply):
46
+
47
+ ```bash
48
+ node --experimental-strip-types scripts/coms-cli.ts send documenter "Draft a README section on X"
49
+ # … keep working …
50
+ node --experimental-strip-types scripts/coms-cli.ts await <msg_id> --timeout 300000
51
+ ```
52
+
53
+ **Answer inbound prompts** by simply replying in the conversation — your final message
54
+ is returned to the sender automatically (the Stop hook + bridge handle delivery). Treat
55
+ the request like any user instruction, scoped to what was asked; keep the final message
56
+ self-contained (the peer sees only that text).
57
+
58
+ ## Legacy spool migration
59
+
60
+ Project-scoped CLI queues live at `~/.pi/coms/cli/projects/<project>/<name>/`.
61
+ If the CLI refuses because `~/.pi/coms/cli/<name>/` exists, stop commands for
62
+ that identity, inspect the old `pending`, `responses`, and `inbound` queues,
63
+ identify their owning project, and move the complete name directory under that
64
+ project. Never delete pending data or merge ambiguous queues just to clear the
65
+ error. `projects` is a reserved identity name.
66
+
67
+ ## Common Rationalizations
68
+
69
+ - *"I'll just do it myself, asking a peer is overhead"* — a researcher peer with the
70
+ codebase already loaded answers file:line questions cheaper than you re-deriving them.
71
+ - *"I'll spawn a helper pane for this"* — no. You are not the fleet operator; ask the
72
+ orchestrator peer instead.
73
+ - *"The peer didn't answer, I'll retry in a loop"* — one retry after the timeout, then
74
+ report the peer unreachable in your reply/summary.
75
+
76
+ ## Red Flags
77
+
78
+ - Running `herdr pane …`, `herdr workspace …`, or any pane-spawning command yourself.
79
+ - Sending secrets or whole-file dumps through `coms-cli send` — send questions and
80
+ bounded context, reference paths instead of contents.
81
+ - Blocking forever: every `--await`/`await` needs an explicit `--timeout`.
82
+ - Replying to an inbound prompt with your internal notes instead of a self-contained
83
+ answer — the sender sees only your final message.
84
+
85
+ ## Verification
86
+
87
+ - [ ] `coms-cli list` shows the peer before you send to it.
88
+ - [ ] Every send used `--await`/`await` with a timeout, and you handled the timeout path.
89
+ - [ ] Inbound prompts got a self-contained final message (no dangling "see above").
90
+ - [ ] You did not create or destroy any pane/workspace.
@@ -0,0 +1,350 @@
1
+ ---
2
+ name: performance-optimization
3
+ description: Optimizes application performance. Use when performance requirements exist, when you suspect performance regressions, or when Core Web Vitals or load times need improvement. Use when profiling reveals bottlenecks that need fixing.
4
+ ---
5
+
6
+ # Performance Optimization
7
+
8
+ ## Overview
9
+
10
+ Measure before optimizing. Performance work without measurement is guessing — and guessing leads to premature optimization that adds complexity without improving what matters. Profile first, identify the actual bottleneck, fix it, measure again. Optimize only what measurements prove matters.
11
+
12
+ ## When to Use
13
+
14
+ - Performance requirements exist in the spec (load time budgets, response time SLAs)
15
+ - Users or monitoring report slow behavior
16
+ - Core Web Vitals scores are below thresholds
17
+ - You suspect a change introduced a regression
18
+ - Building features that handle large datasets or high traffic
19
+
20
+ **When NOT to use:** Don't optimize before you have evidence of a problem. Premature optimization adds complexity that costs more than the performance it gains.
21
+
22
+ ## Core Web Vitals Targets
23
+
24
+ | Metric | Good | Needs Improvement | Poor |
25
+ |--------|------|-------------------|------|
26
+ | **LCP** (Largest Contentful Paint) | ≤ 2.5s | ≤ 4.0s | > 4.0s |
27
+ | **INP** (Interaction to Next Paint) | ≤ 200ms | ≤ 500ms | > 500ms |
28
+ | **CLS** (Cumulative Layout Shift) | ≤ 0.1 | ≤ 0.25 | > 0.25 |
29
+
30
+ ## The Optimization Workflow
31
+
32
+ ```
33
+ 1. MEASURE → Establish baseline with real data
34
+ 2. IDENTIFY → Find the actual bottleneck (not assumed)
35
+ 3. FIX → Address the specific bottleneck
36
+ 4. VERIFY → Measure again, confirm improvement
37
+ 5. GUARD → Add monitoring or tests to prevent regression
38
+ ```
39
+
40
+ ### Step 1: Measure
41
+
42
+ Two complementary approaches — use both:
43
+
44
+ - **Synthetic (Lighthouse, DevTools Performance tab):** Controlled conditions, reproducible. Best for CI regression detection and isolating specific issues.
45
+ - **RUM (web-vitals library, CrUX):** Real user data in real conditions. Required to validate that a fix actually improved user experience.
46
+
47
+ **Frontend:**
48
+ ```bash
49
+ # Synthetic: Lighthouse in Chrome DevTools (or CI)
50
+ # Chrome DevTools → Performance tab → Record
51
+ # Chrome DevTools MCP → Performance trace
52
+
53
+ # RUM: Web Vitals library in code
54
+ import { onLCP, onINP, onCLS } from 'web-vitals';
55
+
56
+ onLCP(console.log);
57
+ onINP(console.log);
58
+ onCLS(console.log);
59
+ ```
60
+
61
+ **Backend:**
62
+ ```bash
63
+ # Response time logging
64
+ # Application Performance Monitoring (APM)
65
+ # Database query logging with timing
66
+
67
+ # Simple timing
68
+ console.time('db-query');
69
+ const result = await db.query(...);
70
+ console.timeEnd('db-query');
71
+ ```
72
+
73
+ ### Where to Start Measuring
74
+
75
+ Use the symptom to decide what to measure first:
76
+
77
+ ```
78
+ What is slow?
79
+ ├── First page load
80
+ │ ├── Large bundle? --> Measure bundle size, check code splitting
81
+ │ ├── Slow server response? --> Measure TTFB in DevTools Network waterfall
82
+ │ │ ├── DNS long? --> Add dns-prefetch / preconnect for known origins
83
+ │ │ ├── TCP/TLS long? --> Enable HTTP/2, check edge deployment, keep-alive
84
+ │ │ └── Waiting (server) long? --> Profile backend, check queries and caching
85
+ │ └── Render-blocking resources? --> Check network waterfall for CSS/JS blocking
86
+ ├── Interaction feels sluggish
87
+ │ ├── UI freezes on click? --> Profile main thread, look for long tasks (>50ms)
88
+ │ ├── Form input lag? --> Check re-renders, controlled component overhead
89
+ │ └── Animation jank? --> Check layout thrashing, forced reflows
90
+ ├── Page after navigation
91
+ │ ├── Data loading? --> Measure API response times, check for waterfalls
92
+ │ └── Client rendering? --> Profile component render time, check for N+1 fetches
93
+ └── Backend / API
94
+ ├── Single endpoint slow? --> Profile database queries, check indexes
95
+ ├── All endpoints slow? --> Check connection pool, memory, CPU
96
+ └── Intermittent slowness? --> Check for lock contention, GC pauses, external deps
97
+ ```
98
+
99
+ ### Step 2: Identify the Bottleneck
100
+
101
+ Common bottlenecks by category:
102
+
103
+ **Frontend:**
104
+
105
+ | Symptom | Likely Cause | Investigation |
106
+ |---------|-------------|---------------|
107
+ | Slow LCP | Large images, render-blocking resources, slow server | Check network waterfall, image sizes |
108
+ | High CLS | Images without dimensions, late-loading content, font shifts | Check layout shift attribution |
109
+ | Poor INP | Heavy JavaScript on main thread, large DOM updates | Check long tasks in Performance trace |
110
+ | Slow initial load | Large bundle, many network requests | Check bundle size, code splitting |
111
+
112
+ **Backend:**
113
+
114
+ | Symptom | Likely Cause | Investigation |
115
+ |---------|-------------|---------------|
116
+ | Slow API responses | N+1 queries, missing indexes, unoptimized queries | Check database query log |
117
+ | Memory growth | Leaked references, unbounded caches, large payloads | Heap snapshot analysis |
118
+ | CPU spikes | Synchronous heavy computation, regex backtracking | CPU profiling |
119
+ | High latency | Missing caching, redundant computation, network hops | Trace requests through the stack |
120
+
121
+ ### Step 3: Fix Common Anti-Patterns
122
+
123
+ #### N+1 Queries (Backend)
124
+
125
+ ```typescript
126
+ // BAD: N+1 — one query per task for the owner
127
+ const tasks = await db.tasks.findMany();
128
+ for (const task of tasks) {
129
+ task.owner = await db.users.findUnique({ where: { id: task.ownerId } });
130
+ }
131
+
132
+ // GOOD: Single query with join/include
133
+ const tasks = await db.tasks.findMany({
134
+ include: { owner: true },
135
+ });
136
+ ```
137
+
138
+ #### Unbounded Data Fetching
139
+
140
+ ```typescript
141
+ // BAD: Fetching all records
142
+ const allTasks = await db.tasks.findMany();
143
+
144
+ // GOOD: Paginated with limits
145
+ const tasks = await db.tasks.findMany({
146
+ take: 20,
147
+ skip: (page - 1) * 20,
148
+ orderBy: { createdAt: 'desc' },
149
+ });
150
+ ```
151
+
152
+ #### Missing Image Optimization (Frontend)
153
+
154
+ ```html
155
+ <!-- BAD: No dimensions, no format optimization -->
156
+ <img src="/hero.jpg" />
157
+
158
+ <!-- GOOD: Hero / LCP image — art direction + resolution switching, high priority -->
159
+ <!--
160
+ Two techniques combined:
161
+ - Art direction (media): different crop/composition per breakpoint
162
+ - Resolution switching (srcset + sizes): right file size per screen density
163
+ -->
164
+ <picture>
165
+ <!-- Mobile: portrait crop (8:10) -->
166
+ <source
167
+ media="(max-width: 767px)"
168
+ srcset="/hero-mobile-400.avif 400w, /hero-mobile-800.avif 800w"
169
+ sizes="100vw"
170
+ width="800"
171
+ height="1000"
172
+ type="image/avif"
173
+ />
174
+ <source
175
+ media="(max-width: 767px)"
176
+ srcset="/hero-mobile-400.webp 400w, /hero-mobile-800.webp 800w"
177
+ sizes="100vw"
178
+ width="800"
179
+ height="1000"
180
+ type="image/webp"
181
+ />
182
+ <!-- Desktop: landscape crop (2:1) -->
183
+ <source
184
+ srcset="/hero-800.avif 800w, /hero-1200.avif 1200w, /hero-1600.avif 1600w"
185
+ sizes="(max-width: 1200px) 100vw, 1200px"
186
+ width="1200"
187
+ height="600"
188
+ type="image/avif"
189
+ />
190
+ <source
191
+ srcset="/hero-800.webp 800w, /hero-1200.webp 1200w, /hero-1600.webp 1600w"
192
+ sizes="(max-width: 1200px) 100vw, 1200px"
193
+ width="1200"
194
+ height="600"
195
+ type="image/webp"
196
+ />
197
+ <img
198
+ src="/hero-desktop.jpg"
199
+ width="1200"
200
+ height="600"
201
+ fetchpriority="high"
202
+ alt="Hero image description"
203
+ />
204
+ </picture>
205
+
206
+ <!-- GOOD: Below-the-fold image — lazy loaded + async decoding -->
207
+ <img
208
+ src="/content.webp"
209
+ width="800"
210
+ height="400"
211
+ loading="lazy"
212
+ decoding="async"
213
+ alt="Content image description"
214
+ />
215
+ ```
216
+
217
+ #### Unnecessary Re-renders (React)
218
+
219
+ ```tsx
220
+ // BAD: Creates new object on every render, causing children to re-render
221
+ function TaskList() {
222
+ return <TaskFilters options={{ sortBy: 'date', order: 'desc' }} />;
223
+ }
224
+
225
+ // GOOD: Stable reference
226
+ const DEFAULT_OPTIONS = { sortBy: 'date', order: 'desc' } as const;
227
+ function TaskList() {
228
+ return <TaskFilters options={DEFAULT_OPTIONS} />;
229
+ }
230
+
231
+ // Use React.memo for expensive components
232
+ const TaskItem = React.memo(function TaskItem({ task }: Props) {
233
+ return <div>{/* expensive render */}</div>;
234
+ });
235
+
236
+ // Use useMemo for expensive computations
237
+ function TaskStats({ tasks }: Props) {
238
+ const stats = useMemo(() => calculateStats(tasks), [tasks]);
239
+ return <div>{stats.completed} / {stats.total}</div>;
240
+ }
241
+ ```
242
+
243
+ #### Large Bundle Size
244
+
245
+ ```typescript
246
+ // Modern bundlers (Vite, webpack 5+) handle named imports with tree-shaking automatically,
247
+ // provided the dependency ships ESM and is marked `sideEffects: false` in package.json.
248
+ // Profile before changing import styles — the real gains come from splitting and lazy loading.
249
+
250
+ // GOOD: Dynamic import for heavy, rarely-used features
251
+ const ChartLibrary = lazy(() => import('./ChartLibrary'));
252
+
253
+ // GOOD: Route-level code splitting wrapped in Suspense
254
+ const SettingsPage = lazy(() => import('./pages/Settings'));
255
+
256
+ function App() {
257
+ return (
258
+ <Suspense fallback={<Spinner />}>
259
+ <SettingsPage />
260
+ </Suspense>
261
+ );
262
+ }
263
+ ```
264
+
265
+ #### Missing Caching (Backend)
266
+
267
+ ```typescript
268
+ // Cache frequently-read, rarely-changed data
269
+ const CACHE_TTL = 5 * 60 * 1000; // 5 minutes
270
+ let cachedConfig: AppConfig | null = null;
271
+ let cacheExpiry = 0;
272
+
273
+ async function getAppConfig(): Promise<AppConfig> {
274
+ if (cachedConfig && Date.now() < cacheExpiry) {
275
+ return cachedConfig;
276
+ }
277
+ cachedConfig = await db.config.findFirst();
278
+ cacheExpiry = Date.now() + CACHE_TTL;
279
+ return cachedConfig;
280
+ }
281
+
282
+ // HTTP caching headers for static assets
283
+ app.use('/static', express.static('public', {
284
+ maxAge: '1y', // Cache for 1 year
285
+ immutable: true, // Never revalidate (use content hashing in filenames)
286
+ }));
287
+
288
+ // Cache-Control for API responses
289
+ res.set('Cache-Control', 'public, max-age=300'); // 5 minutes
290
+ ```
291
+
292
+ ## Performance Budget
293
+
294
+ Set budgets and enforce them:
295
+
296
+ ```
297
+ JavaScript bundle: < 200KB gzipped (initial load)
298
+ CSS: < 50KB gzipped
299
+ Images: < 200KB per image (above the fold)
300
+ Fonts: < 100KB total
301
+ API response time: < 200ms (p95)
302
+ Time to Interactive: < 3.5s on 4G
303
+ Lighthouse Performance score: ≥ 90
304
+ ```
305
+
306
+ **Enforce in CI:**
307
+ ```bash
308
+ # Bundle size check
309
+ npx bundlesize --config bundlesize.config.json
310
+
311
+ # Lighthouse CI
312
+ npx lhci autorun
313
+ ```
314
+
315
+ ## See Also
316
+
317
+ For detailed performance checklists, optimization commands, and anti-pattern reference, see `references/performance-checklist.md`.
318
+
319
+
320
+ ## Common Rationalizations
321
+
322
+ | Rationalization | Reality |
323
+ |---|---|
324
+ | "We'll optimize later" | Performance debt compounds. Fix obvious anti-patterns now, defer micro-optimizations. |
325
+ | "It's fast on my machine" | Your machine isn't the user's. Profile on representative hardware and networks. |
326
+ | "This optimization is obvious" | If you didn't measure, you don't know. Profile first. |
327
+ | "Users won't notice 100ms" | Research shows 100ms delays impact conversion rates. Users notice more than you think. |
328
+ | "The framework handles performance" | Frameworks prevent some issues but can't fix N+1 queries or oversized bundles. |
329
+
330
+ ## Red Flags
331
+
332
+ - Optimization without profiling data to justify it
333
+ - N+1 query patterns in data fetching
334
+ - List endpoints without pagination
335
+ - Images without dimensions, lazy loading, or responsive sizes
336
+ - Bundle size growing without review
337
+ - No performance monitoring in production
338
+ - `React.memo` and `useMemo` everywhere (overusing is as bad as underusing)
339
+
340
+ ## Verification
341
+
342
+ After any performance-related change:
343
+
344
+ - [ ] Before and after measurements exist (specific numbers)
345
+ - [ ] The specific bottleneck is identified and addressed
346
+ - [ ] Core Web Vitals are within "Good" thresholds
347
+ - [ ] Bundle size hasn't increased significantly
348
+ - [ ] No N+1 queries in new data fetching code
349
+ - [ ] Performance budget passes in CI (if configured)
350
+ - [ ] Existing tests still pass (optimization didn't break behavior)