hivehq 2.0.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/CHANGELOG.md +592 -0
- package/LICENSE +208 -0
- package/LICENSE.BSL +101 -0
- package/NOTICE +15 -0
- package/README.en.md +451 -0
- package/README.md +329 -0
- package/SECURITY.md +59 -0
- package/TRADEMARK.md +41 -0
- package/assets/hive-hero.png +0 -0
- package/assets/hive-team-view.png +0 -0
- package/assets/logo.png +0 -0
- package/assets/qq-group.jpg +0 -0
- package/dist/bin/team +7 -0
- package/dist/bin/team.cmd +3 -0
- package/dist/src/cli/hive-remote.d.ts +46 -0
- package/dist/src/cli/hive-remote.js +257 -0
- package/dist/src/cli/hive-update.d.ts +75 -0
- package/dist/src/cli/hive-update.js +215 -0
- package/dist/src/cli/hive.d.ts +78 -0
- package/dist/src/cli/hive.js +336 -0
- package/dist/src/cli/team.d.ts +38 -0
- package/dist/src/cli/team.js +762 -0
- package/dist/src/server/agent-command-resolver.d.ts +17 -0
- package/dist/src/server/agent-command-resolver.js +106 -0
- package/dist/src/server/agent-exit-classification.d.ts +6 -0
- package/dist/src/server/agent-exit-classification.js +6 -0
- package/dist/src/server/agent-launch-cache.d.ts +20 -0
- package/dist/src/server/agent-launch-cache.js +75 -0
- package/dist/src/server/agent-launch-resolver.d.ts +4 -0
- package/dist/src/server/agent-launch-resolver.js +38 -0
- package/dist/src/server/agent-manager-support.d.ts +36 -0
- package/dist/src/server/agent-manager-support.js +318 -0
- package/dist/src/server/agent-manager.d.ts +54 -0
- package/dist/src/server/agent-manager.js +104 -0
- package/dist/src/server/agent-run-bootstrap.d.ts +83 -0
- package/dist/src/server/agent-run-bootstrap.js +101 -0
- package/dist/src/server/agent-run-exit-handler.d.ts +8 -0
- package/dist/src/server/agent-run-exit-handler.js +32 -0
- package/dist/src/server/agent-run-start-context.d.ts +24 -0
- package/dist/src/server/agent-run-start-context.js +1 -0
- package/dist/src/server/agent-run-starter.d.ts +30 -0
- package/dist/src/server/agent-run-starter.js +155 -0
- package/dist/src/server/agent-run-store.d.ts +51 -0
- package/dist/src/server/agent-run-store.js +137 -0
- package/dist/src/server/agent-run-sync.d.ts +10 -0
- package/dist/src/server/agent-run-sync.js +32 -0
- package/dist/src/server/agent-runtime-active-run.d.ts +3 -0
- package/dist/src/server/agent-runtime-active-run.js +10 -0
- package/dist/src/server/agent-runtime-close.d.ts +5 -0
- package/dist/src/server/agent-runtime-close.js +36 -0
- package/dist/src/server/agent-runtime-contract.d.ts +48 -0
- package/dist/src/server/agent-runtime-contract.js +1 -0
- package/dist/src/server/agent-runtime-flow-adapter.d.ts +10 -0
- package/dist/src/server/agent-runtime-flow-adapter.js +14 -0
- package/dist/src/server/agent-runtime-list-runs.d.ts +3 -0
- package/dist/src/server/agent-runtime-list-runs.js +18 -0
- package/dist/src/server/agent-runtime-ports.d.ts +22 -0
- package/dist/src/server/agent-runtime-ports.js +1 -0
- package/dist/src/server/agent-runtime-stop-run.d.ts +4 -0
- package/dist/src/server/agent-runtime-stop-run.js +19 -0
- package/dist/src/server/agent-runtime-types.d.ts +5 -0
- package/dist/src/server/agent-runtime-types.js +1 -0
- package/dist/src/server/agent-runtime.d.ts +10 -0
- package/dist/src/server/agent-runtime.js +143 -0
- package/dist/src/server/agent-session-store.d.ts +7 -0
- package/dist/src/server/agent-session-store.js +45 -0
- package/dist/src/server/agent-startup-instructions.d.ts +20 -0
- package/dist/src/server/agent-startup-instructions.js +36 -0
- package/dist/src/server/agent-stdin-dispatcher.d.ts +52 -0
- package/dist/src/server/agent-stdin-dispatcher.js +224 -0
- package/dist/src/server/agent-tokens.d.ts +15 -0
- package/dist/src/server/agent-tokens.js +25 -0
- package/dist/src/server/app-state-store.d.ts +10 -0
- package/dist/src/server/app-state-store.js +12 -0
- package/dist/src/server/app.d.ts +20 -0
- package/dist/src/server/app.js +211 -0
- package/dist/src/server/claude-command-defaults.d.ts +1 -0
- package/dist/src/server/claude-command-defaults.js +5 -0
- package/dist/src/server/claude-session-coordinator.d.ts +10 -0
- package/dist/src/server/claude-session-coordinator.js +68 -0
- package/dist/src/server/claude-session-support.d.ts +1 -0
- package/dist/src/server/claude-session-support.js +1 -0
- package/dist/src/server/command-preset-defaults.d.ts +11 -0
- package/dist/src/server/command-preset-defaults.js +63 -0
- package/dist/src/server/command-preset-store.d.ts +49 -0
- package/dist/src/server/command-preset-store.js +83 -0
- package/dist/src/server/cron-util.d.ts +7 -0
- package/dist/src/server/cron-util.js +19 -0
- package/dist/src/server/dispatch-ledger-serializer.d.ts +15 -0
- package/dist/src/server/dispatch-ledger-serializer.js +14 -0
- package/dist/src/server/dispatch-ledger-store.d.ts +108 -0
- package/dist/src/server/dispatch-ledger-store.js +241 -0
- package/dist/src/server/env-sync-message.d.ts +9 -0
- package/dist/src/server/env-sync-message.js +29 -0
- package/dist/src/server/feature-flags.d.ts +42 -0
- package/dist/src/server/feature-flags.js +24 -0
- package/dist/src/server/fs-browse.d.ts +40 -0
- package/dist/src/server/fs-browse.js +306 -0
- package/dist/src/server/fs-pick-folder.d.ts +25 -0
- package/dist/src/server/fs-pick-folder.js +115 -0
- package/dist/src/server/fs-sandbox.d.ts +15 -0
- package/dist/src/server/fs-sandbox.js +56 -0
- package/dist/src/server/hive-team-guidance.d.ts +39 -0
- package/dist/src/server/hive-team-guidance.js +295 -0
- package/dist/src/server/http-errors.d.ts +22 -0
- package/dist/src/server/http-errors.js +44 -0
- package/dist/src/server/live-run-registry.d.ts +22 -0
- package/dist/src/server/live-run-registry.js +52 -0
- package/dist/src/server/local-request-guard.d.ts +3 -0
- package/dist/src/server/local-request-guard.js +41 -0
- package/dist/src/server/machine-name.d.ts +2 -0
- package/dist/src/server/machine-name.js +13 -0
- package/dist/src/server/marketplace-store.d.ts +38 -0
- package/dist/src/server/marketplace-store.js +85 -0
- package/dist/src/server/message-log-store.d.ts +51 -0
- package/dist/src/server/message-log-store.js +90 -0
- package/dist/src/server/open-target-commands.d.ts +54 -0
- package/dist/src/server/open-target-commands.js +204 -0
- package/dist/src/server/orchestrator-autostart.d.ts +42 -0
- package/dist/src/server/orchestrator-autostart.js +114 -0
- package/dist/src/server/orchestrator-launch.d.ts +24 -0
- package/dist/src/server/orchestrator-launch.js +71 -0
- package/dist/src/server/package-version.d.ts +17 -0
- package/dist/src/server/package-version.js +32 -0
- package/dist/src/server/path-canonicalization.d.ts +3 -0
- package/dist/src/server/path-canonicalization.js +29 -0
- package/dist/src/server/platform-path.d.ts +4 -0
- package/dist/src/server/platform-path.js +26 -0
- package/dist/src/server/post-start-input-writer.d.ts +6 -0
- package/dist/src/server/post-start-input-writer.js +242 -0
- package/dist/src/server/preset-launch-support.d.ts +6 -0
- package/dist/src/server/preset-launch-support.js +98 -0
- package/dist/src/server/pty-output-bus.d.ts +8 -0
- package/dist/src/server/pty-output-bus.js +32 -0
- package/dist/src/server/recovery-summary.d.ts +15 -0
- package/dist/src/server/recovery-summary.js +92 -0
- package/dist/src/server/remote-audit-store.d.ts +51 -0
- package/dist/src/server/remote-audit-store.js +108 -0
- package/dist/src/server/remote-config-keys.d.ts +17 -0
- package/dist/src/server/remote-config-keys.js +27 -0
- package/dist/src/server/remote-control-constants.d.ts +30 -0
- package/dist/src/server/remote-control-constants.js +29 -0
- package/dist/src/server/remote-device-session.d.ts +40 -0
- package/dist/src/server/remote-device-session.js +22 -0
- package/dist/src/server/remote-device-store.d.ts +36 -0
- package/dist/src/server/remote-device-store.js +67 -0
- package/dist/src/server/remote-frame-bridge.d.ts +102 -0
- package/dist/src/server/remote-frame-bridge.js +791 -0
- package/dist/src/server/remote-gateway-client.d.ts +14 -0
- package/dist/src/server/remote-gateway-client.js +36 -0
- package/dist/src/server/remote-loopback-auth.d.ts +6 -0
- package/dist/src/server/remote-loopback-auth.js +112 -0
- package/dist/src/server/remote-pairing-tunnel.d.ts +59 -0
- package/dist/src/server/remote-pairing-tunnel.js +146 -0
- package/dist/src/server/remote-pairing.d.ts +58 -0
- package/dist/src/server/remote-pairing.js +237 -0
- package/dist/src/server/remote-tunnel.d.ts +113 -0
- package/dist/src/server/remote-tunnel.js +514 -0
- package/dist/src/server/report-outbox-store.d.ts +36 -0
- package/dist/src/server/report-outbox-store.js +33 -0
- package/dist/src/server/restart-policy-support.d.ts +30 -0
- package/dist/src/server/restart-policy-support.js +21 -0
- package/dist/src/server/restart-policy.d.ts +18 -0
- package/dist/src/server/restart-policy.js +77 -0
- package/dist/src/server/role-template-store.d.ts +45 -0
- package/dist/src/server/role-template-store.js +76 -0
- package/dist/src/server/role-templates.d.ts +7 -0
- package/dist/src/server/role-templates.js +54 -0
- package/dist/src/server/route-helpers.d.ts +9 -0
- package/dist/src/server/route-helpers.js +61 -0
- package/dist/src/server/route-types.d.ts +121 -0
- package/dist/src/server/route-types.js +1 -0
- package/dist/src/server/routes-dispatches.d.ts +2 -0
- package/dist/src/server/routes-dispatches.js +54 -0
- package/dist/src/server/routes-fs.d.ts +2 -0
- package/dist/src/server/routes-fs.js +24 -0
- package/dist/src/server/routes-marketplace.d.ts +2 -0
- package/dist/src/server/routes-marketplace.js +54 -0
- package/dist/src/server/routes-open-workspace.d.ts +2 -0
- package/dist/src/server/routes-open-workspace.js +47 -0
- package/dist/src/server/routes-remote.d.ts +2 -0
- package/dist/src/server/routes-remote.js +166 -0
- package/dist/src/server/routes-runtime.d.ts +2 -0
- package/dist/src/server/routes-runtime.js +79 -0
- package/dist/src/server/routes-settings.d.ts +2 -0
- package/dist/src/server/routes-settings.js +213 -0
- package/dist/src/server/routes-tasks.d.ts +2 -0
- package/dist/src/server/routes-tasks.js +47 -0
- package/dist/src/server/routes-team-memory.d.ts +2 -0
- package/dist/src/server/routes-team-memory.js +154 -0
- package/dist/src/server/routes-team-recall.d.ts +2 -0
- package/dist/src/server/routes-team-recall.js +119 -0
- package/dist/src/server/routes-team.d.ts +2 -0
- package/dist/src/server/routes-team.js +351 -0
- package/dist/src/server/routes-ui.d.ts +2 -0
- package/dist/src/server/routes-ui.js +17 -0
- package/dist/src/server/routes-version.d.ts +2 -0
- package/dist/src/server/routes-version.js +6 -0
- package/dist/src/server/routes-workflow-schedules.d.ts +2 -0
- package/dist/src/server/routes-workflow-schedules.js +58 -0
- package/dist/src/server/routes-workflows.d.ts +2 -0
- package/dist/src/server/routes-workflows.js +83 -0
- package/dist/src/server/routes-workspace-memory-dreams.d.ts +2 -0
- package/dist/src/server/routes-workspace-memory-dreams.js +105 -0
- package/dist/src/server/routes-workspace-memory.d.ts +2 -0
- package/dist/src/server/routes-workspace-memory.js +215 -0
- package/dist/src/server/routes-workspaces.d.ts +2 -0
- package/dist/src/server/routes-workspaces.js +177 -0
- package/dist/src/server/routes.d.ts +6 -0
- package/dist/src/server/routes.js +55 -0
- package/dist/src/server/runtime-database.d.ts +3 -0
- package/dist/src/server/runtime-database.js +41 -0
- package/dist/src/server/runtime-message-builders.d.ts +7 -0
- package/dist/src/server/runtime-message-builders.js +60 -0
- package/dist/src/server/runtime-restart-policy.d.ts +18 -0
- package/dist/src/server/runtime-restart-policy.js +12 -0
- package/dist/src/server/runtime-store-contract.d.ts +162 -0
- package/dist/src/server/runtime-store-contract.js +1 -0
- package/dist/src/server/runtime-store-dream.d.ts +23 -0
- package/dist/src/server/runtime-store-dream.js +16 -0
- package/dist/src/server/runtime-store-helpers.d.ts +115 -0
- package/dist/src/server/runtime-store-helpers.js +411 -0
- package/dist/src/server/runtime-store-memory.d.ts +33 -0
- package/dist/src/server/runtime-store-memory.js +37 -0
- package/dist/src/server/runtime-store-remote.d.ts +5 -0
- package/dist/src/server/runtime-store-remote.js +45 -0
- package/dist/src/server/runtime-store-workflows.d.ts +6 -0
- package/dist/src/server/runtime-store-workflows.js +108 -0
- package/dist/src/server/runtime-store.d.ts +4 -0
- package/dist/src/server/runtime-store.js +165 -0
- package/dist/src/server/session-capture-claude.d.ts +34 -0
- package/dist/src/server/session-capture-claude.js +103 -0
- package/dist/src/server/session-capture-codex.d.ts +6 -0
- package/dist/src/server/session-capture-codex.js +108 -0
- package/dist/src/server/session-capture-gemini.d.ts +5 -0
- package/dist/src/server/session-capture-gemini.js +81 -0
- package/dist/src/server/session-capture-opencode.d.ts +22 -0
- package/dist/src/server/session-capture-opencode.js +75 -0
- package/dist/src/server/session-capture.d.ts +77 -0
- package/dist/src/server/session-capture.js +123 -0
- package/dist/src/server/settings-store.d.ts +22 -0
- package/dist/src/server/settings-store.js +22 -0
- package/dist/src/server/sqlite-schema-v10.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v10.js +13 -0
- package/dist/src/server/sqlite-schema-v11.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v11.js +10 -0
- package/dist/src/server/sqlite-schema-v12.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v12.js +21 -0
- package/dist/src/server/sqlite-schema-v13.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v13.js +4 -0
- package/dist/src/server/sqlite-schema-v14.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v14.js +84 -0
- package/dist/src/server/sqlite-schema-v15.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v15.js +73 -0
- package/dist/src/server/sqlite-schema-v16.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v16.js +6 -0
- package/dist/src/server/sqlite-schema-v17.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v17.js +15 -0
- package/dist/src/server/sqlite-schema-v18.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v18.js +6 -0
- package/dist/src/server/sqlite-schema-v19.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v19.js +17 -0
- package/dist/src/server/sqlite-schema-v20.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v20.js +20 -0
- package/dist/src/server/sqlite-schema-v21.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v21.js +20 -0
- package/dist/src/server/sqlite-schema-v22.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v22.js +27 -0
- package/dist/src/server/sqlite-schema-v23.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v23.js +43 -0
- package/dist/src/server/sqlite-schema-v24.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v24.js +34 -0
- package/dist/src/server/sqlite-schema-v25.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v25.js +127 -0
- package/dist/src/server/sqlite-schema-v26.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v26.js +56 -0
- package/dist/src/server/sqlite-schema-v27.d.ts +6 -0
- package/dist/src/server/sqlite-schema-v27.js +92 -0
- package/dist/src/server/sqlite-schema-v28.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v28.js +19 -0
- package/dist/src/server/sqlite-schema-v5.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v5.js +61 -0
- package/dist/src/server/sqlite-schema-v7.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v7.js +70 -0
- package/dist/src/server/sqlite-schema-v8.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v8.js +6 -0
- package/dist/src/server/sqlite-schema-v9.d.ts +2 -0
- package/dist/src/server/sqlite-schema-v9.js +6 -0
- package/dist/src/server/sqlite-schema.d.ts +3 -0
- package/dist/src/server/sqlite-schema.js +353 -0
- package/dist/src/server/startup-command-parser.d.ts +20 -0
- package/dist/src/server/startup-command-parser.js +72 -0
- package/dist/src/server/system-message.d.ts +8 -0
- package/dist/src/server/system-message.js +8 -0
- package/dist/src/server/task-deps.d.ts +32 -0
- package/dist/src/server/task-deps.js +40 -0
- package/dist/src/server/tasks-file-watcher.d.ts +47 -0
- package/dist/src/server/tasks-file-watcher.js +200 -0
- package/dist/src/server/tasks-file.d.ts +23 -0
- package/dist/src/server/tasks-file.js +101 -0
- package/dist/src/server/tasks-websocket-server.d.ts +8 -0
- package/dist/src/server/tasks-websocket-server.js +95 -0
- package/dist/src/server/team-authz.d.ts +13 -0
- package/dist/src/server/team-authz.js +53 -0
- package/dist/src/server/team-autostaff.d.ts +16 -0
- package/dist/src/server/team-autostaff.js +16 -0
- package/dist/src/server/team-list-enrichment.d.ts +22 -0
- package/dist/src/server/team-list-enrichment.js +40 -0
- package/dist/src/server/team-list-serializer.d.ts +2 -0
- package/dist/src/server/team-list-serializer.js +11 -0
- package/dist/src/server/team-memory-digest.d.ts +52 -0
- package/dist/src/server/team-memory-digest.js +200 -0
- package/dist/src/server/team-memory-dream-applier.d.ts +5 -0
- package/dist/src/server/team-memory-dream-applier.js +234 -0
- package/dist/src/server/team-memory-dream-http-serializers.d.ts +13 -0
- package/dist/src/server/team-memory-dream-http-serializers.js +12 -0
- package/dist/src/server/team-memory-dream-ops.d.ts +40 -0
- package/dist/src/server/team-memory-dream-ops.js +153 -0
- package/dist/src/server/team-memory-dream-reverter.d.ts +22 -0
- package/dist/src/server/team-memory-dream-reverter.js +221 -0
- package/dist/src/server/team-memory-dream-run-store.d.ts +23 -0
- package/dist/src/server/team-memory-dream-run-store.js +211 -0
- package/dist/src/server/team-memory-dream-runner.d.ts +37 -0
- package/dist/src/server/team-memory-dream-runner.js +178 -0
- package/dist/src/server/team-memory-dream-scheduler.d.ts +32 -0
- package/dist/src/server/team-memory-dream-scheduler.js +115 -0
- package/dist/src/server/team-memory-dream-store.d.ts +19 -0
- package/dist/src/server/team-memory-dream-store.js +16 -0
- package/dist/src/server/team-memory-dream-types.d.ts +104 -0
- package/dist/src/server/team-memory-dream-types.js +23 -0
- package/dist/src/server/team-memory-export.d.ts +22 -0
- package/dist/src/server/team-memory-export.js +220 -0
- package/dist/src/server/team-memory-feature.d.ts +12 -0
- package/dist/src/server/team-memory-feature.js +12 -0
- package/dist/src/server/team-memory-http-serializers.d.ts +102 -0
- package/dist/src/server/team-memory-http-serializers.js +46 -0
- package/dist/src/server/team-memory-injection.d.ts +31 -0
- package/dist/src/server/team-memory-injection.js +49 -0
- package/dist/src/server/team-memory-store.d.ts +116 -0
- package/dist/src/server/team-memory-store.js +513 -0
- package/dist/src/server/team-operations.d.ts +102 -0
- package/dist/src/server/team-operations.js +387 -0
- package/dist/src/server/team-recall-store.d.ts +38 -0
- package/dist/src/server/team-recall-store.js +205 -0
- package/dist/src/server/terminal-flow-control.d.ts +19 -0
- package/dist/src/server/terminal-flow-control.js +116 -0
- package/dist/src/server/terminal-input-profile.d.ts +10 -0
- package/dist/src/server/terminal-input-profile.js +9 -0
- package/dist/src/server/terminal-protocol.d.ts +29 -0
- package/dist/src/server/terminal-protocol.js +47 -0
- package/dist/src/server/terminal-state-mirror.d.ts +21 -0
- package/dist/src/server/terminal-state-mirror.js +67 -0
- package/dist/src/server/terminal-stream-hub.d.ts +9 -0
- package/dist/src/server/terminal-stream-hub.js +192 -0
- package/dist/src/server/terminal-ws-server.d.ts +6 -0
- package/dist/src/server/terminal-ws-server.js +115 -0
- package/dist/src/server/ui-auth-helpers.d.ts +4 -0
- package/dist/src/server/ui-auth-helpers.js +28 -0
- package/dist/src/server/ui-auth.d.ts +8 -0
- package/dist/src/server/ui-auth.js +32 -0
- package/dist/src/server/version-service.d.ts +16 -0
- package/dist/src/server/version-service.js +72 -0
- package/dist/src/server/webhook-notifier.d.ts +34 -0
- package/dist/src/server/webhook-notifier.js +47 -0
- package/dist/src/server/websocket-upgrade-safety.d.ts +10 -0
- package/dist/src/server/websocket-upgrade-safety.js +35 -0
- package/dist/src/server/windows-command-line.d.ts +3 -0
- package/dist/src/server/windows-command-line.js +9 -0
- package/dist/src/server/windows-filename.d.ts +2 -0
- package/dist/src/server/windows-filename.js +33 -0
- package/dist/src/server/worker-output-tracker.d.ts +14 -0
- package/dist/src/server/worker-output-tracker.js +50 -0
- package/dist/src/server/workflow-cli-policy.d.ts +60 -0
- package/dist/src/server/workflow-cli-policy.js +110 -0
- package/dist/src/server/workflow-dispatch-awaiter.d.ts +12 -0
- package/dist/src/server/workflow-dispatch-awaiter.js +80 -0
- package/dist/src/server/workflow-feature.d.ts +15 -0
- package/dist/src/server/workflow-feature.js +15 -0
- package/dist/src/server/workflow-http-serializers.d.ts +64 -0
- package/dist/src/server/workflow-http-serializers.js +58 -0
- package/dist/src/server/workflow-output-schema.d.ts +18 -0
- package/dist/src/server/workflow-output-schema.js +41 -0
- package/dist/src/server/workflow-run-log-store.d.ts +19 -0
- package/dist/src/server/workflow-run-log-store.js +45 -0
- package/dist/src/server/workflow-run-store.d.ts +50 -0
- package/dist/src/server/workflow-run-store.js +103 -0
- package/dist/src/server/workflow-runner.d.ts +147 -0
- package/dist/src/server/workflow-runner.js +411 -0
- package/dist/src/server/workflow-schedule-create.d.ts +14 -0
- package/dist/src/server/workflow-schedule-create.js +41 -0
- package/dist/src/server/workflow-schedule-store.d.ts +43 -0
- package/dist/src/server/workflow-schedule-store.js +112 -0
- package/dist/src/server/workflow-scheduler.d.ts +36 -0
- package/dist/src/server/workflow-scheduler.js +97 -0
- package/dist/src/server/workflow-script-loader.d.ts +34 -0
- package/dist/src/server/workflow-script-loader.js +106 -0
- package/dist/src/server/workspace-path-validation.d.ts +1 -0
- package/dist/src/server/workspace-path-validation.js +42 -0
- package/dist/src/server/workspace-shell-runtime.d.ts +35 -0
- package/dist/src/server/workspace-shell-runtime.js +228 -0
- package/dist/src/server/workspace-store-contract.d.ts +32 -0
- package/dist/src/server/workspace-store-contract.js +1 -0
- package/dist/src/server/workspace-store-hydration.d.ts +5 -0
- package/dist/src/server/workspace-store-hydration.js +76 -0
- package/dist/src/server/workspace-store-mutations.d.ts +14 -0
- package/dist/src/server/workspace-store-mutations.js +48 -0
- package/dist/src/server/workspace-store-support.d.ts +33 -0
- package/dist/src/server/workspace-store-support.js +36 -0
- package/dist/src/server/workspace-store.d.ts +5 -0
- package/dist/src/server/workspace-store.js +153 -0
- package/dist/src/shared/fs-browse.d.ts +1 -0
- package/dist/src/shared/fs-browse.js +1 -0
- package/dist/src/shared/open-targets.d.ts +20 -0
- package/dist/src/shared/open-targets.js +36 -0
- package/dist/src/shared/path-input.d.ts +12 -0
- package/dist/src/shared/path-input.js +22 -0
- package/dist/src/shared/remote-bridge-routing.d.ts +19 -0
- package/dist/src/shared/remote-bridge-routing.js +141 -0
- package/dist/src/shared/remote-crypto.d.ts +138 -0
- package/dist/src/shared/remote-crypto.js +427 -0
- package/dist/src/shared/remote-pairing-code.d.ts +7 -0
- package/dist/src/shared/remote-pairing-code.js +47 -0
- package/dist/src/shared/remote-protocol.d.ts +160 -0
- package/dist/src/shared/remote-protocol.js +526 -0
- package/dist/src/shared/team-memory.d.ts +11 -0
- package/dist/src/shared/team-memory.js +10 -0
- package/dist/src/shared/team-recall.d.ts +1 -0
- package/dist/src/shared/team-recall.js +1 -0
- package/dist/src/shared/types.d.ts +66 -0
- package/dist/src/shared/types.js +1 -0
- package/dist/vendor/marketplace/en/LICENSE +21 -0
- package/dist/vendor/marketplace/en/SOURCES.md +12 -0
- package/dist/vendor/marketplace/en/academic/academic-anthropologist.md +125 -0
- package/dist/vendor/marketplace/en/academic/academic-geographer.md +127 -0
- package/dist/vendor/marketplace/en/academic/academic-historian.md +123 -0
- package/dist/vendor/marketplace/en/academic/academic-narratologist.md +118 -0
- package/dist/vendor/marketplace/en/academic/academic-psychologist.md +118 -0
- package/dist/vendor/marketplace/en/design/design-brand-guardian.md +322 -0
- package/dist/vendor/marketplace/en/design/design-image-prompt-engineer.md +236 -0
- package/dist/vendor/marketplace/en/design/design-inclusive-visuals-specialist.md +71 -0
- package/dist/vendor/marketplace/en/design/design-ui-designer.md +383 -0
- package/dist/vendor/marketplace/en/design/design-ux-architect.md +469 -0
- package/dist/vendor/marketplace/en/design/design-ux-researcher.md +329 -0
- package/dist/vendor/marketplace/en/design/design-visual-storyteller.md +149 -0
- package/dist/vendor/marketplace/en/design/design-whimsy-injector.md +438 -0
- package/dist/vendor/marketplace/en/engineering/engineering-ai-data-remediation-engineer.md +211 -0
- package/dist/vendor/marketplace/en/engineering/engineering-ai-engineer.md +146 -0
- package/dist/vendor/marketplace/en/engineering/engineering-autonomous-optimization-architect.md +107 -0
- package/dist/vendor/marketplace/en/engineering/engineering-backend-architect.md +235 -0
- package/dist/vendor/marketplace/en/engineering/engineering-cms-developer.md +536 -0
- package/dist/vendor/marketplace/en/engineering/engineering-code-reviewer.md +76 -0
- package/dist/vendor/marketplace/en/engineering/engineering-codebase-onboarding-engineer.md +173 -0
- package/dist/vendor/marketplace/en/engineering/engineering-data-engineer.md +306 -0
- package/dist/vendor/marketplace/en/engineering/engineering-database-optimizer.md +176 -0
- package/dist/vendor/marketplace/en/engineering/engineering-devops-automator.md +376 -0
- package/dist/vendor/marketplace/en/engineering/engineering-email-intelligence-engineer.md +353 -0
- package/dist/vendor/marketplace/en/engineering/engineering-embedded-firmware-engineer.md +173 -0
- package/dist/vendor/marketplace/en/engineering/engineering-feishu-integration-developer.md +598 -0
- package/dist/vendor/marketplace/en/engineering/engineering-filament-optimization-specialist.md +283 -0
- package/dist/vendor/marketplace/en/engineering/engineering-frontend-developer.md +225 -0
- package/dist/vendor/marketplace/en/engineering/engineering-git-workflow-master.md +84 -0
- package/dist/vendor/marketplace/en/engineering/engineering-incident-response-commander.md +444 -0
- package/dist/vendor/marketplace/en/engineering/engineering-minimal-change-engineer.md +207 -0
- package/dist/vendor/marketplace/en/engineering/engineering-mobile-app-builder.md +493 -0
- package/dist/vendor/marketplace/en/engineering/engineering-rapid-prototyper.md +462 -0
- package/dist/vendor/marketplace/en/engineering/engineering-security-engineer.md +304 -0
- package/dist/vendor/marketplace/en/engineering/engineering-senior-developer.md +176 -0
- package/dist/vendor/marketplace/en/engineering/engineering-software-architect.md +81 -0
- package/dist/vendor/marketplace/en/engineering/engineering-solidity-smart-contract-engineer.md +522 -0
- package/dist/vendor/marketplace/en/engineering/engineering-sre.md +90 -0
- package/dist/vendor/marketplace/en/engineering/engineering-technical-writer.md +393 -0
- package/dist/vendor/marketplace/en/engineering/engineering-threat-detection-engineer.md +534 -0
- package/dist/vendor/marketplace/en/engineering/engineering-voice-ai-integration-engineer.md +561 -0
- package/dist/vendor/marketplace/en/engineering/engineering-wechat-mini-program-developer.md +350 -0
- package/dist/vendor/marketplace/en/finance/finance-bookkeeper-controller.md +260 -0
- package/dist/vendor/marketplace/en/finance/finance-financial-analyst.md +234 -0
- package/dist/vendor/marketplace/en/finance/finance-fpa-analyst.md +263 -0
- package/dist/vendor/marketplace/en/finance/finance-investment-researcher.md +272 -0
- package/dist/vendor/marketplace/en/finance/finance-tax-strategist.md +239 -0
- package/dist/vendor/marketplace/en/game-development/blender/blender-addon-engineer.md +234 -0
- package/dist/vendor/marketplace/en/game-development/game-audio-engineer.md +264 -0
- package/dist/vendor/marketplace/en/game-development/game-designer.md +167 -0
- package/dist/vendor/marketplace/en/game-development/godot/godot-gameplay-scripter.md +334 -0
- package/dist/vendor/marketplace/en/game-development/godot/godot-multiplayer-engineer.md +297 -0
- package/dist/vendor/marketplace/en/game-development/godot/godot-shader-developer.md +266 -0
- package/dist/vendor/marketplace/en/game-development/level-designer.md +208 -0
- package/dist/vendor/marketplace/en/game-development/narrative-designer.md +243 -0
- package/dist/vendor/marketplace/en/game-development/roblox-studio/roblox-avatar-creator.md +297 -0
- package/dist/vendor/marketplace/en/game-development/roblox-studio/roblox-experience-designer.md +305 -0
- package/dist/vendor/marketplace/en/game-development/roblox-studio/roblox-systems-scripter.md +325 -0
- package/dist/vendor/marketplace/en/game-development/technical-artist.md +229 -0
- package/dist/vendor/marketplace/en/game-development/unity/unity-architect.md +271 -0
- package/dist/vendor/marketplace/en/game-development/unity/unity-editor-tool-developer.md +310 -0
- package/dist/vendor/marketplace/en/game-development/unity/unity-multiplayer-engineer.md +321 -0
- package/dist/vendor/marketplace/en/game-development/unity/unity-shader-graph-artist.md +269 -0
- package/dist/vendor/marketplace/en/game-development/unreal-engine/unreal-multiplayer-architect.md +313 -0
- package/dist/vendor/marketplace/en/game-development/unreal-engine/unreal-systems-engineer.md +310 -0
- package/dist/vendor/marketplace/en/game-development/unreal-engine/unreal-technical-artist.md +256 -0
- package/dist/vendor/marketplace/en/game-development/unreal-engine/unreal-world-builder.md +273 -0
- package/dist/vendor/marketplace/en/integrations/mcp-memory/backend-architect-with-memory.md +247 -0
- package/dist/vendor/marketplace/en/manifest.json +1869 -0
- package/dist/vendor/marketplace/en/marketing/marketing-agentic-search-optimizer.md +311 -0
- package/dist/vendor/marketplace/en/marketing/marketing-ai-citation-strategist.md +170 -0
- package/dist/vendor/marketplace/en/marketing/marketing-app-store-optimizer.md +321 -0
- package/dist/vendor/marketplace/en/marketing/marketing-baidu-seo-specialist.md +226 -0
- package/dist/vendor/marketplace/en/marketing/marketing-bilibili-content-strategist.md +199 -0
- package/dist/vendor/marketplace/en/marketing/marketing-book-co-author.md +110 -0
- package/dist/vendor/marketplace/en/marketing/marketing-carousel-growth-engine.md +199 -0
- package/dist/vendor/marketplace/en/marketing/marketing-china-ecommerce-operator.md +283 -0
- package/dist/vendor/marketplace/en/marketing/marketing-china-market-localization-strategist.md +283 -0
- package/dist/vendor/marketplace/en/marketing/marketing-content-creator.md +54 -0
- package/dist/vendor/marketplace/en/marketing/marketing-cross-border-ecommerce.md +259 -0
- package/dist/vendor/marketplace/en/marketing/marketing-douyin-strategist.md +149 -0
- package/dist/vendor/marketplace/en/marketing/marketing-growth-hacker.md +54 -0
- package/dist/vendor/marketplace/en/marketing/marketing-instagram-curator.md +113 -0
- package/dist/vendor/marketplace/en/marketing/marketing-kuaishou-strategist.md +223 -0
- package/dist/vendor/marketplace/en/marketing/marketing-linkedin-content-creator.md +214 -0
- package/dist/vendor/marketplace/en/marketing/marketing-livestream-commerce-coach.md +305 -0
- package/dist/vendor/marketplace/en/marketing/marketing-podcast-strategist.md +277 -0
- package/dist/vendor/marketplace/en/marketing/marketing-private-domain-operator.md +308 -0
- package/dist/vendor/marketplace/en/marketing/marketing-reddit-community-builder.md +123 -0
- package/dist/vendor/marketplace/en/marketing/marketing-seo-specialist.md +321 -0
- package/dist/vendor/marketplace/en/marketing/marketing-short-video-editing-coach.md +412 -0
- package/dist/vendor/marketplace/en/marketing/marketing-social-media-strategist.md +125 -0
- package/dist/vendor/marketplace/en/marketing/marketing-tiktok-strategist.md +125 -0
- package/dist/vendor/marketplace/en/marketing/marketing-twitter-engager.md +126 -0
- package/dist/vendor/marketplace/en/marketing/marketing-video-optimization-specialist.md +119 -0
- package/dist/vendor/marketplace/en/marketing/marketing-wechat-official-account.md +145 -0
- package/dist/vendor/marketplace/en/marketing/marketing-weibo-strategist.md +240 -0
- package/dist/vendor/marketplace/en/marketing/marketing-xiaohongshu-specialist.md +138 -0
- package/dist/vendor/marketplace/en/marketing/marketing-zhihu-strategist.md +162 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-auditor.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-creative-strategist.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-paid-social-strategist.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-ppc-strategist.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-programmatic-buyer.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-search-query-analyst.md +71 -0
- package/dist/vendor/marketplace/en/paid-media/paid-media-tracking-specialist.md +71 -0
- package/dist/vendor/marketplace/en/product/product-behavioral-nudge-engine.md +80 -0
- package/dist/vendor/marketplace/en/product/product-feedback-synthesizer.md +119 -0
- package/dist/vendor/marketplace/en/product/product-manager.md +469 -0
- package/dist/vendor/marketplace/en/product/product-sprint-prioritizer.md +154 -0
- package/dist/vendor/marketplace/en/product/product-trend-researcher.md +159 -0
- package/dist/vendor/marketplace/en/project-management/project-management-experiment-tracker.md +198 -0
- package/dist/vendor/marketplace/en/project-management/project-management-jira-workflow-steward.md +230 -0
- package/dist/vendor/marketplace/en/project-management/project-management-project-shepherd.md +194 -0
- package/dist/vendor/marketplace/en/project-management/project-management-studio-operations.md +200 -0
- package/dist/vendor/marketplace/en/project-management/project-management-studio-producer.md +203 -0
- package/dist/vendor/marketplace/en/project-management/project-manager-senior.md +135 -0
- package/dist/vendor/marketplace/en/sales/sales-account-strategist.md +227 -0
- package/dist/vendor/marketplace/en/sales/sales-coach.md +271 -0
- package/dist/vendor/marketplace/en/sales/sales-deal-strategist.md +180 -0
- package/dist/vendor/marketplace/en/sales/sales-discovery-coach.md +225 -0
- package/dist/vendor/marketplace/en/sales/sales-engineer.md +182 -0
- package/dist/vendor/marketplace/en/sales/sales-outbound-strategist.md +201 -0
- package/dist/vendor/marketplace/en/sales/sales-pipeline-analyst.md +267 -0
- package/dist/vendor/marketplace/en/sales/sales-proposal-strategist.md +217 -0
- package/dist/vendor/marketplace/en/spatial-computing/macos-spatial-metal-engineer.md +337 -0
- package/dist/vendor/marketplace/en/spatial-computing/terminal-integration-specialist.md +70 -0
- package/dist/vendor/marketplace/en/spatial-computing/visionos-spatial-engineer.md +54 -0
- package/dist/vendor/marketplace/en/spatial-computing/xr-cockpit-interaction-specialist.md +32 -0
- package/dist/vendor/marketplace/en/spatial-computing/xr-immersive-developer.md +32 -0
- package/dist/vendor/marketplace/en/spatial-computing/xr-interface-architect.md +32 -0
- package/dist/vendor/marketplace/en/specialized/accounts-payable-agent.md +185 -0
- package/dist/vendor/marketplace/en/specialized/agentic-identity-trust.md +387 -0
- package/dist/vendor/marketplace/en/specialized/agents-orchestrator.md +367 -0
- package/dist/vendor/marketplace/en/specialized/automation-governance-architect.md +216 -0
- package/dist/vendor/marketplace/en/specialized/blockchain-security-auditor.md +463 -0
- package/dist/vendor/marketplace/en/specialized/compliance-auditor.md +158 -0
- package/dist/vendor/marketplace/en/specialized/corporate-training-designer.md +192 -0
- package/dist/vendor/marketplace/en/specialized/customer-service.md +398 -0
- package/dist/vendor/marketplace/en/specialized/data-consolidation-agent.md +60 -0
- package/dist/vendor/marketplace/en/specialized/government-digital-presales-consultant.md +363 -0
- package/dist/vendor/marketplace/en/specialized/healthcare-customer-service.md +389 -0
- package/dist/vendor/marketplace/en/specialized/healthcare-marketing-compliance.md +395 -0
- package/dist/vendor/marketplace/en/specialized/hospitality-guest-services.md +603 -0
- package/dist/vendor/marketplace/en/specialized/hr-onboarding.md +451 -0
- package/dist/vendor/marketplace/en/specialized/identity-graph-operator.md +260 -0
- package/dist/vendor/marketplace/en/specialized/language-translator.md +264 -0
- package/dist/vendor/marketplace/en/specialized/legal-billing-time-tracking.md +569 -0
- package/dist/vendor/marketplace/en/specialized/legal-client-intake.md +492 -0
- package/dist/vendor/marketplace/en/specialized/legal-document-review.md +454 -0
- package/dist/vendor/marketplace/en/specialized/loan-officer-assistant.md +555 -0
- package/dist/vendor/marketplace/en/specialized/lsp-index-engineer.md +314 -0
- package/dist/vendor/marketplace/en/specialized/real-estate-buyer-seller.md +596 -0
- package/dist/vendor/marketplace/en/specialized/recruitment-specialist.md +509 -0
- package/dist/vendor/marketplace/en/specialized/report-distribution-agent.md +65 -0
- package/dist/vendor/marketplace/en/specialized/retail-customer-returns.md +566 -0
- package/dist/vendor/marketplace/en/specialized/sales-data-extraction-agent.md +67 -0
- package/dist/vendor/marketplace/en/specialized/sales-outreach.md +425 -0
- package/dist/vendor/marketplace/en/specialized/specialized-chief-of-staff.md +279 -0
- package/dist/vendor/marketplace/en/specialized/specialized-civil-engineer.md +356 -0
- package/dist/vendor/marketplace/en/specialized/specialized-cultural-intelligence-strategist.md +88 -0
- package/dist/vendor/marketplace/en/specialized/specialized-developer-advocate.md +317 -0
- package/dist/vendor/marketplace/en/specialized/specialized-document-generator.md +55 -0
- package/dist/vendor/marketplace/en/specialized/specialized-french-consulting-market.md +192 -0
- package/dist/vendor/marketplace/en/specialized/specialized-korean-business-navigator.md +216 -0
- package/dist/vendor/marketplace/en/specialized/specialized-mcp-builder.md +248 -0
- package/dist/vendor/marketplace/en/specialized/specialized-model-qa.md +488 -0
- package/dist/vendor/marketplace/en/specialized/specialized-salesforce-architect.md +180 -0
- package/dist/vendor/marketplace/en/specialized/specialized-workflow-architect.md +597 -0
- package/dist/vendor/marketplace/en/specialized/study-abroad-advisor.md +282 -0
- package/dist/vendor/marketplace/en/specialized/supply-chain-strategist.md +582 -0
- package/dist/vendor/marketplace/en/support/support-analytics-reporter.md +365 -0
- package/dist/vendor/marketplace/en/support/support-executive-summary-generator.md +212 -0
- package/dist/vendor/marketplace/en/support/support-finance-tracker.md +442 -0
- package/dist/vendor/marketplace/en/support/support-infrastructure-maintainer.md +618 -0
- package/dist/vendor/marketplace/en/support/support-legal-compliance-checker.md +588 -0
- package/dist/vendor/marketplace/en/support/support-support-responder.md +585 -0
- package/dist/vendor/marketplace/en/testing/testing-accessibility-auditor.md +316 -0
- package/dist/vendor/marketplace/en/testing/testing-api-tester.md +306 -0
- package/dist/vendor/marketplace/en/testing/testing-evidence-collector.md +210 -0
- package/dist/vendor/marketplace/en/testing/testing-performance-benchmarker.md +268 -0
- package/dist/vendor/marketplace/en/testing/testing-reality-checker.md +236 -0
- package/dist/vendor/marketplace/en/testing/testing-test-results-analyzer.md +305 -0
- package/dist/vendor/marketplace/en/testing/testing-tool-evaluator.md +394 -0
- package/dist/vendor/marketplace/en/testing/testing-workflow-optimizer.md +450 -0
- package/dist/vendor/marketplace/zh/LICENSE +22 -0
- package/dist/vendor/marketplace/zh/SOURCES.md +12 -0
- package/dist/vendor/marketplace/zh/academic/academic-anthropologist.md +124 -0
- package/dist/vendor/marketplace/zh/academic/academic-geographer.md +126 -0
- package/dist/vendor/marketplace/zh/academic/academic-historian.md +122 -0
- package/dist/vendor/marketplace/zh/academic/academic-narratologist.md +117 -0
- package/dist/vendor/marketplace/zh/academic/academic-psychologist.md +117 -0
- package/dist/vendor/marketplace/zh/academic/academic-study-planner.md +214 -0
- package/dist/vendor/marketplace/zh/design/design-brand-guardian.md +321 -0
- package/dist/vendor/marketplace/zh/design/design-image-prompt-engineer.md +255 -0
- package/dist/vendor/marketplace/zh/design/design-inclusive-visuals-specialist.md +177 -0
- package/dist/vendor/marketplace/zh/design/design-ui-designer.md +382 -0
- package/dist/vendor/marketplace/zh/design/design-ux-architect.md +482 -0
- package/dist/vendor/marketplace/zh/design/design-ux-researcher.md +328 -0
- package/dist/vendor/marketplace/zh/design/design-visual-storyteller.md +159 -0
- package/dist/vendor/marketplace/zh/design/design-whimsy-injector.md +453 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-ai-data-remediation-engineer.md +209 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-ai-engineer.md +161 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-autonomous-optimization-architect.md +115 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-backend-architect.md +234 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-cms-developer.md +534 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-code-reviewer.md +172 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-codebase-onboarding-engineer.md +172 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-data-engineer.md +324 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-database-optimizer.md +175 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-devops-automator.md +375 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-dingtalk-integration-developer.md +574 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-email-intelligence-engineer.md +349 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-embedded-firmware-engineer.md +168 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-embedded-linux-driver-engineer.md +255 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-feishu-integration-developer.md +597 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-filament-optimization-specialist.md +283 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-fpga-digital-design-engineer.md +227 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-frontend-developer.md +224 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-git-workflow-master.md +220 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-incident-response-commander.md +465 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-iot-solution-architect.md +220 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-mechanical-design-engineer.md +311 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-minimal-change-engineer.md +206 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-mobile-app-builder.md +434 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-pc-host-engineer.md +231 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-rapid-prototyper.md +461 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-security-engineer.md +303 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-senior-developer.md +177 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-software-architect.md +200 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-solidity-smart-contract-engineer.md +541 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-sre.md +233 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-technical-writer.md +409 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-threat-detection-engineer.md +553 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-voice-ai-integration-engineer.md +560 -0
- package/dist/vendor/marketplace/zh/engineering/engineering-wechat-mini-program-developer.md +288 -0
- package/dist/vendor/marketplace/zh/finance/finance-bookkeeper-controller.md +271 -0
- package/dist/vendor/marketplace/zh/finance/finance-financial-analyst.md +244 -0
- package/dist/vendor/marketplace/zh/finance/finance-financial-forecaster.md +213 -0
- package/dist/vendor/marketplace/zh/finance/finance-fpa-analyst.md +272 -0
- package/dist/vendor/marketplace/zh/finance/finance-fraud-detector.md +241 -0
- package/dist/vendor/marketplace/zh/finance/finance-investment-researcher.md +283 -0
- package/dist/vendor/marketplace/zh/finance/finance-invoice-manager.md +242 -0
- package/dist/vendor/marketplace/zh/finance/finance-tax-strategist.md +250 -0
- package/dist/vendor/marketplace/zh/game-development/blender/blender-addon-engineer.md +233 -0
- package/dist/vendor/marketplace/zh/game-development/game-audio-engineer.md +265 -0
- package/dist/vendor/marketplace/zh/game-development/game-designer.md +168 -0
- package/dist/vendor/marketplace/zh/game-development/godot/godot-gameplay-scripter.md +335 -0
- package/dist/vendor/marketplace/zh/game-development/godot/godot-multiplayer-engineer.md +296 -0
- package/dist/vendor/marketplace/zh/game-development/godot/godot-shader-developer.md +267 -0
- package/dist/vendor/marketplace/zh/game-development/level-designer.md +209 -0
- package/dist/vendor/marketplace/zh/game-development/narrative-designer.md +244 -0
- package/dist/vendor/marketplace/zh/game-development/roblox-studio/roblox-avatar-creator.md +298 -0
- package/dist/vendor/marketplace/zh/game-development/roblox-studio/roblox-experience-designer.md +306 -0
- package/dist/vendor/marketplace/zh/game-development/roblox-studio/roblox-systems-scripter.md +325 -0
- package/dist/vendor/marketplace/zh/game-development/technical-artist.md +230 -0
- package/dist/vendor/marketplace/zh/game-development/unity/unity-architect.md +272 -0
- package/dist/vendor/marketplace/zh/game-development/unity/unity-editor-tool-developer.md +300 -0
- package/dist/vendor/marketplace/zh/game-development/unity/unity-multiplayer-engineer.md +238 -0
- package/dist/vendor/marketplace/zh/game-development/unity/unity-shader-graph-artist.md +270 -0
- package/dist/vendor/marketplace/zh/game-development/unreal-engine/unreal-multiplayer-architect.md +314 -0
- package/dist/vendor/marketplace/zh/game-development/unreal-engine/unreal-systems-engineer.md +311 -0
- package/dist/vendor/marketplace/zh/game-development/unreal-engine/unreal-technical-artist.md +256 -0
- package/dist/vendor/marketplace/zh/game-development/unreal-engine/unreal-world-builder.md +274 -0
- package/dist/vendor/marketplace/zh/hr/hr-performance-reviewer.md +248 -0
- package/dist/vendor/marketplace/zh/hr/hr-recruiter.md +232 -0
- package/dist/vendor/marketplace/zh/legal/legal-contract-reviewer.md +240 -0
- package/dist/vendor/marketplace/zh/legal/legal-policy-writer.md +308 -0
- package/dist/vendor/marketplace/zh/manifest.json +2181 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-agentic-search-optimizer.md +312 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-ai-citation-strategist.md +169 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-app-store-optimizer.md +319 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-baidu-seo-specialist.md +220 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-bilibili-strategist.md +194 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-book-co-author.md +109 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-carousel-growth-engine.md +215 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-china-ecommerce-operator.md +277 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-china-market-localization-strategist.md +282 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-content-creator.md +145 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-cross-border-ecommerce.md +260 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-daily-news-briefing.md +303 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-douyin-strategist.md +150 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-ecommerce-operator.md +216 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-growth-hacker.md +121 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-instagram-curator.md +179 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-knowledge-commerce-strategist.md +384 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-kuaishou-strategist.md +182 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-linkedin-content-creator.md +232 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-livestream-commerce-coach.md +303 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-podcast-strategist.md +278 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-private-domain-operator.md +309 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-reddit-community-builder.md +127 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-seo-specialist.md +298 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-short-video-editing-coach.md +413 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-social-media-strategist.md +118 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-tiktok-strategist.md +124 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-twitter-engager.md +132 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-video-optimization-specialist.md +128 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-wechat-official-account.md +158 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-wechat-operator.md +156 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-weibo-strategist.md +241 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-weixin-channels-strategist.md +297 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-xiaohongshu-operator.md +139 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-xiaohongshu-specialist.md +151 -0
- package/dist/vendor/marketplace/zh/marketing/marketing-zhihu-strategist.md +175 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-auditor.md +170 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-creative-strategist.md +173 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-paid-social-strategist.md +180 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-ppc-strategist.md +180 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-programmatic-buyer.md +177 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-search-query-analyst.md +182 -0
- package/dist/vendor/marketplace/zh/paid-media/paid-media-tracking-specialist.md +199 -0
- package/dist/vendor/marketplace/zh/product/product-behavioral-nudge-engine.md +246 -0
- package/dist/vendor/marketplace/zh/product/product-feedback-synthesizer.md +175 -0
- package/dist/vendor/marketplace/zh/product/product-manager.md +474 -0
- package/dist/vendor/marketplace/zh/product/product-sprint-prioritizer.md +133 -0
- package/dist/vendor/marketplace/zh/product/product-trend-researcher.md +143 -0
- package/dist/vendor/marketplace/zh/project-management/project-management-experiment-tracker.md +206 -0
- package/dist/vendor/marketplace/zh/project-management/project-management-jira-workflow-steward.md +249 -0
- package/dist/vendor/marketplace/zh/project-management/project-management-project-shepherd.md +202 -0
- package/dist/vendor/marketplace/zh/project-management/project-management-studio-operations.md +208 -0
- package/dist/vendor/marketplace/zh/project-management/project-management-studio-producer.md +211 -0
- package/dist/vendor/marketplace/zh/project-management/project-manager-senior.md +135 -0
- package/dist/vendor/marketplace/zh/sales/sales-account-strategist.md +243 -0
- package/dist/vendor/marketplace/zh/sales/sales-coach.md +291 -0
- package/dist/vendor/marketplace/zh/sales/sales-deal-strategist.md +204 -0
- package/dist/vendor/marketplace/zh/sales/sales-discovery-coach.md +230 -0
- package/dist/vendor/marketplace/zh/sales/sales-engineer.md +200 -0
- package/dist/vendor/marketplace/zh/sales/sales-outbound-strategist.md +208 -0
- package/dist/vendor/marketplace/zh/sales/sales-pipeline-analyst.md +284 -0
- package/dist/vendor/marketplace/zh/sales/sales-proposal-strategist.md +233 -0
- package/dist/vendor/marketplace/zh/spatial-computing/macos-spatial-metal-engineer.md +337 -0
- package/dist/vendor/marketplace/zh/spatial-computing/terminal-integration-specialist.md +236 -0
- package/dist/vendor/marketplace/zh/spatial-computing/visionos-spatial-engineer.md +282 -0
- package/dist/vendor/marketplace/zh/spatial-computing/xr-cockpit-interaction-specialist.md +220 -0
- package/dist/vendor/marketplace/zh/spatial-computing/xr-immersive-developer.md +229 -0
- package/dist/vendor/marketplace/zh/spatial-computing/xr-interface-architect.md +253 -0
- package/dist/vendor/marketplace/zh/specialized/accounts-payable-agent.md +212 -0
- package/dist/vendor/marketplace/zh/specialized/agentic-identity-trust.md +388 -0
- package/dist/vendor/marketplace/zh/specialized/agents-orchestrator.md +366 -0
- package/dist/vendor/marketplace/zh/specialized/automation-governance-architect.md +215 -0
- package/dist/vendor/marketplace/zh/specialized/blockchain-security-auditor.md +484 -0
- package/dist/vendor/marketplace/zh/specialized/compliance-auditor.md +172 -0
- package/dist/vendor/marketplace/zh/specialized/corporate-training-designer.md +191 -0
- package/dist/vendor/marketplace/zh/specialized/data-consolidation-agent.md +327 -0
- package/dist/vendor/marketplace/zh/specialized/gaokao-college-advisor.md +333 -0
- package/dist/vendor/marketplace/zh/specialized/government-digital-presales-consultant.md +362 -0
- package/dist/vendor/marketplace/zh/specialized/healthcare-customer-service.md +388 -0
- package/dist/vendor/marketplace/zh/specialized/healthcare-marketing-compliance.md +394 -0
- package/dist/vendor/marketplace/zh/specialized/hospitality-guest-services.md +597 -0
- package/dist/vendor/marketplace/zh/specialized/hr-onboarding.md +450 -0
- package/dist/vendor/marketplace/zh/specialized/identity-graph-operator.md +270 -0
- package/dist/vendor/marketplace/zh/specialized/language-translator.md +275 -0
- package/dist/vendor/marketplace/zh/specialized/legal-billing-time-tracking.md +566 -0
- package/dist/vendor/marketplace/zh/specialized/legal-client-intake.md +487 -0
- package/dist/vendor/marketplace/zh/specialized/legal-document-review.md +452 -0
- package/dist/vendor/marketplace/zh/specialized/livestock-archive-auditor.md +135 -0
- package/dist/vendor/marketplace/zh/specialized/loan-officer-assistant.md +549 -0
- package/dist/vendor/marketplace/zh/specialized/lsp-index-engineer.md +334 -0
- package/dist/vendor/marketplace/zh/specialized/prompt-engineer.md +176 -0
- package/dist/vendor/marketplace/zh/specialized/real-estate-buyer-seller.md +594 -0
- package/dist/vendor/marketplace/zh/specialized/recruitment-specialist.md +508 -0
- package/dist/vendor/marketplace/zh/specialized/report-distribution-agent.md +354 -0
- package/dist/vendor/marketplace/zh/specialized/retail-customer-returns.md +564 -0
- package/dist/vendor/marketplace/zh/specialized/sales-data-extraction-agent.md +159 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-ai-policy-writer.md +217 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-chief-of-staff.md +278 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-civil-engineer.md +355 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-cultural-intelligence-strategist.md +168 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-developer-advocate.md +334 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-document-generator.md +346 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-french-consulting-market.md +191 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-korean-business-navigator.md +215 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-mcp-builder.md +351 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-meeting-assistant.md +236 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-model-qa.md +507 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-pricing-optimizer.md +254 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-risk-assessor.md +240 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-salesforce-architect.md +179 -0
- package/dist/vendor/marketplace/zh/specialized/specialized-workflow-architect.md +596 -0
- package/dist/vendor/marketplace/zh/specialized/study-abroad-advisor.md +281 -0
- package/dist/vendor/marketplace/zh/specialized/technical-translator-agent.md +167 -0
- package/dist/vendor/marketplace/zh/specialized/zk-steward.md +228 -0
- package/dist/vendor/marketplace/zh/supply-chain/supply-chain-inventory-forecaster.md +212 -0
- package/dist/vendor/marketplace/zh/supply-chain/supply-chain-route-optimizer.md +224 -0
- package/dist/vendor/marketplace/zh/supply-chain/supply-chain-strategist.md +581 -0
- package/dist/vendor/marketplace/zh/supply-chain/supply-chain-vendor-evaluator.md +232 -0
- package/dist/vendor/marketplace/zh/support/support-analytics-reporter.md +364 -0
- package/dist/vendor/marketplace/zh/support/support-executive-summary-generator.md +217 -0
- package/dist/vendor/marketplace/zh/support/support-finance-tracker.md +447 -0
- package/dist/vendor/marketplace/zh/support/support-infrastructure-maintainer.md +623 -0
- package/dist/vendor/marketplace/zh/support/support-legal-compliance-checker.md +587 -0
- package/dist/vendor/marketplace/zh/support/support-recruitment-specialist.md +508 -0
- package/dist/vendor/marketplace/zh/support/support-support-responder.md +584 -0
- package/dist/vendor/marketplace/zh/testing/testing-accessibility-auditor.md +329 -0
- package/dist/vendor/marketplace/zh/testing/testing-api-tester.md +305 -0
- package/dist/vendor/marketplace/zh/testing/testing-embedded-qa-engineer.md +258 -0
- package/dist/vendor/marketplace/zh/testing/testing-evidence-collector.md +153 -0
- package/dist/vendor/marketplace/zh/testing/testing-performance-benchmarker.md +196 -0
- package/dist/vendor/marketplace/zh/testing/testing-reality-checker.md +235 -0
- package/dist/vendor/marketplace/zh/testing/testing-test-results-analyzer.md +313 -0
- package/dist/vendor/marketplace/zh/testing/testing-tool-evaluator.md +402 -0
- package/dist/vendor/marketplace/zh/testing/testing-workflow-optimizer.md +458 -0
- package/package.json +131 -0
- package/scripts/postinstall-native-artifacts.mjs +113 -0
- package/web/dist/assets/AddWorkerDialog-BU2Fn-Mx.js +2 -0
- package/web/dist/assets/AddWorkspaceFlow-BV04MkRt.js +1 -0
- package/web/dist/assets/FirstRunWizard-DS4IYOrd.js +1 -0
- package/web/dist/assets/MarketplaceDrawer-CIQ2B6Fx.js +76 -0
- package/web/dist/assets/TaskGraphDrawer-BPMcRocd.js +1 -0
- package/web/dist/assets/WhatsNewDialog-DEgVY_LD.js +1 -0
- package/web/dist/assets/WorkerModal-DiCcTPpc.js +1 -0
- package/web/dist/assets/WorkflowsDrawer-M2CgAJWK.js +1 -0
- package/web/dist/assets/WorkspaceMemoryDrawer-ClJIqWck.js +1 -0
- package/web/dist/assets/WorkspaceTaskDrawer-gjvXuZ2K.js +1 -0
- package/web/dist/assets/addon-clipboard-wHJhZAA4.js +1 -0
- package/web/dist/assets/addon-fit-DX4qG4td.js +1 -0
- package/web/dist/assets/addon-unicode11-Bt8F3D7-.js +7 -0
- package/web/dist/assets/addon-web-links-DIbG5aQx.js +1 -0
- package/web/dist/assets/addon-webgl-DCtw1yLn.js +64 -0
- package/web/dist/assets/finder-C4Jmsb0B.png +0 -0
- package/web/dist/assets/ghostty-D-Js4rdm.png +0 -0
- package/web/dist/assets/index-bOMtwrkA.js +73 -0
- package/web/dist/assets/index-i9YgsMdD.css +1 -0
- package/web/dist/assets/path-join-7MR1s7b1.js +1 -0
- package/web/dist/assets/search-CmzeVhy0.js +1 -0
- package/web/dist/assets/xterm-B-qIQCd3.js +16 -0
- package/web/dist/assets/zed-C5BQT8X3.png +0 -0
- package/web/dist/bilibili.ico +0 -0
- package/web/dist/cli-icons/claude.png +0 -0
- package/web/dist/cli-icons/codex.png +0 -0
- package/web/dist/cli-icons/gemini.png +0 -0
- package/web/dist/cli-icons/hermes.png +0 -0
- package/web/dist/cli-icons/opencode.svg +18 -0
- package/web/dist/icons/apple-touch-icon-180.png +0 -0
- package/web/dist/icons/icon-192.png +0 -0
- package/web/dist/icons/icon-32.png +0 -0
- package/web/dist/icons/icon-512-maskable.png +0 -0
- package/web/dist/icons/icon-512.png +0 -0
- package/web/dist/index.html +39 -0
- package/web/dist/logo.png +0 -0
- package/web/dist/manifest.webmanifest +60 -0
- package/web/dist/screenshots/wide-overview.png +0 -0
- package/web/dist/sounds/LICENSE-KENNEY.txt +22 -0
- package/web/dist/sounds/hive-beacon.ogg +0 -0
- package/web/dist/sounds/hive-cascade.ogg +0 -0
- package/web/dist/sounds/hive-chime.ogg +0 -0
- package/web/dist/sounds/hive-ping.ogg +0 -0
- package/web/dist/sounds/hive-resolve.ogg +0 -0
- package/web/dist/sounds/hive-soft.ogg +0 -0
- package/web/dist/sw.js +99 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { type ExecFileOptions } from 'node:child_process';
|
|
2
|
+
import { type FsProbeResponse } from './fs-browse.js';
|
|
3
|
+
type SpawnResult = {
|
|
4
|
+
stderr: string;
|
|
5
|
+
stdout: string;
|
|
6
|
+
status: number | null;
|
|
7
|
+
signal: string | null;
|
|
8
|
+
timedOut: boolean;
|
|
9
|
+
spawnError: NodeJS.ErrnoException | null;
|
|
10
|
+
};
|
|
11
|
+
export type RunPickCommand = (command: string, args: string[], options: ExecFileOptions) => Promise<SpawnResult>;
|
|
12
|
+
export interface PickFolderOptions {
|
|
13
|
+
now?: () => number;
|
|
14
|
+
platform?: NodeJS.Platform;
|
|
15
|
+
runCommand?: RunPickCommand;
|
|
16
|
+
}
|
|
17
|
+
export interface PickFolderResponse {
|
|
18
|
+
canceled: boolean;
|
|
19
|
+
error: string | null;
|
|
20
|
+
path: string | null;
|
|
21
|
+
probe: FsProbeResponse | null;
|
|
22
|
+
supported: boolean;
|
|
23
|
+
}
|
|
24
|
+
export declare const pickFolder: (options?: PickFolderOptions) => Promise<PickFolderResponse>;
|
|
25
|
+
export {};
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { execFile } from 'node:child_process';
|
|
2
|
+
import { probeDirectory } from './fs-browse.js';
|
|
3
|
+
// macOS Cocoa returns -1743 when the user clicks Cancel in `choose folder`.
|
|
4
|
+
// osascript maps that to exit code 1 with the message on stderr.
|
|
5
|
+
const MACOS_CANCEL_PATTERNS = [/-128/, /-1743/, /user canceled/i, /execution error/i];
|
|
6
|
+
// zenity documents exit code 1 on Cancel. kdialog uses exit code 1 as well.
|
|
7
|
+
const LINUX_CANCEL_EXIT_CODES = new Set([1]);
|
|
8
|
+
// Cap how long we'll wait for a single picker invocation. A reasonable
|
|
9
|
+
// modal-dialog dwell time is well under this — the cap exists to catch
|
|
10
|
+
// genuinely wedged pickers (PowerShell startup hang under restricted
|
|
11
|
+
// execution policy, zenity hung on a missing DBus, osascript blocked on
|
|
12
|
+
// the macOS Accessibility prompt) so the HTTP request returns instead
|
|
13
|
+
// of pinning a connection forever.
|
|
14
|
+
const PICKER_TIMEOUT_MS = 5 * 60 * 1000;
|
|
15
|
+
const defaultRunCommand = (command, args, options) => new Promise((resolve) => {
|
|
16
|
+
const child = execFile(command, args, options, (error, stdout, stderr) => {
|
|
17
|
+
const errno = error;
|
|
18
|
+
const timedOut = !!errno?.killed && errno?.signal === 'SIGTERM';
|
|
19
|
+
// execFile surfaces ENOENT when the binary is missing; keep the raw errno
|
|
20
|
+
// so the caller can distinguish "command not installed" from "user cancel".
|
|
21
|
+
resolve({
|
|
22
|
+
stderr: String(stderr ?? ''),
|
|
23
|
+
stdout: String(stdout ?? ''),
|
|
24
|
+
status: typeof errno?.code === 'number' ? errno.code : (child.exitCode ?? 0),
|
|
25
|
+
signal: typeof errno?.signal === 'string' ? errno.signal : null,
|
|
26
|
+
spawnError: errno && typeof errno.code === 'string' ? errno : null,
|
|
27
|
+
timedOut,
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
});
|
|
31
|
+
const emptyResponse = (overrides = {}) => ({
|
|
32
|
+
canceled: false,
|
|
33
|
+
error: null,
|
|
34
|
+
path: null,
|
|
35
|
+
probe: null,
|
|
36
|
+
supported: true,
|
|
37
|
+
...overrides,
|
|
38
|
+
});
|
|
39
|
+
const finalizeWithProbe = async (path) => {
|
|
40
|
+
// The OS-native folder picker is itself a user-authorization surface
|
|
41
|
+
// — sandboxing again here would reject any drive other than the one
|
|
42
|
+
// hosting `$HOME` (a common Windows case: `D:\projects`, `E:\code`).
|
|
43
|
+
// The in-browser FS tree (fs-browse.ts:browseDirectory) keeps its
|
|
44
|
+
// own sandbox; only the native picker bypasses it.
|
|
45
|
+
const probe = await probeDirectory(path, { enforceSandbox: false });
|
|
46
|
+
if (!probe.ok || !probe.is_dir) {
|
|
47
|
+
return emptyResponse({
|
|
48
|
+
error: 'Selected path is not a directory.',
|
|
49
|
+
path,
|
|
50
|
+
probe,
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
return emptyResponse({ path: probe.path, probe });
|
|
54
|
+
};
|
|
55
|
+
const macOsPick = async (run) => {
|
|
56
|
+
const script = 'POSIX path of (choose folder with prompt "Select Hive workspace")';
|
|
57
|
+
const result = await run('osascript', ['-e', script], { timeout: PICKER_TIMEOUT_MS });
|
|
58
|
+
if (result.spawnError?.code === 'ENOENT') {
|
|
59
|
+
return emptyResponse({ error: 'osascript is unavailable on this host.', supported: false });
|
|
60
|
+
}
|
|
61
|
+
if (result.timedOut) {
|
|
62
|
+
return emptyResponse({ error: 'Folder picker timed out before a folder was selected.' });
|
|
63
|
+
}
|
|
64
|
+
const combinedStderr = result.stderr.toLowerCase();
|
|
65
|
+
if (result.status !== 0) {
|
|
66
|
+
if (MACOS_CANCEL_PATTERNS.some((re) => re.test(combinedStderr))) {
|
|
67
|
+
return emptyResponse({ canceled: true });
|
|
68
|
+
}
|
|
69
|
+
// Any non-zero exit code without stdout is treated as cancel rather than a
|
|
70
|
+
// hard failure — the user is just closing the dialog.
|
|
71
|
+
if (result.stdout.trim().length === 0)
|
|
72
|
+
return emptyResponse({ canceled: true });
|
|
73
|
+
}
|
|
74
|
+
const picked = result.stdout.trim().replace(/\/$/, '');
|
|
75
|
+
if (picked.length === 0)
|
|
76
|
+
return emptyResponse({ canceled: true });
|
|
77
|
+
return finalizeWithProbe(picked);
|
|
78
|
+
};
|
|
79
|
+
const linuxPick = async (run) => {
|
|
80
|
+
const result = await run('zenity', ['--file-selection', '--directory', '--title=Select Hive workspace'], { timeout: PICKER_TIMEOUT_MS });
|
|
81
|
+
if (result.spawnError?.code === 'ENOENT') {
|
|
82
|
+
return emptyResponse({
|
|
83
|
+
error: 'zenity not installed. Install zenity or use Advanced: paste path.',
|
|
84
|
+
supported: false,
|
|
85
|
+
});
|
|
86
|
+
}
|
|
87
|
+
if (result.timedOut) {
|
|
88
|
+
return emptyResponse({ error: 'Folder picker timed out before a folder was selected.' });
|
|
89
|
+
}
|
|
90
|
+
if (result.status !== 0 && LINUX_CANCEL_EXIT_CODES.has(result.status ?? 0)) {
|
|
91
|
+
return emptyResponse({ canceled: true });
|
|
92
|
+
}
|
|
93
|
+
const picked = result.stdout.trim();
|
|
94
|
+
if (picked.length === 0)
|
|
95
|
+
return emptyResponse({ canceled: true });
|
|
96
|
+
return finalizeWithProbe(picked);
|
|
97
|
+
};
|
|
98
|
+
export const pickFolder = async (options = {}) => {
|
|
99
|
+
const platform = options.platform ?? process.platform;
|
|
100
|
+
const run = options.runCommand ?? defaultRunCommand;
|
|
101
|
+
if (platform === 'darwin')
|
|
102
|
+
return macOsPick(run);
|
|
103
|
+
if (platform === 'linux')
|
|
104
|
+
return linuxPick(run);
|
|
105
|
+
if (platform === 'win32') {
|
|
106
|
+
return emptyResponse({
|
|
107
|
+
error: 'Native folder picker is disabled on Windows. Use Browse server filesystem or paste path.',
|
|
108
|
+
supported: false,
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
return emptyResponse({
|
|
112
|
+
error: 'Native folder picker not supported on this platform. Use Advanced: paste path.',
|
|
113
|
+
supported: false,
|
|
114
|
+
});
|
|
115
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Root directory the FS-browse API is allowed to reveal when sandboxing is
|
|
3
|
+
* enabled. Tests and remote/headless setups can set `HIVE_FS_BROWSE_ROOT`.
|
|
4
|
+
* Normal Windows runs skip this sandbox root and browse from the virtual
|
|
5
|
+
* "This PC" drive list; POSIX sandboxed browsing defaults to `$HOME`.
|
|
6
|
+
*/
|
|
7
|
+
export declare const getFsBrowseRoot: () => string;
|
|
8
|
+
export declare const hasFsBrowseRootOverride: () => boolean;
|
|
9
|
+
/**
|
|
10
|
+
* True when `candidatePath` is `rootPath` itself or a descendant of it.
|
|
11
|
+
* Uses `path.relative` + separator check so Windows back-slashes and drive
|
|
12
|
+
* boundaries are handled correctly — identical shape to kanban's
|
|
13
|
+
* isPathWithinRoot so the semantics match a project we already trust.
|
|
14
|
+
*/
|
|
15
|
+
export declare const isPathWithinRoot: (rootPath: string, candidatePath: string) => boolean;
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { homedir } from 'node:os';
|
|
2
|
+
import { isAbsolute, relative, resolve, sep } from 'node:path';
|
|
3
|
+
import { realpathNative } from './path-canonicalization.js';
|
|
4
|
+
/**
|
|
5
|
+
* Root directory the FS-browse API is allowed to reveal when sandboxing is
|
|
6
|
+
* enabled. Tests and remote/headless setups can set `HIVE_FS_BROWSE_ROOT`.
|
|
7
|
+
* Normal Windows runs skip this sandbox root and browse from the virtual
|
|
8
|
+
* "This PC" drive list; POSIX sandboxed browsing defaults to `$HOME`.
|
|
9
|
+
*/
|
|
10
|
+
export const getFsBrowseRoot = () => {
|
|
11
|
+
const override = process.env.HIVE_FS_BROWSE_ROOT;
|
|
12
|
+
const root = override && override.length > 0 ? resolve(override) : resolve(homedir());
|
|
13
|
+
try {
|
|
14
|
+
return realpathNative(root);
|
|
15
|
+
}
|
|
16
|
+
catch {
|
|
17
|
+
return root;
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
export const hasFsBrowseRootOverride = () => (process.env.HIVE_FS_BROWSE_ROOT ?? '').length > 0;
|
|
21
|
+
const isResolvedPathWithinRoot = (rootPath, candidatePath) => {
|
|
22
|
+
if (candidatePath === rootPath)
|
|
23
|
+
return true;
|
|
24
|
+
const rel = relative(rootPath, candidatePath);
|
|
25
|
+
return rel !== '..' && !rel.startsWith(`..${sep}`) && !isAbsolute(rel);
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* True when `candidatePath` is `rootPath` itself or a descendant of it.
|
|
29
|
+
* Uses `path.relative` + separator check so Windows back-slashes and drive
|
|
30
|
+
* boundaries are handled correctly — identical shape to kanban's
|
|
31
|
+
* isPathWithinRoot so the semantics match a project we already trust.
|
|
32
|
+
*/
|
|
33
|
+
export const isPathWithinRoot = (rootPath, candidatePath) => {
|
|
34
|
+
const lexicalRoot = resolve(rootPath);
|
|
35
|
+
const lexicalCandidate = resolve(candidatePath);
|
|
36
|
+
let resolvedRoot = lexicalRoot;
|
|
37
|
+
let resolvedCandidate = lexicalCandidate;
|
|
38
|
+
try {
|
|
39
|
+
resolvedRoot = realpathNative(resolvedRoot);
|
|
40
|
+
}
|
|
41
|
+
catch {
|
|
42
|
+
// Missing / inaccessible roots are handled by the caller's readdir/stat path.
|
|
43
|
+
}
|
|
44
|
+
try {
|
|
45
|
+
resolvedCandidate = realpathNative(resolvedCandidate);
|
|
46
|
+
}
|
|
47
|
+
catch {
|
|
48
|
+
// Non-existent children still need lexical sandboxing for "create later"
|
|
49
|
+
// probes; existing symlinks/junctions use the realpath branch above.
|
|
50
|
+
if (isResolvedPathWithinRoot(lexicalRoot, lexicalCandidate)) {
|
|
51
|
+
resolvedRoot = lexicalRoot;
|
|
52
|
+
resolvedCandidate = lexicalCandidate;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
return isResolvedPathWithinRoot(resolvedRoot, resolvedCandidate);
|
|
56
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { AgentSummary } from '../shared/types.js';
|
|
2
|
+
import { type FeatureFlags } from './feature-flags.js';
|
|
3
|
+
import { type WorkflowCliPolicy } from './workflow-cli-policy.js';
|
|
4
|
+
/**
|
|
5
|
+
* Tail reminder appended to every message that flows INTO the orchestrator
|
|
6
|
+
* (worker reports, worker status updates, user chat input). Re-anchors the
|
|
7
|
+
* role + dispatch syntax after the agent's CLI internally compacts the
|
|
8
|
+
* conversation transcript (`/compact` in CC, auto-summarize in Codex, etc.)
|
|
9
|
+
* and forgets the original startup instructions.
|
|
10
|
+
*
|
|
11
|
+
* Format choice (XML envelope, position at message tail, action-menu wording)
|
|
12
|
+
* follows a peer LLM-agent review: static `[Hive]` prefixes get filtered as
|
|
13
|
+
* banner noise after a few occurrences, but `<...-system-reminder>` tags
|
|
14
|
+
* mirror the out-of-band envelope LLMs are trained to attend to; placement
|
|
15
|
+
* at the tail (right before the agent's reply turn) maximizes recency
|
|
16
|
+
* weighting; phrasing as a short action menu is more actionable than abstract
|
|
17
|
+
* identity restatement. Kept deliberately SHORT — the full command syntax and
|
|
18
|
+
* the workflow DSL live in `.hive/PROTOCOL.md`, which agents re-read on demand.
|
|
19
|
+
* A long banner on every turn is itself the noise this envelope exists to beat.
|
|
20
|
+
*/
|
|
21
|
+
export declare const buildOrchestratorReminderTail: ({ workflowsEnabled }: FeatureFlags) => string;
|
|
22
|
+
/**
|
|
23
|
+
* Tail reminder appended to dispatches sent TO a worker. Reinforces the
|
|
24
|
+
* worker identity (so the agent does not regress into its normal CLI
|
|
25
|
+
* persona that would call nested subagents) plus the exact report syntax
|
|
26
|
+
* with dispatch_id pre-bound.
|
|
27
|
+
*/
|
|
28
|
+
export declare const buildWorkerReminderTail: (dispatchId: string) => string;
|
|
29
|
+
export declare const getHiveTeamRules: (agent: Pick<AgentSummary, "role">, flags?: FeatureFlags) => readonly string[];
|
|
30
|
+
/**
|
|
31
|
+
* Workspace-local protocol cheat sheet written to `.hive/PROTOCOL.md`. Agents
|
|
32
|
+
* are explicitly trained to look at project root markdown when confused, so
|
|
33
|
+
* keeping a single canonical doc next to `.hive/tasks.md` doubles as a
|
|
34
|
+
* "cat-recover" path when both the startup prompt and the in-message
|
|
35
|
+
* reminders fail to anchor. This is also the single home of the full command
|
|
36
|
+
* syntax and the workflow DSL reference — the always-on injections only carry
|
|
37
|
+
* the lean core rules and point here.
|
|
38
|
+
*/
|
|
39
|
+
export declare const buildProtocolDoc: (cliPolicy?: WorkflowCliPolicy, flags?: FeatureFlags) => string;
|
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
import { FEATURE_FLAGS_ALL_OFF } from './feature-flags.js';
|
|
2
|
+
import { DEFAULT_WORKFLOW_CLI_POLICY } from './workflow-cli-policy.js';
|
|
3
|
+
/**
|
|
4
|
+
* Tail reminder appended to every message that flows INTO the orchestrator
|
|
5
|
+
* (worker reports, worker status updates, user chat input). Re-anchors the
|
|
6
|
+
* role + dispatch syntax after the agent's CLI internally compacts the
|
|
7
|
+
* conversation transcript (`/compact` in CC, auto-summarize in Codex, etc.)
|
|
8
|
+
* and forgets the original startup instructions.
|
|
9
|
+
*
|
|
10
|
+
* Format choice (XML envelope, position at message tail, action-menu wording)
|
|
11
|
+
* follows a peer LLM-agent review: static `[Hive]` prefixes get filtered as
|
|
12
|
+
* banner noise after a few occurrences, but `<...-system-reminder>` tags
|
|
13
|
+
* mirror the out-of-band envelope LLMs are trained to attend to; placement
|
|
14
|
+
* at the tail (right before the agent's reply turn) maximizes recency
|
|
15
|
+
* weighting; phrasing as a short action menu is more actionable than abstract
|
|
16
|
+
* identity restatement. Kept deliberately SHORT — the full command syntax and
|
|
17
|
+
* the workflow DSL live in `.hive/PROTOCOL.md`, which agents re-read on demand.
|
|
18
|
+
* A long banner on every turn is itself the noise this envelope exists to beat.
|
|
19
|
+
*/
|
|
20
|
+
export const buildOrchestratorReminderTail = ({ workflowsEnabled }) => {
|
|
21
|
+
const body = 'You are the Hive Orchestrator. Reply with one of: ' +
|
|
22
|
+
'(a) `team send "<worker-name>" "<task>"` to dispatch — run `team list` first if the roster may have changed since your last view (Hive does not push membership changes; stale names fail). ' +
|
|
23
|
+
'If no worker fits or the roster is empty, `team spawn <role> [--cli claude|codex|opencode|gemini|hermes]` to create one (add `--ephemeral` for a one-shot), then dispatch; do not ask the user to add workers. ' +
|
|
24
|
+
'(b) `team cancel --dispatch <id> "<reason>"` to close an obsolete dispatch. ' +
|
|
25
|
+
(workflowsEnabled
|
|
26
|
+
? '(c) `team workflow run --stdin` to fan out across 3+ workers or run a staged review→fix — never a loop of `team send` (no barrier, no UI group, no stop button). (d) plain text to the user. '
|
|
27
|
+
: '(c) plain text to the user. ') +
|
|
28
|
+
`Do not use your CLI's own subagent${workflowsEnabled ? ' / workflow' : ''} tools — they run inside your CLI, bypass Hive, and never reach the UI or \`team list\`. ` +
|
|
29
|
+
(workflowsEnabled
|
|
30
|
+
? 'Full command syntax and the workflow DSL: re-read `.hive/PROTOCOL.md`.'
|
|
31
|
+
: 'Full command syntax: re-read `.hive/PROTOCOL.md`.');
|
|
32
|
+
return `<hive-system-reminder>\n${body}\n</hive-system-reminder>`;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Tail reminder appended to dispatches sent TO a worker. Reinforces the
|
|
36
|
+
* worker identity (so the agent does not regress into its normal CLI
|
|
37
|
+
* persona that would call nested subagents) plus the exact report syntax
|
|
38
|
+
* with dispatch_id pre-bound.
|
|
39
|
+
*/
|
|
40
|
+
export const buildWorkerReminderTail = (dispatchId) => '<hive-system-reminder>\n' +
|
|
41
|
+
`You are a Hive Worker. Do not launch nested CLI subagents — finish the task yourself. When the task is done, blocked, or has failed, report with: \`team report "<result>" --dispatch ${dispatchId}\` (or \`team report --stdin --dispatch ${dispatchId}\` for long bodies).\n` +
|
|
42
|
+
'</hive-system-reminder>';
|
|
43
|
+
/**
|
|
44
|
+
* Core, always-on orchestrator rules. Injected at startup, on crash recovery,
|
|
45
|
+
* and on restart env-sync. Deliberately free of multi-line code skeletons —
|
|
46
|
+
* those are reference material that lives in `.hive/PROTOCOL.md` (see
|
|
47
|
+
* WORKFLOW_DSL_REFERENCE) so the recovery / env-sync paths re-anchor identity
|
|
48
|
+
* and dispatch discipline without re-injecting a wall of example JS.
|
|
49
|
+
*/
|
|
50
|
+
const CORE_ORCHESTRATOR_RULES = [
|
|
51
|
+
'A Hive worker is a real CLI agent shown as a card on the right — NOT a subagent of your own CLI.',
|
|
52
|
+
'Dispatch against the current roster: re-run `team list` before a `team send` whenever a user reply or one of your own dispatches/cancels has happened since your last list. Hive never pushes membership changes, so do not dispatch from a remembered roster — a renamed or removed worker fails.',
|
|
53
|
+
'Small, low-risk tasks you can finish in a couple of minutes: do them yourself; do not dispatch for the sake of form. Reach for `team send` when the work needs parallelism, long execution, independent review/test, a dedicated role, or the user explicitly asked for a worker.',
|
|
54
|
+
'If exactly one worker is available, dispatch to it directly with `team send <worker-name> "<task>"` — do not bounce the choice back to the user.',
|
|
55
|
+
'When the user says "have a worker do X", dispatch it with `team send <worker-name> "<task>"`.',
|
|
56
|
+
'If the roster is empty or lacks the role the task needs, build the team yourself: `team spawn <role> [--name <n>] [--cli claude|codex|opencode|gemini|hermes]`, then immediately dispatch. Do not stop to ask the user to add members — that call is yours.',
|
|
57
|
+
'`team spawn` is PERSISTENT by default (a normal member that stays in the workspace); add `--ephemeral` for a one-shot worker that auto-dismisses after its first `team report`. Rule of thumb: will you reuse this role in the next 10 minutes? Yes → persistent; no → `--ephemeral`.',
|
|
58
|
+
'When the user cancels or changes direction on an open dispatch, close it explicitly with `team cancel --dispatch <id> "<reason>"` — do not just say "cancel" in prose.',
|
|
59
|
+
'Each `team send` opens a SEPARATE dispatch with its own pending count and its own required report — it is not a way to tack context onto a dispatch already in flight. Send the same worker twice and it owes you TWO reports; one report closes only one dispatch (the one its `--dispatch <id>` names, or the oldest open one if the flag is omitted), so the other stays open and the worker is pinned on `working`. To change or extend an in-flight task, `team cancel --dispatch <id> "<reason>"` the stale dispatch and re-send the whole task, or wait for the worker to report and dispatch the follow-up after.',
|
|
60
|
+
'Only orchestrators can add memory directly; workers should report durable findings for the orchestrator or Dream to capture. Search memory before adding: use `team memory search "<query>"` to avoid duplicates. Use `team memory add "<body>"` only for rare, evidence-backed workspace facts, decisions, and pitfalls that should help future Hive agents across sessions. Nothing worth saving is a normal outcome; do not add memory just to prove you used it. Use `team memory forget <memory-id>` only to archive obsolete memory.',
|
|
61
|
+
"Never substitute your CLI's own subagent / workflow tools (e.g. Task / Explore / Workflow / Agent) for Hive workers or Hive workflows — they run inside your CLI process, bypass Hive's PTY fleet, never appear in the UI or `team list`, and the stop button cannot reach them.",
|
|
62
|
+
'In `team list`, `last_pty_line` is raw terminal output (stdout / help / control-sequence noise), NOT a worker\'s report. A real report arrives only as an injected "report from @<name>" / "status from @<name>" system message — treat only those as replies.',
|
|
63
|
+
];
|
|
64
|
+
/**
|
|
65
|
+
* Workflow-authoring rule — only injected when the experimental workflow
|
|
66
|
+
* feature is ENABLED. When workflows are off the orchestrator is never told
|
|
67
|
+
* to reach for `team workflow`, which keeps its always-on prompt lean and
|
|
68
|
+
* avoids it firing a command the runtime will reject.
|
|
69
|
+
*/
|
|
70
|
+
const WORKFLOW_ORCHESTRATOR_RULES = [
|
|
71
|
+
'Choosing to use a workflow is YOUR call, judged from the task\'s shape — the user describes what they want in plain language and will not (and need not) ask for a "workflow" by name. When a task fans out across 3+ workers, needs a staged review→fix, or loops until results converge, author the workflow script yourself from the task and fire it with ONE `team workflow run --stdin` — decide this on your own, do not wait to be told, and do not approximate it with a loop of `team send` (no barrier, no UI grouping, no stop button). The DSL and ready-made patterns are in `.hive/PROTOCOL.md`.',
|
|
72
|
+
];
|
|
73
|
+
/**
|
|
74
|
+
* Auto-staff rule — only injected when the experimental auto-staff feature is
|
|
75
|
+
* ENABLED (ON by default). Grants + encourages the orchestrator to size the
|
|
76
|
+
* team to the task instead of adding workers one at a time. The shared-FS +
|
|
77
|
+
* ephemeral notes are operating instructions (Hive gives every worker the same
|
|
78
|
+
* workspace root with no per-worker isolation), not optional caution: without
|
|
79
|
+
* them parallel coders overwrite each other.
|
|
80
|
+
*
|
|
81
|
+
* The text adapts to whether workflows are ALSO on: there is no batch `team
|
|
82
|
+
* spawn` syntax (one command per member), so it says exactly that; and when
|
|
83
|
+
* workflows are available it defers one-shot batch fan-out to `team workflow
|
|
84
|
+
* run` so the two experiments don't give the orchestrator competing advice.
|
|
85
|
+
*/
|
|
86
|
+
const buildAutostaffRule = (workflowsEnabled) => 'You may size the team to the task instead of adding workers one at a time: judge what mix of roles runs it fastest (e.g. a couple of coders plus a reviewer and a tester) and issue the individual `team spawn <role> --ephemeral` commands you need up front — one command per member (there is no batch form), this call is yours, do not ask the user. Match the count to the work: more agents is not faster once they would collide or sit idle. CRITICAL: all workers share the same workspace files with NO per-worker isolation, so split the work so no two agents touch the same files/modules. Use `--ephemeral` so this task-scoped staff auto-dismiss after reporting and do not pile up.' +
|
|
87
|
+
(workflowsEnabled
|
|
88
|
+
? ' When the work is a one-shot fan-out across 3+ workers or a staged review→fix that runs to completion, prefer `team workflow run` (barrier, phase tree, stop button) over a batch of `team spawn`; reserve up-front staffing for a standing team you direct interactively across several turns.'
|
|
89
|
+
: '');
|
|
90
|
+
const orchestratorRules = ({ workflowsEnabled, autostaffEnabled, }) => [
|
|
91
|
+
...CORE_ORCHESTRATOR_RULES,
|
|
92
|
+
...(workflowsEnabled ? WORKFLOW_ORCHESTRATOR_RULES : []),
|
|
93
|
+
...(autostaffEnabled ? [buildAutostaffRule(workflowsEnabled)] : []),
|
|
94
|
+
];
|
|
95
|
+
const WORKER_RULES = [
|
|
96
|
+
'You are a real CLI worker shown as a card on the right in Hive — not a subagent of your own CLI.',
|
|
97
|
+
"Do not call `team send`, and do not launch your own CLI's subagent tools to do the work for you — finish it yourself.",
|
|
98
|
+
'When an assigned task is done, blocked, or has failed, you MUST report to the Orchestrator with `team report`.',
|
|
99
|
+
'When you have no active dispatch and only want to report readiness, environment, or status, use `team status "<state>"`.',
|
|
100
|
+
'Use `team recall "<query>"` when prior team messages or reports may contain useful evidence.',
|
|
101
|
+
'Use `team memory search "<query>"` to inspect active workspace memory. Include durable findings in `team report`; workers cannot add or forget memory.',
|
|
102
|
+
'`team --help` only prints command syntax — it is NOT a way to report; its output never reaches the Orchestrator. You still owe a real `team report` / `team status` afterward.',
|
|
103
|
+
'If `team report` / `team status` errors, it also prints USAGE — fix the arguments per USAGE and retry; do not use `team --help` as a stand-in for reporting.',
|
|
104
|
+
];
|
|
105
|
+
export const getHiveTeamRules = (agent, flags = FEATURE_FLAGS_ALL_OFF) => (agent.role === 'orchestrator' ? orchestratorRules(flags) : WORKER_RULES);
|
|
106
|
+
const renderRules = (rules) => rules.map((line) => `- ${line}`).join('\n');
|
|
107
|
+
/**
|
|
108
|
+
* The workflow DSL teaching: agent()/parallel()/pipeline() semantics, the
|
|
109
|
+
* agent() opts surface, runnable skeletons, and the canonical patterns. This
|
|
110
|
+
* is REFERENCE material — it lives only in `.hive/PROTOCOL.md`, never in the
|
|
111
|
+
* per-message reminder or the recovery/env-sync injections, so the always-on
|
|
112
|
+
* paths stay lean. The orchestrator is pointed here by the core rules and the
|
|
113
|
+
* reminder tail whenever it needs to author a `team workflow run`.
|
|
114
|
+
*/
|
|
115
|
+
const WORKFLOW_DSL_REFERENCE = `## Workflow DSL (\`team workflow run --stdin\`)
|
|
116
|
+
|
|
117
|
+
Use a workflow when a task fans out beyond a single dispatch: 3+ parallel
|
|
118
|
+
workers, a staged review→fix, or a loop until results converge. The DSL mirrors
|
|
119
|
+
Claude Code's Workflow tool, but every \`agent()\` runs on Hive's PTY fleet — a
|
|
120
|
+
real CLI process — not an in-CLI API subagent. \`team workflow run\` is the only
|
|
121
|
+
entry into the Hive runtime; never use your CLI's own Workflow/Agent tool.
|
|
122
|
+
|
|
123
|
+
Host functions injected into the script: \`agent(prompt, opts)\`,
|
|
124
|
+
\`parallel(thunks)\`, \`pipeline(items, ...stages)\`, \`phase(title)\`,
|
|
125
|
+
\`log(msg)\`, plus the \`args\` global.
|
|
126
|
+
|
|
127
|
+
\`agent(prompt, opts)\` opts: \`{ agentType?: "coder"|"reviewer"|"tester"|"custom"|<custom-role-name>, cli?: "claude"|"codex"|"opencode"|"gemini"|"hermes", model?: string, outputSchema?: object, label?: string, timeoutMs?: number }\` — other fields are silently ignored. \`agentType\` also accepts the name of a workspace custom role template (case-insensitive); a typo throws rather than silently falling back to coder. \`model\` is passed through to the worker launch config (\`--model <id>\`), so a 100-way fan-out can use a cheap model and the synthesizer a strong one. \`outputSchema\` makes \`agent()\` resolve to a parsed object instead of a string: the worker is told to end its report with a fenced \`\`\`json block whose keys match the schema. On a parse miss it falls back to \`{ text: "<raw report>" }\`, so ALWAYS treat a missing field as the SAFE default (never assume success). The worker auto-dismisses when its \`agent()\` call resolves — you never dismiss it.
|
|
128
|
+
|
|
129
|
+
\`parallel()\` takes an array of THUNKS (\`() => agent(...)\`), NOT already-started promises: \`parallel([agent(...), agent(...)])\` degrades to unordered concurrency counted as a single step (a no-op grouping), because the promises already started at construction time. \`pipeline(items, ...stages)\` stages are also functions, shape \`(prev, item, i) => agent(...)\`.
|
|
130
|
+
|
|
131
|
+
\`log("...")\` writes one narrator line — stored in the DB, shown when the run row is expanded in the Drawer, and its last 8 lines are spliced into the completion reminder sent back to you. Use it for a readable progress summary, e.g. \`log('Discovered 47 endpoints')\`.
|
|
132
|
+
|
|
133
|
+
Runtime limits: each run defaults to at most 1000 \`agent()\` calls and 60 minutes wall-clock; the concurrency cap is \`min(16, cores-2)\` and parallel/pipeline queue against it automatically. Override in \`meta\`, e.g. \`meta = { name, description, maxAgentCalls: 50, maxDurationMs }\`.
|
|
134
|
+
|
|
135
|
+
\`meta\` must be a pure literal (no variables). Scripts are JS, not TS (type annotations error). The body may use top-level \`await\` and a trailing \`return\`.
|
|
136
|
+
|
|
137
|
+
Minimal script (heredoc into \`--stdin\`):
|
|
138
|
+
\`\`\`
|
|
139
|
+
export const meta = { name: 'review-changes', description: 'review + tests' }
|
|
140
|
+
phase('Find')
|
|
141
|
+
const issues = await agent('Run \`git diff\` and list any potential bugs.', { agentType: 'reviewer', label: 'review' })
|
|
142
|
+
phase('Verify')
|
|
143
|
+
const tests = await agent(\`Write tests for: \${issues}\`, { agentType: 'tester', label: 'verify' })
|
|
144
|
+
return { issues, tests }
|
|
145
|
+
\`\`\`
|
|
146
|
+
|
|
147
|
+
Parallel fan-out + multi-vendor mix (Hive's signature — several CLIs in one run):
|
|
148
|
+
\`\`\`
|
|
149
|
+
export const meta = { name: 'parallel-audit', description: 'audit N files in parallel' }
|
|
150
|
+
const files = ['src/a.ts', 'src/b.ts', 'src/c.ts']
|
|
151
|
+
phase('Audit')
|
|
152
|
+
const reports = await parallel(files.map((f) => () => agent(\`Audit \${f} for security bugs.\`, { agentType: 'reviewer', cli: 'codex', label: \`audit:\${f}\` })))
|
|
153
|
+
phase('Synthesize')
|
|
154
|
+
return await agent(\`Synthesize: \${reports.filter(Boolean).join('\\n---\\n')}\`, { agentType: 'reviewer', cli: 'claude', label: 'synth' })
|
|
155
|
+
\`\`\`
|
|
156
|
+
|
|
157
|
+
Passing args (so a saved script is reusable instead of hard-coding values):
|
|
158
|
+
\`\`\`
|
|
159
|
+
team workflow run --stdin --args '["src/a.ts","src/b.ts"]' <<'EOF'
|
|
160
|
+
export const meta = { name: 'audit', description: 'd' }
|
|
161
|
+
phase('Audit')
|
|
162
|
+
return await parallel(args.map((f) => () => agent(\`Audit \${f}\`)))
|
|
163
|
+
EOF
|
|
164
|
+
\`\`\`
|
|
165
|
+
\`--args\` takes JSON (\`'{"q":1}'\`, \`'["a","b"]'\`, \`'"plain"'\`); omitted → \`args\` is \`undefined\`.
|
|
166
|
+
|
|
167
|
+
Patterns worth knowing:
|
|
168
|
+
- **loop-until-dry** — stop after K empty rounds; more robust than \`while (count < N)\`, which stalls on the hard-to-find tail:
|
|
169
|
+
\`\`\`
|
|
170
|
+
const seen = new Set(), confirmed = []
|
|
171
|
+
let dry = 0
|
|
172
|
+
while (dry < 2) {
|
|
173
|
+
const found = await agent('Find any potential bugs not in: ' + [...seen].join(', '))
|
|
174
|
+
const fresh = found.split('\\n').filter((b) => b.trim() && !seen.has(b))
|
|
175
|
+
if (!fresh.length) { dry++; continue }
|
|
176
|
+
dry = 0
|
|
177
|
+
fresh.forEach((b) => { seen.add(b); confirmed.push(b) })
|
|
178
|
+
}
|
|
179
|
+
return confirmed
|
|
180
|
+
\`\`\`
|
|
181
|
+
- **judge panel** — N independent verifiers per finding; majority confirms. \`outputSchema\` makes each vote a typed object instead of fragile yes/no string-matching. Note the safe default: a parse miss has no \`refuted\` key, so \`v.refuted === false\` is false → the finding stays refuted and a malformed reply can never flip it to "confirmed":
|
|
182
|
+
\`\`\`
|
|
183
|
+
phase('Verify')
|
|
184
|
+
const votes = await parallel([
|
|
185
|
+
() => agent(\`Try to REFUTE: \${claim}. Default refuted=true if uncertain.\`, { outputSchema: { refuted: 'boolean' } }),
|
|
186
|
+
() => agent(\`Independently judge: \${claim}.\`, { outputSchema: { refuted: 'boolean' } }),
|
|
187
|
+
() => agent(\`Repro test: \${claim}. Did it reproduce?\`, { outputSchema: { refuted: 'boolean' } }),
|
|
188
|
+
])
|
|
189
|
+
// Only an explicit refuted:false counts as "survived"; missing/unparseable stays safely refuted.
|
|
190
|
+
const real = votes.filter((v) => v && v.refuted === false).length >= 2
|
|
191
|
+
\`\`\`
|
|
192
|
+
- **pipeline** — multi-item, multi-stage, no barrier between stages (item A can be in stage 3 while item B is in stage 1); wall-clock = slowest single item, not sum-of-slowest-per-stage. Each stage gets \`(prevResult, originalItem, index)\`; a stage that throws drops that item to null and skips its remaining stages.
|
|
193
|
+
|
|
194
|
+
On completion Hive injects \`<hive-system-reminder>Hive workflow ... finished: status=...</hive-system-reminder>\` carrying each step's short report; synthesize that back to the user. Full per-agent transcripts: \`team workflow show <run-id>\`.`;
|
|
195
|
+
/**
|
|
196
|
+
* Workspace-local protocol cheat sheet written to `.hive/PROTOCOL.md`. Agents
|
|
197
|
+
* are explicitly trained to look at project root markdown when confused, so
|
|
198
|
+
* keeping a single canonical doc next to `.hive/tasks.md` doubles as a
|
|
199
|
+
* "cat-recover" path when both the startup prompt and the in-message
|
|
200
|
+
* reminders fail to anchor. This is also the single home of the full command
|
|
201
|
+
* syntax and the workflow DSL reference — the always-on injections only carry
|
|
202
|
+
* the lean core rules and point here.
|
|
203
|
+
*/
|
|
204
|
+
export const buildProtocolDoc = (cliPolicy = DEFAULT_WORKFLOW_CLI_POLICY, flags = FEATURE_FLAGS_ALL_OFF) => {
|
|
205
|
+
const { workflowsEnabled } = flags;
|
|
206
|
+
// The `team workflow …` subcommands + the DSL reference + the per-workspace
|
|
207
|
+
// CLI-policy section only appear when the experimental workflow feature is
|
|
208
|
+
// ON. While off, the orchestrator's canonical reference never mentions
|
|
209
|
+
// workflows (leaner prompt) and never points at a command the runtime rejects.
|
|
210
|
+
const workflowCliCommands = workflowsEnabled
|
|
211
|
+
? [
|
|
212
|
+
"- `team workflow run --stdin` — fire a multi-agent workflow; pass JS source via stdin. Add `--args '<JSON>'` to set the script's `args` global.",
|
|
213
|
+
'- `team workflow run --inline "<source>"` — same, single-arg form',
|
|
214
|
+
'- `team workflow stop <run-id>` — cancel a running workflow',
|
|
215
|
+
'- `team workflow show <run-id>` — full per-agent transcript (status, phase, label, prompt, full reportText) — use this when the truncated completion reminder is not enough',
|
|
216
|
+
'- `team workflow schedule --cron "<5-field cron>" --name <n> --stdin` — register a RECURRING run; pass the same JS source you would give `run`. The source is persisted so cron can fire it with no orchestrator present. The UI can pause / delete schedules but never create them — scheduling is your job.',
|
|
217
|
+
]
|
|
218
|
+
: [];
|
|
219
|
+
const workflowSections = workflowsEnabled
|
|
220
|
+
? [
|
|
221
|
+
WORKFLOW_DSL_REFERENCE,
|
|
222
|
+
'',
|
|
223
|
+
'## Workflow agent CLIs (this workspace)',
|
|
224
|
+
'',
|
|
225
|
+
'When a workflow `agent()` omits `cli` it launches a worker on the default',
|
|
226
|
+
'CLI below; an explicit `cli:` must be one of the allowed CLIs or the run',
|
|
227
|
+
'fails with a clear error. (Custom role templates keep their own configured',
|
|
228
|
+
'CLI and are exempt from the allowlist.)',
|
|
229
|
+
'',
|
|
230
|
+
`- Default CLI when \`cli\` is omitted: **${cliPolicy.default}**`,
|
|
231
|
+
`- Allowed CLIs for \`cli\`: ${cliPolicy.allowed.join(', ')}`,
|
|
232
|
+
'',
|
|
233
|
+
]
|
|
234
|
+
: [];
|
|
235
|
+
return [
|
|
236
|
+
'# Hive Team Protocol',
|
|
237
|
+
'',
|
|
238
|
+
'This file is auto-generated by Hive on every workspace open. If you',
|
|
239
|
+
'(the agent) lost context after `/compact` or an internal summarization,',
|
|
240
|
+
're-read `.hive/PROTOCOL.md` (POSIX: `cat`, Windows cmd: `type`, PowerShell:',
|
|
241
|
+
'`Get-Content`) to re-anchor.',
|
|
242
|
+
'',
|
|
243
|
+
'## You are running inside Hive',
|
|
244
|
+
'',
|
|
245
|
+
'Hive is a multi-CLI-agent workbench. Each agent in this workspace is a',
|
|
246
|
+
'real CLI process (Claude Code / Codex / OpenCode / Gemini). All',
|
|
247
|
+
'inter-agent communication goes through the `team` CLI binary on your',
|
|
248
|
+
'PATH.',
|
|
249
|
+
'',
|
|
250
|
+
'## Roles',
|
|
251
|
+
'',
|
|
252
|
+
'- **Orchestrator** — talks to the user, plans tasks, dispatches to workers',
|
|
253
|
+
'- **Worker** (Coder / Reviewer / Tester / custom) — executes one assigned task and reports back',
|
|
254
|
+
'',
|
|
255
|
+
'## `team` CLI — orchestrator',
|
|
256
|
+
'',
|
|
257
|
+
'- `team list` — show workspace members and their status',
|
|
258
|
+
'- `team recall "<query>" [--limit <n>] [--window <n>]` — search prior team messages/reports in this workspace',
|
|
259
|
+
'- `team memory add "<body>" [--kind fact|preference|decision|pitfall|procedure_ref] [--tag <tag>]` — save durable workspace memory (orchestrator entries become active)',
|
|
260
|
+
'- `team memory show <memory-id>` — inspect a memory entry and evidence snapshots',
|
|
261
|
+
'- `team memory search "<query>" [--limit <n>]` — search active workspace memory',
|
|
262
|
+
'- `team memory forget <memory-id>` — archive obsolete memory (orchestrator only; does not physically delete evidence)',
|
|
263
|
+
'- `team send "<worker-name>" "<task>"` — dispatch to a worker by name (never id)',
|
|
264
|
+
'- `team spawn <role> [--name <name>] [--cli claude|codex|opencode|gemini|hermes]` — create a PERSISTENT member when none fits (or when the roster is empty)',
|
|
265
|
+
'- `team spawn <role> --ephemeral [other-flags]` — create a one-shot worker that auto-dismisses after its first `team report`',
|
|
266
|
+
'- `team dismiss <worker-name>` — remove an ephemeral worker you spawned',
|
|
267
|
+
'- `team cancel --dispatch <id> "<reason>"` — cancel an obsolete open dispatch',
|
|
268
|
+
...workflowCliCommands,
|
|
269
|
+
'',
|
|
270
|
+
'## `team` CLI — worker',
|
|
271
|
+
'',
|
|
272
|
+
'- `team recall "<query>" [--limit <n>] [--window <n>]` — search prior team messages/reports in this workspace',
|
|
273
|
+
'- `team memory show <memory-id>` — inspect a memory entry and evidence snapshots',
|
|
274
|
+
'- `team memory search "<query>" [--limit <n>]` — search active workspace memory',
|
|
275
|
+
'- `team report "<result>" --dispatch <id>` — report task outcome',
|
|
276
|
+
'- `team report --stdin --dispatch <id>` — same, body from stdin (pipe content in via your shell — POSIX heredoc, Windows cmd `type file |`, PowerShell `Get-Content -Raw -Encoding utf8 file |`, or portable stdin redirection `< file`)',
|
|
277
|
+
'- `team status "<state>"` — update orchestrator when no dispatch is active',
|
|
278
|
+
'',
|
|
279
|
+
'## Orchestrator rules',
|
|
280
|
+
'',
|
|
281
|
+
renderRules(orchestratorRules(flags)),
|
|
282
|
+
'',
|
|
283
|
+
'## Worker rules',
|
|
284
|
+
'',
|
|
285
|
+
renderRules(WORKER_RULES),
|
|
286
|
+
'',
|
|
287
|
+
...workflowSections,
|
|
288
|
+
'## In-message reminders',
|
|
289
|
+
'',
|
|
290
|
+
'Every message you receive in this workspace ends with a short',
|
|
291
|
+
'`<hive-system-reminder>` block carrying the minimum syntax you need',
|
|
292
|
+
'right now. If something is missing from that block, re-read this file.',
|
|
293
|
+
'',
|
|
294
|
+
].join('\n');
|
|
295
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export declare class HttpError extends Error {
|
|
2
|
+
readonly statusCode: number;
|
|
3
|
+
constructor(statusCode: number, message: string);
|
|
4
|
+
}
|
|
5
|
+
export declare class PtyInactiveError extends HttpError {
|
|
6
|
+
constructor(message: string);
|
|
7
|
+
}
|
|
8
|
+
export declare class UnauthorizedError extends HttpError {
|
|
9
|
+
constructor(message: string);
|
|
10
|
+
}
|
|
11
|
+
export declare class ForbiddenError extends HttpError {
|
|
12
|
+
constructor(message: string);
|
|
13
|
+
}
|
|
14
|
+
export declare class BadRequestError extends HttpError {
|
|
15
|
+
constructor(message: string);
|
|
16
|
+
}
|
|
17
|
+
export declare class PayloadTooLargeError extends HttpError {
|
|
18
|
+
constructor(message: string);
|
|
19
|
+
}
|
|
20
|
+
export declare class ConflictError extends HttpError {
|
|
21
|
+
constructor(message: string);
|
|
22
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
export class HttpError extends Error {
|
|
2
|
+
statusCode;
|
|
3
|
+
constructor(statusCode, message) {
|
|
4
|
+
super(message);
|
|
5
|
+
this.name = 'HttpError';
|
|
6
|
+
this.statusCode = statusCode;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
export class PtyInactiveError extends HttpError {
|
|
10
|
+
constructor(message) {
|
|
11
|
+
super(409, message);
|
|
12
|
+
this.name = 'PtyInactiveError';
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
export class UnauthorizedError extends HttpError {
|
|
16
|
+
constructor(message) {
|
|
17
|
+
super(401, message);
|
|
18
|
+
this.name = 'UnauthorizedError';
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
export class ForbiddenError extends HttpError {
|
|
22
|
+
constructor(message) {
|
|
23
|
+
super(403, message);
|
|
24
|
+
this.name = 'ForbiddenError';
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
export class BadRequestError extends HttpError {
|
|
28
|
+
constructor(message) {
|
|
29
|
+
super(400, message);
|
|
30
|
+
this.name = 'BadRequestError';
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
export class PayloadTooLargeError extends HttpError {
|
|
34
|
+
constructor(message) {
|
|
35
|
+
super(413, message);
|
|
36
|
+
this.name = 'PayloadTooLargeError';
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
export class ConflictError extends HttpError {
|
|
40
|
+
constructor(message) {
|
|
41
|
+
super(409, message);
|
|
42
|
+
this.name = 'ConflictError';
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { LiveAgentRun } from './agent-runtime-types.js';
|
|
2
|
+
export interface RunExitEntry {
|
|
3
|
+
promise: Promise<void>;
|
|
4
|
+
resolve: () => void;
|
|
5
|
+
runId: string;
|
|
6
|
+
}
|
|
7
|
+
export interface LiveRunRegistry {
|
|
8
|
+
add: (run: LiveAgentRun) => void;
|
|
9
|
+
createExitEntry: (runId: string) => void;
|
|
10
|
+
deleteExitEntry: (runId: string) => void;
|
|
11
|
+
get: (runId: string) => LiveAgentRun | undefined;
|
|
12
|
+
getExitEntry: (runId: string) => RunExitEntry | undefined;
|
|
13
|
+
clearPendingExitCode: (runId: string) => void;
|
|
14
|
+
getPendingExitCode: (runId: string) => number | null | undefined;
|
|
15
|
+
hasPendingExitCode: (runId: string) => boolean;
|
|
16
|
+
list: () => LiveAgentRun[];
|
|
17
|
+
listExitEntries: () => RunExitEntry[];
|
|
18
|
+
remove: (runId: string) => void;
|
|
19
|
+
resolveExit: (runId: string) => void;
|
|
20
|
+
setPendingExitCode: (runId: string, exitCode: number | null) => void;
|
|
21
|
+
}
|
|
22
|
+
export declare const createLiveRunRegistry: () => LiveRunRegistry;
|