@ai-agent-forge/agent-forge 0.86.7 → 0.88.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +45 -0
- package/README.md +10 -11
- package/dist/artifacts/artifact-store.d.ts.map +1 -1
- package/dist/artifacts/artifact-store.js +9 -5
- package/dist/artifacts/artifact-store.js.map +1 -1
- package/dist/bundle/.build-manifest.json +430 -413
- package/dist/bundle/chunks/{chunk-A7GUOX2H.js → chunk-6ZKDNZHA.js} +5 -1
- package/dist/bundle/chunks/chunk-HLJEVRWP.js +13 -0
- package/dist/bundle/chunks/chunk-YGHQME4V.js +1456 -0
- package/dist/bundle/chunks/image-resize-worker.js +12 -1
- package/dist/bundle/chunks/{virtual-modules-3IZ4MYSQ.js → virtual-modules-KZ5DRH7Q.js} +1 -1
- package/dist/bundle/cli.js +1 -1
- package/dist/bundle/client.js +1 -1
- package/dist/bundle/index.js +2 -2
- package/dist/bundle/rpc-entry.js +1 -1
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +231 -185
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/auth-check.d.ts.map +1 -1
- package/dist/cli/auth-check.js +17 -4
- package/dist/cli/auth-check.js.map +1 -1
- package/dist/cli/auth-command.d.ts.map +1 -1
- package/dist/cli/auth-command.js +15 -9
- package/dist/cli/auth-command.js.map +1 -1
- package/dist/cli/credential-print.d.ts.map +1 -1
- package/dist/cli/credential-print.js +14 -7
- package/dist/cli/credential-print.js.map +1 -1
- package/dist/cli/experimental/command.d.ts.map +1 -1
- package/dist/cli/experimental/command.js +6 -5
- package/dist/cli/experimental/command.js.map +1 -1
- package/dist/cli/list-models.d.ts.map +1 -1
- package/dist/cli/list-models.js +9 -8
- package/dist/cli/list-models.js.map +1 -1
- package/dist/cli/plugin-manager-controller.d.ts.map +1 -1
- package/dist/cli/plugin-manager-controller.js +2 -1
- package/dist/cli/plugin-manager-controller.js.map +1 -1
- package/dist/cli/serve.d.ts.map +1 -1
- package/dist/cli/serve.js +8 -5
- package/dist/cli/serve.js.map +1 -1
- package/dist/client/remote-session.d.ts.map +1 -1
- package/dist/client/remote-session.js +16 -9
- package/dist/client/remote-session.js.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +5 -3
- package/dist/config.js.map +1 -1
- package/dist/core/agent-capability-contract.d.ts +0 -7
- package/dist/core/agent-capability-contract.d.ts.map +1 -1
- package/dist/core/agent-capability-contract.js +72 -68
- package/dist/core/agent-capability-contract.js.map +1 -1
- package/dist/core/agent-session-bash.d.ts.map +1 -1
- package/dist/core/agent-session-bash.js +5 -4
- package/dist/core/agent-session-bash.js.map +1 -1
- package/dist/core/agent-session-compaction.d.ts +6 -10
- package/dist/core/agent-session-compaction.d.ts.map +1 -1
- package/dist/core/agent-session-compaction.js +35 -133
- package/dist/core/agent-session-compaction.js.map +1 -1
- package/dist/core/agent-session-context.d.ts.map +1 -1
- package/dist/core/agent-session-context.js +18 -13
- package/dist/core/agent-session-context.js.map +1 -1
- package/dist/core/agent-session-internal.d.ts +0 -6
- package/dist/core/agent-session-internal.d.ts.map +1 -1
- package/dist/core/agent-session-internal.js.map +1 -1
- package/dist/core/agent-session-model.d.ts.map +1 -1
- package/dist/core/agent-session-model.js +2 -1
- package/dist/core/agent-session-model.js.map +1 -1
- package/dist/core/agent-session-retry.d.ts.map +1 -1
- package/dist/core/agent-session-retry.js +3 -3
- package/dist/core/agent-session-retry.js.map +1 -1
- package/dist/core/agent-session-runtime.d.ts.map +1 -1
- package/dist/core/agent-session-runtime.js +7 -6
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session-services.d.ts +1 -1
- package/dist/core/agent-session-services.d.ts.map +1 -1
- package/dist/core/agent-session-services.js.map +1 -1
- package/dist/core/agent-session-tools.d.ts.map +1 -1
- package/dist/core/agent-session-tools.js +3 -2
- package/dist/core/agent-session-tools.js.map +1 -1
- package/dist/core/agent-session.d.ts +40 -22
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +147 -67
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/auth-guidance.d.ts.map +1 -1
- package/dist/core/auth-guidance.js +11 -5
- package/dist/core/auth-guidance.js.map +1 -1
- package/dist/core/auth-storage.d.ts.map +1 -1
- package/dist/core/auth-storage.js +9 -6
- package/dist/core/auth-storage.js.map +1 -1
- package/dist/core/compaction/compaction.d.ts.map +1 -1
- package/dist/core/compaction/compaction.js +2 -1
- package/dist/core/compaction/compaction.js.map +1 -1
- package/dist/core/embedded-sdk.d.ts.map +1 -1
- package/dist/core/embedded-sdk.js +10 -6
- package/dist/core/embedded-sdk.js.map +1 -1
- package/dist/core/export-html/index.d.ts.map +1 -1
- package/dist/core/export-html/index.js +9 -4
- package/dist/core/export-html/index.js.map +1 -1
- package/dist/core/extensions/agent-composition.d.ts.map +1 -1
- package/dist/core/extensions/agent-composition.js +26 -19
- package/dist/core/extensions/agent-composition.js.map +1 -1
- package/dist/core/extensions/bootstrap-agent-loop.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-agent-loop.js +3 -2
- package/dist/core/extensions/bootstrap-agent-loop.js.map +1 -1
- package/dist/core/extensions/bootstrap-compaction-policy.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-compaction-policy.js +0 -34
- package/dist/core/extensions/bootstrap-compaction-policy.js.map +1 -1
- package/dist/core/extensions/bootstrap-lifecycle.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-lifecycle.js +20 -17
- package/dist/core/extensions/bootstrap-lifecycle.js.map +1 -1
- package/dist/core/extensions/bootstrap-overflow-policy.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-overflow-policy.js +2 -1
- package/dist/core/extensions/bootstrap-overflow-policy.js.map +1 -1
- package/dist/core/extensions/bootstrap-retry-policy.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-retry-policy.js +4 -3
- package/dist/core/extensions/bootstrap-retry-policy.js.map +1 -1
- package/dist/core/extensions/bootstrap-skills.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-skills.js +7 -6
- package/dist/core/extensions/bootstrap-skills.js.map +1 -1
- package/dist/core/extensions/bootstrap-tools.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-tools.js +2 -1
- package/dist/core/extensions/bootstrap-tools.js.map +1 -1
- package/dist/core/extensions/capability-plugin.d.ts.map +1 -1
- package/dist/core/extensions/capability-plugin.js +37 -13
- package/dist/core/extensions/capability-plugin.js.map +1 -1
- package/dist/core/extensions/capability-runtime-events.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-events.js +17 -13
- package/dist/core/extensions/capability-runtime-events.js.map +1 -1
- package/dist/core/extensions/capability-runtime-guards.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-guards.js +16 -15
- package/dist/core/extensions/capability-runtime-guards.js.map +1 -1
- package/dist/core/extensions/capability-runtime-manifest.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-manifest.js +52 -30
- package/dist/core/extensions/capability-runtime-manifest.js.map +1 -1
- package/dist/core/extensions/capability-runtime-validation.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-validation.js +66 -65
- package/dist/core/extensions/capability-runtime-validation.js.map +1 -1
- package/dist/core/extensions/capability-runtime.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime.js +147 -127
- package/dist/core/extensions/capability-runtime.js.map +1 -1
- package/dist/core/extensions/compaction-memory-failure-mode.d.ts.map +1 -1
- package/dist/core/extensions/compaction-memory-failure-mode.js +3 -2
- package/dist/core/extensions/compaction-memory-failure-mode.js.map +1 -1
- package/dist/core/extensions/context-strategy-binding.d.ts.map +1 -1
- package/dist/core/extensions/context-strategy-binding.js +7 -4
- package/dist/core/extensions/context-strategy-binding.js.map +1 -1
- package/dist/core/extensions/lifecycle-catalog.d.ts.map +1 -1
- package/dist/core/extensions/lifecycle-catalog.js +290 -279
- package/dist/core/extensions/lifecycle-catalog.js.map +1 -1
- package/dist/core/extensions/lifecycle-delivery-queue.d.ts.map +1 -1
- package/dist/core/extensions/lifecycle-delivery-queue.js +3 -2
- package/dist/core/extensions/lifecycle-delivery-queue.js.map +1 -1
- package/dist/core/extensions/provider-failover.d.ts +7 -3
- package/dist/core/extensions/provider-failover.d.ts.map +1 -1
- package/dist/core/extensions/provider-failover.js +9 -8
- package/dist/core/extensions/provider-failover.js.map +1 -1
- package/dist/core/facade/coding-agent-facade.d.ts +6 -6
- package/dist/core/facade/coding-agent-facade.d.ts.map +1 -1
- package/dist/core/facade/coding-agent-facade.js +2 -3
- package/dist/core/facade/coding-agent-facade.js.map +1 -1
- package/dist/core/http-dispatcher.d.ts.map +1 -1
- package/dist/core/http-dispatcher.js +2 -1
- package/dist/core/http-dispatcher.js.map +1 -1
- package/dist/core/i18n/index.d.ts +14 -0
- package/dist/core/i18n/index.d.ts.map +1 -0
- package/dist/core/i18n/index.js +67 -0
- package/dist/core/i18n/index.js.map +1 -0
- package/dist/core/i18n/locales/en/example.d.ts +7 -0
- package/dist/core/i18n/locales/en/example.d.ts.map +1 -0
- package/dist/core/i18n/locales/en/example.js +7 -0
- package/dist/core/i18n/locales/en/example.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/cli.d.ts +8 -0
- package/dist/core/i18n/locales/zh-cn/cli.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/cli.js +229 -0
- package/dist/core/i18n/locales/zh-cn/cli.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/common.d.ts +6 -0
- package/dist/core/i18n/locales/zh-cn/common.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/common.js +6 -0
- package/dist/core/i18n/locales/zh-cn/common.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-core.d.ts +13 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-core.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-core.js +173 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-core.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-extensions.d.ts +12 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-extensions.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-extensions.js +582 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-extensions.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-final.d.ts +9 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-final.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-final.js +55 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-final.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-plugins.d.ts +11 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-plugins.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-plugins.js +455 -0
- package/dist/core/i18n/locales/zh-cn/core-contract-plugins.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-errors.d.ts +9 -0
- package/dist/core/i18n/locales/zh-cn/core-errors.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/core-errors.js +191 -0
- package/dist/core/i18n/locales/zh-cn/core-errors.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/example.d.ts +7 -0
- package/dist/core/i18n/locales/zh-cn/example.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/example.js +10 -0
- package/dist/core/i18n/locales/zh-cn/example.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/index.d.ts +2 -0
- package/dist/core/i18n/locales/zh-cn/index.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/index.js +41 -0
- package/dist/core/i18n/locales/zh-cn/index.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/interactive-mode.d.ts +10 -0
- package/dist/core/i18n/locales/zh-cn/interactive-mode.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/interactive-mode.js +267 -0
- package/dist/core/i18n/locales/zh-cn/interactive-mode.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/keybindings.d.ts +11 -0
- package/dist/core/i18n/locales/zh-cn/keybindings.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/keybindings.js +67 -0
- package/dist/core/i18n/locales/zh-cn/keybindings.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/slash-commands.d.ts +7 -0
- package/dist/core/i18n/locales/zh-cn/slash-commands.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/slash-commands.js +39 -0
- package/dist/core/i18n/locales/zh-cn/slash-commands.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-builtin.d.ts +10 -0
- package/dist/core/i18n/locales/zh-cn/tui-builtin.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-builtin.js +15 -0
- package/dist/core/i18n/locales/zh-cn/tui-builtin.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-misc.d.ts +13 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-misc.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-misc.js +102 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-misc.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-selectors.d.ts +12 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-selectors.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-selectors.js +286 -0
- package/dist/core/i18n/locales/zh-cn/tui-components-selectors.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-interactive-misc.d.ts +9 -0
- package/dist/core/i18n/locales/zh-cn/tui-interactive-misc.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-interactive-misc.js +79 -0
- package/dist/core/i18n/locales/zh-cn/tui-interactive-misc.js.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-self-owned.d.ts +8 -0
- package/dist/core/i18n/locales/zh-cn/tui-self-owned.d.ts.map +1 -0
- package/dist/core/i18n/locales/zh-cn/tui-self-owned.js +72 -0
- package/dist/core/i18n/locales/zh-cn/tui-self-owned.js.map +1 -0
- package/dist/core/keybindings.d.ts +15 -0
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +18 -0
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/logger.d.ts.map +1 -1
- package/dist/core/logger.js +5 -1
- package/dist/core/logger.js.map +1 -1
- package/dist/core/model-config.d.ts +0 -1
- package/dist/core/model-config.d.ts.map +1 -1
- package/dist/core/model-config.js +9 -1
- package/dist/core/model-config.js.map +1 -1
- package/dist/core/model-registry.d.ts.map +1 -1
- package/dist/core/model-registry.js +2 -1
- package/dist/core/model-registry.js.map +1 -1
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +11 -7
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/package-install-host.d.ts.map +1 -1
- package/dist/core/package-install-host.js +4 -3
- package/dist/core/package-install-host.js.map +1 -1
- package/dist/core/package-manager.d.ts.map +1 -1
- package/dist/core/package-manager.js +15 -10
- package/dist/core/package-manager.js.map +1 -1
- package/dist/core/package-resource-collection.d.ts.map +1 -1
- package/dist/core/package-resource-collection.js +2 -1
- package/dist/core/package-resource-collection.js.map +1 -1
- package/dist/core/package-source.d.ts.map +1 -1
- package/dist/core/package-source.js +3 -2
- package/dist/core/package-source.js.map +1 -1
- package/dist/core/provider-composer.d.ts +2 -2
- package/dist/core/provider-composer.d.ts.map +1 -1
- package/dist/core/provider-composer.js +29 -21
- package/dist/core/provider-composer.js.map +1 -1
- package/dist/core/remote-catalog-provider.d.ts.map +1 -1
- package/dist/core/remote-catalog-provider.js +6 -2
- package/dist/core/remote-catalog-provider.js.map +1 -1
- package/dist/core/resolve-config-value.d.ts.map +1 -1
- package/dist/core/resolve-config-value.js +15 -5
- package/dist/core/resolve-config-value.js.map +1 -1
- package/dist/core/sdk.d.ts +27 -5
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +80 -55
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-cwd.d.ts.map +1 -1
- package/dist/core/session-cwd.js +5 -2
- package/dist/core/session-cwd.js.map +1 -1
- package/dist/core/session-export.d.ts.map +1 -1
- package/dist/core/session-export.js +2 -1
- package/dist/core/session-export.js.map +1 -1
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +39 -29
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/session-storage.d.ts.map +1 -1
- package/dist/core/session-storage.js +3 -3
- package/dist/core/session-storage.js.map +1 -1
- package/dist/core/settings-manager.d.ts +20 -20
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +47 -59
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/slash-commands.d.ts.map +1 -1
- package/dist/core/slash-commands.js +53 -32
- package/dist/core/slash-commands.js.map +1 -1
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +25 -2
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/core/tools/bash.d.ts.map +1 -1
- package/dist/core/tools/bash.js +11 -7
- package/dist/core/tools/bash.js.map +1 -1
- package/dist/core/tools/edit-diff.d.ts.map +1 -1
- package/dist/core/tools/edit-diff.js +9 -4
- package/dist/core/tools/edit-diff.js.map +1 -1
- package/dist/core/tools/edit.d.ts.map +1 -1
- package/dist/core/tools/edit.js +4 -3
- package/dist/core/tools/edit.js.map +1 -1
- package/dist/core/tools/index.d.ts.map +1 -1
- package/dist/core/tools/index.js +3 -2
- package/dist/core/tools/index.js.map +1 -1
- package/dist/core/tools/output-accumulator.d.ts.map +1 -1
- package/dist/core/tools/output-accumulator.js +2 -1
- package/dist/core/tools/output-accumulator.js.map +1 -1
- package/dist/core/tools/read.d.ts.map +1 -1
- package/dist/core/tools/read.js +6 -2
- package/dist/core/tools/read.js.map +1 -1
- package/dist/core/tools/write.d.ts.map +1 -1
- package/dist/core/tools/write.js +2 -1
- package/dist/core/tools/write.js.map +1 -1
- package/dist/durable/durable-service.d.ts.map +1 -1
- package/dist/durable/durable-service.js +25 -18
- package/dist/durable/durable-service.js.map +1 -1
- package/dist/host/checkpoint-commit.d.ts.map +1 -1
- package/dist/host/checkpoint-commit.js +2 -1
- package/dist/host/checkpoint-commit.js.map +1 -1
- package/dist/host/manual-compaction.d.ts.map +1 -1
- package/dist/host/manual-compaction.js +2 -1
- package/dist/host/manual-compaction.js.map +1 -1
- package/dist/host/output-projection.d.ts +0 -13
- package/dist/host/output-projection.d.ts.map +1 -1
- package/dist/host/output-projection.js +16 -2
- package/dist/host/output-projection.js.map +1 -1
- package/dist/host/summary-retry.d.ts.map +1 -1
- package/dist/host/summary-retry.js +3 -2
- package/dist/host/summary-retry.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +97 -60
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/agents-view.d.ts.map +1 -1
- package/dist/modes/interactive/components/agents-view.js +18 -15
- package/dist/modes/interactive/components/agents-view.js.map +1 -1
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +6 -5
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/bash-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/bash-execution.js +12 -7
- package/dist/modes/interactive/components/bash-execution.js.map +1 -1
- package/dist/modes/interactive/components/bordered-loader.d.ts.map +1 -1
- package/dist/modes/interactive/components/bordered-loader.js +2 -1
- package/dist/modes/interactive/components/bordered-loader.js.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.js +6 -5
- package/dist/modes/interactive/components/branch-summary-message.js.map +1 -1
- package/dist/modes/interactive/components/compaction-summary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/compaction-summary-message.js +9 -5
- package/dist/modes/interactive/components/compaction-summary-message.js.map +1 -1
- package/dist/modes/interactive/components/config-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/config-selector.js +18 -15
- package/dist/modes/interactive/components/config-selector.js.map +1 -1
- package/dist/modes/interactive/components/custom-entry.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-entry.js +2 -1
- package/dist/modes/interactive/components/custom-entry.js.map +1 -1
- package/dist/modes/interactive/components/dialog-editor.d.ts.map +1 -1
- package/dist/modes/interactive/components/dialog-editor.js +5 -4
- package/dist/modes/interactive/components/dialog-editor.js.map +1 -1
- package/dist/modes/interactive/components/dialog-input.d.ts.map +1 -1
- package/dist/modes/interactive/components/dialog-input.js +2 -1
- package/dist/modes/interactive/components/dialog-input.js.map +1 -1
- package/dist/modes/interactive/components/dialog-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/dialog-selector.js +4 -3
- package/dist/modes/interactive/components/dialog-selector.js.map +1 -1
- package/dist/modes/interactive/components/first-time-setup.d.ts.map +1 -1
- package/dist/modes/interactive/components/first-time-setup.js +11 -10
- package/dist/modes/interactive/components/first-time-setup.js.map +1 -1
- package/dist/modes/interactive/components/footer.d.ts +0 -2
- package/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/dist/modes/interactive/components/footer.js +8 -10
- package/dist/modes/interactive/components/footer.js.map +1 -1
- package/dist/modes/interactive/components/index.d.ts +1 -0
- package/dist/modes/interactive/components/index.d.ts.map +1 -1
- package/dist/modes/interactive/components/index.js +1 -0
- package/dist/modes/interactive/components/index.js.map +1 -1
- package/dist/modes/interactive/components/keybinding-hints.d.ts.map +1 -1
- package/dist/modes/interactive/components/keybinding-hints.js +3 -2
- package/dist/modes/interactive/components/keybinding-hints.js.map +1 -1
- package/dist/modes/interactive/components/login-dialog.d.ts.map +1 -1
- package/dist/modes/interactive/components/login-dialog.js +12 -11
- package/dist/modes/interactive/components/login-dialog.js.map +1 -1
- package/dist/modes/interactive/components/mermaid.d.ts.map +1 -1
- package/dist/modes/interactive/components/mermaid.js +6 -2
- package/dist/modes/interactive/components/mermaid.js.map +1 -1
- package/dist/modes/interactive/components/model-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/model-selector.js +28 -16
- package/dist/modes/interactive/components/model-selector.js.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.js +10 -9
- package/dist/modes/interactive/components/oauth-selector.js.map +1 -1
- package/dist/modes/interactive/components/plugin-manager-entry.d.ts.map +1 -1
- package/dist/modes/interactive/components/plugin-manager-entry.js +22 -13
- package/dist/modes/interactive/components/plugin-manager-entry.js.map +1 -1
- package/dist/modes/interactive/components/plugin-selection-entry.d.ts.map +1 -1
- package/dist/modes/interactive/components/plugin-selection-entry.js +27 -12
- package/dist/modes/interactive/components/plugin-selection-entry.js.map +1 -1
- package/dist/modes/interactive/components/queue-manager-selector.d.ts +60 -0
- package/dist/modes/interactive/components/queue-manager-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/queue-manager-selector.js +166 -0
- package/dist/modes/interactive/components/queue-manager-selector.js.map +1 -0
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +16 -14
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -1
- package/dist/modes/interactive/components/session-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector.js +43 -31
- package/dist/modes/interactive/components/session-selector.js.map +1 -1
- package/dist/modes/interactive/components/settings-selector.d.ts +4 -6
- package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/settings-selector.js +115 -120
- package/dist/modes/interactive/components/settings-selector.js.map +1 -1
- package/dist/modes/interactive/components/settings-submenu.d.ts.map +1 -1
- package/dist/modes/interactive/components/settings-submenu.js +5 -4
- package/dist/modes/interactive/components/settings-submenu.js.map +1 -1
- package/dist/modes/interactive/components/show-images-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/show-images-selector.js +3 -2
- package/dist/modes/interactive/components/show-images-selector.js.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.js +4 -3
- package/dist/modes/interactive/components/skill-invocation-message.js.map +1 -1
- package/dist/modes/interactive/components/status-indicator.d.ts.map +1 -1
- package/dist/modes/interactive/components/status-indicator.js +14 -5
- package/dist/modes/interactive/components/status-indicator.js.map +1 -1
- package/dist/modes/interactive/components/theme-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/theme-selector.js +2 -1
- package/dist/modes/interactive/components/theme-selector.js.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.js +11 -4
- package/dist/modes/interactive/components/thinking-selector.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +8 -3
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/components/tree-list.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-list.js +7 -6
- package/dist/modes/interactive/components/tree-list.js.map +1 -1
- package/dist/modes/interactive/components/tree-render.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-render.js +28 -23
- package/dist/modes/interactive/components/tree-render.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector.js +9 -7
- package/dist/modes/interactive/components/tree-selector.js.map +1 -1
- package/dist/modes/interactive/components/user-message-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/user-message-selector.js +5 -4
- package/dist/modes/interactive/components/user-message-selector.js.map +1 -1
- package/dist/modes/interactive/components/workflow-view.d.ts.map +1 -1
- package/dist/modes/interactive/components/workflow-view.js +36 -21
- package/dist/modes/interactive/components/workflow-view.js.map +1 -1
- package/dist/modes/interactive/external-editor.d.ts.map +1 -1
- package/dist/modes/interactive/external-editor.js +2 -1
- package/dist/modes/interactive/external-editor.js.map +1 -1
- package/dist/modes/interactive/interactive-auth.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-auth.js +71 -40
- package/dist/modes/interactive/interactive-auth.js.map +1 -1
- package/dist/modes/interactive/interactive-commands.d.ts +1 -0
- package/dist/modes/interactive/interactive-commands.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-commands.js +3 -0
- package/dist/modes/interactive/interactive-commands.js.map +1 -1
- package/dist/modes/interactive/interactive-dialog-ui.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-dialog-ui.js +5 -5
- package/dist/modes/interactive/interactive-dialog-ui.js.map +1 -1
- package/dist/modes/interactive/interactive-format.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-format.js +34 -18
- package/dist/modes/interactive/interactive-format.js.map +1 -1
- package/dist/modes/interactive/interactive-helpers.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-helpers.js +7 -2
- package/dist/modes/interactive/interactive-helpers.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +4 -2
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +350 -279
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/interactive-selectors.d.ts +9 -0
- package/dist/modes/interactive/interactive-selectors.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-selectors.js +79 -25
- package/dist/modes/interactive/interactive-selectors.js.map +1 -1
- package/dist/modes/interactive/theme/theme-controller.d.ts.map +1 -1
- package/dist/modes/interactive/theme/theme-controller.js +5 -1
- package/dist/modes/interactive/theme/theme-controller.js.map +1 -1
- package/dist/modes/interactive/theme/theme.d.ts.map +1 -1
- package/dist/modes/interactive/theme/theme.js +26 -23
- package/dist/modes/interactive/theme/theme.js.map +1 -1
- package/dist/modes/json-event.d.ts.map +1 -1
- package/dist/modes/json-event.js +3 -2
- package/dist/modes/json-event.js.map +1 -1
- package/dist/modes/print-mode.d.ts.map +1 -1
- package/dist/modes/print-mode.js +3 -2
- package/dist/modes/print-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts +0 -8
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +3 -14
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-mode.js +0 -9
- package/dist/modes/rpc/rpc-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +0 -19
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/dist/package-manager-cli.d.ts.map +1 -1
- package/dist/package-manager-cli.js +28 -13
- package/dist/package-manager-cli.js.map +1 -1
- package/dist/plugins/ecosystem/catalog.d.ts.map +1 -1
- package/dist/plugins/ecosystem/catalog.js +3 -2
- package/dist/plugins/ecosystem/catalog.js.map +1 -1
- package/dist/plugins/ecosystem/cli.d.ts.map +1 -1
- package/dist/plugins/ecosystem/cli.js +2 -1
- package/dist/plugins/ecosystem/cli.js.map +1 -1
- package/dist/plugins/ecosystem/default-plugin-market.d.ts.map +1 -1
- package/dist/plugins/ecosystem/default-plugin-market.js +3 -2
- package/dist/plugins/ecosystem/default-plugin-market.js.map +1 -1
- package/dist/plugins/ecosystem/distribution.d.ts.map +1 -1
- package/dist/plugins/ecosystem/distribution.js +2 -1
- package/dist/plugins/ecosystem/distribution.js.map +1 -1
- package/dist/plugins/ecosystem/installer.d.ts.map +1 -1
- package/dist/plugins/ecosystem/installer.js +3 -2
- package/dist/plugins/ecosystem/installer.js.map +1 -1
- package/dist/plugins/ecosystem/node-disk-registry-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-disk-registry-source.js +20 -17
- package/dist/plugins/ecosystem/node-disk-registry-source.js.map +1 -1
- package/dist/plugins/ecosystem/node-distribution-host.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-distribution-host.js +35 -34
- package/dist/plugins/ecosystem/node-distribution-host.js.map +1 -1
- package/dist/plugins/ecosystem/node-npm-registry-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-npm-registry-source.js +35 -34
- package/dist/plugins/ecosystem/node-npm-registry-source.js.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-host.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-host.js +9 -8
- package/dist/plugins/ecosystem/node-package-install-host.js.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-persistence.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-persistence.js +4 -3
- package/dist/plugins/ecosystem/node-package-install-persistence.js.map +1 -1
- package/dist/plugins/ecosystem/node-plugin-bootstrap.d.ts +9 -2
- package/dist/plugins/ecosystem/node-plugin-bootstrap.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-plugin-bootstrap.js +44 -5
- package/dist/plugins/ecosystem/node-plugin-bootstrap.js.map +1 -1
- package/dist/plugins/ecosystem/node-plugin-trust-root.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-plugin-trust-root.js +10 -9
- package/dist/plugins/ecosystem/node-plugin-trust-root.js.map +1 -1
- package/dist/plugins/ecosystem/node-registry-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-registry-source.js +31 -30
- package/dist/plugins/ecosystem/node-registry-source.js.map +1 -1
- package/dist/plugins/ecosystem/node-release-package-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-release-package-source.js +30 -29
- package/dist/plugins/ecosystem/node-release-package-source.js.map +1 -1
- package/dist/plugins/ecosystem/node-tar-writer.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-tar-writer.js +11 -10
- package/dist/plugins/ecosystem/node-tar-writer.js.map +1 -1
- package/dist/plugins/ecosystem/node-url-package-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-url-package-source.js +21 -20
- package/dist/plugins/ecosystem/node-url-package-source.js.map +1 -1
- package/dist/plugins/ecosystem/plugin-acquisition.d.ts.map +1 -1
- package/dist/plugins/ecosystem/plugin-acquisition.js +3 -2
- package/dist/plugins/ecosystem/plugin-acquisition.js.map +1 -1
- package/dist/plugins/ecosystem/plugin-bootstrap.d.ts +9 -1
- package/dist/plugins/ecosystem/plugin-bootstrap.d.ts.map +1 -1
- package/dist/plugins/ecosystem/plugin-bootstrap.js +5 -0
- package/dist/plugins/ecosystem/plugin-bootstrap.js.map +1 -1
- package/dist/plugins/ecosystem/registry-cli-adapter.d.ts.map +1 -1
- package/dist/plugins/ecosystem/registry-cli-adapter.js +2 -1
- package/dist/plugins/ecosystem/registry-cli-adapter.js.map +1 -1
- package/dist/plugins/ecosystem/registry.d.ts.map +1 -1
- package/dist/plugins/ecosystem/registry.js +35 -32
- package/dist/plugins/ecosystem/registry.js.map +1 -1
- package/dist/plugins/ecosystem/resolver.d.ts.map +1 -1
- package/dist/plugins/ecosystem/resolver.js +3 -2
- package/dist/plugins/ecosystem/resolver.js.map +1 -1
- package/dist/plugins/ecosystem/selection-store.d.ts.map +1 -1
- package/dist/plugins/ecosystem/selection-store.js +11 -10
- package/dist/plugins/ecosystem/selection-store.js.map +1 -1
- package/dist/plugins/ecosystem/selection.d.ts.map +1 -1
- package/dist/plugins/ecosystem/selection.js +8 -7
- package/dist/plugins/ecosystem/selection.js.map +1 -1
- package/dist/plugins/ecosystem/state.d.ts.map +1 -1
- package/dist/plugins/ecosystem/state.js +24 -23
- package/dist/plugins/ecosystem/state.js.map +1 -1
- package/dist/plugins/ecosystem/updates.d.ts.map +1 -1
- package/dist/plugins/ecosystem/updates.js +5 -4
- package/dist/plugins/ecosystem/updates.js.map +1 -1
- package/dist/plugins/mcp-http.d.ts +0 -17
- package/dist/plugins/mcp-http.d.ts.map +1 -1
- package/dist/plugins/mcp-http.js +30 -7
- package/dist/plugins/mcp-http.js.map +1 -1
- package/dist/plugins/plugin-supervisor.d.ts.map +1 -1
- package/dist/plugins/plugin-supervisor.js +19 -1
- package/dist/plugins/plugin-supervisor.js.map +1 -1
- package/dist/profile/first-roles.d.ts.map +1 -1
- package/dist/profile/first-roles.js +10 -1
- package/dist/profile/first-roles.js.map +1 -1
- package/dist/profile/goal-plugin.d.ts.map +1 -1
- package/dist/profile/goal-plugin.js +24 -5
- package/dist/profile/goal-plugin.js.map +1 -1
- package/dist/profile/identity.d.ts.map +1 -1
- package/dist/profile/identity.js +7 -6
- package/dist/profile/identity.js.map +1 -1
- package/dist/profile/lock.d.ts.map +1 -1
- package/dist/profile/lock.js +15 -1
- package/dist/profile/lock.js.map +1 -1
- package/dist/profile/plan-plugin.d.ts.map +1 -1
- package/dist/profile/plan-plugin.js +26 -13
- package/dist/profile/plan-plugin.js.map +1 -1
- package/dist/profile/plugin-profiles.d.ts.map +1 -1
- package/dist/profile/plugin-profiles.js +2 -1
- package/dist/profile/plugin-profiles.js.map +1 -1
- package/dist/profile/policy-manifest.d.ts.map +1 -1
- package/dist/profile/policy-manifest.js +5 -4
- package/dist/profile/policy-manifest.js.map +1 -1
- package/dist/profile/profile-registry.d.ts +0 -12
- package/dist/profile/profile-registry.d.ts.map +1 -1
- package/dist/profile/profile-registry.js +14 -1
- package/dist/profile/profile-registry.js.map +1 -1
- package/dist/profile/role-catalog.d.ts +0 -1
- package/dist/profile/role-catalog.d.ts.map +1 -1
- package/dist/profile/role-catalog.js +17 -15
- package/dist/profile/role-catalog.js.map +1 -1
- package/dist/profile/role-orchestrator.d.ts.map +1 -1
- package/dist/profile/role-orchestrator.js +8 -7
- package/dist/profile/role-orchestrator.js.map +1 -1
- package/dist/profile/role-runner.d.ts.map +1 -1
- package/dist/profile/role-runner.js +3 -2
- package/dist/profile/role-runner.js.map +1 -1
- package/dist/profile/root-facade.d.ts.map +1 -1
- package/dist/profile/root-facade.js +2 -1
- package/dist/profile/root-facade.js.map +1 -1
- package/dist/profile/skill-discovery-wiring.d.ts.map +1 -1
- package/dist/profile/skill-discovery-wiring.js +7 -2
- package/dist/profile/skill-discovery-wiring.js.map +1 -1
- package/dist/profile/state-store.d.ts.map +1 -1
- package/dist/profile/state-store.js +13 -9
- package/dist/profile/state-store.js.map +1 -1
- package/dist/profile/todo-plugin.d.ts.map +1 -1
- package/dist/profile/todo-plugin.js +9 -4
- package/dist/profile/todo-plugin.js.map +1 -1
- package/dist/profiles/builtin-suites.d.ts +13 -6
- package/dist/profiles/builtin-suites.d.ts.map +1 -1
- package/dist/profiles/builtin-suites.js +15 -6
- package/dist/profiles/builtin-suites.js.map +1 -1
- package/dist/profiles/suite-loader.d.ts +25 -1
- package/dist/profiles/suite-loader.d.ts.map +1 -1
- package/dist/profiles/suite-loader.js +34 -9
- package/dist/profiles/suite-loader.js.map +1 -1
- package/dist/remote/server-entry.d.ts.map +1 -1
- package/dist/remote/server-entry.js +3 -2
- package/dist/remote/server-entry.js.map +1 -1
- package/dist/remote/session-source.d.ts.map +1 -1
- package/dist/remote/session-source.js +8 -4
- package/dist/remote/session-source.js.map +1 -1
- package/dist/share/session-share.d.ts.map +1 -1
- package/dist/share/session-share.js +14 -2
- package/dist/share/session-share.js.map +1 -1
- package/dist/testing/plugin-testkit.d.ts.map +1 -1
- package/dist/testing/plugin-testkit.js +4 -3
- package/dist/testing/plugin-testkit.js.map +1 -1
- package/dist/testing/runtime-delivery-queue.d.ts.map +1 -1
- package/dist/testing/runtime-delivery-queue.js +2 -1
- package/dist/testing/runtime-delivery-queue.js.map +1 -1
- package/dist/testing/session-plugin-testkit.d.ts.map +1 -1
- package/dist/testing/session-plugin-testkit.js +10 -7
- package/dist/testing/session-plugin-testkit.js.map +1 -1
- package/dist/utils/ansi.d.ts.map +1 -1
- package/dist/utils/ansi.js +2 -1
- package/dist/utils/ansi.js.map +1 -1
- package/dist/utils/clipboard.d.ts.map +1 -1
- package/dist/utils/clipboard.js +7 -6
- package/dist/utils/clipboard.js.map +1 -1
- package/dist/utils/image-resize-worker.d.ts.map +1 -1
- package/dist/utils/image-resize-worker.js +3 -2
- package/dist/utils/image-resize-worker.js.map +1 -1
- package/dist/utils/photon.d.ts +2 -2
- package/dist/utils/photon.d.ts.map +1 -1
- package/dist/utils/photon.js +2 -2
- package/dist/utils/photon.js.map +1 -1
- package/dist/utils/shell.d.ts.map +1 -1
- package/dist/utils/shell.js +9 -8
- package/dist/utils/shell.js.map +1 -1
- package/dist/utils/tools-manager.d.ts.map +1 -1
- package/dist/utils/tools-manager.js +23 -13
- package/dist/utils/tools-manager.js.map +1 -1
- package/dist/utils/version-check.d.ts.map +1 -1
- package/dist/utils/version-check.js +5 -1
- package/dist/utils/version-check.js.map +1 -1
- package/docs/compaction.md +1 -3
- package/docs/docs.json +4 -0
- package/docs/index.md +1 -0
- package/docs/keybindings.md +3 -0
- package/docs/mcp.md +103 -0
- package/docs/models.md +14 -22
- package/docs/providers.md +0 -1
- package/docs/quickstart.md +1 -1
- package/docs/rpc.md +1 -26
- package/docs/sdk.md +4 -6
- package/docs/settings.md +10 -12
- package/docs/skills.md +1 -9
- package/docs/terminal-setup.md +2 -3
- package/docs/usage.md +7 -6
- package/examples/extensions/with-deps/package-lock.json +2 -2
- package/examples/extensions/with-deps/package.json +1 -1
- package/examples/extensions/with-deps/plugin.json +1 -1
- package/examples/sdk/10-settings.ts +2 -4
- package/examples/sdk/12-full-control.ts +1 -2
- package/package.json +1 -3
- package/dist/bundle/chunks/chunk-EALJ5DDX.js +0 -1452
- package/dist/core/extensions/microcompact.d.ts +0 -80
- package/dist/core/extensions/microcompact.d.ts.map +0 -1
- package/dist/core/extensions/microcompact.js +0 -134
- package/dist/core/extensions/microcompact.js.map +0 -1
- package/dist/server/create-harness.d.ts +0 -26
- package/dist/server/create-harness.d.ts.map +0 -1
- package/dist/server/create-harness.js +0 -106
- package/dist/server/create-harness.js.map +0 -1
|
@@ -33,6 +33,7 @@ import { formatNoApiKeyFoundMessage, formatNoModelSelectedMessage } from "./auth
|
|
|
33
33
|
import { THINKING_LEVEL_OPTIONS } from "./defaults.js";
|
|
34
34
|
import { definitionSnapshot, detachedSnapshot } from "./extensions/capability-runtime-snapshot.js";
|
|
35
35
|
import { BOOTSTRAP_AGENT_LOOP_PLUGIN_ID, BOOTSTRAP_BRANCH_SUMMARY_PLUGIN_ID, BOOTSTRAP_COMPACTION_PLUGIN_ID, BOOTSTRAP_LIFECYCLE_PLUGIN_ID, BOOTSTRAP_OVERFLOW_PLUGIN_ID, BOOTSTRAP_RETRY_PLUGIN_ID, BOOTSTRAP_SKILLS_PLUGIN_ID, BOOTSTRAP_TOOLS_PLUGIN_ID, createCapabilityRuntime, DEFAULT_BRANCH_SUMMARY_POLICY_NAME, DEFAULT_COMPACTION_POLICY_NAME, DEFAULT_OVERFLOW_POLICY_NAME, DEFAULT_RETRY_POLICY_NAME, DEFAULT_RUN_LOOP_STRATEGY_NAME, EXPERIMENTAL_PUBLIC_API_VERSION, installBootstrapAgentLoop, installBootstrapBranchSummaryPolicy, installBootstrapCompactionPolicy, installBootstrapLifecycle, installBootstrapOverflowPolicy, installBootstrapRetryPolicy, installSessionBootstrapSkills, installSessionBootstrapTools, loadCapabilityPluginFromManifest, loadCapabilityPlugin as loadCapabilityPluginRuntime, } from "./extensions/index.js";
|
|
36
|
+
import { t } from "./i18n/index.js";
|
|
36
37
|
import { expandPromptTemplate } from "./prompt-templates.js";
|
|
37
38
|
import { createSessionJsonlArtifact } from "./session-export.js";
|
|
38
39
|
import { createToolSearchTool } from "./tools/tool-search.js";
|
|
@@ -103,14 +104,6 @@ export class AgentSession {
|
|
|
103
104
|
_overflowRecoveryAttempted = false;
|
|
104
105
|
// biome-ignore lint/correctness/noUnusedPrivateClassMembers: read and written via the agent-session-* submodule facade
|
|
105
106
|
_overflowTrimStage = 0;
|
|
106
|
-
/**
|
|
107
|
-
* microcompact 冷却(按模型请求计数,0 = 不冷却):relief 落地时置
|
|
108
|
-
* MICROCOMPACT_COOLDOWN_ASSISTANT_RESPONSES,此后每次 assistant message_end
|
|
109
|
-
* (无论 stopReason)减 1、下限 0;user message_start 不复位。冷却期内阈值
|
|
110
|
-
* decide 以 microcompactEnabled:false 关闭便宜缓解。微观经济动机见
|
|
111
|
-
* agent-session-compaction.ts 的常量注释(中部历史改写 × 不稳定前缀缓存)。
|
|
112
|
-
*/
|
|
113
|
-
_microcompactCooldown = 0;
|
|
114
107
|
// Branch summarization state
|
|
115
108
|
_branchSummaryAbortController = undefined;
|
|
116
109
|
_branchSummaryPromise = undefined;
|
|
@@ -446,12 +439,23 @@ export class AgentSession {
|
|
|
446
439
|
};
|
|
447
440
|
await this._dispatchModelStreamLifecycle(event.message, "start", "raw");
|
|
448
441
|
}
|
|
449
|
-
// When a user message starts, check if it's from either queue and
|
|
450
|
-
// This ensures the UI sees the updated queue state
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
442
|
+
// When a user or custom message starts, check if it's from either queue and
|
|
443
|
+
// remove it BEFORE emitting. This ensures the UI sees the updated queue state.
|
|
444
|
+
// Queued custom messages (sendCustomMessage deliverAs steer/followUp) are
|
|
445
|
+
// registered in the copy arrays under their contentText text and delivered
|
|
446
|
+
// with role "custom", so they must go through the same copy-removal path
|
|
447
|
+
// (D-078 fix).
|
|
448
|
+
if (event.type === "message_start" && (event.message.role === "user" || event.message.role === "custom")) {
|
|
449
|
+
if (event.message.role === "user") {
|
|
450
|
+
this._overflowRecoveryAttempted = false;
|
|
451
|
+
this._overflowTrimStage = 0;
|
|
452
|
+
}
|
|
453
|
+
// Custom queue entries register their copy text via _queuedCopyText
|
|
454
|
+
// (placeholder for textless content); match removal with the same
|
|
455
|
+
// expression so both sides stay symmetric.
|
|
456
|
+
const messageText = event.message.role === "custom"
|
|
457
|
+
? this._queuedCopyText(event.message.content)
|
|
458
|
+
: contentText(event.message.content, "");
|
|
455
459
|
if (messageText) {
|
|
456
460
|
// Check steering queue first
|
|
457
461
|
const steeringIndex = this._steeringMessages.indexOf(messageText);
|
|
@@ -514,11 +518,6 @@ export class AgentSession {
|
|
|
514
518
|
this._overflowRecoveryAttempted = false;
|
|
515
519
|
this._overflowTrimStage = 0;
|
|
516
520
|
}
|
|
517
|
-
// microcompact 冷却按模型请求计数:每个完成的 assistant 响应(无论
|
|
518
|
-
// stopReason)释放一档,下限 0;冷却期内的阈值 decide 不做便宜缓解。
|
|
519
|
-
if (this._microcompactCooldown > 0) {
|
|
520
|
-
this._microcompactCooldown -= 1;
|
|
521
|
-
}
|
|
522
521
|
// Reset retry counter immediately on successful assistant response
|
|
523
522
|
// This prevents accumulation across multiple LLM calls within a turn
|
|
524
523
|
if (assistantMsg.stopReason !== "error" && this._retryAttempt > 0) {
|
|
@@ -738,7 +737,7 @@ export class AgentSession {
|
|
|
738
737
|
/** Public capability runtime for external orchestration and plugin composition. */
|
|
739
738
|
getCapabilityRuntime() {
|
|
740
739
|
if (!this._capabilityRuntime)
|
|
741
|
-
throw new Error("Capability runtime is not available");
|
|
740
|
+
throw new Error(t("Capability runtime is not available"));
|
|
742
741
|
return this._capabilityRuntime;
|
|
743
742
|
}
|
|
744
743
|
/**
|
|
@@ -774,18 +773,21 @@ export class AgentSession {
|
|
|
774
773
|
commitContext: async (request) => {
|
|
775
774
|
const commit = this._contextCommitQueue.then(async () => {
|
|
776
775
|
if (request.signal?.aborted)
|
|
777
|
-
throw new Error("Context commit cancelled");
|
|
776
|
+
throw new Error(t("Context commit cancelled"));
|
|
778
777
|
const currentRevision = this._contextRevision;
|
|
779
778
|
if (request.operationId.trim() === "")
|
|
780
|
-
throw new Error("Context commit operationId is required");
|
|
779
|
+
throw new Error(t("Context commit operationId is required"));
|
|
781
780
|
if (request.expectedRevision !== currentRevision) {
|
|
782
|
-
throw new Error(
|
|
781
|
+
throw new Error(t("Context revision conflict: expected {expected}, current {current}", {
|
|
782
|
+
expected: request.expectedRevision,
|
|
783
|
+
current: currentRevision,
|
|
784
|
+
}));
|
|
783
785
|
}
|
|
784
786
|
if (!Array.isArray(request.value))
|
|
785
|
-
throw new Error("Session context commit requires a message array");
|
|
787
|
+
throw new Error(t("Session context commit requires a message array"));
|
|
786
788
|
await this.replaceContext(request.value);
|
|
787
789
|
if (request.signal?.aborted)
|
|
788
|
-
throw new Error("Context commit cancelled");
|
|
790
|
+
throw new Error(t("Context commit cancelled"));
|
|
789
791
|
return {
|
|
790
792
|
version: 1,
|
|
791
793
|
status: "committed",
|
|
@@ -868,7 +870,7 @@ export class AgentSession {
|
|
|
868
870
|
}))),
|
|
869
871
|
exportArtifact: (request) => {
|
|
870
872
|
if (request.format !== "jsonl")
|
|
871
|
-
throw new Error(
|
|
873
|
+
throw new Error(t("Unsupported session export format: {format}", { format: request.format }));
|
|
872
874
|
return createSessionJsonlArtifact(this.sessionManager);
|
|
873
875
|
},
|
|
874
876
|
};
|
|
@@ -1007,6 +1009,11 @@ export class AgentSession {
|
|
|
1007
1009
|
.filter((tool) => this._capabilityMode !== "readonly" ||
|
|
1008
1010
|
(!tool.source.startsWith("agent-forge.builtin.") && !tool.source.startsWith("agent-forge.plugin.")) ||
|
|
1009
1011
|
tool.readonlySafe === true)
|
|
1012
|
+
// Deferred plugin tools register but stay out of the active set on
|
|
1013
|
+
// this explicit-activation path too, until tool_search or
|
|
1014
|
+
// setActiveTools names them (same contract as the default path in
|
|
1015
|
+
// agent-session-tools.ts).
|
|
1016
|
+
.filter((tool) => !this._deferredToolPluginIds.has(tool.source))
|
|
1010
1017
|
.map((tool) => tool.name)
|
|
1011
1018
|
.filter((name) => !previousToolNames.has(name));
|
|
1012
1019
|
this._refreshToolRegistry({
|
|
@@ -1019,10 +1026,10 @@ export class AgentSession {
|
|
|
1019
1026
|
const runtime = this._capabilityRuntime;
|
|
1020
1027
|
// v8 ignore next -- capability runtime 恒由 _buildRuntime 创建,dispose 后不再调用,运行期恒存在
|
|
1021
1028
|
if (!runtime)
|
|
1022
|
-
throw new Error("Capability runtime is not available");
|
|
1029
|
+
throw new Error(t("Capability runtime is not available"));
|
|
1023
1030
|
const resolvedManifestPath = resolve(this._cwd, manifestPath);
|
|
1024
1031
|
if (this._capabilityPlugins.has(resolvedManifestPath)) {
|
|
1025
|
-
throw new Error(
|
|
1032
|
+
throw new Error(t("Capability plugin manifest is already loaded: {path}", { path: resolvedManifestPath }));
|
|
1026
1033
|
}
|
|
1027
1034
|
const previousToolNames = new Set(runtime.listTools().map((tool) => tool.name));
|
|
1028
1035
|
const loaded = await loadCapabilityPluginFromManifest(runtime, resolvedManifestPath, options);
|
|
@@ -1037,10 +1044,10 @@ export class AgentSession {
|
|
|
1037
1044
|
const runtime = this._capabilityRuntime;
|
|
1038
1045
|
// v8 ignore next -- capability runtime 恒由 _buildRuntime 创建,dispose 后不再调用,运行期恒存在
|
|
1039
1046
|
if (!runtime)
|
|
1040
|
-
throw new Error("Capability runtime is not available");
|
|
1047
|
+
throw new Error(t("Capability runtime is not available"));
|
|
1041
1048
|
const key = `inline:${manifest.id}`;
|
|
1042
1049
|
if (this._capabilityPlugins.has(key)) {
|
|
1043
|
-
throw new Error(
|
|
1050
|
+
throw new Error(t("Capability plugin is already loaded in this session: {id}", { id: manifest.id }));
|
|
1044
1051
|
}
|
|
1045
1052
|
const previousToolNames = new Set(runtime.listTools().map((tool) => tool.name));
|
|
1046
1053
|
const loaded = await loadCapabilityPluginRuntime(runtime, manifest, factory);
|
|
@@ -1166,7 +1173,9 @@ export class AgentSession {
|
|
|
1166
1173
|
textLength: currentText.length,
|
|
1167
1174
|
reason,
|
|
1168
1175
|
});
|
|
1169
|
-
throw new Error(reason === undefined
|
|
1176
|
+
throw new Error(reason === undefined
|
|
1177
|
+
? t("Input rejected by an input gate")
|
|
1178
|
+
: t("Input rejected by an input gate: {reason}", { reason }));
|
|
1170
1179
|
}
|
|
1171
1180
|
if ("text" in result && typeof result.text === "string") {
|
|
1172
1181
|
currentText = result.text;
|
|
@@ -1188,7 +1197,7 @@ export class AgentSession {
|
|
|
1188
1197
|
*/
|
|
1189
1198
|
async prompt(text, options) {
|
|
1190
1199
|
if (this._reloadInProgress) {
|
|
1191
|
-
throw new Error("Session reload in progress; prompts are unavailable");
|
|
1200
|
+
throw new Error(t("Session reload in progress; prompts are unavailable"));
|
|
1192
1201
|
}
|
|
1193
1202
|
const expandPromptTemplates = options?.expandPromptTemplates ?? true;
|
|
1194
1203
|
const preflightResult = options?.preflightResult;
|
|
@@ -1203,7 +1212,7 @@ export class AgentSession {
|
|
|
1203
1212
|
}
|
|
1204
1213
|
}
|
|
1205
1214
|
if (this._compactionAbortController !== undefined) {
|
|
1206
|
-
throw new Error("Cannot submit a prompt while compaction is in progress. Wait for compaction to finish and retry.");
|
|
1215
|
+
throw new Error(t("Cannot submit a prompt while compaction is in progress. Wait for compaction to finish and retry."));
|
|
1207
1216
|
}
|
|
1208
1217
|
// Dispatch the input.gate chain, then the input.received facts (both
|
|
1209
1218
|
// before skill/template expansion)
|
|
@@ -1217,7 +1226,7 @@ export class AgentSession {
|
|
|
1217
1226
|
// If streaming, queue via steer() or followUp() based on option
|
|
1218
1227
|
if (this.isStreaming) {
|
|
1219
1228
|
if (!options?.streamingBehavior) {
|
|
1220
|
-
throw new Error("Agent is already processing. Specify streamingBehavior ('steer' or 'followUp') to queue the message.");
|
|
1229
|
+
throw new Error(t("Agent is already processing. Specify streamingBehavior ('steer' or 'followUp') to queue the message."));
|
|
1221
1230
|
}
|
|
1222
1231
|
if (options.streamingBehavior === "followUp") {
|
|
1223
1232
|
await this._queueFollowUp(expandedText, currentImages);
|
|
@@ -1241,9 +1250,7 @@ export class AgentSession {
|
|
|
1241
1250
|
if (!hasConfiguredAuth) {
|
|
1242
1251
|
const isOAuth = this._modelRuntime.isUsingOAuth(this.model.provider);
|
|
1243
1252
|
if (isOAuth) {
|
|
1244
|
-
throw new Error(
|
|
1245
|
-
`Credentials may have expired or network is unavailable. ` +
|
|
1246
|
-
`Run '/login ${this.model.provider}' to re-authenticate.`);
|
|
1253
|
+
throw new Error(t("Authentication failed for \"{provider}\". Credentials may have expired or network is unavailable. Run '/login {provider}' to re-authenticate.", { provider: this.model.provider }));
|
|
1247
1254
|
}
|
|
1248
1255
|
throw new Error(formatNoApiKeyFoundMessage(this.model.provider));
|
|
1249
1256
|
}
|
|
@@ -1306,7 +1313,10 @@ export class AgentSession {
|
|
|
1306
1313
|
const skillConflict = skillName !== undefined && this._getAvailableSkills().some((skill) => skill.name === skillName);
|
|
1307
1314
|
if (templateConflict || skillConflict) {
|
|
1308
1315
|
const source = templateConflict ? "prompt template" : "skill";
|
|
1309
|
-
throw new Error(
|
|
1316
|
+
throw new Error(t("Command is registered by both CapabilityAPI and {source}: {command}", {
|
|
1317
|
+
source,
|
|
1318
|
+
command: commandName,
|
|
1319
|
+
}));
|
|
1310
1320
|
}
|
|
1311
1321
|
}
|
|
1312
1322
|
else {
|
|
@@ -1445,9 +1455,15 @@ export class AgentSession {
|
|
|
1445
1455
|
* Send a custom message to the session. Creates a CustomMessageEntry.
|
|
1446
1456
|
*
|
|
1447
1457
|
* Handles four cases:
|
|
1448
|
-
* - Streaming: queues message
|
|
1458
|
+
* - Streaming: queues message (registered in the queued-message view via its
|
|
1459
|
+
* text content), processed when loop pulls from queue
|
|
1449
1460
|
* - Streaming + triggerTurn false: appended to state/session once the current turn ends
|
|
1450
|
-
* - Not streaming + triggerTurn: appends to state/session, starts new turn
|
|
1461
|
+
* - Not streaming + triggerTurn: appends to state/session, starts new turn —
|
|
1462
|
+
* unless manual compaction is in flight (same guard as prompt()), in which
|
|
1463
|
+
* case the message degrades to a followUp queue entry instead of a
|
|
1464
|
+
* concurrent turn (D-060 ruling 12 boundary: the compaction revision
|
|
1465
|
+
* mutex must not be pierced; the queued message is drained at the next
|
|
1466
|
+
* driving point after compaction ends)
|
|
1451
1467
|
* - Not streaming + no trigger: appends to state/session, no turn
|
|
1452
1468
|
*
|
|
1453
1469
|
* @param message Custom message with customType, content, display, details
|
|
@@ -1468,15 +1484,34 @@ export class AgentSession {
|
|
|
1468
1484
|
this._pendingNextTurnMessages.push(appMessage);
|
|
1469
1485
|
}
|
|
1470
1486
|
else if (this.isStreaming && options?.triggerTurn !== false) {
|
|
1487
|
+
// Register the queued text in the session's queued-message view so the
|
|
1488
|
+
// display copy and the agent queue stay isomorphic (D-078 fix). See
|
|
1489
|
+
// _queuedCopyText for the placeholder rationale.
|
|
1490
|
+
const queuedText = this._queuedCopyText(appMessage.content);
|
|
1471
1491
|
if (options?.deliverAs === "followUp") {
|
|
1492
|
+
this._followUpMessages.push(queuedText);
|
|
1472
1493
|
this.agent.followUp(appMessage);
|
|
1473
1494
|
}
|
|
1474
1495
|
else {
|
|
1496
|
+
this._steeringMessages.push(queuedText);
|
|
1475
1497
|
this.agent.steer(appMessage);
|
|
1476
1498
|
}
|
|
1499
|
+
this._emitQueueUpdate();
|
|
1477
1500
|
}
|
|
1478
1501
|
else if (options?.triggerTurn) {
|
|
1479
|
-
|
|
1502
|
+
if (this._compactionAbortController !== undefined) {
|
|
1503
|
+
// 压缩互斥窗口(D-060 裁决 12 边界,复审 C-1):手动压缩进行中(与
|
|
1504
|
+
// prompt() 同判据同字段)时不起并发回合——压缩提交按 revision 互斥,
|
|
1505
|
+
// 并发验收回合会以 revision conflict 打断用户压缩。回注降级为
|
|
1506
|
+
// followUp 入队:消息不丢(队列可见),压缩结束后的下一驱动点(用户
|
|
1507
|
+
// 下一交互或下一结算回注)drain 注入。
|
|
1508
|
+
this._followUpMessages.push(this._queuedCopyText(appMessage.content));
|
|
1509
|
+
this.agent.followUp(appMessage);
|
|
1510
|
+
this._emitQueueUpdate();
|
|
1511
|
+
}
|
|
1512
|
+
else {
|
|
1513
|
+
await this._runAgentPrompt(appMessage);
|
|
1514
|
+
}
|
|
1480
1515
|
}
|
|
1481
1516
|
else if (this.isStreaming) {
|
|
1482
1517
|
// Appending now would put the message between an assistant tool call and its
|
|
@@ -1489,6 +1524,20 @@ export class AgentSession {
|
|
|
1489
1524
|
this._appendCustomMessage(appMessage);
|
|
1490
1525
|
}
|
|
1491
1526
|
}
|
|
1527
|
+
/**
|
|
1528
|
+
* Copy text registered in the queued-message view for a queued custom
|
|
1529
|
+
* message. The copy holds the message's text content; CustomMessage.display
|
|
1530
|
+
* is a boolean visibility flag, not display text. Content without text
|
|
1531
|
+
* (e.g. images only) registers a placeholder: an empty copy entry would
|
|
1532
|
+
* never be matched for removal on delivery (the drain-side guard skips
|
|
1533
|
+
* empty text) and would desynchronize both layers (D-078). The placeholder
|
|
1534
|
+
* is a stable literal, deliberately not localized — both registration and
|
|
1535
|
+
* removal must derive the same string, even if the UI language changes
|
|
1536
|
+
* between the two calls.
|
|
1537
|
+
*/
|
|
1538
|
+
_queuedCopyText(content) {
|
|
1539
|
+
return contentText(content, "") || "(no text)";
|
|
1540
|
+
}
|
|
1492
1541
|
_appendCustomMessage(appMessage) {
|
|
1493
1542
|
this.agent.state.messages.push(appMessage);
|
|
1494
1543
|
this.sessionManager.appendCustomMessageEntry(appMessage.customType, appMessage.content, appMessage.display, appMessage.details);
|
|
@@ -1559,6 +1608,55 @@ export class AgentSession {
|
|
|
1559
1608
|
this._emitQueueUpdate();
|
|
1560
1609
|
return { steering, followUp };
|
|
1561
1610
|
}
|
|
1611
|
+
/**
|
|
1612
|
+
* Move a queued message from index `from` to index `to` within the steering
|
|
1613
|
+
* or follow-up queue. Indices refer to the session's queued-message view
|
|
1614
|
+
* (getSteeringMessages()/getFollowUpMessages() and queue_update payloads)
|
|
1615
|
+
* at the moment of the call; the same move is applied to the agent queue.
|
|
1616
|
+
* During streaming, drain points consume queued messages, so previously
|
|
1617
|
+
* observed indices can become stale.
|
|
1618
|
+
* @returns true when the message moved; false for from === to, out-of-bounds
|
|
1619
|
+
* indices, or an agent-side rejection — both layers stay untouched in every
|
|
1620
|
+
* false case
|
|
1621
|
+
*/
|
|
1622
|
+
reorderQueuedMessages(queue, from, to) {
|
|
1623
|
+
const copy = queue === "steer" ? this._steeringMessages : this._followUpMessages;
|
|
1624
|
+
if (from === to || from < 0 || to < 0 || from >= copy.length || to >= copy.length) {
|
|
1625
|
+
return false;
|
|
1626
|
+
}
|
|
1627
|
+
// Apply the move on the agent queue first and mirror it on the session copy
|
|
1628
|
+
// only after the agent accepts it. A rejected move (stale index) leaves
|
|
1629
|
+
// both layers untouched instead of widening a copy/queue mismatch.
|
|
1630
|
+
if (!this.agent.reorderQueuedMessages(queue, from, to)) {
|
|
1631
|
+
return false;
|
|
1632
|
+
}
|
|
1633
|
+
const [moved] = copy.splice(from, 1);
|
|
1634
|
+
copy.splice(to, 0, moved);
|
|
1635
|
+
this._emitQueueUpdate();
|
|
1636
|
+
return true;
|
|
1637
|
+
}
|
|
1638
|
+
/**
|
|
1639
|
+
* Remove the queued message at `index` from the steering or follow-up queue.
|
|
1640
|
+
* Indices refer to the session's queued-message view at the moment of the
|
|
1641
|
+
* call; the same removal is applied to the agent queue.
|
|
1642
|
+
* @returns The removed queued text, or null when index is out of bounds or the
|
|
1643
|
+
* agent-side removal is rejected — both layers stay untouched in every null case
|
|
1644
|
+
*/
|
|
1645
|
+
removeQueuedMessageAt(queue, index) {
|
|
1646
|
+
const copy = queue === "steer" ? this._steeringMessages : this._followUpMessages;
|
|
1647
|
+
if (index < 0 || index >= copy.length) {
|
|
1648
|
+
return null;
|
|
1649
|
+
}
|
|
1650
|
+
// Remove on the agent queue first and mirror it on the session copy only
|
|
1651
|
+
// after the agent accepts it. A rejected removal (stale index) leaves both
|
|
1652
|
+
// layers untouched instead of widening a copy/queue mismatch.
|
|
1653
|
+
if (this.agent.removeQueuedMessage(queue, index) === null) {
|
|
1654
|
+
return null;
|
|
1655
|
+
}
|
|
1656
|
+
const [removed] = copy.splice(index, 1);
|
|
1657
|
+
this._emitQueueUpdate();
|
|
1658
|
+
return removed;
|
|
1659
|
+
}
|
|
1562
1660
|
/** Number of pending messages (includes both steering and follow-up) */
|
|
1563
1661
|
get pendingMessageCount() {
|
|
1564
1662
|
return this._steeringMessages.length + this._followUpMessages.length;
|
|
@@ -1855,7 +1953,7 @@ export class AgentSession {
|
|
|
1855
1953
|
*/
|
|
1856
1954
|
async compact(customInstructions) {
|
|
1857
1955
|
if (this._reloadInProgress) {
|
|
1858
|
-
throw new Error("Session reload in progress; compaction is unavailable");
|
|
1956
|
+
throw new Error(t("Session reload in progress; compaction is unavailable"));
|
|
1859
1957
|
}
|
|
1860
1958
|
return this._enqueueCompaction(() => this._compactInternal(customInstructions));
|
|
1861
1959
|
}
|
|
@@ -1913,16 +2011,6 @@ export class AgentSession {
|
|
|
1913
2011
|
_runAutoCompaction(reason, willRetry) {
|
|
1914
2012
|
return runAutoCompaction(this._internal, reason, willRetry);
|
|
1915
2013
|
}
|
|
1916
|
-
/**
|
|
1917
|
-
* Toggle auto-compaction setting.
|
|
1918
|
-
*/
|
|
1919
|
-
setAutoCompactionEnabled(enabled) {
|
|
1920
|
-
this.settingsManager.setCompactionEnabled(enabled);
|
|
1921
|
-
}
|
|
1922
|
-
/** Whether auto-compaction is enabled */
|
|
1923
|
-
get autoCompactionEnabled() {
|
|
1924
|
-
return this.settingsManager.getCompactionEnabled();
|
|
1925
|
-
}
|
|
1926
2014
|
/**
|
|
1927
2015
|
* Run the session-start boundary: dispatch session.start@1 to the capability
|
|
1928
2016
|
* runtime and run the resource discovery pass (contributed skills/prompts/
|
|
@@ -2098,7 +2186,7 @@ export class AgentSession {
|
|
|
2098
2186
|
invoke: async (input, options) => {
|
|
2099
2187
|
const model = this.agent.state.model;
|
|
2100
2188
|
if (!model)
|
|
2101
|
-
throw new Error("No model is set on this session's agent");
|
|
2189
|
+
throw new Error(t("No model is set on this session's agent"));
|
|
2102
2190
|
const authResult = await this._modelRuntime.getAuth(model, {
|
|
2103
2191
|
...(options?.signal === undefined ? {} : { signal: options.signal }),
|
|
2104
2192
|
});
|
|
@@ -2299,7 +2387,7 @@ export class AgentSession {
|
|
|
2299
2387
|
}
|
|
2300
2388
|
async reload(options) {
|
|
2301
2389
|
if (this._reloadInProgress)
|
|
2302
|
-
throw new Error("Session reload is already in progress");
|
|
2390
|
+
throw new Error(t("Session reload is already in progress"));
|
|
2303
2391
|
this._reloadInProgress = true;
|
|
2304
2392
|
this._beginContextTransitionFence();
|
|
2305
2393
|
this._bashEpoch += 1;
|
|
@@ -2312,7 +2400,7 @@ export class AgentSession {
|
|
|
2312
2400
|
let hasContextSnapshot = false;
|
|
2313
2401
|
if (contextStrategyName) {
|
|
2314
2402
|
if (!oldCapabilityRuntime?.hasContextStrategy(contextStrategyName)) {
|
|
2315
|
-
throw new Error(
|
|
2403
|
+
throw new Error(t("Configured context strategy is not registered: {name}", { name: contextStrategyName }));
|
|
2316
2404
|
}
|
|
2317
2405
|
contextSnapshot = await oldCapabilityRuntime.snapshotContext(contextStrategyName, this._copyContextMessages(this.agent.state.messages, contextStrategyName, "input"), { reason: "reload", sessionId: this.sessionId });
|
|
2318
2406
|
hasContextSnapshot = true;
|
|
@@ -2361,7 +2449,9 @@ export class AgentSession {
|
|
|
2361
2449
|
if (contextStrategyName && hasContextSnapshot) {
|
|
2362
2450
|
const runtime = this._capabilityRuntime;
|
|
2363
2451
|
if (!runtime?.hasContextStrategy(contextStrategyName)) {
|
|
2364
|
-
throw new Error(
|
|
2452
|
+
throw new Error(t("Configured context strategy is not registered after reload: {name}", {
|
|
2453
|
+
name: contextStrategyName,
|
|
2454
|
+
}));
|
|
2365
2455
|
}
|
|
2366
2456
|
await this._restoreContextTransition(contextSnapshot, "reload", { allowReload: true });
|
|
2367
2457
|
}
|
|
@@ -2375,7 +2465,7 @@ export class AgentSession {
|
|
|
2375
2465
|
this._reloadInProgress = false;
|
|
2376
2466
|
}
|
|
2377
2467
|
if (committedGeneration === undefined)
|
|
2378
|
-
throw new Error("Session reload did not commit a generation");
|
|
2468
|
+
throw new Error(t("Session reload did not commit a generation"));
|
|
2379
2469
|
await this._dispatchSessionReloadLifecycle(committedGeneration);
|
|
2380
2470
|
}
|
|
2381
2471
|
// =========================================================================
|
|
@@ -2407,16 +2497,6 @@ export class AgentSession {
|
|
|
2407
2497
|
get isRetrying() {
|
|
2408
2498
|
return this._retryAbortController !== undefined;
|
|
2409
2499
|
}
|
|
2410
|
-
/** Whether auto-retry is enabled */
|
|
2411
|
-
get autoRetryEnabled() {
|
|
2412
|
-
return this.settingsManager.getRetryEnabled();
|
|
2413
|
-
}
|
|
2414
|
-
/**
|
|
2415
|
-
* Toggle auto-retry setting.
|
|
2416
|
-
*/
|
|
2417
|
-
setAutoRetryEnabled(enabled) {
|
|
2418
|
-
this.settingsManager.setRetryEnabled(enabled);
|
|
2419
|
-
}
|
|
2420
2500
|
// =========================================================================
|
|
2421
2501
|
// Bash Execution
|
|
2422
2502
|
// =========================================================================
|