@chankov/agent-fleet 0.0.4 → 0.0.6
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.
- package/.claude/commands/set-hermes-telegram.md +15 -0
- package/.opencode/commands/af-set-hermes-telegram.md +15 -0
- package/.pi/agents/dispatch-policy.yaml +1 -1
- package/.pi/agents/peers.yaml +4 -4
- package/.pi/extensions/agent-fleet-update-check/README.md +4 -4
- package/.pi/extensions/btw/README.md +10 -10
- package/.pi/extensions/btw/index.ts +11 -11
- package/.pi/extensions/chrome-devtools-mcp/README.md +3 -3
- package/.pi/extensions/chrome-devtools-mcp/index.ts +1 -0
- package/.pi/extensions/compact-and-continue/README.md +2 -2
- package/.pi/extensions/mcp-bridge/README.md +1 -1
- package/.pi/extensions/pi-voice-stt/README.md +7 -7
- package/.pi/extensions/pi-voice-stt/index.ts +4 -4
- package/.pi/harnesses/agent-hub/README.md +84 -84
- package/.pi/harnesses/agent-hub/backend-policy.js +1 -1
- package/.pi/harnesses/agent-hub/delegate.ts +3 -3
- package/.pi/harnesses/agent-hub/drift-watchdog.js +1 -1
- package/.pi/harnesses/agent-hub/index.ts +254 -254
- package/.pi/harnesses/agent-hub/monitor-lifecycle.ts +1 -1
- package/.pi/harnesses/agent-hub/monitor-publisher.ts +3 -3
- package/.pi/harnesses/agent-hub/monitor-session-bridge.ts +1 -1
- package/.pi/harnesses/agent-hub/package.json +1 -1
- package/.pi/harnesses/agent-hub/run-budget.js +1 -1
- package/.pi/harnesses/ask-user-remote/README.md +1 -0
- package/.pi/harnesses/ask-user-remote/index.ts +36 -8
- package/.pi/harnesses/coms/README.md +7 -7
- package/.pi/harnesses/coms/index.ts +13 -13
- package/.pi/harnesses/coms/package.json +1 -1
- package/.pi/harnesses/damage-control-continue/README.md +16 -16
- package/.pi/harnesses/damage-control-continue/index.ts +11 -11
- package/.pi/harnesses/damage-control-continue/package.json +1 -1
- package/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
- package/.pi/harnesses/lib/hermes-monitor-model.ts +9 -0
- package/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
- package/.pi/harnesses/lib/hermes-monitor-socket.ts +118 -0
- package/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
- package/.pi/prompts/af-doctor-agent-fleet.md +15 -0
- package/.pi/prompts/af-set-hermes-telegram.md +15 -0
- package/.pi/prompts/af-setup-agent-fleet.md +27 -0
- package/.versions/0.0.5/.claude/commands/build.md +44 -0
- package/.versions/0.0.5/.claude/commands/code-simplify.md +22 -0
- package/.versions/0.0.5/.claude/commands/design-agent.md +14 -0
- package/.versions/0.0.5/.claude/commands/doctor-agent-fleet.md +17 -0
- package/.versions/0.0.5/.claude/commands/orchestrate.md +112 -0
- package/.versions/0.0.5/.claude/commands/plan.md +16 -0
- package/.versions/0.0.5/.claude/commands/prime.md +22 -0
- package/.versions/0.0.5/.claude/commands/review.md +16 -0
- package/.versions/0.0.5/.claude/commands/set-hermes-telegram.md +15 -0
- package/.versions/0.0.5/.claude/commands/setup-agent-fleet.md +25 -0
- package/.versions/0.0.5/.claude/commands/ship.md +72 -0
- package/.versions/0.0.5/.claude/commands/spec.md +15 -0
- package/.versions/0.0.5/.claude/commands/test.md +19 -0
- package/.versions/0.0.5/.claude/commands/webperf.md +32 -0
- package/.versions/0.0.5/.claude/orchestrate-teams.yaml +24 -0
- package/.versions/0.0.5/.opencode/commands/af-build.md +17 -0
- package/.versions/0.0.5/.opencode/commands/af-code-simplify.md +16 -0
- package/.versions/0.0.5/.opencode/commands/af-compound.md +16 -0
- package/.versions/0.0.5/.opencode/commands/af-design-agent.md +15 -0
- package/.versions/0.0.5/.opencode/commands/af-doctor-agent-fleet.md +17 -0
- package/.versions/0.0.5/.opencode/commands/af-orchestrate.md +112 -0
- package/.versions/0.0.5/.opencode/commands/af-plan.md +16 -0
- package/.versions/0.0.5/.opencode/commands/af-prime.md +22 -0
- package/.versions/0.0.5/.opencode/commands/af-review.md +15 -0
- package/.versions/0.0.5/.opencode/commands/af-set-hermes-telegram.md +15 -0
- package/.versions/0.0.5/.opencode/commands/af-setup-agent-fleet.md +15 -0
- package/.versions/0.0.5/.opencode/commands/af-ship.md +16 -0
- package/.versions/0.0.5/.opencode/commands/af-spec.md +16 -0
- package/.versions/0.0.5/.opencode/commands/af-test.md +21 -0
- package/.versions/0.0.5/.opencode/commands/af-webperf.md +32 -0
- package/.versions/0.0.5/.opencode/orchestrate-teams.yaml +24 -0
- package/.versions/0.0.5/.pi/agents/dispatch-policy.yaml +32 -0
- package/.versions/0.0.5/.pi/agents/model-profiles.yaml +20 -0
- package/.versions/0.0.5/.pi/agents/peers.yaml +146 -0
- package/.versions/0.0.5/.pi/agents/teams.yaml +39 -0
- package/.versions/0.0.5/.pi/damage-control-rules.yaml +297 -0
- package/.versions/0.0.5/.pi/extensions/agent-fleet-update-check/README.md +58 -0
- package/.versions/0.0.5/.pi/extensions/agent-fleet-update-check/index.ts +161 -0
- package/.versions/0.0.5/.pi/extensions/agent-fleet-update-check/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/btw/README.md +118 -0
- package/.versions/0.0.5/.pi/extensions/btw/index.ts +917 -0
- package/.versions/0.0.5/.pi/extensions/btw/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/btw/state.js +179 -0
- package/.versions/0.0.5/.pi/extensions/chrome-devtools-mcp/README.md +58 -0
- package/.versions/0.0.5/.pi/extensions/chrome-devtools-mcp/index.ts +92 -0
- package/.versions/0.0.5/.pi/extensions/chrome-devtools-mcp/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/compact-and-continue/README.md +42 -0
- package/.versions/0.0.5/.pi/extensions/compact-and-continue/index.ts +120 -0
- package/.versions/0.0.5/.pi/extensions/compact-and-continue/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/mcp-bridge/README.md +46 -0
- package/.versions/0.0.5/.pi/extensions/mcp-bridge/index.ts +206 -0
- package/.versions/0.0.5/.pi/extensions/mcp-bridge/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/package-lock.json +1143 -0
- package/.versions/0.0.5/.pi/extensions/package.json +9 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/README.md +201 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/config.ts +198 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/examples/stt.json +35 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/index.ts +248 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/package.json +6 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/providers.ts +214 -0
- package/.versions/0.0.5/.pi/extensions/pi-voice-stt/recorder.ts +158 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/README.md +798 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/access-approval.ts +135 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/artifacts.js +92 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/backend-policy.js +153 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/delegate.ts +386 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/drift-watchdog.js +165 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/evidence-rules.js +96 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/footer.ts +29 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/helpers.ts +214 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/index.ts +8045 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-control.ts +9 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-lifecycle.ts +13 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-publisher.ts +59 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-recovery.ts +3 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-runtime.ts +3 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/monitor-session-bridge.ts +11 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/package.json +7 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/research-retention.js +34 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/research-watchdog.ts +40 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/return-contract.js +215 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/run-budget.js +155 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/safety-routing.ts +22 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/scope-gate.js +103 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/spawn.ts +246 -0
- package/.versions/0.0.5/.pi/harnesses/agent-hub/version.ts +18 -0
- package/.versions/0.0.5/.pi/harnesses/ask-user-remote/README.md +19 -0
- package/.versions/0.0.5/.pi/harnesses/ask-user-remote/index.ts +321 -0
- package/.versions/0.0.5/.pi/harnesses/ask-user-remote/race-core.js +106 -0
- package/.versions/0.0.5/.pi/harnesses/coms/README.md +92 -0
- package/.versions/0.0.5/.pi/harnesses/coms/index.ts +1745 -0
- package/.versions/0.0.5/.pi/harnesses/coms/package.json +7 -0
- package/.versions/0.0.5/.pi/harnesses/coms/version.ts +18 -0
- package/.versions/0.0.5/.pi/harnesses/damage-control-continue/README.md +117 -0
- package/.versions/0.0.5/.pi/harnesses/damage-control-continue/index.ts +536 -0
- package/.versions/0.0.5/.pi/harnesses/damage-control-continue/package.json +7 -0
- package/.versions/0.0.5/.pi/harnesses/damage-control-continue/version.ts +18 -0
- package/.versions/0.0.5/.pi/harnesses/lib/damage-control-shared.ts +197 -0
- package/.versions/0.0.5/.pi/harnesses/lib/herdr-client.ts +458 -0
- package/.versions/0.0.5/.pi/harnesses/lib/herdr-presence.ts +288 -0
- package/.versions/0.0.5/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
- package/.versions/0.0.5/.pi/harnesses/lib/hermes-monitor-model.ts +9 -0
- package/.versions/0.0.5/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
- package/.versions/0.0.5/.pi/harnesses/lib/hermes-monitor-socket.ts +118 -0
- package/.versions/0.0.5/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
- package/.versions/0.0.5/.pi/harnesses/package-lock.json +35 -0
- package/.versions/0.0.5/.pi/harnesses/package.json +9 -0
- package/.versions/0.0.5/.pi/prompts/build.md +24 -0
- package/.versions/0.0.5/.pi/prompts/code-simplify.md +22 -0
- package/.versions/0.0.5/.pi/prompts/plan.md +16 -0
- package/.versions/0.0.5/.pi/prompts/review.md +16 -0
- package/.versions/0.0.5/.pi/prompts/set-hermes-telegram.md +15 -0
- package/.versions/0.0.5/.pi/prompts/ship.md +17 -0
- package/.versions/0.0.5/.pi/prompts/spec.md +15 -0
- package/.versions/0.0.5/.pi/prompts/test.md +19 -0
- package/.versions/0.0.5/.pi/skills/bowser/SKILL.md +145 -0
- package/.versions/0.0.5/.version +1 -0
- package/.versions/0.0.5/agents/architect.md +23 -0
- package/.versions/0.0.5/agents/bowser.md +26 -0
- package/.versions/0.0.5/agents/builder.md +53 -0
- package/.versions/0.0.5/agents/code-reviewer.md +205 -0
- package/.versions/0.0.5/agents/deep-researcher.md +31 -0
- package/.versions/0.0.5/agents/documenter.md +18 -0
- package/.versions/0.0.5/agents/orchestrator.md +54 -0
- package/.versions/0.0.5/agents/plan-reviewer.md +60 -0
- package/.versions/0.0.5/agents/planner.md +69 -0
- package/.versions/0.0.5/agents/releaser.md +24 -0
- package/.versions/0.0.5/agents/researcher.md +28 -0
- package/.versions/0.0.5/agents/security-auditor.md +166 -0
- package/.versions/0.0.5/agents/test-engineer.md +151 -0
- package/.versions/0.0.5/agents/web-debugger.md +42 -0
- package/.versions/0.0.5/agents/web-performance-auditor.md +192 -0
- package/.versions/0.0.5/codex/CONDUCTOR.md +148 -0
- package/.versions/0.0.5/docs/ARCHITECTURE.md +210 -0
- package/.versions/0.0.5/docs/agent-fleet-setup.md +366 -0
- package/.versions/0.0.5/docs/claude-code-coms-bridge.md +103 -0
- package/.versions/0.0.5/docs/codex-remote-conductor.md +170 -0
- package/.versions/0.0.5/docs/coms-hermes-bridge.md +179 -0
- package/.versions/0.0.5/docs/getting-started.md +183 -0
- package/.versions/0.0.5/docs/npm-install.md +337 -0
- package/.versions/0.0.5/docs/opencode-setup.md +249 -0
- package/.versions/0.0.5/docs/pi-extensions.md +293 -0
- package/.versions/0.0.5/docs/pi-setup.md +472 -0
- package/.versions/0.0.5/docs/skill-anatomy.md +150 -0
- package/.versions/0.0.5/hermes/README.md +231 -0
- package/.versions/0.0.5/hermes/skills/hub-conductor/SKILL.md +84 -0
- package/.versions/0.0.5/hermes/skills/hub-liaison/SKILL.md +84 -0
- package/.versions/0.0.5/hooks/SIMPLIFY-IGNORE.md +90 -0
- package/.versions/0.0.5/hooks/coms-stop-hook.mjs +73 -0
- package/.versions/0.0.5/hooks/hooks.json +14 -0
- package/.versions/0.0.5/hooks/session-start.sh +74 -0
- package/.versions/0.0.5/hooks/simplify-ignore.sh +302 -0
- package/.versions/0.0.5/justfile +245 -0
- package/.versions/0.0.5/references/accessibility-checklist.md +160 -0
- package/.versions/0.0.5/references/definition-of-done.md +67 -0
- package/.versions/0.0.5/references/fleet-coordination-patterns.md +151 -0
- package/.versions/0.0.5/references/observability-checklist.md +91 -0
- package/.versions/0.0.5/references/orchestration-patterns.md +370 -0
- package/.versions/0.0.5/references/performance-checklist.md +153 -0
- package/.versions/0.0.5/references/prompting-patterns.md +380 -0
- package/.versions/0.0.5/references/security-checklist.md +179 -0
- package/.versions/0.0.5/references/testing-patterns.md +236 -0
- package/.versions/0.0.5/scripts/codex-conductor.ts +41 -0
- package/.versions/0.0.5/scripts/codex-remote-control.ts +167 -0
- package/.versions/0.0.5/scripts/coms-claude-bridge.ts +286 -0
- package/.versions/0.0.5/scripts/coms-cli.ts +484 -0
- package/.versions/0.0.5/scripts/coms-hermes-bridge.ts +413 -0
- package/.versions/0.0.5/scripts/fleet.ts +141 -0
- package/.versions/0.0.5/scripts/hermes-monitor-capability-runner.ts +25 -0
- package/.versions/0.0.5/scripts/hermes-monitor-scenario.ts +7 -0
- package/.versions/0.0.5/scripts/lib/claude-bridge-core.ts +100 -0
- package/.versions/0.0.5/scripts/lib/codex-conductor.ts +88 -0
- package/.versions/0.0.5/scripts/lib/codex-remote-control.ts +480 -0
- package/.versions/0.0.5/scripts/lib/coms-envelope.ts +539 -0
- package/.versions/0.0.5/scripts/lib/fake-herdr-server.ts +88 -0
- package/.versions/0.0.5/scripts/lib/fleet-command.ts +109 -0
- package/.versions/0.0.5/scripts/lib/herdr-layout.ts +263 -0
- package/.versions/0.0.5/scripts/lib/hermes-bridge-core.ts +241 -0
- package/.versions/0.0.5/scripts/lib/hermes-monitor-herdr.ts +2 -0
- package/.versions/0.0.5/scripts/lib/hermes-monitor-model.ts +3 -0
- package/.versions/0.0.5/scripts/lib/hermes-monitor-registry.ts +2 -0
- package/.versions/0.0.5/scripts/lib/hermes-monitor-socket.ts +2 -0
- package/.versions/0.0.5/scripts/lib/hermes-monitor-store.ts +2 -0
- package/.versions/0.0.5/scripts/lib/persona-banner.ts +62 -0
- package/.versions/0.0.5/scripts/lib/spawn-stagger.ts +101 -0
- package/.versions/0.0.5/scripts/lib/team-project.ts +191 -0
- package/.versions/0.0.5/scripts/lib/team-snapshot.ts +147 -0
- package/.versions/0.0.5/scripts/peer-banner.ts +40 -0
- package/.versions/0.0.5/scripts/team-snapshot.ts +237 -0
- package/.versions/0.0.5/scripts/team-up.ts +351 -0
- package/.versions/0.0.5/skills/_internal/grilling.md +11 -0
- package/.versions/0.0.5/skills/browser-testing-with-devtools/SKILL.md +352 -0
- package/.versions/0.0.5/skills/code-review-and-quality/SKILL.md +381 -0
- package/.versions/0.0.5/skills/compound-learning/SKILL.md +137 -0
- package/.versions/0.0.5/skills/context-engineering/SKILL.md +291 -0
- package/.versions/0.0.5/skills/deprecation-and-migration/SKILL.md +206 -0
- package/.versions/0.0.5/skills/designing-agents/SKILL.md +394 -0
- package/.versions/0.0.5/skills/designing-agents/pi-harness-authoring.md +222 -0
- package/.versions/0.0.5/skills/frontend-ui-engineering/SKILL.md +328 -0
- package/.versions/0.0.5/skills/git-workflow-and-versioning/SKILL.md +316 -0
- package/.versions/0.0.5/skills/guided-workspace-setup/SKILL.md +542 -0
- package/.versions/0.0.5/skills/guided-workspace-setup/companion-manifest.json +35 -0
- package/.versions/0.0.5/skills/idea-refine/SKILL.md +182 -0
- package/.versions/0.0.5/skills/idea-refine/examples.md +238 -0
- package/.versions/0.0.5/skills/idea-refine/frameworks.md +99 -0
- package/.versions/0.0.5/skills/idea-refine/refinement-criteria.md +113 -0
- package/.versions/0.0.5/skills/idea-refine/scripts/idea-refine.sh +15 -0
- package/.versions/0.0.5/skills/incremental-implementation/SKILL.md +287 -0
- package/.versions/0.0.5/skills/interview-me/SKILL.md +226 -0
- package/.versions/0.0.5/skills/orchestration-verification/SKILL.md +181 -0
- package/.versions/0.0.5/skills/peer-coms/SKILL.md +90 -0
- package/.versions/0.0.5/skills/performance-optimization/SKILL.md +350 -0
- package/.versions/0.0.5/skills/planning-and-task-breakdown/SKILL.md +236 -0
- package/.versions/0.0.5/skills/security-and-hardening/SKILL.md +461 -0
- package/.versions/0.0.5/skills/spec-driven-development/SKILL.md +245 -0
- package/.versions/0.0.5/skills/using-agent-skills/SKILL.md +199 -0
- package/.versions/0.0.5/systemd/user/agent-fleet-codex-remote-control.service.in +23 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/LICENSE +21 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/README.md +11 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/api-and-interface-design/SKILL.md +294 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/browser-testing-with-devtools/SKILL.md +317 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/ci-cd-and-automation/SKILL.md +390 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/code-review-and-quality/SKILL.md +396 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/code-simplification/SKILL.md +331 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/context-engineering/SKILL.md +289 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/debugging-and-error-recovery/SKILL.md +300 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/deprecation-and-migration/SKILL.md +247 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/documentation-and-adrs/SKILL.md +278 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/doubt-driven-development/SKILL.md +243 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/frontend-ui-engineering/SKILL.md +328 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/git-workflow-and-versioning/SKILL.md +355 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/idea-refine/SKILL.md +178 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/idea-refine/examples.md +238 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/idea-refine/frameworks.md +99 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/idea-refine/refinement-criteria.md +113 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/idea-refine/scripts/idea-refine.sh +15 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/incremental-implementation/SKILL.md +249 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/interview-me/SKILL.md +225 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/observability-and-instrumentation/SKILL.md +203 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/performance-optimization/SKILL.md +350 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/planning-and-task-breakdown/SKILL.md +234 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/security-and-hardening/SKILL.md +467 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/shipping-and-launch/SKILL.md +310 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/source-driven-development/SKILL.md +194 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/spec-driven-development/SKILL.md +206 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/test-driven-development/SKILL.md +383 -0
- package/.versions/0.0.5/vendor/agent-skills-upstream/skills/using-agent-skills/SKILL.md +191 -0
- package/.versions/0.0.6/.claude/commands/build.md +44 -0
- package/.versions/0.0.6/.claude/commands/code-simplify.md +22 -0
- package/.versions/0.0.6/.claude/commands/design-agent.md +14 -0
- package/.versions/0.0.6/.claude/commands/doctor-agent-fleet.md +17 -0
- package/.versions/0.0.6/.claude/commands/orchestrate.md +112 -0
- package/.versions/0.0.6/.claude/commands/plan.md +16 -0
- package/.versions/0.0.6/.claude/commands/prime.md +22 -0
- package/.versions/0.0.6/.claude/commands/review.md +16 -0
- package/.versions/0.0.6/.claude/commands/set-hermes-telegram.md +15 -0
- package/.versions/0.0.6/.claude/commands/setup-agent-fleet.md +25 -0
- package/.versions/0.0.6/.claude/commands/ship.md +72 -0
- package/.versions/0.0.6/.claude/commands/spec.md +15 -0
- package/.versions/0.0.6/.claude/commands/test.md +19 -0
- package/.versions/0.0.6/.claude/commands/webperf.md +32 -0
- package/.versions/0.0.6/.claude/orchestrate-teams.yaml +24 -0
- package/.versions/0.0.6/.opencode/commands/af-build.md +17 -0
- package/.versions/0.0.6/.opencode/commands/af-code-simplify.md +16 -0
- package/.versions/0.0.6/.opencode/commands/af-compound.md +16 -0
- package/.versions/0.0.6/.opencode/commands/af-design-agent.md +15 -0
- package/.versions/0.0.6/.opencode/commands/af-doctor-agent-fleet.md +17 -0
- package/.versions/0.0.6/.opencode/commands/af-orchestrate.md +112 -0
- package/.versions/0.0.6/.opencode/commands/af-plan.md +16 -0
- package/.versions/0.0.6/.opencode/commands/af-prime.md +22 -0
- package/.versions/0.0.6/.opencode/commands/af-review.md +15 -0
- package/.versions/0.0.6/.opencode/commands/af-set-hermes-telegram.md +15 -0
- package/.versions/0.0.6/.opencode/commands/af-setup-agent-fleet.md +15 -0
- package/.versions/0.0.6/.opencode/commands/af-ship.md +16 -0
- package/.versions/0.0.6/.opencode/commands/af-spec.md +16 -0
- package/.versions/0.0.6/.opencode/commands/af-test.md +21 -0
- package/.versions/0.0.6/.opencode/commands/af-webperf.md +32 -0
- package/.versions/0.0.6/.opencode/orchestrate-teams.yaml +24 -0
- package/.versions/0.0.6/.pi/agents/dispatch-policy.yaml +32 -0
- package/.versions/0.0.6/.pi/agents/model-profiles.yaml +20 -0
- package/.versions/0.0.6/.pi/agents/peers.yaml +146 -0
- package/.versions/0.0.6/.pi/agents/teams.yaml +39 -0
- package/.versions/0.0.6/.pi/damage-control-rules.yaml +297 -0
- package/.versions/0.0.6/.pi/extensions/agent-fleet-update-check/README.md +58 -0
- package/.versions/0.0.6/.pi/extensions/agent-fleet-update-check/index.ts +161 -0
- package/.versions/0.0.6/.pi/extensions/agent-fleet-update-check/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/btw/README.md +118 -0
- package/.versions/0.0.6/.pi/extensions/btw/index.ts +917 -0
- package/.versions/0.0.6/.pi/extensions/btw/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/btw/state.js +179 -0
- package/.versions/0.0.6/.pi/extensions/chrome-devtools-mcp/README.md +58 -0
- package/.versions/0.0.6/.pi/extensions/chrome-devtools-mcp/index.ts +93 -0
- package/.versions/0.0.6/.pi/extensions/chrome-devtools-mcp/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/compact-and-continue/README.md +42 -0
- package/.versions/0.0.6/.pi/extensions/compact-and-continue/index.ts +120 -0
- package/.versions/0.0.6/.pi/extensions/compact-and-continue/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/mcp-bridge/README.md +46 -0
- package/.versions/0.0.6/.pi/extensions/mcp-bridge/index.ts +206 -0
- package/.versions/0.0.6/.pi/extensions/mcp-bridge/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/package-lock.json +1143 -0
- package/.versions/0.0.6/.pi/extensions/package.json +9 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/README.md +201 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/config.ts +198 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/examples/stt.json +35 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/index.ts +248 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/package.json +6 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/providers.ts +214 -0
- package/.versions/0.0.6/.pi/extensions/pi-voice-stt/recorder.ts +158 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/README.md +798 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/access-approval.ts +135 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/artifacts.js +92 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/backend-policy.js +153 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/delegate.ts +386 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/drift-watchdog.js +165 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/evidence-rules.js +96 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/footer.ts +29 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/helpers.ts +214 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/index.ts +8045 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-control.ts +9 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-lifecycle.ts +13 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-publisher.ts +59 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-recovery.ts +3 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-runtime.ts +3 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/monitor-session-bridge.ts +11 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/package.json +7 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/research-retention.js +34 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/research-watchdog.ts +40 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/return-contract.js +215 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/run-budget.js +155 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/safety-routing.ts +22 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/scope-gate.js +103 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/spawn.ts +246 -0
- package/.versions/0.0.6/.pi/harnesses/agent-hub/version.ts +18 -0
- package/.versions/0.0.6/.pi/harnesses/ask-user-remote/README.md +19 -0
- package/.versions/0.0.6/.pi/harnesses/ask-user-remote/index.ts +321 -0
- package/.versions/0.0.6/.pi/harnesses/ask-user-remote/race-core.js +106 -0
- package/.versions/0.0.6/.pi/harnesses/coms/README.md +92 -0
- package/.versions/0.0.6/.pi/harnesses/coms/index.ts +1745 -0
- package/.versions/0.0.6/.pi/harnesses/coms/package.json +7 -0
- package/.versions/0.0.6/.pi/harnesses/coms/version.ts +18 -0
- package/.versions/0.0.6/.pi/harnesses/damage-control-continue/README.md +117 -0
- package/.versions/0.0.6/.pi/harnesses/damage-control-continue/index.ts +536 -0
- package/.versions/0.0.6/.pi/harnesses/damage-control-continue/package.json +7 -0
- package/.versions/0.0.6/.pi/harnesses/damage-control-continue/version.ts +18 -0
- package/.versions/0.0.6/.pi/harnesses/lib/damage-control-shared.ts +197 -0
- package/.versions/0.0.6/.pi/harnesses/lib/herdr-client.ts +458 -0
- package/.versions/0.0.6/.pi/harnesses/lib/herdr-presence.ts +288 -0
- package/.versions/0.0.6/.pi/harnesses/lib/hermes-monitor-herdr.ts +28 -0
- package/.versions/0.0.6/.pi/harnesses/lib/hermes-monitor-model.ts +9 -0
- package/.versions/0.0.6/.pi/harnesses/lib/hermes-monitor-registry.ts +6 -0
- package/.versions/0.0.6/.pi/harnesses/lib/hermes-monitor-socket.ts +118 -0
- package/.versions/0.0.6/.pi/harnesses/lib/hermes-monitor-store.ts +31 -0
- package/.versions/0.0.6/.pi/harnesses/package-lock.json +35 -0
- package/.versions/0.0.6/.pi/harnesses/package.json +9 -0
- package/.versions/0.0.6/.pi/prompts/af-build.md +24 -0
- package/.versions/0.0.6/.pi/prompts/af-code-simplify.md +22 -0
- package/.versions/0.0.6/.pi/prompts/af-doctor-agent-fleet.md +15 -0
- package/.versions/0.0.6/.pi/prompts/af-plan.md +16 -0
- package/.versions/0.0.6/.pi/prompts/af-review.md +16 -0
- package/.versions/0.0.6/.pi/prompts/af-set-hermes-telegram.md +15 -0
- package/.versions/0.0.6/.pi/prompts/af-setup-agent-fleet.md +27 -0
- package/.versions/0.0.6/.pi/prompts/af-ship.md +17 -0
- package/.versions/0.0.6/.pi/prompts/af-spec.md +15 -0
- package/.versions/0.0.6/.pi/prompts/af-test.md +19 -0
- package/.versions/0.0.6/.pi/skills/bowser/SKILL.md +145 -0
- package/.versions/0.0.6/.version +1 -0
- package/.versions/0.0.6/agents/architect.md +23 -0
- package/.versions/0.0.6/agents/bowser.md +26 -0
- package/.versions/0.0.6/agents/builder.md +53 -0
- package/.versions/0.0.6/agents/code-reviewer.md +205 -0
- package/.versions/0.0.6/agents/deep-researcher.md +31 -0
- package/.versions/0.0.6/agents/documenter.md +18 -0
- package/.versions/0.0.6/agents/orchestrator.md +54 -0
- package/.versions/0.0.6/agents/plan-reviewer.md +60 -0
- package/.versions/0.0.6/agents/planner.md +69 -0
- package/.versions/0.0.6/agents/releaser.md +24 -0
- package/.versions/0.0.6/agents/researcher.md +28 -0
- package/.versions/0.0.6/agents/security-auditor.md +166 -0
- package/.versions/0.0.6/agents/test-engineer.md +151 -0
- package/.versions/0.0.6/agents/web-debugger.md +42 -0
- package/.versions/0.0.6/agents/web-performance-auditor.md +192 -0
- package/.versions/0.0.6/codex/CONDUCTOR.md +148 -0
- package/.versions/0.0.6/docs/ARCHITECTURE.md +210 -0
- package/.versions/0.0.6/docs/agent-fleet-setup.md +366 -0
- package/.versions/0.0.6/docs/claude-code-coms-bridge.md +103 -0
- package/.versions/0.0.6/docs/codex-remote-conductor.md +170 -0
- package/.versions/0.0.6/docs/coms-hermes-bridge.md +179 -0
- package/.versions/0.0.6/docs/getting-started.md +183 -0
- package/.versions/0.0.6/docs/npm-install.md +337 -0
- package/.versions/0.0.6/docs/opencode-setup.md +249 -0
- package/.versions/0.0.6/docs/pi-extensions.md +293 -0
- package/.versions/0.0.6/docs/pi-setup.md +476 -0
- package/.versions/0.0.6/docs/skill-anatomy.md +150 -0
- package/.versions/0.0.6/hermes/README.md +231 -0
- package/.versions/0.0.6/hermes/desktop-plugins/agent-fleet-monitor/plugin.js +19 -0
- package/.versions/0.0.6/hermes/desktop-plugins/agent-fleet-monitor/state.js +10 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-cap.test.py +15 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-discovery.test.py +19 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-envelope.test.py +13 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-forged-owner.test.py +11 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-lease-list.test.py +9 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-multihub.test.py +17 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter-output.test.py +34 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter.py +151 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/adapter.test.py +39 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/manifest.json +11 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/plugin-api-validation.test.py +12 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/plugin_api.py +50 -0
- package/.versions/0.0.6/hermes/plugins/agent-fleet-monitor/dashboard/review-live-wiring.red.test.py +22 -0
- package/.versions/0.0.6/hermes/skills/hub-conductor/SKILL.md +84 -0
- package/.versions/0.0.6/hermes/skills/hub-liaison/SKILL.md +84 -0
- package/.versions/0.0.6/hooks/SIMPLIFY-IGNORE.md +90 -0
- package/.versions/0.0.6/hooks/coms-stop-hook.mjs +73 -0
- package/.versions/0.0.6/hooks/hooks.json +14 -0
- package/.versions/0.0.6/hooks/session-start.sh +74 -0
- package/.versions/0.0.6/hooks/simplify-ignore.sh +302 -0
- package/.versions/0.0.6/justfile +245 -0
- package/.versions/0.0.6/references/accessibility-checklist.md +160 -0
- package/.versions/0.0.6/references/definition-of-done.md +67 -0
- package/.versions/0.0.6/references/fleet-coordination-patterns.md +151 -0
- package/.versions/0.0.6/references/observability-checklist.md +91 -0
- package/.versions/0.0.6/references/orchestration-patterns.md +370 -0
- package/.versions/0.0.6/references/performance-checklist.md +153 -0
- package/.versions/0.0.6/references/prompting-patterns.md +380 -0
- package/.versions/0.0.6/references/security-checklist.md +179 -0
- package/.versions/0.0.6/references/testing-patterns.md +236 -0
- package/.versions/0.0.6/scripts/codex-conductor.ts +41 -0
- package/.versions/0.0.6/scripts/codex-remote-control.ts +167 -0
- package/.versions/0.0.6/scripts/coms-claude-bridge.ts +286 -0
- package/.versions/0.0.6/scripts/coms-cli.ts +484 -0
- package/.versions/0.0.6/scripts/coms-hermes-bridge.ts +413 -0
- package/.versions/0.0.6/scripts/fleet.ts +141 -0
- package/.versions/0.0.6/scripts/hermes-monitor-capability-runner.ts +25 -0
- package/.versions/0.0.6/scripts/hermes-monitor-scenario.ts +7 -0
- package/.versions/0.0.6/scripts/lib/claude-bridge-core.ts +100 -0
- package/.versions/0.0.6/scripts/lib/codex-conductor.ts +88 -0
- package/.versions/0.0.6/scripts/lib/codex-remote-control.ts +480 -0
- package/.versions/0.0.6/scripts/lib/coms-envelope.ts +539 -0
- package/.versions/0.0.6/scripts/lib/fake-herdr-server.ts +88 -0
- package/.versions/0.0.6/scripts/lib/fleet-command.ts +109 -0
- package/.versions/0.0.6/scripts/lib/herdr-layout.ts +263 -0
- package/.versions/0.0.6/scripts/lib/hermes-bridge-core.ts +241 -0
- package/.versions/0.0.6/scripts/lib/hermes-monitor-herdr.ts +2 -0
- package/.versions/0.0.6/scripts/lib/hermes-monitor-model.ts +3 -0
- package/.versions/0.0.6/scripts/lib/hermes-monitor-registry.ts +2 -0
- package/.versions/0.0.6/scripts/lib/hermes-monitor-socket.ts +2 -0
- package/.versions/0.0.6/scripts/lib/hermes-monitor-store.ts +2 -0
- package/.versions/0.0.6/scripts/lib/persona-banner.ts +62 -0
- package/.versions/0.0.6/scripts/lib/spawn-stagger.ts +101 -0
- package/.versions/0.0.6/scripts/lib/team-project.ts +191 -0
- package/.versions/0.0.6/scripts/lib/team-snapshot.ts +147 -0
- package/.versions/0.0.6/scripts/peer-banner.ts +40 -0
- package/.versions/0.0.6/scripts/team-snapshot.ts +237 -0
- package/.versions/0.0.6/scripts/team-up.ts +351 -0
- package/.versions/0.0.6/skills/_internal/grilling.md +11 -0
- package/.versions/0.0.6/skills/browser-testing-with-devtools/SKILL.md +352 -0
- package/.versions/0.0.6/skills/code-review-and-quality/SKILL.md +381 -0
- package/.versions/0.0.6/skills/compound-learning/SKILL.md +137 -0
- package/.versions/0.0.6/skills/context-engineering/SKILL.md +291 -0
- package/.versions/0.0.6/skills/deprecation-and-migration/SKILL.md +206 -0
- package/.versions/0.0.6/skills/designing-agents/SKILL.md +394 -0
- package/.versions/0.0.6/skills/designing-agents/pi-harness-authoring.md +222 -0
- package/.versions/0.0.6/skills/frontend-ui-engineering/SKILL.md +328 -0
- package/.versions/0.0.6/skills/git-workflow-and-versioning/SKILL.md +316 -0
- package/.versions/0.0.6/skills/guided-workspace-setup/SKILL.md +544 -0
- package/.versions/0.0.6/skills/guided-workspace-setup/companion-manifest.json +35 -0
- package/.versions/0.0.6/skills/idea-refine/SKILL.md +182 -0
- package/.versions/0.0.6/skills/idea-refine/examples.md +238 -0
- package/.versions/0.0.6/skills/idea-refine/frameworks.md +99 -0
- package/.versions/0.0.6/skills/idea-refine/refinement-criteria.md +113 -0
- package/.versions/0.0.6/skills/idea-refine/scripts/idea-refine.sh +15 -0
- package/.versions/0.0.6/skills/incremental-implementation/SKILL.md +287 -0
- package/.versions/0.0.6/skills/interview-me/SKILL.md +226 -0
- package/.versions/0.0.6/skills/orchestration-verification/SKILL.md +181 -0
- package/.versions/0.0.6/skills/peer-coms/SKILL.md +90 -0
- package/.versions/0.0.6/skills/performance-optimization/SKILL.md +350 -0
- package/.versions/0.0.6/skills/planning-and-task-breakdown/SKILL.md +236 -0
- package/.versions/0.0.6/skills/security-and-hardening/SKILL.md +461 -0
- package/.versions/0.0.6/skills/spec-driven-development/SKILL.md +245 -0
- package/.versions/0.0.6/skills/using-agent-skills/SKILL.md +199 -0
- package/.versions/0.0.6/systemd/user/agent-fleet-codex-remote-control.service.in +23 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/LICENSE +21 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/README.md +11 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/api-and-interface-design/SKILL.md +294 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/browser-testing-with-devtools/SKILL.md +317 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/ci-cd-and-automation/SKILL.md +390 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/code-review-and-quality/SKILL.md +396 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/code-simplification/SKILL.md +331 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/context-engineering/SKILL.md +289 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/debugging-and-error-recovery/SKILL.md +300 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/deprecation-and-migration/SKILL.md +247 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/documentation-and-adrs/SKILL.md +278 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/doubt-driven-development/SKILL.md +243 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/frontend-ui-engineering/SKILL.md +328 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/git-workflow-and-versioning/SKILL.md +355 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/idea-refine/SKILL.md +178 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/idea-refine/examples.md +238 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/idea-refine/frameworks.md +99 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/idea-refine/refinement-criteria.md +113 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/idea-refine/scripts/idea-refine.sh +15 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/incremental-implementation/SKILL.md +249 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/interview-me/SKILL.md +225 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/observability-and-instrumentation/SKILL.md +203 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/performance-optimization/SKILL.md +350 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/planning-and-task-breakdown/SKILL.md +234 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/security-and-hardening/SKILL.md +467 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/shipping-and-launch/SKILL.md +310 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/source-driven-development/SKILL.md +194 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/spec-driven-development/SKILL.md +206 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/test-driven-development/SKILL.md +383 -0
- package/.versions/0.0.6/vendor/agent-skills-upstream/skills/using-agent-skills/SKILL.md +191 -0
- package/CHANGELOG.md +15 -0
- package/README.md +38 -36
- package/agents/documenter.md +1 -1
- package/agents/releaser.md +1 -1
- package/bin/cli.js +103 -21
- package/bin/lib/bootstrap.js +16 -16
- package/bin/lib/doctor.js +1 -1
- package/bin/lib/set-hermes-telegram.js +323 -0
- package/docs/ARCHITECTURE.md +8 -8
- package/docs/agent-fleet-setup.md +12 -12
- package/docs/claude-code-coms-bridge.md +4 -4
- package/docs/codex-remote-conductor.md +12 -12
- package/docs/coms-hermes-bridge.md +62 -4
- package/docs/getting-started.md +4 -4
- package/docs/npm-install.md +21 -21
- package/docs/opencode-setup.md +1 -0
- package/docs/pi-extensions.md +36 -31
- package/docs/pi-setup.md +66 -53
- package/hermes/README.md +14 -11
- package/justfile +141 -152
- package/package.json +6 -3
- package/references/fleet-coordination-patterns.md +3 -3
- package/scripts/coms-hermes-bridge.ts +18 -8
- package/scripts/fleet.ts +141 -0
- package/scripts/lib/fleet-command.ts +109 -0
- package/scripts/lib/hermes-bridge-core.ts +5 -2
- package/scripts/lib/hermes-monitor-herdr.ts +2 -28
- package/scripts/lib/hermes-monitor-model.ts +3 -9
- package/scripts/lib/hermes-monitor-registry.ts +2 -6
- package/scripts/lib/hermes-monitor-socket.ts +2 -118
- package/scripts/lib/hermes-monitor-store.ts +2 -31
- package/scripts/lib/team-project.ts +10 -3
- package/scripts/team-snapshot.ts +4 -5
- package/scripts/team-up.ts +24 -6
- package/skills/browser-testing-with-devtools/SKILL.md +1 -1
- package/skills/compound-learning/SKILL.md +3 -3
- package/skills/guided-workspace-setup/SKILL.md +27 -18
- package/skills/guided-workspace-setup/companion-manifest.json +3 -1
- package/skills/peer-coms/SKILL.md +1 -1
- package/hermes/plugins/agent-fleet-monitor/dashboard/dist/index.js +0 -10
- /package/.pi/prompts/{build.md → af-build.md} +0 -0
- /package/.pi/prompts/{code-simplify.md → af-code-simplify.md} +0 -0
- /package/.pi/prompts/{plan.md → af-plan.md} +0 -0
- /package/.pi/prompts/{review.md → af-review.md} +0 -0
- /package/.pi/prompts/{ship.md → af-ship.md} +0 -0
- /package/.pi/prompts/{spec.md → af-spec.md} +0 -0
- /package/.pi/prompts/{test.md → af-test.md} +0 -0
- /package/{.pi → .versions/0.0.5/.pi}/prompts/doctor-agent-fleet.md +0 -0
- /package/{.pi → .versions/0.0.5/.pi}/prompts/setup-agent-fleet.md +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/desktop-plugins/agent-fleet-monitor/plugin.js +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/desktop-plugins/agent-fleet-monitor/state.js +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-cap.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-discovery.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-envelope.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-forged-owner.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-lease-list.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-multihub.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter-output.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/adapter.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/manifest.json +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/plugin-api-validation.test.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/plugin_api.py +0 -0
- /package/{hermes → .versions/0.0.5/hermes}/plugins/agent-fleet-monitor/dashboard/review-live-wiring.red.test.py +0 -0
|
@@ -0,0 +1,386 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* delegate — the injected extension that gives an agent-hub specialist a
|
|
3
|
+
* mid-turn `delegate(role, instruction, context?, allow_write?)` tool.
|
|
4
|
+
*
|
|
5
|
+
* The hub adds `-e delegate.ts` (plus `delegate` in the child's `--tools`
|
|
6
|
+
* allowlist — pi's allowlist applies to extension tools too) when a dispatched
|
|
7
|
+
* persona declares `subagents:` in its frontmatter. Everything this extension
|
|
8
|
+
* may spawn comes from AGENT_HUB_DELEGATE_CONFIG (JSON, serialized by the
|
|
9
|
+
* hub): the declared sub-roles and their models, the remaining depth budget,
|
|
10
|
+
* the tree-wide remaining spawn budget, and the event directory. The child
|
|
11
|
+
* process NEVER re-parses persona files — model choice is configuration, not
|
|
12
|
+
* the LLM's whim.
|
|
13
|
+
*
|
|
14
|
+
* Budgets (readable refusals, never silent):
|
|
15
|
+
* - tree-wide spawn budget: at most 4 delegate children per dispatch
|
|
16
|
+
* - depth budget: each child receives `depth − 1`; the hub normally omits
|
|
17
|
+
* delegate tooling from children at remaining depth 0, so a persona with
|
|
18
|
+
* `delegate_depth: 1` (the default and max) can spawn terminal children
|
|
19
|
+
*
|
|
20
|
+
* Write safety: a child is read-only (read,grep,find,ls) unless it is the ONLY
|
|
21
|
+
* live child and the parent passed `allow_write: true` — then it inherits the
|
|
22
|
+
* parent's tools, intersected with the role's declared `tools:` cap when one
|
|
23
|
+
* exists. Concurrent children are always forced read-only (two agents editing
|
|
24
|
+
* the same files is not solvable with guardrails).
|
|
25
|
+
*
|
|
26
|
+
* Observability: every spawn/timeline/usage/exit is appended as JSONL to
|
|
27
|
+
* `<eventDir>/events.jsonl`. The hub watches that file and renders children as
|
|
28
|
+
* nested rows under the parent's grid card (openable via /af-zoom). Kill cascade:
|
|
29
|
+
* children are spawned in THIS process's group (the hub spawns specialists
|
|
30
|
+
* detached), so `/af-agents-kill` on the parent SIGTERMs the whole tree; a
|
|
31
|
+
* SIGTERM trap forwards to live children as a fallback.
|
|
32
|
+
*/
|
|
33
|
+
|
|
34
|
+
import type { ExtensionAPI } from "@mariozechner/pi-coding-agent";
|
|
35
|
+
import { Type } from "@sinclair/typebox";
|
|
36
|
+
import { appendFileSync, mkdirSync, writeFileSync } from "fs";
|
|
37
|
+
import type { ChildProcess } from "child_process";
|
|
38
|
+
import { spawnPiAgent, killPiTree } from "./spawn.ts";
|
|
39
|
+
import {
|
|
40
|
+
delegateBudgetRefusal,
|
|
41
|
+
DELEGATE_TREE_SPAWN_BUDGET,
|
|
42
|
+
normalizeDelegateRuntimeBudgets,
|
|
43
|
+
planDelegateSpawn,
|
|
44
|
+
resolveDelegateTools,
|
|
45
|
+
safeAgentKey,
|
|
46
|
+
safePathWithin,
|
|
47
|
+
} from "./helpers.ts";
|
|
48
|
+
|
|
49
|
+
const DEFAULT_CALL_BUDGET = DELEGATE_TREE_SPAWN_BUDGET;
|
|
50
|
+
const RESULT_CAP = 2000;
|
|
51
|
+
const DIGEST_MAX_LINES = 30;
|
|
52
|
+
// How often buffered text/thinking deltas are flushed into the event file.
|
|
53
|
+
const TIMELINE_FLUSH_MS = 700;
|
|
54
|
+
|
|
55
|
+
// Serialized by the hub into AGENT_HUB_DELEGATE_CONFIG. `tag` is this
|
|
56
|
+
// process's node id in the delegation tree ("root" for the specialist itself);
|
|
57
|
+
// nested delegate.ts instances get their child id as tag, so every event line
|
|
58
|
+
// carries an unambiguous parent chain.
|
|
59
|
+
export interface DelegateConfig {
|
|
60
|
+
persona: string;
|
|
61
|
+
tag: string;
|
|
62
|
+
roles: Record<string, { model: string; tools?: string }>;
|
|
63
|
+
depth: number;
|
|
64
|
+
callBudget: number;
|
|
65
|
+
remainingSpawns?: number;
|
|
66
|
+
parentTools: string;
|
|
67
|
+
personaPrompt: string;
|
|
68
|
+
eventDir: string;
|
|
69
|
+
damageControl?: string;
|
|
70
|
+
delegateExt: string;
|
|
71
|
+
/** Parent-side per-tool deadline inherited by every terminal child. */
|
|
72
|
+
reconSearchTimeoutMs?: number | null;
|
|
73
|
+
/** Whole-run deadline per delegate child (hub mode budget); null/absent = off. */
|
|
74
|
+
turnDeadlineMs?: number | null;
|
|
75
|
+
cwd: string;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// Appended to every child's system prompt so it knows its place in the tree
|
|
79
|
+
// and reports tersely (its full report returns through the tool result, which
|
|
80
|
+
// lands in the parent's context).
|
|
81
|
+
function subagentProtocol(persona: string, role: string, canDelegate: boolean): string {
|
|
82
|
+
return `
|
|
83
|
+
|
|
84
|
+
## You are the "${role}" sub-agent of a ${persona} specialist
|
|
85
|
+
Your parent delegated ONE specific task to you. Do exactly that task — do not
|
|
86
|
+
widen scope, do not start unrelated work. Your full output is written to a result
|
|
87
|
+
file, but your parent receives only a compact digest. End your final message with
|
|
88
|
+
a \`DIGEST:\` section of no more than 30 lines, self-contained, with path:line
|
|
89
|
+
citations where relevant. Put the most important findings and next actions there.${canDelegate ? `
|
|
90
|
+
You may delegate narrow sub-tasks further via your own delegate tool, within
|
|
91
|
+
its declared roles and remaining tree budget.` : `
|
|
92
|
+
You CANNOT delegate further — your remaining depth is 0, so this child has no
|
|
93
|
+
delegate tooling. Do the work yourself with the tools you have.`}`;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
function childResultDigest(output: string, resultPath: string): { text: string; hasDigest: boolean } {
|
|
97
|
+
const lines = String(output || "").split(/\r?\n/);
|
|
98
|
+
const marker = lines.map(l => l.trim()).findIndex(l => /^DIGEST:\s*$/i.test(l));
|
|
99
|
+
if (marker >= 0) {
|
|
100
|
+
const digestLines = lines.slice(marker, marker + DIGEST_MAX_LINES);
|
|
101
|
+
return {
|
|
102
|
+
text: capInline(`${digestLines.join("\n")}\n\nFull output: ${resultPath}\nRead the result file only if this digest is insufficient.`),
|
|
103
|
+
hasDigest: true,
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
const fallback = lines.slice(0, DIGEST_MAX_LINES).join("\n");
|
|
107
|
+
return {
|
|
108
|
+
text: capInline(`${fallback}\n\n[no DIGEST section — full output at ${resultPath}]`),
|
|
109
|
+
hasDigest: false,
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
function capInline(text: string): string {
|
|
114
|
+
return text.length > RESULT_CAP ? text.slice(0, RESULT_CAP) + "\n... [digest truncated]" : text;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export default function (pi: ExtensionAPI) {
|
|
118
|
+
let cfg: DelegateConfig | null = null;
|
|
119
|
+
try {
|
|
120
|
+
cfg = JSON.parse(process.env.AGENT_HUB_DELEGATE_CONFIG || "");
|
|
121
|
+
} catch {
|
|
122
|
+
cfg = null;
|
|
123
|
+
}
|
|
124
|
+
// Misconfigured (or launched outside the hub): register nothing — the
|
|
125
|
+
// parent simply has no delegate tool.
|
|
126
|
+
if (!cfg || !cfg.roles || !cfg.eventDir) return;
|
|
127
|
+
const config = cfg;
|
|
128
|
+
const budgets = normalizeDelegateRuntimeBudgets(config, DEFAULT_CALL_BUDGET);
|
|
129
|
+
config.depth = budgets.depth;
|
|
130
|
+
config.callBudget = budgets.callBudget;
|
|
131
|
+
config.remainingSpawns = budgets.remainingSpawns;
|
|
132
|
+
|
|
133
|
+
let callCount = 0;
|
|
134
|
+
let childSeq = 0;
|
|
135
|
+
// Synchronous reservation counter for the write-safety gate. Incremented at
|
|
136
|
+
// the gate (before any await), so two parallel delegate calls can never both
|
|
137
|
+
// observe "I am the only child" — do NOT replace this with liveChildren.size,
|
|
138
|
+
// which only grows once the child process actually spawns.
|
|
139
|
+
let liveCount = 0;
|
|
140
|
+
const liveChildren = new Set<ChildProcess>();
|
|
141
|
+
|
|
142
|
+
// Fallback cascade: the primary kill path is the process group (the hub
|
|
143
|
+
// signals the specialist's negative PID), but if only this process is
|
|
144
|
+
// terminated, forward the signal to any live children.
|
|
145
|
+
process.on("SIGTERM", () => {
|
|
146
|
+
for (const child of liveChildren) killPiTree(child, "SIGTERM");
|
|
147
|
+
});
|
|
148
|
+
|
|
149
|
+
const emit = (event: Record<string, unknown>) => {
|
|
150
|
+
try {
|
|
151
|
+
appendFileSync(safePathWithin(config.eventDir, "events.jsonl"), JSON.stringify(event) + "\n", "utf-8");
|
|
152
|
+
} catch {}
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
const roleNames = Object.keys(config.roles).filter((name) => {
|
|
156
|
+
try { safeAgentKey(name); return true; } catch { return false; }
|
|
157
|
+
});
|
|
158
|
+
if (roleNames.length === 0) return;
|
|
159
|
+
|
|
160
|
+
pi.registerTool({
|
|
161
|
+
name: "delegate",
|
|
162
|
+
label: "Delegate",
|
|
163
|
+
description:
|
|
164
|
+
`Spawn one of your declared sub-agents on its pre-configured model and wait for its report. ` +
|
|
165
|
+
`Declared roles: ${roleNames.join(", ")}. Use it to fan out scoped sub-tasks (reviews, scans, ` +
|
|
166
|
+
`doc checks) instead of doing everything yourself; at most ${DELEGATE_TREE_SPAWN_BUDGET} ` +
|
|
167
|
+
`children may be spawned per dispatch, and parallel children are forced read-only. The child ` +
|
|
168
|
+
`does not share your context — pass everything it needs in \`instruction\`/\`context\`.`,
|
|
169
|
+
parameters: Type.Object({
|
|
170
|
+
role: Type.String({ description: `Declared sub-role to spawn. One of: ${roleNames.join(", ")}` }),
|
|
171
|
+
instruction: Type.String({ description: "The specific, self-contained task for the sub-agent." }),
|
|
172
|
+
context: Type.Optional(Type.String({
|
|
173
|
+
description: "Optional background brief pasted above the instruction (the child shares none of " +
|
|
174
|
+
"your context). The keyword 'fork' (full context fork) is accepted but treated as a summary " +
|
|
175
|
+
"brief in v1 — write the brief out.",
|
|
176
|
+
})),
|
|
177
|
+
allow_write: Type.Optional(Type.Boolean({
|
|
178
|
+
description: "Let the child inherit your tools (including write access). Honored only while it " +
|
|
179
|
+
"is your ONLY live child; concurrent children are always read-only. A role-level tools cap " +
|
|
180
|
+
"still wins and refuses delegation if it leaves no tools.",
|
|
181
|
+
})),
|
|
182
|
+
}),
|
|
183
|
+
|
|
184
|
+
async execute(_toolCallId, params, _signal, onUpdate) {
|
|
185
|
+
const { role, instruction, context, allow_write } = params as {
|
|
186
|
+
role: string; instruction: string; context?: string; allow_write?: boolean;
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
// Readable refusals — budget exhaustion is an answer, not a mystery.
|
|
190
|
+
const budgetRefusal = delegateBudgetRefusal({
|
|
191
|
+
depth: config.depth,
|
|
192
|
+
callBudget: config.callBudget,
|
|
193
|
+
remainingSpawns: config.remainingSpawns ?? 0,
|
|
194
|
+
callCount,
|
|
195
|
+
});
|
|
196
|
+
if (budgetRefusal) {
|
|
197
|
+
return { content: [{ type: "text" as const, text: budgetRefusal }] };
|
|
198
|
+
}
|
|
199
|
+
const roleKey = roleNames.find(r => r.toLowerCase() === role.toLowerCase());
|
|
200
|
+
if (!roleKey) {
|
|
201
|
+
return {
|
|
202
|
+
content: [{ type: "text" as const, text:
|
|
203
|
+
`Delegation refused: "${role}" is not a declared sub-role. Declared roles: ` +
|
|
204
|
+
`${roleNames.join(", ")}.` }],
|
|
205
|
+
};
|
|
206
|
+
}
|
|
207
|
+
const roleDef = config.roles[roleKey];
|
|
208
|
+
|
|
209
|
+
// Write safety: read-only unless this is the only live child AND the
|
|
210
|
+
// parent explicitly granted write. The role's tools cap always wins.
|
|
211
|
+
const tools = resolveDelegateTools({
|
|
212
|
+
parentTools: config.parentTools,
|
|
213
|
+
roleTools: roleDef.tools,
|
|
214
|
+
allowWrite: allow_write === true,
|
|
215
|
+
concurrent: liveCount > 0,
|
|
216
|
+
});
|
|
217
|
+
if (tools.refused) {
|
|
218
|
+
return {
|
|
219
|
+
content: [{ type: "text" as const, text:
|
|
220
|
+
`Delegation refused: role "${roleKey}" declares tools "${roleDef.tools}" but none are ` +
|
|
221
|
+
`available under the current parent/concurrency tool policy.` }],
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
const effectiveTools = tools.effectiveTools;
|
|
225
|
+
const writeDowngraded = tools.writeDowngraded;
|
|
226
|
+
|
|
227
|
+
callCount++;
|
|
228
|
+
childSeq++;
|
|
229
|
+
const plan = planDelegateSpawn({
|
|
230
|
+
tag: config.tag,
|
|
231
|
+
roleKey,
|
|
232
|
+
childSeq,
|
|
233
|
+
depth: config.depth,
|
|
234
|
+
remainingSpawns: config.remainingSpawns ?? 0,
|
|
235
|
+
effectiveTools,
|
|
236
|
+
damageControl: config.damageControl,
|
|
237
|
+
delegateExt: config.delegateExt,
|
|
238
|
+
});
|
|
239
|
+
config.remainingSpawns = plan.nextRemainingSpawns;
|
|
240
|
+
const childId = plan.childId;
|
|
241
|
+
const childDepth = plan.childDepth;
|
|
242
|
+
const childRemainingSpawns = plan.childRemainingSpawns;
|
|
243
|
+
const childCanDelegate = plan.childCanDelegate;
|
|
244
|
+
const childExtensions = plan.childExtensions;
|
|
245
|
+
const childTools = plan.childTools;
|
|
246
|
+
const childConfig: DelegateConfig | null = plan.includeDelegateConfig ? {
|
|
247
|
+
...config,
|
|
248
|
+
tag: childId,
|
|
249
|
+
depth: childDepth,
|
|
250
|
+
remainingSpawns: childRemainingSpawns,
|
|
251
|
+
parentTools: effectiveTools,
|
|
252
|
+
} : null;
|
|
253
|
+
|
|
254
|
+
const sessionsDir = safePathWithin(config.eventDir, "sessions");
|
|
255
|
+
const resultsDir = safePathWithin(config.eventDir, "results");
|
|
256
|
+
const childSessionFile = safePathWithin(sessionsDir, `${childId}.jsonl`);
|
|
257
|
+
const childResultFile = safePathWithin(resultsDir, `${childId}.md`);
|
|
258
|
+
try { mkdirSync(sessionsDir, { recursive: true }); } catch {}
|
|
259
|
+
try { mkdirSync(resultsDir, { recursive: true }); } catch {}
|
|
260
|
+
|
|
261
|
+
emit({
|
|
262
|
+
t: "spawn", id: childId, parent: config.tag, role: roleKey,
|
|
263
|
+
model: roleDef.model, tools: effectiveTools, remainingSpawns: childRemainingSpawns, ts: Date.now(),
|
|
264
|
+
});
|
|
265
|
+
onUpdate?.({
|
|
266
|
+
content: [{ type: "text", text: `Delegating to ${roleKey} (${roleDef.model})...` }],
|
|
267
|
+
details: { id: childId, role: roleKey, model: roleDef.model, status: "running" },
|
|
268
|
+
});
|
|
269
|
+
|
|
270
|
+
// Buffered timeline streaming: coalesce text/thinking deltas and flush
|
|
271
|
+
// them into the event file on an interval (and on tool/exit), so the
|
|
272
|
+
// hub can render a live /af-zoom timeline without an event per token.
|
|
273
|
+
let pendingKind: "text" | "thinking" | null = null;
|
|
274
|
+
let pendingDelta = "";
|
|
275
|
+
const flushTimeline = () => {
|
|
276
|
+
if (!pendingKind || !pendingDelta) return;
|
|
277
|
+
emit({ t: "timeline", id: childId, kind: pendingKind, delta: pendingDelta });
|
|
278
|
+
pendingDelta = "";
|
|
279
|
+
};
|
|
280
|
+
const queueDelta = (kind: "text" | "thinking", delta: string) => {
|
|
281
|
+
if (pendingKind !== kind) flushTimeline();
|
|
282
|
+
pendingKind = kind;
|
|
283
|
+
pendingDelta += delta;
|
|
284
|
+
};
|
|
285
|
+
const flushTimer = setInterval(flushTimeline, TIMELINE_FLUSH_MS);
|
|
286
|
+
|
|
287
|
+
const startTime = Date.now();
|
|
288
|
+
let childProc: ChildProcess | null = null;
|
|
289
|
+
const mode = context?.trim().toLowerCase();
|
|
290
|
+
const brief = context && mode !== "summary" && mode !== "fork" ? context : undefined;
|
|
291
|
+
const prompt = brief
|
|
292
|
+
? `## Context from your parent\n${brief}\n\n## Your task\n${instruction}`
|
|
293
|
+
: instruction;
|
|
294
|
+
|
|
295
|
+
let res;
|
|
296
|
+
liveCount++;
|
|
297
|
+
try {
|
|
298
|
+
res = await spawnPiAgent({
|
|
299
|
+
model: roleDef.model,
|
|
300
|
+
tools: childTools,
|
|
301
|
+
thinking: "off",
|
|
302
|
+
appendSystemPrompt: subagentProtocol(config.persona, roleKey, childCanDelegate),
|
|
303
|
+
sessionFile: childSessionFile,
|
|
304
|
+
prompt,
|
|
305
|
+
extensions: childExtensions,
|
|
306
|
+
env: childConfig ? { AGENT_HUB_DELEGATE_CONFIG: JSON.stringify(childConfig) } : undefined,
|
|
307
|
+
cwd: config.cwd,
|
|
308
|
+
// Each nested child owns its group. The SIGTERM trap above forwards
|
|
309
|
+
// parent cancellation so detached children cannot become orphans.
|
|
310
|
+
detached: true,
|
|
311
|
+
signal: _signal,
|
|
312
|
+
// `null` is the explicit `off` override; preserve it rather than
|
|
313
|
+
// silently restoring the default for terminal children.
|
|
314
|
+
toolWatchdog: { timeoutMs: config.reconSearchTimeoutMs === undefined ? 120_000 : config.reconSearchTimeoutMs },
|
|
315
|
+
// Whole-run bound from the hub's mode budget: a hung delegate (the
|
|
316
|
+
// 92-minute conventions scout) must not hold its parent hostage.
|
|
317
|
+
turnDeadlineMs: config.turnDeadlineMs === undefined ? null : config.turnDeadlineMs,
|
|
318
|
+
}, {
|
|
319
|
+
onProcess: (p) => { childProc = p; liveChildren.add(p); },
|
|
320
|
+
onTextDelta: (delta) => queueDelta("text", delta),
|
|
321
|
+
onThinkingDelta: (delta) => queueDelta("thinking", delta),
|
|
322
|
+
onToolStart: (toolName, argStr) => {
|
|
323
|
+
flushTimeline();
|
|
324
|
+
emit({ t: "tool", id: childId, name: toolName, args: argStr.slice(0, 500) });
|
|
325
|
+
},
|
|
326
|
+
onUsage: (usage, source) => {
|
|
327
|
+
if (source === "message_end") {
|
|
328
|
+
emit({ t: "usage", id: childId, input: usage.input || 0, output: usage.output || 0 });
|
|
329
|
+
}
|
|
330
|
+
},
|
|
331
|
+
});
|
|
332
|
+
} finally {
|
|
333
|
+
liveCount--;
|
|
334
|
+
clearInterval(flushTimer);
|
|
335
|
+
if (childProc) liveChildren.delete(childProc);
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
flushTimeline();
|
|
339
|
+
const elapsed = Date.now() - startTime;
|
|
340
|
+
const code = res.spawnError ? 1 : (res.termination ? (res.termination.reason === "cancelled" ? 130 : res.termination.reason === "drift_stop" ? 125 : 124) : (res.exitCode ?? 1));
|
|
341
|
+
emit({ t: "exit", id: childId, code, elapsed, termination: res.termination, ts: Date.now() });
|
|
342
|
+
|
|
343
|
+
if (res.spawnError) {
|
|
344
|
+
const spawnFailure = `Delegate ${childId} failed to spawn: ${res.spawnError}`;
|
|
345
|
+
try { writeFileSync(childResultFile, spawnFailure + "\n", "utf-8"); } catch {}
|
|
346
|
+
return {
|
|
347
|
+
content: [{ type: "text" as const, text: `${spawnFailure}\n\nFull output: ${childResultFile}` }],
|
|
348
|
+
details: { id: childId, role: roleKey, status: "error", resultPath: childResultFile },
|
|
349
|
+
};
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
let output = res.output;
|
|
353
|
+
if (res.termination) {
|
|
354
|
+
const reason = res.termination.reason;
|
|
355
|
+
const tool = res.termination.tool;
|
|
356
|
+
const explanation = reason === "tool_timeout"
|
|
357
|
+
? `exceeded its per-tool watchdog on ${tool?.toolName || "tool"} (${tool?.toolCallId || "unknown"})`
|
|
358
|
+
: reason === "turn_timeout"
|
|
359
|
+
? "exceeded the per-run deadline (mode budget / agent-turn-timeout-s)"
|
|
360
|
+
: reason === "drift_stop"
|
|
361
|
+
? "was stopped by the drift watchdog"
|
|
362
|
+
: "was cancelled by its caller";
|
|
363
|
+
output = `${reason}: delegate ${childId} ${explanation}; terminationConfirmed=${res.termination.confirmed}.`;
|
|
364
|
+
} else if (code !== 0) {
|
|
365
|
+
const errTail = res.stderr.trim().slice(-1000);
|
|
366
|
+
output = output
|
|
367
|
+
? `${output}\n\n[stderr]\n${errTail}`
|
|
368
|
+
: `Delegate ${childId} exited with code ${code} and produced no output.\n\n[stderr]\n${errTail}`;
|
|
369
|
+
}
|
|
370
|
+
try { writeFileSync(childResultFile, output, "utf-8"); } catch {}
|
|
371
|
+
const digest = childResultDigest(output, childResultFile);
|
|
372
|
+
|
|
373
|
+
const notes: string[] = [];
|
|
374
|
+
if (writeDowngraded) notes.push("allow_write ignored — other children were live, so it ran read-only");
|
|
375
|
+
if (mode === "fork") notes.push("context: fork is not supported in v1 — the child started fresh from your instruction");
|
|
376
|
+
const noteBlock = notes.length > 0 ? `\n[note: ${notes.join("; ")}]` : "";
|
|
377
|
+
|
|
378
|
+
return {
|
|
379
|
+
content: [{ type: "text" as const, text:
|
|
380
|
+
`[delegate ${childId} · ${roleDef.model} · ${effectiveTools}] ${res.termination ? res.termination.reason : code === 0 ? "done" : "error"} ` +
|
|
381
|
+
`in ${Math.round(elapsed / 1000)}s${noteBlock}\n\n${digest.text}` }],
|
|
382
|
+
details: { id: childId, role: roleKey, model: roleDef.model, status: res.termination ? res.termination.reason : code === 0 ? "done" : "error", elapsed, resultPath: childResultFile, digestFound: digest.hasDigest, termination: res.termination },
|
|
383
|
+
};
|
|
384
|
+
},
|
|
385
|
+
});
|
|
386
|
+
}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
// Drift watchdog — the pure policy core behind in-flight specialist
|
|
2
|
+
// observation. Layer 1 is deterministic rules over the child's tool event
|
|
3
|
+
// stream (zero tokens); a firing rule is an ESCALATION SIGNAL, not a verdict —
|
|
4
|
+
// the harness then asks a cheap LLM judge (layer 2) whether the run is still
|
|
5
|
+
// on task, and only a DRIFTING/STUCK verdict terminates it (`drift_stop`).
|
|
6
|
+
// Everything here is data + pure functions so the policy is unit-testable
|
|
7
|
+
// away from the harness.
|
|
8
|
+
|
|
9
|
+
import { checkScope } from "./scope-gate.js";
|
|
10
|
+
|
|
11
|
+
export const WATCHDOG_SETTINGS = ["on", "off", "auto"];
|
|
12
|
+
export const DEFAULT_WATCHDOG_SETTING = "auto";
|
|
13
|
+
|
|
14
|
+
/** "On", " AUTO " → canonical setting, or null when unrecognized. */
|
|
15
|
+
export function normalizeWatchdogSetting(value) {
|
|
16
|
+
const v = String(value ?? "").trim().toLowerCase();
|
|
17
|
+
return WATCHDOG_SETTINGS.includes(v) ? v : null;
|
|
18
|
+
}
|
|
19
|
+
|
|
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).
|
|
24
|
+
*/
|
|
25
|
+
export function resolveWatchdogActive(dispatchParam, agentOverride, hubSetting) {
|
|
26
|
+
if (dispatchParam === true) return true;
|
|
27
|
+
if (dispatchParam === false) return false;
|
|
28
|
+
if (agentOverride === "on") return true;
|
|
29
|
+
if (agentOverride === "off") return false;
|
|
30
|
+
return normalizeWatchdogSetting(hubSetting) !== "off";
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Conservative thresholds: a false positive kills a productive run, so every
|
|
34
|
+
// rule needs sustained evidence before it fires.
|
|
35
|
+
export const DRIFT_DEFAULTS = {
|
|
36
|
+
writeTools: ["write", "edit"],
|
|
37
|
+
maxRepeats: 4,
|
|
38
|
+
maxConsecutiveFailures: 5,
|
|
39
|
+
maxToolCalls: 200,
|
|
40
|
+
trailLimit: 60,
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
const pathFromArgs = (argStr) => {
|
|
44
|
+
try {
|
|
45
|
+
const args = JSON.parse(argStr || "{}");
|
|
46
|
+
for (const key of ["path", "file_path", "filePath", "file", "filename"]) {
|
|
47
|
+
if (typeof args[key] === "string" && args[key].trim()) return args[key].trim();
|
|
48
|
+
}
|
|
49
|
+
} catch {}
|
|
50
|
+
return null;
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Per-run monitor fed from the tool event stream. `onToolStart(tool, argStr)`
|
|
55
|
+
* and `onToolEnd(tool, isError)` return `null` while the run looks healthy, or
|
|
56
|
+
* `{ rule, detail }` when a rule crosses its threshold:
|
|
57
|
+
* scope — a write-capable tool touched a path outside the declared scope
|
|
58
|
+
* loop — the exact same (tool, args) call repeated maxRepeats times
|
|
59
|
+
* failures — maxConsecutiveFailures failed tool calls in a row
|
|
60
|
+
* toolcap — maxToolCalls total tool calls in one run
|
|
61
|
+
* Each rule instance fires once (at the crossing), so the caller escalates —
|
|
62
|
+
* it never gets spammed. `trail(n)` returns the recent tool trail for the judge.
|
|
63
|
+
*/
|
|
64
|
+
export function createDriftMonitor(cfg = {}) {
|
|
65
|
+
const scopeGlobs = (cfg.scopeGlobs || []).filter(Boolean);
|
|
66
|
+
const writeTools = new Set(cfg.writeTools || DRIFT_DEFAULTS.writeTools);
|
|
67
|
+
const maxRepeats = cfg.maxRepeats ?? DRIFT_DEFAULTS.maxRepeats;
|
|
68
|
+
const maxConsecutiveFailures = cfg.maxConsecutiveFailures ?? DRIFT_DEFAULTS.maxConsecutiveFailures;
|
|
69
|
+
const maxToolCalls = cfg.maxToolCalls ?? DRIFT_DEFAULTS.maxToolCalls;
|
|
70
|
+
const trailLimit = cfg.trailLimit ?? DRIFT_DEFAULTS.trailLimit;
|
|
71
|
+
|
|
72
|
+
const callCounts = new Map();
|
|
73
|
+
const trailLines = [];
|
|
74
|
+
let totalCalls = 0;
|
|
75
|
+
let consecutiveFailures = 0;
|
|
76
|
+
|
|
77
|
+
const pushTrail = (line) => {
|
|
78
|
+
trailLines.push(line);
|
|
79
|
+
if (trailLines.length > trailLimit) trailLines.shift();
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
return {
|
|
83
|
+
onToolStart(toolName, argStr) {
|
|
84
|
+
totalCalls++;
|
|
85
|
+
pushTrail(`${toolName} ${String(argStr || "").slice(0, 120)}`.trim());
|
|
86
|
+
|
|
87
|
+
if (scopeGlobs.length > 0 && writeTools.has(toolName)) {
|
|
88
|
+
const path = pathFromArgs(argStr);
|
|
89
|
+
if (path && checkScope([path], scopeGlobs).outOfScope.length > 0) {
|
|
90
|
+
return { rule: "scope", detail: `${toolName} touched ${path} — outside the declared scope (${scopeGlobs.join(", ")})` };
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
const fingerprint = `${toolName}::${argStr || ""}`;
|
|
95
|
+
const count = (callCounts.get(fingerprint) || 0) + 1;
|
|
96
|
+
callCounts.set(fingerprint, count);
|
|
97
|
+
if (count === maxRepeats) {
|
|
98
|
+
return { rule: "loop", detail: `${toolName} called ${count}× with identical arguments — likely stuck in a loop` };
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
if (totalCalls === maxToolCalls) {
|
|
102
|
+
return { rule: "toolcap", detail: `${totalCalls} tool calls in one run — far beyond a focused task` };
|
|
103
|
+
}
|
|
104
|
+
return null;
|
|
105
|
+
},
|
|
106
|
+
|
|
107
|
+
onToolEnd(_toolName, isError) {
|
|
108
|
+
if (isError === true) {
|
|
109
|
+
consecutiveFailures++;
|
|
110
|
+
pushTrail(" ↳ FAILED");
|
|
111
|
+
if (consecutiveFailures % maxConsecutiveFailures === 0) {
|
|
112
|
+
return { rule: "failures", detail: `${consecutiveFailures} consecutive failed tool calls — no forward progress` };
|
|
113
|
+
}
|
|
114
|
+
} else if (isError === false) {
|
|
115
|
+
consecutiveFailures = 0;
|
|
116
|
+
}
|
|
117
|
+
// isError undefined: the stream carries no error flag — rule stays inert.
|
|
118
|
+
return null;
|
|
119
|
+
},
|
|
120
|
+
|
|
121
|
+
trail(n = 40) {
|
|
122
|
+
return trailLines.slice(-n);
|
|
123
|
+
},
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* The one-shot judge prompt: original task + declared scope + recent trail +
|
|
129
|
+
* the rule that fired. The judge answers with a single machine-parseable line.
|
|
130
|
+
*/
|
|
131
|
+
export function buildJudgePrompt({ agent, task, scopeGlobs = [], trail = [], violation }) {
|
|
132
|
+
const scopeBlock = scopeGlobs.length > 0
|
|
133
|
+
? `\n## Declared file scope\n${scopeGlobs.map(s => `- ${s}`).join("\n")}\n`
|
|
134
|
+
: "";
|
|
135
|
+
return `You are a drift watchdog judging whether a running coding agent is still on task.
|
|
136
|
+
Do not solve the task. Judge only whether the agent's recent actions serve it.
|
|
137
|
+
|
|
138
|
+
## Agent
|
|
139
|
+
${agent}
|
|
140
|
+
|
|
141
|
+
## Original task (verbatim)
|
|
142
|
+
${task}
|
|
143
|
+
${scopeBlock}
|
|
144
|
+
## Escalation signal
|
|
145
|
+
Rule "${violation?.rule || "unknown"}" fired: ${violation?.detail || "(no detail)"}
|
|
146
|
+
|
|
147
|
+
## Recent tool trail (oldest first)
|
|
148
|
+
${trail.length > 0 ? trail.join("\n") : "(no tool calls recorded)"}
|
|
149
|
+
|
|
150
|
+
## Your answer
|
|
151
|
+
Reply with EXACTLY one line, nothing else:
|
|
152
|
+
VERDICT: ON_TRACK — <why the actions still serve the task>
|
|
153
|
+
VERDICT: DRIFTING — <what the agent is doing instead of the task>
|
|
154
|
+
VERDICT: STUCK — <the loop or dead end it cannot escape>
|
|
155
|
+
Prefer ON_TRACK unless the trail clearly contradicts the task: false alarms kill
|
|
156
|
+
productive work.`;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/** Parse the judge's reply. Returns { verdict, reason } or null when unparseable. */
|
|
160
|
+
export function parseJudgeVerdict(text) {
|
|
161
|
+
const matches = [...String(text ?? "").matchAll(/VERDICT:\s*(ON_TRACK|DRIFTING|STUCK)\s*(?:[—:-]\s*(.*))?/gi)];
|
|
162
|
+
if (matches.length === 0) return null;
|
|
163
|
+
const last = matches[matches.length - 1];
|
|
164
|
+
return { verdict: last[1].toLowerCase(), reason: (last[2] || "").trim() };
|
|
165
|
+
}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { isAbsolute, relative, resolve } from "node:path";
|
|
2
|
+
|
|
3
|
+
const KNOWN_TAGS = new Set(["test", "runtime-ui", "code-grep", "manual"]);
|
|
4
|
+
|
|
5
|
+
export function validateEvidence(tag, evidence, options = {}) {
|
|
6
|
+
const normalizedTag = String(tag || "").trim().toLowerCase();
|
|
7
|
+
const text = String(evidence || "").trim();
|
|
8
|
+
if (!KNOWN_TAGS.has(normalizedTag)) {
|
|
9
|
+
return { ok: false, reason: `Unknown assertion tag "${tag}"; expected one of test, runtime-ui, code-grep, manual.` };
|
|
10
|
+
}
|
|
11
|
+
if (!text) return { ok: false, reason: "Evidence is required." };
|
|
12
|
+
|
|
13
|
+
if (normalizedTag === "test") return validateTestEvidence(text);
|
|
14
|
+
if (normalizedTag === "runtime-ui") return validateRuntimeUiEvidence(text, options);
|
|
15
|
+
if (normalizedTag === "code-grep") return validateCodeGrepEvidence(text);
|
|
16
|
+
if (normalizedTag === "manual") return validateManualEvidence(text);
|
|
17
|
+
return { ok: false, reason: `Unknown assertion tag "${tag}".` };
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function validateTestEvidence(text) {
|
|
21
|
+
const hasIdentifier = /(?:\b(?:npm|pnpm|yarn|node|npx|vitest|jest|pytest|playwright|cargo|go test|bun)\b|\btest(?:s| name| file)?\b|`[^`]+`)/i.test(text);
|
|
22
|
+
const hasOutcome = /(?:\bpass(?:ed|es)?\b|\bgreen\b|\bok\b|\bexit\s*0\b|\b0\s+fail(?:ed|ures)?\b|\b\d+\/\d+\b|✓|✔)/i.test(text);
|
|
23
|
+
if (!hasIdentifier && !hasOutcome) return { ok: false, reason: "Test evidence must name the command/test identifier and its outcome." };
|
|
24
|
+
if (!hasIdentifier) return { ok: false, reason: "Test evidence must name the command or test identifier." };
|
|
25
|
+
if (!hasOutcome) return { ok: false, reason: "Test evidence must include the test outcome (pass/fail count, exit status, or equivalent)." };
|
|
26
|
+
return { ok: true };
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function validateRuntimeUiEvidence(text, options) {
|
|
30
|
+
const candidates = extractPathCandidates(text).filter((p) => /(?:^|\/)artifacts\/evidence\//.test(normalizePath(p)));
|
|
31
|
+
if (candidates.length === 0) {
|
|
32
|
+
return { ok: false, reason: "Runtime-ui evidence must reference a session artifact path under artifacts/evidence/." };
|
|
33
|
+
}
|
|
34
|
+
const fileExists = typeof options.fileExists === "function" ? options.fileExists : () => false;
|
|
35
|
+
const evidenceRoot = options.evidenceRoot ? resolve(options.evidenceRoot) : null;
|
|
36
|
+
const resolvedCandidates = candidates.map((p) => resolveSessionEvidenceCandidate(p, evidenceRoot)).filter(Boolean);
|
|
37
|
+
if (resolvedCandidates.length === 0) {
|
|
38
|
+
return { ok: false, reason: "Runtime-ui evidence must reference a session artifact evidence path, not a repo-local ./artifacts path." };
|
|
39
|
+
}
|
|
40
|
+
const existing = resolvedCandidates.find((p) => {
|
|
41
|
+
try { return fileExists(p); } catch { return false; }
|
|
42
|
+
});
|
|
43
|
+
if (!existing) {
|
|
44
|
+
return { ok: false, reason: `Runtime-ui evidence artifact does not exist: ${resolvedCandidates[0]}.` };
|
|
45
|
+
}
|
|
46
|
+
return { ok: true };
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
function validateCodeGrepEvidence(text) {
|
|
50
|
+
const hasPattern = /(?:\bpattern\s*:|\bregex\s*:|\bgrep\b|`[^`]+`|\/[^/]+\/)/i.test(text);
|
|
51
|
+
const hasSample = /(?:\bmatch(?:ed|es)?\b|\bno[- ]?match(?:es)?\b|\b0\s+matches\b|\bfound\b|\bnot found\b|[\w./-]+:\d+)/i.test(text);
|
|
52
|
+
if (!hasPattern && !hasSample) return { ok: false, reason: "Code-grep evidence must include the searched pattern and a match/no-match result sample." };
|
|
53
|
+
if (!hasPattern) return { ok: false, reason: "Code-grep evidence must include the searched pattern." };
|
|
54
|
+
if (!hasSample) return { ok: false, reason: "Code-grep evidence must include a match/no-match result sample." };
|
|
55
|
+
return { ok: true };
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function validateManualEvidence(text) {
|
|
59
|
+
const hasConfirmation = /(?:\bask_user\b|\bhuman\s+confirm(?:ed|ation)\b|\buser\s+(?:confirmed|said|approved|chose|answered)\b|\bmanual\s+confirm(?:ed|ation)\b|"[^"]+")/i.test(text);
|
|
60
|
+
if (!hasConfirmation) return { ok: false, reason: "Manual evidence must reference the ask_user answer or explicit user confirmation." };
|
|
61
|
+
return { ok: true };
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function extractPathCandidates(text) {
|
|
65
|
+
const out = [];
|
|
66
|
+
const re = /(?:^|[\s(\[])(["']?)([^"'\s)\]]*(?:\.pi\/agent-sessions\/)?artifacts\/evidence\/[^"'\s)\]]+)\1/g;
|
|
67
|
+
let match;
|
|
68
|
+
while ((match = re.exec(text))) out.push(match[2].replace(/[.,;:]+$/, ""));
|
|
69
|
+
return out;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
function resolveSessionEvidenceCandidate(candidate, evidenceRoot) {
|
|
73
|
+
const raw = String(candidate || "").trim();
|
|
74
|
+
const normalized = normalizePath(raw);
|
|
75
|
+
if (normalized.startsWith("./artifacts/evidence/")) return null;
|
|
76
|
+
if (evidenceRoot && normalized.startsWith("artifacts/evidence/")) {
|
|
77
|
+
return resolve(evidenceRoot, normalized.slice("artifacts/evidence/".length));
|
|
78
|
+
}
|
|
79
|
+
if (evidenceRoot && normalized.startsWith(".pi/agent-sessions/artifacts/evidence/")) {
|
|
80
|
+
return resolve(evidenceRoot, normalized.slice(".pi/agent-sessions/artifacts/evidence/".length));
|
|
81
|
+
}
|
|
82
|
+
if (isAbsolute(raw)) {
|
|
83
|
+
const abs = resolve(raw);
|
|
84
|
+
return !evidenceRoot || isWithin(evidenceRoot, abs) ? abs : null;
|
|
85
|
+
}
|
|
86
|
+
return null;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
function isWithin(root, target) {
|
|
90
|
+
const rel = relative(resolve(root), resolve(target));
|
|
91
|
+
return rel === "" || (!!rel && !rel.startsWith("..") && !isAbsolute(rel));
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
function normalizePath(value) {
|
|
95
|
+
return String(value || "").replace(/\\/g, "/");
|
|
96
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
type FooterTheme = {
|
|
2
|
+
fg(color: string, text: string): string;
|
|
3
|
+
};
|
|
4
|
+
|
|
5
|
+
export function composeHubFooterLeft(
|
|
6
|
+
version: string | null,
|
|
7
|
+
model: string,
|
|
8
|
+
thinkingSuffix: string,
|
|
9
|
+
team: string,
|
|
10
|
+
): string {
|
|
11
|
+
return [version ? `v${version}` : "", `${model}${thinkingSuffix}`, team]
|
|
12
|
+
.filter(Boolean)
|
|
13
|
+
.join(" · ");
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export function renderHubFooterLeft(
|
|
17
|
+
theme: FooterTheme,
|
|
18
|
+
version: string | null,
|
|
19
|
+
model: string,
|
|
20
|
+
thinkingSuffix: string,
|
|
21
|
+
team: string,
|
|
22
|
+
): string {
|
|
23
|
+
const metadata = [version ? `v${version}` : "", `${model}${thinkingSuffix}`]
|
|
24
|
+
.filter(Boolean)
|
|
25
|
+
.join(" · ");
|
|
26
|
+
const dimMetadata = theme.fg("dim", ` ${metadata}`);
|
|
27
|
+
const separator = metadata && team ? theme.fg("muted", " · ") : "";
|
|
28
|
+
return dimMetadata + separator + (team ? theme.fg("accent", team) : "");
|
|
29
|
+
}
|