bosun 0.42.6 → 0.43.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env.example +26 -15
- package/README.md +1 -11
- package/agent/agent-event-bus.mjs +33 -2
- package/agent/agent-hooks.mjs +4 -52
- package/agent/agent-launcher.mjs +6210 -0
- package/agent/agent-pool.mjs +7 -4182
- package/agent/agent-prompt-catalog.mjs +3 -4
- package/agent/agent-sdk.mjs +1 -4
- package/agent/agent-supervisor.mjs +30 -6
- package/agent/auth/_shared.mjs +129 -0
- package/agent/auth/anthropic-api-key.mjs +13 -0
- package/agent/auth/azure-openai.mjs +17 -0
- package/agent/auth/cerebras.mjs +14 -0
- package/agent/auth/chatgpt-codex-subscription.mjs +15 -0
- package/agent/auth/claude-subscription.mjs +15 -0
- package/agent/auth/copilot-oauth.mjs +13 -0
- package/agent/auth/deepinfra.mjs +14 -0
- package/agent/auth/fireworks.mjs +14 -0
- package/agent/auth/gemini-api-key.mjs +14 -0
- package/agent/auth/groq.mjs +14 -0
- package/agent/auth/index.mjs +85 -0
- package/agent/auth/nebius.mjs +14 -0
- package/agent/auth/ollama.mjs +14 -0
- package/agent/auth/openai-api-key.mjs +13 -0
- package/agent/auth/openai-compatible.mjs +15 -0
- package/agent/auth/openrouter.mjs +14 -0
- package/agent/auth/perplexity.mjs +14 -0
- package/agent/auth/sambanova.mjs +14 -0
- package/agent/auth/together.mjs +14 -0
- package/agent/auth/xai.mjs +14 -0
- package/agent/bosun-skills.mjs +177 -68
- package/agent/fleet-coordinator.mjs +153 -37
- package/agent/harness/agent-loop.mjs +26 -0
- package/agent/harness/event-contract.mjs +125 -0
- package/agent/harness/followup-queue.mjs +33 -0
- package/agent/harness/message-normalizer.mjs +43 -0
- package/agent/harness/module-boundaries.md +73 -0
- package/agent/harness/run-contract.mjs +122 -0
- package/agent/harness/runtime-config.mjs +132 -0
- package/agent/harness/session-state.mjs +80 -0
- package/agent/harness/steering-queue.mjs +35 -0
- package/agent/harness/tool-runner.mjs +95 -0
- package/agent/harness/turn-runner.mjs +135 -0
- package/agent/harness-agent-service.mjs +852 -0
- package/agent/harness-executor-config.mjs +384 -0
- package/agent/hook-library.mjs +139 -0
- package/agent/hook-profiles.mjs +46 -108
- package/agent/internal-harness-control-plane.mjs +672 -0
- package/agent/internal-harness-profile.mjs +519 -0
- package/agent/internal-harness-runtime.mjs +1219 -0
- package/agent/lineage-graph.mjs +141 -0
- package/agent/primary-agent.mjs +593 -646
- package/agent/provider-auth-manager.mjs +830 -0
- package/agent/provider-auth-state.mjs +440 -0
- package/agent/provider-capabilities.mjs +116 -0
- package/agent/provider-kernel.mjs +596 -0
- package/agent/provider-message-transform.mjs +583 -0
- package/agent/provider-model-catalog.mjs +163 -0
- package/agent/provider-registry.mjs +657 -0
- package/agent/provider-runtime-discovery.mjs +147 -0
- package/agent/provider-session.mjs +767 -0
- package/agent/providers/_shared.mjs +397 -0
- package/agent/providers/anthropic-messages.mjs +64 -0
- package/agent/providers/azure-openai-responses.mjs +69 -0
- package/agent/providers/cerebras.mjs +66 -0
- package/agent/providers/claude-subscription-shim.mjs +68 -0
- package/agent/providers/copilot-oauth.mjs +66 -0
- package/agent/providers/deepinfra.mjs +66 -0
- package/agent/providers/fireworks.mjs +66 -0
- package/agent/providers/gemini-generate-content.mjs +66 -0
- package/agent/providers/groq.mjs +66 -0
- package/agent/providers/index.mjs +208 -0
- package/agent/providers/nebius.mjs +66 -0
- package/agent/providers/ollama.mjs +66 -0
- package/agent/providers/openai-codex-subscription.mjs +75 -0
- package/agent/providers/openai-compatible.mjs +65 -0
- package/agent/providers/openai-responses.mjs +67 -0
- package/agent/providers/openrouter.mjs +66 -0
- package/agent/providers/perplexity.mjs +66 -0
- package/agent/providers/provider-contract.mjs +138 -0
- package/agent/providers/provider-errors.mjs +63 -0
- package/agent/providers/provider-model-pricing.mjs +246 -0
- package/agent/providers/provider-stream-normalizer.mjs +7 -0
- package/agent/providers/provider-usage-normalizer.mjs +48 -0
- package/agent/providers/sambanova.mjs +66 -0
- package/agent/providers/together.mjs +66 -0
- package/agent/providers/xai.mjs +66 -0
- package/agent/query-engine.mjs +260 -0
- package/agent/retry-queue.mjs +1 -0
- package/agent/session-contract.mjs +127 -0
- package/agent/session-manager.mjs +1859 -0
- package/agent/session-replay.mjs +617 -0
- package/agent/session-snapshot-store.mjs +379 -0
- package/agent/skills/agent-coordination.md +6 -0
- package/agent/skills/background-task-execution.md +6 -0
- package/agent/skills/bosun-agent-api.md +6 -0
- package/agent/skills/code-quality-anti-patterns.md +7 -0
- package/agent/skills/commit-conventions.md +6 -0
- package/agent/skills/custom-tool-creation.md +6 -0
- package/agent/skills/error-recovery.md +6 -0
- package/agent/skills/pr-workflow.md +6 -0
- package/agent/skills/tdd-pattern.md +6 -0
- package/agent/subagent-contract.mjs +104 -0
- package/agent/subagent-control.mjs +633 -0
- package/agent/subagent-pool.mjs +260 -0
- package/agent/thread-contract.mjs +88 -0
- package/agent/thread-registry.mjs +552 -0
- package/agent/tool-approval-manager.mjs +259 -0
- package/agent/tool-builtin-catalog.mjs +855 -0
- package/agent/tool-contract.mjs +101 -0
- package/agent/tool-event-contract.mjs +99 -0
- package/agent/tool-execution-ledger.mjs +32 -0
- package/agent/tool-network-policy.mjs +86 -0
- package/agent/tool-orchestrator.mjs +382 -0
- package/agent/tool-output-truncation.mjs +70 -0
- package/agent/tool-registry.mjs +200 -0
- package/agent/tool-retry-policy.mjs +57 -0
- package/agent/tool-runtime-context.mjs +220 -0
- package/bench/harness-load-bench.mjs +281 -0
- package/bench/harness-parity-bench.mjs +214 -0
- package/bench/swebench/bosun-swebench.mjs +1 -0
- package/bosun-tui.mjs +59 -13
- package/bosun.schema.json +358 -1
- package/cli.mjs +641 -190
- package/config/config-doctor.mjs +78 -4
- package/config/config-editor.mjs +417 -0
- package/config/config.mjs +217 -117
- package/config/repo-config.mjs +78 -10
- package/config/repo-root.mjs +33 -1
- package/desktop/main.mjs +438 -99
- package/desktop/package.json +1 -1
- package/git/diff-stats.mjs +7 -5
- package/infra/anomaly-detector.mjs +115 -15
- package/infra/approval-projection-store.mjs +75 -0
- package/infra/config-reload-bus.mjs +33 -0
- package/infra/container-runner.mjs +37 -3
- package/infra/error-detector.mjs +109 -34
- package/infra/event-schema.mjs +353 -0
- package/infra/guardrails.mjs +383 -0
- package/infra/heartbeat-monitor.mjs +432 -0
- package/infra/library-manager.mjs +359 -233
- package/infra/live-event-projector.mjs +197 -0
- package/infra/maintenance.mjs +176 -37
- package/infra/monitor.mjs +1280 -194
- package/infra/preflight.mjs +71 -5
- package/infra/presence.mjs +33 -9
- package/infra/projection-contract.mjs +27 -0
- package/infra/provider-usage-ledger.mjs +73 -0
- package/infra/replay-reader.mjs +140 -0
- package/infra/runtime-accumulator.mjs +303 -8
- package/infra/runtime-metrics.mjs +156 -0
- package/infra/session-projection-store.mjs +169 -0
- package/infra/session-telemetry-runtime.mjs +580 -0
- package/infra/session-telemetry.mjs +338 -0
- package/infra/session-tracker.mjs +1407 -174
- package/infra/startup-service.mjs +0 -2
- package/infra/storage-janitor.mjs +1046 -0
- package/infra/subagent-projection-store.mjs +89 -0
- package/infra/test-runtime.mjs +53 -20
- package/infra/trace-export.mjs +103 -0
- package/infra/tracing.mjs +13 -125
- package/infra/tui-bridge.mjs +607 -5
- package/infra/update-check.mjs +7 -8
- package/infra/windows-hidden-child-processes.mjs +99 -0
- package/infra/worktree-recovery-state.mjs +15 -5
- package/kanban/kanban-adapter.mjs +674 -41
- package/kanban/repo-mirror-projection-store.mjs +871 -0
- package/lib/agent-configuration-guide.mjs +280 -0
- package/lib/hot-path-runtime.mjs +1061 -0
- package/lib/integrations-registry.mjs +294 -0
- package/lib/log-tail.mjs +101 -0
- package/lib/mojibake-repair.mjs +40 -0
- package/lib/repo-map.mjs +137 -24
- package/lib/request-json-api.mjs +59 -0
- package/lib/safe-box.mjs +56 -0
- package/lib/session-insights.mjs +3 -65
- package/lib/state-ledger-sqlite.mjs +4462 -0
- package/lib/vault-keychain.mjs +259 -0
- package/lib/vault.mjs +374 -0
- package/lib/workflow-flowchart-utils.mjs +326 -0
- package/native/bosun-telemetry/Cargo.toml +9 -0
- package/native/bosun-telemetry/src/export.rs +151 -0
- package/native/bosun-telemetry/src/main.rs +76 -0
- package/native/bosun-telemetry/src/metrics.rs +114 -0
- package/native/bosun-telemetry/src/session_telemetry.rs +178 -0
- package/native/bosun-unified-exec/Cargo.lock +107 -0
- package/native/bosun-unified-exec/Cargo.toml +8 -0
- package/native/bosun-unified-exec/src/async_watcher.rs +145 -0
- package/native/bosun-unified-exec/src/head_tail_buffer.rs +241 -0
- package/native/bosun-unified-exec/src/main.rs +86 -0
- package/native/bosun-unified-exec/src/process_manager.rs +308 -0
- package/native/bosun-unified-exec/src/tool_orchestrator.rs +187 -0
- package/package.json +214 -36
- package/postinstall.mjs +182 -12
- package/server/bosun-mcp-server.mjs +333 -3
- package/server/routes/harness-agent-bridge.mjs +128 -0
- package/server/routes/harness-approvals.mjs +290 -0
- package/server/routes/harness-events.mjs +469 -0
- package/server/routes/harness-providers.mjs +385 -0
- package/server/routes/harness-sessions.mjs +2230 -0
- package/server/routes/harness-subagents.mjs +138 -0
- package/server/routes/harness-surface-payload.mjs +74 -0
- package/server/setup-web-server.mjs +199 -24
- package/server/ui-server.mjs +10983 -3421
- package/setup.mjs +25 -2
- package/shell/anthropic-native-adapter.mjs +1218 -0
- package/shell/auth-resolver.mjs +247 -0
- package/shell/claude-shell.mjs +85 -2
- package/shell/codex-config-file.mjs +9 -0
- package/shell/codex-config.mjs +49 -5
- package/shell/codex-model-profiles.mjs +29 -59
- package/shell/codex-sdk-import.mjs +7 -0
- package/shell/codex-shell.mjs +574 -159
- package/shell/context-compaction.mjs +898 -0
- package/shell/copilot-shell.mjs +362 -130
- package/shell/gemini-native-adapter.mjs +411 -0
- package/shell/gemini-shell.mjs +121 -13
- package/shell/mcp-client.mjs +401 -0
- package/shell/mcp-registry.mjs +72 -0
- package/shell/message-pruner.mjs +248 -0
- package/shell/openai-native-adapter.mjs +1975 -0
- package/shell/opencode-providers.mjs +16 -816
- package/shell/opencode-shell.mjs +180 -9
- package/shell/provider-transform.mjs +386 -0
- package/shell/retry-fetch.mjs +244 -0
- package/shell/session-resume.mjs +97 -0
- package/shell/session-store.mjs +215 -0
- package/shell/shell-adapter-registry.mjs +346 -0
- package/shell/shell-session-compat.mjs +442 -0
- package/shell/smooth-stream.mjs +233 -0
- package/shell/stop-condition.mjs +238 -0
- package/shell/tool-call-repair.mjs +345 -0
- package/shell/tool-executor.mjs +571 -0
- package/task/pipeline.mjs +3 -1
- package/task/task-assessment.mjs +312 -6
- package/task/task-claims.mjs +311 -47
- package/task/task-cli.mjs +79 -4
- package/task/task-context.mjs +37 -0
- package/task/task-debt-ledger.mjs +110 -0
- package/task/task-executor.mjs +1093 -107
- package/task/task-replanner.mjs +553 -0
- package/task/task-simulate-cli.mjs +1481 -0
- package/task/task-store.mjs +960 -64
- package/telegram/executor-health-region-cache.mjs +75 -0
- package/telegram/harness-api-client.mjs +124 -0
- package/telegram/sticky-menu-state.mjs +384 -0
- package/telegram/telegram-bot.mjs +418 -812
- package/telegram/telegram-sentinel.mjs +24 -13
- package/telegram/telegram-surface-runtime.mjs +53 -0
- package/tools/generate-demo-defaults.mjs +23 -4
- package/tools/harness-hotpath-bench.mjs +246 -0
- package/tools/import-check.mjs +56 -11
- package/tools/install-git-hooks.mjs +96 -20
- package/tools/native-rust.mjs +124 -0
- package/tools/packed-cli-smoke.mjs +139 -53
- package/tools/prepublish-check.mjs +53 -1
- package/tools/run-workflow-guaranteed-suite.mjs +56 -0
- package/tools/sync-demo-ui.mjs +188 -0
- package/tools/syntax-check.mjs +32 -28
- package/tools/vite-windows-realpath-shim.mjs +274 -0
- package/tools/vitest-esbuild-shim.mjs +45 -0
- package/tools/vitest-full-suite.mjs +310 -0
- package/tools/vitest-runner.mjs +474 -7
- package/tools/workflow-orphan-worktree-recovery.mjs +24 -7
- package/tui/CommandPalette.js +87 -0
- package/tui/app.mjs +422 -36
- package/tui/components/status-header.mjs +39 -0
- package/tui/lib/command-palette.mjs +191 -0
- package/tui/lib/connection-target.mjs +577 -0
- package/tui/lib/navigation.mjs +6 -2
- package/tui/lib/ws-bridge.mjs +141 -51
- package/tui/screens/agents-screen-helpers.mjs +87 -3
- package/tui/screens/agents.mjs +1068 -200
- package/tui/screens/connection-setup.mjs +363 -0
- package/tui/screens/harness-approvals.mjs +7 -0
- package/tui/screens/harness-sessions.mjs +109 -0
- package/tui/screens/harness-subagents.mjs +18 -0
- package/tui/screens/harness-telemetry.mjs +67 -0
- package/tui/screens/logs.mjs +1 -5
- package/tui/screens/settings-screen-helpers.mjs +75 -0
- package/tui/screens/settings.mjs +397 -0
- package/tui/screens/status.mjs +126 -4
- package/tui/screens/telemetry-screen-helpers.mjs +158 -0
- package/tui/screens/telemetry.mjs +246 -0
- package/tui/screens/workflows.mjs +984 -0
- package/ui/app.js +450 -183
- package/ui/assets/toastui-editor-all.min.js +24 -0
- package/ui/components/agent-selector.js +706 -49
- package/ui/components/charts.js +16 -12
- package/ui/components/chat-view.js +536 -35
- package/ui/components/context-menu.js +89 -0
- package/ui/components/diff-viewer.js +83 -34
- package/ui/components/kanban-board.js +513 -94
- package/ui/components/session-list.js +292 -65
- package/ui/components/task-markdown.js +272 -0
- package/ui/components/workspace-switcher.js +11 -2
- package/ui/demo-defaults.js +13806 -3965
- package/ui/demo.html +817 -3
- package/ui/index.html +32 -6
- package/ui/modules/agent-events.js +309 -36
- package/ui/modules/api.js +236 -13
- package/ui/modules/chat-turn-groups.js +101 -0
- package/ui/modules/harness-client.js +56 -0
- package/ui/modules/icons.js +18 -2
- package/ui/modules/router.js +2 -0
- package/ui/modules/session-api.js +158 -14
- package/ui/modules/session-insights-worker.js +28 -0
- package/ui/modules/session-insights.js +173 -4
- package/ui/modules/session-surface.js +221 -0
- package/ui/modules/settings-schema.js +146 -26
- package/ui/modules/state.js +56 -3
- package/ui/modules/streaming.js +196 -60
- package/ui/modules/structured-values.js +47 -0
- package/ui/modules/task-hierarchy.js +374 -0
- package/ui/modules/worktree-recovery.js +10 -1
- package/ui/setup.html +174 -6
- package/ui/styles/components.css +982 -130
- package/ui/styles/kanban.css +229 -0
- package/ui/styles/layout.css +404 -144
- package/ui/styles/toastui-editor-dark.css +1 -0
- package/ui/styles/toastui-editor-viewer.css +6 -0
- package/ui/styles/toastui-editor.css +6 -0
- package/ui/styles/variables.css +14 -2
- package/ui/styles/workspace-switcher.css +22 -0
- package/ui/styles.css +19 -0
- package/ui/tabs/agents.js +1032 -96
- package/ui/tabs/chat.js +588 -146
- package/ui/tabs/context-compression-lab.js +962 -0
- package/ui/tabs/control.js +121 -0
- package/ui/tabs/dashboard.js +302 -86
- package/ui/tabs/guardrails.js +1140 -0
- package/ui/tabs/integrations.js +388 -0
- package/ui/tabs/library.js +19 -4
- package/ui/tabs/manual-flows.js +268 -52
- package/ui/tabs/settings.js +1604 -104
- package/ui/tabs/tasks.js +2544 -300
- package/ui/tabs/telemetry.js +102 -6
- package/ui/tabs/workflow-canvas-utils.mjs +172 -15
- package/ui/tabs/workflows.js +2421 -196
- package/ui/tui/App.js +117 -117
- package/ui/tui/HelpScreen.js +201 -0
- package/ui/tui/SettingsScreen.js +388 -0
- package/ui/tui/TasksScreen.js +25 -11
- package/ui/tui/TelemetryScreen.js +155 -0
- package/ui/tui/WorkflowsScreen.js +350 -0
- package/ui/tui/config-events.js +13 -0
- package/ui/tui/constants.js +1 -1
- package/ui/tui/tasks-screen-helpers.js +52 -0
- package/ui/tui/telemetry-helpers.js +158 -0
- package/ui/tui/useTasks.js +1 -6
- package/ui/tui/useWebSocket.js +1 -7
- package/ui/tui/useWorkflows.js +120 -5
- package/ui/tui/workflows-screen-helpers.js +220 -0
- package/utils.mjs +9 -22
- package/voice/vision-session-state.mjs +257 -0
- package/voice/voice-action-dispatcher.mjs +57 -12
- package/voice/voice-agents-sdk.mjs +1 -1
- package/voice/voice-auth-manager.mjs +102 -123
- package/voice/voice-tool-definitions.mjs +7 -7
- package/voice/voice-tools.mjs +837 -101
- package/workflow/action-approval.mjs +415 -0
- package/workflow/approval-queue.mjs +1254 -0
- package/workflow/credential-store.mjs +553 -0
- package/workflow/cron-scheduler.mjs +512 -0
- package/workflow/declarative-workflows.mjs +21 -2
- package/workflow/delegation-runtime.mjs +557 -0
- package/workflow/execution-ledger.mjs +1317 -33
- package/workflow/harness-approval-node.mjs +237 -0
- package/workflow/harness-output-contract.mjs +86 -0
- package/workflow/harness-session-node.mjs +160 -0
- package/workflow/harness-subagent-node.mjs +483 -0
- package/workflow/harness-tool-node.mjs +176 -0
- package/workflow/heavy-runner-pool.mjs +71 -4
- package/workflow/manual-flows.mjs +969 -28
- package/workflow/mcp-discovery-proxy.mjs +349 -137
- package/workflow/mcp-registry.mjs +331 -27
- package/workflow/meeting-workflow-service.mjs +24 -12
- package/workflow/pipeline-workflows.mjs +44 -2
- package/workflow/pipeline.mjs +72 -28
- package/workflow/project-detection.mjs +31 -6
- package/workflow/research-evidence-sidecar.mjs +1246 -0
- package/workflow/run-evaluator.mjs +2155 -0
- package/workflow/workflow-cli.mjs +229 -2
- package/workflow/workflow-contract.mjs +130 -2
- package/workflow/workflow-engine.mjs +5520 -298
- package/workflow/workflow-nodes/actions.mjs +15526 -0
- package/workflow/workflow-nodes/agent.mjs +1863 -0
- package/workflow/workflow-nodes/conditions.mjs +307 -0
- package/workflow/workflow-nodes/definitions.mjs +176 -15
- package/workflow/workflow-nodes/flow.mjs +749 -0
- package/workflow/workflow-nodes/loop.mjs +449 -0
- package/workflow/workflow-nodes/meetings.mjs +456 -0
- package/workflow/workflow-nodes/notifications.mjs +169 -0
- package/workflow/workflow-nodes/transforms.mjs +50 -24
- package/workflow/workflow-nodes/triggers.mjs +1405 -0
- package/workflow/workflow-nodes/validation.mjs +722 -0
- package/workflow/workflow-nodes.mjs +38 -15781
- package/workflow/workflow-serializer.mjs +294 -0
- package/workflow/workflow-templates.mjs +197 -12
- package/workflow-templates/_helpers.mjs +1 -3
- package/workflow-templates/agents.mjs +235 -27
- package/workflow-templates/bosun-native.mjs +3 -1
- package/workflow-templates/code-quality.mjs +1 -217
- package/workflow-templates/continuation-loop.mjs +22 -7
- package/workflow-templates/coverage.mjs +6 -2
- package/workflow-templates/github.mjs +2263 -136
- package/workflow-templates/planning.mjs +1 -22
- package/workflow-templates/reliability.mjs +383 -12
- package/workflow-templates/research-evidence.mjs +389 -0
- package/workflow-templates/security.mjs +75 -62
- package/workflow-templates/sub-workflows.mjs +11 -3
- package/workflow-templates/task-batch.mjs +100 -10
- package/workflow-templates/task-lifecycle.mjs +313 -49
- package/workspace/context-cache.mjs +934 -102
- package/workspace/context-indexer.mjs +915 -9
- package/workspace/context-injector.mjs +144 -0
- package/workspace/execution-journal.mjs +255 -0
- package/workspace/scope-locks.mjs +481 -0
- package/workspace/shared-knowledge.mjs +496 -91
- package/workspace/shared-state-manager.mjs +344 -1
- package/workspace/skillbook-store.mjs +681 -0
- package/workspace/workspace-manager.mjs +14 -8
- package/workspace/workspace-monitor.mjs +3 -3
- package/workspace/worktree-manager.mjs +54 -12
- package/workspace/worktree-setup.mjs +634 -43
- package/agent/rotate-agent-logs.sh +0 -134
package/.env.example
CHANGED
|
@@ -91,8 +91,6 @@ TELEGRAM_MINIAPP_ENABLED=false
|
|
|
91
91
|
# BOSUN_UI_BROWSER_OPEN_MODE=manual
|
|
92
92
|
# Legacy auto-open toggle for UI server (requires BOSUN_UI_BROWSER_OPEN_MODE=auto)
|
|
93
93
|
# BOSUN_UI_AUTO_OPEN_BROWSER=false
|
|
94
|
-
# Daemon startup keeps browser auto-open disabled unless this is explicitly true.
|
|
95
|
-
# BOSUN_UI_AUTO_OPEN_ON_DAEMON=false
|
|
96
94
|
# Show full /?token=... browser URL in logs (default: false; token is hidden)
|
|
97
95
|
# BOSUN_UI_LOG_TOKENIZED_BROWSER_URL=false
|
|
98
96
|
# Setup wizard browser auto-open (default: true when mode=auto)
|
|
@@ -382,6 +380,12 @@ VOICE_DELEGATE_EXECUTOR=codex-sdk
|
|
|
382
380
|
# INTERNAL_EXECUTOR_REVIEW_TIMEOUT_MS=300000
|
|
383
381
|
# Experimental autonomous backlog replenishment (disabled by default)
|
|
384
382
|
# INTERNAL_EXECUTOR_REPLENISH_ENABLED=false
|
|
383
|
+
# Enable deterministic internal harness compile/activate control-plane support
|
|
384
|
+
# BOSUN_HARNESS_ENABLED=false
|
|
385
|
+
# Path to harness profile source (JSON or markdown fenced JSON)
|
|
386
|
+
# BOSUN_HARNESS_SOURCE=.bosun/harness/internal-harness.md
|
|
387
|
+
# Validation mode: off | report | enforce
|
|
388
|
+
# BOSUN_HARNESS_VALIDATION_MODE=report
|
|
385
389
|
# Minimum follow-up tasks to generate per completed task (1-2)
|
|
386
390
|
# INTERNAL_EXECUTOR_REPLENISH_MIN_NEW_TASKS=1
|
|
387
391
|
# Maximum follow-up tasks to generate per completed task (1-3)
|
|
@@ -498,6 +502,7 @@ VOICE_DELEGATE_EXECUTOR=codex-sdk
|
|
|
498
502
|
# internal - local task-store source of truth (recommended primary)
|
|
499
503
|
# github - GitHub Issues
|
|
500
504
|
# jira - Jira Issues
|
|
505
|
+
# gnap - GNAP projection backend (off by default)
|
|
501
506
|
# KANBAN_BACKEND=internal
|
|
502
507
|
# Sync behavior:
|
|
503
508
|
# internal-primary - internal task-store remains source-of-truth (recommended)
|
|
@@ -598,6 +603,20 @@ VOICE_DELEGATE_EXECUTOR=codex-sdk
|
|
|
598
603
|
# Optional JSON custom field to store full shared state payload
|
|
599
604
|
# JIRA_CUSTOM_FIELD_SHARED_STATE=customfield_10048
|
|
600
605
|
|
|
606
|
+
# GNAP backend (KANBAN_BACKEND=gnap)
|
|
607
|
+
# Master toggle for GNAP integration. Must be enabled before selecting gnap.
|
|
608
|
+
# GNAP_ENABLED=false
|
|
609
|
+
# Path to the repo or clone that will host GNAP projection data
|
|
610
|
+
# GNAP_REPO_PATH=
|
|
611
|
+
# Synchronization mode. Bosun currently supports projection-only GNAP wiring.
|
|
612
|
+
# GNAP_SYNC_MODE=projection
|
|
613
|
+
# Where to store GNAP run metadata: git|local
|
|
614
|
+
# GNAP_RUN_STORAGE=git
|
|
615
|
+
# Where to store GNAP message projections: off|git|local
|
|
616
|
+
# GNAP_MESSAGE_STORAGE=off
|
|
617
|
+
# Optional sanitized roadmap export for shared visibility
|
|
618
|
+
# GNAP_PUBLIC_ROADMAP_ENABLED=false
|
|
619
|
+
|
|
601
620
|
# ─── Sandbox Policy ──────────────────────────────────────────────────────────
|
|
602
621
|
# Controls agent sandbox isolation when using Codex SDK.
|
|
603
622
|
# Options:
|
|
@@ -1020,17 +1039,8 @@ COPILOT_CLOUD_DISABLED=true
|
|
|
1020
1039
|
# WORKFLOW_RECOVERY_BACKOFF_MAX_MS=60000
|
|
1021
1040
|
# Random jitter ratio (0.0-0.9) applied to backoff to prevent retry storms.
|
|
1022
1041
|
# WORKFLOW_RECOVERY_BACKOFF_JITTER_RATIO=0.2
|
|
1023
|
-
# Delay startup
|
|
1024
|
-
#
|
|
1025
|
-
# WORKFLOW_RECOVERY_STARTUP_GRACE_MS=30000
|
|
1026
|
-
# Additional delay inserted between each startup recovery action.
|
|
1027
|
-
# WORKFLOW_RECOVERY_STARTUP_STEP_DELAY_MS=15000
|
|
1028
|
-
|
|
1029
|
-
# Bosun MCP policy: by default Bosun-launched agents only receive validated
|
|
1030
|
-
# library-managed MCP servers, with required auth pulled from environment.
|
|
1031
|
-
# BOSUN_MCP_REQUIRE_AUTH=true
|
|
1032
|
-
# BOSUN_MCP_ALLOW_EXTERNAL_SOURCES=false
|
|
1033
|
-
# BOSUN_MCP_ALLOW_DEFAULT_SERVERS=false
|
|
1042
|
+
# Delay startup interrupted-run replay so the UI/API can become responsive first.
|
|
1043
|
+
# WORKFLOW_STARTUP_HISTORY_RECOVERY_DELAY_MS=120000
|
|
1034
1044
|
|
|
1035
1045
|
# ─── GitHub Issue Reconciler ─────────────────────────────────────────────────
|
|
1036
1046
|
# Periodically reconciles open GitHub issues against open/merged PRs.
|
|
@@ -1114,6 +1124,9 @@ COPILOT_CLOUD_DISABLED=true
|
|
|
1114
1124
|
# Monitor source hot-reload watcher. Default: enabled in devmode, disabled otherwise.
|
|
1115
1125
|
# Set to true to force-enable monitor source hot-restart, false to force-disable.
|
|
1116
1126
|
# SELF_RESTART_WATCH_ENABLED=true
|
|
1127
|
+
# Quiet period after the last source-file change before self-restart is allowed.
|
|
1128
|
+
# Default: 180000 (3 minutes)
|
|
1129
|
+
# SELF_RESTART_QUIET_MS=180000
|
|
1117
1130
|
# Status file path (default: .cache/orchestrator-status.json)
|
|
1118
1131
|
# STATUS_FILE=.cache/orchestrator-status.json
|
|
1119
1132
|
# Log directory (default: ./logs)
|
|
@@ -1156,5 +1169,3 @@ COPILOT_CLOUD_DISABLED=true
|
|
|
1156
1169
|
|
|
1157
1170
|
# OpenTelemetry tracing (optional)
|
|
1158
1171
|
# BOSUN_OTEL_ENDPOINT=http://localhost:4318/v1/traces
|
|
1159
|
-
|
|
1160
|
-
|
package/README.md
CHANGED
|
@@ -65,7 +65,7 @@ Open `https://localhost:3080` to start the setup wizard.
|
|
|
65
65
|
|
|
66
66
|
Requires:
|
|
67
67
|
|
|
68
|
-
- Node.js
|
|
68
|
+
- Node.js 22.13+
|
|
69
69
|
- Git
|
|
70
70
|
- Bash (for `.sh` wrappers) or PowerShell 7+ (for `.ps1` wrappers)
|
|
71
71
|
- GitHub CLI (`gh`) recommended
|
|
@@ -144,16 +144,6 @@ Set `primaryAgent` in `.bosun/bosun.config.json` or choose an executor preset du
|
|
|
144
144
|
- `bosun --daemon --sentinel` starts daemon + sentinel together (recommended for unattended operation).
|
|
145
145
|
- `bosun --terminate` is the clean reset command when you suspect stale/ghost processes.
|
|
146
146
|
|
|
147
|
-
## VS Code debugging
|
|
148
|
-
|
|
149
|
-
Bosun now includes workspace debug entries in `.vscode/launch.json` and helper tasks in `.vscode/tasks.json`.
|
|
150
|
-
|
|
151
|
-
- `Debug Bosun CLI` launches `cli.mjs` with the repo-local `.bosun` config and attaches the debugger to the real CLI entry path.
|
|
152
|
-
- `Debug Bosun Monitor Direct` launches `infra/monitor.mjs` directly when you want to debug monitor logic without stepping through the CLI worker bootstrap.
|
|
153
|
-
- `Debug Bosun Daemon Child (foreground)` runs the daemon-child path without detaching, which is useful for restart-loop and daemon-specific behavior.
|
|
154
|
-
- `Attach to Bosun CLI Startup (9229)` and `Attach to Bosun Monitor Startup (9230)` start Bosun under `--inspect-brk` so you can catch startup failures before normal breakpoints would bind.
|
|
155
|
-
- `Bosun: Terminate Runtime` is the cleanup task to use if a stale monitor/daemon is holding the lock before a debug session.
|
|
156
|
-
|
|
157
147
|
Telegram operators can pull the weekly agent work summary with `/weekly [days]` or `/report weekly [days]`. To post it automatically once per week, set `TELEGRAM_WEEKLY_REPORT_ENABLED=true` together with `TELEGRAM_WEEKLY_REPORT_DAY`, `TELEGRAM_WEEKLY_REPORT_HOUR`, and optional `TELEGRAM_WEEKLY_REPORT_DAYS`.
|
|
158
148
|
|
|
159
149
|
## Documentation
|
|
@@ -18,6 +18,12 @@
|
|
|
18
18
|
* createAgentEventBus(options) → AgentEventBus instance
|
|
19
19
|
* AgentEventBus class
|
|
20
20
|
* AGENT_EVENT — Frozen enum of all event types
|
|
21
|
+
*
|
|
22
|
+
* Canonical architecture note:
|
|
23
|
+
* This bus is the canonical runtime ingress for live agent events into the
|
|
24
|
+
* observability spine. Surfaces may subscribe or rebroadcast, but canonical
|
|
25
|
+
* event normalization and harness telemetry recording must remain centralized
|
|
26
|
+
* here plus `infra/session-telemetry.mjs`.
|
|
21
27
|
*/
|
|
22
28
|
|
|
23
29
|
import {
|
|
@@ -26,6 +32,12 @@ import {
|
|
|
26
32
|
snapshotRetryQueue,
|
|
27
33
|
} from "./retry-queue.mjs";
|
|
28
34
|
import { addSpanEvent, recordAgentError, recordIntervention } from "../infra/tracing.mjs";
|
|
35
|
+
import {
|
|
36
|
+
getHarnessTelemetrySummary,
|
|
37
|
+
listHarnessTelemetryEvents,
|
|
38
|
+
recordHarnessTelemetryEvent,
|
|
39
|
+
} from "../infra/session-telemetry.mjs";
|
|
40
|
+
import { normalizeCanonicalBusEvent } from "../infra/event-schema.mjs";
|
|
29
41
|
|
|
30
42
|
const TAG = "[agent-event-bus]";
|
|
31
43
|
|
|
@@ -147,6 +159,7 @@ export class AgentEventBus {
|
|
|
147
159
|
: (typeof globalThis.__bosun_setRetryQueueData === "function"
|
|
148
160
|
? globalThis.__bosun_setRetryQueueData
|
|
149
161
|
: null);
|
|
162
|
+
this._configDir = options.configDir || process.cwd();
|
|
150
163
|
|
|
151
164
|
/** @type {Array<{type: string, taskId: string, payload: object, ts: number}>} ring buffer */
|
|
152
165
|
this._eventLog = [];
|
|
@@ -259,6 +272,7 @@ export class AgentEventBus {
|
|
|
259
272
|
if (this._eventLog.length > this._maxEventLogSize) {
|
|
260
273
|
this._eventLog.shift();
|
|
261
274
|
}
|
|
275
|
+
this._recordCanonicalEvent(event);
|
|
262
276
|
|
|
263
277
|
// ── WS broadcast
|
|
264
278
|
if (!opts.skipBroadcast) {
|
|
@@ -589,6 +603,7 @@ export class AgentEventBus {
|
|
|
589
603
|
*/
|
|
590
604
|
getStatus() {
|
|
591
605
|
const retryQueue = snapshotRetryQueue(this._retryQueueState);
|
|
606
|
+
const observability = getHarnessTelemetrySummary({ configDir: this._configDir });
|
|
592
607
|
return {
|
|
593
608
|
started: this._started,
|
|
594
609
|
eventLogSize: this._eventLog.length,
|
|
@@ -599,6 +614,10 @@ export class AgentEventBus {
|
|
|
599
614
|
retryQueue,
|
|
600
615
|
liveness: this.getAgentLiveness(),
|
|
601
616
|
errorPatterns: this.getErrorPatternSummary(),
|
|
617
|
+
observability: {
|
|
618
|
+
eventCount: Number(observability?.eventCount || 0),
|
|
619
|
+
lastEventAt: observability?.lastEventAt || null,
|
|
620
|
+
},
|
|
602
621
|
};
|
|
603
622
|
}
|
|
604
623
|
|
|
@@ -606,6 +625,13 @@ export class AgentEventBus {
|
|
|
606
625
|
return snapshotRetryQueue(this._retryQueueState);
|
|
607
626
|
}
|
|
608
627
|
|
|
628
|
+
getCanonicalEventLog(filter = {}) {
|
|
629
|
+
return listHarnessTelemetryEvents({
|
|
630
|
+
...filter,
|
|
631
|
+
source: filter.source || "agent-event-bus",
|
|
632
|
+
}, { configDir: this._configDir });
|
|
633
|
+
}
|
|
634
|
+
|
|
609
635
|
clearRetryQueueTask(taskId, reason = "manual") {
|
|
610
636
|
const id = String(taskId || "").trim();
|
|
611
637
|
if (!id) return;
|
|
@@ -637,6 +663,13 @@ export class AgentEventBus {
|
|
|
637
663
|
}
|
|
638
664
|
}
|
|
639
665
|
|
|
666
|
+
_recordCanonicalEvent(event) {
|
|
667
|
+
recordHarnessTelemetryEvent(
|
|
668
|
+
normalizeCanonicalBusEvent(event),
|
|
669
|
+
{ configDir: this._configDir },
|
|
670
|
+
);
|
|
671
|
+
}
|
|
672
|
+
|
|
640
673
|
_updateRetryQueue(action, meta = {}) {
|
|
641
674
|
this._retryQueueState = reduceRetryQueue(this._retryQueueState, action);
|
|
642
675
|
const snapshot = snapshotRetryQueue(this._retryQueueState);
|
|
@@ -1100,5 +1133,3 @@ export class AgentEventBus {
|
|
|
1100
1133
|
export function createAgentEventBus(options) {
|
|
1101
1134
|
return new AgentEventBus(options);
|
|
1102
1135
|
}
|
|
1103
|
-
|
|
1104
|
-
|
package/agent/agent-hooks.mjs
CHANGED
|
@@ -51,9 +51,6 @@ const MAX_OUTPUT_BYTES = 64 * 1024;
|
|
|
51
51
|
/** Whether we're running on Windows */
|
|
52
52
|
const IS_WINDOWS = process.platform === "win32";
|
|
53
53
|
|
|
54
|
-
/** Preferred Windows shell for hook execution. */
|
|
55
|
-
const WINDOWS_SHELL = process.env.ComSpec || "cmd.exe";
|
|
56
|
-
|
|
57
54
|
/** Default max retries for retryable hooks */
|
|
58
55
|
const DEFAULT_MAX_RETRIES = 2;
|
|
59
56
|
|
|
@@ -844,42 +841,6 @@ function _buildEnv(ctx) {
|
|
|
844
841
|
return env;
|
|
845
842
|
}
|
|
846
843
|
|
|
847
|
-
function _getSpawnCommand(command) {
|
|
848
|
-
const trimmed = String(command ?? "").trim();
|
|
849
|
-
|
|
850
|
-
if (IS_WINDOWS) {
|
|
851
|
-
const lower = trimmed.toLowerCase();
|
|
852
|
-
if (lower.startsWith("powershell ") || lower.startsWith("powershell.exe ")) {
|
|
853
|
-
const inlineCommand = trimmed
|
|
854
|
-
.replace(/^powershell(?:\.exe)?\s+-NoProfile\s+-Command\s+/i, "")
|
|
855
|
-
.replace(/^powershell(?:\.exe)?\s+-Command\s+/i, "")
|
|
856
|
-
.replace(/^"|"$/g, "");
|
|
857
|
-
return {
|
|
858
|
-
file: "powershell.exe",
|
|
859
|
-
args: ["-NoProfile", "-Command", inlineCommand],
|
|
860
|
-
};
|
|
861
|
-
}
|
|
862
|
-
if (lower.startsWith("cmd ") || lower.startsWith("cmd.exe ")) {
|
|
863
|
-
const inlineCommand = trimmed
|
|
864
|
-
.replace(/^cmd(?:\.exe)?\s+\/d\s+\/s\s+\/c\s+/i, "")
|
|
865
|
-
.replace(/^cmd(?:\.exe)?\s+\/c\s+/i, "");
|
|
866
|
-
return {
|
|
867
|
-
file: WINDOWS_SHELL,
|
|
868
|
-
args: ["/d", "/s", "/c", inlineCommand],
|
|
869
|
-
};
|
|
870
|
-
}
|
|
871
|
-
return {
|
|
872
|
-
file: WINDOWS_SHELL,
|
|
873
|
-
args: ["/d", "/s", "/c", trimmed],
|
|
874
|
-
};
|
|
875
|
-
}
|
|
876
|
-
|
|
877
|
-
return {
|
|
878
|
-
file: "/bin/sh",
|
|
879
|
-
args: ["-c", trimmed],
|
|
880
|
-
};
|
|
881
|
-
}
|
|
882
|
-
|
|
883
844
|
// ── Internal: Synchronous Hook Execution ────────────────────────────────────
|
|
884
845
|
|
|
885
846
|
/**
|
|
@@ -931,13 +892,12 @@ function _executeHookSync(hook, ctx, env) {
|
|
|
931
892
|
};
|
|
932
893
|
|
|
933
894
|
try {
|
|
934
|
-
const
|
|
935
|
-
const result = spawnSync(spawnTarget.file, spawnTarget.args, {
|
|
895
|
+
const result = spawnSync(hook.command, {
|
|
936
896
|
cwd,
|
|
937
897
|
env: hookEnv,
|
|
938
898
|
encoding: "utf8",
|
|
939
899
|
timeout,
|
|
940
|
-
shell:
|
|
900
|
+
shell: true,
|
|
941
901
|
windowsHide: true,
|
|
942
902
|
maxBuffer: MAX_OUTPUT_BYTES,
|
|
943
903
|
});
|
|
@@ -1039,11 +999,10 @@ function _executeHookAsyncOnce(hook, ctx, env, attempt) {
|
|
|
1039
999
|
|
|
1040
1000
|
let child;
|
|
1041
1001
|
try {
|
|
1042
|
-
|
|
1043
|
-
child = spawn(spawnTarget.file, spawnTarget.args, {
|
|
1002
|
+
child = spawn(hook.command, {
|
|
1044
1003
|
cwd,
|
|
1045
1004
|
env: hookEnv,
|
|
1046
|
-
shell:
|
|
1005
|
+
shell: true,
|
|
1047
1006
|
windowsHide: true,
|
|
1048
1007
|
stdio: ["ignore", "pipe", "pipe"],
|
|
1049
1008
|
});
|
|
@@ -1294,10 +1253,3 @@ export function registerLibraryHooks(hooksByEvent) {
|
|
|
1294
1253
|
}
|
|
1295
1254
|
return { registered, skipped };
|
|
1296
1255
|
}
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|