@inhuman.tools/harness 0.1.0 → 0.3.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/compact.prompt +12 -2
- package/dist/builtin-tools/catalog-entry.d.ts.map +1 -1
- package/dist/builtin-tools/catalog-entry.js +1 -0
- package/dist/builtin-tools/catalog-entry.js.map +1 -1
- package/dist/builtin-tools/index.d.ts +1 -2
- package/dist/builtin-tools/index.d.ts.map +1 -1
- package/dist/builtin-tools/index.js +1 -2
- package/dist/builtin-tools/index.js.map +1 -1
- package/dist/builtin-tools/metadata/context-need.d.ts +1 -0
- package/dist/builtin-tools/metadata/context-need.d.ts.map +1 -1
- package/dist/builtin-tools/metadata/context-need.js +13 -6
- package/dist/builtin-tools/metadata/context-need.js.map +1 -1
- package/dist/builtin-tools/metadata/context-recall.d.ts +1 -5
- package/dist/builtin-tools/metadata/context-recall.d.ts.map +1 -1
- package/dist/builtin-tools/metadata/context-recall.js +10 -7
- package/dist/builtin-tools/metadata/context-recall.js.map +1 -1
- package/dist/builtin-tools/metadata/update-metadata.d.ts +1 -0
- package/dist/builtin-tools/metadata/update-metadata.d.ts.map +1 -1
- package/dist/builtin-tools/metadata/update-metadata.js +12 -12
- package/dist/builtin-tools/metadata/update-metadata.js.map +1 -1
- package/dist/builtin-tools/named-agents/agent-catalog.d.ts.map +1 -1
- package/dist/builtin-tools/named-agents/agent-catalog.js +9 -9
- package/dist/builtin-tools/named-agents/agent-catalog.js.map +1 -1
- package/dist/builtin-tools/named-agents/agent-stdlib.d.ts.map +1 -1
- package/dist/builtin-tools/named-agents/agent-stdlib.js +2 -0
- package/dist/builtin-tools/named-agents/agent-stdlib.js.map +1 -1
- package/dist/builtin-tools/schemas/tool-result.d.ts +2 -0
- package/dist/builtin-tools/schemas/tool-result.d.ts.map +1 -1
- package/dist/builtin-tools/schemas/tool-result.js +2 -0
- package/dist/builtin-tools/schemas/tool-result.js.map +1 -1
- package/dist/builtin-tools/shell/job-stop.d.ts +1 -0
- package/dist/builtin-tools/shell/job-stop.d.ts.map +1 -1
- package/dist/builtin-tools/shell/shell-tool.d.ts +1 -0
- package/dist/builtin-tools/shell/shell-tool.d.ts.map +1 -1
- package/dist/builtin-tools/toolkit/dist-tools.d.ts +1 -0
- package/dist/builtin-tools/toolkit/dist-tools.d.ts.map +1 -1
- package/dist/builtin-tools/toolkit/dist-tools.js +1 -0
- package/dist/builtin-tools/toolkit/dist-tools.js.map +1 -1
- package/dist/connections/adopt.d.ts +2 -0
- package/dist/connections/adopt.d.ts.map +1 -1
- package/dist/connections/adopt.js.map +1 -1
- package/dist/connections/index.d.ts +1 -1
- package/dist/connections/index.d.ts.map +1 -1
- package/dist/extensions/adjust-json.js +1 -1
- package/dist/extensions/behavior.d.ts.map +1 -1
- package/dist/extensions/behavior.js +17 -4
- package/dist/extensions/behavior.js.map +1 -1
- package/dist/extensions/consent.d.ts +0 -68
- package/dist/extensions/consent.d.ts.map +1 -1
- package/dist/extensions/consent.js +0 -69
- package/dist/extensions/consent.js.map +1 -1
- package/dist/extensions/contributions.d.ts.map +1 -1
- package/dist/extensions/contributions.js +1 -0
- package/dist/extensions/contributions.js.map +1 -1
- package/dist/extensions/dispatch.d.ts +1 -9
- package/dist/extensions/dispatch.d.ts.map +1 -1
- package/dist/extensions/dispatch.js +5 -7
- package/dist/extensions/dispatch.js.map +1 -1
- package/dist/extensions/eval.d.ts.map +1 -1
- package/dist/extensions/eval.js +2 -0
- package/dist/extensions/eval.js.map +1 -1
- package/dist/extensions/hook-deadline.d.ts +28 -0
- package/dist/extensions/hook-deadline.d.ts.map +1 -0
- package/dist/extensions/hook-deadline.js +72 -0
- package/dist/extensions/hook-deadline.js.map +1 -0
- package/dist/extensions/host.d.ts +2 -0
- package/dist/extensions/host.d.ts.map +1 -1
- package/dist/extensions/host.js +15 -0
- package/dist/extensions/host.js.map +1 -1
- package/dist/extensions/install.js +2 -2
- package/dist/extensions/inventory.d.ts +9 -0
- package/dist/extensions/inventory.d.ts.map +1 -1
- package/dist/extensions/inventory.js +15 -1
- package/dist/extensions/inventory.js.map +1 -1
- package/dist/extensions/notes.d.ts +1 -0
- package/dist/extensions/notes.d.ts.map +1 -1
- package/dist/extensions/notes.js +1 -0
- package/dist/extensions/notes.js.map +1 -1
- package/dist/extensions/schemas/bot-definition.d.ts +1 -1
- package/dist/extensions/schemas/bot-definition.d.ts.map +1 -1
- package/dist/extensions/schemas/plugin-manifest.d.ts +4 -4
- package/dist/extensions/schemas/plugin-manifest.d.ts.map +1 -1
- package/dist/extensions/schemas/plugin-manifest.js +13 -1
- package/dist/extensions/schemas/plugin-manifest.js.map +1 -1
- package/dist/extensions/state.d.ts.map +1 -1
- package/dist/extensions/state.js +5 -0
- package/dist/extensions/state.js.map +1 -1
- package/dist/extensions/value.d.ts +4 -0
- package/dist/extensions/value.d.ts.map +1 -1
- package/dist/extensions/value.js.map +1 -1
- package/dist/protocol/schemas/health.d.ts +1 -3
- package/dist/protocol/schemas/health.d.ts.map +1 -1
- package/dist/protocol/schemas/health.js.map +1 -1
- package/dist/protocol/schemas/identity.d.ts +0 -4
- package/dist/protocol/schemas/identity.d.ts.map +1 -1
- package/dist/protocol/schemas/identity.js.map +1 -1
- package/dist/protocol/schemas/loss.d.ts +0 -2
- package/dist/protocol/schemas/loss.d.ts.map +1 -1
- package/dist/protocol/schemas/loss.js.map +1 -1
- package/dist/protocol/schemas/message.d.ts +0 -1
- package/dist/protocol/schemas/message.d.ts.map +1 -1
- package/dist/protocol/supervision/loss.d.ts +0 -1
- package/dist/protocol/supervision/loss.d.ts.map +1 -1
- package/dist/protocol/supervision/loss.js +0 -3
- package/dist/protocol/supervision/loss.js.map +1 -1
- package/dist/providers/auth/device.d.ts +2 -0
- package/dist/providers/auth/device.d.ts.map +1 -1
- package/dist/providers/auth/device.js +3 -3
- package/dist/providers/auth/device.js.map +1 -1
- package/dist/providers/auth/fetch.d.ts +1 -1
- package/dist/providers/auth/fetch.d.ts.map +1 -1
- package/dist/providers/auth/fetch.js +2 -2
- package/dist/providers/auth/fetch.js.map +1 -1
- package/dist/providers/auth/index.d.ts +2 -2
- package/dist/providers/auth/index.d.ts.map +1 -1
- package/dist/providers/auth/index.js +2 -2
- package/dist/providers/auth/index.js.map +1 -1
- package/dist/providers/auth/loopback.d.ts +0 -2
- package/dist/providers/auth/loopback.d.ts.map +1 -1
- package/dist/providers/auth/loopback.js.map +1 -1
- package/dist/providers/auth/oidc.d.ts +8 -0
- package/dist/providers/auth/oidc.d.ts.map +1 -1
- package/dist/providers/auth/oidc.js +38 -7
- package/dist/providers/auth/oidc.js.map +1 -1
- package/dist/providers/chatgpt/connection.d.ts +1 -0
- package/dist/providers/chatgpt/connection.d.ts.map +1 -1
- package/dist/providers/chatgpt/connection.js +1 -1
- package/dist/providers/chatgpt/connection.js.map +1 -1
- package/dist/providers/grok/connection.d.ts +2 -1
- package/dist/providers/grok/connection.d.ts.map +1 -1
- package/dist/providers/grok/connection.js +1 -1
- package/dist/providers/grok/connection.js.map +1 -1
- package/dist/providers/mcp/fetch.d.ts.map +1 -1
- package/dist/providers/mcp/fetch.js +2 -6
- package/dist/providers/mcp/fetch.js.map +1 -1
- package/dist/providers/nous/driver.d.ts +1 -0
- package/dist/providers/nous/driver.d.ts.map +1 -1
- package/dist/providers/openai-compat/actor.d.ts.map +1 -1
- package/dist/providers/openai-compat/actor.js +167 -39
- package/dist/providers/openai-compat/actor.js.map +1 -1
- package/dist/providers/openai-compat/adopt.d.ts +2 -0
- package/dist/providers/openai-compat/adopt.d.ts.map +1 -1
- package/dist/providers/openai-compat/adopt.js.map +1 -1
- package/dist/providers/openai-compat/connection.d.ts +9 -2
- package/dist/providers/openai-compat/connection.d.ts.map +1 -1
- package/dist/providers/openai-compat/connection.js +35 -27
- package/dist/providers/openai-compat/connection.js.map +1 -1
- package/dist/providers/openai-compat/fetch-types.d.ts.map +1 -1
- package/dist/providers/openai-compat/fetch-types.js +2 -6
- package/dist/providers/openai-compat/fetch-types.js.map +1 -1
- package/dist/providers/openai-compat/index.d.ts +2 -2
- package/dist/providers/openai-compat/index.d.ts.map +1 -1
- package/dist/providers/openai-compat/index.js +2 -2
- package/dist/providers/openai-compat/index.js.map +1 -1
- package/dist/providers/openai-compat/model-capabilities.d.ts +7 -0
- package/dist/providers/openai-compat/model-capabilities.d.ts.map +1 -0
- package/dist/providers/openai-compat/model-capabilities.js +24 -0
- package/dist/providers/openai-compat/model-capabilities.js.map +1 -0
- package/dist/providers/openai-compat/schema.d.ts +1 -1
- package/dist/providers/web/registrations/ids.d.ts +0 -2
- package/dist/providers/web/registrations/ids.d.ts.map +1 -1
- package/dist/providers/web/registrations/ids.js +0 -1
- package/dist/providers/web/registrations/ids.js.map +1 -1
- package/dist/runtime/bot-mcp.d.ts.map +1 -1
- package/dist/runtime/bot-mcp.js +1 -4
- package/dist/runtime/bot-mcp.js.map +1 -1
- package/dist/runtime/intent-recovery.d.ts +3 -20
- package/dist/runtime/intent-recovery.d.ts.map +1 -1
- package/dist/runtime/intent-recovery.js +1 -122
- package/dist/runtime/intent-recovery.js.map +1 -1
- package/dist/server/ask-answer.d.ts.map +1 -1
- package/dist/server/ask-answer.js +3 -3
- package/dist/server/ask-answer.js.map +1 -1
- package/dist/server/daemon/kernel/KernelDaemon.d.ts +28 -0
- package/dist/server/daemon/kernel/KernelDaemon.d.ts.map +1 -1
- package/dist/server/daemon/kernel/KernelDaemon.js +160 -39
- package/dist/server/daemon/kernel/KernelDaemon.js.map +1 -1
- package/dist/server/daemon/kernel/completion-catalog.d.ts +8 -0
- package/dist/server/daemon/kernel/completion-catalog.d.ts.map +1 -1
- package/dist/server/daemon/kernel/completion-catalog.js +16 -0
- package/dist/server/daemon/kernel/completion-catalog.js.map +1 -1
- package/dist/server/daemon/kernel/fs-reflection/reflectKernel.d.ts.map +1 -1
- package/dist/server/daemon/kernel/fs-reflection/reflectKernel.js +47 -1
- package/dist/server/daemon/kernel/fs-reflection/reflectKernel.js.map +1 -1
- package/dist/server/daemon/kernel/glance-ask-line.d.ts +1 -6
- package/dist/server/daemon/kernel/glance-ask-line.d.ts.map +1 -1
- package/dist/server/daemon/kernel/glance-ask-line.js +1 -35
- package/dist/server/daemon/kernel/glance-ask-line.js.map +1 -1
- package/dist/server/daemon/kernel/kernel-package.js +1 -1
- package/dist/server/daemon/kernel/remote-access.d.ts +75 -0
- package/dist/server/daemon/kernel/remote-access.d.ts.map +1 -0
- package/dist/server/daemon/kernel/remote-access.js +206 -0
- package/dist/server/daemon/kernel/remote-access.js.map +1 -0
- package/dist/server/daemon/kernel/remote-connector.d.ts +29 -0
- package/dist/server/daemon/kernel/remote-connector.d.ts.map +1 -0
- package/dist/server/daemon/kernel/remote-connector.js +475 -0
- package/dist/server/daemon/kernel/remote-connector.js.map +1 -0
- package/dist/server/daemon/kernel/remote-http.d.ts +19 -0
- package/dist/server/daemon/kernel/remote-http.d.ts.map +1 -0
- package/dist/server/daemon/kernel/remote-http.js +161 -0
- package/dist/server/daemon/kernel/remote-http.js.map +1 -0
- package/dist/server/daemon/kernel/settings-files.d.ts +1 -1
- package/dist/server/daemon/kernel/settings-files.d.ts.map +1 -1
- package/dist/server/daemon/kernel/settings-files.js +3 -6
- package/dist/server/daemon/kernel/settings-files.js.map +1 -1
- package/dist/server/daemon/project/ProjectDaemon.d.ts +4 -0
- package/dist/server/daemon/project/ProjectDaemon.d.ts.map +1 -1
- package/dist/server/daemon/project/ProjectDaemon.js +11 -0
- package/dist/server/daemon/project/ProjectDaemon.js.map +1 -1
- package/dist/server/daemon/server/HarnessDaemon.d.ts.map +1 -1
- package/dist/server/daemon/server/HarnessDaemon.js +8 -2
- package/dist/server/daemon/server/HarnessDaemon.js.map +1 -1
- package/dist/server/daemon/session/SessionDaemon.d.ts +5 -3
- package/dist/server/daemon/session/SessionDaemon.d.ts.map +1 -1
- package/dist/server/daemon/session/SessionDaemon.js +54 -37
- package/dist/server/daemon/session/SessionDaemon.js.map +1 -1
- package/dist/server/daemon/session/SessionOrchestrator.d.ts +1 -0
- package/dist/server/daemon/session/SessionOrchestrator.d.ts.map +1 -1
- package/dist/server/daemon/session/SessionOrchestrator.js +1371 -1146
- package/dist/server/daemon/session/SessionOrchestrator.js.map +1 -1
- package/dist/server/daemon/session/agent-runtime.d.ts +2 -0
- package/dist/server/daemon/session/agent-runtime.d.ts.map +1 -1
- package/dist/server/daemon/session/agent-runtime.js +55 -6
- package/dist/server/daemon/session/agent-runtime.js.map +1 -1
- package/dist/server/daemon/session/ambient-compact.d.ts +3 -21
- package/dist/server/daemon/session/ambient-compact.d.ts.map +1 -1
- package/dist/server/daemon/session/ambient-compact.js +7 -116
- package/dist/server/daemon/session/ambient-compact.js.map +1 -1
- package/dist/server/daemon/session/behavior-host.d.ts +9 -3
- package/dist/server/daemon/session/behavior-host.d.ts.map +1 -1
- package/dist/server/daemon/session/behavior-host.js +222 -47
- package/dist/server/daemon/session/behavior-host.js.map +1 -1
- package/dist/server/daemon/session/compact.d.ts +0 -1
- package/dist/server/daemon/session/compact.d.ts.map +1 -1
- package/dist/server/daemon/session/compact.js +7 -1
- package/dist/server/daemon/session/compact.js.map +1 -1
- package/dist/server/daemon/session/plugin-abi.d.ts.map +1 -1
- package/dist/server/daemon/session/plugin-abi.js +7 -11
- package/dist/server/daemon/session/plugin-abi.js.map +1 -1
- package/dist/server/daemon/session/prompt-message-of.d.ts +1 -8
- package/dist/server/daemon/session/prompt-message-of.d.ts.map +1 -1
- package/dist/server/daemon/session/prompt-message-of.js +2 -12
- package/dist/server/daemon/session/prompt-message-of.js.map +1 -1
- package/dist/server/daemon/session/re-act-loop-intent-detected-trigger.d.ts +3 -42
- package/dist/server/daemon/session/re-act-loop-intent-detected-trigger.d.ts.map +1 -1
- package/dist/server/daemon/session/re-act-loop-intent-detected-trigger.js +4 -145
- package/dist/server/daemon/session/re-act-loop-intent-detected-trigger.js.map +1 -1
- package/dist/server/daemon/session/round-boundary.d.ts +13 -0
- package/dist/server/daemon/session/round-boundary.d.ts.map +1 -0
- package/dist/server/daemon/session/round-boundary.js +196 -0
- package/dist/server/daemon/session/round-boundary.js.map +1 -0
- package/dist/server/daemon/session/round-stop.d.ts +1 -25
- package/dist/server/daemon/session/round-stop.d.ts.map +1 -1
- package/dist/server/daemon/session/round-stop.js +1 -75
- package/dist/server/daemon/session/round-stop.js.map +1 -1
- package/dist/server/daemon/session/turn-iterator.d.ts +1 -44
- package/dist/server/daemon/session/turn-iterator.d.ts.map +1 -1
- package/dist/server/daemon/session/turn-iterator.js +1 -435
- package/dist/server/daemon/session/turn-iterator.js.map +1 -1
- package/dist/server/daemon/session/turn-resolvers.d.ts +1 -16
- package/dist/server/daemon/session/turn-resolvers.d.ts.map +1 -1
- package/dist/server/daemon/session/turn-resolvers.js +1 -28
- package/dist/server/daemon/session/turn-resolvers.js.map +1 -1
- package/dist/server/daemon/session/visual-store.d.ts +2 -2
- package/dist/server/daemon/session/visual-store.d.ts.map +1 -1
- package/dist/server/daemon/session/visual-store.js +19 -20
- package/dist/server/daemon/session/visual-store.js.map +1 -1
- package/dist/server/drivers/request-timeout.d.ts +1 -0
- package/dist/server/drivers/request-timeout.d.ts.map +1 -1
- package/dist/server/drivers/request-timeout.js +2 -1
- package/dist/server/drivers/request-timeout.js.map +1 -1
- package/dist/server/runtime-bin.js +5 -8
- package/dist/server/runtime-bin.js.map +1 -1
- package/dist/server/schemas/index.d.ts +0 -1
- package/dist/server/schemas/index.d.ts.map +1 -1
- package/dist/server/schemas/index.js +0 -1
- package/dist/server/schemas/index.js.map +1 -1
- package/dist/server/schemas/json-record.d.ts +0 -6
- package/dist/server/schemas/json-record.d.ts.map +1 -1
- package/dist/server/schemas/json-record.js +0 -16
- package/dist/server/schemas/json-record.js.map +1 -1
- package/dist/server/schemas/well-known.d.ts +0 -2
- package/dist/server/schemas/well-known.d.ts.map +1 -1
- package/dist/server/schemas/well-known.js +0 -1
- package/dist/server/schemas/well-known.js.map +1 -1
- package/dist/server/testkit/scripted-model.d.ts +11 -0
- package/dist/server/testkit/scripted-model.d.ts.map +1 -1
- package/dist/server/testkit/scripted-model.js +42 -3
- package/dist/server/testkit/scripted-model.js.map +1 -1
- package/dist/server/toolkit/actor.d.ts +0 -1
- package/dist/server/toolkit/actor.d.ts.map +1 -1
- package/dist/server/toolkit/actor.js +2 -5
- package/dist/server/toolkit/actor.js.map +1 -1
- package/dist/server/toolkit/catalog.d.ts +0 -2
- package/dist/server/toolkit/catalog.d.ts.map +1 -1
- package/dist/server/toolkit/catalog.js +0 -81
- package/dist/server/toolkit/catalog.js.map +1 -1
- package/dist/server/toolkit/pack-catalog.d.ts +2 -1
- package/dist/server/toolkit/pack-catalog.d.ts.map +1 -1
- package/dist/server/toolkit/pack-catalog.js +1 -0
- package/dist/server/toolkit/pack-catalog.js.map +1 -1
- package/dist/server/toolkit/tool-entry.d.ts.map +1 -1
- package/dist/server/toolkit/tool-entry.js +1 -0
- package/dist/server/toolkit/tool-entry.js.map +1 -1
- package/dist/server/toolkit/tool-table.d.ts +0 -1
- package/dist/server/toolkit/tool-table.d.ts.map +1 -1
- package/dist/server/toolkit/tool-table.js +0 -3
- package/dist/server/toolkit/tool-table.js.map +1 -1
- package/dist/server/util/read-field.d.ts +0 -2
- package/dist/server/util/read-field.d.ts.map +1 -1
- package/dist/server/util/read-field.js +0 -9
- package/dist/server/util/read-field.js.map +1 -1
- package/dist/server/util/tool-call-json.d.ts +0 -1
- package/dist/server/util/tool-call-json.d.ts.map +1 -1
- package/dist/server/util/tool-call-json.js +0 -25
- package/dist/server/util/tool-call-json.js.map +1 -1
- package/dist/session/index.d.ts +4 -1
- package/dist/session/index.d.ts.map +1 -1
- package/dist/session/index.js +10 -1
- package/dist/session/index.js.map +1 -1
- package/dist/tool-runtime/guard-tool.d.ts +3 -0
- package/dist/tool-runtime/guard-tool.d.ts.map +1 -1
- package/dist/tool-runtime/guard-tool.js +37 -3
- package/dist/tool-runtime/guard-tool.js.map +1 -1
- package/dist/yjs/document-service.d.ts +2 -4
- package/dist/yjs/document-service.d.ts.map +1 -1
- package/dist/yjs/document-service.js +0 -6
- package/dist/yjs/document-service.js.map +1 -1
- package/package.json +44 -43
- package/dist/adjust-json.d.ts +0 -2
- package/dist/adjust-json.d.ts.map +0 -1
- package/dist/adjust-json.js +0 -16
- package/dist/adjust-json.js.map +0 -1
- package/dist/agent-calls/acceptance.d.ts +0 -14
- package/dist/agent-calls/acceptance.d.ts.map +0 -1
- package/dist/agent-calls/acceptance.js +0 -82
- package/dist/agent-calls/acceptance.js.map +0 -1
- package/dist/agent-calls/callbacks.d.ts +0 -14
- package/dist/agent-calls/callbacks.d.ts.map +0 -1
- package/dist/agent-calls/callbacks.js +0 -64
- package/dist/agent-calls/callbacks.js.map +0 -1
- package/dist/agent-calls/delivery.d.ts +0 -13
- package/dist/agent-calls/delivery.d.ts.map +0 -1
- package/dist/agent-calls/delivery.js +0 -62
- package/dist/agent-calls/delivery.js.map +0 -1
- package/dist/agent-calls/index.d.ts +0 -2
- package/dist/agent-calls/index.d.ts.map +0 -1
- package/dist/agent-calls/index.js +0 -2
- package/dist/agent-calls/index.js.map +0 -1
- package/dist/agent-calls/operator.d.ts +0 -22
- package/dist/agent-calls/operator.d.ts.map +0 -1
- package/dist/agent-calls/operator.js +0 -88
- package/dist/agent-calls/operator.js.map +0 -1
- package/dist/agent-calls/runtime.d.ts +0 -38
- package/dist/agent-calls/runtime.d.ts.map +0 -1
- package/dist/agent-calls/runtime.js +0 -251
- package/dist/agent-calls/runtime.js.map +0 -1
- package/dist/agent-calls/types.d.ts +0 -31
- package/dist/agent-calls/types.d.ts.map +0 -1
- package/dist/agent-calls/types.js +0 -2
- package/dist/agent-calls/types.js.map +0 -1
- package/dist/bin.d.ts +0 -6
- package/dist/bin.d.ts.map +0 -1
- package/dist/bin.js +0 -16
- package/dist/bin.js.map +0 -1
- package/dist/builtin-tools/error-with-invariant.d.ts +0 -9
- package/dist/builtin-tools/error-with-invariant.d.ts.map +0 -1
- package/dist/builtin-tools/error-with-invariant.js +0 -12
- package/dist/builtin-tools/error-with-invariant.js.map +0 -1
- package/dist/builtin-tools/schemas/write-gate.d.ts +0 -13
- package/dist/builtin-tools/schemas/write-gate.d.ts.map +0 -1
- package/dist/builtin-tools/schemas/write-gate.js +0 -14
- package/dist/builtin-tools/schemas/write-gate.js.map +0 -1
- package/dist/cli/adjust-json.d.ts +0 -2
- package/dist/cli/adjust-json.d.ts.map +0 -1
- package/dist/cli/adjust-json.js +0 -18
- package/dist/cli/adjust-json.js.map +0 -1
- package/dist/cli/completion-command.d.ts +0 -15
- package/dist/cli/completion-command.d.ts.map +0 -1
- package/dist/cli/completion-command.js +0 -201
- package/dist/cli/completion-command.js.map +0 -1
- package/dist/cli/context.d.ts +0 -23
- package/dist/cli/context.d.ts.map +0 -1
- package/dist/cli/context.js +0 -67
- package/dist/cli/context.js.map +0 -1
- package/dist/cli/continue-pick.d.ts +0 -17
- package/dist/cli/continue-pick.d.ts.map +0 -1
- package/dist/cli/continue-pick.js +0 -20
- package/dist/cli/continue-pick.js.map +0 -1
- package/dist/cli/daemon.d.ts +0 -22
- package/dist/cli/daemon.d.ts.map +0 -1
- package/dist/cli/daemon.js +0 -61
- package/dist/cli/daemon.js.map +0 -1
- package/dist/cli/eval-command.d.ts +0 -16
- package/dist/cli/eval-command.d.ts.map +0 -1
- package/dist/cli/eval-command.js +0 -114
- package/dist/cli/eval-command.js.map +0 -1
- package/dist/cli/install-command.d.ts +0 -8
- package/dist/cli/install-command.d.ts.map +0 -1
- package/dist/cli/install-command.js +0 -25
- package/dist/cli/install-command.js.map +0 -1
- package/dist/cli/install.d.ts +0 -22
- package/dist/cli/install.d.ts.map +0 -1
- package/dist/cli/install.js +0 -143
- package/dist/cli/install.js.map +0 -1
- package/dist/cli/kernel-client.d.ts +0 -3
- package/dist/cli/kernel-client.d.ts.map +0 -1
- package/dist/cli/kernel-client.js +0 -12
- package/dist/cli/kernel-client.js.map +0 -1
- package/dist/cli/mcp-commands.d.ts +0 -61
- package/dist/cli/mcp-commands.d.ts.map +0 -1
- package/dist/cli/mcp-commands.js +0 -139
- package/dist/cli/mcp-commands.js.map +0 -1
- package/dist/cli/mcp.d.ts +0 -25
- package/dist/cli/mcp.d.ts.map +0 -1
- package/dist/cli/mcp.js +0 -261
- package/dist/cli/mcp.js.map +0 -1
- package/dist/cli/model-flags.d.ts +0 -44
- package/dist/cli/model-flags.d.ts.map +0 -1
- package/dist/cli/model-flags.js +0 -216
- package/dist/cli/model-flags.js.map +0 -1
- package/dist/cli/register.d.ts +0 -12
- package/dist/cli/register.d.ts.map +0 -1
- package/dist/cli/register.js +0 -103
- package/dist/cli/register.js.map +0 -1
- package/dist/cli/resume-complete.d.ts +0 -24
- package/dist/cli/resume-complete.d.ts.map +0 -1
- package/dist/cli/resume-complete.js +0 -35
- package/dist/cli/resume-complete.js.map +0 -1
- package/dist/cli/term-continue.d.ts +0 -13
- package/dist/cli/term-continue.d.ts.map +0 -1
- package/dist/cli/term-continue.js +0 -17
- package/dist/cli/term-continue.js.map +0 -1
- package/dist/cli/term-session-key.d.ts +0 -8
- package/dist/cli/term-session-key.d.ts.map +0 -1
- package/dist/cli/term-session-key.js +0 -76
- package/dist/cli/term-session-key.js.map +0 -1
- package/dist/cli/tui-command.d.ts +0 -11
- package/dist/cli/tui-command.d.ts.map +0 -1
- package/dist/cli/tui-command.js +0 -38
- package/dist/cli/tui-command.js.map +0 -1
- package/dist/cli/tui.d.ts +0 -17
- package/dist/cli/tui.d.ts.map +0 -1
- package/dist/cli/tui.js +0 -207
- package/dist/cli/tui.js.map +0 -1
- package/dist/cli/web-command.d.ts +0 -8
- package/dist/cli/web-command.d.ts.map +0 -1
- package/dist/cli/web-command.js +0 -151
- package/dist/cli/web-command.js.map +0 -1
- package/dist/client.d.ts +0 -34
- package/dist/client.d.ts.map +0 -1
- package/dist/client.js +0 -235
- package/dist/client.js.map +0 -1
- package/dist/context/compact-floors.d.ts +0 -21
- package/dist/context/compact-floors.d.ts.map +0 -1
- package/dist/context/compact-floors.js +0 -23
- package/dist/context/compact-floors.js.map +0 -1
- package/dist/context/compact.d.ts +0 -42
- package/dist/context/compact.d.ts.map +0 -1
- package/dist/context/compact.js +0 -156
- package/dist/context/compact.js.map +0 -1
- package/dist/context/delivery.d.ts +0 -13
- package/dist/context/delivery.d.ts.map +0 -1
- package/dist/context/delivery.js +0 -6
- package/dist/context/delivery.js.map +0 -1
- package/dist/context/history.d.ts +0 -30
- package/dist/context/history.d.ts.map +0 -1
- package/dist/context/history.js +0 -225
- package/dist/context/history.js.map +0 -1
- package/dist/context/observations.d.ts +0 -7
- package/dist/context/observations.d.ts.map +0 -1
- package/dist/context/observations.js +0 -11
- package/dist/context/observations.js.map +0 -1
- package/dist/context/squeeze.d.ts +0 -32
- package/dist/context/squeeze.d.ts.map +0 -1
- package/dist/context/squeeze.js +0 -161
- package/dist/context/squeeze.js.map +0 -1
- package/dist/context/tools.d.ts +0 -16
- package/dist/context/tools.d.ts.map +0 -1
- package/dist/context/tools.js +0 -68
- package/dist/context/tools.js.map +0 -1
- package/dist/context/transcript.d.ts +0 -147
- package/dist/context/transcript.d.ts.map +0 -1
- package/dist/context/transcript.js +0 -667
- package/dist/context/transcript.js.map +0 -1
- package/dist/contract.d.ts +0 -87
- package/dist/contract.d.ts.map +0 -1
- package/dist/contract.js +0 -254
- package/dist/contract.js.map +0 -1
- package/dist/daemon/Runner.d.ts +0 -18
- package/dist/daemon/Runner.d.ts.map +0 -1
- package/dist/daemon/Runner.js +0 -29
- package/dist/daemon/Runner.js.map +0 -1
- package/dist/daemon/kernel/KernelDaemon.d.ts +0 -88
- package/dist/daemon/kernel/KernelDaemon.d.ts.map +0 -1
- package/dist/daemon/kernel/KernelDaemon.js +0 -351
- package/dist/daemon/kernel/KernelDaemon.js.map +0 -1
- package/dist/daemon/kernel/catalog.d.ts +0 -24
- package/dist/daemon/kernel/catalog.d.ts.map +0 -1
- package/dist/daemon/kernel/catalog.js +0 -176
- package/dist/daemon/kernel/catalog.js.map +0 -1
- package/dist/daemon/kernel/connection-rpc.d.ts +0 -135
- package/dist/daemon/kernel/connection-rpc.d.ts.map +0 -1
- package/dist/daemon/kernel/connection-rpc.js +0 -180
- package/dist/daemon/kernel/connection-rpc.js.map +0 -1
- package/dist/daemon/kernel/defaults.d.ts +0 -19
- package/dist/daemon/kernel/defaults.d.ts.map +0 -1
- package/dist/daemon/kernel/defaults.js +0 -65
- package/dist/daemon/kernel/defaults.js.map +0 -1
- package/dist/daemon/kernel/fs-reflection/KernelReflector.d.ts +0 -10
- package/dist/daemon/kernel/fs-reflection/KernelReflector.d.ts.map +0 -1
- package/dist/daemon/kernel/fs-reflection/KernelReflector.js +0 -36
- package/dist/daemon/kernel/fs-reflection/KernelReflector.js.map +0 -1
- package/dist/daemon/kernel/fs-reflection/WatchPaths.d.ts +0 -3
- package/dist/daemon/kernel/fs-reflection/WatchPaths.d.ts.map +0 -1
- package/dist/daemon/kernel/fs-reflection/WatchPaths.js +0 -37
- package/dist/daemon/kernel/fs-reflection/WatchPaths.js.map +0 -1
- package/dist/daemon/kernel/fs-reflection/reflectKernel.d.ts +0 -3
- package/dist/daemon/kernel/fs-reflection/reflectKernel.d.ts.map +0 -1
- package/dist/daemon/kernel/fs-reflection/reflectKernel.js +0 -155
- package/dist/daemon/kernel/fs-reflection/reflectKernel.js.map +0 -1
- package/dist/daemon/kernel/plugin-graph.d.ts +0 -18
- package/dist/daemon/kernel/plugin-graph.d.ts.map +0 -1
- package/dist/daemon/kernel/plugin-graph.js +0 -131
- package/dist/daemon/kernel/plugin-graph.js.map +0 -1
- package/dist/daemon/kernel/secrets.d.ts +0 -6
- package/dist/daemon/kernel/secrets.d.ts.map +0 -1
- package/dist/daemon/kernel/secrets.js +0 -76
- package/dist/daemon/kernel/secrets.js.map +0 -1
- package/dist/daemon/kernel/seed.d.ts +0 -2
- package/dist/daemon/kernel/seed.d.ts.map +0 -1
- package/dist/daemon/kernel/seed.js +0 -32
- package/dist/daemon/kernel/seed.js.map +0 -1
- package/dist/daemon/project/ProjectDaemon.d.ts +0 -22
- package/dist/daemon/project/ProjectDaemon.d.ts.map +0 -1
- package/dist/daemon/project/ProjectDaemon.js +0 -114
- package/dist/daemon/project/ProjectDaemon.js.map +0 -1
- package/dist/daemon/project/ProjectPlexus.d.ts +0 -9
- package/dist/daemon/project/ProjectPlexus.d.ts.map +0 -1
- package/dist/daemon/project/ProjectPlexus.js +0 -17
- package/dist/daemon/project/ProjectPlexus.js.map +0 -1
- package/dist/daemon/project/ToolCallHandler.d.ts +0 -26
- package/dist/daemon/project/ToolCallHandler.d.ts.map +0 -1
- package/dist/daemon/project/ToolCallHandler.js +0 -28
- package/dist/daemon/project/ToolCallHandler.js.map +0 -1
- package/dist/daemon/server/HTTPServer.d.ts +0 -15
- package/dist/daemon/server/HTTPServer.d.ts.map +0 -1
- package/dist/daemon/server/HTTPServer.js +0 -129
- package/dist/daemon/server/HTTPServer.js.map +0 -1
- package/dist/daemon/server/HarnessDaemon.d.ts +0 -15
- package/dist/daemon/server/HarnessDaemon.d.ts.map +0 -1
- package/dist/daemon/server/HarnessDaemon.js +0 -97
- package/dist/daemon/server/HarnessDaemon.js.map +0 -1
- package/dist/daemon/session/MindRunner.d.ts +0 -26
- package/dist/daemon/session/MindRunner.d.ts.map +0 -1
- package/dist/daemon/session/MindRunner.js +0 -173
- package/dist/daemon/session/MindRunner.js.map +0 -1
- package/dist/daemon/session/SessionDaemon.d.ts +0 -62
- package/dist/daemon/session/SessionDaemon.d.ts.map +0 -1
- package/dist/daemon/session/SessionDaemon.js +0 -257
- package/dist/daemon/session/SessionDaemon.js.map +0 -1
- package/dist/daemon/session/SessionOrchestrator.d.ts +0 -35
- package/dist/daemon/session/SessionOrchestrator.d.ts.map +0 -1
- package/dist/daemon/session/SessionOrchestrator.js +0 -203
- package/dist/daemon/session/SessionOrchestrator.js.map +0 -1
- package/dist/daemon/session/TurnRunner.d.ts +0 -17
- package/dist/daemon/session/TurnRunner.d.ts.map +0 -1
- package/dist/daemon/session/TurnRunner.js +0 -269
- package/dist/daemon/session/TurnRunner.js.map +0 -1
- package/dist/daemon/session/approval/dist.d.ts +0 -11
- package/dist/daemon/session/approval/dist.d.ts.map +0 -1
- package/dist/daemon/session/approval/dist.js +0 -33
- package/dist/daemon/session/approval/dist.js.map +0 -1
- package/dist/daemon/session/approval/evaluate.d.ts +0 -28
- package/dist/daemon/session/approval/evaluate.d.ts.map +0 -1
- package/dist/daemon/session/approval/evaluate.js +0 -135
- package/dist/daemon/session/approval/evaluate.js.map +0 -1
- package/dist/daemon/session/approval/index.d.ts +0 -7
- package/dist/daemon/session/approval/index.d.ts.map +0 -1
- package/dist/daemon/session/approval/index.js +0 -7
- package/dist/daemon/session/approval/index.js.map +0 -1
- package/dist/daemon/session/approval/judge.d.ts +0 -37
- package/dist/daemon/session/approval/judge.d.ts.map +0 -1
- package/dist/daemon/session/approval/judge.js +0 -86
- package/dist/daemon/session/approval/judge.js.map +0 -1
- package/dist/daemon/session/approval/session.d.ts +0 -50
- package/dist/daemon/session/approval/session.d.ts.map +0 -1
- package/dist/daemon/session/approval/session.js +0 -187
- package/dist/daemon/session/approval/session.js.map +0 -1
- package/dist/daemon/session/approval/votes.d.ts +0 -38
- package/dist/daemon/session/approval/votes.d.ts.map +0 -1
- package/dist/daemon/session/approval/votes.js +0 -64
- package/dist/daemon/session/approval/votes.js.map +0 -1
- package/dist/daemon/session/compact-env.d.ts +0 -60
- package/dist/daemon/session/compact-env.d.ts.map +0 -1
- package/dist/daemon/session/compact-env.js +0 -256
- package/dist/daemon/session/compact-env.js.map +0 -1
- package/dist/daemon/session/compact.d.ts +0 -39
- package/dist/daemon/session/compact.d.ts.map +0 -1
- package/dist/daemon/session/compact.js +0 -152
- package/dist/daemon/session/compact.js.map +0 -1
- package/dist/daemon/session/cutoff.d.ts +0 -280
- package/dist/daemon/session/cutoff.d.ts.map +0 -1
- package/dist/daemon/session/cutoff.js +0 -234
- package/dist/daemon/session/cutoff.js.map +0 -1
- package/dist/daemon/session/transcript.d.ts +0 -100
- package/dist/daemon/session/transcript.d.ts.map +0 -1
- package/dist/daemon/session/transcript.js +0 -425
- package/dist/daemon/session/transcript.js.map +0 -1
- package/dist/daemon/session/turn-interpret.d.ts +0 -13
- package/dist/daemon/session/turn-interpret.d.ts.map +0 -1
- package/dist/daemon/session/turn-interpret.js +0 -259
- package/dist/daemon/session/turn-interpret.js.map +0 -1
- package/dist/daemon/util/fs.d.ts +0 -3
- package/dist/daemon/util/fs.d.ts.map +0 -1
- package/dist/daemon/util/fs.js +0 -18
- package/dist/daemon/util/fs.js.map +0 -1
- package/dist/daemon/util/import-paths.d.ts +0 -4
- package/dist/daemon/util/import-paths.d.ts.map +0 -1
- package/dist/daemon/util/import-paths.js +0 -25
- package/dist/daemon/util/import-paths.js.map +0 -1
- package/dist/daemon/util/slug.d.ts +0 -2
- package/dist/daemon/util/slug.d.ts.map +0 -1
- package/dist/daemon/util/slug.js +0 -9
- package/dist/daemon/util/slug.js.map +0 -1
- package/dist/daemon/well-known/schemas.d.ts +0 -187
- package/dist/daemon/well-known/schemas.d.ts.map +0 -1
- package/dist/daemon/well-known/schemas.js +0 -100
- package/dist/daemon/well-known/schemas.js.map +0 -1
- package/dist/diagnostics/debug-gate.d.ts +0 -5
- package/dist/diagnostics/debug-gate.d.ts.map +0 -1
- package/dist/diagnostics/debug-gate.js +0 -48
- package/dist/diagnostics/debug-gate.js.map +0 -1
- package/dist/diagnostics/index.d.ts +0 -3
- package/dist/diagnostics/index.d.ts.map +0 -1
- package/dist/diagnostics/index.js +0 -3
- package/dist/diagnostics/index.js.map +0 -1
- package/dist/diagnostics/process-log.d.ts +0 -32
- package/dist/diagnostics/process-log.d.ts.map +0 -1
- package/dist/diagnostics/process-log.js +0 -162
- package/dist/diagnostics/process-log.js.map +0 -1
- package/dist/drivers/adopt.d.ts +0 -24
- package/dist/drivers/adopt.d.ts.map +0 -1
- package/dist/drivers/adopt.js +0 -23
- package/dist/drivers/adopt.js.map +0 -1
- package/dist/drivers/builtins.d.ts +0 -17
- package/dist/drivers/builtins.d.ts.map +0 -1
- package/dist/drivers/builtins.js +0 -45
- package/dist/drivers/builtins.js.map +0 -1
- package/dist/drivers/chatgpt-driver.d.ts +0 -41
- package/dist/drivers/chatgpt-driver.d.ts.map +0 -1
- package/dist/drivers/chatgpt-driver.js +0 -56
- package/dist/drivers/chatgpt-driver.js.map +0 -1
- package/dist/drivers/grok-driver.d.ts +0 -32
- package/dist/drivers/grok-driver.d.ts.map +0 -1
- package/dist/drivers/grok-driver.js +0 -48
- package/dist/drivers/grok-driver.js.map +0 -1
- package/dist/drivers/mcp/actor.d.ts +0 -31
- package/dist/drivers/mcp/actor.d.ts.map +0 -1
- package/dist/drivers/mcp/actor.js +0 -112
- package/dist/drivers/mcp/actor.js.map +0 -1
- package/dist/drivers/mcp/adopt.d.ts +0 -21
- package/dist/drivers/mcp/adopt.d.ts.map +0 -1
- package/dist/drivers/mcp/adopt.js +0 -88
- package/dist/drivers/mcp/adopt.js.map +0 -1
- package/dist/drivers/mcp/config.d.ts +0 -32
- package/dist/drivers/mcp/config.d.ts.map +0 -1
- package/dist/drivers/mcp/config.js +0 -50
- package/dist/drivers/mcp/config.js.map +0 -1
- package/dist/drivers/mcp/http-driver.d.ts +0 -23
- package/dist/drivers/mcp/http-driver.d.ts.map +0 -1
- package/dist/drivers/mcp/http-driver.js +0 -147
- package/dist/drivers/mcp/http-driver.js.map +0 -1
- package/dist/drivers/mcp/index.d.ts +0 -8
- package/dist/drivers/mcp/index.d.ts.map +0 -1
- package/dist/drivers/mcp/index.js +0 -8
- package/dist/drivers/mcp/index.js.map +0 -1
- package/dist/drivers/mcp/mcp-connection.d.ts +0 -27
- package/dist/drivers/mcp/mcp-connection.d.ts.map +0 -1
- package/dist/drivers/mcp/mcp-connection.js +0 -90
- package/dist/drivers/mcp/mcp-connection.js.map +0 -1
- package/dist/drivers/mcp/oauth.d.ts +0 -21
- package/dist/drivers/mcp/oauth.d.ts.map +0 -1
- package/dist/drivers/mcp/oauth.js +0 -271
- package/dist/drivers/mcp/oauth.js.map +0 -1
- package/dist/drivers/mcp/stdio-driver.d.ts +0 -22
- package/dist/drivers/mcp/stdio-driver.d.ts.map +0 -1
- package/dist/drivers/mcp/stdio-driver.js +0 -123
- package/dist/drivers/mcp/stdio-driver.js.map +0 -1
- package/dist/drivers/mcp/stdio-env.d.ts +0 -23
- package/dist/drivers/mcp/stdio-env.d.ts.map +0 -1
- package/dist/drivers/mcp/stdio-env.js +0 -82
- package/dist/drivers/mcp/stdio-env.js.map +0 -1
- package/dist/drivers/oidc/oidc-driver.d.ts +0 -28
- package/dist/drivers/oidc/oidc-driver.d.ts.map +0 -1
- package/dist/drivers/oidc/oidc-driver.js +0 -207
- package/dist/drivers/oidc/oidc-driver.js.map +0 -1
- package/dist/drivers/oidc/oidc.d.ts +0 -49
- package/dist/drivers/oidc/oidc.d.ts.map +0 -1
- package/dist/drivers/oidc/oidc.js +0 -200
- package/dist/drivers/oidc/oidc.js.map +0 -1
- package/dist/drivers/openai-compat/account-look.d.ts +0 -5
- package/dist/drivers/openai-compat/account-look.d.ts.map +0 -1
- package/dist/drivers/openai-compat/account-look.js +0 -33
- package/dist/drivers/openai-compat/account-look.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/chutes.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/chutes.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/chutes.js +0 -38
- package/dist/drivers/openai-compat/api-extensions/chutes.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/deepinfra.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/deepinfra.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/deepinfra.js +0 -44
- package/dist/drivers/openai-compat/api-extensions/deepinfra.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/deepseek.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/deepseek.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/deepseek.js +0 -41
- package/dist/drivers/openai-compat/api-extensions/deepseek.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/http.d.ts +0 -9
- package/dist/drivers/openai-compat/api-extensions/http.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/http.js +0 -42
- package/dist/drivers/openai-compat/api-extensions/http.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/index.d.ts +0 -15
- package/dist/drivers/openai-compat/api-extensions/index.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/index.js +0 -14
- package/dist/drivers/openai-compat/api-extensions/index.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/moonshot.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/moonshot.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/moonshot.js +0 -25
- package/dist/drivers/openai-compat/api-extensions/moonshot.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/novita.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/novita.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/novita.js +0 -45
- package/dist/drivers/openai-compat/api-extensions/novita.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/opencode-go.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/opencode-go.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/opencode-go.js +0 -50
- package/dist/drivers/openai-compat/api-extensions/opencode-go.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/openrouter.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/openrouter.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/openrouter.js +0 -65
- package/dist/drivers/openai-compat/api-extensions/openrouter.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/poe.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/poe.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/poe.js +0 -16
- package/dist/drivers/openai-compat/api-extensions/poe.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/siliconflow.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/siliconflow.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/siliconflow.js +0 -46
- package/dist/drivers/openai-compat/api-extensions/siliconflow.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/together.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/together.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/together.js +0 -30
- package/dist/drivers/openai-compat/api-extensions/together.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/types.d.ts +0 -380
- package/dist/drivers/openai-compat/api-extensions/types.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/types.js +0 -188
- package/dist/drivers/openai-compat/api-extensions/types.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/venice.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/venice.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/venice.js +0 -45
- package/dist/drivers/openai-compat/api-extensions/venice.js.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/vercel-ai-gateway.d.ts +0 -3
- package/dist/drivers/openai-compat/api-extensions/vercel-ai-gateway.d.ts.map +0 -1
- package/dist/drivers/openai-compat/api-extensions/vercel-ai-gateway.js +0 -18
- package/dist/drivers/openai-compat/api-extensions/vercel-ai-gateway.js.map +0 -1
- package/dist/drivers/openai-compat/config.d.ts +0 -18
- package/dist/drivers/openai-compat/config.d.ts.map +0 -1
- package/dist/drivers/openai-compat/config.js +0 -51
- package/dist/drivers/openai-compat/config.js.map +0 -1
- package/dist/drivers/openai-compat/index.d.ts +0 -12
- package/dist/drivers/openai-compat/index.d.ts.map +0 -1
- package/dist/drivers/openai-compat/index.js +0 -12
- package/dist/drivers/openai-compat/index.js.map +0 -1
- package/dist/drivers/openai-compat/lineage.d.ts +0 -67
- package/dist/drivers/openai-compat/lineage.d.ts.map +0 -1
- package/dist/drivers/openai-compat/lineage.js +0 -300
- package/dist/drivers/openai-compat/lineage.js.map +0 -1
- package/dist/drivers/openai-compat/model-catalog.d.ts +0 -13
- package/dist/drivers/openai-compat/model-catalog.d.ts.map +0 -1
- package/dist/drivers/openai-compat/model-catalog.js +0 -76
- package/dist/drivers/openai-compat/model-catalog.js.map +0 -1
- package/dist/drivers/openai-compat/openai-compat-driver.d.ts +0 -83
- package/dist/drivers/openai-compat/openai-compat-driver.d.ts.map +0 -1
- package/dist/drivers/openai-compat/openai-compat-driver.js +0 -843
- package/dist/drivers/openai-compat/openai-compat-driver.js.map +0 -1
- package/dist/drivers/openai-compat/presence.d.ts +0 -19
- package/dist/drivers/openai-compat/presence.d.ts.map +0 -1
- package/dist/drivers/openai-compat/presence.js +0 -178
- package/dist/drivers/openai-compat/presence.js.map +0 -1
- package/dist/drivers/openai-compat/well-known.d.ts +0 -16
- package/dist/drivers/openai-compat/well-known.d.ts.map +0 -1
- package/dist/drivers/openai-compat/well-known.js +0 -113
- package/dist/drivers/openai-compat/well-known.js.map +0 -1
- package/dist/drivers/openrouter/index.d.ts +0 -9
- package/dist/drivers/openrouter/index.d.ts.map +0 -1
- package/dist/drivers/openrouter/index.js +0 -9
- package/dist/drivers/openrouter/index.js.map +0 -1
- package/dist/drivers/openrouter/openrouter-auth.d.ts +0 -12
- package/dist/drivers/openrouter/openrouter-auth.d.ts.map +0 -1
- package/dist/drivers/openrouter/openrouter-auth.js +0 -43
- package/dist/drivers/openrouter/openrouter-auth.js.map +0 -1
- package/dist/drivers/openrouter/openrouter-driver.d.ts +0 -17
- package/dist/drivers/openrouter/openrouter-driver.d.ts.map +0 -1
- package/dist/drivers/openrouter/openrouter-driver.js +0 -29
- package/dist/drivers/openrouter/openrouter-driver.js.map +0 -1
- package/dist/drivers/toolkit/actor.d.ts +0 -26
- package/dist/drivers/toolkit/actor.d.ts.map +0 -1
- package/dist/drivers/toolkit/actor.js +0 -149
- package/dist/drivers/toolkit/actor.js.map +0 -1
- package/dist/drivers/toolkit/background.d.ts +0 -30
- package/dist/drivers/toolkit/background.d.ts.map +0 -1
- package/dist/drivers/toolkit/background.js +0 -86
- package/dist/drivers/toolkit/background.js.map +0 -1
- package/dist/drivers/toolkit/bounds.d.ts +0 -4
- package/dist/drivers/toolkit/bounds.d.ts.map +0 -1
- package/dist/drivers/toolkit/bounds.js +0 -4
- package/dist/drivers/toolkit/bounds.js.map +0 -1
- package/dist/drivers/toolkit/catalog.d.ts +0 -31
- package/dist/drivers/toolkit/catalog.d.ts.map +0 -1
- package/dist/drivers/toolkit/catalog.js +0 -108
- package/dist/drivers/toolkit/catalog.js.map +0 -1
- package/dist/drivers/toolkit/connection-tools.d.ts +0 -28
- package/dist/drivers/toolkit/connection-tools.d.ts.map +0 -1
- package/dist/drivers/toolkit/connection-tools.js +0 -129
- package/dist/drivers/toolkit/connection-tools.js.map +0 -1
- package/dist/drivers/toolkit/dist-tools.d.ts +0 -96
- package/dist/drivers/toolkit/dist-tools.d.ts.map +0 -1
- package/dist/drivers/toolkit/dist-tools.js +0 -488
- package/dist/drivers/toolkit/dist-tools.js.map +0 -1
- package/dist/drivers/toolkit/executor.d.ts +0 -17
- package/dist/drivers/toolkit/executor.d.ts.map +0 -1
- package/dist/drivers/toolkit/executor.js +0 -60
- package/dist/drivers/toolkit/executor.js.map +0 -1
- package/dist/drivers/toolkit/finder.d.ts +0 -4
- package/dist/drivers/toolkit/finder.d.ts.map +0 -1
- package/dist/drivers/toolkit/finder.js +0 -65
- package/dist/drivers/toolkit/finder.js.map +0 -1
- package/dist/drivers/toolkit/index.d.ts +0 -26
- package/dist/drivers/toolkit/index.d.ts.map +0 -1
- package/dist/drivers/toolkit/index.js +0 -26
- package/dist/drivers/toolkit/index.js.map +0 -1
- package/dist/drivers/toolkit/pack-catalog.d.ts +0 -44
- package/dist/drivers/toolkit/pack-catalog.d.ts.map +0 -1
- package/dist/drivers/toolkit/pack-catalog.js +0 -29
- package/dist/drivers/toolkit/pack-catalog.js.map +0 -1
- package/dist/drivers/toolkit/pack-plugin-host.d.ts +0 -29
- package/dist/drivers/toolkit/pack-plugin-host.d.ts.map +0 -1
- package/dist/drivers/toolkit/pack-plugin-host.js +0 -119
- package/dist/drivers/toolkit/pack-plugin-host.js.map +0 -1
- package/dist/drivers/toolkit/plugin-tools.d.ts +0 -6
- package/dist/drivers/toolkit/plugin-tools.d.ts.map +0 -1
- package/dist/drivers/toolkit/plugin-tools.js +0 -2
- package/dist/drivers/toolkit/plugin-tools.js.map +0 -1
- package/dist/drivers/toolkit/shell-tool.d.ts +0 -19
- package/dist/drivers/toolkit/shell-tool.d.ts.map +0 -1
- package/dist/drivers/toolkit/shell-tool.js +0 -102
- package/dist/drivers/toolkit/shell-tool.js.map +0 -1
- package/dist/drivers/toolkit/system-plugins.d.ts +0 -16
- package/dist/drivers/toolkit/system-plugins.d.ts.map +0 -1
- package/dist/drivers/toolkit/system-plugins.js +0 -33
- package/dist/drivers/toolkit/system-plugins.js.map +0 -1
- package/dist/drivers/toolkit/tool-entry.d.ts +0 -12
- package/dist/drivers/toolkit/tool-entry.d.ts.map +0 -1
- package/dist/drivers/toolkit/tool-entry.js +0 -38
- package/dist/drivers/toolkit/tool-entry.js.map +0 -1
- package/dist/drivers/toolkit/tool-table.d.ts +0 -53
- package/dist/drivers/toolkit/tool-table.d.ts.map +0 -1
- package/dist/drivers/toolkit/tool-table.js +0 -134
- package/dist/drivers/toolkit/tool-table.js.map +0 -1
- package/dist/ensure.d.ts +0 -7
- package/dist/ensure.d.ts.map +0 -1
- package/dist/ensure.js +0 -165
- package/dist/ensure.js.map +0 -1
- package/dist/eval/compile.d.ts +0 -6
- package/dist/eval/compile.d.ts.map +0 -1
- package/dist/eval/compile.js +0 -16
- package/dist/eval/compile.js.map +0 -1
- package/dist/eval/format.d.ts +0 -7
- package/dist/eval/format.d.ts.map +0 -1
- package/dist/eval/format.js +0 -25
- package/dist/eval/format.js.map +0 -1
- package/dist/eval/progress.d.ts +0 -8
- package/dist/eval/progress.d.ts.map +0 -1
- package/dist/eval/progress.js +0 -64
- package/dist/eval/progress.js.map +0 -1
- package/dist/eval/run.d.ts +0 -20
- package/dist/eval/run.d.ts.map +0 -1
- package/dist/eval/run.js +0 -301
- package/dist/eval/run.js.map +0 -1
- package/dist/eval/watch.d.ts +0 -12
- package/dist/eval/watch.d.ts.map +0 -1
- package/dist/eval/watch.js +0 -65
- package/dist/eval/watch.js.map +0 -1
- package/dist/experimental/scheme-repl/index.d.ts +0 -3
- package/dist/experimental/scheme-repl/index.d.ts.map +0 -1
- package/dist/experimental/scheme-repl/index.js +0 -3
- package/dist/experimental/scheme-repl/index.js.map +0 -1
- package/dist/experimental/scheme-repl/interpret.d.ts +0 -17
- package/dist/experimental/scheme-repl/interpret.d.ts.map +0 -1
- package/dist/experimental/scheme-repl/interpret.js +0 -295
- package/dist/experimental/scheme-repl/interpret.js.map +0 -1
- package/dist/experimental/scheme-repl/limits.d.ts +0 -17
- package/dist/experimental/scheme-repl/limits.d.ts.map +0 -1
- package/dist/experimental/scheme-repl/limits.js +0 -15
- package/dist/experimental/scheme-repl/limits.js.map +0 -1
- package/dist/experimental/scheme-repl/register.d.ts +0 -26
- package/dist/experimental/scheme-repl/register.d.ts.map +0 -1
- package/dist/experimental/scheme-repl/register.js +0 -42
- package/dist/experimental/scheme-repl/register.js.map +0 -1
- package/dist/interpreter/ComputedExecBox.d.ts +0 -12
- package/dist/interpreter/ComputedExecBox.d.ts.map +0 -1
- package/dist/interpreter/ComputedExecBox.js +0 -88
- package/dist/interpreter/ComputedExecBox.js.map +0 -1
- package/dist/interpreter/image.d.ts +0 -10
- package/dist/interpreter/image.d.ts.map +0 -1
- package/dist/interpreter/image.js +0 -67
- package/dist/interpreter/image.js.map +0 -1
- package/dist/interpreter/imageCapability.d.ts +0 -9
- package/dist/interpreter/imageCapability.d.ts.map +0 -1
- package/dist/interpreter/imageCapability.js +0 -49
- package/dist/interpreter/imageCapability.js.map +0 -1
- package/dist/interpreter/reactivity.d.ts +0 -12
- package/dist/interpreter/reactivity.d.ts.map +0 -1
- package/dist/interpreter/reactivity.js +0 -86
- package/dist/interpreter/reactivity.js.map +0 -1
- package/dist/interpreter/rpc.d.ts +0 -11
- package/dist/interpreter/rpc.d.ts.map +0 -1
- package/dist/interpreter/rpc.js +0 -94
- package/dist/interpreter/rpc.js.map +0 -1
- package/dist/interpreter/rpcCapability.d.ts +0 -11
- package/dist/interpreter/rpcCapability.d.ts.map +0 -1
- package/dist/interpreter/rpcCapability.js +0 -91
- package/dist/interpreter/rpcCapability.js.map +0 -1
- package/dist/interpreter/ui.d.ts +0 -34
- package/dist/interpreter/ui.d.ts.map +0 -1
- package/dist/interpreter/ui.js +0 -204
- package/dist/interpreter/ui.js.map +0 -1
- package/dist/interpreter/uiCapability.d.ts +0 -34
- package/dist/interpreter/uiCapability.d.ts.map +0 -1
- package/dist/interpreter/uiCapability.js +0 -207
- package/dist/interpreter/uiCapability.js.map +0 -1
- package/dist/models/index.d.ts +0 -3
- package/dist/models/index.d.ts.map +0 -1
- package/dist/models/index.js +0 -3
- package/dist/models/index.js.map +0 -1
- package/dist/models/kernel/CommandSpec.d.ts +0 -19
- package/dist/models/kernel/CommandSpec.d.ts.map +0 -1
- package/dist/models/kernel/CommandSpec.js +0 -124
- package/dist/models/kernel/CommandSpec.js.map +0 -1
- package/dist/models/kernel/InstalledPlugin.d.ts +0 -25
- package/dist/models/kernel/InstalledPlugin.d.ts.map +0 -1
- package/dist/models/kernel/InstalledPlugin.js +0 -120
- package/dist/models/kernel/InstalledPlugin.js.map +0 -1
- package/dist/models/kernel/InterceptorSpec.d.ts +0 -25
- package/dist/models/kernel/InterceptorSpec.d.ts.map +0 -1
- package/dist/models/kernel/InterceptorSpec.js +0 -114
- package/dist/models/kernel/InterceptorSpec.js.map +0 -1
- package/dist/models/kernel/KernelPlexus.d.ts +0 -9
- package/dist/models/kernel/KernelPlexus.d.ts.map +0 -1
- package/dist/models/kernel/KernelPlexus.js +0 -15
- package/dist/models/kernel/KernelPlexus.js.map +0 -1
- package/dist/models/kernel/KernelRoot.d.ts +0 -70
- package/dist/models/kernel/KernelRoot.d.ts.map +0 -1
- package/dist/models/kernel/KernelRoot.js +0 -237
- package/dist/models/kernel/KernelRoot.js.map +0 -1
- package/dist/models/kernel/ModeRuleSpec.d.ts +0 -17
- package/dist/models/kernel/ModeRuleSpec.d.ts.map +0 -1
- package/dist/models/kernel/ModeRuleSpec.js +0 -94
- package/dist/models/kernel/ModeRuleSpec.js.map +0 -1
- package/dist/models/kernel/ProjectRoot.d.ts +0 -31
- package/dist/models/kernel/ProjectRoot.d.ts.map +0 -1
- package/dist/models/kernel/ProjectRoot.js +0 -141
- package/dist/models/kernel/ProjectRoot.js.map +0 -1
- package/dist/models/kernel/index.d.ts +0 -12
- package/dist/models/kernel/index.d.ts.map +0 -1
- package/dist/models/kernel/index.js +0 -12
- package/dist/models/kernel/index.js.map +0 -1
- package/dist/models/session/Agent.d.ts +0 -31
- package/dist/models/session/Agent.d.ts.map +0 -1
- package/dist/models/session/Agent.js +0 -146
- package/dist/models/session/Agent.js.map +0 -1
- package/dist/models/session/MindQueueEntry.d.ts +0 -24
- package/dist/models/session/MindQueueEntry.d.ts.map +0 -1
- package/dist/models/session/MindQueueEntry.js +0 -99
- package/dist/models/session/MindQueueEntry.js.map +0 -1
- package/dist/models/session/RegisteredToolsSet.d.ts +0 -19
- package/dist/models/session/RegisteredToolsSet.d.ts.map +0 -1
- package/dist/models/session/RegisteredToolsSet.js +0 -93
- package/dist/models/session/RegisteredToolsSet.js.map +0 -1
- package/dist/models/session/SessionPlexus.d.ts +0 -14
- package/dist/models/session/SessionPlexus.d.ts.map +0 -1
- package/dist/models/session/SessionPlexus.js +0 -18
- package/dist/models/session/SessionPlexus.js.map +0 -1
- package/dist/models/session/SessionRoot.d.ts +0 -58
- package/dist/models/session/SessionRoot.d.ts.map +0 -1
- package/dist/models/session/SessionRoot.js +0 -231
- package/dist/models/session/SessionRoot.js.map +0 -1
- package/dist/models/session/SessionSystemPrompt.d.ts +0 -34
- package/dist/models/session/SessionSystemPrompt.d.ts.map +0 -1
- package/dist/models/session/SessionSystemPrompt.js +0 -118
- package/dist/models/session/SessionSystemPrompt.js.map +0 -1
- package/dist/models/session/SessionSystemPromptDerivation.d.ts +0 -24
- package/dist/models/session/SessionSystemPromptDerivation.d.ts.map +0 -1
- package/dist/models/session/SessionSystemPromptDerivation.js +0 -123
- package/dist/models/session/SessionSystemPromptDerivation.js.map +0 -1
- package/dist/models/session/SessionUnit.d.ts +0 -157
- package/dist/models/session/SessionUnit.d.ts.map +0 -1
- package/dist/models/session/SessionUnit.js +0 -592
- package/dist/models/session/SessionUnit.js.map +0 -1
- package/dist/models/session/expectations/CompletionExpectation.d.ts +0 -42
- package/dist/models/session/expectations/CompletionExpectation.d.ts.map +0 -1
- package/dist/models/session/expectations/CompletionExpectation.js +0 -165
- package/dist/models/session/expectations/CompletionExpectation.js.map +0 -1
- package/dist/models/session/expectations/ToolCallExpectation.d.ts +0 -55
- package/dist/models/session/expectations/ToolCallExpectation.d.ts.map +0 -1
- package/dist/models/session/expectations/ToolCallExpectation.js +0 -212
- package/dist/models/session/expectations/ToolCallExpectation.js.map +0 -1
- package/dist/models/session/expectations/disposition.d.ts +0 -11
- package/dist/models/session/expectations/disposition.d.ts.map +0 -1
- package/dist/models/session/expectations/disposition.js +0 -9
- package/dist/models/session/expectations/disposition.js.map +0 -1
- package/dist/models/session/expectations/index.d.ts +0 -5
- package/dist/models/session/expectations/index.d.ts.map +0 -1
- package/dist/models/session/expectations/index.js +0 -5
- package/dist/models/session/expectations/index.js.map +0 -1
- package/dist/models/session/index.d.ts +0 -18
- package/dist/models/session/index.d.ts.map +0 -1
- package/dist/models/session/index.js +0 -18
- package/dist/models/session/index.js.map +0 -1
- package/dist/models/session/prompt-parts.d.ts +0 -27
- package/dist/models/session/prompt-parts.d.ts.map +0 -1
- package/dist/models/session/prompt-parts.js +0 -182
- package/dist/models/session/prompt-parts.js.map +0 -1
- package/dist/models/session/rewrite.d.ts +0 -18
- package/dist/models/session/rewrite.d.ts.map +0 -1
- package/dist/models/session/rewrite.js +0 -56
- package/dist/models/session/rewrite.js.map +0 -1
- package/dist/models/session/squeeze.d.ts +0 -20
- package/dist/models/session/squeeze.d.ts.map +0 -1
- package/dist/models/session/squeeze.js +0 -119
- package/dist/models/session/squeeze.js.map +0 -1
- package/dist/models/shared/AbstractRoot.d.ts +0 -14
- package/dist/models/shared/AbstractRoot.d.ts.map +0 -1
- package/dist/models/shared/AbstractRoot.js +0 -89
- package/dist/models/shared/AbstractRoot.js.map +0 -1
- package/dist/models/shared/ActionSpec.d.ts +0 -14
- package/dist/models/shared/ActionSpec.d.ts.map +0 -1
- package/dist/models/shared/ActionSpec.js +0 -106
- package/dist/models/shared/ActionSpec.js.map +0 -1
- package/dist/models/shared/BackgroundJob.d.ts +0 -33
- package/dist/models/shared/BackgroundJob.d.ts.map +0 -1
- package/dist/models/shared/BackgroundJob.js +0 -117
- package/dist/models/shared/BackgroundJob.js.map +0 -1
- package/dist/models/shared/KeyValueStorage.d.ts +0 -11
- package/dist/models/shared/KeyValueStorage.d.ts.map +0 -1
- package/dist/models/shared/KeyValueStorage.js +0 -17
- package/dist/models/shared/KeyValueStorage.js.map +0 -1
- package/dist/models/shared/WorkDemand.d.ts +0 -28
- package/dist/models/shared/WorkDemand.d.ts.map +0 -1
- package/dist/models/shared/WorkDemand.js +0 -96
- package/dist/models/shared/WorkDemand.js.map +0 -1
- package/dist/models/shared/index.d.ts +0 -6
- package/dist/models/shared/index.d.ts.map +0 -1
- package/dist/models/shared/index.js +0 -6
- package/dist/models/shared/index.js.map +0 -1
- package/dist/models/shared/policy/control.d.ts +0 -23
- package/dist/models/shared/policy/control.d.ts.map +0 -1
- package/dist/models/shared/policy/control.js +0 -32
- package/dist/models/shared/policy/control.js.map +0 -1
- package/dist/models/shared/policy/index.d.ts +0 -4
- package/dist/models/shared/policy/index.d.ts.map +0 -1
- package/dist/models/shared/policy/index.js +0 -4
- package/dist/models/shared/policy/index.js.map +0 -1
- package/dist/models/shared/policy/mode-policy.d.ts +0 -25
- package/dist/models/shared/policy/mode-policy.d.ts.map +0 -1
- package/dist/models/shared/policy/mode-policy.js +0 -106
- package/dist/models/shared/policy/mode-policy.js.map +0 -1
- package/dist/models/shared/residual.d.ts +0 -22
- package/dist/models/shared/residual.d.ts.map +0 -1
- package/dist/models/shared/residual.js +0 -11
- package/dist/models/shared/residual.js.map +0 -1
- package/dist/oauth-loopback.d.ts +0 -24
- package/dist/oauth-loopback.d.ts.map +0 -1
- package/dist/oauth-loopback.js +0 -120
- package/dist/oauth-loopback.js.map +0 -1
- package/dist/open-external.d.ts +0 -2
- package/dist/open-external.d.ts.map +0 -1
- package/dist/open-external.js +0 -24
- package/dist/open-external.js.map +0 -1
- package/dist/paths.d.ts +0 -7
- package/dist/paths.d.ts.map +0 -1
- package/dist/paths.js +0 -16
- package/dist/paths.js.map +0 -1
- package/dist/policy-processor/check.d.ts +0 -19
- package/dist/policy-processor/check.d.ts.map +0 -1
- package/dist/policy-processor/check.js +0 -251
- package/dist/policy-processor/check.js.map +0 -1
- package/dist/policy-processor/classifier.d.ts +0 -39
- package/dist/policy-processor/classifier.d.ts.map +0 -1
- package/dist/policy-processor/classifier.js +0 -435
- package/dist/policy-processor/classifier.js.map +0 -1
- package/dist/policy-processor/cluster.d.ts +0 -3
- package/dist/policy-processor/cluster.d.ts.map +0 -1
- package/dist/policy-processor/cluster.js +0 -26
- package/dist/policy-processor/cluster.js.map +0 -1
- package/dist/policy-processor/compile.d.ts +0 -37
- package/dist/policy-processor/compile.d.ts.map +0 -1
- package/dist/policy-processor/compile.js +0 -217
- package/dist/policy-processor/compile.js.map +0 -1
- package/dist/policy-processor/error-with-invariant.d.ts +0 -9
- package/dist/policy-processor/error-with-invariant.d.ts.map +0 -1
- package/dist/policy-processor/error-with-invariant.js +0 -12
- package/dist/policy-processor/error-with-invariant.js.map +0 -1
- package/dist/policy-processor/evidence.d.ts +0 -21
- package/dist/policy-processor/evidence.d.ts.map +0 -1
- package/dist/policy-processor/evidence.js +0 -169
- package/dist/policy-processor/evidence.js.map +0 -1
- package/dist/policy-processor/identity.d.ts +0 -15
- package/dist/policy-processor/identity.d.ts.map +0 -1
- package/dist/policy-processor/identity.js +0 -52
- package/dist/policy-processor/identity.js.map +0 -1
- package/dist/policy-processor/judge.d.ts +0 -39
- package/dist/policy-processor/judge.d.ts.map +0 -1
- package/dist/policy-processor/judge.js +0 -435
- package/dist/policy-processor/judge.js.map +0 -1
- package/dist/policy-processor/lift.d.ts +0 -4
- package/dist/policy-processor/lift.d.ts.map +0 -1
- package/dist/policy-processor/lift.js +0 -11
- package/dist/policy-processor/lift.js.map +0 -1
- package/dist/policy-processor/path-policy.d.ts +0 -32
- package/dist/policy-processor/path-policy.d.ts.map +0 -1
- package/dist/policy-processor/path-policy.js +0 -118
- package/dist/policy-processor/path-policy.js.map +0 -1
- package/dist/policy-processor/prep.d.ts +0 -58
- package/dist/policy-processor/prep.d.ts.map +0 -1
- package/dist/policy-processor/prep.js +0 -690
- package/dist/policy-processor/prep.js.map +0 -1
- package/dist/policy-processor/processor.d.ts +0 -31
- package/dist/policy-processor/processor.d.ts.map +0 -1
- package/dist/policy-processor/processor.js +0 -65
- package/dist/policy-processor/processor.js.map +0 -1
- package/dist/policy-processor/reasonable-defaults.d.ts +0 -3
- package/dist/policy-processor/reasonable-defaults.d.ts.map +0 -1
- package/dist/policy-processor/reasonable-defaults.js +0 -23
- package/dist/policy-processor/reasonable-defaults.js.map +0 -1
- package/dist/policy-processor/schemas/index.d.ts +0 -2
- package/dist/policy-processor/schemas/index.d.ts.map +0 -1
- package/dist/policy-processor/schemas/index.js +0 -2
- package/dist/policy-processor/schemas/index.js.map +0 -1
- package/dist/policy-processor/schemas/tirith.d.ts +0 -58
- package/dist/policy-processor/schemas/tirith.d.ts.map +0 -1
- package/dist/policy-processor/schemas/tirith.js +0 -23
- package/dist/policy-processor/schemas/tirith.js.map +0 -1
- package/dist/policy-processor/tirith-units.d.ts +0 -2
- package/dist/policy-processor/tirith-units.d.ts.map +0 -1
- package/dist/policy-processor/tirith-units.js +0 -227
- package/dist/policy-processor/tirith-units.js.map +0 -1
- package/dist/policy-processor/tirith.d.ts +0 -24
- package/dist/policy-processor/tirith.d.ts.map +0 -1
- package/dist/policy-processor/tirith.js +0 -311
- package/dist/policy-processor/tirith.js.map +0 -1
- package/dist/policy-processor/types.d.ts +0 -47
- package/dist/policy-processor/types.d.ts.map +0 -1
- package/dist/policy-processor/types.js +0 -8
- package/dist/policy-processor/types.js.map +0 -1
- package/dist/protocol/codec.d.ts +0 -4
- package/dist/protocol/codec.d.ts.map +0 -1
- package/dist/protocol/codec.js +0 -9
- package/dist/protocol/codec.js.map +0 -1
- package/dist/protocol/document/awareness.d.ts +0 -33
- package/dist/protocol/document/awareness.d.ts.map +0 -1
- package/dist/protocol/document/awareness.js +0 -68
- package/dist/protocol/document/awareness.js.map +0 -1
- package/dist/protocol/document/frames.d.ts +0 -15
- package/dist/protocol/document/frames.d.ts.map +0 -1
- package/dist/protocol/document/frames.js +0 -66
- package/dist/protocol/document/frames.js.map +0 -1
- package/dist/protocol/document/recovery.d.ts +0 -26
- package/dist/protocol/document/recovery.d.ts.map +0 -1
- package/dist/protocol/document/recovery.js +0 -63
- package/dist/protocol/document/recovery.js.map +0 -1
- package/dist/protocol/document.d.ts +0 -10
- package/dist/protocol/document.d.ts.map +0 -1
- package/dist/protocol/document.js +0 -10
- package/dist/protocol/document.js.map +0 -1
- package/dist/protocol/loss.d.ts +0 -28
- package/dist/protocol/loss.d.ts.map +0 -1
- package/dist/protocol/loss.js +0 -77
- package/dist/protocol/loss.js.map +0 -1
- package/dist/protocol/rpc/envelope.d.ts +0 -18
- package/dist/protocol/rpc/envelope.d.ts.map +0 -1
- package/dist/protocol/rpc/envelope.js +0 -34
- package/dist/protocol/rpc/envelope.js.map +0 -1
- package/dist/protocol/rpc/schemas.d.ts +0 -62
- package/dist/protocol/rpc/schemas.d.ts.map +0 -1
- package/dist/protocol/rpc/schemas.js +0 -51
- package/dist/protocol/rpc/schemas.js.map +0 -1
- package/dist/protocol/rpc/shapes.d.ts +0 -489
- package/dist/protocol/rpc/shapes.d.ts.map +0 -1
- package/dist/protocol/rpc/shapes.js +0 -320
- package/dist/protocol/rpc/shapes.js.map +0 -1
- package/dist/protocol/rpc.d.ts +0 -4
- package/dist/protocol/rpc.d.ts.map +0 -1
- package/dist/protocol/rpc.js +0 -4
- package/dist/protocol/rpc.js.map +0 -1
- package/dist/protocol/supervision.d.ts +0 -4
- package/dist/protocol/supervision.d.ts.map +0 -1
- package/dist/protocol/supervision.js +0 -4
- package/dist/protocol/supervision.js.map +0 -1
- package/dist/schemas/index.d.ts +0 -2
- package/dist/schemas/index.d.ts.map +0 -1
- package/dist/schemas/index.js +0 -2
- package/dist/schemas/index.js.map +0 -1
- package/dist/schemas/worker-boot.d.ts +0 -14
- package/dist/schemas/worker-boot.d.ts.map +0 -1
- package/dist/schemas/worker-boot.js +0 -15
- package/dist/schemas/worker-boot.js.map +0 -1
- package/dist/scheme/bound-tools.d.ts +0 -6
- package/dist/scheme/bound-tools.d.ts.map +0 -1
- package/dist/scheme/bound-tools.js +0 -88
- package/dist/scheme/bound-tools.js.map +0 -1
- package/dist/scheme/catalog-description.d.ts +0 -5
- package/dist/scheme/catalog-description.d.ts.map +0 -1
- package/dist/scheme/catalog-description.js +0 -150
- package/dist/scheme/catalog-description.js.map +0 -1
- package/dist/scheme/connection-models.d.ts +0 -20
- package/dist/scheme/connection-models.d.ts.map +0 -1
- package/dist/scheme/connection-models.js +0 -31
- package/dist/scheme/connection-models.js.map +0 -1
- package/dist/scheme/env.d.ts +0 -109
- package/dist/scheme/env.d.ts.map +0 -1
- package/dist/scheme/env.js +0 -923
- package/dist/scheme/env.js.map +0 -1
- package/dist/scheme/file-path.d.ts +0 -2
- package/dist/scheme/file-path.d.ts.map +0 -1
- package/dist/scheme/file-path.js +0 -2
- package/dist/scheme/file-path.js.map +0 -1
- package/dist/scheme/index.d.ts +0 -10
- package/dist/scheme/index.d.ts.map +0 -1
- package/dist/scheme/index.js +0 -10
- package/dist/scheme/index.js.map +0 -1
- package/dist/scheme/interpret.d.ts +0 -13
- package/dist/scheme/interpret.d.ts.map +0 -1
- package/dist/scheme/interpret.js +0 -26
- package/dist/scheme/interpret.js.map +0 -1
- package/dist/scheme/keywords.d.ts +0 -17
- package/dist/scheme/keywords.d.ts.map +0 -1
- package/dist/scheme/keywords.js +0 -76
- package/dist/scheme/keywords.js.map +0 -1
- package/dist/scheme/limits.d.ts +0 -11
- package/dist/scheme/limits.d.ts.map +0 -1
- package/dist/scheme/limits.js +0 -4
- package/dist/scheme/limits.js.map +0 -1
- package/dist/scheme/period.d.ts +0 -9
- package/dist/scheme/period.d.ts.map +0 -1
- package/dist/scheme/period.js +0 -152
- package/dist/scheme/period.js.map +0 -1
- package/dist/scheme/program-source.d.ts +0 -2
- package/dist/scheme/program-source.d.ts.map +0 -1
- package/dist/scheme/program-source.js +0 -2
- package/dist/scheme/program-source.js.map +0 -1
- package/dist/scheme/replay.d.ts +0 -9
- package/dist/scheme/replay.d.ts.map +0 -1
- package/dist/scheme/replay.js +0 -38
- package/dist/scheme/replay.js.map +0 -1
- package/dist/sdk/client-agents-tree.d.ts +0 -123
- package/dist/sdk/client-agents-tree.d.ts.map +0 -1
- package/dist/sdk/client-agents-tree.js +0 -504
- package/dist/sdk/client-agents-tree.js.map +0 -1
- package/dist/sdk/client-agents.d.ts +0 -50
- package/dist/sdk/client-agents.d.ts.map +0 -1
- package/dist/sdk/client-agents.js +0 -299
- package/dist/sdk/client-agents.js.map +0 -1
- package/dist/sdk/client.d.ts +0 -89
- package/dist/sdk/client.d.ts.map +0 -1
- package/dist/sdk/client.js +0 -589
- package/dist/sdk/client.js.map +0 -1
- package/dist/sdk/debug-log.d.ts +0 -2
- package/dist/sdk/debug-log.d.ts.map +0 -1
- package/dist/sdk/debug-log.js +0 -2
- package/dist/sdk/debug-log.js.map +0 -1
- package/dist/sdk/index.d.ts +0 -9
- package/dist/sdk/index.d.ts.map +0 -1
- package/dist/sdk/index.js +0 -9
- package/dist/sdk/index.js.map +0 -1
- package/dist/sdk/json-record.d.ts +0 -2
- package/dist/sdk/json-record.d.ts.map +0 -1
- package/dist/sdk/json-record.js +0 -2
- package/dist/sdk/json-record.js.map +0 -1
- package/dist/sdk/launch/continue-pick.d.ts +0 -17
- package/dist/sdk/launch/continue-pick.d.ts.map +0 -1
- package/dist/sdk/launch/continue-pick.js +0 -20
- package/dist/sdk/launch/continue-pick.js.map +0 -1
- package/dist/sdk/launch/index.d.ts +0 -6
- package/dist/sdk/launch/index.d.ts.map +0 -1
- package/dist/sdk/launch/index.js +0 -6
- package/dist/sdk/launch/index.js.map +0 -1
- package/dist/sdk/launch/model-flags.d.ts +0 -44
- package/dist/sdk/launch/model-flags.d.ts.map +0 -1
- package/dist/sdk/launch/model-flags.js +0 -216
- package/dist/sdk/launch/model-flags.js.map +0 -1
- package/dist/sdk/launch/streams.d.ts +0 -15
- package/dist/sdk/launch/streams.d.ts.map +0 -1
- package/dist/sdk/launch/streams.js +0 -2
- package/dist/sdk/launch/streams.js.map +0 -1
- package/dist/sdk/launch/term-continue.d.ts +0 -13
- package/dist/sdk/launch/term-continue.d.ts.map +0 -1
- package/dist/sdk/launch/term-continue.js +0 -17
- package/dist/sdk/launch/term-continue.js.map +0 -1
- package/dist/sdk/launch/term-session-key.d.ts +0 -8
- package/dist/sdk/launch/term-session-key.d.ts.map +0 -1
- package/dist/sdk/launch/term-session-key.js +0 -76
- package/dist/sdk/launch/term-session-key.js.map +0 -1
- package/dist/sdk/models/index.d.ts +0 -2
- package/dist/sdk/models/index.d.ts.map +0 -1
- package/dist/sdk/models/index.js +0 -2
- package/dist/sdk/models/index.js.map +0 -1
- package/dist/sdk/models/kernel/index.d.ts +0 -2
- package/dist/sdk/models/kernel/index.d.ts.map +0 -1
- package/dist/sdk/models/kernel/index.js +0 -2
- package/dist/sdk/models/kernel/index.js.map +0 -1
- package/dist/sdk/models/register.d.ts +0 -6
- package/dist/sdk/models/register.d.ts.map +0 -1
- package/dist/sdk/models/register.js +0 -6
- package/dist/sdk/models/register.js.map +0 -1
- package/dist/sdk/models/session/index.d.ts +0 -2
- package/dist/sdk/models/session/index.d.ts.map +0 -1
- package/dist/sdk/models/session/index.js +0 -2
- package/dist/sdk/models/session/index.js.map +0 -1
- package/dist/sdk/observable-abort-signal.d.ts +0 -7
- package/dist/sdk/observable-abort-signal.d.ts.map +0 -1
- package/dist/sdk/observable-abort-signal.js +0 -56
- package/dist/sdk/observable-abort-signal.js.map +0 -1
- package/dist/sdk/open-external.d.ts +0 -2
- package/dist/sdk/open-external.d.ts.map +0 -1
- package/dist/sdk/open-external.js +0 -24
- package/dist/sdk/open-external.js.map +0 -1
- package/dist/sdk/paths.d.ts +0 -7
- package/dist/sdk/paths.d.ts.map +0 -1
- package/dist/sdk/paths.js +0 -16
- package/dist/sdk/paths.js.map +0 -1
- package/dist/sdk/peer.d.ts +0 -12
- package/dist/sdk/peer.d.ts.map +0 -1
- package/dist/sdk/peer.js +0 -11
- package/dist/sdk/peer.js.map +0 -1
- package/dist/sdk/project/ProjectPlexus.d.ts +0 -15
- package/dist/sdk/project/ProjectPlexus.d.ts.map +0 -1
- package/dist/sdk/project/ProjectPlexus.js +0 -23
- package/dist/sdk/project/ProjectPlexus.js.map +0 -1
- package/dist/sdk/protocol.d.ts +0 -2
- package/dist/sdk/protocol.d.ts.map +0 -1
- package/dist/sdk/protocol.js +0 -2
- package/dist/sdk/protocol.js.map +0 -1
- package/dist/sdk/schemas/agent-call.d.ts +0 -2
- package/dist/sdk/schemas/agent-call.d.ts.map +0 -1
- package/dist/sdk/schemas/agent-call.js +0 -2
- package/dist/sdk/schemas/agent-call.js.map +0 -1
- package/dist/sdk/schemas/auto-allow.d.ts +0 -2
- package/dist/sdk/schemas/auto-allow.d.ts.map +0 -1
- package/dist/sdk/schemas/auto-allow.js +0 -2
- package/dist/sdk/schemas/auto-allow.js.map +0 -1
- package/dist/sdk/schemas/context-need.d.ts +0 -2
- package/dist/sdk/schemas/context-need.d.ts.map +0 -1
- package/dist/sdk/schemas/context-need.js +0 -2
- package/dist/sdk/schemas/context-need.js.map +0 -1
- package/dist/sdk/schemas/index.d.ts +0 -13
- package/dist/sdk/schemas/index.d.ts.map +0 -1
- package/dist/sdk/schemas/index.js +0 -13
- package/dist/sdk/schemas/index.js.map +0 -1
- package/dist/sdk/schemas/json-record.d.ts +0 -2
- package/dist/sdk/schemas/json-record.d.ts.map +0 -1
- package/dist/sdk/schemas/json-record.js +0 -2
- package/dist/sdk/schemas/json-record.js.map +0 -1
- package/dist/sdk/schemas/optional-description.d.ts +0 -2
- package/dist/sdk/schemas/optional-description.d.ts.map +0 -1
- package/dist/sdk/schemas/optional-description.js +0 -2
- package/dist/sdk/schemas/optional-description.js.map +0 -1
- package/dist/sdk/schemas/protocol.d.ts +0 -2
- package/dist/sdk/schemas/protocol.d.ts.map +0 -1
- package/dist/sdk/schemas/protocol.js +0 -2
- package/dist/sdk/schemas/protocol.js.map +0 -1
- package/dist/sdk/schemas/scheme-repl.d.ts +0 -2
- package/dist/sdk/schemas/scheme-repl.d.ts.map +0 -1
- package/dist/sdk/schemas/scheme-repl.js +0 -2
- package/dist/sdk/schemas/scheme-repl.js.map +0 -1
- package/dist/sdk/schemas/text-only-continue.d.ts +0 -2
- package/dist/sdk/schemas/text-only-continue.d.ts.map +0 -1
- package/dist/sdk/schemas/text-only-continue.js +0 -2
- package/dist/sdk/schemas/text-only-continue.js.map +0 -1
- package/dist/sdk/schemas/tool-outcome.d.ts +0 -2
- package/dist/sdk/schemas/tool-outcome.d.ts.map +0 -1
- package/dist/sdk/schemas/tool-outcome.js +0 -2
- package/dist/sdk/schemas/tool-outcome.js.map +0 -1
- package/dist/sdk/schemas/update-metadata.d.ts +0 -2
- package/dist/sdk/schemas/update-metadata.d.ts.map +0 -1
- package/dist/sdk/schemas/update-metadata.js +0 -2
- package/dist/sdk/schemas/update-metadata.js.map +0 -1
- package/dist/sdk/schemas/web-extract.d.ts +0 -2
- package/dist/sdk/schemas/web-extract.d.ts.map +0 -1
- package/dist/sdk/schemas/web-extract.js +0 -2
- package/dist/sdk/schemas/web-extract.js.map +0 -1
- package/dist/sdk/schemas/web-search.d.ts +0 -2
- package/dist/sdk/schemas/web-search.d.ts.map +0 -1
- package/dist/sdk/schemas/web-search.js +0 -2
- package/dist/sdk/schemas/web-search.js.map +0 -1
- package/dist/sdk/transport/awareness.d.ts +0 -2
- package/dist/sdk/transport/awareness.d.ts.map +0 -1
- package/dist/sdk/transport/awareness.js +0 -2
- package/dist/sdk/transport/awareness.js.map +0 -1
- package/dist/sdk/transport/frames.d.ts +0 -2
- package/dist/sdk/transport/frames.d.ts.map +0 -1
- package/dist/sdk/transport/frames.js +0 -2
- package/dist/sdk/transport/frames.js.map +0 -1
- package/dist/sdk/transport/plane.d.ts +0 -10
- package/dist/sdk/transport/plane.d.ts.map +0 -1
- package/dist/sdk/transport/plane.js +0 -59
- package/dist/sdk/transport/plane.js.map +0 -1
- package/dist/sdk/transport/rpc.d.ts +0 -25
- package/dist/sdk/transport/rpc.d.ts.map +0 -1
- package/dist/sdk/transport/rpc.js +0 -168
- package/dist/sdk/transport/rpc.js.map +0 -1
- package/dist/sdk/transport/unix.d.ts +0 -19
- package/dist/sdk/transport/unix.d.ts.map +0 -1
- package/dist/sdk/transport/unix.js +0 -68
- package/dist/sdk/transport/unix.js.map +0 -1
- package/dist/sdk/vt-text.d.ts +0 -2
- package/dist/sdk/vt-text.d.ts.map +0 -1
- package/dist/sdk/vt-text.js +0 -2
- package/dist/sdk/vt-text.js.map +0 -1
- package/dist/sdk/worker-permissions.d.ts +0 -30
- package/dist/sdk/worker-permissions.d.ts.map +0 -1
- package/dist/sdk/worker-permissions.js +0 -49
- package/dist/sdk/worker-permissions.js.map +0 -1
- package/dist/server/daemon/intent-recovery.d.ts +0 -39
- package/dist/server/daemon/intent-recovery.d.ts.map +0 -1
- package/dist/server/daemon/intent-recovery.js +0 -142
- package/dist/server/daemon/intent-recovery.js.map +0 -1
- package/dist/server/daemon/kernel/plugin-state-store.d.ts +0 -2
- package/dist/server/daemon/kernel/plugin-state-store.d.ts.map +0 -1
- package/dist/server/daemon/kernel/plugin-state-store.js +0 -2
- package/dist/server/daemon/kernel/plugin-state-store.js.map +0 -1
- package/dist/server/daemon/kernel/workflow-feeds.d.ts +0 -27
- package/dist/server/daemon/kernel/workflow-feeds.d.ts.map +0 -1
- package/dist/server/daemon/kernel/workflow-feeds.js +0 -230
- package/dist/server/daemon/kernel/workflow-feeds.js.map +0 -1
- package/dist/server/daemon/project/ToolCallHandler.d.ts +0 -5
- package/dist/server/daemon/project/ToolCallHandler.d.ts.map +0 -1
- package/dist/server/daemon/project/ToolCallHandler.js +0 -5
- package/dist/server/daemon/project/ToolCallHandler.js.map +0 -1
- package/dist/server/daemon/session/agent-acceptance.d.ts +0 -5
- package/dist/server/daemon/session/agent-acceptance.d.ts.map +0 -1
- package/dist/server/daemon/session/agent-acceptance.js +0 -5
- package/dist/server/daemon/session/agent-acceptance.js.map +0 -1
- package/dist/server/daemon/session/approval/approved.d.ts +0 -5
- package/dist/server/daemon/session/approval/approved.d.ts.map +0 -1
- package/dist/server/daemon/session/approval/approved.js +0 -5
- package/dist/server/daemon/session/approval/approved.js.map +0 -1
- package/dist/server/daemon/session/approval/dist.d.ts +0 -5
- package/dist/server/daemon/session/approval/dist.d.ts.map +0 -1
- package/dist/server/daemon/session/approval/dist.js +0 -5
- package/dist/server/daemon/session/approval/dist.js.map +0 -1
- package/dist/server/daemon/session/approval/guard.d.ts +0 -5
- package/dist/server/daemon/session/approval/guard.d.ts.map +0 -1
- package/dist/server/daemon/session/approval/guard.js +0 -5
- package/dist/server/daemon/session/approval/guard.js.map +0 -1
- package/dist/server/daemon/session/approval/index.d.ts +0 -4
- package/dist/server/daemon/session/approval/index.d.ts.map +0 -1
- package/dist/server/daemon/session/approval/index.js +0 -4
- package/dist/server/daemon/session/approval/index.js.map +0 -1
- package/dist/server/daemon/session/approval/unattended.d.ts +0 -5
- package/dist/server/daemon/session/approval/unattended.d.ts.map +0 -1
- package/dist/server/daemon/session/approval/unattended.js +0 -5
- package/dist/server/daemon/session/approval/unattended.js.map +0 -1
- package/dist/server/daemon/session/call-delivery.d.ts +0 -7
- package/dist/server/daemon/session/call-delivery.d.ts.map +0 -1
- package/dist/server/daemon/session/call-delivery.js +0 -7
- package/dist/server/daemon/session/call-delivery.js.map +0 -1
- package/dist/server/daemon/session/compact-env.d.ts +0 -5
- package/dist/server/daemon/session/compact-env.d.ts.map +0 -1
- package/dist/server/daemon/session/compact-env.js +0 -5
- package/dist/server/daemon/session/compact-env.js.map +0 -1
- package/dist/server/daemon/session/compact-floors.d.ts +0 -5
- package/dist/server/daemon/session/compact-floors.d.ts.map +0 -1
- package/dist/server/daemon/session/compact-floors.js +0 -5
- package/dist/server/daemon/session/compact-floors.js.map +0 -1
- package/dist/server/daemon/session/skills.d.ts +0 -22
- package/dist/server/daemon/session/skills.d.ts.map +0 -1
- package/dist/server/daemon/session/skills.js +0 -277
- package/dist/server/daemon/session/skills.js.map +0 -1
- package/dist/server/daemon/session/statusline-run.d.ts +0 -29
- package/dist/server/daemon/session/statusline-run.d.ts.map +0 -1
- package/dist/server/daemon/session/statusline-run.js +0 -336
- package/dist/server/daemon/session/statusline-run.js.map +0 -1
- package/dist/server/daemon/session/text-only-continue.d.ts +0 -39
- package/dist/server/daemon/session/text-only-continue.d.ts.map +0 -1
- package/dist/server/daemon/session/text-only-continue.js +0 -142
- package/dist/server/daemon/session/text-only-continue.js.map +0 -1
- package/dist/server/daemon/session/tool-behavior.d.ts +0 -6
- package/dist/server/daemon/session/tool-behavior.d.ts.map +0 -1
- package/dist/server/daemon/session/tool-behavior.js +0 -2
- package/dist/server/daemon/session/tool-behavior.js.map +0 -1
- package/dist/server/daemon/session/transcript.d.ts +0 -5
- package/dist/server/daemon/session/transcript.d.ts.map +0 -1
- package/dist/server/daemon/session/transcript.js +0 -5
- package/dist/server/daemon/session/transcript.js.map +0 -1
- package/dist/server/drivers/adopt.d.ts +0 -8
- package/dist/server/drivers/adopt.d.ts.map +0 -1
- package/dist/server/drivers/adopt.js +0 -7
- package/dist/server/drivers/adopt.js.map +0 -1
- package/dist/server/drivers/chatgpt-driver.d.ts +0 -6
- package/dist/server/drivers/chatgpt-driver.d.ts.map +0 -1
- package/dist/server/drivers/chatgpt-driver.js +0 -6
- package/dist/server/drivers/chatgpt-driver.js.map +0 -1
- package/dist/server/drivers/connection-miss.d.ts +0 -2
- package/dist/server/drivers/connection-miss.d.ts.map +0 -1
- package/dist/server/drivers/connection-miss.js +0 -2
- package/dist/server/drivers/connection-miss.js.map +0 -1
- package/dist/server/drivers/grok-driver.d.ts +0 -7
- package/dist/server/drivers/grok-driver.d.ts.map +0 -1
- package/dist/server/drivers/grok-driver.js +0 -7
- package/dist/server/drivers/grok-driver.js.map +0 -1
- package/dist/server/drivers/mcp/actor.d.ts +0 -5
- package/dist/server/drivers/mcp/actor.d.ts.map +0 -1
- package/dist/server/drivers/mcp/actor.js +0 -5
- package/dist/server/drivers/mcp/actor.js.map +0 -1
- package/dist/server/drivers/mcp/adopt.d.ts +0 -5
- package/dist/server/drivers/mcp/adopt.d.ts.map +0 -1
- package/dist/server/drivers/mcp/adopt.js +0 -5
- package/dist/server/drivers/mcp/adopt.js.map +0 -1
- package/dist/server/drivers/mcp/config.d.ts +0 -5
- package/dist/server/drivers/mcp/config.d.ts.map +0 -1
- package/dist/server/drivers/mcp/config.js +0 -5
- package/dist/server/drivers/mcp/config.js.map +0 -1
- package/dist/server/drivers/mcp/mcp-connection.d.ts +0 -5
- package/dist/server/drivers/mcp/mcp-connection.d.ts.map +0 -1
- package/dist/server/drivers/mcp/mcp-connection.js +0 -5
- package/dist/server/drivers/mcp/mcp-connection.js.map +0 -1
- package/dist/server/drivers/mcp/mcp-result.d.ts +0 -5
- package/dist/server/drivers/mcp/mcp-result.d.ts.map +0 -1
- package/dist/server/drivers/mcp/mcp-result.js +0 -5
- package/dist/server/drivers/mcp/mcp-result.js.map +0 -1
- package/dist/server/drivers/mcp/oauth.d.ts +0 -5
- package/dist/server/drivers/mcp/oauth.d.ts.map +0 -1
- package/dist/server/drivers/mcp/oauth.js +0 -5
- package/dist/server/drivers/mcp/oauth.js.map +0 -1
- package/dist/server/drivers/mcp/persist.d.ts +0 -5
- package/dist/server/drivers/mcp/persist.d.ts.map +0 -1
- package/dist/server/drivers/mcp/persist.js +0 -5
- package/dist/server/drivers/mcp/persist.js.map +0 -1
- package/dist/server/drivers/mcp/stdio-env.d.ts +0 -5
- package/dist/server/drivers/mcp/stdio-env.d.ts.map +0 -1
- package/dist/server/drivers/mcp/stdio-env.js +0 -5
- package/dist/server/drivers/mcp/stdio-env.js.map +0 -1
- package/dist/server/drivers/mcp/tool-filter.d.ts +0 -5
- package/dist/server/drivers/mcp/tool-filter.d.ts.map +0 -1
- package/dist/server/drivers/mcp/tool-filter.js +0 -5
- package/dist/server/drivers/mcp/tool-filter.js.map +0 -1
- package/dist/server/drivers/mcp/tool-severity.d.ts +0 -5
- package/dist/server/drivers/mcp/tool-severity.d.ts.map +0 -1
- package/dist/server/drivers/mcp/tool-severity.js +0 -5
- package/dist/server/drivers/mcp/tool-severity.js.map +0 -1
- package/dist/server/drivers/nous-auth.d.ts +0 -3
- package/dist/server/drivers/nous-auth.d.ts.map +0 -1
- package/dist/server/drivers/nous-auth.js +0 -2
- package/dist/server/drivers/nous-auth.js.map +0 -1
- package/dist/server/drivers/oidc/oidc.d.ts +0 -6
- package/dist/server/drivers/oidc/oidc.d.ts.map +0 -1
- package/dist/server/drivers/oidc/oidc.js +0 -6
- package/dist/server/drivers/oidc/oidc.js.map +0 -1
- package/dist/server/drivers/openai-compat/actor.d.ts +0 -3
- package/dist/server/drivers/openai-compat/actor.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/actor.js +0 -2
- package/dist/server/drivers/openai-compat/actor.js.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/chatgpt-usage.d.ts +0 -2
- package/dist/server/drivers/openai-compat/api-extensions/chatgpt-usage.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/chatgpt-usage.js +0 -2
- package/dist/server/drivers/openai-compat/api-extensions/chatgpt-usage.js.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/grok-billing.d.ts +0 -2
- package/dist/server/drivers/openai-compat/api-extensions/grok-billing.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/grok-billing.js +0 -2
- package/dist/server/drivers/openai-compat/api-extensions/grok-billing.js.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/index.d.ts +0 -4
- package/dist/server/drivers/openai-compat/api-extensions/index.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/api-extensions/index.js +0 -3
- package/dist/server/drivers/openai-compat/api-extensions/index.js.map +0 -1
- package/dist/server/drivers/openai-compat/cache-affinity.d.ts +0 -3
- package/dist/server/drivers/openai-compat/cache-affinity.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/cache-affinity.js +0 -2
- package/dist/server/drivers/openai-compat/cache-affinity.js.map +0 -1
- package/dist/server/drivers/openai-compat/connection.d.ts +0 -3
- package/dist/server/drivers/openai-compat/connection.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/connection.js +0 -2
- package/dist/server/drivers/openai-compat/connection.js.map +0 -1
- package/dist/server/drivers/openai-compat/index.d.ts +0 -3
- package/dist/server/drivers/openai-compat/index.d.ts.map +0 -1
- package/dist/server/drivers/openai-compat/index.js +0 -3
- package/dist/server/drivers/openai-compat/index.js.map +0 -1
- package/dist/server/drivers/openrouter/index.d.ts +0 -9
- package/dist/server/drivers/openrouter/index.d.ts.map +0 -1
- package/dist/server/drivers/openrouter/index.js +0 -9
- package/dist/server/drivers/openrouter/index.js.map +0 -1
- package/dist/server/drivers/web-search/actor.d.ts +0 -2
- package/dist/server/drivers/web-search/actor.d.ts.map +0 -1
- package/dist/server/drivers/web-search/actor.js +0 -2
- package/dist/server/drivers/web-search/actor.js.map +0 -1
- package/dist/server/drivers/web-search/adapters.d.ts +0 -2
- package/dist/server/drivers/web-search/adapters.d.ts.map +0 -1
- package/dist/server/drivers/web-search/adapters.js +0 -2
- package/dist/server/drivers/web-search/adapters.js.map +0 -1
- package/dist/server/drivers/web-search/borrow.d.ts +0 -2
- package/dist/server/drivers/web-search/borrow.d.ts.map +0 -1
- package/dist/server/drivers/web-search/borrow.js +0 -2
- package/dist/server/drivers/web-search/borrow.js.map +0 -1
- package/dist/server/drivers/web-search/connection.d.ts +0 -2
- package/dist/server/drivers/web-search/connection.d.ts.map +0 -1
- package/dist/server/drivers/web-search/connection.js +0 -2
- package/dist/server/drivers/web-search/connection.js.map +0 -1
- package/dist/server/drivers/web-search/exa.d.ts +0 -2
- package/dist/server/drivers/web-search/exa.d.ts.map +0 -1
- package/dist/server/drivers/web-search/exa.js +0 -2
- package/dist/server/drivers/web-search/exa.js.map +0 -1
- package/dist/server/drivers/web-search/extract-actor.d.ts +0 -2
- package/dist/server/drivers/web-search/extract-actor.d.ts.map +0 -1
- package/dist/server/drivers/web-search/extract-actor.js +0 -2
- package/dist/server/drivers/web-search/extract-actor.js.map +0 -1
- package/dist/server/drivers/web-search/extract.d.ts +0 -2
- package/dist/server/drivers/web-search/extract.d.ts.map +0 -1
- package/dist/server/drivers/web-search/extract.js +0 -2
- package/dist/server/drivers/web-search/extract.js.map +0 -1
- package/dist/server/drivers/web-search/firecrawl.d.ts +0 -2
- package/dist/server/drivers/web-search/firecrawl.d.ts.map +0 -1
- package/dist/server/drivers/web-search/firecrawl.js +0 -2
- package/dist/server/drivers/web-search/firecrawl.js.map +0 -1
- package/dist/server/drivers/web-search/http.d.ts +0 -2
- package/dist/server/drivers/web-search/http.d.ts.map +0 -1
- package/dist/server/drivers/web-search/http.js +0 -2
- package/dist/server/drivers/web-search/http.js.map +0 -1
- package/dist/server/drivers/web-search/keenable.d.ts +0 -2
- package/dist/server/drivers/web-search/keenable.d.ts.map +0 -1
- package/dist/server/drivers/web-search/keenable.js +0 -2
- package/dist/server/drivers/web-search/keenable.js.map +0 -1
- package/dist/server/drivers/web-search/keyless.d.ts +0 -2
- package/dist/server/drivers/web-search/keyless.d.ts.map +0 -1
- package/dist/server/drivers/web-search/keyless.js +0 -2
- package/dist/server/drivers/web-search/keyless.js.map +0 -1
- package/dist/server/drivers/web-search/parallel.d.ts +0 -2
- package/dist/server/drivers/web-search/parallel.d.ts.map +0 -1
- package/dist/server/drivers/web-search/parallel.js +0 -2
- package/dist/server/drivers/web-search/parallel.js.map +0 -1
- package/dist/server/drivers/web-search/ring.d.ts +0 -2
- package/dist/server/drivers/web-search/ring.d.ts.map +0 -1
- package/dist/server/drivers/web-search/ring.js +0 -2
- package/dist/server/drivers/web-search/ring.js.map +0 -1
- package/dist/server/drivers/web-search/ssrf.d.ts +0 -2
- package/dist/server/drivers/web-search/ssrf.d.ts.map +0 -1
- package/dist/server/drivers/web-search/ssrf.js +0 -2
- package/dist/server/drivers/web-search/ssrf.js.map +0 -1
- package/dist/server/drivers/web-search/tavily.d.ts +0 -2
- package/dist/server/drivers/web-search/tavily.d.ts.map +0 -1
- package/dist/server/drivers/web-search/tavily.js +0 -2
- package/dist/server/drivers/web-search/tavily.js.map +0 -1
- package/dist/server/error-with-invariant.d.ts +0 -9
- package/dist/server/error-with-invariant.d.ts.map +0 -1
- package/dist/server/error-with-invariant.js +0 -12
- package/dist/server/error-with-invariant.js.map +0 -1
- package/dist/server/keywords.d.ts +0 -6
- package/dist/server/keywords.d.ts.map +0 -1
- package/dist/server/keywords.js +0 -6
- package/dist/server/keywords.js.map +0 -1
- package/dist/server/outcome-receipts.d.ts +0 -5
- package/dist/server/outcome-receipts.d.ts.map +0 -1
- package/dist/server/outcome-receipts.js +0 -5
- package/dist/server/outcome-receipts.js.map +0 -1
- package/dist/server/plugin-surface/dispatch.d.ts +0 -3
- package/dist/server/plugin-surface/dispatch.d.ts.map +0 -1
- package/dist/server/plugin-surface/dispatch.js +0 -2
- package/dist/server/plugin-surface/dispatch.js.map +0 -1
- package/dist/server/plugin-surface/eval.d.ts +0 -2
- package/dist/server/plugin-surface/eval.d.ts.map +0 -1
- package/dist/server/plugin-surface/eval.js +0 -2
- package/dist/server/plugin-surface/eval.js.map +0 -1
- package/dist/server/plugin-surface/host.d.ts +0 -3
- package/dist/server/plugin-surface/host.d.ts.map +0 -1
- package/dist/server/plugin-surface/host.js +0 -2
- package/dist/server/plugin-surface/host.js.map +0 -1
- package/dist/server/plugin-surface/index.d.ts +0 -3
- package/dist/server/plugin-surface/index.d.ts.map +0 -1
- package/dist/server/plugin-surface/index.js +0 -2
- package/dist/server/plugin-surface/index.js.map +0 -1
- package/dist/server/plugin-surface/manifest.d.ts +0 -3
- package/dist/server/plugin-surface/manifest.d.ts.map +0 -1
- package/dist/server/plugin-surface/manifest.js +0 -2
- package/dist/server/plugin-surface/manifest.js.map +0 -1
- package/dist/server/plugin-surface/notes.d.ts +0 -3
- package/dist/server/plugin-surface/notes.d.ts.map +0 -1
- package/dist/server/plugin-surface/notes.js +0 -2
- package/dist/server/plugin-surface/notes.js.map +0 -1
- package/dist/server/plugin-surface/state.d.ts +0 -3
- package/dist/server/plugin-surface/state.d.ts.map +0 -1
- package/dist/server/plugin-surface/state.js +0 -2
- package/dist/server/plugin-surface/state.js.map +0 -1
- package/dist/server/plugin-surface/value.d.ts +0 -3
- package/dist/server/plugin-surface/value.d.ts.map +0 -1
- package/dist/server/plugin-surface/value.js +0 -2
- package/dist/server/plugin-surface/value.js.map +0 -1
- package/dist/server/plugins/graph.d.ts +0 -2
- package/dist/server/plugins/graph.d.ts.map +0 -1
- package/dist/server/plugins/graph.js +0 -2
- package/dist/server/plugins/graph.js.map +0 -1
- package/dist/server/plugins/inventory.d.ts +0 -2
- package/dist/server/plugins/inventory.d.ts.map +0 -1
- package/dist/server/plugins/inventory.js +0 -2
- package/dist/server/plugins/inventory.js.map +0 -1
- package/dist/server/provider-roster/chatgpt.d.ts +0 -2
- package/dist/server/provider-roster/chatgpt.d.ts.map +0 -1
- package/dist/server/provider-roster/chatgpt.js +0 -2
- package/dist/server/provider-roster/chatgpt.js.map +0 -1
- package/dist/server/provider-roster/grok.d.ts +0 -2
- package/dist/server/provider-roster/grok.d.ts.map +0 -1
- package/dist/server/provider-roster/grok.js +0 -2
- package/dist/server/provider-roster/grok.js.map +0 -1
- package/dist/server/provider-roster/mcp.d.ts +0 -2
- package/dist/server/provider-roster/mcp.d.ts.map +0 -1
- package/dist/server/provider-roster/mcp.js +0 -2
- package/dist/server/provider-roster/mcp.js.map +0 -1
- package/dist/server/provider-roster/openai-compat.d.ts +0 -4
- package/dist/server/provider-roster/openai-compat.d.ts.map +0 -1
- package/dist/server/provider-roster/openai-compat.js +0 -4
- package/dist/server/provider-roster/openai-compat.js.map +0 -1
- package/dist/server/provider-roster/openrouter.d.ts +0 -2
- package/dist/server/provider-roster/openrouter.d.ts.map +0 -1
- package/dist/server/provider-roster/openrouter.js +0 -2
- package/dist/server/provider-roster/openrouter.js.map +0 -1
- package/dist/server/provider-roster/web.d.ts +0 -2
- package/dist/server/provider-roster/web.d.ts.map +0 -1
- package/dist/server/provider-roster/web.js +0 -2
- package/dist/server/provider-roster/web.js.map +0 -1
- package/dist/server/schemas/agent-call.d.ts +0 -2
- package/dist/server/schemas/agent-call.d.ts.map +0 -1
- package/dist/server/schemas/agent-call.js +0 -2
- package/dist/server/schemas/agent-call.js.map +0 -1
- package/dist/server/schemas/bot-definition.d.ts +0 -2
- package/dist/server/schemas/bot-definition.d.ts.map +0 -1
- package/dist/server/schemas/bot-definition.js +0 -2
- package/dist/server/schemas/bot-definition.js.map +0 -1
- package/dist/server/schemas/connection.d.ts +0 -142
- package/dist/server/schemas/connection.d.ts.map +0 -1
- package/dist/server/schemas/connection.js +0 -62
- package/dist/server/schemas/connection.js.map +0 -1
- package/dist/server/schemas/mcp.d.ts +0 -5
- package/dist/server/schemas/mcp.d.ts.map +0 -1
- package/dist/server/schemas/mcp.js +0 -5
- package/dist/server/schemas/mcp.js.map +0 -1
- package/dist/server/schemas/openai-compat.d.ts +0 -3
- package/dist/server/schemas/openai-compat.d.ts.map +0 -1
- package/dist/server/schemas/openai-compat.js +0 -2
- package/dist/server/schemas/openai-compat.js.map +0 -1
- package/dist/server/schemas/optional-description.d.ts +0 -2
- package/dist/server/schemas/optional-description.d.ts.map +0 -1
- package/dist/server/schemas/optional-description.js +0 -2
- package/dist/server/schemas/optional-description.js.map +0 -1
- package/dist/server/schemas/rpc.d.ts +0 -2
- package/dist/server/schemas/rpc.d.ts.map +0 -1
- package/dist/server/schemas/rpc.js +0 -2
- package/dist/server/schemas/rpc.js.map +0 -1
- package/dist/server/schemas/scheme-repl.d.ts +0 -2
- package/dist/server/schemas/scheme-repl.d.ts.map +0 -1
- package/dist/server/schemas/scheme-repl.js +0 -2
- package/dist/server/schemas/scheme-repl.js.map +0 -1
- package/dist/server/schemas/skill-frontmatter.d.ts +0 -3
- package/dist/server/schemas/skill-frontmatter.d.ts.map +0 -1
- package/dist/server/schemas/skill-frontmatter.js +0 -3
- package/dist/server/schemas/skill-frontmatter.js.map +0 -1
- package/dist/server/schemas/ui-resolve.d.ts +0 -5
- package/dist/server/schemas/ui-resolve.d.ts.map +0 -1
- package/dist/server/schemas/ui-resolve.js +0 -7
- package/dist/server/schemas/ui-resolve.js.map +0 -1
- package/dist/server/schemas/web-search.d.ts +0 -2
- package/dist/server/schemas/web-search.d.ts.map +0 -1
- package/dist/server/schemas/web-search.js +0 -2
- package/dist/server/schemas/web-search.js.map +0 -1
- package/dist/server/schemas/write-gate.d.ts +0 -13
- package/dist/server/schemas/write-gate.d.ts.map +0 -1
- package/dist/server/schemas/write-gate.js +0 -14
- package/dist/server/schemas/write-gate.js.map +0 -1
- package/dist/server/scheme-repl/agent-spec.d.ts +0 -3
- package/dist/server/scheme-repl/agent-spec.d.ts.map +0 -1
- package/dist/server/scheme-repl/agent-spec.js +0 -3
- package/dist/server/scheme-repl/agent-spec.js.map +0 -1
- package/dist/server/scheme-repl/bound-tools.d.ts +0 -3
- package/dist/server/scheme-repl/bound-tools.d.ts.map +0 -1
- package/dist/server/scheme-repl/bound-tools.js +0 -3
- package/dist/server/scheme-repl/bound-tools.js.map +0 -1
- package/dist/server/scheme-repl/catalog-description.d.ts +0 -3
- package/dist/server/scheme-repl/catalog-description.d.ts.map +0 -1
- package/dist/server/scheme-repl/catalog-description.js +0 -3
- package/dist/server/scheme-repl/catalog-description.js.map +0 -1
- package/dist/server/scheme-repl/connection-models.d.ts +0 -3
- package/dist/server/scheme-repl/connection-models.d.ts.map +0 -1
- package/dist/server/scheme-repl/connection-models.js +0 -3
- package/dist/server/scheme-repl/connection-models.js.map +0 -1
- package/dist/server/scheme-repl/env.d.ts +0 -3
- package/dist/server/scheme-repl/env.d.ts.map +0 -1
- package/dist/server/scheme-repl/env.js +0 -3
- package/dist/server/scheme-repl/env.js.map +0 -1
- package/dist/server/scheme-repl/file-path.d.ts +0 -3
- package/dist/server/scheme-repl/file-path.d.ts.map +0 -1
- package/dist/server/scheme-repl/file-path.js +0 -3
- package/dist/server/scheme-repl/file-path.js.map +0 -1
- package/dist/server/scheme-repl/interpret.d.ts +0 -3
- package/dist/server/scheme-repl/interpret.d.ts.map +0 -1
- package/dist/server/scheme-repl/interpret.js +0 -3
- package/dist/server/scheme-repl/interpret.js.map +0 -1
- package/dist/server/scheme-repl/keywords.d.ts +0 -3
- package/dist/server/scheme-repl/keywords.d.ts.map +0 -1
- package/dist/server/scheme-repl/keywords.js +0 -3
- package/dist/server/scheme-repl/keywords.js.map +0 -1
- package/dist/server/scheme-repl/limits.d.ts +0 -3
- package/dist/server/scheme-repl/limits.d.ts.map +0 -1
- package/dist/server/scheme-repl/limits.js +0 -3
- package/dist/server/scheme-repl/limits.js.map +0 -1
- package/dist/server/scheme-repl/period.d.ts +0 -4
- package/dist/server/scheme-repl/period.d.ts.map +0 -1
- package/dist/server/scheme-repl/period.js +0 -4
- package/dist/server/scheme-repl/period.js.map +0 -1
- package/dist/server/scheme-repl/program-source.d.ts +0 -3
- package/dist/server/scheme-repl/program-source.d.ts.map +0 -1
- package/dist/server/scheme-repl/program-source.js +0 -3
- package/dist/server/scheme-repl/program-source.js.map +0 -1
- package/dist/server/squeeze.d.ts +0 -5
- package/dist/server/squeeze.d.ts.map +0 -1
- package/dist/server/squeeze.js +0 -5
- package/dist/server/squeeze.js.map +0 -1
- package/dist/server/system-plugins/metadata/context-need.d.ts +0 -2
- package/dist/server/system-plugins/metadata/context-need.d.ts.map +0 -1
- package/dist/server/system-plugins/metadata/context-need.js +0 -2
- package/dist/server/system-plugins/metadata/context-need.js.map +0 -1
- package/dist/server/system-plugins/metadata/update-metadata.d.ts +0 -2
- package/dist/server/system-plugins/metadata/update-metadata.d.ts.map +0 -1
- package/dist/server/system-plugins/metadata/update-metadata.js +0 -2
- package/dist/server/system-plugins/metadata/update-metadata.js.map +0 -1
- package/dist/server/system-plugins/scheme-repl/register.d.ts +0 -2
- package/dist/server/system-plugins/scheme-repl/register.d.ts.map +0 -1
- package/dist/server/system-plugins/scheme-repl/register.js +0 -2
- package/dist/server/system-plugins/scheme-repl/register.js.map +0 -1
- package/dist/server/system-plugins/shell/job-stop.d.ts +0 -2
- package/dist/server/system-plugins/shell/job-stop.d.ts.map +0 -1
- package/dist/server/system-plugins/shell/job-stop.js +0 -2
- package/dist/server/system-plugins/shell/job-stop.js.map +0 -1
- package/dist/server/system-plugins/shell/shell-tool.d.ts +0 -2
- package/dist/server/system-plugins/shell/shell-tool.d.ts.map +0 -1
- package/dist/server/system-plugins/shell/shell-tool.js +0 -2
- package/dist/server/system-plugins/shell/shell-tool.js.map +0 -1
- package/dist/server/system-plugins/toolkit/bounds.d.ts +0 -2
- package/dist/server/system-plugins/toolkit/bounds.d.ts.map +0 -1
- package/dist/server/system-plugins/toolkit/bounds.js +0 -2
- package/dist/server/system-plugins/toolkit/bounds.js.map +0 -1
- package/dist/server/system-plugins/toolkit/finder.d.ts +0 -2
- package/dist/server/system-plugins/toolkit/finder.d.ts.map +0 -1
- package/dist/server/system-plugins/toolkit/finder.js +0 -2
- package/dist/server/system-plugins/toolkit/finder.js.map +0 -1
- package/dist/server/system-plugins/toolkit/write-gate.d.ts +0 -5
- package/dist/server/system-plugins/toolkit/write-gate.d.ts.map +0 -1
- package/dist/server/system-plugins/toolkit/write-gate.js +0 -5
- package/dist/server/system-plugins/toolkit/write-gate.js.map +0 -1
- package/dist/server/system-plugins/web-search/web-extract.d.ts +0 -2
- package/dist/server/system-plugins/web-search/web-extract.d.ts.map +0 -1
- package/dist/server/system-plugins/web-search/web-extract.js +0 -2
- package/dist/server/system-plugins/web-search/web-extract.js.map +0 -1
- package/dist/server/system-plugins/web-search/web-search.d.ts +0 -2
- package/dist/server/system-plugins/web-search/web-search.d.ts.map +0 -1
- package/dist/server/system-plugins/web-search/web-search.js +0 -2
- package/dist/server/system-plugins/web-search/web-search.js.map +0 -1
- package/dist/server/toolkit/connection-tools.d.ts +0 -5
- package/dist/server/toolkit/connection-tools.d.ts.map +0 -1
- package/dist/server/toolkit/connection-tools.js +0 -5
- package/dist/server/toolkit/connection-tools.js.map +0 -1
- package/dist/server/toolkit/model-wire.d.ts +0 -2
- package/dist/server/toolkit/model-wire.d.ts.map +0 -1
- package/dist/server/toolkit/model-wire.js +0 -2
- package/dist/server/toolkit/model-wire.js.map +0 -1
- package/dist/server/toolkit/optional-description.d.ts +0 -2
- package/dist/server/toolkit/optional-description.d.ts.map +0 -1
- package/dist/server/toolkit/optional-description.js +0 -2
- package/dist/server/toolkit/optional-description.js.map +0 -1
- package/dist/server/toolkit/pack-plugin-host.d.ts +0 -2
- package/dist/server/toolkit/pack-plugin-host.d.ts.map +0 -1
- package/dist/server/toolkit/pack-plugin-host.js +0 -2
- package/dist/server/toolkit/pack-plugin-host.js.map +0 -1
- package/dist/server/toolkit/plugin-context.d.ts +0 -5
- package/dist/server/toolkit/plugin-context.d.ts.map +0 -1
- package/dist/server/toolkit/plugin-context.js +0 -5
- package/dist/server/toolkit/plugin-context.js.map +0 -1
- package/dist/server/toolkit/private-plugin-mcp.d.ts +0 -5
- package/dist/server/toolkit/private-plugin-mcp.d.ts.map +0 -1
- package/dist/server/toolkit/private-plugin-mcp.js +0 -5
- package/dist/server/toolkit/private-plugin-mcp.js.map +0 -1
- package/dist/server/toolkit/run-system-tool.d.ts +0 -5
- package/dist/server/toolkit/run-system-tool.d.ts.map +0 -1
- package/dist/server/toolkit/run-system-tool.js +0 -5
- package/dist/server/toolkit/run-system-tool.js.map +0 -1
- package/dist/server/transport/keepalive.d.ts +0 -2
- package/dist/server/transport/keepalive.d.ts.map +0 -1
- package/dist/server/transport/keepalive.js +0 -2
- package/dist/server/transport/keepalive.js.map +0 -1
- package/dist/server/transport/relay.d.ts +0 -2
- package/dist/server/transport/relay.d.ts.map +0 -1
- package/dist/server/transport/relay.js +0 -2
- package/dist/server/transport/relay.js.map +0 -1
- package/dist/server/transport/websocket.d.ts +0 -2
- package/dist/server/transport/websocket.d.ts.map +0 -1
- package/dist/server/transport/websocket.js +0 -2
- package/dist/server/transport/websocket.js.map +0 -1
- package/dist/session/cancel.d.ts +0 -12
- package/dist/session/cancel.d.ts.map +0 -1
- package/dist/session/cancel.js +0 -72
- package/dist/session/cancel.js.map +0 -1
- package/dist/session/commands.d.ts +0 -39
- package/dist/session/commands.d.ts.map +0 -1
- package/dist/session/commands.js +0 -233
- package/dist/session/commands.js.map +0 -1
- package/dist/session/compact-actor.d.ts +0 -23
- package/dist/session/compact-actor.d.ts.map +0 -1
- package/dist/session/compact-actor.js +0 -132
- package/dist/session/compact-actor.js.map +0 -1
- package/dist/session/compact-env.d.ts +0 -52
- package/dist/session/compact-env.d.ts.map +0 -1
- package/dist/session/compact-env.js +0 -296
- package/dist/session/compact-env.js.map +0 -1
- package/dist/session/compact.d.ts +0 -31
- package/dist/session/compact.d.ts.map +0 -1
- package/dist/session/compact.js +0 -58
- package/dist/session/compact.js.map +0 -1
- package/dist/session/park.d.ts +0 -16
- package/dist/session/park.d.ts.map +0 -1
- package/dist/session/park.js +0 -73
- package/dist/session/park.js.map +0 -1
- package/dist/session/types.d.ts +0 -49
- package/dist/session/types.d.ts.map +0 -1
- package/dist/session/types.js +0 -2
- package/dist/session/types.js.map +0 -1
- package/dist/step.d.ts +0 -14
- package/dist/step.d.ts.map +0 -1
- package/dist/step.js +0 -132
- package/dist/step.js.map +0 -1
- package/dist/tool-catalog/catalog.d.ts +0 -78
- package/dist/tool-catalog/catalog.d.ts.map +0 -1
- package/dist/tool-catalog/catalog.js +0 -377
- package/dist/tool-catalog/catalog.js.map +0 -1
- package/dist/tool-catalog/model-wire.d.ts +0 -8
- package/dist/tool-catalog/model-wire.d.ts.map +0 -1
- package/dist/tool-catalog/model-wire.js +0 -25
- package/dist/tool-catalog/model-wire.js.map +0 -1
- package/dist/tool-catalog/recipes.d.ts +0 -45
- package/dist/tool-catalog/recipes.d.ts.map +0 -1
- package/dist/tool-catalog/recipes.js +0 -126
- package/dist/tool-catalog/recipes.js.map +0 -1
- package/dist/tool-catalog/types.d.ts +0 -71
- package/dist/tool-catalog/types.d.ts.map +0 -1
- package/dist/tool-catalog/types.js +0 -2
- package/dist/tool-catalog/types.js.map +0 -1
- package/dist/tool-runtime/approval/approved.d.ts +0 -21
- package/dist/tool-runtime/approval/approved.d.ts.map +0 -1
- package/dist/tool-runtime/approval/approved.js +0 -40
- package/dist/tool-runtime/approval/approved.js.map +0 -1
- package/dist/tool-runtime/approval/dist.d.ts +0 -6
- package/dist/tool-runtime/approval/dist.d.ts.map +0 -1
- package/dist/tool-runtime/approval/dist.js +0 -28
- package/dist/tool-runtime/approval/dist.js.map +0 -1
- package/dist/tool-runtime/approval/inbound.d.ts +0 -7
- package/dist/tool-runtime/approval/inbound.d.ts.map +0 -1
- package/dist/tool-runtime/approval/inbound.js +0 -47
- package/dist/tool-runtime/approval/inbound.js.map +0 -1
- package/dist/tool-runtime/approval/unattended.d.ts +0 -8
- package/dist/tool-runtime/approval/unattended.d.ts.map +0 -1
- package/dist/tool-runtime/approval/unattended.js +0 -23
- package/dist/tool-runtime/approval/unattended.js.map +0 -1
- package/dist/tool-runtime/extra-root.d.ts +0 -3
- package/dist/tool-runtime/extra-root.d.ts.map +0 -1
- package/dist/tool-runtime/extra-root.js +0 -14
- package/dist/tool-runtime/extra-root.js.map +0 -1
- package/dist/tool-runtime/handler.d.ts +0 -28
- package/dist/tool-runtime/handler.d.ts.map +0 -1
- package/dist/tool-runtime/handler.js +0 -444
- package/dist/tool-runtime/handler.js.map +0 -1
- package/dist/tool-runtime/peel.d.ts +0 -18
- package/dist/tool-runtime/peel.d.ts.map +0 -1
- package/dist/tool-runtime/peel.js +0 -73
- package/dist/tool-runtime/peel.js.map +0 -1
- package/dist/tool-runtime/plugin-context.d.ts +0 -15
- package/dist/tool-runtime/plugin-context.d.ts.map +0 -1
- package/dist/tool-runtime/plugin-context.js +0 -67
- package/dist/tool-runtime/plugin-context.js.map +0 -1
- package/dist/tool-runtime/run-system-tool.d.ts +0 -13
- package/dist/tool-runtime/run-system-tool.d.ts.map +0 -1
- package/dist/tool-runtime/run-system-tool.js +0 -230
- package/dist/tool-runtime/run-system-tool.js.map +0 -1
- package/dist/tool-runtime/worker-tools.d.ts +0 -8
- package/dist/tool-runtime/worker-tools.d.ts.map +0 -1
- package/dist/tool-runtime/worker-tools.js +0 -63
- package/dist/tool-runtime/worker-tools.js.map +0 -1
- package/dist/tool-runtime/write-admit.d.ts +0 -16
- package/dist/tool-runtime/write-admit.d.ts.map +0 -1
- package/dist/tool-runtime/write-admit.js +0 -74
- package/dist/tool-runtime/write-admit.js.map +0 -1
- package/dist/transport/frames.d.ts +0 -12
- package/dist/transport/frames.d.ts.map +0 -1
- package/dist/transport/frames.js +0 -50
- package/dist/transport/frames.js.map +0 -1
- package/dist/transport/jsonrpc.d.ts +0 -30
- package/dist/transport/jsonrpc.d.ts.map +0 -1
- package/dist/transport/jsonrpc.js +0 -60
- package/dist/transport/jsonrpc.js.map +0 -1
- package/dist/transport/keepalive.d.ts +0 -11
- package/dist/transport/keepalive.d.ts.map +0 -1
- package/dist/transport/keepalive.js +0 -27
- package/dist/transport/keepalive.js.map +0 -1
- package/dist/transport/relay.d.ts +0 -28
- package/dist/transport/relay.d.ts.map +0 -1
- package/dist/transport/relay.js +0 -119
- package/dist/transport/relay.js.map +0 -1
- package/dist/transport/websocket.d.ts +0 -4
- package/dist/transport/websocket.d.ts.map +0 -1
- package/dist/transport/websocket.js +0 -39
- package/dist/transport/websocket.js.map +0 -1
- package/dist/tui/ack-prompt.d.ts +0 -53
- package/dist/tui/ack-prompt.d.ts.map +0 -1
- package/dist/tui/ack-prompt.js +0 -59
- package/dist/tui/ack-prompt.js.map +0 -1
- package/dist/tui/agent-cover.d.ts +0 -43
- package/dist/tui/agent-cover.d.ts.map +0 -1
- package/dist/tui/agent-cover.js +0 -123
- package/dist/tui/agent-cover.js.map +0 -1
- package/dist/tui/agents-drawer.d.ts +0 -47
- package/dist/tui/agents-drawer.d.ts.map +0 -1
- package/dist/tui/agents-drawer.js +0 -314
- package/dist/tui/agents-drawer.js.map +0 -1
- package/dist/tui/agents-keys.d.ts +0 -7
- package/dist/tui/agents-keys.d.ts.map +0 -1
- package/dist/tui/agents-keys.js +0 -22
- package/dist/tui/agents-keys.js.map +0 -1
- package/dist/tui/approval-cover.d.ts +0 -26
- package/dist/tui/approval-cover.d.ts.map +0 -1
- package/dist/tui/approval-cover.js +0 -19
- package/dist/tui/approval-cover.js.map +0 -1
- package/dist/tui/ask-shortcuts.d.ts +0 -59
- package/dist/tui/ask-shortcuts.d.ts.map +0 -1
- package/dist/tui/ask-shortcuts.js +0 -96
- package/dist/tui/ask-shortcuts.js.map +0 -1
- package/dist/tui/channel.d.ts +0 -59
- package/dist/tui/channel.d.ts.map +0 -1
- package/dist/tui/channel.js +0 -27
- package/dist/tui/channel.js.map +0 -1
- package/dist/tui/effects-summary.d.ts +0 -9
- package/dist/tui/effects-summary.d.ts.map +0 -1
- package/dist/tui/effects-summary.js +0 -63
- package/dist/tui/effects-summary.js.map +0 -1
- package/dist/tui/flatten.d.ts +0 -4
- package/dist/tui/flatten.d.ts.map +0 -1
- package/dist/tui/flatten.js +0 -14
- package/dist/tui/flatten.js.map +0 -1
- package/dist/tui/format-shell.d.ts +0 -5
- package/dist/tui/format-shell.d.ts.map +0 -1
- package/dist/tui/format-shell.js +0 -53
- package/dist/tui/format-shell.js.map +0 -1
- package/dist/tui/host-verbs.d.ts +0 -7
- package/dist/tui/host-verbs.d.ts.map +0 -1
- package/dist/tui/host-verbs.js +0 -9
- package/dist/tui/host-verbs.js.map +0 -1
- package/dist/tui/host.d.ts +0 -25
- package/dist/tui/host.d.ts.map +0 -1
- package/dist/tui/host.js +0 -380
- package/dist/tui/host.js.map +0 -1
- package/dist/tui/identity.d.ts +0 -66
- package/dist/tui/identity.d.ts.map +0 -1
- package/dist/tui/identity.js +0 -432
- package/dist/tui/identity.js.map +0 -1
- package/dist/tui/liveness.d.ts +0 -69
- package/dist/tui/liveness.d.ts.map +0 -1
- package/dist/tui/liveness.js +0 -270
- package/dist/tui/liveness.js.map +0 -1
- package/dist/tui/mcp-identity.d.ts +0 -25
- package/dist/tui/mcp-identity.d.ts.map +0 -1
- package/dist/tui/mcp-identity.js +0 -133
- package/dist/tui/mcp-identity.js.map +0 -1
- package/dist/tui/oauth-loopback.d.ts +0 -22
- package/dist/tui/oauth-loopback.d.ts.map +0 -1
- package/dist/tui/oauth-loopback.js +0 -116
- package/dist/tui/oauth-loopback.js.map +0 -1
- package/dist/tui/omnibox-seat.d.ts +0 -132
- package/dist/tui/omnibox-seat.d.ts.map +0 -1
- package/dist/tui/omnibox-seat.js +0 -182
- package/dist/tui/omnibox-seat.js.map +0 -1
- package/dist/tui/open-external.d.ts +0 -2
- package/dist/tui/open-external.d.ts.map +0 -1
- package/dist/tui/open-external.js +0 -24
- package/dist/tui/open-external.js.map +0 -1
- package/dist/tui/paint-controller.d.ts +0 -165
- package/dist/tui/paint-controller.d.ts.map +0 -1
- package/dist/tui/paint-controller.js +0 -950
- package/dist/tui/paint-controller.js.map +0 -1
- package/dist/tui/paint-dom.d.ts +0 -336
- package/dist/tui/paint-dom.d.ts.map +0 -1
- package/dist/tui/paint-dom.js +0 -709
- package/dist/tui/paint-dom.js.map +0 -1
- package/dist/tui/paint-source.d.ts +0 -57
- package/dist/tui/paint-source.d.ts.map +0 -1
- package/dist/tui/paint-source.js +0 -570
- package/dist/tui/paint-source.js.map +0 -1
- package/dist/tui/paint-transport.d.ts +0 -42
- package/dist/tui/paint-transport.d.ts.map +0 -1
- package/dist/tui/paint-transport.js +0 -207
- package/dist/tui/paint-transport.js.map +0 -1
- package/dist/tui/paint-types.d.ts +0 -15
- package/dist/tui/paint-types.d.ts.map +0 -1
- package/dist/tui/paint-types.js +0 -6
- package/dist/tui/paint-types.js.map +0 -1
- package/dist/tui/paint-widgets.d.ts +0 -94
- package/dist/tui/paint-widgets.d.ts.map +0 -1
- package/dist/tui/paint-widgets.js +0 -877
- package/dist/tui/paint-widgets.js.map +0 -1
- package/dist/tui/parse-args.d.ts +0 -3
- package/dist/tui/parse-args.d.ts.map +0 -1
- package/dist/tui/parse-args.js +0 -13
- package/dist/tui/parse-args.js.map +0 -1
- package/dist/tui/permissions-view.d.ts +0 -93
- package/dist/tui/permissions-view.d.ts.map +0 -1
- package/dist/tui/permissions-view.js +0 -174
- package/dist/tui/permissions-view.js.map +0 -1
- package/dist/tui/present-visual/approve.d.ts +0 -10
- package/dist/tui/present-visual/approve.d.ts.map +0 -1
- package/dist/tui/present-visual/approve.js +0 -156
- package/dist/tui/present-visual/approve.js.map +0 -1
- package/dist/tui/present-visual/dump.d.ts +0 -47
- package/dist/tui/present-visual/dump.d.ts.map +0 -1
- package/dist/tui/present-visual/dump.js +0 -144
- package/dist/tui/present-visual/dump.js.map +0 -1
- package/dist/tui/present-visual/journey-teardown.d.ts +0 -3
- package/dist/tui/present-visual/journey-teardown.d.ts.map +0 -1
- package/dist/tui/present-visual/journey-teardown.js +0 -188
- package/dist/tui/present-visual/journey-teardown.js.map +0 -1
- package/dist/tui/present-visual/journey.d.ts +0 -15
- package/dist/tui/present-visual/journey.d.ts.map +0 -1
- package/dist/tui/present-visual/journey.js +0 -88
- package/dist/tui/present-visual/journey.js.map +0 -1
- package/dist/tui/present-visual/raster.d.ts +0 -3
- package/dist/tui/present-visual/raster.d.ts.map +0 -1
- package/dist/tui/present-visual/raster.js +0 -75
- package/dist/tui/present-visual/raster.js.map +0 -1
- package/dist/tui/pretty-identity.d.ts +0 -15
- package/dist/tui/pretty-identity.d.ts.map +0 -1
- package/dist/tui/pretty-identity.js +0 -112
- package/dist/tui/pretty-identity.js.map +0 -1
- package/dist/tui/queue-shortcuts.d.ts +0 -13
- package/dist/tui/queue-shortcuts.d.ts.map +0 -1
- package/dist/tui/queue-shortcuts.js +0 -23
- package/dist/tui/queue-shortcuts.js.map +0 -1
- package/dist/tui/read-widen.d.ts +0 -14
- package/dist/tui/read-widen.d.ts.map +0 -1
- package/dist/tui/read-widen.js +0 -45
- package/dist/tui/read-widen.js.map +0 -1
- package/dist/tui/rewind-chrome.d.ts +0 -29
- package/dist/tui/rewind-chrome.d.ts.map +0 -1
- package/dist/tui/rewind-chrome.js +0 -77
- package/dist/tui/rewind-chrome.js.map +0 -1
- package/dist/tui/rust-present.d.ts +0 -37
- package/dist/tui/rust-present.d.ts.map +0 -1
- package/dist/tui/rust-present.js +0 -205
- package/dist/tui/rust-present.js.map +0 -1
- package/dist/tui/spinner-phase.d.ts +0 -24
- package/dist/tui/spinner-phase.d.ts.map +0 -1
- package/dist/tui/spinner-phase.js +0 -25
- package/dist/tui/spinner-phase.js.map +0 -1
- package/dist/tui/statusline-path.d.ts +0 -10
- package/dist/tui/statusline-path.d.ts.map +0 -1
- package/dist/tui/statusline-path.js +0 -42
- package/dist/tui/statusline-path.js.map +0 -1
- package/dist/tui/storybook/catalog.d.ts +0 -22
- package/dist/tui/storybook/catalog.d.ts.map +0 -1
- package/dist/tui/storybook/catalog.js +0 -212
- package/dist/tui/storybook/catalog.js.map +0 -1
- package/dist/tui/storybook/main.d.ts +0 -2
- package/dist/tui/storybook/main.d.ts.map +0 -1
- package/dist/tui/storybook/main.js +0 -232
- package/dist/tui/storybook/main.js.map +0 -1
- package/dist/tui/storybook/shell.d.ts +0 -29
- package/dist/tui/storybook/shell.d.ts.map +0 -1
- package/dist/tui/storybook/shell.js +0 -212
- package/dist/tui/storybook/shell.js.map +0 -1
- package/dist/tui/storybook/source.d.ts +0 -27
- package/dist/tui/storybook/source.d.ts.map +0 -1
- package/dist/tui/storybook/source.js +0 -113
- package/dist/tui/storybook/source.js.map +0 -1
- package/dist/tui/storybook/stage.d.ts +0 -32
- package/dist/tui/storybook/stage.d.ts.map +0 -1
- package/dist/tui/storybook/stage.js +0 -451
- package/dist/tui/storybook/stage.js.map +0 -1
- package/dist/tui/storybook/stories.d.ts +0 -20
- package/dist/tui/storybook/stories.d.ts.map +0 -1
- package/dist/tui/storybook/stories.js +0 -156
- package/dist/tui/storybook/stories.js.map +0 -1
- package/dist/tui/storybook/types.d.ts +0 -31
- package/dist/tui/storybook/types.d.ts.map +0 -1
- package/dist/tui/storybook/types.js +0 -12
- package/dist/tui/storybook/types.js.map +0 -1
- package/dist/tui/sugarcoat-paint.d.ts +0 -14
- package/dist/tui/sugarcoat-paint.d.ts.map +0 -1
- package/dist/tui/sugarcoat-paint.js +0 -146
- package/dist/tui/sugarcoat-paint.js.map +0 -1
- package/dist/tui/sugarcoat.d.ts +0 -29
- package/dist/tui/sugarcoat.d.ts.map +0 -1
- package/dist/tui/sugarcoat.js +0 -148
- package/dist/tui/sugarcoat.js.map +0 -1
- package/dist/tui/tape-spans.d.ts +0 -64
- package/dist/tui/tape-spans.d.ts.map +0 -1
- package/dist/tui/tape-spans.js +0 -93
- package/dist/tui/tape-spans.js.map +0 -1
- package/dist/tui/tea.d.ts +0 -75
- package/dist/tui/tea.d.ts.map +0 -1
- package/dist/tui/tea.js +0 -2934
- package/dist/tui/tea.js.map +0 -1
- package/dist/tui/transcript.d.ts +0 -11
- package/dist/tui/transcript.d.ts.map +0 -1
- package/dist/tui/transcript.js +0 -3
- package/dist/tui/transcript.js.map +0 -1
- package/dist/tui/unwrap-program.d.ts +0 -2
- package/dist/tui/unwrap-program.d.ts.map +0 -1
- package/dist/tui/unwrap-program.js +0 -137
- package/dist/tui/unwrap-program.js.map +0 -1
- package/dist/tui/vt-paint.d.ts +0 -12
- package/dist/tui/vt-paint.d.ts.map +0 -1
- package/dist/tui/vt-paint.js +0 -123
- package/dist/tui/vt-paint.js.map +0 -1
- package/dist/tui/wait-phrase.d.ts +0 -31
- package/dist/tui/wait-phrase.d.ts.map +0 -1
- package/dist/tui/wait-phrase.js +0 -26
- package/dist/tui/wait-phrase.js.map +0 -1
- package/dist/tui/widget-host.d.ts +0 -34
- package/dist/tui/widget-host.d.ts.map +0 -1
- package/dist/tui/widget-host.js +0 -80
- package/dist/tui/widget-host.js.map +0 -1
- package/dist/tui/work-cells.d.ts +0 -47
- package/dist/tui/work-cells.d.ts.map +0 -1
- package/dist/tui/work-cells.js +0 -606
- package/dist/tui/work-cells.js.map +0 -1
- package/dist/tui/work-text.d.ts +0 -72
- package/dist/tui/work-text.d.ts.map +0 -1
- package/dist/tui/work-text.js +0 -315
- package/dist/tui/work-text.js.map +0 -1
- package/dist/tui/worker-entry.d.ts +0 -2
- package/dist/tui/worker-entry.d.ts.map +0 -1
- package/dist/tui/worker-entry.js +0 -98
- package/dist/tui/worker-entry.js.map +0 -1
package/dist/tui/tea.js
DELETED
|
@@ -1,2934 +0,0 @@
|
|
|
1
|
-
var __runInitializers = (this && this.__runInitializers) || function (thisArg, initializers, value) {
|
|
2
|
-
var useValue = arguments.length > 2;
|
|
3
|
-
for (var i = 0; i < initializers.length; i++) {
|
|
4
|
-
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
|
|
5
|
-
}
|
|
6
|
-
return useValue ? value : void 0;
|
|
7
|
-
};
|
|
8
|
-
var __esDecorate = (this && this.__esDecorate) || function (ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
|
|
9
|
-
function accept(f) { if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected"); return f; }
|
|
10
|
-
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
|
|
11
|
-
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
|
|
12
|
-
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
|
|
13
|
-
var _, done = false;
|
|
14
|
-
for (var i = decorators.length - 1; i >= 0; i--) {
|
|
15
|
-
var context = {};
|
|
16
|
-
for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
|
|
17
|
-
for (var p in contextIn.access) context.access[p] = contextIn.access[p];
|
|
18
|
-
context.addInitializer = function (f) { if (done) throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); };
|
|
19
|
-
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
|
|
20
|
-
if (kind === "accessor") {
|
|
21
|
-
if (result === void 0) continue;
|
|
22
|
-
if (result === null || typeof result !== "object") throw new TypeError("Object expected");
|
|
23
|
-
if (_ = accept(result.get)) descriptor.get = _;
|
|
24
|
-
if (_ = accept(result.set)) descriptor.set = _;
|
|
25
|
-
if (_ = accept(result.init)) initializers.unshift(_);
|
|
26
|
-
}
|
|
27
|
-
else if (_ = accept(result)) {
|
|
28
|
-
if (kind === "field") initializers.unshift(_);
|
|
29
|
-
else descriptor[key] = _;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
if (target) Object.defineProperty(target, contextIn.name, descriptor);
|
|
33
|
-
done = true;
|
|
34
|
-
};
|
|
35
|
-
var __setFunctionName = (this && this.__setFunctionName) || function (f, name, prefix) {
|
|
36
|
-
if (typeof name === "symbol") name = name.description ? "[".concat(name.description, "]") : "";
|
|
37
|
-
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
38
|
-
};
|
|
39
|
-
/**
|
|
40
|
-
* Worker Tea. Posts paint_init / paint_patch. Catalog is CommandSpec plus
|
|
41
|
-
* host verbs — host-verbs.ts has no CommandSpec body; invoke locally.
|
|
42
|
-
*
|
|
43
|
-
* Omnibox winner lives in omnibox-seat.ts, CHANGE ONLY.
|
|
44
|
-
*/
|
|
45
|
-
import { exec } from "@here.build/arrival";
|
|
46
|
-
import { fail, step, trace } from "@inhuman.tools/harness-diagnostics";
|
|
47
|
-
import { CallJob, AgentMessageJob, otherSessionSeatCount, DEFAULT_CONTEXT_GLOW_REMAINING, STATUSLINE_NOTE_SEP, fileReadPreparedPath, mcpReadFloorDenies, parseCompactTrigger, parseSuperKey, PERMISSION_MODES, MCPToolJob, isAtTip, isRewindPin, onTipChain, previousPin, futurePins, pastPins, resolvedTip, reactChunks, tapeCompletion, layersOf, SessionTurn, sessionDisplayTitle, skillMatchesVerb, ToolCallJob, } from "@inhuman.tools/harness-model";
|
|
48
|
-
import { flattenAgentDrawer, hostAskEscalateSessionId, mentionedAgentCall, projectAgentDrawer, projectRecentSessions, openExternalUrl, } from "@inhuman.tools/harness-sdk";
|
|
49
|
-
import { agentAskStackedBody, agentCoverPrompt, agentRecipeDescription, agentSpecKey, coverAskAnnotation, shellAskCommand, askPaintHead, emptyWaitChrome, formatMcpArgs, mcpConfirmViewport, } from "@inhuman.tools/harness-sdk/text";
|
|
50
|
-
import { applyDraftOp } from "@inhuman.tools/quickdraw/input";
|
|
51
|
-
import { eventMatchesChord } from "@inhuman.tools/quickdraw/layout";
|
|
52
|
-
import { agentsRowKeyFromHit, keyEventToDraftOp, maybeVisualMotion, receiveSubmit, rootInnerWidth, sessionIdFromAgentsKey, } from "@inhuman.tools/quickdraw/runtime";
|
|
53
|
-
import { catalogKey, COMPOSER_COMMAND_MAX_VISIBLE, matchComposerCommand, peekScroll, reconcileSelectedKey, } from "@inhuman.tools/quickdraw/widgets";
|
|
54
|
-
import { action, comparer, computed, observable, reaction, runInAction, when } from "mobx";
|
|
55
|
-
import invariant from "tiny-invariant";
|
|
56
|
-
import { isUiForm } from "../protocol/rpc/index.js";
|
|
57
|
-
import { imageCapability } from "../interpreter/imageCapability.js";
|
|
58
|
-
import { rpcCapability } from "../interpreter/rpcCapability.js";
|
|
59
|
-
import { uiCapability, UiNode } from "../interpreter/uiCapability.js";
|
|
60
|
-
import { agentsPaintFace } from "./agents-drawer.js";
|
|
61
|
-
import { ackAnnotation, ackPromptModel, ackVariant, cycleAck, } from "./ack-prompt.js";
|
|
62
|
-
import { HOTKEY_EVENT } from "./ask-shortcuts.js";
|
|
63
|
-
import { isHostVerb } from "./host-verbs.js";
|
|
64
|
-
import { parseProbe, permissionsSurface, permissionsView, } from "./permissions-view.js";
|
|
65
|
-
import { omniboxSeat, omniboxStackPanel, paintOmnibox, } from "./omnibox-seat.js";
|
|
66
|
-
import { createPaintController, isCompletionCutoff, trackEqual, trackTurn, } from "./paint-controller.js";
|
|
67
|
-
import { CLASSES } from "@inhuman.tools/policy/floor";
|
|
68
|
-
import { fileReadWiden } from "./read-widen.js";
|
|
69
|
-
import { rewindNeighborSlots } from "./rewind-chrome.js";
|
|
70
|
-
import { cwdParts } from "./statusline-path.js";
|
|
71
|
-
import { waitPhrase } from "./wait-phrase.js";
|
|
72
|
-
import { askPinFace, askPinWorthPainting } from "./work-cells.js";
|
|
73
|
-
import { ComputedExecBox } from "../interpreter/ComputedExecBox.js";
|
|
74
|
-
const COMMAND_CAPABILITIES = [imageCapability, uiCapability, rpcCapability];
|
|
75
|
-
/** Mash after cancel must not peel into history. Tea-local; the turn must also be idle. */
|
|
76
|
-
const REWIND_GRACE_MS = 1000;
|
|
77
|
-
export function bootComposerDraft(draft, connections) {
|
|
78
|
-
if (draft != null && draft !== "")
|
|
79
|
-
return draft;
|
|
80
|
-
for (const spec of connections) {
|
|
81
|
-
if (spec.driver?.abilityClaim.includes("completion"))
|
|
82
|
-
return undefined;
|
|
83
|
-
}
|
|
84
|
-
return "/connect";
|
|
85
|
-
}
|
|
86
|
-
let Tea = (() => {
|
|
87
|
-
var _a, _b, _c, _d, _e, _f;
|
|
88
|
-
let _instanceExtraInitializers = [];
|
|
89
|
-
let _draft_decorators;
|
|
90
|
-
let _draft_initializers = [];
|
|
91
|
-
let _draft_extraInitializers = [];
|
|
92
|
-
let _submission_decorators;
|
|
93
|
-
let _submission_initializers = [];
|
|
94
|
-
let _submission_extraInitializers = [];
|
|
95
|
-
let _selectedCommandKey_decorators;
|
|
96
|
-
let _selectedCommandKey_initializers = [];
|
|
97
|
-
let _selectedCommandKey_extraInitializers = [];
|
|
98
|
-
let _scrollOffset_decorators;
|
|
99
|
-
let _scrollOffset_initializers = [];
|
|
100
|
-
let _scrollOffset_extraInitializers = [];
|
|
101
|
-
let _escClearArmed_decorators;
|
|
102
|
-
let _escClearArmed_initializers = [];
|
|
103
|
-
let _escClearArmed_extraInitializers = [];
|
|
104
|
-
let _cols_decorators;
|
|
105
|
-
let _cols_initializers = [];
|
|
106
|
-
let _cols_extraInitializers = [];
|
|
107
|
-
let _rows_decorators;
|
|
108
|
-
let _rows_initializers = [];
|
|
109
|
-
let _rows_extraInitializers = [];
|
|
110
|
-
let _private_busy_decorators;
|
|
111
|
-
let _private_busy_initializers = [];
|
|
112
|
-
let _private_busy_extraInitializers = [];
|
|
113
|
-
let _private_busy_descriptor;
|
|
114
|
-
let _private_callback_decorators;
|
|
115
|
-
let _private_callback_initializers = [];
|
|
116
|
-
let _private_callback_extraInitializers = [];
|
|
117
|
-
let _private_callback_descriptor;
|
|
118
|
-
let _private_focus_decorators;
|
|
119
|
-
let _private_focus_initializers = [];
|
|
120
|
-
let _private_focus_extraInitializers = [];
|
|
121
|
-
let _private_focus_descriptor;
|
|
122
|
-
let _private_oauthWaiting_decorators;
|
|
123
|
-
let _private_oauthWaiting_initializers = [];
|
|
124
|
-
let _private_oauthWaiting_extraInitializers = [];
|
|
125
|
-
let _private_oauthWaiting_descriptor;
|
|
126
|
-
let _private_processing_decorators;
|
|
127
|
-
let _private_processing_initializers = [];
|
|
128
|
-
let _private_processing_extraInitializers = [];
|
|
129
|
-
let _private_processing_descriptor;
|
|
130
|
-
let _private_coverDraft_decorators;
|
|
131
|
-
let _private_coverDraft_initializers = [];
|
|
132
|
-
let _private_coverDraft_extraInitializers = [];
|
|
133
|
-
let _private_coverDraft_descriptor;
|
|
134
|
-
let _private_coverThrottle_decorators;
|
|
135
|
-
let _private_coverThrottle_initializers = [];
|
|
136
|
-
let _private_coverThrottle_extraInitializers = [];
|
|
137
|
-
let _private_coverThrottle_descriptor;
|
|
138
|
-
let _private_coverConfirmLive_decorators;
|
|
139
|
-
let _private_coverConfirmLive_initializers = [];
|
|
140
|
-
let _private_coverConfirmLive_extraInitializers = [];
|
|
141
|
-
let _private_coverConfirmLive_descriptor;
|
|
142
|
-
let _private_ackPick_decorators;
|
|
143
|
-
let _private_ackPick_initializers = [];
|
|
144
|
-
let _private_ackPick_extraInitializers = [];
|
|
145
|
-
let _private_ackPick_descriptor;
|
|
146
|
-
let _private_askHold_decorators;
|
|
147
|
-
let _private_askHold_initializers = [];
|
|
148
|
-
let _private_askHold_extraInitializers = [];
|
|
149
|
-
let _private_askHold_descriptor;
|
|
150
|
-
let _private_drainAsk_decorators;
|
|
151
|
-
let _private_drainAsk_initializers = [];
|
|
152
|
-
let _private_drainAsk_extraInitializers = [];
|
|
153
|
-
let _private_drainAsk_descriptor;
|
|
154
|
-
let _private_agentsOpen_decorators;
|
|
155
|
-
let _private_agentsOpen_initializers = [];
|
|
156
|
-
let _private_agentsOpen_extraInitializers = [];
|
|
157
|
-
let _private_agentsOpen_descriptor;
|
|
158
|
-
let _private_agentsFocus_decorators;
|
|
159
|
-
let _private_agentsFocus_initializers = [];
|
|
160
|
-
let _private_agentsFocus_extraInitializers = [];
|
|
161
|
-
let _private_agentsFocus_descriptor;
|
|
162
|
-
let _private_agentsHover_decorators;
|
|
163
|
-
let _private_agentsHover_initializers = [];
|
|
164
|
-
let _private_agentsHover_extraInitializers = [];
|
|
165
|
-
let _private_agentsHover_descriptor;
|
|
166
|
-
let _private_agentsScroll_decorators;
|
|
167
|
-
let _private_agentsScroll_initializers = [];
|
|
168
|
-
let _private_agentsScroll_extraInitializers = [];
|
|
169
|
-
let _private_agentsScroll_descriptor;
|
|
170
|
-
let _private_agentsPreview_decorators;
|
|
171
|
-
let _private_agentsPreview_initializers = [];
|
|
172
|
-
let _private_agentsPreview_extraInitializers = [];
|
|
173
|
-
let _private_agentsPreview_descriptor;
|
|
174
|
-
let _private_peekPlexus_decorators;
|
|
175
|
-
let _private_peekPlexus_initializers = [];
|
|
176
|
-
let _private_peekPlexus_extraInitializers = [];
|
|
177
|
-
let _private_peekPlexus_descriptor;
|
|
178
|
-
let _private_askPlexus_decorators;
|
|
179
|
-
let _private_askPlexus_initializers = [];
|
|
180
|
-
let _private_askPlexus_extraInitializers = [];
|
|
181
|
-
let _private_askPlexus_descriptor;
|
|
182
|
-
let _private_viewPin_decorators;
|
|
183
|
-
let _private_viewPin_initializers = [];
|
|
184
|
-
let _private_viewPin_extraInitializers = [];
|
|
185
|
-
let _private_viewPin_descriptor;
|
|
186
|
-
let _private_historyNav_decorators;
|
|
187
|
-
let _private_historyNav_initializers = [];
|
|
188
|
-
let _private_historyNav_extraInitializers = [];
|
|
189
|
-
let _private_historyNav_descriptor;
|
|
190
|
-
let _private_restoredDraft_decorators;
|
|
191
|
-
let _private_restoredDraft_initializers = [];
|
|
192
|
-
let _private_restoredDraft_extraInitializers = [];
|
|
193
|
-
let _private_restoredDraft_descriptor;
|
|
194
|
-
let _private_get_agentDrawerRows_decorators;
|
|
195
|
-
let _private_get_agentDrawerRows_descriptor;
|
|
196
|
-
let _private_get_sessionTitle_decorators;
|
|
197
|
-
let _private_get_sessionTitle_descriptor;
|
|
198
|
-
let _private_get_isHeadAtTip_decorators;
|
|
199
|
-
let _private_get_isHeadAtTip_descriptor;
|
|
200
|
-
let _private_get_askHead_decorators;
|
|
201
|
-
let _private_get_askHead_descriptor;
|
|
202
|
-
let _private_get_ackPrompt_decorators;
|
|
203
|
-
let _private_get_ackPrompt_descriptor;
|
|
204
|
-
let _private_get_coverAskAgentSpec_decorators;
|
|
205
|
-
let _private_get_coverAskAgentSpec_descriptor;
|
|
206
|
-
let _private_get_askHome_decorators;
|
|
207
|
-
let _private_get_askHome_descriptor;
|
|
208
|
-
let _private_get_readWiden_decorators;
|
|
209
|
-
let _private_get_readWiden_descriptor;
|
|
210
|
-
let _private_get_omniboxValue_decorators;
|
|
211
|
-
let _private_get_omniboxValue_descriptor;
|
|
212
|
-
let _private_get_contextRail_decorators;
|
|
213
|
-
let _private_get_contextRail_descriptor;
|
|
214
|
-
let _private_get_omnibox_decorators;
|
|
215
|
-
let _private_get_omnibox_descriptor;
|
|
216
|
-
let _private_get_askIsolated_decorators;
|
|
217
|
-
let _private_get_askIsolated_descriptor;
|
|
218
|
-
let _private_get_admissionDeckText_decorators;
|
|
219
|
-
let _private_get_admissionDeckText_descriptor;
|
|
220
|
-
let _private_get_waitChrome_decorators;
|
|
221
|
-
let _private_get_waitChrome_descriptor;
|
|
222
|
-
let _private_get_commands_decorators;
|
|
223
|
-
let _private_get_commands_descriptor;
|
|
224
|
-
let _private_get_parentNode_decorators;
|
|
225
|
-
let _private_get_parentNode_descriptor;
|
|
226
|
-
let _private_get_inCommand_decorators;
|
|
227
|
-
let _private_get_inCommand_descriptor;
|
|
228
|
-
let _private_get_atCatalog_decorators;
|
|
229
|
-
let _private_get_atCatalog_descriptor;
|
|
230
|
-
let _private_get_pickerRows_decorators;
|
|
231
|
-
let _private_get_pickerRows_descriptor;
|
|
232
|
-
let _private_get_catalogNodes_decorators;
|
|
233
|
-
let _private_get_catalogNodes_descriptor;
|
|
234
|
-
let _private_get_commandChoices_decorators;
|
|
235
|
-
let _private_get_commandChoices_descriptor;
|
|
236
|
-
let _get_effectiveKey_decorators;
|
|
237
|
-
let _private_get_commandAction_decorators;
|
|
238
|
-
let _private_get_commandAction_descriptor;
|
|
239
|
-
let _private_get_commandSurface_decorators;
|
|
240
|
-
let _private_get_commandSurface_descriptor;
|
|
241
|
-
let _private_get_selectedIndex_decorators;
|
|
242
|
-
let _private_get_selectedIndex_descriptor;
|
|
243
|
-
let _focusAt_decorators;
|
|
244
|
-
let _handle_decorators;
|
|
245
|
-
let _private_get_activeConnection_decorators;
|
|
246
|
-
let _private_get_activeConnection_descriptor;
|
|
247
|
-
let _private_get_quotaWindows_decorators;
|
|
248
|
-
let _private_get_quotaWindows_descriptor;
|
|
249
|
-
let _private_get_statusItems_decorators;
|
|
250
|
-
let _private_get_statusItems_descriptor;
|
|
251
|
-
let _private_stepCoverThrottle_decorators;
|
|
252
|
-
let _private_stepCoverThrottle_descriptor;
|
|
253
|
-
let _private_get_attentionSubjects_decorators;
|
|
254
|
-
let _private_get_attentionSubjects_descriptor;
|
|
255
|
-
return class Tea {
|
|
256
|
-
static {
|
|
257
|
-
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(null) : void 0;
|
|
258
|
-
__esDecorate(this, null, _draft_decorators, { kind: "accessor", name: "draft", static: false, private: false, access: { has: obj => "draft" in obj, get: obj => obj.draft, set: (obj, value) => { obj.draft = value; } }, metadata: _metadata }, _draft_initializers, _draft_extraInitializers);
|
|
259
|
-
__esDecorate(this, null, _submission_decorators, { kind: "accessor", name: "submission", static: false, private: false, access: { has: obj => "submission" in obj, get: obj => obj.submission, set: (obj, value) => { obj.submission = value; } }, metadata: _metadata }, _submission_initializers, _submission_extraInitializers);
|
|
260
|
-
__esDecorate(this, null, _selectedCommandKey_decorators, { kind: "accessor", name: "selectedCommandKey", static: false, private: false, access: { has: obj => "selectedCommandKey" in obj, get: obj => obj.selectedCommandKey, set: (obj, value) => { obj.selectedCommandKey = value; } }, metadata: _metadata }, _selectedCommandKey_initializers, _selectedCommandKey_extraInitializers);
|
|
261
|
-
__esDecorate(this, null, _scrollOffset_decorators, { kind: "accessor", name: "scrollOffset", static: false, private: false, access: { has: obj => "scrollOffset" in obj, get: obj => obj.scrollOffset, set: (obj, value) => { obj.scrollOffset = value; } }, metadata: _metadata }, _scrollOffset_initializers, _scrollOffset_extraInitializers);
|
|
262
|
-
__esDecorate(this, null, _escClearArmed_decorators, { kind: "accessor", name: "escClearArmed", static: false, private: false, access: { has: obj => "escClearArmed" in obj, get: obj => obj.escClearArmed, set: (obj, value) => { obj.escClearArmed = value; } }, metadata: _metadata }, _escClearArmed_initializers, _escClearArmed_extraInitializers);
|
|
263
|
-
__esDecorate(this, null, _cols_decorators, { kind: "accessor", name: "cols", static: false, private: false, access: { has: obj => "cols" in obj, get: obj => obj.cols, set: (obj, value) => { obj.cols = value; } }, metadata: _metadata }, _cols_initializers, _cols_extraInitializers);
|
|
264
|
-
__esDecorate(this, null, _rows_decorators, { kind: "accessor", name: "rows", static: false, private: false, access: { has: obj => "rows" in obj, get: obj => obj.rows, set: (obj, value) => { obj.rows = value; } }, metadata: _metadata }, _rows_initializers, _rows_extraInitializers);
|
|
265
|
-
__esDecorate(this, _private_busy_descriptor = { get: __setFunctionName(function () { return this.#busy_accessor_storage; }, "#busy", "get"), set: __setFunctionName(function (value) { this.#busy_accessor_storage = value; }, "#busy", "set") }, _private_busy_decorators, { kind: "accessor", name: "#busy", static: false, private: true, access: { has: obj => #busy in obj, get: obj => obj.#busy, set: (obj, value) => { obj.#busy = value; } }, metadata: _metadata }, _private_busy_initializers, _private_busy_extraInitializers);
|
|
266
|
-
__esDecorate(this, _private_callback_descriptor = { get: __setFunctionName(function () { return this.#callback_accessor_storage; }, "#callback", "get"), set: __setFunctionName(function (value) { this.#callback_accessor_storage = value; }, "#callback", "set") }, _private_callback_decorators, { kind: "accessor", name: "#callback", static: false, private: true, access: { has: obj => #callback in obj, get: obj => obj.#callback, set: (obj, value) => { obj.#callback = value; } }, metadata: _metadata }, _private_callback_initializers, _private_callback_extraInitializers);
|
|
267
|
-
__esDecorate(this, _private_focus_descriptor = { get: __setFunctionName(function () { return this.#focus_accessor_storage; }, "#focus", "get"), set: __setFunctionName(function (value) { this.#focus_accessor_storage = value; }, "#focus", "set") }, _private_focus_decorators, { kind: "accessor", name: "#focus", static: false, private: true, access: { has: obj => #focus in obj, get: obj => obj.#focus, set: (obj, value) => { obj.#focus = value; } }, metadata: _metadata }, _private_focus_initializers, _private_focus_extraInitializers);
|
|
268
|
-
__esDecorate(this, _private_oauthWaiting_descriptor = { get: __setFunctionName(function () { return this.#oauthWaiting_accessor_storage; }, "#oauthWaiting", "get"), set: __setFunctionName(function (value) { this.#oauthWaiting_accessor_storage = value; }, "#oauthWaiting", "set") }, _private_oauthWaiting_decorators, { kind: "accessor", name: "#oauthWaiting", static: false, private: true, access: { has: obj => #oauthWaiting in obj, get: obj => obj.#oauthWaiting, set: (obj, value) => { obj.#oauthWaiting = value; } }, metadata: _metadata }, _private_oauthWaiting_initializers, _private_oauthWaiting_extraInitializers);
|
|
269
|
-
__esDecorate(this, _private_processing_descriptor = { get: __setFunctionName(function () { return this.#processing_accessor_storage; }, "#processing", "get"), set: __setFunctionName(function (value) { this.#processing_accessor_storage = value; }, "#processing", "set") }, _private_processing_decorators, { kind: "accessor", name: "#processing", static: false, private: true, access: { has: obj => #processing in obj, get: obj => obj.#processing, set: (obj, value) => { obj.#processing = value; } }, metadata: _metadata }, _private_processing_initializers, _private_processing_extraInitializers);
|
|
270
|
-
__esDecorate(this, _private_coverDraft_descriptor = { get: __setFunctionName(function () { return this.#coverDraft_accessor_storage; }, "#coverDraft", "get"), set: __setFunctionName(function (value) { this.#coverDraft_accessor_storage = value; }, "#coverDraft", "set") }, _private_coverDraft_decorators, { kind: "accessor", name: "#coverDraft", static: false, private: true, access: { has: obj => #coverDraft in obj, get: obj => obj.#coverDraft, set: (obj, value) => { obj.#coverDraft = value; } }, metadata: _metadata }, _private_coverDraft_initializers, _private_coverDraft_extraInitializers);
|
|
271
|
-
__esDecorate(this, _private_coverThrottle_descriptor = { get: __setFunctionName(function () { return this.#coverThrottle_accessor_storage; }, "#coverThrottle", "get"), set: __setFunctionName(function (value) { this.#coverThrottle_accessor_storage = value; }, "#coverThrottle", "set") }, _private_coverThrottle_decorators, { kind: "accessor", name: "#coverThrottle", static: false, private: true, access: { has: obj => #coverThrottle in obj, get: obj => obj.#coverThrottle, set: (obj, value) => { obj.#coverThrottle = value; } }, metadata: _metadata }, _private_coverThrottle_initializers, _private_coverThrottle_extraInitializers);
|
|
272
|
-
__esDecorate(this, _private_coverConfirmLive_descriptor = { get: __setFunctionName(function () { return this.#coverConfirmLive_accessor_storage; }, "#coverConfirmLive", "get"), set: __setFunctionName(function (value) { this.#coverConfirmLive_accessor_storage = value; }, "#coverConfirmLive", "set") }, _private_coverConfirmLive_decorators, { kind: "accessor", name: "#coverConfirmLive", static: false, private: true, access: { has: obj => #coverConfirmLive in obj, get: obj => obj.#coverConfirmLive, set: (obj, value) => { obj.#coverConfirmLive = value; } }, metadata: _metadata }, _private_coverConfirmLive_initializers, _private_coverConfirmLive_extraInitializers);
|
|
273
|
-
__esDecorate(this, _private_ackPick_descriptor = { get: __setFunctionName(function () { return this.#ackPick_accessor_storage; }, "#ackPick", "get"), set: __setFunctionName(function (value) { this.#ackPick_accessor_storage = value; }, "#ackPick", "set") }, _private_ackPick_decorators, { kind: "accessor", name: "#ackPick", static: false, private: true, access: { has: obj => #ackPick in obj, get: obj => obj.#ackPick, set: (obj, value) => { obj.#ackPick = value; } }, metadata: _metadata }, _private_ackPick_initializers, _private_ackPick_extraInitializers);
|
|
274
|
-
__esDecorate(this, _private_askHold_descriptor = { get: __setFunctionName(function () { return this.#askHold_accessor_storage; }, "#askHold", "get"), set: __setFunctionName(function (value) { this.#askHold_accessor_storage = value; }, "#askHold", "set") }, _private_askHold_decorators, { kind: "accessor", name: "#askHold", static: false, private: true, access: { has: obj => #askHold in obj, get: obj => obj.#askHold, set: (obj, value) => { obj.#askHold = value; } }, metadata: _metadata }, _private_askHold_initializers, _private_askHold_extraInitializers);
|
|
275
|
-
__esDecorate(this, _private_drainAsk_descriptor = { get: __setFunctionName(function () { return this.#drainAsk_accessor_storage; }, "#drainAsk", "get"), set: __setFunctionName(function (value) { this.#drainAsk_accessor_storage = value; }, "#drainAsk", "set") }, _private_drainAsk_decorators, { kind: "accessor", name: "#drainAsk", static: false, private: true, access: { has: obj => #drainAsk in obj, get: obj => obj.#drainAsk, set: (obj, value) => { obj.#drainAsk = value; } }, metadata: _metadata }, _private_drainAsk_initializers, _private_drainAsk_extraInitializers);
|
|
276
|
-
__esDecorate(this, _private_agentsOpen_descriptor = { get: __setFunctionName(function () { return this.#agentsOpen_accessor_storage; }, "#agentsOpen", "get"), set: __setFunctionName(function (value) { this.#agentsOpen_accessor_storage = value; }, "#agentsOpen", "set") }, _private_agentsOpen_decorators, { kind: "accessor", name: "#agentsOpen", static: false, private: true, access: { has: obj => #agentsOpen in obj, get: obj => obj.#agentsOpen, set: (obj, value) => { obj.#agentsOpen = value; } }, metadata: _metadata }, _private_agentsOpen_initializers, _private_agentsOpen_extraInitializers);
|
|
277
|
-
__esDecorate(this, _private_agentsFocus_descriptor = { get: __setFunctionName(function () { return this.#agentsFocus_accessor_storage; }, "#agentsFocus", "get"), set: __setFunctionName(function (value) { this.#agentsFocus_accessor_storage = value; }, "#agentsFocus", "set") }, _private_agentsFocus_decorators, { kind: "accessor", name: "#agentsFocus", static: false, private: true, access: { has: obj => #agentsFocus in obj, get: obj => obj.#agentsFocus, set: (obj, value) => { obj.#agentsFocus = value; } }, metadata: _metadata }, _private_agentsFocus_initializers, _private_agentsFocus_extraInitializers);
|
|
278
|
-
__esDecorate(this, _private_agentsHover_descriptor = { get: __setFunctionName(function () { return this.#agentsHover_accessor_storage; }, "#agentsHover", "get"), set: __setFunctionName(function (value) { this.#agentsHover_accessor_storage = value; }, "#agentsHover", "set") }, _private_agentsHover_decorators, { kind: "accessor", name: "#agentsHover", static: false, private: true, access: { has: obj => #agentsHover in obj, get: obj => obj.#agentsHover, set: (obj, value) => { obj.#agentsHover = value; } }, metadata: _metadata }, _private_agentsHover_initializers, _private_agentsHover_extraInitializers);
|
|
279
|
-
__esDecorate(this, _private_agentsScroll_descriptor = { get: __setFunctionName(function () { return this.#agentsScroll_accessor_storage; }, "#agentsScroll", "get"), set: __setFunctionName(function (value) { this.#agentsScroll_accessor_storage = value; }, "#agentsScroll", "set") }, _private_agentsScroll_decorators, { kind: "accessor", name: "#agentsScroll", static: false, private: true, access: { has: obj => #agentsScroll in obj, get: obj => obj.#agentsScroll, set: (obj, value) => { obj.#agentsScroll = value; } }, metadata: _metadata }, _private_agentsScroll_initializers, _private_agentsScroll_extraInitializers);
|
|
280
|
-
__esDecorate(this, _private_agentsPreview_descriptor = { get: __setFunctionName(function () { return this.#agentsPreview_accessor_storage; }, "#agentsPreview", "get"), set: __setFunctionName(function (value) { this.#agentsPreview_accessor_storage = value; }, "#agentsPreview", "set") }, _private_agentsPreview_decorators, { kind: "accessor", name: "#agentsPreview", static: false, private: true, access: { has: obj => #agentsPreview in obj, get: obj => obj.#agentsPreview, set: (obj, value) => { obj.#agentsPreview = value; } }, metadata: _metadata }, _private_agentsPreview_initializers, _private_agentsPreview_extraInitializers);
|
|
281
|
-
__esDecorate(this, _private_peekPlexus_descriptor = { get: __setFunctionName(function () { return this.#peekPlexus_accessor_storage; }, "#peekPlexus", "get"), set: __setFunctionName(function (value) { this.#peekPlexus_accessor_storage = value; }, "#peekPlexus", "set") }, _private_peekPlexus_decorators, { kind: "accessor", name: "#peekPlexus", static: false, private: true, access: { has: obj => #peekPlexus in obj, get: obj => obj.#peekPlexus, set: (obj, value) => { obj.#peekPlexus = value; } }, metadata: _metadata }, _private_peekPlexus_initializers, _private_peekPlexus_extraInitializers);
|
|
282
|
-
__esDecorate(this, _private_askPlexus_descriptor = { get: __setFunctionName(function () { return this.#askPlexus_accessor_storage; }, "#askPlexus", "get"), set: __setFunctionName(function (value) { this.#askPlexus_accessor_storage = value; }, "#askPlexus", "set") }, _private_askPlexus_decorators, { kind: "accessor", name: "#askPlexus", static: false, private: true, access: { has: obj => #askPlexus in obj, get: obj => obj.#askPlexus, set: (obj, value) => { obj.#askPlexus = value; } }, metadata: _metadata }, _private_askPlexus_initializers, _private_askPlexus_extraInitializers);
|
|
283
|
-
__esDecorate(this, _private_viewPin_descriptor = { get: __setFunctionName(function () { return this.#viewPin_accessor_storage; }, "#viewPin", "get"), set: __setFunctionName(function (value) { this.#viewPin_accessor_storage = value; }, "#viewPin", "set") }, _private_viewPin_decorators, { kind: "accessor", name: "#viewPin", static: false, private: true, access: { has: obj => #viewPin in obj, get: obj => obj.#viewPin, set: (obj, value) => { obj.#viewPin = value; } }, metadata: _metadata }, _private_viewPin_initializers, _private_viewPin_extraInitializers);
|
|
284
|
-
__esDecorate(this, _private_historyNav_descriptor = { get: __setFunctionName(function () { return this.#historyNav_accessor_storage; }, "#historyNav", "get"), set: __setFunctionName(function (value) { this.#historyNav_accessor_storage = value; }, "#historyNav", "set") }, _private_historyNav_decorators, { kind: "accessor", name: "#historyNav", static: false, private: true, access: { has: obj => #historyNav in obj, get: obj => obj.#historyNav, set: (obj, value) => { obj.#historyNav = value; } }, metadata: _metadata }, _private_historyNav_initializers, _private_historyNav_extraInitializers);
|
|
285
|
-
__esDecorate(this, _private_restoredDraft_descriptor = { get: __setFunctionName(function () { return this.#restoredDraft_accessor_storage; }, "#restoredDraft", "get"), set: __setFunctionName(function (value) { this.#restoredDraft_accessor_storage = value; }, "#restoredDraft", "set") }, _private_restoredDraft_decorators, { kind: "accessor", name: "#restoredDraft", static: false, private: true, access: { has: obj => #restoredDraft in obj, get: obj => obj.#restoredDraft, set: (obj, value) => { obj.#restoredDraft = value; } }, metadata: _metadata }, _private_restoredDraft_initializers, _private_restoredDraft_extraInitializers);
|
|
286
|
-
__esDecorate(this, _private_get_agentDrawerRows_descriptor = { get: __setFunctionName(function () {
|
|
287
|
-
return flattenAgentDrawer(projectAgentDrawer(this.client));
|
|
288
|
-
}, "#agentDrawerRows", "get") }, _private_get_agentDrawerRows_decorators, { kind: "getter", name: "#agentDrawerRows", static: false, private: true, access: { has: obj => #agentDrawerRows in obj, get: obj => obj.#agentDrawerRows }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
289
|
-
__esDecorate(this, _private_get_sessionTitle_descriptor = { get: __setFunctionName(function () {
|
|
290
|
-
return (this.client.sessionRoot.manualTitle.trim() ||
|
|
291
|
-
resolvedTip(this.client.sessionRoot.head, this.client.sessionRoot.tip)?.metadata?.title ||
|
|
292
|
-
"");
|
|
293
|
-
}, "#sessionTitle", "get") }, _private_get_sessionTitle_decorators, { kind: "getter", name: "#sessionTitle", static: false, private: true, access: { has: obj => #sessionTitle in obj, get: obj => obj.#sessionTitle }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
294
|
-
__esDecorate(this, _private_get_isHeadAtTip_descriptor = { get: __setFunctionName(function () {
|
|
295
|
-
return isAtTip(this.client.sessionRoot.head, this.client.sessionRoot.tip);
|
|
296
|
-
}, "#isHeadAtTip", "get") }, _private_get_isHeadAtTip_decorators, { kind: "getter", name: "#isHeadAtTip", static: false, private: true, access: { has: obj => #isHeadAtTip in obj, get: obj => obj.#isHeadAtTip }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
297
|
-
__esDecorate(this, _private_get_askHead_descriptor = { get: __setFunctionName(function () {
|
|
298
|
-
const host = this.client.sessionRoot.findRunningTurn()?.approvalHead ?? null;
|
|
299
|
-
if (host != null)
|
|
300
|
-
return host;
|
|
301
|
-
const id = hostAskEscalateSessionId(this.client);
|
|
302
|
-
if (id == null || this.#askPlexus?.root.sessionId !== id)
|
|
303
|
-
return null;
|
|
304
|
-
return this.#askPlexus.root.findRunningTurn()?.approvalHead ?? null;
|
|
305
|
-
}, "#askHead", "get") }, _private_get_askHead_decorators, { kind: "getter", name: "#askHead", static: false, private: true, access: { has: obj => #askHead in obj, get: obj => obj.#askHead }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
306
|
-
__esDecorate(this, _private_get_ackPrompt_descriptor = { get: __setFunctionName(function () {
|
|
307
|
-
const leaf = this.#askHead;
|
|
308
|
-
if (leaf == null)
|
|
309
|
-
return null;
|
|
310
|
-
const variant = ackVariant({
|
|
311
|
-
ackPending: leaf.ackPending,
|
|
312
|
-
policyResult: leaf.policyResult,
|
|
313
|
-
baseDecision: leaf.baseLicenseDetail.decision,
|
|
314
|
-
});
|
|
315
|
-
if (variant === null)
|
|
316
|
-
return null;
|
|
317
|
-
return ackPromptModel({
|
|
318
|
-
variant,
|
|
319
|
-
flags: leaf.ackFlags,
|
|
320
|
-
options: leaf.ackOptions,
|
|
321
|
-
bot: this.#askHome.agent.spec.name.trim() !== "",
|
|
322
|
-
});
|
|
323
|
-
}, "#ackPrompt", "get") }, _private_get_ackPrompt_decorators, { kind: "getter", name: "#ackPrompt", static: false, private: true, access: { has: obj => #ackPrompt in obj, get: obj => obj.#ackPrompt }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
324
|
-
__esDecorate(this, _private_get_coverAskAgentSpec_descriptor = { get: __setFunctionName(function () {
|
|
325
|
-
const leaf = this.#askHead;
|
|
326
|
-
if (leaf == null)
|
|
327
|
-
return undefined;
|
|
328
|
-
if (this.client.sessionRoot.findRunningTurn()?.approvalHead === leaf)
|
|
329
|
-
return undefined;
|
|
330
|
-
const id = hostAskEscalateSessionId(this.client);
|
|
331
|
-
if (id == null)
|
|
332
|
-
return undefined;
|
|
333
|
-
for (const agent of this.client.agents) {
|
|
334
|
-
if (agent.sessionId === id)
|
|
335
|
-
return agent.specName;
|
|
336
|
-
}
|
|
337
|
-
return "";
|
|
338
|
-
}, "#coverAskAgentSpec", "get") }, _private_get_coverAskAgentSpec_decorators, { kind: "getter", name: "#coverAskAgentSpec", static: false, private: true, access: { has: obj => #coverAskAgentSpec in obj, get: obj => obj.#coverAskAgentSpec }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
339
|
-
__esDecorate(this, _private_get_askHome_descriptor = { get: __setFunctionName(function () {
|
|
340
|
-
const host = this.client.sessionRoot;
|
|
341
|
-
if (host.findRunningTurn()?.approvalHead != null)
|
|
342
|
-
return host;
|
|
343
|
-
const id = hostAskEscalateSessionId(this.client);
|
|
344
|
-
if (id != null && this.#askPlexus?.root.sessionId === id)
|
|
345
|
-
return this.#askPlexus.root;
|
|
346
|
-
return host;
|
|
347
|
-
}, "#askHome", "get") }, _private_get_askHome_decorators, { kind: "getter", name: "#askHome", static: false, private: true, access: { has: obj => #askHome in obj, get: obj => obj.#askHome }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
348
|
-
__esDecorate(this, _private_get_readWiden_descriptor = { get: __setFunctionName(function () {
|
|
349
|
-
const leaf = this.#askHead;
|
|
350
|
-
if (!(leaf instanceof ToolCallJob))
|
|
351
|
-
return undefined;
|
|
352
|
-
const root = this.#askHome;
|
|
353
|
-
const prepared = fileReadPreparedPath(root.path, leaf.name, leaf.args);
|
|
354
|
-
if (prepared === undefined)
|
|
355
|
-
return undefined;
|
|
356
|
-
// Evidence is another outside read in flight, or a folder already treated as part of this session.
|
|
357
|
-
const observed = Object.keys(root.readRoots);
|
|
358
|
-
const turn = root.findRunningTurn();
|
|
359
|
-
for (const job of turn?.approvalLeaves ?? []) {
|
|
360
|
-
if (!(job instanceof ToolCallJob) || job === leaf)
|
|
361
|
-
continue;
|
|
362
|
-
const path = fileReadPreparedPath(root.path, job.name, job.args);
|
|
363
|
-
if (path !== undefined)
|
|
364
|
-
observed.push(path);
|
|
365
|
-
}
|
|
366
|
-
return fileReadWiden(root.path, prepared, observed);
|
|
367
|
-
}, "#readWiden", "get") }, _private_get_readWiden_decorators, { kind: "getter", name: "#readWiden", static: false, private: true, access: { has: obj => #readWiden in obj, get: obj => obj.#readWiden }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
368
|
-
__esDecorate(this, _private_get_omniboxValue_descriptor = { get: __setFunctionName(function () {
|
|
369
|
-
const overlay = this.#callback?.surface;
|
|
370
|
-
const leaf = this.#askHead;
|
|
371
|
-
const running = this.client.sessionRoot.findRunningTurn();
|
|
372
|
-
let overlayBag = null;
|
|
373
|
-
if (overlay !== undefined) {
|
|
374
|
-
const message = overlay.description === "" ? overlay.name : overlay.description;
|
|
375
|
-
const url = urlFrom(overlay);
|
|
376
|
-
const overlayText = url === undefined || message.includes(url) ? message : message === "" ? url : `${message}\n${url}`;
|
|
377
|
-
const overlayAsBody = !hasInputHole(overlay) && url === undefined;
|
|
378
|
-
const instructional = this.#inputting && (url !== undefined || overlay.description.trim() !== "");
|
|
379
|
-
overlayBag = {
|
|
380
|
-
body: overlayAsBody ? overlayText : undefined,
|
|
381
|
-
placeholder: overlayAsBody || this.#oauthWaiting || instructional ? undefined : overlayText,
|
|
382
|
-
secret: overlay.secret === true,
|
|
383
|
-
inputting: this.#inputting,
|
|
384
|
-
processing: this.#processing,
|
|
385
|
-
commandChoices: this.#commandChoices,
|
|
386
|
-
commandAction: this.#commandAction,
|
|
387
|
-
selectedCommandKey: this.effectiveKey,
|
|
388
|
-
};
|
|
389
|
-
}
|
|
390
|
-
const slash = overlay !== undefined || this.#pickerRows === undefined
|
|
391
|
-
? null
|
|
392
|
-
: {
|
|
393
|
-
commandChoices: this.#commandChoices,
|
|
394
|
-
commandAction: this.#commandAction,
|
|
395
|
-
selectedCommandKey: this.effectiveKey,
|
|
396
|
-
};
|
|
397
|
-
const widen = this.#readWiden;
|
|
398
|
-
const model = nonempty(this.client.sessionRoot.kvs.model);
|
|
399
|
-
const asked = coverAskAnnotation(leaf, {
|
|
400
|
-
model,
|
|
401
|
-
kernel: this.client.kernelRoot,
|
|
402
|
-
agentSpec: this.#coverAskAgentSpec,
|
|
403
|
-
});
|
|
404
|
-
const mcpDeny = leaf instanceof MCPToolJob && mcpReadFloorDenies(leaf.serverToolName);
|
|
405
|
-
const ack = this.#ackPrompt;
|
|
406
|
-
const ackChoice = ack?.choices[this.#ackIndex];
|
|
407
|
-
const ask = leaf === null
|
|
408
|
-
? null
|
|
409
|
-
: {
|
|
410
|
-
armed: this.#coverConfirmLive,
|
|
411
|
-
// The daemon's offer for this exact call: a family for an ask, nothing for a soft-deny.
|
|
412
|
-
...(leaf.grantOptions.length === 0 ? {} : { remember: leaf.grantOptions[0].label }),
|
|
413
|
-
persistDeny: mcpDeny,
|
|
414
|
-
caution: leaf.policyResult === "deny",
|
|
415
|
-
tier: leaf.policyResult === "deny" ? "Soft-deny" : "Ask",
|
|
416
|
-
classLabels: leaf.policyClasses.map((id) => CLASSES[id].label),
|
|
417
|
-
...(leaf.judgeReason == null || leaf.classifierResult === null
|
|
418
|
-
? {}
|
|
419
|
-
: { judgeLine: `Judge: ${leaf.judgeReason}` }),
|
|
420
|
-
widen: widen?.label,
|
|
421
|
-
...(ack === null
|
|
422
|
-
? {}
|
|
423
|
-
: {
|
|
424
|
-
ack: {
|
|
425
|
-
variant: ack.variant,
|
|
426
|
-
...(ackChoice === undefined ? {} : { choice: ackChoice.text }),
|
|
427
|
-
cycle: ack.choices.length > 1,
|
|
428
|
-
},
|
|
429
|
-
}),
|
|
430
|
-
annotation: askAnnotation(leaf, asked, widen, ack ?? undefined),
|
|
431
|
-
...askStack(leaf, this.rows, this.client.kernelRoot.bots),
|
|
432
|
-
};
|
|
433
|
-
return {
|
|
434
|
-
draft: {
|
|
435
|
-
draft: this.draft.draft,
|
|
436
|
-
cursor: this.draft.cursor,
|
|
437
|
-
mark: this.draft.mark,
|
|
438
|
-
},
|
|
439
|
-
cover: {
|
|
440
|
-
draft: this.#coverDraft.draft,
|
|
441
|
-
cursor: this.#coverDraft.cursor,
|
|
442
|
-
mark: this.#coverDraft.mark,
|
|
443
|
-
},
|
|
444
|
-
ask,
|
|
445
|
-
slash,
|
|
446
|
-
overlay: overlayBag,
|
|
447
|
-
auth: this.#oauthWaiting ? { waiting: true } : null,
|
|
448
|
-
queue: running == null
|
|
449
|
-
? null
|
|
450
|
-
: {
|
|
451
|
-
stackedBody: this.#admissionDeckText,
|
|
452
|
-
queued: this.client.sessionRoot.promptQueue.length,
|
|
453
|
-
running: true,
|
|
454
|
-
},
|
|
455
|
-
busy: this.#busy,
|
|
456
|
-
escClearArmed: this.escClearArmed,
|
|
457
|
-
lastTurnIncomplete: this.client.sessionRoot.lastTurnIncomplete,
|
|
458
|
-
atTip: !this.#browsing() && this.#isHeadAtTip,
|
|
459
|
-
restoredDraft: this.#untouchedRestoredDraft,
|
|
460
|
-
retainedHistory: !this.#browsing() && !this.#isHeadAtTip,
|
|
461
|
-
sessionTitle: this.#sessionTitle,
|
|
462
|
-
retrying: isRetrying(running, this.#now()),
|
|
463
|
-
superKey: this.#superKey,
|
|
464
|
-
errorAnnotation: this.#errorAnnotation() ?? null,
|
|
465
|
-
statusItems: this.#statusItems,
|
|
466
|
-
quotaWindows: this.#quotaWindows,
|
|
467
|
-
...this.#contextRail,
|
|
468
|
-
scrollOffset: this.scrollOffset,
|
|
469
|
-
};
|
|
470
|
-
}, "#omniboxValue", "get") }, _private_get_omniboxValue_decorators, { kind: "getter", name: "#omniboxValue", static: false, private: true, access: { has: obj => #omniboxValue in obj, get: obj => obj.#omniboxValue }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
471
|
-
__esDecorate(this, _private_get_contextRail_descriptor = { get: __setFunctionName(function () {
|
|
472
|
-
const glowAt = parseCompactTrigger(this.client.kernelRoot.contextGlowRemaining) ??
|
|
473
|
-
parseCompactTrigger(DEFAULT_CONTEXT_GLOW_REMAINING) ??
|
|
474
|
-
0.75;
|
|
475
|
-
const liveModel = nonempty(this.client.sessionRoot.kvs.model);
|
|
476
|
-
const catalogLimit = catalogContextLimit(this.#activeConnection, liveModel);
|
|
477
|
-
const head = this.client.sessionRoot.head;
|
|
478
|
-
if (head instanceof SessionTurn) {
|
|
479
|
-
// A model switch moves the window before the next round reports it —
|
|
480
|
-
// the tape still carries the prior model's stamp (empty until a round
|
|
481
|
-
// names one). Re-base on the live model's catalog window so the rail
|
|
482
|
-
// follows the switch immediately; the tape's own stamp takes over again
|
|
483
|
-
// once a round re-measures it. A stale window beats none.
|
|
484
|
-
const switched = liveModel !== "" && head.contextModel !== liveModel;
|
|
485
|
-
const limit = switched ? catalogLimit || head.contextLimit : head.contextLimit;
|
|
486
|
-
return {
|
|
487
|
-
progress: head.contextRemainingProgress(this.client.kernelRoot.compactTriggers.soft, limit) ?? 0,
|
|
488
|
-
progressGlowAt: glowAt,
|
|
489
|
-
contextUsed: head.contextUsed,
|
|
490
|
-
contextLimit: limit,
|
|
491
|
-
};
|
|
492
|
-
}
|
|
493
|
-
return {
|
|
494
|
-
progress: 0,
|
|
495
|
-
progressGlowAt: glowAt,
|
|
496
|
-
contextUsed: 0,
|
|
497
|
-
contextLimit: catalogLimit,
|
|
498
|
-
};
|
|
499
|
-
}, "#contextRail", "get") }, _private_get_contextRail_decorators, { kind: "getter", name: "#contextRail", static: false, private: true, access: { has: obj => #contextRail in obj, get: obj => obj.#contextRail }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
500
|
-
__esDecorate(this, _private_get_omnibox_descriptor = { get: __setFunctionName(function () {
|
|
501
|
-
return omniboxSeat(this.#omniboxValue);
|
|
502
|
-
}, "#omnibox", "get") }, _private_get_omnibox_decorators, { kind: "getter", name: "#omnibox", static: false, private: true, access: { has: obj => #omnibox in obj, get: obj => obj.#omnibox }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
503
|
-
__esDecorate(this, _private_get_askIsolated_descriptor = { get: __setFunctionName(function () {
|
|
504
|
-
return this.#omnibox.input === "ask";
|
|
505
|
-
}, "#askIsolated", "get") }, _private_get_askIsolated_decorators, { kind: "getter", name: "#askIsolated", static: false, private: true, access: { has: obj => #askIsolated in obj, get: obj => obj.#askIsolated }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
506
|
-
__esDecorate(this, _private_get_admissionDeckText_descriptor = { get: __setFunctionName(function () {
|
|
507
|
-
const lines = [];
|
|
508
|
-
for (const row of this.client.sessionRoot.promptQueue) {
|
|
509
|
-
const text = row.text.trim();
|
|
510
|
-
if (text !== "")
|
|
511
|
-
lines.push(text);
|
|
512
|
-
}
|
|
513
|
-
return lines.join("\n");
|
|
514
|
-
}, "#admissionDeckText", "get") }, _private_get_admissionDeckText_decorators, { kind: "getter", name: "#admissionDeckText", static: false, private: true, access: { has: obj => #admissionDeckText in obj, get: obj => obj.#admissionDeckText }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
515
|
-
__esDecorate(this, _private_get_waitChrome_descriptor = { get: __setFunctionName(function () {
|
|
516
|
-
return waitPhrase({
|
|
517
|
-
seat: () => this.#omnibox.render,
|
|
518
|
-
historyHides: () => this.#historyHidesOmnibox,
|
|
519
|
-
ask: () => this.#askPinFace() != null,
|
|
520
|
-
occupancy: () => {
|
|
521
|
-
const head = this.client.sessionRoot.head;
|
|
522
|
-
return head instanceof SessionTurn && !this.#cancelAsked.has(head) ? emptyWaitChrome(head) : null;
|
|
523
|
-
},
|
|
524
|
-
cancel: () => this.#processing && this.client.sessionRoot.findRunningTurn() != null,
|
|
525
|
-
catalog: () => {
|
|
526
|
-
const connectionId = (this.client.sessionRoot.kvs.connection ?? "").trim();
|
|
527
|
-
const spec = connectionId === "" ? undefined : this.client.kernelRoot.connections[connectionId];
|
|
528
|
-
const models = spec == null ? [] : Array.isArray(spec.live.models) ? spec.live.models : [];
|
|
529
|
-
return { connectionId, readyState: spec?.readyState ?? null, modelCount: models.length };
|
|
530
|
-
},
|
|
531
|
-
slash: () => slashVerb(this.draft.draft),
|
|
532
|
-
error: () => this.#errorAnnotation()?.message ?? "",
|
|
533
|
-
});
|
|
534
|
-
}, "#waitChrome", "get") }, _private_get_waitChrome_decorators, { kind: "getter", name: "#waitChrome", static: false, private: true, access: { has: obj => #waitChrome in obj, get: obj => obj.#waitChrome }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
535
|
-
__esDecorate(this, _private_get_commands_descriptor = { get: __setFunctionName(function () {
|
|
536
|
-
const byVerb = new Map();
|
|
537
|
-
for (const spec of Object.values(this.client.kernelRoot.commands)) {
|
|
538
|
-
if (spec.verb === "" || isHostVerb(spec.verb))
|
|
539
|
-
continue;
|
|
540
|
-
byVerb.set(spec.verb, {
|
|
541
|
-
name: spec.verb,
|
|
542
|
-
description: spec.description === "" ? undefined : spec.description,
|
|
543
|
-
aliases: spec.aliases,
|
|
544
|
-
});
|
|
545
|
-
}
|
|
546
|
-
const compact = this.client.kernelRoot.commands.compact;
|
|
547
|
-
byVerb.set("compact", {
|
|
548
|
-
name: "compact",
|
|
549
|
-
description: compact?.description !== undefined && compact.description !== ""
|
|
550
|
-
? compact.description
|
|
551
|
-
: "Compact conversation context",
|
|
552
|
-
aliases: compact?.aliases,
|
|
553
|
-
});
|
|
554
|
-
const rename = this.client.kernelRoot.commands.rename;
|
|
555
|
-
byVerb.set("rename", {
|
|
556
|
-
name: "rename",
|
|
557
|
-
description: rename?.description !== undefined && rename.description !== ""
|
|
558
|
-
? rename.description
|
|
559
|
-
: "Set or clear the session title",
|
|
560
|
-
aliases: rename?.aliases,
|
|
561
|
-
});
|
|
562
|
-
const minted = this.client.kernelRoot.commands.new;
|
|
563
|
-
byVerb.set("new", {
|
|
564
|
-
name: "new",
|
|
565
|
-
description: minted?.description !== undefined && minted.description !== "" ? minted.description : "Mint a new session",
|
|
566
|
-
aliases: minted?.aliases,
|
|
567
|
-
});
|
|
568
|
-
const quit = this.client.kernelRoot.commands.quit;
|
|
569
|
-
byVerb.set("quit", {
|
|
570
|
-
name: "quit",
|
|
571
|
-
description: quit?.description !== undefined && quit.description !== "" ? quit.description : "Leave the TUI",
|
|
572
|
-
aliases: quit?.aliases,
|
|
573
|
-
});
|
|
574
|
-
const agentic = this.client.kernelRoot.commands.agentic;
|
|
575
|
-
byVerb.set("agentic", {
|
|
576
|
-
name: "agentic",
|
|
577
|
-
description: agentic?.description !== undefined && agentic.description !== ""
|
|
578
|
-
? agentic.description
|
|
579
|
-
: "Keep the session running without a client",
|
|
580
|
-
aliases: agentic?.aliases,
|
|
581
|
-
});
|
|
582
|
-
const background = this.client.kernelRoot.commands.background;
|
|
583
|
-
byVerb.set("background", {
|
|
584
|
-
name: "background",
|
|
585
|
-
description: background?.description !== undefined && background.description !== ""
|
|
586
|
-
? background.description
|
|
587
|
-
: "Keep the session running and leave the TUI",
|
|
588
|
-
aliases: background?.aliases,
|
|
589
|
-
});
|
|
590
|
-
const rewind = this.client.kernelRoot.commands.rewind;
|
|
591
|
-
byVerb.set("rewind", {
|
|
592
|
-
name: "rewind",
|
|
593
|
-
description: rewind?.description !== undefined && rewind.description !== ""
|
|
594
|
-
? rewind.description
|
|
595
|
-
: "Rewind conversation one step; files stay",
|
|
596
|
-
aliases: rewind?.aliases ?? ["undo"],
|
|
597
|
-
});
|
|
598
|
-
const permissions = this.client.kernelRoot.commands.permissions;
|
|
599
|
-
byVerb.set("permissions", {
|
|
600
|
-
name: "permissions",
|
|
601
|
-
description: permissions?.description !== undefined && permissions.description !== ""
|
|
602
|
-
? permissions.description
|
|
603
|
-
: "Mode, grants, acknowledgements; explain a call",
|
|
604
|
-
aliases: permissions?.aliases,
|
|
605
|
-
});
|
|
606
|
-
const skillEscape = new Set();
|
|
607
|
-
for (const skill of this.client.sessionRoot.skills) {
|
|
608
|
-
const verb = skill.invoke === "" ? skill.name : skill.invoke;
|
|
609
|
-
if (verb !== "" && !isHostVerb(verb) && !byVerb.has(verb)) {
|
|
610
|
-
byVerb.set(verb, {
|
|
611
|
-
name: verb,
|
|
612
|
-
description: skill.description === "" ? undefined : skill.description,
|
|
613
|
-
});
|
|
614
|
-
}
|
|
615
|
-
if (skillEscape.has(skill.name))
|
|
616
|
-
continue;
|
|
617
|
-
skillEscape.add(skill.name);
|
|
618
|
-
const escape = `skill:${skill.name}`;
|
|
619
|
-
if (escape === "" || isHostVerb(escape) || byVerb.has(escape))
|
|
620
|
-
continue;
|
|
621
|
-
byVerb.set(escape, {
|
|
622
|
-
name: escape,
|
|
623
|
-
description: skill.description === "" ? undefined : skill.description,
|
|
624
|
-
});
|
|
625
|
-
}
|
|
626
|
-
return [...byVerb.values()];
|
|
627
|
-
}, "#commands", "get") }, _private_get_commands_decorators, { kind: "getter", name: "#commands", static: false, private: true, access: { has: obj => #commands in obj, get: obj => obj.#commands }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
628
|
-
__esDecorate(this, _private_get_parentNode_descriptor = { get: __setFunctionName(function () {
|
|
629
|
-
if (this.#callback !== undefined)
|
|
630
|
-
return this.#callback.surface;
|
|
631
|
-
if (this.#focus !== undefined)
|
|
632
|
-
return this.#focus;
|
|
633
|
-
return this.#commandSurface;
|
|
634
|
-
}, "#parentNode", "get") }, _private_get_parentNode_decorators, { kind: "getter", name: "#parentNode", static: false, private: true, access: { has: obj => #parentNode in obj, get: obj => obj.#parentNode }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
635
|
-
__esDecorate(this, _private_get_inCommand_descriptor = { get: __setFunctionName(function () {
|
|
636
|
-
const verb = slashVerb(this.draft.draft);
|
|
637
|
-
if (verb === null)
|
|
638
|
-
return false;
|
|
639
|
-
if (isHostVerb(verb))
|
|
640
|
-
return true;
|
|
641
|
-
if (this.client.kernelRoot.commands[verb] !== undefined)
|
|
642
|
-
return true;
|
|
643
|
-
return this.#skillVerb(verb);
|
|
644
|
-
}, "#inCommand", "get") }, _private_get_inCommand_decorators, { kind: "getter", name: "#inCommand", static: false, private: true, access: { has: obj => #inCommand in obj, get: obj => obj.#inCommand }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
645
|
-
__esDecorate(this, _private_get_atCatalog_descriptor = { get: __setFunctionName(function () {
|
|
646
|
-
if (this.#parentNode !== undefined)
|
|
647
|
-
return false;
|
|
648
|
-
if (this.#inCommand)
|
|
649
|
-
return false;
|
|
650
|
-
return (this.draft.draft.split("\n")[0] ?? "").trim().startsWith("/");
|
|
651
|
-
}, "#atCatalog", "get") }, _private_get_atCatalog_decorators, { kind: "getter", name: "#atCatalog", static: false, private: true, access: { has: obj => #atCatalog in obj, get: obj => obj.#atCatalog }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
652
|
-
__esDecorate(this, _private_get_pickerRows_descriptor = { get: __setFunctionName(function () {
|
|
653
|
-
if (this.#focus !== undefined) {
|
|
654
|
-
return this.#focus.choices.filter((child) => child.name !== "");
|
|
655
|
-
}
|
|
656
|
-
const parent = this.#parentNode;
|
|
657
|
-
if (parent !== undefined) {
|
|
658
|
-
const verb = slashVerb(this.draft.draft) ?? "";
|
|
659
|
-
const needle = (this.draft.draft.split("\n")[0] ?? "")
|
|
660
|
-
.trim()
|
|
661
|
-
.slice(verb.length + 1)
|
|
662
|
-
.trim()
|
|
663
|
-
.toLowerCase();
|
|
664
|
-
const named = parent.choices.filter((child) => child.name !== "");
|
|
665
|
-
const exact = named.some((child) => child.name.toLowerCase() === needle);
|
|
666
|
-
return named.filter((child) => {
|
|
667
|
-
if (needle === "" || exact)
|
|
668
|
-
return true;
|
|
669
|
-
const hay = [child.name, child.annotation, child.description, child.healthAnnotation, ...child.aliases]
|
|
670
|
-
.join(" ")
|
|
671
|
-
.toLowerCase();
|
|
672
|
-
return hay.includes(needle);
|
|
673
|
-
});
|
|
674
|
-
}
|
|
675
|
-
if (this.#atCatalog)
|
|
676
|
-
return this.#catalogNodes;
|
|
677
|
-
if (this.#inCommand)
|
|
678
|
-
return [];
|
|
679
|
-
return undefined;
|
|
680
|
-
}, "#pickerRows", "get") }, _private_get_pickerRows_decorators, { kind: "getter", name: "#pickerRows", static: false, private: true, access: { has: obj => #pickerRows in obj, get: obj => obj.#pickerRows }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
681
|
-
__esDecorate(this, _private_get_catalogNodes_descriptor = { get: __setFunctionName(function () {
|
|
682
|
-
return matchComposerCommand(this.draft.draft, this.#commands).matches.map((cmd) => new UiNode(cmd.name.replace(/^\//, ""), cmd.description ?? "", cmd.aliases ?? [], "ok", "", undefined, [], [], [], null, {}));
|
|
683
|
-
}, "#catalogNodes", "get") }, _private_get_catalogNodes_decorators, { kind: "getter", name: "#catalogNodes", static: false, private: true, access: { has: obj => #catalogNodes in obj, get: obj => obj.#catalogNodes }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
684
|
-
__esDecorate(this, _private_get_commandChoices_descriptor = { get: __setFunctionName(function () {
|
|
685
|
-
const rows = this.#pickerRows;
|
|
686
|
-
if (rows === undefined)
|
|
687
|
-
return undefined;
|
|
688
|
-
const catalog = this.#atCatalog;
|
|
689
|
-
const parent = this.#focus === undefined ? this.#parentNode : this.#focus;
|
|
690
|
-
const named = parent === undefined ? undefined : parent.choices.filter((child) => child.name !== "");
|
|
691
|
-
return rows.map((node) => {
|
|
692
|
-
const unfilteredIndex = named === undefined ? -1 : named.indexOf(node);
|
|
693
|
-
const name = catalog && !node.name.startsWith("/") ? `/${node.name}` : node.name;
|
|
694
|
-
const annotation = node.annotation.trim();
|
|
695
|
-
const description = node.description.trim();
|
|
696
|
-
const healthAnnotation = node.healthAnnotation.trim();
|
|
697
|
-
return {
|
|
698
|
-
key: catalog ? catalogKey(node.name) : `choice:${unfilteredIndex}:${node.name}`,
|
|
699
|
-
name,
|
|
700
|
-
description: description || healthAnnotation || undefined,
|
|
701
|
-
annotation: annotation === "" ? undefined : annotation,
|
|
702
|
-
status: node.health === "ok" ? undefined : node.health,
|
|
703
|
-
actionDisplayName: primaryDisplayName(node) ?? (isActivatable(node, catalog) ? "select" : undefined),
|
|
704
|
-
actions: pickerActions(node, catalog),
|
|
705
|
-
};
|
|
706
|
-
});
|
|
707
|
-
}, "#commandChoices", "get") }, _private_get_commandChoices_decorators, { kind: "getter", name: "#commandChoices", static: false, private: true, access: { has: obj => #commandChoices in obj, get: obj => obj.#commandChoices }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
708
|
-
__esDecorate(this, null, _get_effectiveKey_decorators, { kind: "getter", name: "effectiveKey", static: false, private: false, access: { has: obj => "effectiveKey" in obj, get: obj => obj.effectiveKey }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
709
|
-
__esDecorate(this, _private_get_commandAction_descriptor = { get: __setFunctionName(function () {
|
|
710
|
-
const surface = this.#parentNode;
|
|
711
|
-
if (surface === undefined)
|
|
712
|
-
return undefined;
|
|
713
|
-
const row = surface.description.trim() === ""
|
|
714
|
-
? (primaryDisplayName(surface) ??
|
|
715
|
-
(surface.action[0]?.name === "" ? "select" : (surface.action[0]?.name ?? surface.name)))
|
|
716
|
-
: surface.description;
|
|
717
|
-
if (this.#processing) {
|
|
718
|
-
return { name: row, displayName: row, actions: [], href: urlFrom(surface) };
|
|
719
|
-
}
|
|
720
|
-
const actions = this.#oauthWaiting
|
|
721
|
-
? pickerActions(surface).filter((item) => item.hotkey?.toLowerCase() === "escape")
|
|
722
|
-
: pickerActions(surface);
|
|
723
|
-
if (actions.length === 0)
|
|
724
|
-
return undefined;
|
|
725
|
-
return {
|
|
726
|
-
name: row,
|
|
727
|
-
displayName: row,
|
|
728
|
-
actions,
|
|
729
|
-
href: urlFrom(surface),
|
|
730
|
-
};
|
|
731
|
-
}, "#commandAction", "get") }, _private_get_commandAction_decorators, { kind: "getter", name: "#commandAction", static: false, private: true, access: { has: obj => #commandAction in obj, get: obj => obj.#commandAction }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
732
|
-
__esDecorate(this, _private_get_commandSurface_descriptor = { get: __setFunctionName(function () {
|
|
733
|
-
if (this.#callback !== undefined)
|
|
734
|
-
return this.#callback.surface;
|
|
735
|
-
const verb = slashVerb(this.draft.draft);
|
|
736
|
-
if (verb === null)
|
|
737
|
-
return undefined;
|
|
738
|
-
const body = this.client.kernelRoot.commands[verb]?.body;
|
|
739
|
-
if (body === undefined || body === "")
|
|
740
|
-
return undefined;
|
|
741
|
-
const surface = this.#execFor(verb, body, this.client.kernelRoot).get();
|
|
742
|
-
if (verb === "model")
|
|
743
|
-
this.#noteModelEval(surface);
|
|
744
|
-
return surface instanceof UiNode ? surface : undefined;
|
|
745
|
-
}, "#commandSurface", "get") }, _private_get_commandSurface_decorators, { kind: "getter", name: "#commandSurface", static: false, private: true, access: { has: obj => #commandSurface in obj, get: obj => obj.#commandSurface }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
746
|
-
__esDecorate(this, _private_get_selectedIndex_descriptor = { get: __setFunctionName(function () {
|
|
747
|
-
const keyed = this.#commandChoices;
|
|
748
|
-
if (keyed === undefined || keyed.length === 0)
|
|
749
|
-
return 0;
|
|
750
|
-
const i = keyed.findIndex((row) => row.key === this.effectiveKey);
|
|
751
|
-
return Math.max(i, 0);
|
|
752
|
-
}, "#selectedIndex", "get") }, _private_get_selectedIndex_decorators, { kind: "getter", name: "#selectedIndex", static: false, private: true, access: { has: obj => #selectedIndex in obj, get: obj => obj.#selectedIndex }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
753
|
-
__esDecorate(this, null, _focusAt_decorators, { kind: "method", name: "focusAt", static: false, private: false, access: { has: obj => "focusAt" in obj, get: obj => obj.focusAt }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
754
|
-
__esDecorate(this, null, _handle_decorators, { kind: "method", name: "handle", static: false, private: false, access: { has: obj => "handle" in obj, get: obj => obj.handle }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
755
|
-
__esDecorate(this, _private_get_activeConnection_descriptor = { get: __setFunctionName(function () {
|
|
756
|
-
const connectionId = (this.client.sessionRoot.kvs.connection ?? "").trim();
|
|
757
|
-
return connectionId === "" ? undefined : this.client.kernelRoot.connections[connectionId];
|
|
758
|
-
}, "#activeConnection", "get") }, _private_get_activeConnection_decorators, { kind: "getter", name: "#activeConnection", static: false, private: true, access: { has: obj => #activeConnection in obj, get: obj => obj.#activeConnection }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
759
|
-
__esDecorate(this, _private_get_quotaWindows_descriptor = { get: __setFunctionName(function () {
|
|
760
|
-
return quotaWindowsOf(this.#activeConnection);
|
|
761
|
-
}, "#quotaWindows", "get") }, _private_get_quotaWindows_decorators, { kind: "getter", name: "#quotaWindows", static: false, private: true, access: { has: obj => #quotaWindows in obj, get: obj => obj.#quotaWindows }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
762
|
-
__esDecorate(this, _private_get_statusItems_descriptor = { get: __setFunctionName(function () {
|
|
763
|
-
const session = this.client.sessionRoot;
|
|
764
|
-
const kvs = session.kvs;
|
|
765
|
-
const model = (kvs.model ?? "").trim();
|
|
766
|
-
const connectionId = (kvs.connection ?? "").trim();
|
|
767
|
-
const connection = this.#activeConnection;
|
|
768
|
-
const provider = nonempty(typeof connection?.live?.catalogName === "string" ? connection.live.catalogName.trim() : "") ||
|
|
769
|
-
nonempty(connection?.name) ||
|
|
770
|
-
nonempty(connection?.driver?.name) ||
|
|
771
|
-
connectionId;
|
|
772
|
-
const items = [];
|
|
773
|
-
if (model !== "")
|
|
774
|
-
items.push(model);
|
|
775
|
-
if (provider !== "")
|
|
776
|
-
items.push(provider);
|
|
777
|
-
const chip = policyChip(session);
|
|
778
|
-
if (chip !== null)
|
|
779
|
-
items.push(chip);
|
|
780
|
-
return items.length > 0 ? items : undefined;
|
|
781
|
-
}, "#statusItems", "get") }, _private_get_statusItems_decorators, { kind: "getter", name: "#statusItems", static: false, private: true, access: { has: obj => #statusItems in obj, get: obj => obj.#statusItems }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
782
|
-
__esDecorate(this, _private_stepCoverThrottle_descriptor = { value: __setFunctionName(function () {
|
|
783
|
-
const leaf = this.#askHead;
|
|
784
|
-
const pendingLeafId = askLeafId(leaf);
|
|
785
|
-
const now = this.#now();
|
|
786
|
-
if (pendingLeafId === null) {
|
|
787
|
-
if (!this.#askHold && !this.#drainAsk) {
|
|
788
|
-
this.#coverThrottle = { episodeFrom: null, armedUntil: 0 };
|
|
789
|
-
}
|
|
790
|
-
this.#coverConfirmLive = false;
|
|
791
|
-
}
|
|
792
|
-
else {
|
|
793
|
-
if (this.#coverThrottle.episodeFrom === null) {
|
|
794
|
-
const throttleMs = Math.max(0, this.client.kernelRoot.approvalAskThrottleMs);
|
|
795
|
-
this.#coverThrottle = {
|
|
796
|
-
episodeFrom: pendingLeafId,
|
|
797
|
-
armedUntil: this.draft.draft.trim() !== "" && throttleMs > 0 ? now + throttleMs : 0,
|
|
798
|
-
};
|
|
799
|
-
}
|
|
800
|
-
this.#coverConfirmLive = now >= this.#coverThrottle.armedUntil;
|
|
801
|
-
}
|
|
802
|
-
if (this.#coverTimer !== undefined) {
|
|
803
|
-
clearTimeout(this.#coverTimer);
|
|
804
|
-
this.#coverTimer = undefined;
|
|
805
|
-
}
|
|
806
|
-
if (leaf === null) {
|
|
807
|
-
this.#coverDraft = { draft: "", cursor: 0, mark: null };
|
|
808
|
-
return;
|
|
809
|
-
}
|
|
810
|
-
if (!this.#coverConfirmLive && this.#coverThrottle.armedUntil > this.#now()) {
|
|
811
|
-
const wait = this.#coverThrottle.armedUntil - this.#now();
|
|
812
|
-
this.#coverTimer = setTimeout(() => {
|
|
813
|
-
runInAction(() => this.#stepCoverThrottle());
|
|
814
|
-
}, wait);
|
|
815
|
-
}
|
|
816
|
-
}, "#stepCoverThrottle") }, _private_stepCoverThrottle_decorators, { kind: "method", name: "#stepCoverThrottle", static: false, private: true, access: { has: obj => #stepCoverThrottle in obj, get: obj => obj.#stepCoverThrottle }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
817
|
-
__esDecorate(this, _private_get_attentionSubjects_descriptor = { get: __setFunctionName(function () {
|
|
818
|
-
const rows = this.#pickerRows;
|
|
819
|
-
if (rows === undefined)
|
|
820
|
-
return [];
|
|
821
|
-
const { connections, drivers } = this.client.kernelRoot;
|
|
822
|
-
const out = new Set();
|
|
823
|
-
for (const node of rows) {
|
|
824
|
-
for (const leaf of node.action) {
|
|
825
|
-
const spec = leaf.op === "kv/set" && leaf.params.key === "connection"
|
|
826
|
-
? connections[paramString(leaf.params.value)]
|
|
827
|
-
: leaf.op === "connect/adopt"
|
|
828
|
-
? drivers[paramString(leaf.params.driver)]
|
|
829
|
-
: undefined;
|
|
830
|
-
if (spec === undefined)
|
|
831
|
-
continue;
|
|
832
|
-
out.add(spec);
|
|
833
|
-
break;
|
|
834
|
-
}
|
|
835
|
-
}
|
|
836
|
-
return [...out];
|
|
837
|
-
}, "#attentionSubjects", "get") }, _private_get_attentionSubjects_decorators, { kind: "getter", name: "#attentionSubjects", static: false, private: true, access: { has: obj => #attentionSubjects in obj, get: obj => obj.#attentionSubjects }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
838
|
-
if (_metadata) Object.defineProperty(this, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
839
|
-
}
|
|
840
|
-
client = __runInitializers(this, _instanceExtraInitializers);
|
|
841
|
-
post;
|
|
842
|
-
#draft_accessor_storage = __runInitializers(this, _draft_initializers, { draft: "", cursor: 0, mark: null });
|
|
843
|
-
get draft() { return this.#draft_accessor_storage; }
|
|
844
|
-
set draft(value) { this.#draft_accessor_storage = value; }
|
|
845
|
-
#submission_accessor_storage = (__runInitializers(this, _draft_extraInitializers), __runInitializers(this, _submission_initializers, null));
|
|
846
|
-
/** Last honest submit. Parts and command stay apart; the string draft is typing only. */
|
|
847
|
-
get submission() { return this.#submission_accessor_storage; }
|
|
848
|
-
set submission(value) { this.#submission_accessor_storage = value; }
|
|
849
|
-
#selectedCommandKey_accessor_storage = (__runInitializers(this, _submission_extraInitializers), __runInitializers(this, _selectedCommandKey_initializers, null));
|
|
850
|
-
get selectedCommandKey() { return this.#selectedCommandKey_accessor_storage; }
|
|
851
|
-
set selectedCommandKey(value) { this.#selectedCommandKey_accessor_storage = value; }
|
|
852
|
-
#scrollOffset_accessor_storage = (__runInitializers(this, _selectedCommandKey_extraInitializers), __runInitializers(this, _scrollOffset_initializers, 0));
|
|
853
|
-
get scrollOffset() { return this.#scrollOffset_accessor_storage; }
|
|
854
|
-
set scrollOffset(value) { this.#scrollOffset_accessor_storage = value; }
|
|
855
|
-
#escClearArmed_accessor_storage = (__runInitializers(this, _scrollOffset_extraInitializers), __runInitializers(this, _escClearArmed_initializers, false));
|
|
856
|
-
get escClearArmed() { return this.#escClearArmed_accessor_storage; }
|
|
857
|
-
set escClearArmed(value) { this.#escClearArmed_accessor_storage = value; }
|
|
858
|
-
#cols_accessor_storage = (__runInitializers(this, _escClearArmed_extraInitializers), __runInitializers(this, _cols_initializers, 80));
|
|
859
|
-
get cols() { return this.#cols_accessor_storage; }
|
|
860
|
-
set cols(value) { this.#cols_accessor_storage = value; }
|
|
861
|
-
#rows_accessor_storage = (__runInitializers(this, _cols_extraInitializers), __runInitializers(this, _rows_initializers, 24));
|
|
862
|
-
get rows() { return this.#rows_accessor_storage; }
|
|
863
|
-
set rows(value) { this.#rows_accessor_storage = value; }
|
|
864
|
-
#busy_accessor_storage = (__runInitializers(this, _rows_extraInitializers), __runInitializers(this, _private_busy_initializers, false));
|
|
865
|
-
get #busy() { return _private_busy_descriptor.get.call(this); }
|
|
866
|
-
set #busy(value) { return _private_busy_descriptor.set.call(this, value); }
|
|
867
|
-
#callback_accessor_storage = (__runInitializers(this, _private_busy_extraInitializers), __runInitializers(this, _private_callback_initializers, undefined));
|
|
868
|
-
get #callback() { return _private_callback_descriptor.get.call(this); }
|
|
869
|
-
set #callback(value) { return _private_callback_descriptor.set.call(this, value); }
|
|
870
|
-
#focus_accessor_storage = (__runInitializers(this, _private_callback_extraInitializers), __runInitializers(this, _private_focus_initializers, undefined));
|
|
871
|
-
get #focus() { return _private_focus_descriptor.get.call(this); }
|
|
872
|
-
set #focus(value) { return _private_focus_descriptor.set.call(this, value); }
|
|
873
|
-
#oauthWaiting_accessor_storage = (__runInitializers(this, _private_focus_extraInitializers), __runInitializers(this, _private_oauthWaiting_initializers, false));
|
|
874
|
-
get #oauthWaiting() { return _private_oauthWaiting_descriptor.get.call(this); }
|
|
875
|
-
set #oauthWaiting(value) { return _private_oauthWaiting_descriptor.set.call(this, value); }
|
|
876
|
-
#processing_accessor_storage = (__runInitializers(this, _private_oauthWaiting_extraInitializers), __runInitializers(this, _private_processing_initializers, false));
|
|
877
|
-
/** Overlay action fired; ui/resolve (or the next park) has not landed yet. */
|
|
878
|
-
get #processing() { return _private_processing_descriptor.get.call(this); }
|
|
879
|
-
set #processing(value) { return _private_processing_descriptor.set.call(this, value); }
|
|
880
|
-
#coverDraft_accessor_storage = (__runInitializers(this, _private_processing_extraInitializers), __runInitializers(this, _private_coverDraft_initializers, { draft: "", cursor: 0, mark: null }));
|
|
881
|
-
get #coverDraft() { return _private_coverDraft_descriptor.get.call(this); }
|
|
882
|
-
set #coverDraft(value) { return _private_coverDraft_descriptor.set.call(this, value); }
|
|
883
|
-
#coverThrottle_accessor_storage = (__runInitializers(this, _private_coverDraft_extraInitializers), __runInitializers(this, _private_coverThrottle_initializers, { episodeFrom: null, armedUntil: 0 }));
|
|
884
|
-
get #coverThrottle() { return _private_coverThrottle_descriptor.get.call(this); }
|
|
885
|
-
set #coverThrottle(value) { return _private_coverThrottle_descriptor.set.call(this, value); }
|
|
886
|
-
#coverConfirmLive_accessor_storage = (__runInitializers(this, _private_coverThrottle_extraInitializers), __runInitializers(this, _private_coverConfirmLive_initializers, false));
|
|
887
|
-
get #coverConfirmLive() { return _private_coverConfirmLive_descriptor.get.call(this); }
|
|
888
|
-
set #coverConfirmLive(value) { return _private_coverConfirmLive_descriptor.set.call(this, value); }
|
|
889
|
-
#ackPick_accessor_storage = (__runInitializers(this, _private_coverConfirmLive_extraInitializers), __runInitializers(this, _private_ackPick_initializers, { id: "", index: 0 }));
|
|
890
|
-
/** see omnibox-seat.ts, CHANGE ONLY. */
|
|
891
|
-
/** Which remember option of the acknowledgement prompt is picked (reset when another call asks). */
|
|
892
|
-
get #ackPick() { return _private_ackPick_descriptor.get.call(this); }
|
|
893
|
-
set #ackPick(value) { return _private_ackPick_descriptor.set.call(this, value); }
|
|
894
|
-
#askHold_accessor_storage = (__runInitializers(this, _private_ackPick_extraInitializers), __runInitializers(this, _private_askHold_initializers, false));
|
|
895
|
-
get #askHold() { return _private_askHold_descriptor.get.call(this); }
|
|
896
|
-
set #askHold(value) { return _private_askHold_descriptor.set.call(this, value); }
|
|
897
|
-
#drainAsk_accessor_storage = (__runInitializers(this, _private_askHold_extraInitializers), __runInitializers(this, _private_drainAsk_initializers, false));
|
|
898
|
-
get #drainAsk() { return _private_drainAsk_descriptor.get.call(this); }
|
|
899
|
-
set #drainAsk(value) { return _private_drainAsk_descriptor.set.call(this, value); }
|
|
900
|
-
#agentsOpen_accessor_storage = (__runInitializers(this, _private_drainAsk_extraInitializers), __runInitializers(this, _private_agentsOpen_initializers, false));
|
|
901
|
-
get #agentsOpen() { return _private_agentsOpen_descriptor.get.call(this); }
|
|
902
|
-
set #agentsOpen(value) { return _private_agentsOpen_descriptor.set.call(this, value); }
|
|
903
|
-
#agentsFocus_accessor_storage = (__runInitializers(this, _private_agentsOpen_extraInitializers), __runInitializers(this, _private_agentsFocus_initializers, null));
|
|
904
|
-
get #agentsFocus() { return _private_agentsFocus_descriptor.get.call(this); }
|
|
905
|
-
set #agentsFocus(value) { return _private_agentsFocus_descriptor.set.call(this, value); }
|
|
906
|
-
#agentsHover_accessor_storage = (__runInitializers(this, _private_agentsFocus_extraInitializers), __runInitializers(this, _private_agentsHover_initializers, null));
|
|
907
|
-
get #agentsHover() { return _private_agentsHover_descriptor.get.call(this); }
|
|
908
|
-
set #agentsHover(value) { return _private_agentsHover_descriptor.set.call(this, value); }
|
|
909
|
-
#agentsScroll_accessor_storage = (__runInitializers(this, _private_agentsHover_extraInitializers), __runInitializers(this, _private_agentsScroll_initializers, 0));
|
|
910
|
-
get #agentsScroll() { return _private_agentsScroll_descriptor.get.call(this); }
|
|
911
|
-
set #agentsScroll(value) { return _private_agentsScroll_descriptor.set.call(this, value); }
|
|
912
|
-
#agentsPreview_accessor_storage = (__runInitializers(this, _private_agentsScroll_extraInitializers), __runInitializers(this, _private_agentsPreview_initializers, null));
|
|
913
|
-
get #agentsPreview() { return _private_agentsPreview_descriptor.get.call(this); }
|
|
914
|
-
set #agentsPreview(value) { return _private_agentsPreview_descriptor.set.call(this, value); }
|
|
915
|
-
#peekPlexus_accessor_storage = (__runInitializers(this, _private_agentsPreview_extraInitializers), __runInitializers(this, _private_peekPlexus_initializers, null));
|
|
916
|
-
get #peekPlexus() { return _private_peekPlexus_descriptor.get.call(this); }
|
|
917
|
-
set #peekPlexus(value) { return _private_peekPlexus_descriptor.set.call(this, value); }
|
|
918
|
-
#askPlexus_accessor_storage = (__runInitializers(this, _private_peekPlexus_extraInitializers), __runInitializers(this, _private_askPlexus_initializers, null));
|
|
919
|
-
get #askPlexus() { return _private_askPlexus_descriptor.get.call(this); }
|
|
920
|
-
set #askPlexus(value) { return _private_askPlexus_descriptor.set.call(this, value); }
|
|
921
|
-
/** Turns this client asked the daemon to cancel; only `turn/cancel` writes `cancelRequested`. */
|
|
922
|
-
#cancelAsked = (__runInitializers(this, _private_askPlexus_extraInitializers), observable.set([], { deep: false }));
|
|
923
|
-
#askedPolicy = null;
|
|
924
|
-
#viewPin_accessor_storage = __runInitializers(this, _private_viewPin_initializers, null);
|
|
925
|
-
/** Local tape selection. Null follows `head`. Enter commits via `turn/rewind`. */
|
|
926
|
-
get #viewPin() { return _private_viewPin_descriptor.get.call(this); }
|
|
927
|
-
set #viewPin(value) { return _private_viewPin_descriptor.set.call(this, value); }
|
|
928
|
-
#historyNav_accessor_storage = (__runInitializers(this, _private_viewPin_extraInitializers), __runInitializers(this, _private_historyNav_initializers, false));
|
|
929
|
-
/** Double-Esc on empty. Arrows move the view; Esc / Enter leave. */
|
|
930
|
-
get #historyNav() { return _private_historyNav_descriptor.get.call(this); }
|
|
931
|
-
set #historyNav(value) { return _private_historyNav_descriptor.set.call(this, value); }
|
|
932
|
-
#restoredDraft_accessor_storage = (__runInitializers(this, _private_historyNav_extraInitializers), __runInitializers(this, _private_restoredDraft_initializers, null));
|
|
933
|
-
get #restoredDraft() { return _private_restoredDraft_descriptor.get.call(this); }
|
|
934
|
-
set #restoredDraft(value) { return _private_restoredDraft_descriptor.set.call(this, value); }
|
|
935
|
-
#rewindPending = (__runInitializers(this, _private_restoredDraft_extraInitializers), false);
|
|
936
|
-
#askBindGen = 0;
|
|
937
|
-
#paint;
|
|
938
|
-
#disposers = [];
|
|
939
|
-
#execs = new Map();
|
|
940
|
-
#lastModelEvalLog = "";
|
|
941
|
-
#resolveWaiter;
|
|
942
|
-
#savedDraft;
|
|
943
|
-
#agentsParked;
|
|
944
|
-
/** The pending whose `opened` answer is in flight; Esc sends it a cancel. */
|
|
945
|
-
#waitingPending;
|
|
946
|
-
#coverTimer;
|
|
947
|
-
#rewindGraceUntil = 0;
|
|
948
|
-
#open;
|
|
949
|
-
#now;
|
|
950
|
-
#title;
|
|
951
|
-
#quit;
|
|
952
|
-
#resident;
|
|
953
|
-
#replaceSession;
|
|
954
|
-
get #superKey() {
|
|
955
|
-
return parseSuperKey(this.client.kernelRoot.superKey);
|
|
956
|
-
}
|
|
957
|
-
constructor(client, post, options = {}) {
|
|
958
|
-
this.client = client;
|
|
959
|
-
this.post = post;
|
|
960
|
-
this.cols = options.cols ?? 80;
|
|
961
|
-
this.rows = options.rows ?? 24;
|
|
962
|
-
this.#open = options.open ?? openExternalUrl;
|
|
963
|
-
this.#now = options.now ?? Date.now;
|
|
964
|
-
this.#title = options.title;
|
|
965
|
-
this.#quit = options.quit;
|
|
966
|
-
this.#resident = options.resident;
|
|
967
|
-
this.#replaceSession = options.replaceSession;
|
|
968
|
-
if (options.draft != null && options.draft !== "") {
|
|
969
|
-
this.draft = { draft: options.draft, cursor: options.draft.length, mark: null };
|
|
970
|
-
}
|
|
971
|
-
this.#paint = createPaintController((message) => this.post([message]), "paint", {
|
|
972
|
-
agentGlance: (job) => agentTapeGlance(job, this.client.kernelRoot, this.client.sessionRoot.kvs.model),
|
|
973
|
-
kernel: this.client.kernelRoot,
|
|
974
|
-
cancelAsked: (turn) => this.#cancelAsked.has(turn),
|
|
975
|
-
});
|
|
976
|
-
this.client.setComputedAttention(() => this.#attentionSubjects);
|
|
977
|
-
this.client.setComputedAttentionFocus(() => this.#activeConnection ?? null);
|
|
978
|
-
this.#disposers.push(reaction(() => sessionDisplayTitle(this.client.sessionRoot), (title) => this.#title?.(title), { fireImmediately: true }), reaction(() => this.client.sessionRoot.agent.spec.resident, (on) => this.#resident?.(on), { fireImmediately: true }), reaction(() => askLeafId(this.#askHead), () => this.#stepCoverThrottle(), { fireImmediately: true }), reaction(() => this.#paintComposerFace(), (face) => this.#paint.projectComposer(face), { fireImmediately: true }), reaction(() => this.#askPinFace(), (face) => this.#paint.projectAsk(face), { fireImmediately: true }), reaction(() => this.#waitChrome, (chrome) => this.#paint.projectWait(chrome), { fireImmediately: true }), reaction(() => [this.client.sessionRoot.path, this.client.sessionRoot.statuslineLeft], ([path, left]) => {
|
|
979
|
-
const parts = cwdParts(path);
|
|
980
|
-
const cut = left.indexOf(STATUSLINE_NOTE_SEP);
|
|
981
|
-
this.#paint.projectStatusline({
|
|
982
|
-
cwd: `${parts.root}${parts.rest}`,
|
|
983
|
-
cwdRoot: parts.root,
|
|
984
|
-
left: cut === -1 ? left : left.slice(0, cut),
|
|
985
|
-
note: cut === -1 ? "" : left.slice(cut + STATUSLINE_NOTE_SEP.length),
|
|
986
|
-
});
|
|
987
|
-
}, { fireImmediately: true }), reaction(() => this.#paintTrackSpine(), () => {
|
|
988
|
-
this.#paint.syncSpine(this.#paintSpineTurns(), this.client.sessionRoot.steerQueue);
|
|
989
|
-
this.#applyPinRecap();
|
|
990
|
-
}, { fireImmediately: true, equals: trackEqual }), reaction(() => this.#rewindPaintTrack(), () => this.#syncRewindPaint(), { fireImmediately: true }), reaction(() => this.#previewPaintTrack(), () => this.#paint.syncPreviewSpine(this.#agentsPreview === null ? null : this.#previewSpineTurns(), this.#peekPlexus?.root.kvs.model), { fireImmediately: true, equals: trackEqual }), reaction(() => this.#agentsPaintFace(), (face) => this.#paint.projectAgents(face), { fireImmediately: true }), reaction(() => hostAskEscalateSessionId(this.client), (id) => {
|
|
991
|
-
void this.#bindAskEscalate(id);
|
|
992
|
-
}, { fireImmediately: true }));
|
|
993
|
-
this.#paint.attach();
|
|
994
|
-
}
|
|
995
|
-
/** Write tree. Cadence / visual present read the host replica, not this. */
|
|
996
|
-
get paintRoot() {
|
|
997
|
-
return this.#paint.root;
|
|
998
|
-
}
|
|
999
|
-
flushPaint() {
|
|
1000
|
-
this.#paint.flush();
|
|
1001
|
-
}
|
|
1002
|
-
#paintComposerFace() {
|
|
1003
|
-
const face = paintOmnibox(this.#omniboxValue);
|
|
1004
|
-
return this.#agentsOpen || this.#agentsPreview !== null ? { ...face, interactive: false } : face;
|
|
1005
|
-
}
|
|
1006
|
-
#agentsPaintFace() {
|
|
1007
|
-
const keys = this.#agentsRowKeys();
|
|
1008
|
-
if (this.#agentsHover !== null && !keys.includes(this.#agentsHover)) {
|
|
1009
|
-
runInAction(() => {
|
|
1010
|
-
this.#agentsHover = null;
|
|
1011
|
-
});
|
|
1012
|
-
}
|
|
1013
|
-
if (this.#agentsPreview !== null &&
|
|
1014
|
-
!keys.includes(this.#agentsPreview) &&
|
|
1015
|
-
mentionedAgentCall(this.client, this.#agentsPreview) == null) {
|
|
1016
|
-
runInAction(() => {
|
|
1017
|
-
this.#closeAgentsPreview();
|
|
1018
|
-
});
|
|
1019
|
-
}
|
|
1020
|
-
return agentsPaintFace(this.client, {
|
|
1021
|
-
open: this.#agentsOpen,
|
|
1022
|
-
focusKey: this.#agentsHover ?? this.#agentsFocus,
|
|
1023
|
-
scroll: this.#agentsScroll,
|
|
1024
|
-
previewKey: this.#agentsPreview,
|
|
1025
|
-
});
|
|
1026
|
-
}
|
|
1027
|
-
get #agentDrawerRows() { return _private_get_agentDrawerRows_descriptor.get.call(this); }
|
|
1028
|
-
#agentsRowKeys() {
|
|
1029
|
-
return this.#agentDrawerRows.map((row) => row.key);
|
|
1030
|
-
}
|
|
1031
|
-
#openAgents() {
|
|
1032
|
-
this.#agentsParked = { draft: this.draft.draft, cursor: this.draft.cursor, mark: this.draft.mark };
|
|
1033
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
1034
|
-
this.#resetSelection();
|
|
1035
|
-
this.#agentsOpen = true;
|
|
1036
|
-
this.#agentsScroll = 0;
|
|
1037
|
-
this.#agentsFocus = this.#agentsRowKeys()[0] ?? null;
|
|
1038
|
-
this.#agentsHover = null;
|
|
1039
|
-
}
|
|
1040
|
-
#closeAgents() {
|
|
1041
|
-
this.#closeAgentsPreview();
|
|
1042
|
-
const parked = this.#agentsParked;
|
|
1043
|
-
this.#agentsParked = undefined;
|
|
1044
|
-
this.#agentsOpen = false;
|
|
1045
|
-
this.#agentsFocus = null;
|
|
1046
|
-
this.#agentsHover = null;
|
|
1047
|
-
this.#agentsScroll = 0;
|
|
1048
|
-
if (parked !== undefined)
|
|
1049
|
-
Object.assign(this.draft, parked);
|
|
1050
|
-
}
|
|
1051
|
-
#moveAgentsFocus(delta) {
|
|
1052
|
-
const keys = this.#agentsRowKeys();
|
|
1053
|
-
if (keys.length === 0)
|
|
1054
|
-
return;
|
|
1055
|
-
if (this.#agentsHover !== null) {
|
|
1056
|
-
this.#agentsFocus = this.#agentsHover;
|
|
1057
|
-
this.#agentsHover = null;
|
|
1058
|
-
}
|
|
1059
|
-
const i = Math.max(0, keys.indexOf(this.#agentsFocus ?? ""));
|
|
1060
|
-
const next = Math.min(keys.length - 1, Math.max(0, i + delta));
|
|
1061
|
-
this.#agentsFocus = keys[next];
|
|
1062
|
-
this.#agentsScroll = Math.max(0, next);
|
|
1063
|
-
}
|
|
1064
|
-
#handleAgentsChord(event, seat) {
|
|
1065
|
-
const chord = event.ctrl === true || event.meta === true || event.alt === true;
|
|
1066
|
-
if (this.#omniboxValue.ask !== null)
|
|
1067
|
-
return false;
|
|
1068
|
-
if (this.#agentsPreviewConsumes(event))
|
|
1069
|
-
return true;
|
|
1070
|
-
if (!this.#agentsOpen) {
|
|
1071
|
-
if (chord || event.key !== "ArrowLeft" || this.draft.draft !== "")
|
|
1072
|
-
return false;
|
|
1073
|
-
if (seat.input === "overlay" || seat.input === "auth")
|
|
1074
|
-
return false;
|
|
1075
|
-
this.#openAgents();
|
|
1076
|
-
return true;
|
|
1077
|
-
}
|
|
1078
|
-
return this.#agentsDrawerConsumes(event);
|
|
1079
|
-
}
|
|
1080
|
-
#agentsPreviewConsumes(event) {
|
|
1081
|
-
if (this.#agentsPreview === null)
|
|
1082
|
-
return false;
|
|
1083
|
-
if (event.key === "Escape")
|
|
1084
|
-
this.#closeAgentsPreview();
|
|
1085
|
-
return true;
|
|
1086
|
-
}
|
|
1087
|
-
#agentsDrawerConsumes(event) {
|
|
1088
|
-
if (event.ctrl === true || event.meta === true || event.alt === true)
|
|
1089
|
-
return true;
|
|
1090
|
-
if (event.key === "j" || event.key === "ArrowDown") {
|
|
1091
|
-
this.#moveAgentsFocus(1);
|
|
1092
|
-
return true;
|
|
1093
|
-
}
|
|
1094
|
-
if (event.key === "k" || event.key === "ArrowUp") {
|
|
1095
|
-
this.#moveAgentsFocus(-1);
|
|
1096
|
-
return true;
|
|
1097
|
-
}
|
|
1098
|
-
if (event.key === "ArrowRight" || event.key === "Escape") {
|
|
1099
|
-
this.#closeAgents();
|
|
1100
|
-
return true;
|
|
1101
|
-
}
|
|
1102
|
-
if (event.key === "Enter") {
|
|
1103
|
-
this.#activateAgentsKey(this.#agentsHover ?? this.#agentsFocus);
|
|
1104
|
-
return true;
|
|
1105
|
-
}
|
|
1106
|
-
return true;
|
|
1107
|
-
}
|
|
1108
|
-
#focusAgentsKey(key) {
|
|
1109
|
-
const row = agentsRowKeyFromHit(key) ?? key;
|
|
1110
|
-
const keys = this.#agentsRowKeys();
|
|
1111
|
-
const i = keys.indexOf(row);
|
|
1112
|
-
if (i === -1)
|
|
1113
|
-
return;
|
|
1114
|
-
this.#agentsFocus = keys[i];
|
|
1115
|
-
this.#agentsScroll = Math.max(0, i);
|
|
1116
|
-
}
|
|
1117
|
-
#activateAgentsKey(key) {
|
|
1118
|
-
if (key == null)
|
|
1119
|
-
return;
|
|
1120
|
-
const rowKey = agentsRowKeyFromHit(key) ?? key;
|
|
1121
|
-
const row = this.#agentDrawerRows.find((item) => item.key === rowKey);
|
|
1122
|
-
if (row?.kind === "call") {
|
|
1123
|
-
this.#openAgentsPreview(row.key, row.sessionId);
|
|
1124
|
-
return;
|
|
1125
|
-
}
|
|
1126
|
-
const sessionId = sessionIdFromAgentsKey(key);
|
|
1127
|
-
if (sessionId == null)
|
|
1128
|
-
return;
|
|
1129
|
-
this.#switchSession(sessionId);
|
|
1130
|
-
}
|
|
1131
|
-
#openAgentsPreview(key, sessionId) {
|
|
1132
|
-
this.#agentsPreview = key;
|
|
1133
|
-
if (this.client.peekPlexus?.root.sessionId === sessionId) {
|
|
1134
|
-
this.#peekPlexus = this.client.peekPlexus;
|
|
1135
|
-
return;
|
|
1136
|
-
}
|
|
1137
|
-
this.#peekPlexus = null;
|
|
1138
|
-
this.client.releasePeek();
|
|
1139
|
-
if (sessionId === "")
|
|
1140
|
-
return;
|
|
1141
|
-
const token = key;
|
|
1142
|
-
void this.client
|
|
1143
|
-
.watchPeek(sessionId)
|
|
1144
|
-
.then(() => {
|
|
1145
|
-
return runInAction(() => {
|
|
1146
|
-
if (this.#agentsPreview !== token)
|
|
1147
|
-
return;
|
|
1148
|
-
this.#peekPlexus = this.client.peekPlexus;
|
|
1149
|
-
});
|
|
1150
|
-
})
|
|
1151
|
-
.catch(() => undefined);
|
|
1152
|
-
}
|
|
1153
|
-
#closeAgentsPreview() {
|
|
1154
|
-
this.#agentsPreview = null;
|
|
1155
|
-
this.#peekPlexus = null;
|
|
1156
|
-
this.client.releasePeek();
|
|
1157
|
-
}
|
|
1158
|
-
async #bindAskEscalate(id) {
|
|
1159
|
-
const gen = ++this.#askBindGen;
|
|
1160
|
-
if (id == null) {
|
|
1161
|
-
runInAction(() => {
|
|
1162
|
-
this.#askPlexus = null;
|
|
1163
|
-
});
|
|
1164
|
-
this.client.releaseAsk();
|
|
1165
|
-
return;
|
|
1166
|
-
}
|
|
1167
|
-
if (this.client.askPlexus?.root.sessionId === id) {
|
|
1168
|
-
runInAction(() => {
|
|
1169
|
-
this.#askPlexus = this.client.askPlexus;
|
|
1170
|
-
});
|
|
1171
|
-
return;
|
|
1172
|
-
}
|
|
1173
|
-
try {
|
|
1174
|
-
await this.client.watchAsk(id);
|
|
1175
|
-
}
|
|
1176
|
-
catch {
|
|
1177
|
-
// TODO: swallowed — glance says awaiting, so no cover mounts until the
|
|
1178
|
-
// ask interns. Same shape as watchPeek. Surface or log, do not silently
|
|
1179
|
-
// retry (the ask still lives on the host queue).
|
|
1180
|
-
return;
|
|
1181
|
-
}
|
|
1182
|
-
if (gen !== this.#askBindGen)
|
|
1183
|
-
return;
|
|
1184
|
-
runInAction(() => {
|
|
1185
|
-
if (hostAskEscalateSessionId(this.client) !== id)
|
|
1186
|
-
return;
|
|
1187
|
-
this.#askPlexus = this.client.askPlexus;
|
|
1188
|
-
});
|
|
1189
|
-
}
|
|
1190
|
-
#switchSession(sessionId) {
|
|
1191
|
-
if (sessionId === this.client.sessionId) {
|
|
1192
|
-
this.#closeAgents();
|
|
1193
|
-
return;
|
|
1194
|
-
}
|
|
1195
|
-
if (!projectRecentSessions(this.client).some((row) => row.sessionId === sessionId)) {
|
|
1196
|
-
this.#closeAgents();
|
|
1197
|
-
void this.#showNotice("session not found");
|
|
1198
|
-
return;
|
|
1199
|
-
}
|
|
1200
|
-
if (this.#replaceSession === undefined)
|
|
1201
|
-
return;
|
|
1202
|
-
this.#replaceSession({ path: this.client.sessionRoot.path, sessionId });
|
|
1203
|
-
}
|
|
1204
|
-
#paintSpineTurns() {
|
|
1205
|
-
const root = this.client.sessionRoot;
|
|
1206
|
-
return tapeSpine(this.#historyNav ? resolvedTip(root.head, root.tip) : root.head);
|
|
1207
|
-
}
|
|
1208
|
-
get #sessionTitle() { return _private_get_sessionTitle_descriptor.get.call(this); }
|
|
1209
|
-
get #isHeadAtTip() { return _private_get_isHeadAtTip_descriptor.get.call(this); }
|
|
1210
|
-
#viewTurn() {
|
|
1211
|
-
const head = this.client.sessionRoot.head;
|
|
1212
|
-
const tip = resolvedTip(head, this.client.sessionRoot.tip);
|
|
1213
|
-
const view = this.#viewPin;
|
|
1214
|
-
if (view instanceof SessionTurn && onTipChain(view, tip, head))
|
|
1215
|
-
return view;
|
|
1216
|
-
return head instanceof SessionTurn ? head : null;
|
|
1217
|
-
}
|
|
1218
|
-
get #untouchedRestoredDraft() {
|
|
1219
|
-
return (this.#restoredDraft != null &&
|
|
1220
|
-
this.#restoredDraft.turnId === this.client.sessionRoot.head?.uuid &&
|
|
1221
|
-
this.#restoredDraft.prompt === this.draft.draft);
|
|
1222
|
-
}
|
|
1223
|
-
#browsing() {
|
|
1224
|
-
return this.#historyNav;
|
|
1225
|
-
}
|
|
1226
|
-
#enterHistory() {
|
|
1227
|
-
if (this.#viewTurn() == null)
|
|
1228
|
-
return;
|
|
1229
|
-
if (this.client.sessionRoot.findRunningTurn() != null)
|
|
1230
|
-
return;
|
|
1231
|
-
const head = this.client.sessionRoot.head;
|
|
1232
|
-
if (head instanceof SessionTurn && head.openWork)
|
|
1233
|
-
return;
|
|
1234
|
-
this.#historyNav = true;
|
|
1235
|
-
// A promptless suffix (continue, empty compact) is not a message. Land
|
|
1236
|
-
// on the latest prompt so Enter rolls that suffix back instead of
|
|
1237
|
-
// prefilling an empty draft over a head that never moves.
|
|
1238
|
-
if (head instanceof SessionTurn && !isRewindPin(head)) {
|
|
1239
|
-
const pin = previousPin(head);
|
|
1240
|
-
if (pin != null)
|
|
1241
|
-
this.#viewPin = pin;
|
|
1242
|
-
}
|
|
1243
|
-
}
|
|
1244
|
-
#leaveHistory() {
|
|
1245
|
-
this.#historyNav = false;
|
|
1246
|
-
this.#viewPin = null;
|
|
1247
|
-
}
|
|
1248
|
-
/**
|
|
1249
|
-
* Turns newer than `view`, oldest first. Pins, then the episode ceiling
|
|
1250
|
-
* when it is not already that last pin — a promptless continue, or the
|
|
1251
|
-
* last message once `futurePins` has stopped short of it.
|
|
1252
|
-
*/
|
|
1253
|
-
#aheadOf(view) {
|
|
1254
|
-
const tip = this.client.sessionRoot.tip;
|
|
1255
|
-
const ahead = futurePins(view, tip);
|
|
1256
|
-
const ceiling = resolvedTip(view, tip);
|
|
1257
|
-
if (ceiling != null && ceiling !== view && ahead.at(-1) !== ceiling)
|
|
1258
|
-
ahead.push(ceiling);
|
|
1259
|
-
return ahead;
|
|
1260
|
-
}
|
|
1261
|
-
#moveView(turn) {
|
|
1262
|
-
// Keep the pin even when it is `head`. Rewind cuts *before* the selected
|
|
1263
|
-
// message, so head is the turn we just left — ArrowDown has to be able
|
|
1264
|
-
// to land back on it.
|
|
1265
|
-
this.#viewPin = turn;
|
|
1266
|
-
this.#historyNav = true;
|
|
1267
|
-
}
|
|
1268
|
-
#pinById(id) {
|
|
1269
|
-
const head = this.client.sessionRoot.head;
|
|
1270
|
-
const tip = resolvedTip(head, this.client.sessionRoot.tip);
|
|
1271
|
-
let unit = tip;
|
|
1272
|
-
const seen = new Set();
|
|
1273
|
-
while (unit instanceof SessionTurn) {
|
|
1274
|
-
if (seen.has(unit))
|
|
1275
|
-
break;
|
|
1276
|
-
seen.add(unit);
|
|
1277
|
-
if (unit.uuid === id && (isRewindPin(unit) || unit === tip))
|
|
1278
|
-
return unit;
|
|
1279
|
-
unit = unit.turnTail;
|
|
1280
|
-
}
|
|
1281
|
-
return null;
|
|
1282
|
-
}
|
|
1283
|
-
#applyPinRecap() {
|
|
1284
|
-
const view = this.#viewTurn();
|
|
1285
|
-
const running = this.client.sessionRoot.findRunningTurn() != null;
|
|
1286
|
-
if (running || view == null || !this.#historyNav || this.#callback !== undefined) {
|
|
1287
|
-
this.#paint.projectPinRecap(null);
|
|
1288
|
-
return;
|
|
1289
|
-
}
|
|
1290
|
-
this.#paint.projectPinRecap(view, this.#sessionTitle, [
|
|
1291
|
-
{ key: "Enter", action: "Rollback here" },
|
|
1292
|
-
{ key: "Esc", action: "Back" },
|
|
1293
|
-
...(previousPin(view) == null ? [] : [{ key: "↑", action: "Previous message" }]),
|
|
1294
|
-
...(this.#aheadOf(view).length === 0 ? [] : [{ key: "↓", action: "Next message" }]),
|
|
1295
|
-
]);
|
|
1296
|
-
}
|
|
1297
|
-
#rewindPaintTrack() {
|
|
1298
|
-
const head = this.client.sessionRoot.head;
|
|
1299
|
-
const tip = this.client.sessionRoot.tip;
|
|
1300
|
-
return [
|
|
1301
|
-
head?.uuid ?? "",
|
|
1302
|
-
tip?.uuid ?? "",
|
|
1303
|
-
this.#viewPin?.uuid ?? "",
|
|
1304
|
-
this.#historyNav,
|
|
1305
|
-
this.client.sessionRoot.findRunningTurn()?.uuid ?? "",
|
|
1306
|
-
this.#sessionTitle,
|
|
1307
|
-
this.#callback?.surface.name ?? "",
|
|
1308
|
-
];
|
|
1309
|
-
}
|
|
1310
|
-
#syncRewindPaint() {
|
|
1311
|
-
const tip = this.client.sessionRoot.tip;
|
|
1312
|
-
const view = this.#viewTurn();
|
|
1313
|
-
const running = this.client.sessionRoot.findRunningTurn() != null;
|
|
1314
|
-
const rewindChromeCollapsed = running || !this.#historyNav || view == null || this.#callback !== undefined;
|
|
1315
|
-
// LATEST_PLACE: the view is the episode ceiling, so there is no newer
|
|
1316
|
-
// message and the ahead stack drops. The composer stays hidden either
|
|
1317
|
-
// way — the recap block is the input while history navigation is open.
|
|
1318
|
-
const latestPlace = !rewindChromeCollapsed && view != null && isAtTip(view, tip);
|
|
1319
|
-
const pastAll = rewindChromeCollapsed ? [] : pastPins(view);
|
|
1320
|
-
const futureAll = rewindChromeCollapsed || latestPlace || view == null ? [] : this.#aheadOf(view);
|
|
1321
|
-
const slots = rewindNeighborSlots(futureAll.length, pastAll.length);
|
|
1322
|
-
const past = pastAll
|
|
1323
|
-
.slice(0, slots.behind)
|
|
1324
|
-
.toReversed()
|
|
1325
|
-
.map((turn) => ({ key: turn.uuid, text: turn.prompt }));
|
|
1326
|
-
const future = futureAll
|
|
1327
|
-
.slice(0, slots.ahead)
|
|
1328
|
-
.map((turn) => ({ key: turn.uuid, text: turn.prompt || "Latest conversation" }));
|
|
1329
|
-
const steal = this.#omnibox.render === "ask" || this.#omnibox.render === "overlay" || this.#omnibox.render === "auth";
|
|
1330
|
-
this.#paint.projectRewind({
|
|
1331
|
-
// atTip is "not browsing". The ceiling still browses: it dims the
|
|
1332
|
-
// tape and scrolls to the block. Follow-tail is only for the live view.
|
|
1333
|
-
atTip: rewindChromeCollapsed,
|
|
1334
|
-
seatRim: steal || !this.#browsing(),
|
|
1335
|
-
past,
|
|
1336
|
-
future,
|
|
1337
|
-
pastTotal: pastAll.length,
|
|
1338
|
-
futureTotal: futureAll.length,
|
|
1339
|
-
});
|
|
1340
|
-
this.#applyPinRecap();
|
|
1341
|
-
}
|
|
1342
|
-
#previewSpineTurns() {
|
|
1343
|
-
if (this.#agentsPreview == null)
|
|
1344
|
-
return [];
|
|
1345
|
-
return tapeSpine(this.#peekPlexus?.root.head ?? null);
|
|
1346
|
-
}
|
|
1347
|
-
#paintTrackSpine() {
|
|
1348
|
-
const tip = resolvedTip(this.client.sessionRoot.head, this.client.sessionRoot.tip);
|
|
1349
|
-
return [
|
|
1350
|
-
this.client.kernelRoot.hideFloorTools,
|
|
1351
|
-
this.#trackSpine(this.#paintSpineTurns()),
|
|
1352
|
-
this.client.sessionRoot.steerQueue.map((row) => [row, row.text]),
|
|
1353
|
-
tip?.uuid ?? "",
|
|
1354
|
-
this.client.sessionRoot.findRunningTurn()?.uuid ?? "",
|
|
1355
|
-
];
|
|
1356
|
-
}
|
|
1357
|
-
#previewPaintTrack() {
|
|
1358
|
-
return [
|
|
1359
|
-
this.#agentsPreview,
|
|
1360
|
-
this.client.kernelRoot.hideFloorTools,
|
|
1361
|
-
this.#peekPlexus?.root.kvs.model ?? "",
|
|
1362
|
-
this.#trackSpine(this.#previewSpineTurns()),
|
|
1363
|
-
];
|
|
1364
|
-
}
|
|
1365
|
-
/**
|
|
1366
|
-
* Structure only — turn/chunk identity, cutoff, ask pin, hidden tools.
|
|
1367
|
-
* PEW field values belong to per-cell reactions in PaintController.
|
|
1368
|
-
*/
|
|
1369
|
-
#trackSpine(turns) {
|
|
1370
|
-
return turns.map((turn) => [trackTurn(turn), this.#cancelAsked.has(turn)]);
|
|
1371
|
-
}
|
|
1372
|
-
get #askHead() { return _private_get_askHead_descriptor.get.call(this); }
|
|
1373
|
-
/** The acknowledgement the asked call carries, when a flag still waits on a person. */
|
|
1374
|
-
get #ackPrompt() { return _private_get_ackPrompt_descriptor.get.call(this); }
|
|
1375
|
-
get #ackIndex() {
|
|
1376
|
-
const leaf = this.#askHead;
|
|
1377
|
-
const model = this.#ackPrompt;
|
|
1378
|
-
if (leaf == null || model == null || this.#ackPick.id !== leaf.uuid)
|
|
1379
|
-
return 0;
|
|
1380
|
-
return Math.min(this.#ackPick.index, Math.max(0, model.choices.length - 1));
|
|
1381
|
-
}
|
|
1382
|
-
get #coverAskAgentSpec() { return _private_get_coverAskAgentSpec_descriptor.get.call(this); }
|
|
1383
|
-
get #askHome() { return _private_get_askHome_descriptor.get.call(this); }
|
|
1384
|
-
get #readWiden() { return _private_get_readWiden_descriptor.get.call(this); }
|
|
1385
|
-
get #omniboxValue() { return _private_get_omniboxValue_descriptor.get.call(this); }
|
|
1386
|
-
get #contextRail() { return _private_get_contextRail_descriptor.get.call(this); }
|
|
1387
|
-
get #omnibox() { return _private_get_omnibox_descriptor.get.call(this); }
|
|
1388
|
-
get #askIsolated() { return _private_get_askIsolated_descriptor.get.call(this); }
|
|
1389
|
-
get #historyHidesOmnibox() {
|
|
1390
|
-
if (!this.#browsing())
|
|
1391
|
-
return false;
|
|
1392
|
-
const render = this.#omnibox.render;
|
|
1393
|
-
return render !== "ask" && render !== "overlay" && render !== "auth";
|
|
1394
|
-
}
|
|
1395
|
-
/** Next-turn rows only. A sitting steer paints as an upcoming user prompt. */
|
|
1396
|
-
get #admissionDeckText() { return _private_get_admissionDeckText_descriptor.get.call(this); }
|
|
1397
|
-
#askPinFace() {
|
|
1398
|
-
const seat = this.#omnibox;
|
|
1399
|
-
if (seat.render === "overlay" || seat.render === "auth")
|
|
1400
|
-
return null;
|
|
1401
|
-
const host = this.client.sessionRoot.findRunningTurn();
|
|
1402
|
-
const turn = host?.approvalHead == null ? this.#askHome.findRunningTurn() : host;
|
|
1403
|
-
const head = turn == null ? null : askPaintHead(turn);
|
|
1404
|
-
if (head instanceof ToolCallJob) {
|
|
1405
|
-
const face = askPinFace(head, this.client.kernelRoot);
|
|
1406
|
-
return askPinWorthPainting(face) ? face : null;
|
|
1407
|
-
}
|
|
1408
|
-
return null;
|
|
1409
|
-
}
|
|
1410
|
-
/**
|
|
1411
|
-
* Plexus facts for the pin. The paint tree is MST, so the constructor
|
|
1412
|
-
* reaction stamps this through `projectWait`.
|
|
1413
|
-
*/
|
|
1414
|
-
get #waitChrome() { return _private_get_waitChrome_descriptor.get.call(this); }
|
|
1415
|
-
get #inputting() {
|
|
1416
|
-
return (this.#callback !== undefined && hasInputHole(this.#callback.surface) && !this.#oauthWaiting && !this.#processing);
|
|
1417
|
-
}
|
|
1418
|
-
get #commands() { return _private_get_commands_descriptor.get.call(this); }
|
|
1419
|
-
#skillVerb(verb) {
|
|
1420
|
-
if (isHostVerb(verb) || this.client.kernelRoot.commands[verb] !== undefined)
|
|
1421
|
-
return false;
|
|
1422
|
-
return this.client.sessionRoot.skills.some((skill) => skillMatchesVerb(skill, verb));
|
|
1423
|
-
}
|
|
1424
|
-
get #parentNode() { return _private_get_parentNode_descriptor.get.call(this); }
|
|
1425
|
-
get #inCommand() { return _private_get_inCommand_descriptor.get.call(this); }
|
|
1426
|
-
get #atCatalog() { return _private_get_atCatalog_descriptor.get.call(this); }
|
|
1427
|
-
get #pickerRows() { return _private_get_pickerRows_descriptor.get.call(this); }
|
|
1428
|
-
get #catalogNodes() { return _private_get_catalogNodes_descriptor.get.call(this); }
|
|
1429
|
-
get #commandChoices() { return _private_get_commandChoices_descriptor.get.call(this); }
|
|
1430
|
-
get effectiveKey() {
|
|
1431
|
-
return reconcileSelectedKey(this.selectedCommandKey, this.#commandChoices ?? []);
|
|
1432
|
-
}
|
|
1433
|
-
get #commandAction() { return _private_get_commandAction_descriptor.get.call(this); }
|
|
1434
|
-
/** Picker rows. Logic reads this; paint is not the catalog. */
|
|
1435
|
-
get commandChoices() {
|
|
1436
|
-
return this.#commandChoices;
|
|
1437
|
-
}
|
|
1438
|
-
/** Composer title. Manual title wins; otherwise the latest metadata claim. */
|
|
1439
|
-
get sessionTitle() {
|
|
1440
|
-
return this.#sessionTitle;
|
|
1441
|
-
}
|
|
1442
|
-
/** Quota windows Tea hands to paint. Paint spells the remaining label. */
|
|
1443
|
-
get quotaWindows() {
|
|
1444
|
-
return this.#quotaWindows ?? [];
|
|
1445
|
-
}
|
|
1446
|
-
/** Parked confirm / oauth surface. Null when the composer owns the draft. */
|
|
1447
|
-
get callbackSurface() {
|
|
1448
|
-
return this.#callback?.surface ?? null;
|
|
1449
|
-
}
|
|
1450
|
-
// COMMAND_SURFACE_KEEPALIVE: isolated-ask paint skips this surface for a
|
|
1451
|
-
// tick. Without keepAlive, onBecomeUnobserved runs exec.get() and aborts
|
|
1452
|
-
// the command-body eval.
|
|
1453
|
-
get #commandSurface() { return _private_get_commandSurface_descriptor.get.call(this); }
|
|
1454
|
-
#noteModelEval(surface) {
|
|
1455
|
-
const kernel = this.client.kernelRoot;
|
|
1456
|
-
const session = this.client.sessionRoot;
|
|
1457
|
-
const connections = Object.values(kernel.connections).map((spec) => {
|
|
1458
|
-
const models = Array.isArray(spec.live.models) ? spec.live.models.map(String) : [];
|
|
1459
|
-
const can = spec.driver?.abilityClaim ?? [];
|
|
1460
|
-
return `${spec.id} can=${can.join(",") || "(none)"} ready=${spec.readyState} models=${models.length}`;
|
|
1461
|
-
});
|
|
1462
|
-
const choices = surface instanceof UiNode ? surface.choices.filter((child) => child.name !== "").length : "no-surface";
|
|
1463
|
-
const replica = this.client.kernelPlexus.doc;
|
|
1464
|
-
const line = `command evaluation: current connection=${session.kvs.connection ?? ""} model=${session.kvs.model ?? ""} surface=${choices} replica=guid=${replica.guid} client=${replica.clientID} ${connections.join("; ") || "connections=(none)"}`;
|
|
1465
|
-
if (line === this.#lastModelEvalLog)
|
|
1466
|
-
return;
|
|
1467
|
-
this.#lastModelEvalLog = line;
|
|
1468
|
-
step(line);
|
|
1469
|
-
}
|
|
1470
|
-
#commandConfig(extra = {}) {
|
|
1471
|
-
return {
|
|
1472
|
-
kernel: this.client.kernelRoot,
|
|
1473
|
-
session: this.client.sessionRoot,
|
|
1474
|
-
rpc: (method, params) => this.client.request(method, params),
|
|
1475
|
-
...extra,
|
|
1476
|
-
};
|
|
1477
|
-
}
|
|
1478
|
-
#execFor(verb, body, kernel) {
|
|
1479
|
-
const hit = this.#execs.get(verb);
|
|
1480
|
-
if (hit !== undefined && hit.body === body)
|
|
1481
|
-
return hit.exec;
|
|
1482
|
-
const box = new ComputedExecBox(body, {
|
|
1483
|
-
capabilities: COMMAND_CAPABILITIES,
|
|
1484
|
-
config: this.#commandConfig({ kernel }),
|
|
1485
|
-
});
|
|
1486
|
-
this.#execs.set(verb, { body, exec: box });
|
|
1487
|
-
return box;
|
|
1488
|
-
}
|
|
1489
|
-
get #selectedIndex() { return _private_get_selectedIndex_descriptor.get.call(this); }
|
|
1490
|
-
focusAt(index) {
|
|
1491
|
-
const keyed = this.#commandChoices;
|
|
1492
|
-
if (keyed === undefined || keyed.length === 0)
|
|
1493
|
-
return;
|
|
1494
|
-
const i = ((index % keyed.length) + keyed.length) % keyed.length;
|
|
1495
|
-
this.selectedCommandKey = keyed[i].key ?? null;
|
|
1496
|
-
const sel = keyed.findIndex((row) => row.key === this.selectedCommandKey);
|
|
1497
|
-
this.scrollOffset = peekScroll(sel, keyed.length, COMPOSER_COMMAND_MAX_VISIBLE, this.scrollOffset);
|
|
1498
|
-
}
|
|
1499
|
-
#draftFromKey(state, event) {
|
|
1500
|
-
const op = keyEventToDraftOp(event);
|
|
1501
|
-
if (op === null || op === "clear")
|
|
1502
|
-
return null;
|
|
1503
|
-
return applyDraftOp(state, maybeVisualMotion(op, state, rootInnerWidth(this.cols)));
|
|
1504
|
-
}
|
|
1505
|
-
#peekSelection() {
|
|
1506
|
-
const keyed = this.#commandChoices;
|
|
1507
|
-
if (keyed === undefined || keyed.length === 0) {
|
|
1508
|
-
if (omniboxStackPanel(this.#omniboxValue).body === "")
|
|
1509
|
-
this.scrollOffset = 0;
|
|
1510
|
-
return;
|
|
1511
|
-
}
|
|
1512
|
-
const sel = keyed.findIndex((row) => row.key === this.effectiveKey);
|
|
1513
|
-
this.scrollOffset = peekScroll(sel, keyed.length, COMPOSER_COMMAND_MAX_VISIBLE, this.scrollOffset);
|
|
1514
|
-
}
|
|
1515
|
-
#resetSelection() {
|
|
1516
|
-
this.selectedCommandKey = null;
|
|
1517
|
-
this.#peekSelection();
|
|
1518
|
-
}
|
|
1519
|
-
handle(message) {
|
|
1520
|
-
switch (message.kind) {
|
|
1521
|
-
case "resize":
|
|
1522
|
-
this.cols = message.cols;
|
|
1523
|
-
this.rows = message.rows;
|
|
1524
|
-
return;
|
|
1525
|
-
case "input_events": {
|
|
1526
|
-
this.#stepCoverThrottle();
|
|
1527
|
-
if (this.#askHead != null || this.#drainAsk)
|
|
1528
|
-
this.#askHold = true;
|
|
1529
|
-
if (this.#agentsOpen && this.#omniboxValue.ask !== null)
|
|
1530
|
-
this.#closeAgents();
|
|
1531
|
-
let draftChanged = false;
|
|
1532
|
-
for (const event of message.events) {
|
|
1533
|
-
if (this.escClearArmed && event.key !== "Escape")
|
|
1534
|
-
this.escClearArmed = false;
|
|
1535
|
-
if (this.#handleHotkey(event))
|
|
1536
|
-
continue;
|
|
1537
|
-
if (this.#askIsolated) {
|
|
1538
|
-
const next = this.#draftFromKey(this.#coverDraft, event);
|
|
1539
|
-
if (next === null)
|
|
1540
|
-
continue;
|
|
1541
|
-
Object.assign(this.#coverDraft, next);
|
|
1542
|
-
continue;
|
|
1543
|
-
}
|
|
1544
|
-
if (this.#historyHidesOmnibox)
|
|
1545
|
-
continue;
|
|
1546
|
-
if (this.#busy && !this.#inputting)
|
|
1547
|
-
continue;
|
|
1548
|
-
const prevVerb = slashVerb(this.draft.draft);
|
|
1549
|
-
const prevInCommand = this.#inCommand;
|
|
1550
|
-
const prevText = this.draft.draft;
|
|
1551
|
-
const next = this.#draftFromKey(this.draft, event);
|
|
1552
|
-
if (next === null)
|
|
1553
|
-
continue;
|
|
1554
|
-
if (next.draft !== this.draft.draft) {
|
|
1555
|
-
draftChanged = true;
|
|
1556
|
-
if (slashVerb(next.draft) !== prevVerb)
|
|
1557
|
-
this.#focus = undefined;
|
|
1558
|
-
}
|
|
1559
|
-
Object.assign(this.draft, next);
|
|
1560
|
-
if (next.draft !== prevText) {
|
|
1561
|
-
this.#askHold = false;
|
|
1562
|
-
this.#drainAsk = false;
|
|
1563
|
-
}
|
|
1564
|
-
// see COMMAND_SURFACE_KEEPALIVE.
|
|
1565
|
-
if (this.#inCommand !== prevInCommand || (this.#inCommand && slashVerb(this.draft.draft) !== prevVerb)) {
|
|
1566
|
-
this.selectedCommandKey = null;
|
|
1567
|
-
}
|
|
1568
|
-
}
|
|
1569
|
-
if (this.#askHead == null && !this.#drainAsk)
|
|
1570
|
-
this.#askHold = false;
|
|
1571
|
-
if (draftChanged)
|
|
1572
|
-
this.#peekSelection();
|
|
1573
|
-
return;
|
|
1574
|
-
}
|
|
1575
|
-
case "picker_activate": {
|
|
1576
|
-
const keyed = this.#commandChoices;
|
|
1577
|
-
const nodes = this.#pickerRows;
|
|
1578
|
-
if (keyed === undefined || nodes === undefined)
|
|
1579
|
-
return;
|
|
1580
|
-
const i = keyed.findIndex((row) => row.key === message.key);
|
|
1581
|
-
if (i !== -1)
|
|
1582
|
-
this.#pick(nodes[i], true);
|
|
1583
|
-
return;
|
|
1584
|
-
}
|
|
1585
|
-
case "picker_scroll": {
|
|
1586
|
-
const panel = omniboxStackPanel(this.#omniboxValue);
|
|
1587
|
-
if (panel.body !== "") {
|
|
1588
|
-
const n = panel.body.split("\n").length;
|
|
1589
|
-
const viewport = panel.viewport ?? n;
|
|
1590
|
-
const maxS = Math.max(0, n - viewport);
|
|
1591
|
-
this.scrollOffset = Math.min(maxS, Math.max(0, this.scrollOffset + message.delta));
|
|
1592
|
-
return;
|
|
1593
|
-
}
|
|
1594
|
-
const n = this.#commandChoices?.length ?? 0;
|
|
1595
|
-
const maxS = Math.max(0, n - COMPOSER_COMMAND_MAX_VISIBLE);
|
|
1596
|
-
this.scrollOffset = Math.min(maxS, Math.max(0, this.scrollOffset + message.delta));
|
|
1597
|
-
return;
|
|
1598
|
-
}
|
|
1599
|
-
case "agents_scroll":
|
|
1600
|
-
if (!this.#agentsOpen || this.#agentsPreview !== null)
|
|
1601
|
-
return;
|
|
1602
|
-
this.#agentsScroll = Math.max(0, this.#agentsScroll + message.delta);
|
|
1603
|
-
return;
|
|
1604
|
-
case "agents_focus":
|
|
1605
|
-
if (!this.#agentsOpen || this.#agentsPreview !== null)
|
|
1606
|
-
return;
|
|
1607
|
-
this.#focusAgentsKey(message.key);
|
|
1608
|
-
return;
|
|
1609
|
-
case "agents_hover": {
|
|
1610
|
-
if (!this.#agentsOpen || this.#agentsPreview !== null)
|
|
1611
|
-
return;
|
|
1612
|
-
if (message.key == null) {
|
|
1613
|
-
this.#agentsHover = null;
|
|
1614
|
-
return;
|
|
1615
|
-
}
|
|
1616
|
-
const row = agentsRowKeyFromHit(message.key) ?? message.key;
|
|
1617
|
-
this.#agentsHover = this.#agentsRowKeys().includes(row) ? row : null;
|
|
1618
|
-
return;
|
|
1619
|
-
}
|
|
1620
|
-
case "submit": {
|
|
1621
|
-
const received = receiveSubmit(message);
|
|
1622
|
-
if (received !== null)
|
|
1623
|
-
this.submission = received;
|
|
1624
|
-
return;
|
|
1625
|
-
}
|
|
1626
|
-
case "activate":
|
|
1627
|
-
if (this.#agentsPreview !== null) {
|
|
1628
|
-
if (message.key.endsWith(":backdrop"))
|
|
1629
|
-
this.#closeAgentsPreview();
|
|
1630
|
-
return;
|
|
1631
|
-
}
|
|
1632
|
-
if (message.key.startsWith("mention:")) {
|
|
1633
|
-
const call = mentionedAgentCall(this.client, `call:${message.key.slice("mention:".length)}`);
|
|
1634
|
-
if (call != null) {
|
|
1635
|
-
this.#openAgentsPreview(call.key, call.sessionId);
|
|
1636
|
-
return;
|
|
1637
|
-
}
|
|
1638
|
-
}
|
|
1639
|
-
if (this.#agentsOpen) {
|
|
1640
|
-
if (message.key.endsWith(":backdrop")) {
|
|
1641
|
-
this.#closeAgents();
|
|
1642
|
-
return;
|
|
1643
|
-
}
|
|
1644
|
-
this.#activateAgentsKey(message.key);
|
|
1645
|
-
return;
|
|
1646
|
-
}
|
|
1647
|
-
{
|
|
1648
|
-
const pin = this.#pinById(message.key);
|
|
1649
|
-
if (pin != null)
|
|
1650
|
-
this.#moveView(pin);
|
|
1651
|
-
}
|
|
1652
|
-
return;
|
|
1653
|
-
default:
|
|
1654
|
-
return;
|
|
1655
|
-
}
|
|
1656
|
-
}
|
|
1657
|
-
/**
|
|
1658
|
-
* Honest submit wins. Text parts join into the prompt. Picture bytes ride
|
|
1659
|
-
* beside it. The command stays out of both. With no submission, the typed
|
|
1660
|
-
* string goes as before.
|
|
1661
|
-
*/
|
|
1662
|
-
#submitTurn(kind) {
|
|
1663
|
-
const typed = this.draft.draft.trim();
|
|
1664
|
-
const honest = this.submission;
|
|
1665
|
-
const joined = honest !== null && honest.parts.length > 0 ? promptFromParts(honest.parts) : null;
|
|
1666
|
-
const prompt = joined === null ? typed : joined.text;
|
|
1667
|
-
const visuals = joined?.visuals ?? [];
|
|
1668
|
-
if (prompt.trim() === "" && visuals.length === 0)
|
|
1669
|
-
return false;
|
|
1670
|
-
const params = { prompt };
|
|
1671
|
-
if (kind !== undefined)
|
|
1672
|
-
params.kind = kind;
|
|
1673
|
-
if (visuals.length > 0)
|
|
1674
|
-
params.visuals = visuals;
|
|
1675
|
-
trace("harness:turn", `submit chars=${prompt.trim().length}`);
|
|
1676
|
-
this.#fire([new UiNode("turn", "", [], "ok", "", undefined, [], [], [], "turn", params)], true);
|
|
1677
|
-
this.submission = null;
|
|
1678
|
-
return true;
|
|
1679
|
-
}
|
|
1680
|
-
#fire(leaves, dismiss = false) {
|
|
1681
|
-
if (leaves === undefined || leaves.length === 0)
|
|
1682
|
-
return;
|
|
1683
|
-
if (this.#resolveWaiter !== undefined) {
|
|
1684
|
-
const leaf = leaves.find((item) => item.op === "ui/resolve") ?? leaves[0];
|
|
1685
|
-
if (leaf?.op === "ui/resolve") {
|
|
1686
|
-
this.#completeCallback(fillParams(jsonParams(leaf.params), this.#remainder));
|
|
1687
|
-
}
|
|
1688
|
-
return;
|
|
1689
|
-
}
|
|
1690
|
-
if (this.#busy)
|
|
1691
|
-
return;
|
|
1692
|
-
void this.#run(leaves, dismiss);
|
|
1693
|
-
}
|
|
1694
|
-
/** One named RPC at a time. A `{ form: "ui" }` result parks in the omnibox. */
|
|
1695
|
-
async #run(leaves, dismiss = false) {
|
|
1696
|
-
const saved = dismiss ? { draft: this.draft.draft, cursor: this.draft.cursor, mark: this.draft.mark } : null;
|
|
1697
|
-
runInAction(() => {
|
|
1698
|
-
if (dismiss) {
|
|
1699
|
-
this.#savedDraft = saved ?? undefined;
|
|
1700
|
-
this.#focus = undefined;
|
|
1701
|
-
this.escClearArmed = false;
|
|
1702
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
1703
|
-
this.#resetSelection();
|
|
1704
|
-
}
|
|
1705
|
-
this.#busy = true;
|
|
1706
|
-
});
|
|
1707
|
-
try {
|
|
1708
|
-
for (const leaf of leaves) {
|
|
1709
|
-
if (leaf.op == null)
|
|
1710
|
-
continue;
|
|
1711
|
-
const params = fillParams(jsonParams(leaf.params), this.#remainder);
|
|
1712
|
-
let log = `tea ${leaf.op}`;
|
|
1713
|
-
if (leaf.op === "kv/set" || leaf.op === "kv/clear") {
|
|
1714
|
-
const key = typeof params.key === "string" ? params.key : "";
|
|
1715
|
-
if (key !== "") {
|
|
1716
|
-
const scope = params.scope === "kernel" || params.scope === "project" ? params.scope : "session";
|
|
1717
|
-
if (leaf.op === "kv/clear") {
|
|
1718
|
-
log += ` ${scope} ${key}`;
|
|
1719
|
-
}
|
|
1720
|
-
else {
|
|
1721
|
-
const value = typeof params.value === "string" ? params.value : "";
|
|
1722
|
-
log += ` ${scope} ${key}=${value}`;
|
|
1723
|
-
}
|
|
1724
|
-
}
|
|
1725
|
-
}
|
|
1726
|
-
step(log);
|
|
1727
|
-
let result = await this.client.request(leaf.op, params);
|
|
1728
|
-
while (isUiForm(result)) {
|
|
1729
|
-
result = await this.#awaitCallback(result);
|
|
1730
|
-
}
|
|
1731
|
-
const refused = refusalOf(result);
|
|
1732
|
-
if (refused !== undefined)
|
|
1733
|
-
throw new Error(refused);
|
|
1734
|
-
if (leaf.op === "connect/adopt") {
|
|
1735
|
-
const value = typeof result === "object" && result !== null ? result.id : undefined;
|
|
1736
|
-
const id = typeof value === "string" && value.trim() !== "" ? value.trim() : undefined;
|
|
1737
|
-
if (id !== undefined) {
|
|
1738
|
-
const connection = { key: "connection", value: id };
|
|
1739
|
-
step(`tea kv/set session connection=${id}`);
|
|
1740
|
-
await this.client.request("kv/set", connection);
|
|
1741
|
-
runInAction(() => {
|
|
1742
|
-
this.#savedDraft = undefined;
|
|
1743
|
-
this.draft = { draft: "/model", cursor: 6, mark: null };
|
|
1744
|
-
this.#resetSelection();
|
|
1745
|
-
});
|
|
1746
|
-
}
|
|
1747
|
-
}
|
|
1748
|
-
}
|
|
1749
|
-
const kvs = this.client.sessionRoot.kvs;
|
|
1750
|
-
step(`tea replica model=${kvs.model ?? ""} connection=${kvs.connection ?? ""}`);
|
|
1751
|
-
}
|
|
1752
|
-
catch (error) {
|
|
1753
|
-
if (saved !== null) {
|
|
1754
|
-
runInAction(() => {
|
|
1755
|
-
Object.assign(this.draft, saved);
|
|
1756
|
-
});
|
|
1757
|
-
}
|
|
1758
|
-
fail("tea run", error);
|
|
1759
|
-
await this.#showNotice(error instanceof Error ? error.message : String(error));
|
|
1760
|
-
}
|
|
1761
|
-
finally {
|
|
1762
|
-
runInAction(() => {
|
|
1763
|
-
this.#busy = false;
|
|
1764
|
-
this.#processing = false;
|
|
1765
|
-
this.#callback = undefined;
|
|
1766
|
-
this.#focus = undefined;
|
|
1767
|
-
});
|
|
1768
|
-
}
|
|
1769
|
-
}
|
|
1770
|
-
async #showNotice(message) {
|
|
1771
|
-
const surface = new UiNode(message, "", [], "ok", "", undefined, [new UiNode("Dismiss", "", [], "ok", "", undefined, [], [], [], "ui/resolve", { pending: "", kind: "dismiss" })], [new UiNode("Dismiss", "", [], "ok", "", "escape", [], [], [], "ui/resolve", { pending: "", kind: "dismiss" })], [], null, {});
|
|
1772
|
-
await this.#parkSurface(surface);
|
|
1773
|
-
}
|
|
1774
|
-
/** Park a surface in the omnibox until one of its `ui/resolve` leaves fires; the draft comes back after. */
|
|
1775
|
-
async #parkSurface(surface) {
|
|
1776
|
-
const saved = { ...this.draft };
|
|
1777
|
-
this.#savedDraft = saved;
|
|
1778
|
-
runInAction(() => {
|
|
1779
|
-
this.#callback = { pending: "", surface };
|
|
1780
|
-
this.#focus = undefined;
|
|
1781
|
-
this.draft = { draft: "", cursor: 0, mark: null };
|
|
1782
|
-
this.#resetSelection();
|
|
1783
|
-
this.escClearArmed = false;
|
|
1784
|
-
});
|
|
1785
|
-
try {
|
|
1786
|
-
return await new Promise((resolve) => {
|
|
1787
|
-
this.#resolveWaiter = resolve;
|
|
1788
|
-
});
|
|
1789
|
-
}
|
|
1790
|
-
finally {
|
|
1791
|
-
this.#resolveWaiter = undefined;
|
|
1792
|
-
runInAction(() => {
|
|
1793
|
-
this.#callback = undefined;
|
|
1794
|
-
this.#processing = false;
|
|
1795
|
-
Object.assign(this.draft, this.#savedDraft ?? saved);
|
|
1796
|
-
this.#savedDraft = undefined;
|
|
1797
|
-
});
|
|
1798
|
-
}
|
|
1799
|
-
}
|
|
1800
|
-
/** `/permissions [probe]`: the view, then Enter on a stored row revokes it and the view reloads. */
|
|
1801
|
-
async #showPermissions(probe) {
|
|
1802
|
-
const root = this.client.sessionRoot;
|
|
1803
|
-
let explain;
|
|
1804
|
-
const parsed = parseProbe(probe);
|
|
1805
|
-
for (;;) {
|
|
1806
|
-
if (parsed !== null) {
|
|
1807
|
-
explain = await this.client.request("policy/explain", { probe: parsed }).then((outcome) => ({ probe, outcome: outcome }), (error) => ({
|
|
1808
|
-
probe,
|
|
1809
|
-
outcome: null,
|
|
1810
|
-
error: error instanceof Error ? error.message : String(error),
|
|
1811
|
-
}));
|
|
1812
|
-
}
|
|
1813
|
-
const listing = { sessionId: root.sessionId, projectPath: root.path };
|
|
1814
|
-
const rows = async (method) => this.client.request(method, listing).then((out) => out.rows, (error) => {
|
|
1815
|
-
fail(method, error);
|
|
1816
|
-
return [];
|
|
1817
|
-
});
|
|
1818
|
-
const view = permissionsView({
|
|
1819
|
-
mode: root.permissionMode,
|
|
1820
|
-
layers: layersOf({
|
|
1821
|
-
user: root.authorizationUserJson,
|
|
1822
|
-
project: root.authorizationProjectJson,
|
|
1823
|
-
session: root.authorizationOverlayJson,
|
|
1824
|
-
}),
|
|
1825
|
-
grants: await rows("grant/list"),
|
|
1826
|
-
acks: await rows("ack/list"),
|
|
1827
|
-
nowMs: this.#now(),
|
|
1828
|
-
...(explain === undefined ? {} : { explain }),
|
|
1829
|
-
});
|
|
1830
|
-
const answer = await this.#parkSurface(permissionsSurface(view));
|
|
1831
|
-
const picked = answer.kind === "revoke" && typeof answer.index === "number" ? view.revocable[answer.index] : undefined;
|
|
1832
|
-
if (picked === undefined)
|
|
1833
|
-
return;
|
|
1834
|
-
await this.client.request(picked.revoke.method, picked.revoke.params).catch((error) => fail(picked.revoke.method, error));
|
|
1835
|
-
}
|
|
1836
|
-
}
|
|
1837
|
-
async #awaitCallback(form) {
|
|
1838
|
-
const values = await exec(form.body, {
|
|
1839
|
-
capabilities: COMMAND_CAPABILITIES,
|
|
1840
|
-
config: this.#commandConfig({ pending: form.pending }),
|
|
1841
|
-
});
|
|
1842
|
-
const surface = values.at(-1);
|
|
1843
|
-
invariant(surface instanceof UiNode, "ui form body did not eval to a UiNode");
|
|
1844
|
-
const saved = this.#savedDraft ?? {
|
|
1845
|
-
draft: this.draft.draft,
|
|
1846
|
-
cursor: this.draft.cursor,
|
|
1847
|
-
mark: this.draft.mark,
|
|
1848
|
-
};
|
|
1849
|
-
this.#savedDraft = saved;
|
|
1850
|
-
runInAction(() => {
|
|
1851
|
-
this.#callback = { pending: form.pending, surface };
|
|
1852
|
-
this.#processing = false;
|
|
1853
|
-
this.#focus = undefined;
|
|
1854
|
-
this.draft = { draft: "", cursor: 0, mark: null };
|
|
1855
|
-
this.#resetSelection();
|
|
1856
|
-
this.escClearArmed = false;
|
|
1857
|
-
});
|
|
1858
|
-
const answerPromise = new Promise((resolve) => {
|
|
1859
|
-
this.#resolveWaiter = resolve;
|
|
1860
|
-
});
|
|
1861
|
-
const url = urlFrom(surface);
|
|
1862
|
-
// No field to type in (Nous): the link opens now and Enter means "continue".
|
|
1863
|
-
if (url !== undefined && !hasInputHole(surface))
|
|
1864
|
-
this.#openUrl(url);
|
|
1865
|
-
try {
|
|
1866
|
-
let answer = await answerPromise;
|
|
1867
|
-
step(`oauth resolve keys=${Object.keys(answer).sort().join(",")}`);
|
|
1868
|
-
// An empty field on a link park is "open it": the daemon owns the callback and waits for it.
|
|
1869
|
-
if (url !== undefined && answer.kind === "text" && answer.input === "") {
|
|
1870
|
-
this.#openUrl(url);
|
|
1871
|
-
answer = { kind: "opened", url };
|
|
1872
|
-
}
|
|
1873
|
-
if (answer.kind === "opened") {
|
|
1874
|
-
this.#waitingPending = form.pending;
|
|
1875
|
-
runInAction(() => {
|
|
1876
|
-
this.#oauthWaiting = true;
|
|
1877
|
-
});
|
|
1878
|
-
}
|
|
1879
|
-
return await this.client.request("ui/resolve", { pending: form.pending, ...answer });
|
|
1880
|
-
}
|
|
1881
|
-
finally {
|
|
1882
|
-
this.#waitingPending = undefined;
|
|
1883
|
-
this.#resolveWaiter = undefined;
|
|
1884
|
-
runInAction(() => {
|
|
1885
|
-
this.#oauthWaiting = false;
|
|
1886
|
-
this.#processing = false;
|
|
1887
|
-
this.#callback = undefined;
|
|
1888
|
-
Object.assign(this.draft, this.#savedDraft ?? saved);
|
|
1889
|
-
this.#savedDraft = undefined;
|
|
1890
|
-
});
|
|
1891
|
-
}
|
|
1892
|
-
}
|
|
1893
|
-
#openUrl(url) {
|
|
1894
|
-
let host;
|
|
1895
|
-
try {
|
|
1896
|
-
host = new URL(url).host;
|
|
1897
|
-
}
|
|
1898
|
-
catch {
|
|
1899
|
-
host = "invalid";
|
|
1900
|
-
}
|
|
1901
|
-
step(`oauth open ${host}`);
|
|
1902
|
-
this.#open(url);
|
|
1903
|
-
}
|
|
1904
|
-
/** Esc on "Waiting for the browser…": abort the daemon's wait; the `opened` request then settles. */
|
|
1905
|
-
#cancelWaiting() {
|
|
1906
|
-
const pending = this.#waitingPending;
|
|
1907
|
-
if (pending === undefined)
|
|
1908
|
-
return;
|
|
1909
|
-
this.#waitingPending = undefined;
|
|
1910
|
-
this.client.request("ui/resolve", { pending, kind: "cancel" }).catch((error) => {
|
|
1911
|
-
fail("oauth cancel", error);
|
|
1912
|
-
});
|
|
1913
|
-
}
|
|
1914
|
-
#completeCallback(params) {
|
|
1915
|
-
const waiter = this.#resolveWaiter;
|
|
1916
|
-
this.#resolveWaiter = undefined;
|
|
1917
|
-
if (params.kind !== "cancel") {
|
|
1918
|
-
runInAction(() => {
|
|
1919
|
-
this.#processing = true;
|
|
1920
|
-
});
|
|
1921
|
-
}
|
|
1922
|
-
waiter?.(params);
|
|
1923
|
-
}
|
|
1924
|
-
get #activeConnection() { return _private_get_activeConnection_descriptor.get.call(this); }
|
|
1925
|
-
/** Top-right omnibox annotation: failed head, else the selected wire's sticky error. */
|
|
1926
|
-
#errorAnnotation() {
|
|
1927
|
-
const head = this.client.sessionRoot.head;
|
|
1928
|
-
if (head instanceof SessionTurn && !isRetrying(head, this.#now())) {
|
|
1929
|
-
const chunks = reactChunks(head);
|
|
1930
|
-
for (let i = chunks.length - 1; i >= 0; i -= 1) {
|
|
1931
|
-
const pew = tapeCompletion(chunks[i]);
|
|
1932
|
-
if (pew == null || pew.outcome !== "failed")
|
|
1933
|
-
continue;
|
|
1934
|
-
if (isCompletionCutoff(pew))
|
|
1935
|
-
continue;
|
|
1936
|
-
const picked = pew.endDetail ?? pew.failReason;
|
|
1937
|
-
return { level: "error", message: picked == null ? "turn failed" : picked.trim() };
|
|
1938
|
-
}
|
|
1939
|
-
}
|
|
1940
|
-
const connection = this.#activeConnection;
|
|
1941
|
-
if (connection != null) {
|
|
1942
|
-
const message = nonempty(connection.error);
|
|
1943
|
-
const failed = connection.readyState === "failed";
|
|
1944
|
-
const authLine = failed && authStatusLine(message);
|
|
1945
|
-
if (authLine)
|
|
1946
|
-
return { level: "error", message: "The key was refused. Reconnect." };
|
|
1947
|
-
if (failed && message !== "")
|
|
1948
|
-
return { level: "error", message };
|
|
1949
|
-
if (connection.live.auth === "needs-auth") {
|
|
1950
|
-
const id = connection.id.trim();
|
|
1951
|
-
const who = id === "" ? "connection" : `connection ${id}`;
|
|
1952
|
-
return { level: "error", message: `${who} needs auth — reconnect` };
|
|
1953
|
-
}
|
|
1954
|
-
if (failed)
|
|
1955
|
-
return { level: "error", message: "connection failed" };
|
|
1956
|
-
}
|
|
1957
|
-
return this.#pluginAnnotation();
|
|
1958
|
-
}
|
|
1959
|
-
/** The session's plugin behavior problem, else the first installed plugin that failed to load. */
|
|
1960
|
-
#pluginAnnotation() {
|
|
1961
|
-
const session = nonempty(this.client.sessionRoot.pluginProblem);
|
|
1962
|
-
if (session !== "")
|
|
1963
|
-
return { level: "warning", message: session };
|
|
1964
|
-
for (const plugin of Object.values(this.client.kernelRoot.plugins ?? {})) {
|
|
1965
|
-
const problem = plugin.enabled ? nonempty(plugin.problem) : "";
|
|
1966
|
-
if (problem !== "")
|
|
1967
|
-
return { level: "warning", message: `${plugin.pluginName}: ${problem}` };
|
|
1968
|
-
}
|
|
1969
|
-
return undefined;
|
|
1970
|
-
}
|
|
1971
|
-
/** Persist-mod overlay data. Paint spells remaining from resetAt; Tea does not. */
|
|
1972
|
-
get #quotaWindows() { return _private_get_quotaWindows_descriptor.get.call(this); }
|
|
1973
|
-
/** Bottom-right omnibox chips: model, wire name, then auto / always approve. Manual is blank. */
|
|
1974
|
-
get #statusItems() { return _private_get_statusItems_descriptor.get.call(this); }
|
|
1975
|
-
get #remainder() {
|
|
1976
|
-
const line = (this.draft.draft.split("\n")[0] ?? "").trim();
|
|
1977
|
-
if (this.#callback !== undefined)
|
|
1978
|
-
return line;
|
|
1979
|
-
const verb = slashVerb(this.draft.draft);
|
|
1980
|
-
if (verb === null)
|
|
1981
|
-
return line;
|
|
1982
|
-
return line.slice(verb.length + 1).trim();
|
|
1983
|
-
}
|
|
1984
|
-
get #stepCoverThrottle() { return _private_stepCoverThrottle_descriptor.value; }
|
|
1985
|
-
#fireHotkeyEvent(event) {
|
|
1986
|
-
switch (event) {
|
|
1987
|
-
case HOTKEY_EVENT.allow:
|
|
1988
|
-
if (this.#processing || this.#oauthWaiting)
|
|
1989
|
-
return true;
|
|
1990
|
-
this.#answerAsk(true);
|
|
1991
|
-
return true;
|
|
1992
|
-
case HOTKEY_EVENT.allowSession:
|
|
1993
|
-
if (this.#processing || this.#oauthWaiting)
|
|
1994
|
-
return true;
|
|
1995
|
-
this.#answerAsk(true, { remember: "session" });
|
|
1996
|
-
return true;
|
|
1997
|
-
case HOTKEY_EVENT.allowAlways:
|
|
1998
|
-
if (this.#processing || this.#oauthWaiting)
|
|
1999
|
-
return true;
|
|
2000
|
-
this.#answerAsk(true, { remember: "project" });
|
|
2001
|
-
return true;
|
|
2002
|
-
case HOTKEY_EVENT.ackRemember: {
|
|
2003
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2004
|
-
return true;
|
|
2005
|
-
const choice = this.#ackPrompt?.choices[this.#ackIndex];
|
|
2006
|
-
if (choice !== undefined)
|
|
2007
|
-
this.#answerAsk(true, { ackChoice: choice });
|
|
2008
|
-
return true;
|
|
2009
|
-
}
|
|
2010
|
-
case HOTKEY_EVENT.ackNext:
|
|
2011
|
-
case HOTKEY_EVENT.ackPrev: {
|
|
2012
|
-
const leaf = this.#askHead;
|
|
2013
|
-
const size = this.#ackPrompt?.choices.length ?? 0;
|
|
2014
|
-
if (leaf == null || size === 0)
|
|
2015
|
-
return true;
|
|
2016
|
-
this.#ackPick = {
|
|
2017
|
-
id: leaf.uuid,
|
|
2018
|
-
index: cycleAck(this.#ackIndex, size, event === HOTKEY_EVENT.ackNext ? 1 : -1),
|
|
2019
|
-
};
|
|
2020
|
-
return true;
|
|
2021
|
-
}
|
|
2022
|
-
case HOTKEY_EVENT.allowWiden: {
|
|
2023
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2024
|
-
return true;
|
|
2025
|
-
const widen = this.#readWiden;
|
|
2026
|
-
this.#answerAsk(true, { widen: widen?.path });
|
|
2027
|
-
return true;
|
|
2028
|
-
}
|
|
2029
|
-
case HOTKEY_EVENT.deny:
|
|
2030
|
-
if (this.#processing)
|
|
2031
|
-
return true;
|
|
2032
|
-
this.#answerAsk(false);
|
|
2033
|
-
return true;
|
|
2034
|
-
case HOTKEY_EVENT.denySession:
|
|
2035
|
-
if (this.#processing)
|
|
2036
|
-
return true;
|
|
2037
|
-
this.#answerAsk(false, { persist: "session" });
|
|
2038
|
-
return true;
|
|
2039
|
-
case HOTKEY_EVENT.denyAlways:
|
|
2040
|
-
if (this.#processing)
|
|
2041
|
-
return true;
|
|
2042
|
-
this.#answerAsk(false, { persist: "always" });
|
|
2043
|
-
return true;
|
|
2044
|
-
case HOTKEY_EVENT.retry:
|
|
2045
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2046
|
-
return true;
|
|
2047
|
-
this.#fire([new UiNode("turn/retry", "", [], "ok", "", undefined, [], [], [], "turn/retry", {})], true);
|
|
2048
|
-
return true;
|
|
2049
|
-
case HOTKEY_EVENT.queueMessage: {
|
|
2050
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2051
|
-
return true;
|
|
2052
|
-
if (!this.#submitTurn("queue"))
|
|
2053
|
-
return true;
|
|
2054
|
-
return true;
|
|
2055
|
-
}
|
|
2056
|
-
case HOTKEY_EVENT.steerFirst:
|
|
2057
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2058
|
-
return true;
|
|
2059
|
-
this.#queueMove("queue/steer-first", this.client.sessionRoot.promptQueue[0]);
|
|
2060
|
-
return true;
|
|
2061
|
-
case HOTKEY_EVENT.continue: {
|
|
2062
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2063
|
-
return true;
|
|
2064
|
-
const head = this.client.sessionRoot.head;
|
|
2065
|
-
if (head instanceof SessionTurn && head.lastTurnIncomplete && isAtTip(head, this.client.sessionRoot.tip)) {
|
|
2066
|
-
this.#fire([
|
|
2067
|
-
new UiNode("turn", "", [], "ok", "", undefined, [], [], [], "turn", {
|
|
2068
|
-
prompt: "",
|
|
2069
|
-
kind: "continue",
|
|
2070
|
-
}),
|
|
2071
|
-
], true);
|
|
2072
|
-
}
|
|
2073
|
-
return true;
|
|
2074
|
-
}
|
|
2075
|
-
case HOTKEY_EVENT.clear:
|
|
2076
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2077
|
-
this.escClearArmed = false;
|
|
2078
|
-
this.#resetSelection();
|
|
2079
|
-
return true;
|
|
2080
|
-
case HOTKEY_EVENT.cancelTurn: {
|
|
2081
|
-
const running = this.client.sessionRoot.findRunningTurn();
|
|
2082
|
-
this.escClearArmed = false;
|
|
2083
|
-
this.#drainAsk = false;
|
|
2084
|
-
this.#askHold = false;
|
|
2085
|
-
if (running != null)
|
|
2086
|
-
this.#requestTurnCancel(running);
|
|
2087
|
-
return true;
|
|
2088
|
-
}
|
|
2089
|
-
default:
|
|
2090
|
-
return true;
|
|
2091
|
-
}
|
|
2092
|
-
}
|
|
2093
|
-
/**
|
|
2094
|
-
* One human answer. `remember` stores the family the daemon offered for this exact call (an ask;
|
|
2095
|
-
* a soft-deny offers none). `widen` says yes to "Treat <folder> as part of this session?".
|
|
2096
|
-
* `persist` hides a refused MCP look-up. The daemon checks all three; a refusal here is a no-op.
|
|
2097
|
-
*/
|
|
2098
|
-
#answerAsk(allow, opts = {}) {
|
|
2099
|
-
const leaf = this.#askHead;
|
|
2100
|
-
if (leaf === null || leaf.humanApprove !== null)
|
|
2101
|
-
return;
|
|
2102
|
-
const comment = this.#coverDraft.draft.trim();
|
|
2103
|
-
const desk = this.client.sessionRoot;
|
|
2104
|
-
const ack = this.#ackPrompt;
|
|
2105
|
-
let combinedAckStore;
|
|
2106
|
-
if (ack !== null) {
|
|
2107
|
-
const picked = ack.choices[this.#ackIndex];
|
|
2108
|
-
const ackStore = !allow || comment !== ""
|
|
2109
|
-
? undefined
|
|
2110
|
-
: opts.ackChoice !== undefined
|
|
2111
|
-
? { scope: opts.ackChoice.scope, subject: opts.ackChoice.subject }
|
|
2112
|
-
: opts.remember !== undefined && picked !== undefined
|
|
2113
|
-
? { scope: opts.remember, subject: picked.subject }
|
|
2114
|
-
: undefined;
|
|
2115
|
-
const own = desk.findRunningTurn()?.approvalHead === leaf;
|
|
2116
|
-
const sessionId = own ? desk.sessionId : (this.#askPlexus?.root.sessionId ?? desk.sessionId);
|
|
2117
|
-
if (ack.variant === "ack") {
|
|
2118
|
-
// Allowed by policy; only the acknowledgement is asked.
|
|
2119
|
-
void this.client
|
|
2120
|
-
.request("ack/answer", {
|
|
2121
|
-
sessionId,
|
|
2122
|
-
jobId: leaf.uuid,
|
|
2123
|
-
ackId: leaf.uuid,
|
|
2124
|
-
accept: allow,
|
|
2125
|
-
...(ackStore === undefined ? {} : { store: ackStore }),
|
|
2126
|
-
...(comment === "" ? {} : { comment }),
|
|
2127
|
-
})
|
|
2128
|
-
.catch((error) => fail("ack/answer", error));
|
|
2129
|
-
this.#drainAsk = true;
|
|
2130
|
-
this.#askHold = true;
|
|
2131
|
-
this.#coverDraft = { draft: "", cursor: 0, mark: null };
|
|
2132
|
-
this.#stepCoverThrottle();
|
|
2133
|
-
return;
|
|
2134
|
-
}
|
|
2135
|
-
// A combined prompt: the human yes settles both; remembering the flag rides as `ackStore`.
|
|
2136
|
-
combinedAckStore = ackStore;
|
|
2137
|
-
}
|
|
2138
|
-
// A kernel-wide "never this tool" is a kernel RPC; everything on the session is the daemon's answer.
|
|
2139
|
-
if (opts.persist === "always" && comment === "" && !allow) {
|
|
2140
|
-
if (leaf instanceof MCPToolJob && mcpReadFloorDenies(leaf.serverToolName))
|
|
2141
|
-
this.#persistGlobal(leaf, false);
|
|
2142
|
-
}
|
|
2143
|
-
const subject = leaf.grantOptions[0]?.subject;
|
|
2144
|
-
const store = allow && comment === "" && opts.remember !== undefined && subject !== undefined
|
|
2145
|
-
? { scope: opts.remember, subject }
|
|
2146
|
-
: undefined;
|
|
2147
|
-
const own = desk.findRunningTurn()?.approvalHead === leaf;
|
|
2148
|
-
void this.client
|
|
2149
|
-
.request("ask/answer", {
|
|
2150
|
-
sessionId: own ? desk.sessionId : (this.#askPlexus?.root.sessionId ?? desk.sessionId),
|
|
2151
|
-
jobId: leaf.uuid,
|
|
2152
|
-
allow,
|
|
2153
|
-
...(comment === "" ? {} : { comment }),
|
|
2154
|
-
...(opts.widen === undefined || opts.widen === "" ? {} : { widen: opts.widen }),
|
|
2155
|
-
...(store === undefined ? {} : { store }),
|
|
2156
|
-
...(combinedAckStore === undefined ? {} : { ackStore: combinedAckStore }),
|
|
2157
|
-
...(opts.persist === undefined || allow ? {} : { persist: opts.persist }),
|
|
2158
|
-
})
|
|
2159
|
-
.catch((error) => fail("ask/answer", error));
|
|
2160
|
-
this.#drainAsk = true;
|
|
2161
|
-
this.#askHold = true;
|
|
2162
|
-
this.#coverDraft = { draft: "", cursor: 0, mark: null };
|
|
2163
|
-
this.#stepCoverThrottle();
|
|
2164
|
-
}
|
|
2165
|
-
#setResident(resident) {
|
|
2166
|
-
return this.client.request("resident/set", { resident }).catch((error) => fail("resident/set", error));
|
|
2167
|
-
}
|
|
2168
|
-
/** The daemon moves the row; a local shift would merge with its turn-close drain. */
|
|
2169
|
-
#queueMove(op, row) {
|
|
2170
|
-
if (row == null)
|
|
2171
|
-
return;
|
|
2172
|
-
this.#fire([new UiNode(op, "", [], "ok", "", undefined, [], [], [], op, { id: row.uuid })]);
|
|
2173
|
-
}
|
|
2174
|
-
/** Paint the cancel before the daemon stamps it; the turn's flag stays the daemon's to write. */
|
|
2175
|
-
#askCancel(turn) {
|
|
2176
|
-
runInAction(() => this.#cancelAsked.add(turn));
|
|
2177
|
-
this.#disposers.push(when(() => turn.cutOff || !turn.inLoop, () => runInAction(() => this.#cancelAsked.delete(turn))));
|
|
2178
|
-
}
|
|
2179
|
-
#requestTurnCancel(turn) {
|
|
2180
|
-
this.#askCancel(turn);
|
|
2181
|
-
this.#rewindGraceUntil = this.#now() + REWIND_GRACE_MS;
|
|
2182
|
-
this.#fire([
|
|
2183
|
-
new UiNode("turn/cancel", "", [], "ok", "", undefined, [], [], [], "turn/cancel", {
|
|
2184
|
-
turnId: turn.uuid,
|
|
2185
|
-
}),
|
|
2186
|
-
], true);
|
|
2187
|
-
}
|
|
2188
|
-
#handleEscapeUnwind(seat) {
|
|
2189
|
-
if (this.#oauthWaiting) {
|
|
2190
|
-
this.#cancelWaiting();
|
|
2191
|
-
return true;
|
|
2192
|
-
}
|
|
2193
|
-
if (this.#processing)
|
|
2194
|
-
return true;
|
|
2195
|
-
if (seat.input === "overlay" || seat.input === "auth" || this.#callback !== undefined) {
|
|
2196
|
-
this.#completeCallback({ kind: "cancel" });
|
|
2197
|
-
return true;
|
|
2198
|
-
}
|
|
2199
|
-
if (this.#focus !== undefined) {
|
|
2200
|
-
this.#focus = undefined;
|
|
2201
|
-
this.#resetSelection();
|
|
2202
|
-
this.escClearArmed = false;
|
|
2203
|
-
return true;
|
|
2204
|
-
}
|
|
2205
|
-
if (this.draft.draft.length > 0 && !this.#historyNav) {
|
|
2206
|
-
if (this.escClearArmed) {
|
|
2207
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2208
|
-
this.escClearArmed = false;
|
|
2209
|
-
this.#resetSelection();
|
|
2210
|
-
}
|
|
2211
|
-
else {
|
|
2212
|
-
this.escClearArmed = true;
|
|
2213
|
-
}
|
|
2214
|
-
return true;
|
|
2215
|
-
}
|
|
2216
|
-
// see omnibox-seat.ts, CHANGE ONLY.
|
|
2217
|
-
if (this.client.sessionRoot.promptQueue.length > 0 && !this.#drainAsk && !this.#askHold) {
|
|
2218
|
-
this.#queueMove("queue/retract-last", this.client.sessionRoot.promptQueue.at(-1));
|
|
2219
|
-
this.escClearArmed = false;
|
|
2220
|
-
return true;
|
|
2221
|
-
}
|
|
2222
|
-
const running = this.client.sessionRoot.findRunningTurn();
|
|
2223
|
-
if (running != null) {
|
|
2224
|
-
if (this.escClearArmed) {
|
|
2225
|
-
this.escClearArmed = false;
|
|
2226
|
-
this.#drainAsk = false;
|
|
2227
|
-
this.#askHold = false;
|
|
2228
|
-
this.#requestTurnCancel(running);
|
|
2229
|
-
}
|
|
2230
|
-
else {
|
|
2231
|
-
this.escClearArmed = true;
|
|
2232
|
-
}
|
|
2233
|
-
return true;
|
|
2234
|
-
}
|
|
2235
|
-
if (this.#historyNav) {
|
|
2236
|
-
this.#leaveHistory();
|
|
2237
|
-
this.escClearArmed = false;
|
|
2238
|
-
return true;
|
|
2239
|
-
}
|
|
2240
|
-
if (this.#rewindGraceActive()) {
|
|
2241
|
-
this.escClearArmed = false;
|
|
2242
|
-
return true;
|
|
2243
|
-
}
|
|
2244
|
-
if (this.#viewTurn() == null) {
|
|
2245
|
-
this.escClearArmed = false;
|
|
2246
|
-
return true;
|
|
2247
|
-
}
|
|
2248
|
-
if (this.escClearArmed) {
|
|
2249
|
-
this.escClearArmed = false;
|
|
2250
|
-
this.#enterHistory();
|
|
2251
|
-
}
|
|
2252
|
-
else {
|
|
2253
|
-
this.escClearArmed = true;
|
|
2254
|
-
}
|
|
2255
|
-
return true;
|
|
2256
|
-
}
|
|
2257
|
-
#rewindGraceActive() {
|
|
2258
|
-
if (this.client.sessionRoot.findRunningTurn() != null)
|
|
2259
|
-
return false;
|
|
2260
|
-
return this.#now() < this.#rewindGraceUntil;
|
|
2261
|
-
}
|
|
2262
|
-
#handleRewindArrows(event, chord) {
|
|
2263
|
-
if (this.#callback !== undefined)
|
|
2264
|
-
return false;
|
|
2265
|
-
if (chord || event.shift === true)
|
|
2266
|
-
return false;
|
|
2267
|
-
if (event.key !== "ArrowUp" && event.key !== "ArrowDown")
|
|
2268
|
-
return false;
|
|
2269
|
-
if (!this.#browsing())
|
|
2270
|
-
return false;
|
|
2271
|
-
if (this.client.sessionRoot.findRunningTurn() != null)
|
|
2272
|
-
return false;
|
|
2273
|
-
const view = this.#viewTurn();
|
|
2274
|
-
const target = event.key === "ArrowUp" ? previousPin(view) : view ? (this.#aheadOf(view)[0] ?? null) : null;
|
|
2275
|
-
if (target != null)
|
|
2276
|
-
this.#moveView(target);
|
|
2277
|
-
return true;
|
|
2278
|
-
}
|
|
2279
|
-
#hostRewind() {
|
|
2280
|
-
if (this.#remainder.trim() !== "") {
|
|
2281
|
-
void this.#showNotice("usage: /rewind");
|
|
2282
|
-
return;
|
|
2283
|
-
}
|
|
2284
|
-
const pin = previousPin(this.#viewTurn());
|
|
2285
|
-
if (pin == null) {
|
|
2286
|
-
void this.#showNotice("nothing to rewind");
|
|
2287
|
-
return;
|
|
2288
|
-
}
|
|
2289
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2290
|
-
this.#resetSelection();
|
|
2291
|
-
this.#moveView(pin);
|
|
2292
|
-
}
|
|
2293
|
-
#confirmHistory() {
|
|
2294
|
-
if (this.#rewindPending)
|
|
2295
|
-
return;
|
|
2296
|
-
const target = this.#viewTurn();
|
|
2297
|
-
if (target == null)
|
|
2298
|
-
return;
|
|
2299
|
-
if (target.visuals.length > 0) {
|
|
2300
|
-
void this.#showNotice("pictures on this turn can be edited in the web or mobile app");
|
|
2301
|
-
return;
|
|
2302
|
-
}
|
|
2303
|
-
const head = this.client.sessionRoot.head;
|
|
2304
|
-
const tip = resolvedTip(head, this.client.sessionRoot.tip);
|
|
2305
|
-
// The selected message is what the operator is about to resend, so it
|
|
2306
|
-
// leaves the tape. Head lands on the previous user message. The immediate
|
|
2307
|
-
// tail is often a promptless continue or compact, and the daemon refuses
|
|
2308
|
-
// those (`not-a-pin`). Nothing before the first message is a prefill.
|
|
2309
|
-
const before = previousPin(target);
|
|
2310
|
-
const ceiling = target === head && isAtTip(head, tip);
|
|
2311
|
-
if (before == null || (ceiling && target.prompt.trim() === "")) {
|
|
2312
|
-
// First message, or a promptless ceiling: there is no pin to cut to.
|
|
2313
|
-
// Prefilling "" and closing navigation lets the same Enter fall through
|
|
2314
|
-
// into `kind: "continue"`. A real first-message prompt is the resend.
|
|
2315
|
-
const prefill = ceiling && target.prompt.trim() === "" ? "" : target.prompt;
|
|
2316
|
-
this.#restoredDraft = prefill === "" ? null : { turnId: target.uuid, prompt: prefill };
|
|
2317
|
-
Object.assign(this.draft, { draft: prefill, cursor: prefill.length, mark: null });
|
|
2318
|
-
this.#resetSelection();
|
|
2319
|
-
this.#leaveHistory();
|
|
2320
|
-
return;
|
|
2321
|
-
}
|
|
2322
|
-
void this.#requestRewind(before.uuid, target.prompt);
|
|
2323
|
-
}
|
|
2324
|
-
async #requestRewind(turnId, draft) {
|
|
2325
|
-
if (this.#rewindPending)
|
|
2326
|
-
return;
|
|
2327
|
-
this.#rewindPending = true;
|
|
2328
|
-
try {
|
|
2329
|
-
const result = await this.client.request("turn/rewind", { turnId });
|
|
2330
|
-
if (typeof result === "object" &&
|
|
2331
|
-
result !== null &&
|
|
2332
|
-
"ok" in result &&
|
|
2333
|
-
result.ok === false) {
|
|
2334
|
-
await this.#showNotice("nothing to rewind");
|
|
2335
|
-
return;
|
|
2336
|
-
}
|
|
2337
|
-
runInAction(() => {
|
|
2338
|
-
this.#restoredDraft = draft === "" ? null : { turnId, prompt: draft };
|
|
2339
|
-
Object.assign(this.draft, { draft, cursor: draft.length, mark: null });
|
|
2340
|
-
this.#resetSelection();
|
|
2341
|
-
this.#leaveHistory();
|
|
2342
|
-
});
|
|
2343
|
-
}
|
|
2344
|
-
catch (error) {
|
|
2345
|
-
await this.#showNotice(error instanceof Error ? error.message : String(error));
|
|
2346
|
-
}
|
|
2347
|
-
finally {
|
|
2348
|
-
this.#rewindPending = false;
|
|
2349
|
-
}
|
|
2350
|
-
}
|
|
2351
|
-
#hostNew() {
|
|
2352
|
-
const remainder = this.#remainder;
|
|
2353
|
-
const path = this.client.sessionRoot.path;
|
|
2354
|
-
// The turn is shared. Cancel only when this window is the last seat —
|
|
2355
|
-
// another open window is still watching the loop.
|
|
2356
|
-
const running = otherSessionSeatCount(this.client.kernelPlexus.awareness, this.client.sessionId) === 0
|
|
2357
|
-
? this.client.sessionRoot.findRunningTurn()
|
|
2358
|
-
: null;
|
|
2359
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2360
|
-
this.#resetSelection();
|
|
2361
|
-
if (this.#replaceSession === undefined)
|
|
2362
|
-
return;
|
|
2363
|
-
const fire = () => {
|
|
2364
|
-
this.#replaceSession?.({ path, ...(remainder === "" ? {} : { draft: remainder }) });
|
|
2365
|
-
};
|
|
2366
|
-
if (running == null) {
|
|
2367
|
-
fire();
|
|
2368
|
-
return;
|
|
2369
|
-
}
|
|
2370
|
-
this.#processing = true;
|
|
2371
|
-
this.#askCancel(running);
|
|
2372
|
-
void this.client
|
|
2373
|
-
.request("turn/cancel", { turnId: running.uuid })
|
|
2374
|
-
.catch((error) => fail("turn/cancel", error))
|
|
2375
|
-
.finally(() => {
|
|
2376
|
-
this.#processing = false;
|
|
2377
|
-
fire();
|
|
2378
|
-
});
|
|
2379
|
-
}
|
|
2380
|
-
#persistGlobal(leaf, allow) {
|
|
2381
|
-
const method = allow ? "connect/always-allow" : "connect/exclude-tool";
|
|
2382
|
-
void this.client.request(method, { id: leaf.connectionKey, tool: leaf.serverToolName }).catch((error) => {
|
|
2383
|
-
fail(method, error);
|
|
2384
|
-
});
|
|
2385
|
-
}
|
|
2386
|
-
#handleHotkey(event) {
|
|
2387
|
-
const seat = this.#omnibox;
|
|
2388
|
-
const rows = this.#pickerRows;
|
|
2389
|
-
const i = this.#selectedIndex;
|
|
2390
|
-
const selected = rows?.[i];
|
|
2391
|
-
const chord = event.ctrl === true || event.meta === true || event.alt === true;
|
|
2392
|
-
if (this.#handleAgentsChord(event, seat))
|
|
2393
|
-
return true;
|
|
2394
|
-
if (event.key === "Tab" && event.shift === true && !chord) {
|
|
2395
|
-
const ids = PERMISSION_MODES;
|
|
2396
|
-
const current = this.#askedPolicy ?? this.client.sessionRoot.permissionMode;
|
|
2397
|
-
const next = ids[(ids.indexOf(current) + 1) % ids.length];
|
|
2398
|
-
// The daemon writes the mode; cycle from what was asked until the replica shows it.
|
|
2399
|
-
this.#askedPolicy = next;
|
|
2400
|
-
void this.client
|
|
2401
|
-
.request("policy/set", { policy: next })
|
|
2402
|
-
.catch((error) => {
|
|
2403
|
-
fail("policy/set", error);
|
|
2404
|
-
})
|
|
2405
|
-
.finally(() => {
|
|
2406
|
-
if (this.#askedPolicy === next)
|
|
2407
|
-
this.#askedPolicy = null;
|
|
2408
|
-
});
|
|
2409
|
-
return true;
|
|
2410
|
-
}
|
|
2411
|
-
if (this.#browsing() &&
|
|
2412
|
-
this.#callback === undefined &&
|
|
2413
|
-
!chord &&
|
|
2414
|
-
event.shift !== true &&
|
|
2415
|
-
(event.key === "Enter" || event.key === "Escape")) {
|
|
2416
|
-
if (event.key === "Escape") {
|
|
2417
|
-
if (!this.#rewindPending)
|
|
2418
|
-
this.#leaveHistory();
|
|
2419
|
-
return true;
|
|
2420
|
-
}
|
|
2421
|
-
this.#confirmHistory();
|
|
2422
|
-
return true;
|
|
2423
|
-
}
|
|
2424
|
-
if (this.#historyHidesOmnibox && !chord && event.shift !== true && this.#handleRewindArrows(event, chord))
|
|
2425
|
-
return true;
|
|
2426
|
-
if (event.key === "Escape" && !chord) {
|
|
2427
|
-
const target = this.#askIsolated ? this.#coverDraft : this.draft;
|
|
2428
|
-
if (target.mark !== null && target.mark !== target.cursor) {
|
|
2429
|
-
Object.assign(target, { draft: target.draft, cursor: target.cursor, mark: null });
|
|
2430
|
-
return true;
|
|
2431
|
-
}
|
|
2432
|
-
}
|
|
2433
|
-
const painted = this.#paintComposerFace().hotkeys;
|
|
2434
|
-
const hit = painted?.find((hotkey) => hotkey.event !== undefined && eventMatchesChord(event, hotkey.key));
|
|
2435
|
-
if (hit?.event !== undefined) {
|
|
2436
|
-
if (seat.askChords === "inert")
|
|
2437
|
-
return true;
|
|
2438
|
-
// see omnibox-seat.ts, CHANGE ONLY.
|
|
2439
|
-
if ((this.#drainAsk || this.#askHold) && seat.askChords === "off" && event.key === "Enter") {
|
|
2440
|
-
return true;
|
|
2441
|
-
}
|
|
2442
|
-
return this.#fireHotkeyEvent(hit.event);
|
|
2443
|
-
}
|
|
2444
|
-
if (seat.askChords !== "off" && (event.key === "Enter" || event.key === "Escape")) {
|
|
2445
|
-
return true;
|
|
2446
|
-
}
|
|
2447
|
-
if ((this.#drainAsk || this.#askHold) && event.key === "Enter") {
|
|
2448
|
-
return true;
|
|
2449
|
-
}
|
|
2450
|
-
if (seat.input === "ask")
|
|
2451
|
-
return false;
|
|
2452
|
-
if (event.key === "Enter" && !chord && event.shift !== true) {
|
|
2453
|
-
if (this.#processing || this.#oauthWaiting)
|
|
2454
|
-
return true;
|
|
2455
|
-
if (selected !== undefined) {
|
|
2456
|
-
this.#pick(selected, true);
|
|
2457
|
-
return true;
|
|
2458
|
-
}
|
|
2459
|
-
if (seat.input === "overlay" || this.#callback !== undefined) {
|
|
2460
|
-
this.#fire(this.#parentNode?.action, true);
|
|
2461
|
-
return true;
|
|
2462
|
-
}
|
|
2463
|
-
if (this.#historyNav) {
|
|
2464
|
-
this.#confirmHistory();
|
|
2465
|
-
return true;
|
|
2466
|
-
}
|
|
2467
|
-
const verb = slashVerb(this.draft.draft);
|
|
2468
|
-
if (verb === "compact") {
|
|
2469
|
-
const focus = this.#remainder;
|
|
2470
|
-
this.#fire([new UiNode("compact", "", [], "ok", "", undefined, [], [], [], "compact", focus === "" ? {} : { focus })], true);
|
|
2471
|
-
return true;
|
|
2472
|
-
}
|
|
2473
|
-
if (verb === "rename") {
|
|
2474
|
-
const rest = this.#remainder;
|
|
2475
|
-
this.#fire([
|
|
2476
|
-
new UiNode("rename", "", [], "ok", "", undefined, [], [], [], "rename", {
|
|
2477
|
-
title: rest === "--auto" ? "" : rest,
|
|
2478
|
-
}),
|
|
2479
|
-
], true);
|
|
2480
|
-
return true;
|
|
2481
|
-
}
|
|
2482
|
-
if (verb !== null && isHostVerb(verb) && verb !== "compact" && verb !== "rename") {
|
|
2483
|
-
this.#invokeHostVerb(verb);
|
|
2484
|
-
return true;
|
|
2485
|
-
}
|
|
2486
|
-
if (verb !== null && this.#skillVerb(verb)) {
|
|
2487
|
-
this.#submitTurn(seat.input === "queue" ? "queue" : undefined);
|
|
2488
|
-
return true;
|
|
2489
|
-
}
|
|
2490
|
-
if (seat.input === "slash" || verb !== null) {
|
|
2491
|
-
this.#fire(this.#parentNode?.action, true);
|
|
2492
|
-
return true;
|
|
2493
|
-
}
|
|
2494
|
-
if (seat.input === "queue") {
|
|
2495
|
-
if (this.#submitTurn("queue"))
|
|
2496
|
-
return true;
|
|
2497
|
-
this.#queueMove("queue/steer-first", this.client.sessionRoot.promptQueue[0]);
|
|
2498
|
-
return true;
|
|
2499
|
-
}
|
|
2500
|
-
if (this.#submitTurn())
|
|
2501
|
-
return true;
|
|
2502
|
-
const head = this.client.sessionRoot.head;
|
|
2503
|
-
if (!isAtTip(head, this.client.sessionRoot.tip))
|
|
2504
|
-
return true;
|
|
2505
|
-
if (head instanceof SessionTurn && head.lastTurnIncomplete) {
|
|
2506
|
-
this.#fire([
|
|
2507
|
-
new UiNode("turn", "", [], "ok", "", undefined, [], [], [], "turn", {
|
|
2508
|
-
prompt: "",
|
|
2509
|
-
kind: "continue",
|
|
2510
|
-
}),
|
|
2511
|
-
], true);
|
|
2512
|
-
return true;
|
|
2513
|
-
}
|
|
2514
|
-
this.#fire(this.#parentNode?.action, true);
|
|
2515
|
-
return true;
|
|
2516
|
-
}
|
|
2517
|
-
if (event.key === "Escape" && !chord) {
|
|
2518
|
-
return this.#handleEscapeUnwind(seat);
|
|
2519
|
-
}
|
|
2520
|
-
if (rows !== undefined && rows.length > 0 && selected !== undefined && !chord && event.shift !== true) {
|
|
2521
|
-
if (event.key === "ArrowUp") {
|
|
2522
|
-
this.focusAt(i - 1);
|
|
2523
|
-
return true;
|
|
2524
|
-
}
|
|
2525
|
-
if (event.key === "ArrowDown") {
|
|
2526
|
-
this.focusAt(i + 1);
|
|
2527
|
-
return true;
|
|
2528
|
-
}
|
|
2529
|
-
if (event.key === "Tab") {
|
|
2530
|
-
this.#pick(selected, false);
|
|
2531
|
-
return true;
|
|
2532
|
-
}
|
|
2533
|
-
}
|
|
2534
|
-
if (this.#handleRewindArrows(event, chord))
|
|
2535
|
-
return true;
|
|
2536
|
-
const alt = selected?.alternateActions.find((item) => eventMatchesChord(event, item.hotkey ?? "")) ??
|
|
2537
|
-
this.#parentNode?.alternateActions.find((item) => eventMatchesChord(event, item.hotkey ?? ""));
|
|
2538
|
-
if (alt !== undefined) {
|
|
2539
|
-
this.#fire([alt]);
|
|
2540
|
-
return true;
|
|
2541
|
-
}
|
|
2542
|
-
return false;
|
|
2543
|
-
}
|
|
2544
|
-
#pick(node, invoke) {
|
|
2545
|
-
if (this.#atCatalog || node.choices.length > 0) {
|
|
2546
|
-
if (invoke && this.#atCatalog) {
|
|
2547
|
-
const verb = node.name.replace(/^\//, "");
|
|
2548
|
-
if (isHostVerb(verb) && verb !== "compact" && verb !== "rename") {
|
|
2549
|
-
this.#completeName(node);
|
|
2550
|
-
this.#resetSelection();
|
|
2551
|
-
this.#invokeHostVerb(verb);
|
|
2552
|
-
return;
|
|
2553
|
-
}
|
|
2554
|
-
}
|
|
2555
|
-
if (!this.#atCatalog)
|
|
2556
|
-
this.#focus = node;
|
|
2557
|
-
this.#completeName(node);
|
|
2558
|
-
this.#resetSelection();
|
|
2559
|
-
return;
|
|
2560
|
-
}
|
|
2561
|
-
this.#completeName(node);
|
|
2562
|
-
if (invoke && node.action.length > 0)
|
|
2563
|
-
this.#fire(node.action, true);
|
|
2564
|
-
}
|
|
2565
|
-
/** Catalog Enter on a host verb that has no CommandSpec body. */
|
|
2566
|
-
#invokeHostVerb(verb) {
|
|
2567
|
-
if (verb === "quit") {
|
|
2568
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2569
|
-
this.#resetSelection();
|
|
2570
|
-
this.#quit?.();
|
|
2571
|
-
return;
|
|
2572
|
-
}
|
|
2573
|
-
if (verb === "new") {
|
|
2574
|
-
this.#hostNew();
|
|
2575
|
-
return;
|
|
2576
|
-
}
|
|
2577
|
-
if (verb === "agentic") {
|
|
2578
|
-
const rest = this.#remainder.trim().toLowerCase();
|
|
2579
|
-
const flag = rest === "true" ? true : rest === "false" ? false : null;
|
|
2580
|
-
if (flag === null)
|
|
2581
|
-
return;
|
|
2582
|
-
void this.#setResident(flag);
|
|
2583
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2584
|
-
this.#resetSelection();
|
|
2585
|
-
return;
|
|
2586
|
-
}
|
|
2587
|
-
if (verb === "background") {
|
|
2588
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2589
|
-
this.#resetSelection();
|
|
2590
|
-
// Leave only after the daemon holds the bit; a replica write could die with this process.
|
|
2591
|
-
void this.#setResident(true).finally(() => this.#quit?.());
|
|
2592
|
-
return;
|
|
2593
|
-
}
|
|
2594
|
-
if (verb === "rewind" || verb === "undo") {
|
|
2595
|
-
this.#hostRewind();
|
|
2596
|
-
return;
|
|
2597
|
-
}
|
|
2598
|
-
if (verb === "permissions") {
|
|
2599
|
-
if (this.#callback !== undefined)
|
|
2600
|
-
return;
|
|
2601
|
-
const probe = this.#remainder.trim();
|
|
2602
|
-
Object.assign(this.draft, { draft: "", cursor: 0, mark: null });
|
|
2603
|
-
this.#resetSelection();
|
|
2604
|
-
void this.#showPermissions(probe);
|
|
2605
|
-
}
|
|
2606
|
-
}
|
|
2607
|
-
#completeName(node) {
|
|
2608
|
-
if (this.#atCatalog) {
|
|
2609
|
-
const draft = this.draft.draft;
|
|
2610
|
-
const nl = draft.indexOf("\n");
|
|
2611
|
-
const first = nl === -1 ? draft : draft.slice(0, nl);
|
|
2612
|
-
const rest = nl === -1 ? "" : draft.slice(nl);
|
|
2613
|
-
const lead = first.match(/^\s*/)?.[0] ?? "";
|
|
2614
|
-
const after = first.slice(lead.length);
|
|
2615
|
-
if (!after.startsWith("/")) {
|
|
2616
|
-
Object.assign(this.draft, { draft, cursor: draft.length, mark: null });
|
|
2617
|
-
return;
|
|
2618
|
-
}
|
|
2619
|
-
const sp = after.search(/\s/);
|
|
2620
|
-
const args = sp < 0 ? " " : after.slice(sp);
|
|
2621
|
-
const verb = node.name.replace(/^\//, "");
|
|
2622
|
-
const nextFirst = `${lead}/${verb}${args}`;
|
|
2623
|
-
Object.assign(this.draft, {
|
|
2624
|
-
draft: `${nextFirst}${rest}`,
|
|
2625
|
-
cursor: nextFirst.length,
|
|
2626
|
-
mark: null,
|
|
2627
|
-
});
|
|
2628
|
-
return;
|
|
2629
|
-
}
|
|
2630
|
-
const verb = slashVerb(this.draft.draft);
|
|
2631
|
-
if (verb === null)
|
|
2632
|
-
return;
|
|
2633
|
-
const draft = this.draft.draft;
|
|
2634
|
-
const nl = draft.indexOf("\n");
|
|
2635
|
-
const rest = nl === -1 ? "" : draft.slice(nl);
|
|
2636
|
-
const lead = (nl === -1 ? draft : draft.slice(0, nl)).match(/^\s*/)?.[0] ?? "";
|
|
2637
|
-
const nextFirst = `${lead}/${verb} ${node.name}`;
|
|
2638
|
-
Object.assign(this.draft, {
|
|
2639
|
-
draft: `${nextFirst}${rest}`,
|
|
2640
|
-
cursor: nextFirst.length,
|
|
2641
|
-
mark: null,
|
|
2642
|
-
});
|
|
2643
|
-
}
|
|
2644
|
-
/**
|
|
2645
|
-
* What the open picker looks at: the connections it lists, and the drivers
|
|
2646
|
-
* whose adopt doors it lists (so a driver can keep its offers fresh).
|
|
2647
|
-
*/
|
|
2648
|
-
get #attentionSubjects() { return _private_get_attentionSubjects_descriptor.get.call(this); }
|
|
2649
|
-
[(_draft_decorators = [observable], _submission_decorators = [observable], _selectedCommandKey_decorators = [observable], _scrollOffset_decorators = [observable], _escClearArmed_decorators = [observable], _cols_decorators = [observable], _rows_decorators = [observable], _private_busy_decorators = [observable], _private_callback_decorators = [observable], _private_focus_decorators = [observable], _private_oauthWaiting_decorators = [observable], _private_processing_decorators = [observable], _private_coverDraft_decorators = [observable], _private_coverThrottle_decorators = [(_a = observable).ref.bind(_a)], _private_coverConfirmLive_decorators = [observable], _private_ackPick_decorators = [observable], _private_askHold_decorators = [observable], _private_drainAsk_decorators = [observable], _private_agentsOpen_decorators = [observable], _private_agentsFocus_decorators = [observable], _private_agentsHover_decorators = [observable], _private_agentsScroll_decorators = [observable], _private_agentsPreview_decorators = [observable], _private_peekPlexus_decorators = [(_b = observable).ref.bind(_b)], _private_askPlexus_decorators = [(_c = observable).ref.bind(_c)], _private_viewPin_decorators = [(_d = observable).ref.bind(_d)], _private_historyNav_decorators = [observable], _private_restoredDraft_decorators = [(_e = observable).ref.bind(_e)], _private_get_agentDrawerRows_decorators = [computed], _private_get_sessionTitle_decorators = [computed], _private_get_isHeadAtTip_decorators = [computed], _private_get_askHead_decorators = [computed], _private_get_ackPrompt_decorators = [computed], _private_get_coverAskAgentSpec_decorators = [computed], _private_get_askHome_decorators = [computed], _private_get_readWiden_decorators = [computed], _private_get_omniboxValue_decorators = [computed], _private_get_contextRail_decorators = [computed({ equals: comparer.structural })], _private_get_omnibox_decorators = [computed], _private_get_askIsolated_decorators = [computed], _private_get_admissionDeckText_decorators = [computed], _private_get_waitChrome_decorators = [(_f = computed).struct.bind(_f)], _private_get_commands_decorators = [computed], _private_get_parentNode_decorators = [computed], _private_get_inCommand_decorators = [computed], _private_get_atCatalog_decorators = [computed], _private_get_pickerRows_decorators = [computed], _private_get_catalogNodes_decorators = [computed], _private_get_commandChoices_decorators = [computed], _get_effectiveKey_decorators = [computed], _private_get_commandAction_decorators = [computed], _private_get_commandSurface_decorators = [computed({ keepAlive: true })], _private_get_selectedIndex_decorators = [computed], _focusAt_decorators = [action], _handle_decorators = [action], _private_get_activeConnection_decorators = [computed], _private_get_quotaWindows_decorators = [computed({ equals: comparer.structural })], _private_get_statusItems_decorators = [computed({ equals: comparer.structural })], _private_stepCoverThrottle_decorators = [action], _private_get_attentionSubjects_decorators = [computed], Symbol.dispose)]() {
|
|
2650
|
-
if (this.#coverTimer !== undefined) {
|
|
2651
|
-
clearTimeout(this.#coverTimer);
|
|
2652
|
-
this.#coverTimer = undefined;
|
|
2653
|
-
}
|
|
2654
|
-
this.client.releasePeek();
|
|
2655
|
-
this.client.releaseAsk();
|
|
2656
|
-
this.client.setComputedAttention(() => []);
|
|
2657
|
-
this.client.setComputedAttentionFocus(() => null);
|
|
2658
|
-
this.#cancelWaiting();
|
|
2659
|
-
this.#completeCallback({ kind: "cancel" });
|
|
2660
|
-
for (const dispose of this.#disposers.splice(0))
|
|
2661
|
-
dispose();
|
|
2662
|
-
this.#paint[Symbol.dispose]();
|
|
2663
|
-
}
|
|
2664
|
-
};
|
|
2665
|
-
})();
|
|
2666
|
-
export { Tea };
|
|
2667
|
-
function primaryDisplayName(node) {
|
|
2668
|
-
const first = node.action[0];
|
|
2669
|
-
if (first === undefined)
|
|
2670
|
-
return undefined;
|
|
2671
|
-
const label = first.name.trim();
|
|
2672
|
-
if (label !== "" && label !== (first.op ?? ""))
|
|
2673
|
-
return label;
|
|
2674
|
-
return "select";
|
|
2675
|
-
}
|
|
2676
|
-
function isActivatable(node, catalog) {
|
|
2677
|
-
return catalog || node.choices.length > 0 || node.action.length > 0;
|
|
2678
|
-
}
|
|
2679
|
-
function pickerActions(node, catalog = false) {
|
|
2680
|
-
const first = node.action[0];
|
|
2681
|
-
const head = isActivatable(node, catalog)
|
|
2682
|
-
? [
|
|
2683
|
-
{
|
|
2684
|
-
name: first?.op ?? first?.name ?? node.name,
|
|
2685
|
-
displayName: primaryDisplayName(node) ?? "select",
|
|
2686
|
-
hotkey: "Enter",
|
|
2687
|
-
},
|
|
2688
|
-
]
|
|
2689
|
-
: [];
|
|
2690
|
-
const alts = node.alternateActions.map((alt) => ({
|
|
2691
|
-
name: alt.op ?? alt.name,
|
|
2692
|
-
displayName: alt.name,
|
|
2693
|
-
hotkey: alt.hotkey,
|
|
2694
|
-
}));
|
|
2695
|
-
return [...head, ...alts];
|
|
2696
|
-
}
|
|
2697
|
-
function urlFrom(node) {
|
|
2698
|
-
for (const item of [node, ...node.action, ...node.alternateActions]) {
|
|
2699
|
-
const url = item.params.url;
|
|
2700
|
-
if (typeof url === "string" && /^https?:\/\//i.test(url.trim()))
|
|
2701
|
-
return url.trim();
|
|
2702
|
-
}
|
|
2703
|
-
return undefined;
|
|
2704
|
-
}
|
|
2705
|
-
/** `{ ok: false, error }` is how a host verb such as `plugin/method` refuses without throwing. */
|
|
2706
|
-
function refusalOf(result) {
|
|
2707
|
-
if (result === null || typeof result !== "object")
|
|
2708
|
-
return undefined;
|
|
2709
|
-
const record = result;
|
|
2710
|
-
return record.ok === false && typeof record.error === "string" ? record.error : undefined;
|
|
2711
|
-
}
|
|
2712
|
-
/** A scheme-built param is a bare string, a boxed `{ __string__ }`, or a spec with an `id`. */
|
|
2713
|
-
function paramString(value) {
|
|
2714
|
-
if (typeof value === "string")
|
|
2715
|
-
return value;
|
|
2716
|
-
if (typeof value !== "object" || value === null)
|
|
2717
|
-
return "";
|
|
2718
|
-
const rec = value;
|
|
2719
|
-
if (typeof rec.__string__ === "string")
|
|
2720
|
-
return rec.__string__;
|
|
2721
|
-
return typeof rec.id === "string" ? rec.id : "";
|
|
2722
|
-
}
|
|
2723
|
-
function fillParams(params, remainder) {
|
|
2724
|
-
if (remainder === "")
|
|
2725
|
-
return params;
|
|
2726
|
-
let next = params;
|
|
2727
|
-
if (Object.prototype.hasOwnProperty.call(params, "input") && (params.input === undefined || params.input === "")) {
|
|
2728
|
-
next = { ...next, input: remainder };
|
|
2729
|
-
}
|
|
2730
|
-
if (Object.prototype.hasOwnProperty.call(params, "value") && params.value === "") {
|
|
2731
|
-
next = { ...next, value: remainder };
|
|
2732
|
-
}
|
|
2733
|
-
return next;
|
|
2734
|
-
}
|
|
2735
|
-
function hasInputHole(node) {
|
|
2736
|
-
const walk = [node, ...node.action, ...node.alternateActions, ...node.choices];
|
|
2737
|
-
return walk.some((item) => item.op != null &&
|
|
2738
|
-
Object.prototype.hasOwnProperty.call(item.params, "input") &&
|
|
2739
|
-
(item.params.input === undefined || item.params.input === ""));
|
|
2740
|
-
}
|
|
2741
|
-
/** Text parts join in order. Picture bytes are standard base64 beside the prompt. */
|
|
2742
|
-
function promptFromParts(parts) {
|
|
2743
|
-
const visuals = [];
|
|
2744
|
-
let text = "";
|
|
2745
|
-
for (const part of parts) {
|
|
2746
|
-
const image = part.image;
|
|
2747
|
-
if (image !== undefined) {
|
|
2748
|
-
visuals.push({ mime: image.mime, bytesBase64: Buffer.from(image.bytes).toString("base64") });
|
|
2749
|
-
}
|
|
2750
|
-
if (typeof part.text === "string")
|
|
2751
|
-
text += part.text;
|
|
2752
|
-
}
|
|
2753
|
-
return { text, visuals };
|
|
2754
|
-
}
|
|
2755
|
-
function jsonParams(params) {
|
|
2756
|
-
try {
|
|
2757
|
-
return JSON.parse(JSON.stringify(params, (_key, value) => {
|
|
2758
|
-
if (typeof value === "boolean")
|
|
2759
|
-
return value;
|
|
2760
|
-
if (typeof value !== "object" || value === null)
|
|
2761
|
-
return value;
|
|
2762
|
-
const rec = value;
|
|
2763
|
-
if (typeof rec.__boolean__ === "boolean")
|
|
2764
|
-
return rec.__boolean__;
|
|
2765
|
-
if (typeof rec.__string__ === "string")
|
|
2766
|
-
return rec.__string__;
|
|
2767
|
-
if (typeof rec.id === "string" && rec.id.length > 0 && "configuration" in rec)
|
|
2768
|
-
return rec.id;
|
|
2769
|
-
if (typeof rec.name === "string" && "importPath" in rec)
|
|
2770
|
-
return rec.name;
|
|
2771
|
-
return value;
|
|
2772
|
-
}));
|
|
2773
|
-
}
|
|
2774
|
-
catch {
|
|
2775
|
-
return {};
|
|
2776
|
-
}
|
|
2777
|
-
}
|
|
2778
|
-
function nonempty(value) {
|
|
2779
|
-
return (value ?? "").trim();
|
|
2780
|
-
}
|
|
2781
|
-
/** 401 or 403 as a status, not a digit inside a longer number. Same test as connect.scm `auth-line?`. */
|
|
2782
|
-
function authStatusLine(line) {
|
|
2783
|
-
return /(?:^|\D)40[13](?:\D|$)/.test(line);
|
|
2784
|
-
}
|
|
2785
|
-
function askStack(leaf, rows, bots = {}) {
|
|
2786
|
-
if (leaf instanceof CallJob || leaf instanceof AgentMessageJob) {
|
|
2787
|
-
const description = agentRecipeDescription(bots, agentSpecKey(leaf));
|
|
2788
|
-
let body = nonempty(agentAskStackedBody(agentCoverPrompt(leaf), description));
|
|
2789
|
-
if (body === "" && leaf instanceof CallJob) {
|
|
2790
|
-
const args = { ...(leaf.args ?? {}) };
|
|
2791
|
-
delete args.spec;
|
|
2792
|
-
body = nonempty(formatMcpArgs(args));
|
|
2793
|
-
}
|
|
2794
|
-
if (body === "")
|
|
2795
|
-
return {};
|
|
2796
|
-
return { stackedBody: body, stackedViewport: mcpConfirmViewport(rows) };
|
|
2797
|
-
}
|
|
2798
|
-
if (leaf instanceof MCPToolJob) {
|
|
2799
|
-
const body = nonempty(formatMcpArgs(leaf.args));
|
|
2800
|
-
if (body === "")
|
|
2801
|
-
return {};
|
|
2802
|
-
return { stackedBody: body, stackedViewport: mcpConfirmViewport(rows) };
|
|
2803
|
-
}
|
|
2804
|
-
const command = shellAskCommand(leaf);
|
|
2805
|
-
if (command === undefined)
|
|
2806
|
-
return {};
|
|
2807
|
-
return {
|
|
2808
|
-
stackedBody: command,
|
|
2809
|
-
stackedViewport: mcpConfirmViewport(rows),
|
|
2810
|
-
stackedLang: "bash",
|
|
2811
|
-
};
|
|
2812
|
-
}
|
|
2813
|
-
function policyChip(session) {
|
|
2814
|
-
if (session.permissionMode === "yolo")
|
|
2815
|
-
return { text: "always approve", role: "attention" };
|
|
2816
|
-
if (session.permissionMode !== "auto")
|
|
2817
|
-
return null;
|
|
2818
|
-
return { text: "auto", role: "auto" };
|
|
2819
|
-
}
|
|
2820
|
-
/**
|
|
2821
|
-
* The line over an approval: what kind of question this is and why the floor asked, the judge's
|
|
2822
|
-
* reason when it weighed in, what the call is, and the folder question when one is suggested.
|
|
2823
|
-
*/
|
|
2824
|
-
export function askAnnotation(leaf, asked, widen, ack) {
|
|
2825
|
-
// An allowed call that only waits for an acknowledgement is not an ask: its own header leads.
|
|
2826
|
-
if (ack?.variant === "ack") {
|
|
2827
|
-
return [ackAnnotation(ack), asked].filter((part) => part !== undefined && part !== "").join(" · ");
|
|
2828
|
-
}
|
|
2829
|
-
const tier = leaf.policyResult === "deny" ? "Soft-deny" : "Ask";
|
|
2830
|
-
const why = leaf.policyClasses.map((id) => CLASSES[id].label).join(", ");
|
|
2831
|
-
const parts = [
|
|
2832
|
-
why === "" ? tier : `${tier} · ${why}`,
|
|
2833
|
-
leaf.policyResult === "deny" ? "licensed every time, nothing is remembered" : undefined,
|
|
2834
|
-
leaf.classifierResult !== null && leaf.judgeReason ? `Judge: ${leaf.judgeReason}` : undefined,
|
|
2835
|
-
ack === undefined ? undefined : ackAnnotation(ack),
|
|
2836
|
-
asked,
|
|
2837
|
-
widen === undefined ? undefined : `Treat ${widen.label} as part of this session?`,
|
|
2838
|
-
].filter((part) => part !== undefined && part !== "");
|
|
2839
|
-
return parts.length === 0 ? undefined : parts.join(" · ");
|
|
2840
|
-
}
|
|
2841
|
-
function catalogContextLimit(connection, model) {
|
|
2842
|
-
const windows = connection?.live?.windows;
|
|
2843
|
-
if (typeof windows !== "object" || windows === null)
|
|
2844
|
-
return 0;
|
|
2845
|
-
const id = (model ?? "").trim();
|
|
2846
|
-
const raw = id === "" ? undefined : windows[id];
|
|
2847
|
-
return typeof raw === "number" && Number.isFinite(raw) && raw > 0 ? raw : 0;
|
|
2848
|
-
}
|
|
2849
|
-
function quotaWindowsOf(connection) {
|
|
2850
|
-
const account = connection?.live?.account;
|
|
2851
|
-
if (typeof account !== "object" || account === null)
|
|
2852
|
-
return undefined;
|
|
2853
|
-
const detail = account.balanceDetail;
|
|
2854
|
-
if (typeof detail !== "object" || detail === null)
|
|
2855
|
-
return undefined;
|
|
2856
|
-
const rows = detail.windows;
|
|
2857
|
-
if (!Array.isArray(rows))
|
|
2858
|
-
return undefined;
|
|
2859
|
-
const out = [];
|
|
2860
|
-
for (const row of rows) {
|
|
2861
|
-
if (typeof row !== "object" || row === null)
|
|
2862
|
-
continue;
|
|
2863
|
-
const rec = row;
|
|
2864
|
-
const remaining = numberOf(rec.remainingPercent);
|
|
2865
|
-
if (remaining === undefined)
|
|
2866
|
-
continue;
|
|
2867
|
-
const remainingPercent = Math.round(Math.min(100, Math.max(0, remaining)));
|
|
2868
|
-
const resetAtRaw = numberOf(rec.resetAt);
|
|
2869
|
-
const resetAt = resetAtRaw === undefined ? undefined : Math.trunc(resetAtRaw);
|
|
2870
|
-
out.push(resetAt === undefined ? { remainingPercent } : { remainingPercent, resetAt });
|
|
2871
|
-
}
|
|
2872
|
-
return out.length > 0 ? out : undefined;
|
|
2873
|
-
}
|
|
2874
|
-
function numberOf(value) {
|
|
2875
|
-
if (typeof value === "number" && Number.isFinite(value))
|
|
2876
|
-
return value;
|
|
2877
|
-
if (typeof value !== "string")
|
|
2878
|
-
return undefined;
|
|
2879
|
-
const n = Number(value.trim());
|
|
2880
|
-
return Number.isFinite(n) ? n : undefined;
|
|
2881
|
-
}
|
|
2882
|
-
function askLeafId(leaf) {
|
|
2883
|
-
if (leaf === null)
|
|
2884
|
-
return null;
|
|
2885
|
-
if (leaf instanceof ToolCallJob && leaf.toolCallId !== "")
|
|
2886
|
-
return leaf.toolCallId;
|
|
2887
|
-
if (leaf instanceof ToolCallJob && leaf.name !== "")
|
|
2888
|
-
return leaf.name;
|
|
2889
|
-
return "ask";
|
|
2890
|
-
}
|
|
2891
|
-
function agentTapeGlance(job, kernel, parentModel) {
|
|
2892
|
-
const id = job.workerSessionId.trim();
|
|
2893
|
-
const glance = id === "" ? undefined : kernel.sessions[id];
|
|
2894
|
-
const recap = (glance?.status ?? "").replaceAll(/\s+/g, " ").trim();
|
|
2895
|
-
const live = !job.completed || glance?.midMotion === true;
|
|
2896
|
-
const status = recap === "" ? (glance?.asking === true ? "blocked" : live ? "active" : "") : recap;
|
|
2897
|
-
const model = (glance?.model.trim() || parentModel?.trim() || "").trim();
|
|
2898
|
-
return { status, model };
|
|
2899
|
-
}
|
|
2900
|
-
function tapeSpine(head) {
|
|
2901
|
-
const spine = [];
|
|
2902
|
-
const seen = new Set();
|
|
2903
|
-
let cell = head;
|
|
2904
|
-
while (cell !== null && !seen.has(cell)) {
|
|
2905
|
-
seen.add(cell);
|
|
2906
|
-
if (cell instanceof SessionTurn)
|
|
2907
|
-
spine.push(cell);
|
|
2908
|
-
cell = cell.turnTail;
|
|
2909
|
-
}
|
|
2910
|
-
spine.reverse();
|
|
2911
|
-
return spine;
|
|
2912
|
-
}
|
|
2913
|
-
function slashVerb(draft) {
|
|
2914
|
-
const token = (draft.split("\n")[0] ?? "").trim().split(/\s/)[0] ?? "";
|
|
2915
|
-
if (!token.startsWith("/") || token.length < 2)
|
|
2916
|
-
return null;
|
|
2917
|
-
return token.slice(1);
|
|
2918
|
-
}
|
|
2919
|
-
function isRetrying(turn, now) {
|
|
2920
|
-
if (turn == null)
|
|
2921
|
-
return false;
|
|
2922
|
-
const chunks = reactChunks(turn);
|
|
2923
|
-
for (let i = chunks.length - 1; i >= 0; i -= 1) {
|
|
2924
|
-
const pew = tapeCompletion(chunks[i]);
|
|
2925
|
-
if (pew == null)
|
|
2926
|
-
continue;
|
|
2927
|
-
if (pew.outcome != null)
|
|
2928
|
-
return false;
|
|
2929
|
-
const retryUntilMs = pew.report?.retryUntilMs;
|
|
2930
|
-
return typeof retryUntilMs === "number" && retryUntilMs > now;
|
|
2931
|
-
}
|
|
2932
|
-
return false;
|
|
2933
|
-
}
|
|
2934
|
-
//# sourceMappingURL=tea.js.map
|