@timurproko/a1 0.1.8-dev.472 → 0.1.8-dev.508
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/bin/cli.js +4 -5
- package/bin/guardian.js +5 -1
- package/bin/module-identity.js +53 -98
- package/bin/module-resolver.js +138 -0
- package/bin/pinned-pi-public.js +25 -6
- package/bin/ui.js +7 -2
- package/bin/update-recovery.js +76 -7
- package/bin/warmup.js +3 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/clipboard-diagnostics.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/clipboard-image.js +1 -1
- package/dist/app/session-shell/helper-pool.d.ts +33 -0
- package/dist/app/session-shell/helper-pool.js +98 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-preparation-client.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-preparation-client.js +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-preparation.js +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-source.js +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-worker.js +1 -1
- package/dist/app/session-shell/index.d.ts +7 -0
- package/dist/app/session-shell/index.js +4 -0
- package/dist/app/session-shell/paste-executor.d.ts +18 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-executor.js +50 -29
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-helper.js +1 -1
- package/dist/app/session-shell/paste-preparation-client.d.ts +31 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-preparation-client.js +19 -8
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-protocol.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-protocol.js +1 -1
- package/dist/app/session-shell/paste-text-preparation.d.ts +6 -0
- package/dist/{integrations/pi/session-ui/paste-text-preparation.d.ts → app/session-shell/paste-types.d.ts} +1 -4
- package/dist/{integrations/pi/session-ui → app/session-shell}/path-chip-presentation.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-chips.d.ts +5 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-chips.js +6 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-history-controller.d.ts +2 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-history-controller.js +2 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-suggestion-controller.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/prompt-suggestion-controller.js +2 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/quit-outro.js +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-coordinator.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-coordinator.js +3 -5
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-helper.js +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-protocol.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-transport.d.ts +10 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-transport.js +45 -19
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-shell-root.d.ts +75 -53
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-shell-root.js +30 -20
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-shell.d.ts +9 -8
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-shell.js +108 -67
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-viewport-controller.d.ts +5 -5
- package/dist/{integrations/pi/session-ui → app/session-shell}/session-viewport-controller.js +5 -5
- package/dist/{integrations/pi/session-ui → app/session-shell}/system-clipboard.d.ts +1 -1
- package/dist/{integrations/pi/session-ui → app/session-shell}/system-clipboard.js +1 -1
- package/dist/cli/index.d.ts +8 -5
- package/dist/cli/index.js +4 -5
- package/dist/composition/index.d.ts +0 -1
- package/dist/composition/index.js +0 -1
- package/dist/composition/owned-ui.d.ts +2 -2
- package/dist/composition/owned-ui.js +35 -36
- package/dist/composition/settings-route-host.d.ts +2 -2
- package/dist/contracts/agent-engine/domain.d.ts +6 -1
- package/dist/contracts/agent-engine/index.d.ts +11 -8
- package/dist/contracts/agent-engine/index.js +6 -8
- package/dist/contracts/owned-ui/extension-ui.d.ts +8 -0
- package/dist/contracts/owned-ui/index.d.ts +12 -8
- package/dist/contracts/owned-ui/index.js +8 -8
- package/dist/features/launch/index.d.ts +12 -6
- package/dist/features/launch/index.js +6 -6
- package/dist/features/launch/intent.d.ts +5 -5
- package/dist/features/launch/intent.js +2 -2
- package/dist/features/owned-ui/index.d.ts +6 -6
- package/dist/features/owned-ui/index.js +4 -6
- package/dist/features/owned-ui/run.d.ts +2 -2
- package/dist/features/owned-ui/settings-app.d.ts +2 -2
- package/dist/features/owned-ui/settings-app.js +18 -5
- package/dist/features/prompt-history/service.d.ts +1 -1
- package/dist/features/prompt-history/service.js +1 -1
- package/dist/features/prompt-history/store.js +3 -7
- package/dist/features/prompt-suggestions/diagnostics.js +1 -1
- package/dist/features/prompt-suggestions/index.d.ts +2 -1
- package/dist/features/prompt-suggestions/index.js +1 -1
- package/dist/foundation/launch-guardian/index.d.ts +2 -1
- package/dist/foundation/launch-guardian/index.js +1 -1
- package/dist/foundation/lifecycle/index.d.ts +11 -6
- package/dist/foundation/lifecycle/index.js +5 -6
- package/dist/foundation/process-containment/index.d.ts +8 -6
- package/dist/foundation/process-containment/index.js +6 -6
- package/dist/foundation/process-containment/native-guardian-containment.js +3 -3
- package/dist/foundation/protocol/index.d.ts +3 -2
- package/dist/foundation/protocol/index.js +2 -2
- package/dist/foundation/release/bootstrap.d.ts +0 -4
- package/dist/foundation/release/bootstrap.js +1 -82
- package/dist/foundation/release/dependency-layer.d.ts +2 -5
- package/dist/foundation/release/endpoints.d.ts +4 -0
- package/dist/foundation/release/endpoints.js +86 -2
- package/dist/foundation/release/index.d.ts +30 -16
- package/dist/foundation/release/index.js +16 -16
- package/dist/foundation/release/release.d.ts +1 -1
- package/dist/foundation/release/types.d.ts +11 -0
- package/dist/foundation/release/types.js +1 -0
- package/dist/foundation/release/update-transaction.d.ts +1 -1
- package/dist/foundation/release/update.d.ts +2 -1
- package/dist/foundation/release/update.js +3 -18
- package/dist/foundation/startup/index.d.ts +4 -2
- package/dist/foundation/startup/index.js +2 -2
- package/dist/foundation/startup/startup-descriptor.js +2 -2
- package/dist/foundation/storage/control-store.d.ts +1 -45
- package/dist/foundation/storage/control-store.js +54 -277
- package/dist/foundation/storage/index.d.ts +1 -1
- package/dist/foundation/storage/index.js +1 -1
- package/dist/foundation/supervision/index.d.ts +2 -2
- package/dist/foundation/supervision/index.js +2 -2
- package/dist/foundation/supervision/server.d.ts +5 -10
- package/dist/foundation/supervision/server.js +7 -7
- package/dist/foundation/terminal-cleanup/index.d.ts +3 -2
- package/dist/foundation/terminal-cleanup/index.js +2 -2
- package/dist/integrations/pi/components/editor-interaction.d.ts +1 -1
- package/dist/integrations/pi/components/history-editor-loader.d.ts +1 -1
- package/dist/integrations/pi/components/index.d.ts +20 -13
- package/dist/integrations/pi/components/index.js +12 -13
- package/dist/integrations/pi/components/owned-editor-ux.js +5 -8
- package/dist/integrations/pi/components/resources/builtin-themes.d.ts +7 -5
- package/dist/integrations/pi/components/resources/builtin-themes.js +7 -5
- package/dist/integrations/pi/components/shell-editor-autocomplete.js +1 -1
- package/dist/integrations/pi/components/shell-extension-ui.js +2 -1
- package/dist/integrations/pi/components/shell-footer-status.js +1 -1
- package/dist/integrations/pi/components/shell-presenters-info.d.ts +1 -1
- package/dist/integrations/pi/components/shell-presenters-info.js +1 -1
- package/dist/integrations/pi/components/shell-presenters-transcript.js +1 -1
- package/dist/integrations/pi/components/shell-selectors-dialogs.d.ts +9 -3
- package/dist/integrations/pi/components/shell-selectors-dialogs.js +9 -6
- package/dist/integrations/pi/components/shell-shared-facade.d.ts +3 -1
- package/dist/integrations/pi/components/shell-shared-facade.js +4 -2
- package/dist/integrations/pi/components/submitted-prompt-adapter.d.ts +1 -1
- package/dist/integrations/pi/components/submitted-prompt-adapter.js +1 -1
- package/dist/integrations/pi/components/tool-image-presentation.d.ts +1 -1
- package/dist/integrations/pi/components/tool-image-presentation.js +4 -7
- package/dist/integrations/pi/components/upstream/adjacent/core/keybindings.d.ts +36 -22
- package/dist/integrations/pi/components/upstream/adjacent/core/keybindings.js +43 -7
- package/dist/integrations/pi/components/upstream/assets/earendil-image.json +2 -2
- package/dist/integrations/pi/components/upstream/components/countdown-timer.d.ts +6 -3
- package/dist/integrations/pi/components/upstream/components/daxnuts.d.ts +8 -1
- package/dist/integrations/pi/components/upstream/components/daxnuts.js +7 -3
- package/dist/integrations/pi/components/upstream/components/earendil-announcement.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/earendil-announcement.js +10 -4
- package/dist/integrations/pi/components/upstream/components/extension-editor.d.ts +7 -4
- package/dist/integrations/pi/components/upstream/components/extension-editor.js +7 -4
- package/dist/integrations/pi/components/upstream/components/mermaid.js +8 -4
- package/dist/integrations/pi/components/upstream/components/owned-editor.d.ts +9 -5
- package/dist/integrations/pi/components/upstream/components/owned-editor.js +10 -6
- package/dist/integrations/pi/components/upstream/components/scoped-models-selector.d.ts +8 -4
- package/dist/integrations/pi/components/upstream/components/scoped-models-selector.js +27 -25
- package/dist/integrations/pi/components/upstream/components/session-footer.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/session-footer.js +8 -10
- package/dist/integrations/pi/components/upstream/components/session-selector-search.js +6 -4
- package/dist/integrations/pi/components/upstream/components/session-selector.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/session-selector.js +8 -4
- package/dist/integrations/pi/components/upstream/components/skill-invocation-message.d.ts +7 -5
- package/dist/integrations/pi/components/upstream/components/skill-invocation-message.js +8 -6
- package/dist/integrations/pi/components/upstream/components/status-indicator.d.ts +9 -4
- package/dist/integrations/pi/components/upstream/components/status-indicator.js +15 -5
- package/dist/integrations/pi/components/upstream/components/tool-execution.d.ts +8 -2
- package/dist/integrations/pi/components/upstream/components/tool-execution.js +58 -37
- package/dist/integrations/pi/components/upstream/components/tree-selector.d.ts +7 -4
- package/dist/integrations/pi/components/upstream/components/tree-selector.js +7 -4
- package/dist/integrations/pi/components/upstream/components/trust-selector.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/trust-selector.js +10 -5
- package/dist/integrations/pi/components/upstream/external-editor.js +8 -4
- package/dist/integrations/pi/components/upstream/history/editor-core.d.ts +13 -4
- package/dist/integrations/pi/components/upstream/history/editor-core.js +112 -30
- package/dist/integrations/pi/components/upstream/history/kill-ring.d.ts +6 -3
- package/dist/integrations/pi/components/upstream/history/kill-ring.js +6 -3
- package/dist/integrations/pi/components/upstream/history/printable-key.js +7 -4
- package/dist/integrations/pi/components/upstream/history/text-helpers.js +6 -3
- package/dist/integrations/pi/components/upstream/history/undo-stack.d.ts +6 -3
- package/dist/integrations/pi/components/upstream/history/undo-stack.js +6 -3
- package/dist/integrations/pi/components/upstream/history/word-navigation.js +6 -3
- package/dist/integrations/pi/components/upstream/model-search.d.ts +5 -2
- package/dist/integrations/pi/components/upstream/theme/theme-controller.d.ts +8 -0
- package/dist/integrations/pi/components/upstream/theme/theme-controller.js +0 -3
- package/dist/integrations/pi/components/upstream/theme/theme.d.ts +2 -2
- package/dist/integrations/pi/components/upstream/theme/theme.js +17 -6
- package/dist/integrations/pi/engine/adapter.d.ts +39 -138
- package/dist/integrations/pi/engine/adapter.js +338 -3226
- package/dist/integrations/pi/engine/command-dispatch.d.ts +41 -0
- package/dist/integrations/pi/engine/command-dispatch.js +125 -0
- package/dist/integrations/pi/engine/event-delivery.d.ts +100 -0
- package/dist/integrations/pi/engine/event-delivery.js +184 -0
- package/dist/integrations/pi/engine/extension-ui-binding.d.ts +35 -0
- package/dist/integrations/pi/engine/extension-ui-binding.js +81 -0
- package/dist/integrations/pi/engine/index.d.ts +18 -14
- package/dist/integrations/pi/engine/index.js +10 -14
- package/dist/integrations/pi/engine/message-values.d.ts +29 -0
- package/dist/integrations/pi/engine/message-values.js +168 -0
- package/dist/integrations/pi/engine/pending-delivery.d.ts +2 -2
- package/dist/integrations/pi/engine/pending-delivery.js +2 -4
- package/dist/integrations/pi/engine/pi-settings-metadata.json +382 -371
- package/dist/integrations/pi/engine/prompt-suggestions.d.ts +30 -0
- package/dist/integrations/pi/engine/prompt-suggestions.js +102 -0
- package/dist/integrations/pi/engine/provider-authentication.d.ts +34 -0
- package/dist/integrations/pi/engine/provider-authentication.js +209 -0
- package/dist/integrations/pi/engine/resource-catalog.d.ts +49 -0
- package/dist/integrations/pi/engine/resource-catalog.js +289 -0
- package/dist/integrations/pi/engine/resources/changelog.json +4 -4
- package/dist/integrations/pi/engine/session-events.d.ts +48 -0
- package/dist/integrations/pi/engine/session-events.js +223 -0
- package/dist/integrations/pi/engine/session-integration.js +2 -4
- package/dist/integrations/pi/engine/session-runtime.d.ts +84 -0
- package/dist/integrations/pi/engine/session-runtime.js +249 -0
- package/dist/integrations/pi/engine/{settings-effects.d.ts → settings-bridge.d.ts} +57 -2
- package/dist/integrations/pi/engine/settings-bridge.js +514 -0
- package/dist/integrations/pi/engine/settings-metadata.d.ts +31 -0
- package/dist/integrations/pi/engine/settings-metadata.js +67 -0
- package/dist/integrations/pi/engine/settings-port.d.ts +42 -0
- package/dist/integrations/pi/engine/settings-port.js +353 -0
- package/dist/integrations/pi/engine/transcript-projection.d.ts +39 -0
- package/dist/integrations/pi/engine/transcript-projection.js +405 -0
- package/dist/integrations/pi/engine/usage-view.d.ts +4 -0
- package/dist/integrations/pi/engine/usage-view.js +56 -0
- package/dist/integrations/pi/engine/workflow-contexts.d.ts +59 -0
- package/dist/integrations/pi/engine/workflow-contexts.js +316 -0
- package/dist/integrations/pi/engine/workflow-runner.d.ts +60 -0
- package/dist/integrations/pi/engine/workflow-runner.js +509 -0
- package/dist/integrations/pi/engine/workflow-support.d.ts +33 -0
- package/dist/integrations/pi/engine/workflow-support.js +352 -0
- package/dist/integrations/pi/engine/workflows.d.ts +63 -2
- package/dist/integrations/pi/engine/workflows.js +5 -2
- package/dist/integrations/pi/startup-public.js +576 -554
- package/dist/integrations/pi/startup-public.manifest.json +1730 -984
- package/dist/integrations/pi/tui-runtime/adapter.js +10 -13
- package/dist/integrations/pi/tui-runtime/contracts.d.ts +11 -1
- package/dist/integrations/pi/tui-runtime/damage-aware-terminal.d.ts +1 -1
- package/dist/integrations/pi/tui-runtime/damage-aware-terminal.js +4 -7
- package/dist/integrations/pi/tui-runtime/index.d.ts +8 -6
- package/dist/integrations/pi/tui-runtime/index.js +4 -6
- package/dist/integrations/pi/tui-runtime/mouse-report-input.js +2 -4
- package/dist/integrations/pi/tui-runtime/overlay-geometry.d.ts +2 -2
- package/dist/integrations/pi/tui-runtime/overlay-geometry.js +4 -5
- package/dist/integrations/pi/tui-runtime/presentation-adapter.js +1 -1
- package/dist/native/darwin-arm64/manifest.json +1 -1
- package/dist/native/linux-x64/manifest.json +1 -1
- package/dist/native/win32-x64/manifest.json +2 -2
- package/dist/native/win32-x64/process-guardian.exe +0 -0
- package/dist/runtime-payload-inventory.json +51320 -46509
- package/dist/ui/apps/index.d.ts +5 -3
- package/dist/ui/apps/index.js +3 -3
- package/dist/ui/components/index.d.ts +47 -25
- package/dist/ui/components/index.js +25 -25
- package/dist/ui/components/prompt-input.js +1 -4
- package/dist/ui/settings/declarations.d.ts +119 -0
- package/dist/ui/settings/declarations.js +20 -11
- package/dist/ui/settings/index.d.ts +10 -6
- package/dist/ui/settings/index.js +5 -6
- package/dist/ui/settings/manager.d.ts +54 -0
- package/dist/ui/settings/{session.js → manager.js} +101 -9
- package/dist/ui/settings/sections.d.ts +2 -7
- package/docs/architecture/boundaries.md +4 -4
- package/docs/architecture/history-editor-provenance.md +1 -1
- package/docs/architecture/project-structure.md +6 -6
- package/docs/architecture/prompt-suggestions.md +1 -1
- package/docs/architecture/terminal-host-proof-gate.md +1 -1
- package/docs/architecture/terminal-host-spike-evidence.md +1 -1
- package/docs/architecture/toolchain.md +8 -0
- package/docs/architecture/ui-reference-provenance.md +4 -4
- package/docs/ci-release-runbook.md +7 -1
- package/docs/features/modal-content-interaction.md +2 -2
- package/docs/local-worktree-cleanup.md +4 -2
- package/docs/validation.md +6 -4
- package/package.json +7 -11
- package/bin/pi-tui.d.ts +0 -6
- package/bin/pi-tui.js +0 -28
- package/bin/sync-pi-tui-proxy.js +0 -97
- package/dist/cli/version.d.ts +0 -2
- package/dist/cli/version.js +0 -23
- package/dist/composition/agent-engine-bridge.d.ts +0 -3
- package/dist/composition/agent-engine-bridge.js +0 -108
- package/dist/composition/process.d.ts +0 -16
- package/dist/composition/process.js +0 -45
- package/dist/contracts/workspace/index.d.ts +0 -2
- package/dist/contracts/workspace/index.js +0 -2
- package/dist/contracts/workspace/model.d.ts +0 -248
- package/dist/contracts/workspace/model.js +0 -2
- package/dist/contracts/workspace/validation.d.ts +0 -13
- package/dist/contracts/workspace/validation.js +0 -335
- package/dist/features/owned-ui/customization.d.ts +0 -40
- package/dist/features/owned-ui/customization.js +0 -110
- package/dist/features/owned-ui/diagnostics.d.ts +0 -34
- package/dist/features/owned-ui/diagnostics.js +0 -95
- package/dist/features/workspace/capabilities.d.ts +0 -31
- package/dist/features/workspace/capabilities.js +0 -75
- package/dist/features/workspace/index.d.ts +0 -6
- package/dist/features/workspace/index.js +0 -6
- package/dist/features/workspace/presentation.d.ts +0 -30
- package/dist/features/workspace/presentation.js +0 -70
- package/dist/features/workspace/reconciliation.d.ts +0 -15
- package/dist/features/workspace/reconciliation.js +0 -82
- package/dist/features/workspace/reducer.d.ts +0 -43
- package/dist/features/workspace/reducer.js +0 -214
- package/dist/features/workspace/router.d.ts +0 -32
- package/dist/features/workspace/router.js +0 -125
- package/dist/features/workspace/store.d.ts +0 -18
- package/dist/features/workspace/store.js +0 -55
- package/dist/foundation/native-host-protocol/codec.d.ts +0 -13
- package/dist/foundation/native-host-protocol/codec.js +0 -58
- package/dist/foundation/native-host-protocol/evidence.d.ts +0 -67
- package/dist/foundation/native-host-protocol/evidence.js +0 -141
- package/dist/foundation/native-host-protocol/index.d.ts +0 -4
- package/dist/foundation/native-host-protocol/index.js +0 -4
- package/dist/foundation/native-host-protocol/messages.d.ts +0 -56
- package/dist/foundation/native-host-protocol/messages.js +0 -149
- package/dist/foundation/native-host-protocol/proof-gate.d.ts +0 -13
- package/dist/foundation/native-host-protocol/proof-gate.js +0 -33
- package/dist/foundation/structured-agent-runtime/backpressure.d.ts +0 -47
- package/dist/foundation/structured-agent-runtime/backpressure.js +0 -119
- package/dist/foundation/structured-agent-runtime/commands.d.ts +0 -53
- package/dist/foundation/structured-agent-runtime/commands.js +0 -165
- package/dist/foundation/structured-agent-runtime/handshake.d.ts +0 -41
- package/dist/foundation/structured-agent-runtime/handshake.js +0 -151
- package/dist/foundation/structured-agent-runtime/index.d.ts +0 -5
- package/dist/foundation/structured-agent-runtime/index.js +0 -5
- package/dist/foundation/structured-agent-runtime/reconnection.d.ts +0 -38
- package/dist/foundation/structured-agent-runtime/reconnection.js +0 -130
- package/dist/foundation/structured-agent-runtime/state.d.ts +0 -57
- package/dist/foundation/structured-agent-runtime/state.js +0 -119
- package/dist/integrations/pi/components/upstream/components/custom-entry.d.ts +0 -17
- package/dist/integrations/pi/components/upstream/components/custom-entry.js +0 -51
- package/dist/integrations/pi/components/upstream/components/first-time-setup.d.ts +0 -24
- package/dist/integrations/pi/components/upstream/components/first-time-setup.js +0 -105
- package/dist/integrations/pi/components/upstream/components/markdown-transform.d.ts +0 -2
- package/dist/integrations/pi/components/upstream/components/markdown-transform.js +0 -18
- package/dist/integrations/pi/engine/model-auth-integration.d.ts +0 -31
- package/dist/integrations/pi/engine/model-auth-integration.js +0 -62
- package/dist/integrations/pi/engine/resource-extension-integration.d.ts +0 -32
- package/dist/integrations/pi/engine/resource-extension-integration.js +0 -81
- package/dist/integrations/pi/engine/settings-effects.js +0 -249
- package/dist/integrations/pi/engine/settings-integration.d.ts +0 -43
- package/dist/integrations/pi/engine/settings-integration.js +0 -227
- package/dist/integrations/pi/engine/workflow-controllers.d.ts +0 -21
- package/dist/integrations/pi/engine/workflow-controllers.js +0 -49
- package/dist/integrations/pi/session-ui/index.d.ts +0 -5
- package/dist/integrations/pi/session-ui/index.js +0 -5
- package/dist/integrations/pi/session-ui/paste-executor.d.ts +0 -10
- package/dist/integrations/pi/session-ui/paste-preparation-client.d.ts +0 -16
- package/dist/integrations/pi/session-ui/route-host.d.ts +0 -5
- package/dist/integrations/pi/tui-runtime/conformance.d.ts +0 -18
- package/dist/integrations/pi/tui-runtime/conformance.js +0 -145
- package/dist/ui/components/prompt-row.d.ts +0 -14
- package/dist/ui/components/prompt-row.js +0 -20
- package/dist/ui/settings/session.d.ts +0 -36
- package/dist/ui/settings/store.d.ts +0 -29
- package/dist/ui/settings/store.js +0 -91
- package/dist/{integrations/pi/session-ui → app/session-shell}/clipboard-diagnostics.js +2 -2
- package/dist/{integrations/pi/session-ui → app/session-shell}/clipboard-image.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/editor-hyperlink-budget.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/editor-hyperlink-budget.js +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-preparation.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-source.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/image-worker.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-helper.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-text-preparation.js +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-text-worker.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/paste-text-worker.js +0 -0
- package/dist/{integrations/pi/session-ui/response-copy-helper.d.ts → app/session-shell/paste-types.js} +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/path-chip-presentation.js +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/quit-outro-effects.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/quit-outro-effects.js +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/quit-outro.d.ts +0 -0
- package/dist/{integrations/pi/session-ui/route-host.js → app/session-shell/response-copy-helper.d.ts} +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/response-copy-protocol.js +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/stream-presentation-coalescer.d.ts +0 -0
- package/dist/{integrations/pi/session-ui → app/session-shell}/stream-presentation-coalescer.js +3 -3
- /package/dist/{integrations/pi/session-ui → app/session-shell}/text-paste.d.ts +0 -0
- /package/dist/{integrations/pi/session-ui → app/session-shell}/text-paste.js +0 -0
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
import { AGENT_ENGINE_CONTRACT_VERSION, assertAgentCommand, } from "../contracts/agent-engine/index.js";
|
|
2
|
-
const CAPABILITIES = {
|
|
3
|
-
contractVersion: AGENT_ENGINE_CONTRACT_VERSION,
|
|
4
|
-
commands: ["prompt", "steer", "follow-up", "abort", "retry", "compact", "bash", "replace-session"],
|
|
5
|
-
events: ["lifecycle", "content", "command-outcome", "snapshot-invalidated", "diagnostic"],
|
|
6
|
-
snapshots: { supported: true, maxBytes: 1024 * 1024 },
|
|
7
|
-
};
|
|
8
|
-
export function createPiAgentEngineBridge(adapter, cwd) {
|
|
9
|
-
return new PiAgentEngineBridge(adapter, cwd);
|
|
10
|
-
}
|
|
11
|
-
class PiAgentEngineBridge {
|
|
12
|
-
adapter;
|
|
13
|
-
cwd;
|
|
14
|
-
capabilities = CAPABILITIES;
|
|
15
|
-
#session;
|
|
16
|
-
constructor(adapter, cwd) {
|
|
17
|
-
this.adapter = adapter;
|
|
18
|
-
this.cwd = cwd;
|
|
19
|
-
}
|
|
20
|
-
async createSession(input) {
|
|
21
|
-
if (this.#session)
|
|
22
|
-
return this.#session;
|
|
23
|
-
if (input.cwd !== this.cwd)
|
|
24
|
-
throw new TypeError("composed Pi engine cannot change working directory");
|
|
25
|
-
await this.adapter.start();
|
|
26
|
-
this.#session = new PiAgentSessionBridge(this.adapter, input.sessionId);
|
|
27
|
-
return this.#session;
|
|
28
|
-
}
|
|
29
|
-
async dispose() { await this.adapter.dispose(); }
|
|
30
|
-
}
|
|
31
|
-
class PiAgentSessionBridge {
|
|
32
|
-
adapter;
|
|
33
|
-
sessionId;
|
|
34
|
-
capabilities = CAPABILITIES;
|
|
35
|
-
lifecycle = "starting";
|
|
36
|
-
#listeners = new Set();
|
|
37
|
-
#unsubscribe;
|
|
38
|
-
constructor(adapter, sessionId) {
|
|
39
|
-
this.adapter = adapter;
|
|
40
|
-
this.sessionId = sessionId;
|
|
41
|
-
this.#unsubscribe = adapter.onEvent(event => {
|
|
42
|
-
const converted = convertEvent(event);
|
|
43
|
-
if (!converted)
|
|
44
|
-
return;
|
|
45
|
-
if (converted.type === "lifecycle")
|
|
46
|
-
this.lifecycle = converted.lifecycle;
|
|
47
|
-
for (const listener of this.#listeners)
|
|
48
|
-
listener(converted);
|
|
49
|
-
});
|
|
50
|
-
this.lifecycle = toLifecycle(adapter.snapshot().view.lifecycle);
|
|
51
|
-
}
|
|
52
|
-
async execute(command) {
|
|
53
|
-
assertAgentCommand(command, this.capabilities);
|
|
54
|
-
if (command.sessionId !== this.sessionId)
|
|
55
|
-
return "rejected";
|
|
56
|
-
if (command.type === "bash") {
|
|
57
|
-
const result = await this.adapter.executeBashWorkflow(command.command, false);
|
|
58
|
-
return !result.cancelled && result.exitCode === 0 ? "completed" : result.cancelled ? "cancelled" : "failed";
|
|
59
|
-
}
|
|
60
|
-
const result = await this.adapter.execute(toOwnedCommand(command));
|
|
61
|
-
return result.outcome === "timed-out" ? "failed" : result.outcome;
|
|
62
|
-
}
|
|
63
|
-
subscribe(listener) { this.#listeners.add(listener); return () => this.#listeners.delete(listener); }
|
|
64
|
-
async snapshot() {
|
|
65
|
-
const snapshot = this.adapter.snapshot();
|
|
66
|
-
return {
|
|
67
|
-
contractVersion: AGENT_ENGINE_CONTRACT_VERSION,
|
|
68
|
-
snapshotId: snapshot.snapshotId,
|
|
69
|
-
sessionId: this.sessionId,
|
|
70
|
-
revision: snapshot.view.revision,
|
|
71
|
-
sequence: snapshot.sequence,
|
|
72
|
-
lifecycle: toLifecycle(snapshot.view.lifecycle),
|
|
73
|
-
content: snapshot.view.transcript.map(toMessage),
|
|
74
|
-
activeCommandIds: snapshot.view.activeCommandIds,
|
|
75
|
-
capabilities: this.capabilities,
|
|
76
|
-
};
|
|
77
|
-
}
|
|
78
|
-
async dispose() { this.#unsubscribe(); this.#listeners.clear(); await this.adapter.dispose(); this.lifecycle = "stopped"; }
|
|
79
|
-
}
|
|
80
|
-
function toOwnedCommand(command) {
|
|
81
|
-
const base = { correlationId: command.commandId, sessionId: command.sessionId };
|
|
82
|
-
if (command.type === "replace-session")
|
|
83
|
-
return command.source.kind === "new" ? { ...base, type: "new-session" } : { ...base, type: "resume-session", sessionPath: command.source.sessionPath };
|
|
84
|
-
if (command.type === "prompt" || command.type === "steer" || command.type === "follow-up")
|
|
85
|
-
return { ...base, type: command.type, text: command.text };
|
|
86
|
-
return { ...base, type: command.type };
|
|
87
|
-
}
|
|
88
|
-
function convertEvent(event) {
|
|
89
|
-
const base = { contractVersion: AGENT_ENGINE_CONTRACT_VERSION, sessionId: event.sessionId, sequence: event.sequence };
|
|
90
|
-
if (event.type === "session-lifecycle")
|
|
91
|
-
return { ...base, type: "lifecycle", lifecycle: toLifecycle(event.lifecycle), reason: event.reason };
|
|
92
|
-
if (event.type === "transcript-block")
|
|
93
|
-
return { ...base, type: "content", content: toMessage(event.block) };
|
|
94
|
-
if (event.type === "command-outcome")
|
|
95
|
-
return { ...base, type: "command-outcome", commandId: event.correlationId, outcome: event.outcome === "timed-out" ? "failed" : event.outcome, diagnostic: event.diagnostic };
|
|
96
|
-
if (event.type === "diagnostic")
|
|
97
|
-
return { ...base, type: "diagnostic", code: event.diagnostic.code, message: event.diagnostic.message, recoverable: event.diagnostic.recoverable };
|
|
98
|
-
if (event.type === "session-view")
|
|
99
|
-
return { ...base, type: "snapshot-invalidated", expectedRevision: event.view.revision };
|
|
100
|
-
return null;
|
|
101
|
-
}
|
|
102
|
-
function toLifecycle(lifecycle) {
|
|
103
|
-
return lifecycle === "suspended" ? "ready" : lifecycle;
|
|
104
|
-
}
|
|
105
|
-
function toMessage(block) {
|
|
106
|
-
const role = block.kind === "user" ? "user" : block.kind === "system" ? "system" : block.kind === "tool-call" || block.kind === "tool-result" ? "tool" : "assistant";
|
|
107
|
-
return { id: block.id, role, status: block.status === "live" ? "streaming" : "final", content: [{ kind: "text", text: block.text }] };
|
|
108
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { type AgentEnginePort } from "../contracts/agent-engine/index.js";
|
|
2
|
-
import { type PiEngineAdapter } from "../integrations/pi/engine/index.js";
|
|
3
|
-
import { type PresentationComponentPort, type PresentationRuntimePort, type PresentationTerminalPort } from "../contracts/presentation/index.js";
|
|
4
|
-
export interface ProcessCompositionOptions {
|
|
5
|
-
readonly cwd?: string;
|
|
6
|
-
readonly sessionId?: string;
|
|
7
|
-
readonly engine?: AgentEnginePort;
|
|
8
|
-
readonly presentationFactory?: (root: PresentationComponentPort, terminal: PresentationTerminalPort) => PresentationRuntimePort;
|
|
9
|
-
readonly createPiAdapter?: () => Promise<PiEngineAdapter>;
|
|
10
|
-
}
|
|
11
|
-
export interface ProcessComposition {
|
|
12
|
-
readonly engine: AgentEnginePort;
|
|
13
|
-
createPresentation(root: PresentationComponentPort, terminal: PresentationTerminalPort): PresentationRuntimePort;
|
|
14
|
-
dispose(): Promise<void>;
|
|
15
|
-
}
|
|
16
|
-
export declare function composeProcess(options?: ProcessCompositionOptions): Promise<ProcessComposition>;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { assertAgentCapabilityContract, } from "../contracts/agent-engine/index.js";
|
|
2
|
-
import { createPiEngineAdapter } from "../integrations/pi/engine/index.js";
|
|
3
|
-
import { createPiPresentationRuntime } from "../integrations/pi/tui-runtime/index.js";
|
|
4
|
-
import { assertPresentationComponent, assertPresentationRuntime, } from "../contracts/presentation/index.js";
|
|
5
|
-
import { createPiAgentEngineBridge } from "./agent-engine-bridge.js";
|
|
6
|
-
export async function composeProcess(options = {}) {
|
|
7
|
-
let engine = options.engine;
|
|
8
|
-
if (!engine) {
|
|
9
|
-
const adapter = options.createPiAdapter
|
|
10
|
-
? await options.createPiAdapter()
|
|
11
|
-
: await createPiEngineAdapter({
|
|
12
|
-
...(options.cwd === undefined ? {} : { cwd: options.cwd }),
|
|
13
|
-
...(options.sessionId === undefined ? {} : { sessionId: options.sessionId }),
|
|
14
|
-
});
|
|
15
|
-
engine = createPiAgentEngineBridge(adapter, options.cwd ?? process.cwd());
|
|
16
|
-
}
|
|
17
|
-
assertAgentCapabilityContract(engine.capabilities);
|
|
18
|
-
if (typeof engine.createSession !== "function" || typeof engine.dispose !== "function")
|
|
19
|
-
throw new TypeError("composed engine does not satisfy the neutral engine port");
|
|
20
|
-
const presentations = new Set();
|
|
21
|
-
let disposed = false;
|
|
22
|
-
return {
|
|
23
|
-
engine,
|
|
24
|
-
createPresentation(root, terminal) {
|
|
25
|
-
if (disposed)
|
|
26
|
-
throw new Error("process composition is disposed");
|
|
27
|
-
assertPresentationComponent(root);
|
|
28
|
-
const runtime = options.presentationFactory?.(root, terminal) ?? createPiPresentationRuntime(root, terminal);
|
|
29
|
-
assertPresentationRuntime(runtime);
|
|
30
|
-
presentations.add(runtime);
|
|
31
|
-
return runtime;
|
|
32
|
-
},
|
|
33
|
-
async dispose() {
|
|
34
|
-
if (disposed)
|
|
35
|
-
return;
|
|
36
|
-
disposed = true;
|
|
37
|
-
const failures = [];
|
|
38
|
-
for (const runtime of [...presentations].reverse())
|
|
39
|
-
await runtime.stop().catch(error => failures.push(error));
|
|
40
|
-
await engine.dispose().catch(error => failures.push(error));
|
|
41
|
-
if (failures.length)
|
|
42
|
-
throw new AggregateError(failures, "process composition disposal failed");
|
|
43
|
-
},
|
|
44
|
-
};
|
|
45
|
-
}
|
|
@@ -1,248 +0,0 @@
|
|
|
1
|
-
export declare const WORKSPACE_CONTRACT_VERSION: 1;
|
|
2
|
-
export declare const NATIVE_HOST_PROTOCOL_VERSION: 1;
|
|
3
|
-
export type WorkspaceId = string;
|
|
4
|
-
export type AgentId = string;
|
|
5
|
-
export type AdapterId = string;
|
|
6
|
-
export type CorrelationId = string;
|
|
7
|
-
export type EventPosition = number;
|
|
8
|
-
export type WindowId = string;
|
|
9
|
-
export type TabId = string;
|
|
10
|
-
export type PaneId = string;
|
|
11
|
-
export type TerminalSessionId = string;
|
|
12
|
-
export type TopologyNodeId = string;
|
|
13
|
-
export type NativeHostInstanceId = string;
|
|
14
|
-
export type RecoveryReferenceId = string;
|
|
15
|
-
export type AgentRuntimeKind = "structured" | "composed-terminal";
|
|
16
|
-
export type AgentLifecycleState = "creating" | "ready" | "inactive" | "stopping" | "stopped" | "failed" | "discontinuous";
|
|
17
|
-
export interface StructuredFlowLimits {
|
|
18
|
-
readonly maxEventBytes: number;
|
|
19
|
-
readonly maxSnapshotBytes: number;
|
|
20
|
-
readonly maxAttachmentBytes: number;
|
|
21
|
-
readonly maxQueuedEvents: number;
|
|
22
|
-
readonly maxConcurrentCommands: number;
|
|
23
|
-
readonly maxReconnectEvents: number;
|
|
24
|
-
}
|
|
25
|
-
export interface StructuredCapabilityContract {
|
|
26
|
-
readonly kind: "structured";
|
|
27
|
-
readonly protocolVersion: typeof WORKSPACE_CONTRACT_VERSION;
|
|
28
|
-
readonly adapterId: AdapterId;
|
|
29
|
-
readonly commands: readonly string[];
|
|
30
|
-
readonly eventTypes: readonly string[];
|
|
31
|
-
readonly snapshots: "none" | "authoritative";
|
|
32
|
-
readonly resume: "none" | "position" | "snapshot";
|
|
33
|
-
readonly cancellation: "none" | "correlated";
|
|
34
|
-
readonly attachmentTypes: readonly string[];
|
|
35
|
-
readonly flow: StructuredFlowLimits;
|
|
36
|
-
}
|
|
37
|
-
export interface ComposedTerminalCapabilityContract {
|
|
38
|
-
readonly kind: "composed-terminal";
|
|
39
|
-
readonly protocolVersion: typeof NATIVE_HOST_PROTOCOL_VERSION;
|
|
40
|
-
readonly hostInstanceId: NativeHostInstanceId;
|
|
41
|
-
readonly topologyRevision: number;
|
|
42
|
-
readonly proofStatus: "unavailable" | "pending" | "accepted" | "rejected";
|
|
43
|
-
}
|
|
44
|
-
export type AgentCapabilityContract = StructuredCapabilityContract | ComposedTerminalCapabilityContract;
|
|
45
|
-
export interface ManagedAgentDescriptor {
|
|
46
|
-
readonly id: AgentId;
|
|
47
|
-
readonly displayName: string;
|
|
48
|
-
readonly adapterId: AdapterId;
|
|
49
|
-
readonly runtime: AgentRuntimeKind;
|
|
50
|
-
readonly lifecycle: AgentLifecycleState;
|
|
51
|
-
readonly capability: AgentCapabilityContract;
|
|
52
|
-
readonly createdAt: string;
|
|
53
|
-
readonly recoveryReferenceId: RecoveryReferenceId | null;
|
|
54
|
-
}
|
|
55
|
-
export interface TerminalDimensions {
|
|
56
|
-
readonly columns: number;
|
|
57
|
-
readonly rows: number;
|
|
58
|
-
readonly widthPixels: number;
|
|
59
|
-
readonly heightPixels: number;
|
|
60
|
-
}
|
|
61
|
-
export interface TerminalSessionLaunch {
|
|
62
|
-
readonly id: TerminalSessionId;
|
|
63
|
-
readonly executable: string;
|
|
64
|
-
readonly arguments: readonly string[];
|
|
65
|
-
readonly cwd: string;
|
|
66
|
-
readonly environment: Readonly<Record<string, string>>;
|
|
67
|
-
readonly dimensions: TerminalDimensions;
|
|
68
|
-
readonly inactivity: "live-unpainted" | "pause-display" | "suspend" | "terminate";
|
|
69
|
-
}
|
|
70
|
-
export interface TerminalPane {
|
|
71
|
-
readonly id: PaneId;
|
|
72
|
-
readonly sessionId: TerminalSessionId;
|
|
73
|
-
}
|
|
74
|
-
export type TerminalTopologyNode = {
|
|
75
|
-
readonly id: TopologyNodeId;
|
|
76
|
-
readonly kind: "leaf";
|
|
77
|
-
readonly paneId: PaneId;
|
|
78
|
-
} | {
|
|
79
|
-
readonly id: TopologyNodeId;
|
|
80
|
-
readonly kind: "split";
|
|
81
|
-
readonly axis: "horizontal" | "vertical";
|
|
82
|
-
readonly ratio: number;
|
|
83
|
-
readonly first: TopologyNodeId;
|
|
84
|
-
readonly second: TopologyNodeId;
|
|
85
|
-
};
|
|
86
|
-
export interface TerminalTab {
|
|
87
|
-
readonly id: TabId;
|
|
88
|
-
readonly rootNodeId: TopologyNodeId;
|
|
89
|
-
readonly focusedPaneId: PaneId;
|
|
90
|
-
readonly nodes: readonly TerminalTopologyNode[];
|
|
91
|
-
readonly panes: readonly TerminalPane[];
|
|
92
|
-
}
|
|
93
|
-
export interface TerminalWindow {
|
|
94
|
-
readonly id: WindowId;
|
|
95
|
-
readonly activeTabId: TabId;
|
|
96
|
-
readonly tabs: readonly TerminalTab[];
|
|
97
|
-
}
|
|
98
|
-
export interface TerminalTopologySnapshot {
|
|
99
|
-
readonly hostInstanceId: NativeHostInstanceId;
|
|
100
|
-
readonly revision: number;
|
|
101
|
-
readonly windows: readonly TerminalWindow[];
|
|
102
|
-
readonly sessions: readonly TerminalSessionLaunch[];
|
|
103
|
-
}
|
|
104
|
-
export type WorkspaceCommand = {
|
|
105
|
-
readonly type: "create-agent";
|
|
106
|
-
readonly correlationId: CorrelationId;
|
|
107
|
-
readonly agent: ManagedAgentDescriptor;
|
|
108
|
-
} | {
|
|
109
|
-
readonly type: "select-agent";
|
|
110
|
-
readonly correlationId: CorrelationId;
|
|
111
|
-
readonly agentId: AgentId;
|
|
112
|
-
} | {
|
|
113
|
-
readonly type: "rename-agent";
|
|
114
|
-
readonly correlationId: CorrelationId;
|
|
115
|
-
readonly agentId: AgentId;
|
|
116
|
-
readonly displayName: string;
|
|
117
|
-
} | {
|
|
118
|
-
readonly type: "stop-agent" | "restart-agent" | "remove-agent";
|
|
119
|
-
readonly correlationId: CorrelationId;
|
|
120
|
-
readonly agentId: AgentId;
|
|
121
|
-
} | {
|
|
122
|
-
readonly type: "structured-command";
|
|
123
|
-
readonly correlationId: CorrelationId;
|
|
124
|
-
readonly agentId: AgentId;
|
|
125
|
-
readonly command: string;
|
|
126
|
-
readonly payload: unknown;
|
|
127
|
-
} | {
|
|
128
|
-
readonly type: "cancel-structured-command";
|
|
129
|
-
readonly correlationId: CorrelationId;
|
|
130
|
-
readonly agentId: AgentId;
|
|
131
|
-
readonly targetCorrelationId: CorrelationId;
|
|
132
|
-
};
|
|
133
|
-
export type WorkspaceEvent = {
|
|
134
|
-
readonly type: "agent-lifecycle";
|
|
135
|
-
readonly agentId: AgentId;
|
|
136
|
-
readonly position: EventPosition;
|
|
137
|
-
readonly state: AgentLifecycleState;
|
|
138
|
-
} | {
|
|
139
|
-
readonly type: "structured-event";
|
|
140
|
-
readonly agentId: AgentId;
|
|
141
|
-
readonly position: EventPosition;
|
|
142
|
-
readonly eventType: string;
|
|
143
|
-
readonly payload: unknown;
|
|
144
|
-
} | {
|
|
145
|
-
readonly type: "command-outcome";
|
|
146
|
-
readonly agentId: AgentId;
|
|
147
|
-
readonly correlationId: CorrelationId;
|
|
148
|
-
readonly outcome: "accepted" | "rejected" | "completed" | "failed" | "timed-out" | "cancelled";
|
|
149
|
-
} | {
|
|
150
|
-
readonly type: "terminal-topology";
|
|
151
|
-
readonly agentId: AgentId;
|
|
152
|
-
readonly topology: TerminalTopologySnapshot;
|
|
153
|
-
} | {
|
|
154
|
-
readonly type: "recovery-discontinuity";
|
|
155
|
-
readonly agentId: AgentId;
|
|
156
|
-
readonly reason: string;
|
|
157
|
-
};
|
|
158
|
-
export interface WorkspaceSnapshot {
|
|
159
|
-
readonly contractVersion: typeof WORKSPACE_CONTRACT_VERSION;
|
|
160
|
-
readonly workspaceId: WorkspaceId;
|
|
161
|
-
readonly revision: number;
|
|
162
|
-
readonly selectedAgentId: AgentId | null;
|
|
163
|
-
readonly agents: readonly ManagedAgentDescriptor[];
|
|
164
|
-
}
|
|
165
|
-
export interface StructuredAgentSnapshot {
|
|
166
|
-
readonly contractVersion: typeof WORKSPACE_CONTRACT_VERSION;
|
|
167
|
-
readonly agentId: AgentId;
|
|
168
|
-
readonly snapshotId: string;
|
|
169
|
-
readonly position: EventPosition;
|
|
170
|
-
readonly authoritative: true;
|
|
171
|
-
readonly payload: unknown;
|
|
172
|
-
}
|
|
173
|
-
export interface NativeHostHello {
|
|
174
|
-
readonly protocolVersion: typeof NATIVE_HOST_PROTOCOL_VERSION;
|
|
175
|
-
readonly hostInstanceId: NativeHostInstanceId;
|
|
176
|
-
readonly buildId: string;
|
|
177
|
-
readonly platform: "windows" | "macos" | "linux";
|
|
178
|
-
readonly capabilities: readonly ("exact-command" | "revisioned-topology" | "native-input" | "native-rendering" | "retained-terminal-state")[];
|
|
179
|
-
}
|
|
180
|
-
export type NativeHostCommand = {
|
|
181
|
-
readonly type: "snapshot";
|
|
182
|
-
readonly correlationId: CorrelationId;
|
|
183
|
-
} | {
|
|
184
|
-
readonly type: "apply-topology";
|
|
185
|
-
readonly correlationId: CorrelationId;
|
|
186
|
-
readonly expectedRevision: number;
|
|
187
|
-
readonly topology: TerminalTopologySnapshot;
|
|
188
|
-
} | {
|
|
189
|
-
readonly type: "focus-pane";
|
|
190
|
-
readonly correlationId: CorrelationId;
|
|
191
|
-
readonly expectedRevision: number;
|
|
192
|
-
readonly paneId: PaneId;
|
|
193
|
-
} | {
|
|
194
|
-
readonly type: "close-pane";
|
|
195
|
-
readonly correlationId: CorrelationId;
|
|
196
|
-
readonly expectedRevision: number;
|
|
197
|
-
readonly paneId: PaneId;
|
|
198
|
-
} | {
|
|
199
|
-
readonly type: "shutdown";
|
|
200
|
-
readonly correlationId: CorrelationId;
|
|
201
|
-
};
|
|
202
|
-
export type NativeHostEvent = {
|
|
203
|
-
readonly type: "topology-changed";
|
|
204
|
-
readonly topology: TerminalTopologySnapshot;
|
|
205
|
-
} | {
|
|
206
|
-
readonly type: "pane-ready";
|
|
207
|
-
readonly paneId: PaneId;
|
|
208
|
-
readonly sessionId: TerminalSessionId;
|
|
209
|
-
} | {
|
|
210
|
-
readonly type: "process-exited";
|
|
211
|
-
readonly paneId: PaneId;
|
|
212
|
-
readonly sessionId: TerminalSessionId;
|
|
213
|
-
readonly exitCode: number | null;
|
|
214
|
-
readonly signal: string | null;
|
|
215
|
-
} | {
|
|
216
|
-
readonly type: "host-degraded";
|
|
217
|
-
readonly code: string;
|
|
218
|
-
readonly message: string;
|
|
219
|
-
};
|
|
220
|
-
export interface StructuredRecoveryAuthority {
|
|
221
|
-
readonly kind: "structured";
|
|
222
|
-
readonly referenceId: RecoveryReferenceId;
|
|
223
|
-
readonly agentId: AgentId;
|
|
224
|
-
readonly adapterId: AdapterId;
|
|
225
|
-
readonly processIdentity: string;
|
|
226
|
-
readonly ownershipProof: string;
|
|
227
|
-
readonly boundary: {
|
|
228
|
-
readonly kind: "position";
|
|
229
|
-
readonly position: EventPosition;
|
|
230
|
-
readonly resumeToken: string;
|
|
231
|
-
} | {
|
|
232
|
-
readonly kind: "snapshot";
|
|
233
|
-
readonly snapshotId: string;
|
|
234
|
-
};
|
|
235
|
-
}
|
|
236
|
-
export interface ComposedRecoveryAuthority {
|
|
237
|
-
readonly kind: "composed-terminal";
|
|
238
|
-
readonly referenceId: RecoveryReferenceId;
|
|
239
|
-
readonly agentId: AgentId;
|
|
240
|
-
readonly hostInstanceId: NativeHostInstanceId;
|
|
241
|
-
readonly hostBuildId: string;
|
|
242
|
-
readonly processIdentity: string;
|
|
243
|
-
readonly pseudoterminalIdentity: string;
|
|
244
|
-
readonly retainedStateIdentity: string;
|
|
245
|
-
readonly topologyRevision: number;
|
|
246
|
-
readonly streamPosition: number;
|
|
247
|
-
}
|
|
248
|
-
export type AgentRecoveryAuthority = StructuredRecoveryAuthority | ComposedRecoveryAuthority;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { AgentCapabilityContract, AgentRecoveryAuthority, ComposedTerminalCapabilityContract, ManagedAgentDescriptor, NativeHostCommand, StructuredAgentSnapshot, StructuredCapabilityContract, TerminalSessionLaunch, TerminalTopologySnapshot, WorkspaceCommand, WorkspaceEvent, WorkspaceSnapshot } from "./model.js";
|
|
2
|
-
export declare function assertManagedAgentDescriptor(agent: ManagedAgentDescriptor): void;
|
|
3
|
-
export declare function assertAgentCapability(capability: AgentCapabilityContract): void;
|
|
4
|
-
export declare function assertStructuredCapability(capability: StructuredCapabilityContract): void;
|
|
5
|
-
export declare function assertComposedTerminalCapability(capability: ComposedTerminalCapabilityContract): void;
|
|
6
|
-
export declare function assertWorkspaceSnapshot(snapshot: WorkspaceSnapshot): void;
|
|
7
|
-
export declare function assertWorkspaceCommand(command: WorkspaceCommand): void;
|
|
8
|
-
export declare function assertWorkspaceEvent(event: WorkspaceEvent): void;
|
|
9
|
-
export declare function assertStructuredAgentSnapshot(snapshot: StructuredAgentSnapshot): void;
|
|
10
|
-
export declare function assertTerminalTopologySnapshot(topology: TerminalTopologySnapshot): void;
|
|
11
|
-
export declare function assertNativeHostCommand(command: NativeHostCommand): void;
|
|
12
|
-
export declare function assertRecoveryAuthority(authority: AgentRecoveryAuthority): void;
|
|
13
|
-
export declare function assertTerminalSessionLaunch(session: TerminalSessionLaunch): void;
|