@tencent-ai/agent-harness 0.2.0-beta.7 → 0.2.0-beta.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +29 -0
- package/cli/CHANGELOG.md +74 -0
- package/cli/dist-server/lite/in-memory-session-store.js +1 -1
- package/cli/dist-server/shared.cjs +263 -217
- package/cli/dist-server/types/node/a2a/a2a-protocol.d.ts +516 -0
- package/cli/dist-server/types/node/agent/agent-completion-waiter.d.ts +28 -0
- package/cli/dist-server/types/node/agent/agent-controller.d.ts +147 -0
- package/cli/dist-server/types/node/agent/agent-display.d.ts +77 -0
- package/cli/dist-server/types/node/agent/agent-manager.d.ts +964 -0
- package/cli/dist-server/types/node/agent/agent-memory.d.ts +72 -0
- package/cli/dist-server/types/node/agent/agent-runtime-adapter.d.ts +71 -0
- package/cli/dist-server/types/node/agent/builtin-agent-modes.d.ts +47 -0
- package/cli/dist-server/types/node/agent/custom-agent-identity.d.ts +54 -0
- package/cli/dist-server/types/node/agent/custom-agent-manager.d.ts +43 -0
- package/cli/dist-server/types/node/agent/custom-agent-path-registry.d.ts +19 -0
- package/cli/dist-server/types/node/agent/exit-planmode-visibility.d.ts +64 -0
- package/cli/dist-server/types/node/agent/index.d.ts +22 -0
- package/cli/dist-server/types/node/agent/insights-data-agent-run-interceptor.d.ts +67 -0
- package/cli/dist-server/types/node/agent/interceptors/command-interceptors.d.ts +89 -0
- package/cli/dist-server/types/node/agent/interceptors/deep-research-pending-interceptor.d.ts +30 -0
- package/cli/dist-server/types/node/agent/interceptors/env-interceptor.d.ts +7 -0
- package/cli/dist-server/types/node/agent/interceptors/file-interceptors.d.ts +45 -0
- package/cli/dist-server/types/node/agent/interceptors/image-interceptors.d.ts +47 -0
- package/cli/dist-server/types/node/agent/interceptors/index.d.ts +16 -0
- package/cli/dist-server/types/node/agent/interceptors/initial-prompt-interceptor.d.ts +29 -0
- package/cli/dist-server/types/node/agent/interceptors/manual-compact-request-handler.d.ts +29 -0
- package/cli/dist-server/types/node/agent/interceptors/model-interceptors.d.ts +43 -0
- package/cli/dist-server/types/node/agent/interceptors/sandbox-interceptor.d.ts +84 -0
- package/cli/dist-server/types/node/agent/interceptors/sensitive-user-input-interceptor.d.ts +7 -0
- package/cli/dist-server/types/node/agent/interceptors/system-reminder-interceptor.d.ts +101 -0
- package/cli/dist-server/types/node/agent/interceptors/team-resume-intent-interceptor.d.ts +31 -0
- package/cli/dist-server/types/node/agent/interceptors/telemetry-interceptors.d.ts +43 -0
- package/cli/dist-server/types/node/agent/interceptors/ultracode-effort-reminder-interceptor.d.ts +21 -0
- package/cli/dist-server/types/node/agent/interceptors/ultracode-keyword-interceptor.d.ts +34 -0
- package/cli/dist-server/types/node/agent/main-agent-policy.d.ts +33 -0
- package/cli/dist-server/types/node/agent/main-agent-preset.d.ts +32 -0
- package/cli/dist-server/types/node/agent/main-agent-resolver.d.ts +156 -0
- package/cli/dist-server/types/node/agent/main-agent-session.d.ts +212 -0
- package/cli/dist-server/types/node/agent/memory-context-interceptor.d.ts +84 -0
- package/cli/dist-server/types/node/agent/standing-main-agent.d.ts +12 -0
- package/cli/dist-server/types/node/agent/stream-json-init-interceptor.d.ts +9 -0
- package/cli/dist-server/types/node/agent/subagent-limits.d.ts +90 -0
- package/cli/dist-server/types/node/agent/team-context-interceptor.d.ts +42 -0
- package/cli/dist-server/types/node/agent/teammate-failure-interceptor.d.ts +67 -0
- package/cli/dist-server/types/node/agent-home/agent-home-attachments.d.ts +83 -0
- package/cli/dist-server/types/node/agent-home/agent-home-channel-system-event.d.ts +15 -0
- package/cli/dist-server/types/node/agent-home/agent-home-channel-task-event.d.ts +24 -0
- package/cli/dist-server/types/node/agent-home/agent-home-channel-wake.d.ts +115 -0
- package/cli/dist-server/types/node/agent-home/agent-home-channel-widget.d.ts +45 -0
- package/cli/dist-server/types/node/agent-home/agent-home-directory.d.ts +304 -0
- package/cli/dist-server/types/node/agent-home/agent-home-limits.d.ts +73 -0
- package/cli/dist-server/types/node/agent-home/agent-home-membership.d.ts +34 -0
- package/cli/dist-server/types/node/agent-home/agent-home-mentions.d.ts +39 -0
- package/cli/dist-server/types/node/agent-home/agent-home-room-contacts.d.ts +51 -0
- package/cli/dist-server/types/node/agent-home/channel-wake-service.d.ts +69 -0
- package/cli/dist-server/types/node/agent-task/agent-task-manager.d.ts +242 -0
- package/cli/dist-server/types/node/agent-task/agent-task-output-manager.d.ts +55 -0
- package/cli/dist-server/types/node/agent-task/agent-task-protocol.d.ts +687 -0
- package/cli/dist-server/types/node/agent-task/agent-task.d.ts +405 -0
- package/cli/dist-server/types/node/agent-task/background-task-notifier.d.ts +212 -0
- package/cli/dist-server/types/node/agent-task/background-task-tool-approval-service.d.ts +36 -0
- package/cli/dist-server/types/node/agent-task/index.d.ts +9 -0
- package/cli/dist-server/types/node/agent-task/retained-agent-task.d.ts +11 -0
- package/cli/dist-server/types/node/agent-task/stream-json-drain-trigger.d.ts +23 -0
- package/cli/dist-server/types/node/agent-task/subagent-output-scanner.d.ts +53 -0
- package/cli/dist-server/types/node/agent-team/backends/teammate-backend-protocol.d.ts +119 -0
- package/cli/dist-server/types/node/agent-team/team-member.d.ts +391 -0
- package/cli/dist-server/types/node/agent-team/team-protocol.d.ts +375 -0
- package/cli/dist-server/types/node/agent-view/agent-view-actions.d.ts +209 -0
- package/cli/dist-server/types/node/agent-view/agent-view-protocol.d.ts +714 -0
- package/cli/dist-server/types/node/agent-view/handoff-policy.d.ts +80 -0
- package/cli/dist-server/types/node/agent-view/launch-workspace.d.ts +9 -0
- package/cli/dist-server/types/node/agent-view/session-handoff.d.ts +161 -0
- package/cli/dist-server/types/node/ask/ask-protoctol.d.ts +102 -0
- package/cli/dist-server/types/node/ask/ask-service.d.ts +62 -0
- package/cli/dist-server/types/node/ask/index.d.ts +3 -0
- package/cli/dist-server/types/node/ask/session-ask-user-question-handler.d.ts +25 -0
- package/cli/dist-server/types/node/authentication/api-key-authentication-storage.d.ts +17 -0
- package/cli/dist-server/types/node/authentication/custom-token-authentication-storage.d.ts +10 -0
- package/cli/dist-server/types/node/authentication/file-authentication-storage.d.ts +71 -0
- package/cli/dist-server/types/node/bash-sandbox/bash-sandbox-manager.d.ts +125 -0
- package/cli/dist-server/types/node/bash-sandbox/index.d.ts +4 -0
- package/cli/dist-server/types/node/bash-sandbox/legacy-sandbox-shell-protocol.d.ts +33 -0
- package/cli/dist-server/types/node/bash-sandbox/legacy-sandbox-shell-service.d.ts +33 -0
- package/cli/dist-server/types/node/blob-store/blob-store-protocol.d.ts +104 -0
- package/cli/dist-server/types/node/blob-store/blob-store-service.d.ts +22 -0
- package/cli/dist-server/types/node/blob-store/image-blob-service.d.ts +121 -0
- package/cli/dist-server/types/node/blob-store/index.d.ts +4 -0
- package/cli/dist-server/types/node/blob-store/tool-result-blob-service.d.ts +109 -0
- package/cli/dist-server/types/node/channel/channel-event-service.d.ts +18 -0
- package/cli/dist-server/types/node/channel/channel-manager.d.ts +41 -0
- package/cli/dist-server/types/node/channel/channel-permission-adapter.d.ts +27 -0
- package/cli/dist-server/types/node/channel/channel-protocol.d.ts +192 -0
- package/cli/dist-server/types/node/channel/channel-security-manager.d.ts +12 -0
- package/cli/dist-server/types/node/channel/index.d.ts +5 -0
- package/cli/dist-server/types/node/cli/tui-mode-service.d.ts +20 -0
- package/cli/dist-server/types/node/code-ratio/cli-git-commit-watcher.d.ts +142 -0
- package/cli/dist-server/types/node/code-ratio/cli-svn-commit-watcher.d.ts +111 -0
- package/cli/dist-server/types/node/code-ratio/code-ratio-reporting-service.d.ts +90 -0
- package/cli/dist-server/types/node/code-ratio/fs-file-reader.d.ts +26 -0
- package/cli/dist-server/types/node/code-ratio/index.d.ts +5 -0
- package/cli/dist-server/types/node/code-ratio/vcs-repo-resolver.d.ts +51 -0
- package/cli/dist-server/types/node/command/add-dir-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/agent-mode-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/agents-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/auto-compact-command-executor.d.ts +20 -0
- package/cli/dist-server/types/node/command/background-command-executor.d.ts +29 -0
- package/cli/dist-server/types/node/command/bash-command-executor.d.ts +62 -0
- package/cli/dist-server/types/node/command/btw-command-executor.d.ts +13 -0
- package/cli/dist-server/types/node/command/clear-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/command-manager.d.ts +54 -0
- package/cli/dist-server/types/node/command/command-protocol.d.ts +106 -0
- package/cli/dist-server/types/node/command/config-command-executor.d.ts +15 -0
- package/cli/dist-server/types/node/command/context-command-executor.d.ts +42 -0
- package/cli/dist-server/types/node/command/copy-command-executor.d.ts +10 -0
- package/cli/dist-server/types/node/command/cost-command-executor.d.ts +13 -0
- package/cli/dist-server/types/node/command/custom-command-renderer.d.ts +29 -0
- package/cli/dist-server/types/node/command/debug-command-executor.d.ts +15 -0
- package/cli/dist-server/types/node/command/deep-research-command-executor.d.ts +27 -0
- package/cli/dist-server/types/node/command/doctor-command-executor.d.ts +7 -0
- package/cli/dist-server/types/node/command/effort-command-executor.d.ts +68 -0
- package/cli/dist-server/types/node/command/exit-command-executor.d.ts +14 -0
- package/cli/dist-server/types/node/command/export-command-executor.d.ts +7 -0
- package/cli/dist-server/types/node/command/feedback-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/fork-bg-command-executor.d.ts +29 -0
- package/cli/dist-server/types/node/command/fork-command-executor.d.ts +28 -0
- package/cli/dist-server/types/node/command/goal-command-executor.d.ts +50 -0
- package/cli/dist-server/types/node/command/handoff-message-adapter.d.ts +9 -0
- package/cli/dist-server/types/node/command/help-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/hooks-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/ide-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/index.d.ts +66 -0
- package/cli/dist-server/types/node/command/local-shell.d.ts +31 -0
- package/cli/dist-server/types/node/command/mcp-command-executor.d.ts +15 -0
- package/cli/dist-server/types/node/command/mcp-prompt-renderer.d.ts +44 -0
- package/cli/dist-server/types/node/command/memory-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/model-image-to-image-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-image-to-video-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-lite-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-reasoning-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-text-to-image-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/model-text-to-video-command-executor.d.ts +17 -0
- package/cli/dist-server/types/node/command/multitask-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/permissions-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/plan-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/plugin-command-executor.d.ts +25 -0
- package/cli/dist-server/types/node/command/plugin-validate-command-executor.d.ts +21 -0
- package/cli/dist-server/types/node/command/release-notes-command-executor.d.ts +18 -0
- package/cli/dist-server/types/node/command/reload-plugins-command-executor.d.ts +22 -0
- package/cli/dist-server/types/node/command/remote-control-command-executor.d.ts +44 -0
- package/cli/dist-server/types/node/command/rename-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/reset-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/resume-command-executor.d.ts +21 -0
- package/cli/dist-server/types/node/command/rewind-command-executor.d.ts +10 -0
- package/cli/dist-server/types/node/command/sandbox-command-executor.d.ts +20 -0
- package/cli/dist-server/types/node/command/save-workflow-command-executor.d.ts +43 -0
- package/cli/dist-server/types/node/command/skills-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/stats-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/status-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/tasks-command-executor.d.ts +9 -0
- package/cli/dist-server/types/node/command/terminal-setup-command-executor.d.ts +7 -0
- package/cli/dist-server/types/node/command/theme-command-executor.d.ts +7 -0
- package/cli/dist-server/types/node/command/todos-command-executor.d.ts +16 -0
- package/cli/dist-server/types/node/command/upgrade-command-executor.d.ts +13 -0
- package/cli/dist-server/types/node/command/vim-command-executor.d.ts +11 -0
- package/cli/dist-server/types/node/command/web-command-executor.d.ts +18 -0
- package/cli/dist-server/types/node/command/workflows-command-executor.d.ts +26 -0
- package/cli/dist-server/types/node/command-parser/command-parser-protocol.d.ts +81 -0
- package/cli/dist-server/types/node/console/console-manager.d.ts +37 -0
- package/cli/dist-server/types/node/console/console-protocol.d.ts +112 -0
- package/cli/dist-server/types/node/console/index.d.ts +2 -0
- package/cli/dist-server/types/node/context/deferred-tools-description-builder.d.ts +145 -0
- package/cli/dist-server/types/node/context/token-calculator/token-calculator-protocol.d.ts +27 -0
- package/cli/dist-server/types/node/debug/debug-middleware.d.ts +8 -0
- package/cli/dist-server/types/node/debug/debug-protocol.d.ts +63 -0
- package/cli/dist-server/types/node/debug/debug-service.d.ts +26 -0
- package/cli/dist-server/types/node/debug/index.d.ts +3 -0
- package/cli/dist-server/types/node/elicitation/elicitation-service.d.ts +100 -0
- package/cli/dist-server/types/node/feedback/feedback-protocol.d.ts +32 -0
- package/cli/dist-server/types/node/feedback/feedback-service.d.ts +19 -0
- package/cli/dist-server/types/node/feedback/index.d.ts +2 -0
- package/cli/dist-server/types/node/galileo/agent-metrics-aggregator.d.ts +115 -0
- package/cli/dist-server/types/node/galileo/error-category.d.ts +65 -0
- package/cli/dist-server/types/node/galileo/galileo-chat-reporter.d.ts +302 -0
- package/cli/dist-server/types/node/galileo/galileo-protocol.d.ts +78 -0
- package/cli/dist-server/types/node/galileo/galileo-service.d.ts +171 -0
- package/cli/dist-server/types/node/galileo/galileo-session-bridge-protocol.d.ts +134 -0
- package/cli/dist-server/types/node/galileo/galileo-session-bridge.d.ts +105 -0
- package/cli/dist-server/types/node/galileo/galileo-timing-hook.d.ts +115 -0
- package/cli/dist-server/types/node/galileo/galileo-tool-error-report-hook.d.ts +32 -0
- package/cli/dist-server/types/node/galileo/galileo-tool-post-hook.d.ts +18 -0
- package/cli/dist-server/types/node/galileo/galileo-tool-pre-hook.d.ts +16 -0
- package/cli/dist-server/types/node/galileo/galileo-tool-start-report-hook.d.ts +14 -0
- package/cli/dist-server/types/node/galileo/galileo-tool-success-report-hook.d.ts +14 -0
- package/cli/dist-server/types/node/galileo/index.d.ts +15 -0
- package/cli/dist-server/types/node/galileo/session-error-tracker.d.ts +44 -0
- package/cli/dist-server/types/node/galileo/task-outcome-resolver.d.ts +28 -0
- package/cli/dist-server/types/node/galileo/task-outcome.d.ts +35 -0
- package/cli/dist-server/types/node/hooks/functional-hooks-protocol.d.ts +78 -0
- package/cli/dist-server/types/node/hooks/functional-hooks.d.ts +23 -0
- package/cli/dist-server/types/node/http/certificate-manager.d.ts +50 -0
- package/cli/dist-server/types/node/http/classify-network-error.d.ts +21 -0
- package/cli/dist-server/types/node/http/custom-header-http-interceptor.d.ts +14 -0
- package/cli/dist-server/types/node/http/custom-headers-provider.d.ts +26 -0
- package/cli/dist-server/types/node/http/fetch-proxy.d.ts +22 -0
- package/cli/dist-server/types/node/http/http-proxy-interceptor.d.ts +116 -0
- package/cli/dist-server/types/node/http/index.d.ts +6 -0
- package/cli/dist-server/types/node/ide-integration/ide-edit-manager.d.ts +53 -0
- package/cli/dist-server/types/node/ide-integration/ide-protocol.d.ts +450 -0
- package/cli/dist-server/types/node/install/index.d.ts +6 -0
- package/cli/dist-server/types/node/install/install-controller.d.ts +15 -0
- package/cli/dist-server/types/node/install/install-env.d.ts +12 -0
- package/cli/dist-server/types/node/install/install-protocol.d.ts +83 -0
- package/cli/dist-server/types/node/install/install-service.d.ts +36 -0
- package/cli/dist-server/types/node/install/releases-service.d.ts +29 -0
- package/cli/dist-server/types/node/install/shell-setup.d.ts +36 -0
- package/cli/dist-server/types/node/library-runtime.d.ts +9 -0
- package/cli/dist-server/types/node/loopback/endpoint-provider.d.ts +9 -0
- package/cli/dist-server/types/node/loopback/error-provider.d.ts +9 -0
- package/cli/dist-server/types/node/loopback/index.d.ts +4 -0
- package/cli/dist-server/types/node/loopback/loopback-body-limit.d.ts +52 -0
- package/cli/dist-server/types/node/lsp/index.d.ts +6 -0
- package/cli/dist-server/types/node/lsp/lsp-client.d.ts +104 -0
- package/cli/dist-server/types/node/lsp/lsp-manager.d.ts +90 -0
- package/cli/dist-server/types/node/lsp/lsp-protocol.d.ts +245 -0
- package/cli/dist-server/types/node/mcp/agent-scoped-mcp-manager.d.ts +38 -0
- package/cli/dist-server/types/node/mcp/index.d.ts +32 -0
- package/cli/dist-server/types/node/mcp/mcp-cli-config-initializer.d.ts +18 -0
- package/cli/dist-server/types/node/mcp/mcp-config-diagnostics-manager.d.ts +29 -0
- package/cli/dist-server/types/node/mcp/mcp-config-env-expand-service.d.ts +45 -0
- package/cli/dist-server/types/node/mcp/mcp-config-fingerprint.d.ts +28 -0
- package/cli/dist-server/types/node/mcp/mcp-config-manager.d.ts +110 -0
- package/cli/dist-server/types/node/mcp/mcp-config-store.d.ts +18 -0
- package/cli/dist-server/types/node/mcp/mcp-connection-manager.d.ts +35 -0
- package/cli/dist-server/types/node/mcp/mcp-controller.d.ts +56 -0
- package/cli/dist-server/types/node/mcp/mcp-descriptor-environment.d.ts +5 -0
- package/cli/dist-server/types/node/mcp/mcp-first-run-status-service.d.ts +37 -0
- package/cli/dist-server/types/node/mcp/mcp-log-service.d.ts +5 -0
- package/cli/dist-server/types/node/mcp/mcp-manager.d.ts +339 -0
- package/cli/dist-server/types/node/mcp/mcp-oauth-controller.d.ts +26 -0
- package/cli/dist-server/types/node/mcp/mcp-oauth-manager.d.ts +33 -0
- package/cli/dist-server/types/node/mcp/mcp-oauth-store.d.ts +30 -0
- package/cli/dist-server/types/node/mcp/mcp-permissions-manager.d.ts +52 -0
- package/cli/dist-server/types/node/mcp/mcp-plugin-registry.d.ts +39 -0
- package/cli/dist-server/types/node/mcp/mcp-ready-service.d.ts +94 -0
- package/cli/dist-server/types/node/mcp/mcp-resource-catalog-protocol.d.ts +62 -0
- package/cli/dist-server/types/node/mcp/mcp-resource-catalog.d.ts +32 -0
- package/cli/dist-server/types/node/mcp/mcp-server-manager.d.ts +283 -0
- package/cli/dist-server/types/node/mcp/mcp-server-model-manager.d.ts +14 -0
- package/cli/dist-server/types/node/mcp/mcp-subagent-tool-manager.d.ts +36 -0
- package/cli/dist-server/types/node/mcp/mcp-toggle-manager.d.ts +45 -0
- package/cli/dist-server/types/node/mcp/mcp-transport-manager.d.ts +34 -0
- package/cli/dist-server/types/node/mcp/mcp-validate-middleware.d.ts +25 -0
- package/cli/dist-server/types/node/mcp/node-websocket-transport.d.ts +38 -0
- package/cli/dist-server/types/node/mcp/official-mcp-egress-policy.d.ts +17 -0
- package/cli/dist-server/types/node/mcp/sdk-mcp-server.d.ts +149 -0
- package/cli/dist-server/types/node/mcp/sdk-mcp-transport.d.ts +97 -0
- package/cli/dist-server/types/node/memory/conditional-rules-service.d.ts +21 -0
- package/cli/dist-server/types/node/memory/glob-matcher.d.ts +16 -0
- package/cli/dist-server/types/node/memory/index.d.ts +20 -0
- package/cli/dist-server/types/node/memory/memory-age.d.ts +44 -0
- package/cli/dist-server/types/node/memory/memory-cache.d.ts +8 -0
- package/cli/dist-server/types/node/memory/memory-controller.d.ts +62 -0
- package/cli/dist-server/types/node/memory/memory-extraction-prompts.d.ts +11 -0
- package/cli/dist-server/types/node/memory/memory-extraction-service.d.ts +56 -0
- package/cli/dist-server/types/node/memory/memory-extraction-stop-hook.d.ts +18 -0
- package/cli/dist-server/types/node/memory/memory-freshness-post-tool-hook.d.ts +22 -0
- package/cli/dist-server/types/node/memory/memory-loader.d.ts +62 -0
- package/cli/dist-server/types/node/memory/memory-manager.d.ts +24 -0
- package/cli/dist-server/types/node/memory/memory-parser.d.ts +15 -0
- package/cli/dist-server/types/node/memory/memory-prompt-builder.d.ts +38 -0
- package/cli/dist-server/types/node/memory/memory-protocol.d.ts +235 -0
- package/cli/dist-server/types/node/memory/memory-relevance-protocol.d.ts +33 -0
- package/cli/dist-server/types/node/memory/memory-relevance-service.d.ts +30 -0
- package/cli/dist-server/types/node/memory/memory-scan.d.ts +35 -0
- package/cli/dist-server/types/node/memory/memory-types.d.ts +49 -0
- package/cli/dist-server/types/node/memory/memory-validator.d.ts +6 -0
- package/cli/dist-server/types/node/memory/subdirectory-memory-loader.d.ts +55 -0
- package/cli/dist-server/types/node/model/model-protocol.d.ts +22 -0
- package/cli/dist-server/types/node/multitask/session-flags.d.ts +110 -0
- package/cli/dist-server/types/node/multitask/types.d.ts +123 -0
- package/cli/dist-server/types/node/navigation/index.d.ts +2 -0
- package/cli/dist-server/types/node/navigation/navigation-manager.d.ts +12 -0
- package/cli/dist-server/types/node/navigation/navigation-protocol.d.ts +23 -0
- package/cli/dist-server/types/node/notification/notification-protocol.d.ts +19 -0
- package/cli/dist-server/types/node/output-style/output-style-protocol.d.ts +60 -0
- package/cli/dist-server/types/node/permission/brokered-sandbox/approval-coordinator.d.ts +32 -0
- package/cli/dist-server/types/node/permission/brokered-sandbox/host-protocol.d.ts +103 -0
- package/cli/dist-server/types/node/permission/canonicalize-command.d.ts +30 -0
- package/cli/dist-server/types/node/permission/codebuddy-sandbox-env.d.ts +35 -0
- package/cli/dist-server/types/node/permission/directory-trust-service.d.ts +45 -0
- package/cli/dist-server/types/node/permission/file-policy-assessment.d.ts +35 -0
- package/cli/dist-server/types/node/permission/index.d.ts +16 -0
- package/cli/dist-server/types/node/permission/permission-protocol.d.ts +9 -0
- package/cli/dist-server/types/node/permission/sandbox-attribution-analyzer.d.ts +108 -0
- package/cli/dist-server/types/node/permission/sandbox-audit-service.d.ts +40 -0
- package/cli/dist-server/types/node/permission/sandbox-exec-policy-builtin.d.ts +30 -0
- package/cli/dist-server/types/node/permission/sandbox-exec-policy-protocol.d.ts +67 -0
- package/cli/dist-server/types/node/permission/sandbox-exec-policy.d.ts +13 -0
- package/cli/dist-server/types/node/permission/sandbox-orchestrator-protocol.d.ts +239 -0
- package/cli/dist-server/types/node/permission/sandbox-orchestrator.d.ts +308 -0
- package/cli/dist-server/types/node/permission/sandbox-permission-gateway.d.ts +36 -0
- package/cli/dist-server/types/node/permission/sandbox-telemetry-context.d.ts +27 -0
- package/cli/dist-server/types/node/permission/sensitive-command-detector.d.ts +71 -0
- package/cli/dist-server/types/node/prewarm/prewarm-protocol.d.ts +296 -0
- package/cli/dist-server/types/node/product/api-key-helper-product-provider.d.ts +105 -0
- package/cli/dist-server/types/node/product/cli-options-product-provider.d.ts +30 -0
- package/cli/dist-server/types/node/product/cloud-pre-product-provider.d.ts +76 -0
- package/cli/dist-server/types/node/product/config-watch-service.d.ts +201 -0
- package/cli/dist-server/types/node/product/craft-to-cli-agent-models-sync-provider.d.ts +16 -0
- package/cli/dist-server/types/node/product/custom-agents-product-provider.d.ts +67 -0
- package/cli/dist-server/types/node/product/custom-commands-product-provider.d.ts +49 -0
- package/cli/dist-server/types/node/product/custom-product-config-provider.d.ts +6 -0
- package/cli/dist-server/types/node/product/index.d.ts +21 -0
- package/cli/dist-server/types/node/product/internet-enviroment-product-provider.d.ts +61 -0
- package/cli/dist-server/types/node/product/mcp-prompt-product-provider.d.ts +17 -0
- package/cli/dist-server/types/node/product/mcp-watch-service.d.ts +31 -0
- package/cli/dist-server/types/node/product/models-product-provider.d.ts +41 -0
- package/cli/dist-server/types/node/product/plugin-product-provider.d.ts +13 -0
- package/cli/dist-server/types/node/product/product-capabilities.d.ts +55 -0
- package/cli/dist-server/types/node/product/product-config-controller.d.ts +27 -0
- package/cli/dist-server/types/node/product/product-env-service.d.ts +20 -0
- package/cli/dist-server/types/node/product/product-identity.d.ts +57 -0
- package/cli/dist-server/types/node/product/product-protocol.d.ts +7 -0
- package/cli/dist-server/types/node/product/sdk-initialize-product-provider.d.ts +17 -0
- package/cli/dist-server/types/node/product/settings-endpoint-product-provider.d.ts +20 -0
- package/cli/dist-server/types/node/product/skill-product-provider.d.ts +62 -0
- package/cli/dist-server/types/node/references/index.d.ts +2 -0
- package/cli/dist-server/types/node/references/reference-protocol.d.ts +20 -0
- package/cli/dist-server/types/node/references/reference-service.d.ts +42 -0
- package/cli/dist-server/types/node/remote-control/remote-control-protocol.d.ts +288 -0
- package/cli/dist-server/types/node/runtime/add-dir-middleware.d.ts +13 -0
- package/cli/dist-server/types/node/runtime/cli-capabilities.d.ts +28 -0
- package/cli/dist-server/types/node/runtime/external-uri-opener.d.ts +8 -0
- package/cli/dist-server/types/node/runtime/file-local-storage.d.ts +17 -0
- package/cli/dist-server/types/node/runtime/host-capability-provider.d.ts +57 -0
- package/cli/dist-server/types/node/runtime/host-detection.d.ts +34 -0
- package/cli/dist-server/types/node/runtime/index.d.ts +8 -0
- package/cli/dist-server/types/node/runtime/workspace-folder-manager.d.ts +45 -0
- package/cli/dist-server/types/node/runtime/workspace.d.ts +5 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-backend-support.d.ts +7 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-cli-lifecycle-protocol.d.ts +109 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-cli-protocol.d.ts +376 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-rule-sync-service.d.ts +310 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-session-preparation.d.ts +49 -0
- package/cli/dist-server/types/node/sandbox-cli/sandbox-turn-config.d.ts +32 -0
- package/cli/dist-server/types/node/sandbox-cli/threat-domain-checker.d.ts +137 -0
- package/cli/dist-server/types/node/security-review/gate.d.ts +13 -0
- package/cli/dist-server/types/node/security-review/index.d.ts +2 -0
- package/cli/dist-server/types/node/security-review/protocol.d.ts +14 -0
- package/cli/dist-server/types/node/sensitive-content/index.d.ts +15 -0
- package/cli/dist-server/types/node/sensitive-content/managed-cipher-stream-restorer.d.ts +22 -0
- package/cli/dist-server/types/node/sensitive-content/sandbox-center-ipc-client-protocol.d.ts +3 -0
- package/cli/dist-server/types/node/sensitive-content/sandbox-center-ipc-client.d.ts +7 -0
- package/cli/dist-server/types/node/sensitive-content/sandbox-center-port.d.ts +17 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-approval-port.d.ts +22 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-content-mediation.d.ts +6 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-decision-mediation.d.ts +69 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-history-admission.d.ts +42 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-history-replay.d.ts +6 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-local-sideband.d.ts +21 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-model-boundary.d.ts +22 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-protection-metadata.d.ts +7 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-session-grants.d.ts +41 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-tool-egress-guard.d.ts +7 -0
- package/cli/dist-server/types/node/sensitive-content/sensitive-user-input-review.d.ts +7 -0
- package/cli/dist-server/types/node/sensitive-content/settings-sensitive-protection-policy.d.ts +14 -0
- package/cli/dist-server/types/node/server/types.d.ts +3 -1
- package/cli/dist-server/types/node/session/index.d.ts +15 -0
- package/cli/dist-server/types/node/session/input-history-service.d.ts +47 -0
- package/cli/dist-server/types/node/session/input-item-processors.d.ts +70 -0
- package/cli/dist-server/types/node/session/session-abort-middleware.d.ts +22 -0
- package/cli/dist-server/types/node/session/session-controller.d.ts +126 -0
- package/cli/dist-server/types/node/session/session-history-clean-flag.d.ts +2 -0
- package/cli/dist-server/types/node/session/session-history-clean-service.d.ts +49 -0
- package/cli/dist-server/types/node/session/session-hook-host-adapter.d.ts +21 -0
- package/cli/dist-server/types/node/session/session-host-adapter.d.ts +34 -0
- package/cli/dist-server/types/node/session/session-http-protocol.d.ts +1 -0
- package/cli/dist-server/types/node/session/session-interruption-host-adapter.d.ts +115 -0
- package/cli/dist-server/types/node/session/session-manager-host-adapter.d.ts +100 -0
- package/cli/dist-server/types/node/session/session-middleware.d.ts +68 -0
- package/cli/dist-server/types/node/session/session-response-host-adapter.d.ts +9 -0
- package/cli/dist-server/types/node/session/session-store-host-adapter.d.ts +23 -0
- package/cli/dist-server/types/node/session/tasks-controller.d.ts +80 -0
- package/cli/dist-server/types/node/settings/current-session-model-transition-protocol.d.ts +23 -0
- package/cli/dist-server/types/node/settings/current-session-model-transition.d.ts +15 -0
- package/cli/dist-server/types/node/settings/index.d.ts +8 -0
- package/cli/dist-server/types/node/settings/settings-controller.d.ts +23 -0
- package/cli/dist-server/types/node/settings/settings-manager.d.ts +1 -0
- package/cli/dist-server/types/node/settings/settings-protocol.d.ts +4 -0
- package/cli/dist-server/types/node/settings/settings-validate-middleware.d.ts +9 -0
- package/cli/dist-server/types/node/shell/delegating-shell-service.d.ts +44 -0
- package/cli/dist-server/types/node/shell/driver-shell-service.d.ts +8 -0
- package/cli/dist-server/types/node/shell/index.d.ts +10 -0
- package/cli/dist-server/types/node/shell/language-shim-env.d.ts +11 -0
- package/cli/dist-server/types/node/shell/output-spiller.d.ts +39 -0
- package/cli/dist-server/types/node/shell/powershell-safe-delete.d.ts +16 -0
- package/cli/dist-server/types/node/shell/safe-delete/bulk-guard/contract.d.ts +61 -0
- package/cli/dist-server/types/node/shell/safe-delete/bulk-guard/index.d.ts +3 -0
- package/cli/dist-server/types/node/shell/safe-delete/bulk-guard/marker.d.ts +5 -0
- package/cli/dist-server/types/node/shell/safe-delete/bulk-guard/service.d.ts +12 -0
- package/cli/dist-server/types/node/shell/safe-delete/index.d.ts +17 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-attribution.d.ts +16 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-bootstrap.d.ts +1 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-env.d.ts +42 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-report.d.ts +18 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-sandbox-helpers.d.ts +39 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-settings.d.ts +42 -0
- package/cli/dist-server/types/node/shell/safe-delete/safe-delete-trash-service.d.ts +12 -0
- package/cli/dist-server/types/node/shell/shell-protocol.d.ts +287 -0
- package/cli/dist-server/types/node/shell/shell-runtime-paths.d.ts +23 -0
- package/cli/dist-server/types/node/shell/shell-service.d.ts +257 -0
- package/cli/dist-server/types/node/shell/shell-snapshot-protocol.d.ts +75 -0
- package/cli/dist-server/types/node/shell/shell-snapshot-service.d.ts +86 -0
- package/cli/dist-server/types/node/shell/terminal-serializer.d.ts +26 -0
- package/cli/dist-server/types/node/shell/truncate-buffer.d.ts +24 -0
- package/cli/dist-server/types/node/shell/windows-process-utils.d.ts +42 -0
- package/cli/dist-server/types/node/shortcut/shortcut-protocol.d.ts +41 -0
- package/cli/dist-server/types/node/skills/skill-approval.d.ts +31 -0
- package/cli/dist-server/types/node/stats/index.d.ts +5 -0
- package/cli/dist-server/types/node/stats/insights-protocol.d.ts +59 -0
- package/cli/dist-server/types/node/stats/insights-report-service.d.ts +17 -0
- package/cli/dist-server/types/node/stats/session-facet-service.d.ts +46 -0
- package/cli/dist-server/types/node/stats/stats-protocol.d.ts +145 -0
- package/cli/dist-server/types/node/stats/stats-service.d.ts +48 -0
- package/cli/dist-server/types/node/telemetry/cost-protocol.d.ts +67 -0
- package/cli/dist-server/types/node/telemetry/cost-service.d.ts +21 -0
- package/cli/dist-server/types/node/telemetry/extension-info-processor.d.ts +13 -0
- package/cli/dist-server/types/node/telemetry/friction-analysis.d.ts +54 -0
- package/cli/dist-server/types/node/telemetry/friction-recall-client.d.ts +15 -0
- package/cli/dist-server/types/node/telemetry/host-ide-info-processor.d.ts +11 -0
- package/cli/dist-server/types/node/telemetry/index.d.ts +21 -0
- package/cli/dist-server/types/node/telemetry/logger/index.d.ts +1 -0
- package/cli/dist-server/types/node/telemetry/logger/storage-path-provider.d.ts +4 -0
- package/cli/dist-server/types/node/telemetry/plugin-telemetry-protocol.d.ts +68 -0
- package/cli/dist-server/types/node/telemetry/plugin-telemetry-service.d.ts +31 -0
- package/cli/dist-server/types/node/telemetry/qimei-env-detector.d.ts +16 -0
- package/cli/dist-server/types/node/telemetry/sandbox-telemetry-protocol.d.ts +164 -0
- package/cli/dist-server/types/node/telemetry/sandbox-telemetry-service.d.ts +181 -0
- package/cli/dist-server/types/node/telemetry/startup-profiler.d.ts +32 -0
- package/cli/dist-server/types/node/telemetry/status-reporter.d.ts +39 -0
- package/cli/dist-server/types/node/telemetry/telemetry-client-carrier.d.ts +14 -0
- package/cli/dist-server/types/node/telemetry/telemetry-client-info-event-processor.d.ts +8 -0
- package/cli/dist-server/types/node/telemetry/telemetry-protocol.d.ts +137 -0
- package/cli/dist-server/types/node/telemetry/telemetry-service.d.ts +115 -0
- package/cli/dist-server/types/node/telemetry/turn-baggage-processor.d.ts +23 -0
- package/cli/dist-server/types/node/telemetry/vcs-event-processor.d.ts +19 -0
- package/cli/dist-server/types/node/tips/builtin-tips.d.ts +2 -0
- package/cli/dist-server/types/node/tips/index.d.ts +4 -0
- package/cli/dist-server/types/node/tips/tips-manager.d.ts +14 -0
- package/cli/dist-server/types/node/tips/tips-protocol.d.ts +42 -0
- package/cli/dist-server/types/node/tips/user-state-manager.d.ts +25 -0
- package/cli/dist-server/types/node/tool-control/index.d.ts +1 -0
- package/cli/dist-server/types/node/tool-control/tool-control-policy.d.ts +34 -0
- package/cli/dist-server/types/node/tools/a2a-cancel-task-tool.d.ts +55 -0
- package/cli/dist-server/types/node/tools/a2a-get-agent-card-tool.d.ts +59 -0
- package/cli/dist-server/types/node/tools/a2a-get-task-tool.d.ts +334 -0
- package/cli/dist-server/types/node/tools/a2a-send-message-tool.d.ts +168 -0
- package/cli/dist-server/types/node/tools/a2a-tool-guards.d.ts +48 -0
- package/cli/dist-server/types/node/tools/agent-tool.d.ts +202 -0
- package/cli/dist-server/types/node/tools/artifact-control-tool.d.ts +103 -0
- package/cli/dist-server/types/node/tools/artifact-tool.d.ts +96 -0
- package/cli/dist-server/types/node/tools/ask-user-for-structured-input-tool.d.ts +127 -0
- package/cli/dist-server/types/node/tools/ask-user-question-tool.d.ts +237 -0
- package/cli/dist-server/types/node/tools/audio-transcribe-service.d.ts +61 -0
- package/cli/dist-server/types/node/tools/audio-transcribe-tool.d.ts +66 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-allow-filter.d.ts +33 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-classifier-client.d.ts +230 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-critique-client.d.ts +51 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-defaults.d.ts +16 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-denial-tracker.d.ts +114 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-permission-service.d.ts +51 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-project-instructions.d.ts +26 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-protocol.d.ts +140 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-settings.d.ts +36 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-strategy.d.ts +21 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-system-prompt-builder.d.ts +28 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-timeout.d.ts +16 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-transcript-limit.d.ts +29 -0
- package/cli/dist-server/types/node/tools/auto-mode/auto-mode-transcript.d.ts +50 -0
- package/cli/dist-server/types/node/tools/auto-mode/index.d.ts +15 -0
- package/cli/dist-server/types/node/tools/auto-mode/permission-mode-policy.d.ts +63 -0
- package/cli/dist-server/types/node/tools/bash-output-tool.d.ts +34 -0
- package/cli/dist-server/types/node/tools/bash-sandbox-approval-requester.d.ts +55 -0
- package/cli/dist-server/types/node/tools/bash-tool.d.ts +211 -0
- package/cli/dist-server/types/node/tools/brief-mode-service.d.ts +26 -0
- package/cli/dist-server/types/node/tools/channel-tasks-tool.d.ts +174 -0
- package/cli/dist-server/types/node/tools/computer-use-tool.d.ts +86 -0
- package/cli/dist-server/types/node/tools/create-channel-tool.d.ts +82 -0
- package/cli/dist-server/types/node/tools/create-colleague-tool.d.ts +64 -0
- package/cli/dist-server/types/node/tools/cron-create-tool.d.ts +46 -0
- package/cli/dist-server/types/node/tools/cron-delete-tool.d.ts +28 -0
- package/cli/dist-server/types/node/tools/cron-list-tool.d.ts +27 -0
- package/cli/dist-server/types/node/tools/defer-execute-tool.d.ts +265 -0
- package/cli/dist-server/types/node/tools/defer-tool-config-protocol.d.ts +88 -0
- package/cli/dist-server/types/node/tools/defer-tool-config-service.d.ts +23 -0
- package/cli/dist-server/types/node/tools/deferred-tool-bridge.d.ts +50 -0
- package/cli/dist-server/types/node/tools/delegate-tool.d.ts +71 -0
- package/cli/dist-server/types/node/tools/edit-tool.d.ts +83 -0
- package/cli/dist-server/types/node/tools/enter-planmode-tool.d.ts +29 -0
- package/cli/dist-server/types/node/tools/enter-worktree-tool.d.ts +59 -0
- package/cli/dist-server/types/node/tools/exit-planmode-tool.d.ts +86 -0
- package/cli/dist-server/types/node/tools/file-change-artifact-publisher.d.ts +82 -0
- package/cli/dist-server/types/node/tools/glob-tool.d.ts +102 -0
- package/cli/dist-server/types/node/tools/grep-tool.d.ts +141 -0
- package/cli/dist-server/types/node/tools/image-edit-tool.d.ts +94 -0
- package/cli/dist-server/types/node/tools/image-gen-tool.d.ts +107 -0
- package/cli/dist-server/types/node/tools/image-service.d.ts +113 -0
- package/cli/dist-server/types/node/tools/index.d.ts +109 -0
- package/cli/dist-server/types/node/tools/kill-shell-tool.d.ts +27 -0
- package/cli/dist-server/types/node/tools/leave-worktree-tool.d.ts +54 -0
- package/cli/dist-server/types/node/tools/library-upload-tool.d.ts +70 -0
- package/cli/dist-server/types/node/tools/list-colleagues-tool.d.ts +35 -0
- package/cli/dist-server/types/node/tools/list-mcp-resources-tool.d.ts +58 -0
- package/cli/dist-server/types/node/tools/lsp-tool.d.ts +68 -0
- package/cli/dist-server/types/node/tools/main-agent-meta-tools.d.ts +107 -0
- package/cli/dist-server/types/node/tools/memory-tool.d.ts +33 -0
- package/cli/dist-server/types/node/tools/message-colleague-tool.d.ts +83 -0
- package/cli/dist-server/types/node/tools/monitor-tool.d.ts +216 -0
- package/cli/dist-server/types/node/tools/multi-edit-tool.d.ts +109 -0
- package/cli/dist-server/types/node/tools/notebook-edit-tool.d.ts +75 -0
- package/cli/dist-server/types/node/tools/notebook-read-tool.d.ts +55 -0
- package/cli/dist-server/types/node/tools/notebook-write-tool.d.ts +7 -0
- package/cli/dist-server/types/node/tools/plan-storage-service.d.ts +68 -0
- package/cli/dist-server/types/node/tools/powershell-clm-types.d.ts +30 -0
- package/cli/dist-server/types/node/tools/powershell-command-semantics.d.ts +23 -0
- package/cli/dist-server/types/node/tools/powershell-dangerous-cmdlets.d.ts +72 -0
- package/cli/dist-server/types/node/tools/powershell-destructive-warning.d.ts +12 -0
- package/cli/dist-server/types/node/tools/powershell-detection.d.ts +51 -0
- package/cli/dist-server/types/node/tools/powershell-git-safety.d.ts +60 -0
- package/cli/dist-server/types/node/tools/powershell-security.d.ts +93 -0
- package/cli/dist-server/types/node/tools/powershell-tool.d.ts +174 -0
- package/cli/dist-server/types/node/tools/produced-artifact-report.d.ts +35 -0
- package/cli/dist-server/types/node/tools/push-notification-tool.d.ts +55 -0
- package/cli/dist-server/types/node/tools/read-file-state-service.d.ts +27 -0
- package/cli/dist-server/types/node/tools/read-mcp-resource-tool.d.ts +71 -0
- package/cli/dist-server/types/node/tools/read-tool.d.ts +71 -0
- package/cli/dist-server/types/node/tools/repl/index.d.ts +10 -0
- package/cli/dist-server/types/node/tools/repl/repl-bridge-broker.d.ts +150 -0
- package/cli/dist-server/types/node/tools/repl/repl-bridge-host.d.ts +29 -0
- package/cli/dist-server/types/node/tools/repl/repl-catalog-protocol.d.ts +149 -0
- package/cli/dist-server/types/node/tools/repl/repl-catalog-render.d.ts +56 -0
- package/cli/dist-server/types/node/tools/repl/repl-catalog-source.d.ts +108 -0
- package/cli/dist-server/types/node/tools/repl/repl-import-rewrite.d.ts +17 -0
- package/cli/dist-server/types/node/tools/repl/repl-protocol.d.ts +210 -0
- package/cli/dist-server/types/node/tools/repl/repl-tool.d.ts +142 -0
- package/cli/dist-server/types/node/tools/repl/repl-worker-manager.d.ts +103 -0
- package/cli/dist-server/types/node/tools/repl/repl-worker-source.d.ts +16 -0
- package/cli/dist-server/types/node/tools/repl/repl-worker-source.generated.d.ts +2 -0
- package/cli/dist-server/types/node/tools/report-findings-tool.d.ts +97 -0
- package/cli/dist-server/types/node/tools/sandbox-approval-review.d.ts +40 -0
- package/cli/dist-server/types/node/tools/sandbox-permission-file-tool.d.ts +14 -0
- package/cli/dist-server/types/node/tools/sandbox-write-rule-guard.d.ts +126 -0
- package/cli/dist-server/types/node/tools/send-message-tool.d.ts +116 -0
- package/cli/dist-server/types/node/tools/send-user-message-attachments.d.ts +22 -0
- package/cli/dist-server/types/node/tools/send-user-message-tool.d.ts +60 -0
- package/cli/dist-server/types/node/tools/shell-stream-pusher.d.ts +25 -0
- package/cli/dist-server/types/node/tools/skill-manage-tool.d.ts +77 -0
- package/cli/dist-server/types/node/tools/skill-tool.d.ts +129 -0
- package/cli/dist-server/types/node/tools/slash-command-tool.d.ts +51 -0
- package/cli/dist-server/types/node/tools/space-upload/errors.d.ts +14 -0
- package/cli/dist-server/types/node/tools/space-upload/index.d.ts +4 -0
- package/cli/dist-server/types/node/tools/space-upload/local-file-source.d.ts +33 -0
- package/cli/dist-server/types/node/tools/space-upload/types.d.ts +65 -0
- package/cli/dist-server/types/node/tools/space-upload/upload-file.d.ts +27 -0
- package/cli/dist-server/types/node/tools/speak-in-channel-tool.d.ts +182 -0
- package/cli/dist-server/types/node/tools/structured-output-tool.d.ts +43 -0
- package/cli/dist-server/types/node/tools/task-create-tool.d.ts +71 -0
- package/cli/dist-server/types/node/tools/task-get-tool.d.ts +31 -0
- package/cli/dist-server/types/node/tools/task-list-tool.d.ts +20 -0
- package/cli/dist-server/types/node/tools/task-output-tool.d.ts +142 -0
- package/cli/dist-server/types/node/tools/task-stop-tool.d.ts +61 -0
- package/cli/dist-server/types/node/tools/task-storage-service.d.ts +161 -0
- package/cli/dist-server/types/node/tools/task-update-tool.d.ts +79 -0
- package/cli/dist-server/types/node/tools/team-create-tool.d.ts +84 -0
- package/cli/dist-server/types/node/tools/team-delete-tool.d.ts +38 -0
- package/cli/dist-server/types/node/tools/todo-storage-service.d.ts +48 -0
- package/cli/dist-server/types/node/tools/todo-write-tool.d.ts +117 -0
- package/cli/dist-server/types/node/tools/tool-always-approval-service.d.ts +73 -0
- package/cli/dist-server/types/node/tools/tool-argument-rewrite-service.d.ts +4 -0
- package/cli/dist-server/types/node/tools/tool-error-codes.d.ts +140 -0
- package/cli/dist-server/types/node/tools/tool-hook-manager.d.ts +61 -0
- package/cli/dist-server/types/node/tools/tool-manager.d.ts +585 -0
- package/cli/dist-server/types/node/tools/tool-permission-service.d.ts +145 -0
- package/cli/dist-server/types/node/tools/tool-permission-strategy.d.ts +83 -0
- package/cli/dist-server/types/node/tools/tool-protocol.d.ts +2 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/content-history-admission.d.ts +10 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/content-review.d.ts +56 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/execution-approval-adapter.d.ts +11 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/index.d.ts +7 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/mcp-permission-review.d.ts +15 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/mcp-projector.d.ts +5 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/permission-metadata.d.ts +8 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/projector-registry.d.ts +22 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/projectors/index.d.ts +5 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/prompt.d.ts +6 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/protocol.d.ts +231 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/review-context-build.d.ts +2 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/review-context.d.ts +42 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/review-runtime.d.ts +6 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/reviewer-client-impl.d.ts +3 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/reviewer-client.d.ts +37 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/scope.d.ts +6 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/service.d.ts +75 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/session-state.d.ts +49 -0
- package/cli/dist-server/types/node/tools/tool-risk-review/trusted-builtin-code.d.ts +25 -0
- package/cli/dist-server/types/node/tools/tool-search-protocol.d.ts +286 -0
- package/cli/dist-server/types/node/tools/tool-search-service.d.ts +137 -0
- package/cli/dist-server/types/node/tools/tool-search-tool.d.ts +103 -0
- package/cli/dist-server/types/node/tools/tool-spec/agent-tool-defer-overlay-cache.d.ts +45 -0
- package/cli/dist-server/types/node/tools/tool-spec/index.d.ts +6 -0
- package/cli/dist-server/types/node/tools/tool-spec/legacy-ide-tool-names.d.ts +2 -0
- package/cli/dist-server/types/node/tools/tool-spec/tool-defer-overlay.d.ts +70 -0
- package/cli/dist-server/types/node/tools/tool-spec/tool-spec-augment.d.ts +17 -0
- package/cli/dist-server/types/node/tools/tool-spec/tool-spec-parser.d.ts +38 -0
- package/cli/dist-server/types/node/tools/tool-spec/tool-spec-protocol.d.ts +83 -0
- package/cli/dist-server/types/node/tools/video-gen-tool.d.ts +88 -0
- package/cli/dist-server/types/node/tools/video-service.d.ts +57 -0
- package/cli/dist-server/types/node/tools/wait-for-mcp-servers-tool.d.ts +79 -0
- package/cli/dist-server/types/node/tools/web-fetch-tool.d.ts +164 -0
- package/cli/dist-server/types/node/tools/web-search-tool.d.ts +79 -0
- package/cli/dist-server/types/node/tools/wechat-reply-tool.d.ts +43 -0
- package/cli/dist-server/types/node/tools/wecom-reply-tool.d.ts +65 -0
- package/cli/dist-server/types/node/tools/workflow-background-task.d.ts +54 -0
- package/cli/dist-server/types/node/tools/workflow-tool.d.ts +83 -0
- package/cli/dist-server/types/node/tools/write-tool.d.ts +80 -0
- package/cli/dist-server/types/node/trace/trace-collector-protocol.d.ts +203 -0
- package/cli/dist-server/types/node/utils/installation-utils.d.ts +35 -0
- package/cli/dist-server/types/node/utils/osc-protocol-utils.d.ts +209 -0
- package/cli/dist-server/types/node/utils/process-identity.d.ts +40 -0
- package/cli/dist-server/types/node/utils/security-audit-log.d.ts +134 -0
- package/cli/dist-server/types/node/utils/terminal-detector-utils.d.ts +78 -0
- package/cli/dist-server/types/node/vim/index.d.ts +2 -0
- package/cli/dist-server/types/node/vim/vim-manager.d.ts +12 -0
- package/cli/dist-server/types/node/vim/vim-protocol.d.ts +24 -0
- package/cli/dist-server/types/vendor/cbc-core/node/agent/agent-protocol.d.ts +7 -2
- package/cli/dist-server/types/vendor/cbc-core/node/agent/reviewer-recovery.d.ts +7 -0
- package/cli/dist-server/types/vendor/cbc-core/node/context/mods-bridge.d.ts +38 -2
- package/cli/dist-server/types/vendor/cbc-core/node/session/interruption-service.d.ts +4 -0
- package/cli/dist-server/types/vendor/cbc-core/node/session/session-hook-host-protocol.d.ts +2 -1
- package/cli/dist-server/types/vendor/cbc-core/node/session/session-interruption-host-protocol.d.ts +3 -0
- package/cli/dist-server/types/vendor/cbc-core/node/session/session-protocol.d.ts +6 -0
- package/cli/dist-server/types/vendor/cbc-core/node/session/session-store.d.ts +46 -7
- package/cli/dist-server/types/vendor/cbc-core/node/session-title/session-title-utils.d.ts +36 -0
- package/cli/dist-server/types/vendor/cbc-core/node/utils/history-utils.d.ts +37 -9
- package/cli/dist-server/types/vendor/cbc-core/node/utils/input-item-utils.d.ts +27 -0
- package/cli/dist-server/types/vendor/cbc-core/node/utils/model-utils.d.ts +9 -5
- package/cli/dist-server/types/vendor/cbc-shared/node/agent/custom-input-item-types.d.ts +20 -0
- package/cli/dist-server/types/vendor/cbc-shared/node/agent/openai-agents-types.d.ts +2 -2
- package/cli/dist-server/types/vendor/cbc-shared/node/model/model-errors.d.ts +23 -6
- package/cli/dist-server/types/workspace/agent-client-protocol/lib/common/prompt-codec.d.ts +2 -0
- package/cli/dist-server/types/workspace/agent-client-protocol/lib/common/security-review-reason-code.d.ts +0 -10
- package/cli/dist-server/types/workspace/cbc-checkpoint/lib/node/checkpoint/checkpoint-path-utils.d.ts +10 -0
- package/cli/dist-server/types/workspace/cbc-checkpoint/lib/node/checkpoint/checkpoint-service.d.ts +2 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/agent/agent-protocol.d.ts +7 -2
- package/cli/dist-server/types/workspace/cbc-core/lib/node/agent/reviewer-recovery.d.ts +7 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/context/mods-bridge.d.ts +38 -2
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session/interruption-service.d.ts +4 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session/session-hook-host-protocol.d.ts +2 -1
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session/session-interruption-host-protocol.d.ts +3 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session/session-protocol.d.ts +6 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session/session-store.d.ts +46 -7
- package/cli/dist-server/types/workspace/cbc-core/lib/node/session-title/session-title-utils.d.ts +36 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/utils/history-utils.d.ts +37 -9
- package/cli/dist-server/types/workspace/cbc-core/lib/node/utils/input-item-utils.d.ts +27 -0
- package/cli/dist-server/types/workspace/cbc-core/lib/node/utils/model-utils.d.ts +9 -5
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-parser.d.ts +34 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-protocol.d.ts +191 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-scheduler-service.d.ts +131 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-scheduler.d.ts +20 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-state-manager.d.ts +50 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-storage.d.ts +61 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/cron-task-session.d.ts +1 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/index.d.ts +8 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/cron/loop-skill-provider.d.ts +36 -0
- package/cli/dist-server/types/workspace/cbc-cron/lib/node/index.d.ts +10 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/bg-session-handler.d.ts +88 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-auto-restart.d.ts +61 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-channel-autoconnect.d.ts +28 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-enhancements-lifecycle.d.ts +45 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-process.d.ts +77 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-protocol.d.ts +324 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-service.d.ts +45 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/index.d.ts +10 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/session-registry.d.ts +39 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/system-service.d.ts +60 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/wake-detector.d.ts +47 -0
- package/cli/dist-server/types/workspace/cbc-daemon/lib/node/index.d.ts +11 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-format.d.ts +25 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-policy.d.ts +55 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-protocol.d.ts +204 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-service.d.ts +353 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-session-start-hook.d.ts +25 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/goal-utils.d.ts +23 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/goal/index.d.ts +6 -0
- package/cli/dist-server/types/workspace/cbc-goal/lib/node/index.d.ts +12 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/index.d.ts +35 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/builtin/index.d.ts +14 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/builtin/sec-default.d.ts +32 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/builtin/telemetry.d.ts +43 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/enable-flag.d.ts +41 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/engine-builder.d.ts +61 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/hooks-registry.d.ts +188 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/index.d.ts +6 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/mods-runtime.d.ts +101 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/op-table.d.ts +37 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/engine/pattern.d.ts +20 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/core-handler.d.ts +78 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/host-bindings.d.ts +215 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/index.d.ts +6 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/plugin-store.d.ts +22 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/render-component.d.ts +115 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/render-registry.d.ts +99 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/host/terminal-play.d.ts +56 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/index.d.ts +9 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/legacy-adapter/fan-out.d.ts +23 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/legacy-adapter/hook-result-mapper.d.ts +27 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/legacy-adapter/index.d.ts +2 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/bootstrap.d.ts +104 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/bundle-cache.d.ts +59 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/index.d.ts +8 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/isolated-import.d.ts +20 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/load-mod.d.ts +151 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/manifest-dir.d.ts +33 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/mounted-import.d.ts +12 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/ts-runtime.d.ts +64 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/loader/types-emitter.d.ts +105 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/testing/harness.d.ts +84 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/testing/index.d.ts +1 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events/agent.d.ts +188 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events/command.d.ts +114 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events/prompt.d.ts +310 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events/tool.d.ts +308 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events/upstream.d.ts +8777 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/events.d.ts +651 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/mods/types/index.d.ts +1 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/concurrency.d.ts +1 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/dependency-resolver.d.ts +43 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/directory-plugin-cache-projection.d.ts +2 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/guards/index.d.ts +2 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/guards/weixinpay-integrity-guard.d.ts +48 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/index.d.ts +42 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/installers/git-plugin-installer.d.ts +42 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/installers/git-subdir-plugin-installer.d.ts +19 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/installers/index.d.ts +4 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/installers/local-plugin-installer.d.ts +40 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/installers/npm-plugin-installer.d.ts +23 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/agent-loader.d.ts +43 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/command-loader.d.ts +39 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/hook-loader.d.ts +55 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/index.d.ts +8 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/lsp-loader.d.ts +47 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/mcp-loader.d.ts +75 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/output-style-loader.d.ts +49 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/plugin-loader-manager.d.ts +73 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/loaders/skill-loader.d.ts +45 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplace-name-validator.d.ts +50 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplace-path-safety.d.ts +86 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/base-marketplace.d.ts +48 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/builtin-marketplace-provider.d.ts +47 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/directory-marketplace.d.ts +19 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/git-availability-detector.d.ts +62 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/git-fallback-coordinator.d.ts +42 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/git-to-zip-url-converter.d.ts +50 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/github-marketplace.d.ts +41 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/http-marketplace.d.ts +47 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/index.d.ts +13 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/marketplace-config-manager.d.ts +43 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/marketplace-factory.d.ts +12 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/marketplace-storage.d.ts +142 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/marketplace-update-checker.d.ts +41 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/marketplaces/zip-marketplace.d.ts +150 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/mcpb-handler.d.ts +29 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-controller.d.ts +77 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-environment.d.ts +36 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-error-collector.d.ts +17 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-install-stats-service.d.ts +20 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-manager.d.ts +765 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-mcp-snapshot.d.ts +63 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-options-storage.d.ts +87 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-policy-service.d.ts +55 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-protocol.d.ts +1567 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-read-summary.d.ts +61 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-runtime-refresh-service.d.ts +262 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/plugin-validator.d.ts +48 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/session-plugin-snapshot.d.ts +5 -0
- package/cli/dist-server/types/workspace/cbc-plugins/lib/node/plugins/zip-utils.d.ts +94 -0
- package/cli/dist-server/types/workspace/cbc-shared/lib/node/agent/custom-input-item-types.d.ts +20 -0
- package/cli/dist-server/types/workspace/cbc-shared/lib/node/agent/openai-agents-types.d.ts +2 -2
- package/cli/dist-server/types/workspace/cbc-shared/lib/node/model/model-errors.d.ts +23 -6
- package/cli/dist-server/types/workspace/code-ratio/lib/common/code-ratio-protocol.d.ts +124 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/code-ratio-reporter.d.ts +57 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/diff/unified-diff.d.ts +37 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/feature-gate.d.ts +59 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/filters/file-filter.d.ts +41 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/index.d.ts +6 -0
- package/cli/dist-server/types/workspace/code-ratio/lib/common/vcs-repo-resolver-protocol.d.ts +50 -0
- package/cli/dist-server/types/workspace/product/lib/common/index.d.ts +1 -0
- package/cli/dist-server/types/workspace/product/lib/common/repo-params.d.ts +14 -0
- package/cli/dist-server/types/workspace/product/lib/common/types/features.d.ts +35 -22
- package/cli/dist-server/types/workspace/product/lib/common/types/index.d.ts +0 -1
- package/cli/dist-server/types/workspace/product/lib/common/types/language-model.d.ts +1 -0
- package/cli/dist-server/types/workspace/product/lib/common/types/product.d.ts +0 -7
- package/cli/dist-server/types/workspace/sandbox-cli/lib/common/protocol.generated.d.ts +392 -0
- package/cli/dist-server/types/workspace/sandbox-cli/lib/node/file-policy.d.ts +48 -0
- package/cli/dist-server/types/workspace/sandbox-cli/lib/node/resolver.d.ts +95 -0
- package/cli/dist-server/types/workspace/sandbox-cli/lib/node/sandbox-cli-client.d.ts +78 -0
- package/cli/dist-server/types/workspace/telemetry/lib/common/event/types/security-review.d.ts +35 -6
- package/cli/dist-server/types/workspace/telemetry/lib/common/tracing/index.d.ts +1 -1
- package/cli/dist-server/types/workspace/telemetry/lib/common/tracing/otel-env.d.ts +1 -0
- package/cli/package.json +1 -1
- package/cli/product.cloudhosted.json +1 -1
- package/cli/product.internal.json +1 -1
- package/cli/product.ioa.json +1 -1
- package/cli/product.json +1 -1
- package/cli/product.selfhosted.json +1 -1
- package/docs/client.md +41 -0
- package/docs/in-process.md +151 -14
- package/docs/server.md +40 -1
- package/executor/lib/capsule/THIRD_PARTY_LICENSES.md +2 -2
- package/executor/lib/capsule/entry.mjs +8 -8
- package/executor/lib/capsule/manifest.json +2 -2
- package/executor/lib/private-protocol.cjs +33 -2
- package/executor/lib/private-protocol.d.cts +21 -1
- package/executor/lib/types.d.cts +15 -0
- package/lib/agent/v2.d.ts +1 -1
- package/lib/agent/v2.js +1 -1
- package/lib/application/services.d.ts +13 -1
- package/lib/application/services.js +1 -1
- package/lib/cli/main.js +3 -3
- package/lib/client/rpc.d.ts +16 -0
- package/lib/components/functional-hooks.d.mts +4 -0
- package/lib/components/functional-hooks.mjs +1 -0
- package/lib/harness/create-harness.js +1 -1
- package/lib/harness/hooks.d.ts +8 -0
- package/lib/harness/hooks.js +1 -0
- package/lib/harness/runtime.js +1 -1
- package/lib/harness/types.d.ts +7 -2
- package/lib/integration/agent-integration.d.ts +5 -1
- package/lib/integration/agent-integration.js +1 -1
- package/lib/integration/client-mcp-attachment.d.ts +5 -1
- package/lib/integration/client-mcp-attachment.js +1 -1
- package/lib/integration/executor-supervisor.d.ts +10 -1
- package/lib/integration/executor-supervisor.js +1 -1
- package/lib/integration/session-mcp-scope.d.ts +5 -1
- package/lib/integration/session-mcp-scope.js +1 -1
- package/lib/integration/session-mcp-view.d.ts +6 -1
- package/lib/integration/session-mcp-view.js +1 -1
- package/lib/mcp-server/module.d.ts +22 -2
- package/lib/mcp-server/module.js +1 -1
- package/lib/mcp-server/rpcs.d.ts +174 -123
- package/lib/mcp-server/rpcs.js +1 -1
- package/lib/mcp-server/schemas.d.ts +33 -0
- package/lib/mcp-server/schemas.js +1 -1
- package/lib/protocol/rpc.d.ts +73 -3
- package/lib/public.d.ts +1 -1
- package/package.json +24 -20
- package/cli/dist-server/types/workspace/product/lib/common/types/workspace-report.d.ts +0 -119
package/cli/dist-server/types/workspace/cbc-daemon/lib/node/daemon/daemon-channel-autoconnect.d.ts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daemon Channel Auto-Connect — 自动连接已保存凭证的 channel 实例
|
|
3
|
+
*
|
|
4
|
+
* daemon 启动时:
|
|
5
|
+
* 1. 优先检查 CODEBUDDY_DAEMON_RESTORE_CHANNELS 环境变量(restart 恢复)
|
|
6
|
+
* 2. 否则扫描 ~/.codebuddy/channels/ 下的 instances.json,自动连接有凭证的实例
|
|
7
|
+
*
|
|
8
|
+
* 开关优先级(从高到低):
|
|
9
|
+
* 1. 环境变量 CODEBUDDY_DAEMON_AUTO_CONNECT_CHANNELS=0/false → 全局禁用
|
|
10
|
+
* 2. settings.json daemonAutoConnectChannels: false → 全局禁用
|
|
11
|
+
* 3. 实例级别 autoConnect: false → 跳过该实例
|
|
12
|
+
* 4. 默认 → 自动连接
|
|
13
|
+
*/
|
|
14
|
+
import { type IDaemonChannelAutoConnect } from './daemon-protocol.js';
|
|
15
|
+
export declare class DaemonChannelAutoConnectImpl implements IDaemonChannelAutoConnect {
|
|
16
|
+
private readonly logger;
|
|
17
|
+
private readonly remoteControlService?;
|
|
18
|
+
private readonly clientRegistry?;
|
|
19
|
+
private readonly settingsManager?;
|
|
20
|
+
connectSavedChannels(): Promise<void>;
|
|
21
|
+
restoreChannels(channelIds: string[]): Promise<void>;
|
|
22
|
+
getConnectedChannelIds(): string[];
|
|
23
|
+
/**
|
|
24
|
+
* 检查全局开关是否禁用了自动连接。
|
|
25
|
+
* 优先级:环境变量 > settings
|
|
26
|
+
*/
|
|
27
|
+
private isGloballyDisabled;
|
|
28
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daemon Enhancements Lifecycle
|
|
3
|
+
*
|
|
4
|
+
* 在 daemon 模式(ENV_SESSION_KIND=daemon)下自动启动增强功能:
|
|
5
|
+
* 1. WakeDetector — 防 idle sleep + 唤醒检测 → 重连所有长连接
|
|
6
|
+
* 2. DaemonAutoRestart — 更新安装后空闲自动重启
|
|
7
|
+
* 3. DaemonChannelAutoConnect — 自动连接已保存凭证的 channel 实例
|
|
8
|
+
*
|
|
9
|
+
* 生命周期:
|
|
10
|
+
* - initialize: 检测 daemon 模式 → 延迟启动各模块(等待依赖就绪)
|
|
11
|
+
* - onStop: 停止检测器和自动重启,清理订阅
|
|
12
|
+
*/
|
|
13
|
+
import { Application, ApplicationLifecycle } from '@celljs/core';
|
|
14
|
+
export declare class DaemonEnhancementsLifecycle implements ApplicationLifecycle<Application> {
|
|
15
|
+
private logger?;
|
|
16
|
+
private wakeDetector?;
|
|
17
|
+
private autoRestart?;
|
|
18
|
+
private wakeSubscription?;
|
|
19
|
+
initialize(): void;
|
|
20
|
+
onStop(): Promise<void>;
|
|
21
|
+
private initAsync;
|
|
22
|
+
private startWakeDetector;
|
|
23
|
+
private startAutoRestart;
|
|
24
|
+
/**
|
|
25
|
+
* Daemon 启动时主动 "无人值守地" 走一遍完整 session 创建流程,让 webhook(微信/企微/HTTP runs)
|
|
26
|
+
* 一进来就能复用这个 primary session,无需等用户先打开 Web UI 创建对话。
|
|
27
|
+
*
|
|
28
|
+
* 关键:必须发真实的 `POST /internal/agent` 请求(body 不带 prompt),
|
|
29
|
+
* 而不是直接 `sessionManager.create()`。原因:
|
|
30
|
+
* - 直接 create 只造一个对象,**不会触发** SessionMiddleware
|
|
31
|
+
* - SessionMiddleware 是注入 cliRuntimeOptions / 触发 setCurrent / 启动 hooks /
|
|
32
|
+
* 初始化 ToolPermissionContext / 推送 sessionSubject 的统一入口
|
|
33
|
+
* - sessionSubject.next 触发后,ServerModeStrategy 的 take(1) 监听才会调
|
|
34
|
+
* `gatewayBridge.setPrimarySession(session)`,让后续 webhook 全部汇聚到此 session
|
|
35
|
+
*
|
|
36
|
+
* 等价于"daemon 自己代替无人值守的 Web UI 创建一个完整 session"。
|
|
37
|
+
*/
|
|
38
|
+
private bootstrapPrimarySession;
|
|
39
|
+
private connectChannels;
|
|
40
|
+
/**
|
|
41
|
+
* 唤醒后重连所有长连接客户端。
|
|
42
|
+
* 等待 3 秒让网络栈恢复,然后逐个断开并重连。
|
|
43
|
+
*/
|
|
44
|
+
private reconnectAllChannels;
|
|
45
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { type BgSessionOptions, type DaemonConfig, type IDaemonProcessManager } from './daemon-protocol.js';
|
|
2
|
+
/**
|
|
3
|
+
* 子进程管理器 — fork detached 进程、信号处理、存活检测
|
|
4
|
+
*
|
|
5
|
+
* 负责 daemon supervisor 和后台会话的进程创建与管理。
|
|
6
|
+
* 所有 fork 出的子进程都是 detached 模式,父进程可以立即退出。
|
|
7
|
+
*/
|
|
8
|
+
export declare class DaemonProcessManagerImpl implements IDaemonProcessManager {
|
|
9
|
+
forkDaemon(config: DaemonConfig, extraEnv?: Record<string, string>): Promise<{
|
|
10
|
+
pid: number;
|
|
11
|
+
logPath: string;
|
|
12
|
+
}>;
|
|
13
|
+
/**
|
|
14
|
+
* 构造 daemon 子进程的 CLI 参数。抽离成独立方法是为了:
|
|
15
|
+
* 1) `forkDaemon` 主流程更清晰;
|
|
16
|
+
* 2) 单测可以直接覆盖参数装配规则(-y vs --permission-mode 优先级、startupArgs 回放等)
|
|
17
|
+
* 而无需 stub child_process.fork。
|
|
18
|
+
*/
|
|
19
|
+
buildDaemonChildArgs(config: DaemonConfig): string[];
|
|
20
|
+
forkBgSession(args: string[], options: BgSessionOptions): Promise<{
|
|
21
|
+
pid: number;
|
|
22
|
+
logPath: string;
|
|
23
|
+
}>;
|
|
24
|
+
sendSignal(pid: number, signal: NodeJS.Signals): boolean;
|
|
25
|
+
isProcessRunning(pid: number): boolean;
|
|
26
|
+
waitForExit(pid: number, timeoutMs?: number): Promise<boolean>;
|
|
27
|
+
private getLogDir;
|
|
28
|
+
/**
|
|
29
|
+
* 确定 CLI 入口路径。
|
|
30
|
+
* 使用当前进程的启动脚本路径(process.argv[1]),确保 fork 出的子进程
|
|
31
|
+
* 使用和当前进程相同的入口文件,不受 __dirname 打包路径影响。
|
|
32
|
+
*/
|
|
33
|
+
private getEntryPath;
|
|
34
|
+
/**
|
|
35
|
+
* 创建 detached 子进程的统一方法。
|
|
36
|
+
* stdout/stderr 重定向到日志文件,IPC 通道创建后立即断开。
|
|
37
|
+
*
|
|
38
|
+
* Bun SFE 下不能用 `fork()`:它无条件把「模块路径」塞进子进程 argv[1]
|
|
39
|
+
* (`fork(modulePath, args)` 等价于 `spawn(execPath, [modulePath, ...args])`),
|
|
40
|
+
* 而 Bun 编译出的可执行文件本身就是完整入口——那个「模块路径」在Bun SFE 下
|
|
41
|
+
* 是 `process.argv[1]` 的虚拟路径(`/$bunfs/root/<bin>`),被当成参数续传给
|
|
42
|
+
* 子进程后会落进 commander 的位置参数(`argv[2]` 起),子进程又把它当 CLI
|
|
43
|
+
* 入口重新拼进自己的 argv——递归下去 argv 逐代累积虚拟路径(对齐
|
|
44
|
+
* `PathUtils.buildRespawnArgs` 修复的同一类问题,issue #82398)。这里改用
|
|
45
|
+
* `spawn()` 手动带 `'ipc'` stdio(等价于 fork 的 IPC 语义),配合
|
|
46
|
+
* `PathUtils.buildRespawnArgs` 决定要不要把 entry 塞进 argv——本方法只调了
|
|
47
|
+
* `.unref()` + `.disconnect()`,从未用 `.send()`/`.on('message')`,
|
|
48
|
+
* 换成 `spawn` 不影响现有语义。
|
|
49
|
+
*/
|
|
50
|
+
protected forkDetached(args: string[], opts: {
|
|
51
|
+
env: Record<string, string>;
|
|
52
|
+
logPath: string;
|
|
53
|
+
cwd: string;
|
|
54
|
+
}): Promise<{
|
|
55
|
+
pid: number;
|
|
56
|
+
logPath: string;
|
|
57
|
+
}>;
|
|
58
|
+
/**
|
|
59
|
+
* 从 args 中移除 --bg, --background, --name <value> 参数。
|
|
60
|
+
* 后台会话不需要这些标志 — 它们已经通过环境变量传递。
|
|
61
|
+
*/
|
|
62
|
+
private filterBgArgs;
|
|
63
|
+
/** 确保 args 中包含指定参数(两个别名都检查) */
|
|
64
|
+
private ensureArg;
|
|
65
|
+
/**
|
|
66
|
+
* 判断 args 中是否已经传入了带值的 flag(同时支持 `--key value` 与 `--key=value` 两种形式)。
|
|
67
|
+
*/
|
|
68
|
+
private hasFlagWithValue;
|
|
69
|
+
/**
|
|
70
|
+
* Extract inheritable CLI arguments from the parent process.
|
|
71
|
+
* Skips daemon-specific args and mode/lifecycle args that don't apply to the child.
|
|
72
|
+
*
|
|
73
|
+
* 公开为 public:`daemon-service` 在 `runAsSupervisor()` 时需要拿到这份"原始用户参数"
|
|
74
|
+
* 持久化到 PID 文件,供后续 `daemon restart` / auto-restart 还原。
|
|
75
|
+
*/
|
|
76
|
+
getInheritableArgs(): string[];
|
|
77
|
+
}
|
|
@@ -0,0 +1,324 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daemon 模块协议定义
|
|
3
|
+
*
|
|
4
|
+
* 遵循项目 protocol pattern:所有 DI Symbols 和 interface 定义在此文件中,
|
|
5
|
+
* 实现类在独立文件中 import 这些定义。
|
|
6
|
+
*/
|
|
7
|
+
import type { Subject } from 'rxjs';
|
|
8
|
+
export declare const DaemonService: unique symbol;
|
|
9
|
+
export declare const SessionRegistry: unique symbol;
|
|
10
|
+
export declare const DaemonProcessManager: unique symbol;
|
|
11
|
+
export declare const BgSessionHandler: unique symbol;
|
|
12
|
+
export declare const WakeDetector: unique symbol;
|
|
13
|
+
export declare const DaemonAutoRestart: unique symbol;
|
|
14
|
+
export declare const DaemonChannelAutoConnect: unique symbol;
|
|
15
|
+
export declare const SystemService: unique symbol;
|
|
16
|
+
/** PID 文件名匹配模式:仅匹配 `<数字>.json` 和 `manual-<id>.json` 格式 */
|
|
17
|
+
export declare const PID_FILE_PATTERN: RegExp;
|
|
18
|
+
/** Worker 心跳间隔 (30s) */
|
|
19
|
+
export declare const WORKER_HEARTBEAT_INTERVAL_MS = 30000;
|
|
20
|
+
/** Worker 心跳超时 (2min) — 超时的手动 worker 视为已死 */
|
|
21
|
+
export declare const WORKER_HEARTBEAT_TIMEOUT_MS: number;
|
|
22
|
+
/** 后台会话管理子命令(BgSessionStrategy 匹配用) */
|
|
23
|
+
export declare const BG_SESSION_COMMANDS: readonly ['ps', 'logs', 'attach', 'kill', 'stop', 'rm', 'respawn'];
|
|
24
|
+
/** 不需要注册 PID 文件的短生命周期子命令 */
|
|
25
|
+
export declare const SHORT_LIVED_COMMANDS: readonly ["ps", "logs", "attach", "kill", "stop", "rm", "respawn", "daemon", "project"];
|
|
26
|
+
export declare const ENV_SESSION_KIND = "CODEBUDDY_SESSION_KIND";
|
|
27
|
+
export declare const ENV_SESSION_NAME = "CODEBUDDY_SESSION_NAME";
|
|
28
|
+
export declare const ENV_SESSION_LOG = "CODEBUDDY_SESSION_LOG";
|
|
29
|
+
export declare const ENV_DAEMON_RESTORE_CHANNELS = "CODEBUDDY_DAEMON_RESTORE_CHANNELS";
|
|
30
|
+
/** 设置为 '1' 或 'true' 禁用防休眠(允许系统正常进入 idle sleep) */
|
|
31
|
+
export declare const ENV_DAEMON_ALLOW_SLEEP = "CODEBUDDY_DAEMON_ALLOW_SLEEP";
|
|
32
|
+
/** 设置为 '0' 或 'false' 禁用 daemon 启动时自动连接 channel */
|
|
33
|
+
export declare const ENV_DAEMON_AUTO_CONNECT_CHANNELS = "CODEBUDDY_DAEMON_AUTO_CONNECT_CHANNELS";
|
|
34
|
+
/** daemon 启动时请求的原始端口;SERVER__PORT 在绑定后会被改写为实际端口 */
|
|
35
|
+
export declare const ENV_DAEMON_CONFIGURED_PORT = "CODEBUDDY_DAEMON_CONFIGURED_PORT";
|
|
36
|
+
/**
|
|
37
|
+
* 会话类型
|
|
38
|
+
* - interactive: 用户终端交互(默认)
|
|
39
|
+
* - bg: 后台会话(用户可管理:ps/attach/kill)
|
|
40
|
+
* - daemon: 守护进程 supervisor(长生命周期)
|
|
41
|
+
* - daemon-worker: daemon 分配的 worker 子进程(预留)
|
|
42
|
+
* - teammate: 独立进程 teammate(由 team leader fork)
|
|
43
|
+
* - prewarm: 已付清冷启动成本、挂起等待 IPC activate 的预热进程
|
|
44
|
+
* (meta 暴露 prewarmId / socketPath / status,供 cbc-prewarm list 发现)
|
|
45
|
+
*/
|
|
46
|
+
export type SessionKind = 'interactive' | 'bg' | 'daemon' | 'daemon-worker' | 'teammate' | 'prewarm';
|
|
47
|
+
export type SessionStatus = 'busy' | 'idle' | 'waiting' | 'stopped';
|
|
48
|
+
export type DaemonStatus = 'stopped' | 'starting' | 'running' | 'stopping';
|
|
49
|
+
/**
|
|
50
|
+
* 每个进程的 PID 注册信息,存储在 ~/.codebuddy/sessions/<pid>.json
|
|
51
|
+
*/
|
|
52
|
+
export interface PidFileEntry {
|
|
53
|
+
/** 进程 PID */
|
|
54
|
+
pid: number;
|
|
55
|
+
/** 会话唯一标识 */
|
|
56
|
+
sessionId: string;
|
|
57
|
+
/** 启动时的工作目录 */
|
|
58
|
+
cwd: string;
|
|
59
|
+
/** 启动时间戳 (ms) */
|
|
60
|
+
startedAt: number;
|
|
61
|
+
/** 最后更新时间戳 (ms) */
|
|
62
|
+
updatedAt?: number;
|
|
63
|
+
/** 会话类型 */
|
|
64
|
+
kind: SessionKind;
|
|
65
|
+
/** 用户可见名称(用于 ps/logs/kill 查找) */
|
|
66
|
+
name?: string;
|
|
67
|
+
/** 输出日志文件路径(bg 会话必填) */
|
|
68
|
+
logPath?: string;
|
|
69
|
+
/** 当前运行状态 */
|
|
70
|
+
status?: SessionStatus;
|
|
71
|
+
/** 等待描述(如 tool:Bash, user-input) */
|
|
72
|
+
waitingFor?: string;
|
|
73
|
+
/** HTTP 服务端口 */
|
|
74
|
+
port?: number;
|
|
75
|
+
/** HTTP endpoint URL */
|
|
76
|
+
endpoint?: string;
|
|
77
|
+
/** HTTP 服务完整 URL(含 host:port,用于跨实例访问) */
|
|
78
|
+
url?: string;
|
|
79
|
+
/** 网络模式 */
|
|
80
|
+
mode?: 'local' | 'tunnel';
|
|
81
|
+
/** 认证密码(手动添加的远程 worker) */
|
|
82
|
+
password?: string;
|
|
83
|
+
/** 是否手动添加的远程 worker(非本地进程) */
|
|
84
|
+
manual?: boolean;
|
|
85
|
+
/** CLI 版本号 */
|
|
86
|
+
version?: string;
|
|
87
|
+
/** 操作系统 */
|
|
88
|
+
os?: string;
|
|
89
|
+
/** CPU 架构 */
|
|
90
|
+
arch?: string;
|
|
91
|
+
/** 主机名 */
|
|
92
|
+
hostname?: string;
|
|
93
|
+
/** 自定义元数据(如 currentTopic) */
|
|
94
|
+
meta?: Record<string, string>;
|
|
95
|
+
/** 最后心跳时间戳 (ms) */
|
|
96
|
+
lastHeartbeat?: number;
|
|
97
|
+
/** 是否为当前进程(API 返回时动态计算,不持久化) */
|
|
98
|
+
isCurrent?: boolean;
|
|
99
|
+
/** daemon 启动时的原始端口配置(用于 restart 端口复用) */
|
|
100
|
+
configuredPort?: number;
|
|
101
|
+
/** daemon 启动时的原始 host 配置(用于 restart host 复用) */
|
|
102
|
+
configuredHost?: string;
|
|
103
|
+
/** daemon 已连接的 channel IDs(用于 restart 后恢复,格式:'wechat:id' | 'wecom:id') */
|
|
104
|
+
connectedChannels?: string[];
|
|
105
|
+
/**
|
|
106
|
+
* daemon 首次启动时由用户传入的可继承 CLI 参数(已过滤掉子命令/lifecycle flag)。
|
|
107
|
+
*
|
|
108
|
+
* 用途:`daemon restart` 不带参数时从这里恢复,保证用户首次 `daemon start --model X -y`
|
|
109
|
+
* 设置的模型/权限模式等行为在重启后仍然生效,避免回退成默认权限模式 / 默认模型。
|
|
110
|
+
*
|
|
111
|
+
* 仅对 `kind === 'daemon'` 的条目有意义。
|
|
112
|
+
*/
|
|
113
|
+
startupArgs?: string[];
|
|
114
|
+
}
|
|
115
|
+
/** Daemon 默认端口 */
|
|
116
|
+
export declare const DEFAULT_DAEMON_PORT = 9527;
|
|
117
|
+
/** Daemon supervisor 配置 */
|
|
118
|
+
export interface DaemonConfig {
|
|
119
|
+
/** HTTP 端口(0 = 自动分配,默认 9527) */
|
|
120
|
+
port: number;
|
|
121
|
+
/** 绑定地址 */
|
|
122
|
+
host: string;
|
|
123
|
+
/** PID 文件目录(运行时填充) */
|
|
124
|
+
sessionsDir: string;
|
|
125
|
+
/** 日志文件目录(运行时填充) */
|
|
126
|
+
logDir: string;
|
|
127
|
+
/** Permission mode for daemon sessions (default: 'default') */
|
|
128
|
+
permissionMode?: string;
|
|
129
|
+
/**
|
|
130
|
+
* 显式提供给 daemon 子进程的启动参数(不再从 `process.argv` 推断)。
|
|
131
|
+
*
|
|
132
|
+
* - `daemon start` 路径:通常不传,由 `forkDaemon` 内部读取 `process.argv` 推断;
|
|
133
|
+
* - `daemon restart` / auto-restart 路径:必须传上一次持久化的 `startupArgs`,
|
|
134
|
+
* 保证重启后用户原始的 `--model` / `-y` 等参数得到继承。
|
|
135
|
+
*/
|
|
136
|
+
startupArgs?: string[];
|
|
137
|
+
}
|
|
138
|
+
export declare const DEFAULT_DAEMON_CONFIG: DaemonConfig;
|
|
139
|
+
/** daemon status 查询结果 */
|
|
140
|
+
export interface DaemonInfo {
|
|
141
|
+
status: DaemonStatus;
|
|
142
|
+
pid?: number;
|
|
143
|
+
endpoint?: string;
|
|
144
|
+
startedAt?: number;
|
|
145
|
+
}
|
|
146
|
+
/** fork 后台会话的选项 */
|
|
147
|
+
export interface BgSessionOptions {
|
|
148
|
+
/** 用户可见会话名 */
|
|
149
|
+
name?: string;
|
|
150
|
+
/** 工作目录 */
|
|
151
|
+
cwd?: string;
|
|
152
|
+
/** 不自动加 -y(用于 teammate Permission Bridge 场景) */
|
|
153
|
+
skipAutoApprove?: boolean;
|
|
154
|
+
/** 不自动加 -p(子进程需要完整 HTTP 服务,如 --serve 模式) */
|
|
155
|
+
skipPrintMode?: boolean;
|
|
156
|
+
/** 外层 detached 进程作为 PTY broker 托管完整交互会话 */
|
|
157
|
+
jobWorker?: boolean;
|
|
158
|
+
/** 附加环境变量(合并到子进程 env) */
|
|
159
|
+
extraEnv?: Record<string, string>;
|
|
160
|
+
}
|
|
161
|
+
/** Daemon supervisor 生命周期管理 */
|
|
162
|
+
export interface IDaemonService {
|
|
163
|
+
/** 启动 daemon(如已运行则返回现有实例信息) */
|
|
164
|
+
start(config?: Partial<DaemonConfig>): Promise<DaemonInfo>;
|
|
165
|
+
/**
|
|
166
|
+
* 停掉 daemon。
|
|
167
|
+
*
|
|
168
|
+
* 默认连同 daemon 名下的 worker(prewarm / daemon-worker)与后台会话
|
|
169
|
+
* worker(bg)一起停;非 Windows 平台 `keepWorkers` 时保留 bg worker —— 它们是 detached
|
|
170
|
+
* 进程,下一个 daemon 靠 sessions/<pid>.json 注册表重连(对齐 Claude 的
|
|
171
|
+
* `daemon stop --keep-workers`)。
|
|
172
|
+
*/
|
|
173
|
+
stop(options?: {
|
|
174
|
+
keepWorkers?: boolean;
|
|
175
|
+
}): Promise<void>;
|
|
176
|
+
/** 查询 daemon 运行状态 */
|
|
177
|
+
status(): Promise<DaemonInfo>;
|
|
178
|
+
/** 先 stop 再 start */
|
|
179
|
+
restart(config?: Partial<DaemonConfig>): Promise<DaemonInfo>;
|
|
180
|
+
/** 当前进程作为 daemon supervisor 运行(由 fork 出的子进程调用) */
|
|
181
|
+
runAsSupervisor(): Promise<void>;
|
|
182
|
+
}
|
|
183
|
+
/** PID 文件注册表 — 进程发现和管理 */
|
|
184
|
+
export interface ISessionRegistry {
|
|
185
|
+
/** 注册当前进程,写入 PID 文件 */
|
|
186
|
+
register(entry: Omit<PidFileEntry, 'pid'>): Promise<void>;
|
|
187
|
+
/** 注销当前进程,删除 PID 文件 */
|
|
188
|
+
unregister(): Promise<void>;
|
|
189
|
+
/** 更新当前进程的字段(best-effort) */
|
|
190
|
+
update(patch: Partial<Pick<PidFileEntry, 'sessionId' | 'status' | 'waitingFor' | 'name' | 'updatedAt' | 'endpoint' | 'url' | 'mode' | 'meta' | 'lastHeartbeat' | 'version' | 'os' | 'arch' | 'hostname' | 'configuredPort' | 'configuredHost' | 'connectedChannels' | 'startupArgs'>>): Promise<void>;
|
|
191
|
+
/** 列出所有活跃会话(进程存活的) */
|
|
192
|
+
list(filter?: {
|
|
193
|
+
kind?: SessionKind;
|
|
194
|
+
}): Promise<PidFileEntry[]>;
|
|
195
|
+
/** 按 PID(纯数字)或 name/sessionId 查找 */
|
|
196
|
+
find(pidOrName: string): Promise<PidFileEntry | undefined>;
|
|
197
|
+
/** 清理已死进程的 PID 文件,返回清理数量 */
|
|
198
|
+
cleanup(): Promise<number>;
|
|
199
|
+
/** 获取 sessions 目录路径 */
|
|
200
|
+
getSessionsDir(): string;
|
|
201
|
+
/** 手动添加远程 worker(无本地进程,通过 URL 访问) */
|
|
202
|
+
addManual(entry: Omit<PidFileEntry, 'pid'> & {
|
|
203
|
+
url: string;
|
|
204
|
+
}): Promise<PidFileEntry>;
|
|
205
|
+
/** 删除手动添加的远程 worker */
|
|
206
|
+
removeManual(idOrName: string): Promise<void>;
|
|
207
|
+
/** 启动当前进程的心跳定时器(定期更新 lastHeartbeat) */
|
|
208
|
+
startHeartbeat(): void;
|
|
209
|
+
/** 停止心跳定时器 */
|
|
210
|
+
stopHeartbeat(): void;
|
|
211
|
+
/** 获取当前进程 PID(用于标记 isCurrent) */
|
|
212
|
+
getCurrentPid(): number;
|
|
213
|
+
}
|
|
214
|
+
/** 子进程 fork / 信号 / 存活检测 */
|
|
215
|
+
export interface IDaemonProcessManager {
|
|
216
|
+
/** Fork detached daemon supervisor 子进程 */
|
|
217
|
+
forkDaemon(config: DaemonConfig, extraEnv?: Record<string, string>): Promise<{
|
|
218
|
+
pid: number;
|
|
219
|
+
logPath: string;
|
|
220
|
+
}>;
|
|
221
|
+
/** Fork detached 后台会话子进程 */
|
|
222
|
+
forkBgSession(args: string[], options: BgSessionOptions): Promise<{
|
|
223
|
+
pid: number;
|
|
224
|
+
logPath: string;
|
|
225
|
+
}>;
|
|
226
|
+
/** 向指定进程发送信号,返回是否成功 */
|
|
227
|
+
sendSignal(pid: number, signal: NodeJS.Signals): boolean;
|
|
228
|
+
/** 检查进程是否存活(通过 kill -0) */
|
|
229
|
+
isProcessRunning(pid: number): boolean;
|
|
230
|
+
/** 轮询等待进程退出,返回是否在超时前退出 */
|
|
231
|
+
waitForExit(pid: number, timeoutMs?: number): Promise<boolean>;
|
|
232
|
+
/**
|
|
233
|
+
* 从当前进程的 process.argv 中抽取出"可被 daemon 子进程继承"的 CLI 参数。
|
|
234
|
+
* 已剥离 daemon 子命令、模式 flag(--serve/--print/--acp 等)、生命周期 flag、
|
|
235
|
+
* 以及 `--port`/`--host`(由 env 变量传递)。
|
|
236
|
+
*
|
|
237
|
+
* 暴露此方法是为了让 `daemon-service` 在 `runAsSupervisor()` 时把这份"原始用户参数"
|
|
238
|
+
* 持久化到 PID 文件,从而 `daemon restart` / auto-restart 可以原样继承。
|
|
239
|
+
*/
|
|
240
|
+
getInheritableArgs(): string[];
|
|
241
|
+
/**
|
|
242
|
+
* 构造 daemon 子进程的完整 CLI 参数(含 `--serve` 与权限兜底逻辑)。
|
|
243
|
+
* 对外暴露主要方便单测验证参数装配规则。
|
|
244
|
+
*/
|
|
245
|
+
buildDaemonChildArgs(config: DaemonConfig): string[];
|
|
246
|
+
}
|
|
247
|
+
/** 后台会话命令处理器(ps / logs / attach / kill / stop / rm / respawn / --bg) */
|
|
248
|
+
export interface IBgSessionHandler {
|
|
249
|
+
/** 列出所有活跃会话(codebuddy ps) */
|
|
250
|
+
ps(args: string[]): Promise<void>;
|
|
251
|
+
/** 查看会话日志输出(codebuddy logs <id>) */
|
|
252
|
+
logs(pidOrName: string): Promise<void>;
|
|
253
|
+
/** 附加到运行中的会话(codebuddy attach <id>) */
|
|
254
|
+
attach(pidOrName: string): Promise<void>;
|
|
255
|
+
/** 终止会话进程(codebuddy kill <id>) */
|
|
256
|
+
kill(pidOrName: string): Promise<void>;
|
|
257
|
+
/** 从 agent view 列表移除会话(codebuddy rm <id>),对话记录保留在本机 */
|
|
258
|
+
remove(idOrName: string): Promise<void>;
|
|
259
|
+
/** 保留对话重启会话(codebuddy respawn <id>) */
|
|
260
|
+
respawn(idOrName: string): Promise<void>;
|
|
261
|
+
/** 重启所有运行中的会话(codebuddy respawn --all),如换新二进制后整体迁移 */
|
|
262
|
+
respawnAll(): Promise<void>;
|
|
263
|
+
/** 处理 --bg 标志:fork 后台会话并输出信息 */
|
|
264
|
+
handleBgFlag(args: string[]): Promise<void>;
|
|
265
|
+
}
|
|
266
|
+
/** 唤醒检测 + 防 idle sleep */
|
|
267
|
+
export interface IWakeDetector {
|
|
268
|
+
/** 启动检测(含平台防休眠 + 定时器跳跃检测) */
|
|
269
|
+
start(): void;
|
|
270
|
+
/** 停止检测并释放防休眠子进程 */
|
|
271
|
+
stop(): void;
|
|
272
|
+
/** 系统唤醒事件(携带估算休眠时长) */
|
|
273
|
+
readonly onWake: Subject<{
|
|
274
|
+
sleepDurationMs: number;
|
|
275
|
+
}>;
|
|
276
|
+
}
|
|
277
|
+
/** 更新后空闲自动重启 */
|
|
278
|
+
export interface IDaemonAutoRestart {
|
|
279
|
+
/** 启动自动重启监听 */
|
|
280
|
+
start(): void;
|
|
281
|
+
/** 停止监听 */
|
|
282
|
+
stop(): void;
|
|
283
|
+
/** 触发待重启(由 AutoUpdateService 调用) */
|
|
284
|
+
schedulePendingRestart(): void;
|
|
285
|
+
/**
|
|
286
|
+
* 立即执行一次优雅自重启(不等 idle):关闭 HTTP → 注销 PID → fork 新 daemon → exit。
|
|
287
|
+
*
|
|
288
|
+
* 供"restart 请求打到 daemon 自己身上"的路径使用(Web UI POST /api/v1/daemon/restart,
|
|
289
|
+
* issue #72979):本进程不能 stop() 自己(sendSignal 的自身 PID 守卫,#73790),
|
|
290
|
+
* 必须先让当前 HTTP 响应发出,再在后台完成换进程。
|
|
291
|
+
* config 为显式覆盖项(port/host/startupArgs),未提供的字段从 PID 文件快照恢复。
|
|
292
|
+
*/
|
|
293
|
+
restartNow(config?: Partial<DaemonConfig>): void;
|
|
294
|
+
}
|
|
295
|
+
/** Channel 自动连接与恢复 */
|
|
296
|
+
export interface IDaemonChannelAutoConnect {
|
|
297
|
+
/** 自动连接所有有保存凭证的 channel 实例 */
|
|
298
|
+
connectSavedChannels(): Promise<void>;
|
|
299
|
+
/** 恢复指定的 channel 连接(从 restart 恢复) */
|
|
300
|
+
restoreChannels(channelIds: string[]): Promise<void>;
|
|
301
|
+
/** 获取当前已连接的 channel ID 列表(格式:'clientType:instanceId') */
|
|
302
|
+
getConnectedChannelIds(): string[];
|
|
303
|
+
}
|
|
304
|
+
/** 系统服务状态 */
|
|
305
|
+
export interface SystemServiceStatus {
|
|
306
|
+
/** 是否已安装为系统服务 */
|
|
307
|
+
installed: boolean;
|
|
308
|
+
/** 平台后端类型 */
|
|
309
|
+
backend: 'launchd' | 'systemd' | 'task-scheduler' | 'unsupported';
|
|
310
|
+
/** 服务配置文件路径(已安装时) */
|
|
311
|
+
configPath?: string;
|
|
312
|
+
}
|
|
313
|
+
/** 系统服务注册/注销 — 将 daemon 注册为操作系统级服务(登录自启) */
|
|
314
|
+
export interface ISystemService {
|
|
315
|
+
/** 注册为系统服务(开机/登录自启) */
|
|
316
|
+
install(options?: {
|
|
317
|
+
port?: number;
|
|
318
|
+
permissionMode?: string;
|
|
319
|
+
}): Promise<void>;
|
|
320
|
+
/** 移除系统服务注册 */
|
|
321
|
+
uninstall(): Promise<void>;
|
|
322
|
+
/** 查询系统服务状态 */
|
|
323
|
+
status(): Promise<SystemServiceStatus>;
|
|
324
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { type DaemonConfig, type DaemonInfo, type IDaemonService } from './daemon-protocol.js';
|
|
2
|
+
/**
|
|
3
|
+
* Daemon supervisor 生命周期管理
|
|
4
|
+
*
|
|
5
|
+
* start: fork detached 子进程 → 子进程以 --serve 模式启动 HTTP → 注册 PID 文件
|
|
6
|
+
* stop: SIGTERM → 等待退出 → 超时则 SIGKILL → 清理 PID 文件
|
|
7
|
+
* runAsSupervisor: 由 fork 出的子进程内部调用,初始化 HTTP/ACP 服务并保持存活
|
|
8
|
+
*/
|
|
9
|
+
export declare class DaemonServiceImpl implements IDaemonService {
|
|
10
|
+
private readonly registry;
|
|
11
|
+
private readonly processManager;
|
|
12
|
+
private readonly endpointProvider?;
|
|
13
|
+
private readonly gatewayAuth?;
|
|
14
|
+
private readonly corsService?;
|
|
15
|
+
private readonly acpServer?;
|
|
16
|
+
private readonly autoRestart?;
|
|
17
|
+
start(config?: Partial<DaemonConfig>): Promise<DaemonInfo>;
|
|
18
|
+
stop(options?: {
|
|
19
|
+
keepWorkers?: boolean;
|
|
20
|
+
}): Promise<void>;
|
|
21
|
+
status(): Promise<DaemonInfo>;
|
|
22
|
+
restart(config?: Partial<DaemonConfig>): Promise<DaemonInfo>;
|
|
23
|
+
/**
|
|
24
|
+
* 当前进程作为 daemon supervisor 运行。
|
|
25
|
+
*
|
|
26
|
+
* 由 fork 出的子进程调用(启动参数为 --serve + CODEBUDDY_SESSION_KIND=daemon)。
|
|
27
|
+
* 流程:注册 PID → 等待 HTTP 就绪 → 初始化认证/CORS/ACP → 更新 endpoint → 保持存活。
|
|
28
|
+
*
|
|
29
|
+
* 注意:daemon 增强功能(防休眠/唤醒检测/自动重启/channel 自动连接)
|
|
30
|
+
* 由 DaemonEnhancementsLifecycle 自动管理,无需在此手动启动。
|
|
31
|
+
*/
|
|
32
|
+
runAsSupervisor(): Promise<void>;
|
|
33
|
+
/** 当前进程是否就是注册表里的 daemon(restart/stop 打在自己身上的判定) */
|
|
34
|
+
private isRunningAsDaemon;
|
|
35
|
+
private findRunningDaemon;
|
|
36
|
+
private mergeConfig;
|
|
37
|
+
/**
|
|
38
|
+
* 在 `restart()` 中先于 `stop()` 调用,抓取当前在跑 daemon 的启动参数与端口快照。
|
|
39
|
+
*
|
|
40
|
+
* 没有 daemon 在跑、或 PID 文件里没记录 startupArgs(旧版本写出的 PID 文件)时返回空对象,
|
|
41
|
+
* 此时 restart 行为退化为"用当前 process.argv 重新计算",与历史行为兼容。
|
|
42
|
+
*/
|
|
43
|
+
private snapshotPreviousStartup;
|
|
44
|
+
private waitForPidFile;
|
|
45
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * from './daemon-protocol.js';
|
|
2
|
+
export * from './daemon-service.js';
|
|
3
|
+
export * from './session-registry.js';
|
|
4
|
+
export * from './daemon-process.js';
|
|
5
|
+
export * from './bg-session-handler.js';
|
|
6
|
+
export * from './wake-detector.js';
|
|
7
|
+
export * from './daemon-auto-restart.js';
|
|
8
|
+
export * from './daemon-channel-autoconnect.js';
|
|
9
|
+
export * from './daemon-enhancements-lifecycle.js';
|
|
10
|
+
export * from './system-service.js';
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type ISessionRegistry, type PidFileEntry, type SessionKind } from './daemon-protocol.js';
|
|
2
|
+
/**
|
|
3
|
+
* Worker 注册表 — 统一的进程发现和管理
|
|
4
|
+
*
|
|
5
|
+
* 存储位置: ~/.codebuddy/sessions/<pid>.json(本地进程)
|
|
6
|
+
* ~/.codebuddy/sessions/manual-<id>.json(手动添加的远程 worker)
|
|
7
|
+
*
|
|
8
|
+
* 本地进程通过 kill -0 检测存活,手动远程 worker 通过心跳超时检测。
|
|
9
|
+
* 完全替代原有的 InstanceRegistryService。
|
|
10
|
+
*/
|
|
11
|
+
export declare class SessionRegistryImpl implements ISessionRegistry {
|
|
12
|
+
private registered;
|
|
13
|
+
private cleanupRegistered;
|
|
14
|
+
private heartbeatTimer;
|
|
15
|
+
/** 互斥锁——串行化 update() 调用,防止并发读-改-写损坏 JSON */
|
|
16
|
+
private updateMutex;
|
|
17
|
+
getSessionsDir(): string;
|
|
18
|
+
getCurrentPid(): number;
|
|
19
|
+
private getPidFilePath;
|
|
20
|
+
private getManualFilePath;
|
|
21
|
+
register(entry: Omit<PidFileEntry, 'pid'>): Promise<void>;
|
|
22
|
+
unregister(): Promise<void>;
|
|
23
|
+
update(patch: Partial<Pick<PidFileEntry, 'sessionId' | 'status' | 'waitingFor' | 'name' | 'updatedAt' | 'endpoint' | 'url' | 'mode' | 'meta' | 'lastHeartbeat' | 'version' | 'os' | 'arch' | 'hostname' | 'configuredPort' | 'configuredHost' | 'connectedChannels'>>): Promise<void>;
|
|
24
|
+
private doUpdate;
|
|
25
|
+
list(filter?: {
|
|
26
|
+
kind?: SessionKind;
|
|
27
|
+
}): Promise<PidFileEntry[]>;
|
|
28
|
+
find(pidOrName: string): Promise<PidFileEntry | undefined>;
|
|
29
|
+
cleanup(): Promise<number>;
|
|
30
|
+
addManual(entry: Omit<PidFileEntry, 'pid'> & {
|
|
31
|
+
url: string;
|
|
32
|
+
}): Promise<PidFileEntry>;
|
|
33
|
+
removeManual(idOrName: string): Promise<void>;
|
|
34
|
+
startHeartbeat(): void;
|
|
35
|
+
stopHeartbeat(): void;
|
|
36
|
+
private registerExitCleanup;
|
|
37
|
+
private parsePidFromFilename;
|
|
38
|
+
private isProcessAlive;
|
|
39
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 系统服务注册 — 将 daemon 注册为操作系统级服务(登录自启)
|
|
3
|
+
*
|
|
4
|
+
* 跨平台策略(参照 wake-detector.ts):单文件内 process.platform switch。
|
|
5
|
+
* - macOS: ~/Library/LaunchAgents/ plist + launchctl
|
|
6
|
+
* - Linux: ~/.config/systemd/user/ unit + systemctl --user
|
|
7
|
+
* - Windows: Task Scheduler (schtasks)
|
|
8
|
+
*/
|
|
9
|
+
import { type ISystemService, type SystemServiceStatus } from './daemon-protocol.js';
|
|
10
|
+
export declare class SystemServiceImpl implements ISystemService {
|
|
11
|
+
install(options?: {
|
|
12
|
+
port?: number;
|
|
13
|
+
permissionMode?: string;
|
|
14
|
+
}): Promise<void>;
|
|
15
|
+
uninstall(): Promise<void>;
|
|
16
|
+
status(): Promise<SystemServiceStatus>;
|
|
17
|
+
private statusForPlatform;
|
|
18
|
+
/**
|
|
19
|
+
* 入口 guard:argv[1] 不是本产品 CLI 入口时拒绝注册系统服务。
|
|
20
|
+
*
|
|
21
|
+
* 动机(实测事故):单测/嵌入式宿主走到 install() 时,resolvePaths() 取到的是宿主自己的
|
|
22
|
+
* 入口(vitest 的 forks.js、node_modules/.bin/mocha),照样被写进 LaunchAgent。launchd 的
|
|
23
|
+
* RunAtLoad + KeepAlive(SuccessfulExit=false) 于是把它变成永久崩溃重启循环——开发机上
|
|
24
|
+
* 累计 26.6 万次 MODULE_NOT_FOUND、200MB 的 daemon-launchd.err.log,且不会自愈。
|
|
25
|
+
* 注册系统服务是"难以自我恢复"的系统边界,入口对不上就必须拒绝而不是先写再说。
|
|
26
|
+
*/
|
|
27
|
+
private assertInstallableEntry;
|
|
28
|
+
/** capability guard:systemDaemon=false 时拒绝注册/卸载系统服务。 */
|
|
29
|
+
private assertSystemDaemonCapability;
|
|
30
|
+
private getPlistPath;
|
|
31
|
+
private installLaunchd;
|
|
32
|
+
private uninstallLaunchd;
|
|
33
|
+
private statusLaunchd;
|
|
34
|
+
private isCurrentLaunchdRuntime;
|
|
35
|
+
private matchesCurrentProgramArguments;
|
|
36
|
+
generatePlist(options?: {
|
|
37
|
+
port?: number;
|
|
38
|
+
permissionMode?: string;
|
|
39
|
+
}): string;
|
|
40
|
+
private getSystemdUnitPath;
|
|
41
|
+
private installSystemd;
|
|
42
|
+
private uninstallSystemd;
|
|
43
|
+
private statusSystemd;
|
|
44
|
+
generateSystemdUnit(options?: {
|
|
45
|
+
port?: number;
|
|
46
|
+
permissionMode?: string;
|
|
47
|
+
}): string;
|
|
48
|
+
private installTaskScheduler;
|
|
49
|
+
private uninstallTaskScheduler;
|
|
50
|
+
private statusTaskScheduler;
|
|
51
|
+
/** 解析 node 和 cbc 的绝对路径 */
|
|
52
|
+
resolvePaths(): {
|
|
53
|
+
nodePath: string;
|
|
54
|
+
cbcPath: string;
|
|
55
|
+
};
|
|
56
|
+
/** 构建 daemon start 的参数列表 */
|
|
57
|
+
private buildProgramArgs;
|
|
58
|
+
private getLogDir;
|
|
59
|
+
private escapeXml;
|
|
60
|
+
}
|