@code-yeongyu/senpi 2026.9.11 → 2026.9.12-3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +83 -0
- package/README.md +1 -1
- package/dist/bun/cli.d.ts +2 -1
- package/dist/bun/cli.d.ts.map +1 -1
- package/dist/bun/cli.js +5 -8
- package/dist/bun/cli.js.map +1 -1
- package/dist/bun/runtime-setup.d.ts +2 -0
- package/dist/bun/runtime-setup.d.ts.map +1 -0
- package/dist/bun/runtime-setup.js +9 -0
- package/dist/bun/runtime-setup.js.map +1 -0
- package/dist/bun/sandbox-env-setup.d.ts +2 -0
- package/dist/bun/sandbox-env-setup.d.ts.map +1 -0
- package/dist/bun/sandbox-env-setup.js +4 -0
- package/dist/bun/sandbox-env-setup.js.map +1 -0
- package/dist/cli/config-selector.d.ts.map +1 -1
- package/dist/cli/config-selector.js +2 -1
- package/dist/cli/config-selector.js.map +1 -1
- package/dist/cli/setup.d.ts +2 -0
- package/dist/cli/setup.d.ts.map +1 -0
- package/dist/cli/setup.js +12 -0
- package/dist/cli/setup.js.map +1 -0
- package/dist/cli.js +3 -0
- package/dist/cli.js.map +1 -1
- package/dist/client/index.d.ts +1 -2
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +1 -2
- package/dist/client/index.js.map +1 -1
- package/dist/config.d.ts +1 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +1 -0
- package/dist/config.js.map +1 -1
- package/dist/core/agent-session-runtime.d.ts.map +1 -1
- package/dist/core/agent-session-runtime.js +18 -6
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session.d.ts +54 -17
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +153 -157
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/compaction/branch-summarization.d.ts +1 -1
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +6 -4
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction-settings-access.d.ts +18 -2
- package/dist/core/compaction-settings-access.d.ts.map +1 -1
- package/dist/core/compaction-settings-access.js +35 -4
- package/dist/core/compaction-settings-access.js.map +1 -1
- package/dist/core/compaction-settings-resolver.d.ts +2 -2
- package/dist/core/compaction-settings-resolver.d.ts.map +1 -1
- package/dist/core/compaction-settings-resolver.js +6 -3
- package/dist/core/compaction-settings-resolver.js.map +1 -1
- package/dist/core/cursor-history-admission.d.ts +50 -0
- package/dist/core/cursor-history-admission.d.ts.map +1 -0
- package/dist/core/cursor-history-admission.js +130 -0
- package/dist/core/cursor-history-admission.js.map +1 -0
- package/dist/core/extensions/builtin/ask-user/extension.d.ts.map +1 -1
- package/dist/core/extensions/builtin/ask-user/extension.js +11 -0
- package/dist/core/extensions/builtin/ask-user/extension.js.map +1 -1
- package/dist/core/extensions/builtin/cursor-cli-oauth/models.d.ts.map +1 -1
- package/dist/core/extensions/builtin/cursor-cli-oauth/models.js +2 -1
- package/dist/core/extensions/builtin/cursor-cli-oauth/models.js.map +1 -1
- package/dist/core/extensions/builtin/prompt-preset/presets.d.ts.map +1 -1
- package/dist/core/extensions/builtin/prompt-preset/presets.js +7 -1
- package/dist/core/extensions/builtin/prompt-preset/presets.js.map +1 -1
- package/dist/core/extensions/loader.d.ts.map +1 -1
- package/dist/core/extensions/loader.js +4 -2
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/keybindings.d.ts +10 -0
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +8 -0
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/messages.d.ts +1 -1
- package/dist/core/messages.d.ts.map +1 -1
- package/dist/core/messages.js.map +1 -1
- package/dist/core/model-registry.d.ts +5 -1
- package/dist/core/model-registry.d.ts.map +1 -1
- package/dist/core/model-registry.js +8 -0
- package/dist/core/model-registry.js.map +1 -1
- package/dist/core/model-resolver.d.ts.map +1 -1
- package/dist/core/model-resolver.js +2 -0
- package/dist/core/model-resolver.js.map +1 -1
- package/dist/core/model-runtime.d.ts +1 -0
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +5 -2
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/retry-fallback/settings.d.ts +2 -0
- package/dist/core/retry-fallback/settings.d.ts.map +1 -1
- package/dist/core/retry-fallback/settings.js.map +1 -1
- package/dist/core/session-manager.d.ts +5 -2
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +68 -19
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/session-write-reservation.d.ts +9 -0
- package/dist/core/session-write-reservation.d.ts.map +1 -1
- package/dist/core/session-write-reservation.js +33 -0
- package/dist/core/session-write-reservation.js.map +1 -1
- package/dist/core/settings-manager.d.ts +12 -5
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +18 -6
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/settings-public-types.d.ts +1 -1
- package/dist/core/settings-public-types.d.ts.map +1 -1
- package/dist/core/settings-public-types.js.map +1 -1
- package/dist/core/skills.d.ts +1 -1
- package/dist/core/skills.d.ts.map +1 -1
- package/dist/core/skills.js +6 -2
- package/dist/core/skills.js.map +1 -1
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +8 -9
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/core/tools/bash.d.ts.map +1 -1
- package/dist/core/tools/bash.js +3 -142
- package/dist/core/tools/bash.js.map +1 -1
- package/dist/core/tools/edit.d.ts +1 -12
- package/dist/core/tools/edit.d.ts.map +1 -1
- package/dist/core/tools/edit.js +4 -168
- package/dist/core/tools/edit.js.map +1 -1
- package/dist/core/tools/find.d.ts.map +1 -1
- package/dist/core/tools/find.js +2 -53
- package/dist/core/tools/find.js.map +1 -1
- package/dist/core/tools/grep.d.ts.map +1 -1
- package/dist/core/tools/grep.js +2 -58
- package/dist/core/tools/grep.js.map +1 -1
- package/dist/core/tools/ls.d.ts.map +1 -1
- package/dist/core/tools/ls.js +2 -47
- package/dist/core/tools/ls.js.map +1 -1
- package/dist/core/tools/read.d.ts +1 -4
- package/dist/core/tools/read.d.ts.map +1 -1
- package/dist/core/tools/read.js +4 -141
- package/dist/core/tools/read.js.map +1 -1
- package/dist/core/tools/renderers/bash.d.ts +12 -0
- package/dist/core/tools/renderers/bash.d.ts.map +1 -0
- package/dist/core/tools/renderers/bash.js +156 -0
- package/dist/core/tools/renderers/bash.js.map +1 -0
- package/dist/core/tools/renderers/edit.d.ts +23 -0
- package/dist/core/tools/renderers/edit.d.ts.map +1 -0
- package/dist/core/tools/renderers/edit.js +172 -0
- package/dist/core/tools/renderers/edit.js.map +1 -0
- package/dist/core/tools/renderers/find.d.ts +10 -0
- package/dist/core/tools/renderers/find.d.ts.map +1 -0
- package/dist/core/tools/renderers/find.js +64 -0
- package/dist/core/tools/renderers/find.js.map +1 -0
- package/dist/core/tools/renderers/grep.d.ts +10 -0
- package/dist/core/tools/renderers/grep.d.ts.map +1 -0
- package/dist/core/tools/renderers/grep.js +69 -0
- package/dist/core/tools/renderers/grep.js.map +1 -0
- package/dist/core/tools/renderers/index.d.ts +28 -0
- package/dist/core/tools/renderers/index.d.ts.map +1 -0
- package/dist/core/tools/renderers/index.js +47 -0
- package/dist/core/tools/renderers/index.js.map +1 -0
- package/dist/core/tools/renderers/ls.d.ts +10 -0
- package/dist/core/tools/renderers/ls.d.ts.map +1 -0
- package/dist/core/tools/renderers/ls.js +58 -0
- package/dist/core/tools/renderers/ls.js.map +1 -0
- package/dist/core/tools/renderers/read.d.ts +19 -0
- package/dist/core/tools/renderers/read.d.ts.map +1 -0
- package/dist/core/tools/renderers/read.js +149 -0
- package/dist/core/tools/renderers/read.js.map +1 -0
- package/dist/core/tools/renderers/write.d.ts +10 -0
- package/dist/core/tools/renderers/write.d.ts.map +1 -0
- package/dist/core/tools/renderers/write.js +162 -0
- package/dist/core/tools/renderers/write.js.map +1 -0
- package/dist/core/tools/write.d.ts.map +1 -1
- package/dist/core/tools/write.js +4 -153
- package/dist/core/tools/write.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/migrations.d.ts.map +1 -1
- package/dist/migrations.js +2 -2
- package/dist/migrations.js.map +1 -1
- package/dist/modes/app-server/threads/turn-runtime.d.ts +3 -1
- package/dist/modes/app-server/threads/turn-runtime.d.ts.map +1 -1
- package/dist/modes/app-server/threads/turn-runtime.js.map +1 -1
- package/dist/modes/app-server/threads/turns.js +1 -1
- package/dist/modes/app-server/threads/turns.js.map +1 -1
- package/dist/modes/app-server/turn-adapter.js +4 -2
- package/dist/modes/app-server/turn-adapter.js.map +1 -1
- package/dist/modes/interactive/chat-viewport.d.ts +22 -0
- package/dist/modes/interactive/chat-viewport.d.ts.map +1 -0
- package/dist/modes/interactive/chat-viewport.js +29 -0
- package/dist/modes/interactive/chat-viewport.js.map +1 -0
- package/dist/modes/interactive/components/ask-user-answer-key.d.ts +14 -0
- package/dist/modes/interactive/components/ask-user-answer-key.d.ts.map +1 -0
- package/dist/modes/interactive/components/ask-user-answer-key.js +65 -0
- package/dist/modes/interactive/components/ask-user-answer-key.js.map +1 -0
- package/dist/modes/interactive/components/ask-user-async-widget.d.ts +17 -12
- package/dist/modes/interactive/components/ask-user-async-widget.d.ts.map +1 -1
- package/dist/modes/interactive/components/ask-user-async-widget.js +47 -23
- package/dist/modes/interactive/components/ask-user-async-widget.js.map +1 -1
- package/dist/modes/interactive/components/assistant-message.d.ts +7 -0
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +26 -2
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/assistant-render-descriptors.d.ts +4 -0
- package/dist/modes/interactive/components/assistant-render-descriptors.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-render-descriptors.js +8 -5
- package/dist/modes/interactive/components/assistant-render-descriptors.js.map +1 -1
- package/dist/modes/interactive/components/custom-editor.d.ts +10 -1
- package/dist/modes/interactive/components/custom-editor.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-editor.js +37 -1
- package/dist/modes/interactive/components/custom-editor.js.map +1 -1
- package/dist/modes/interactive/components/index.d.ts +1 -1
- package/dist/modes/interactive/components/index.d.ts.map +1 -1
- package/dist/modes/interactive/components/index.js.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +8 -8
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -1
- package/dist/modes/interactive/components/status-indicator.d.ts +4 -1
- package/dist/modes/interactive/components/status-indicator.d.ts.map +1 -1
- package/dist/modes/interactive/components/status-indicator.js +14 -2
- package/dist/modes/interactive/components/status-indicator.js.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.js +4 -4
- package/dist/modes/interactive/components/thinking-selector.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution-renderer.d.ts +4 -1
- package/dist/modes/interactive/components/tool-execution-renderer.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution-renderer.js +23 -10
- package/dist/modes/interactive/components/tool-execution-renderer.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution-types.d.ts +18 -2
- package/dist/modes/interactive/components/tool-execution-types.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution-types.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +3 -3
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +5 -0
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +10 -15
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +178 -138
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/theme/dark.json +2 -1
- package/dist/modes/interactive/theme/grok-day.json +2 -1
- package/dist/modes/interactive/theme/grok-night.json +2 -1
- package/dist/modes/interactive/theme/light.json +2 -1
- package/dist/modes/interactive/theme/theme-controller.d.ts +1 -0
- package/dist/modes/interactive/theme/theme-controller.d.ts.map +1 -1
- package/dist/modes/interactive/theme/theme-controller.js +5 -0
- package/dist/modes/interactive/theme/theme-controller.js.map +1 -1
- package/dist/modes/interactive/theme/theme-json.d.ts +84 -0
- package/dist/modes/interactive/theme/theme-json.d.ts.map +1 -0
- package/dist/modes/interactive/theme/theme-json.js +130 -0
- package/dist/modes/interactive/theme/theme-json.js.map +1 -0
- package/dist/modes/interactive/theme/theme-schema.json +6 -2
- package/dist/modes/interactive/theme/theme.d.ts +10 -5
- package/dist/modes/interactive/theme/theme.d.ts.map +1 -1
- package/dist/modes/interactive/theme/theme.js +14 -117
- package/dist/modes/interactive/theme/theme.js.map +1 -1
- package/dist/modes/interactive/tips/catalog/input-tips.d.ts +5 -0
- package/dist/modes/interactive/tips/catalog/input-tips.d.ts.map +1 -1
- package/dist/modes/interactive/tips/catalog/input-tips.js +5 -0
- package/dist/modes/interactive/tips/catalog/input-tips.js.map +1 -1
- package/dist/modes/interactive/tui-renderer.d.ts +21 -0
- package/dist/modes/interactive/tui-renderer.d.ts.map +1 -0
- package/dist/modes/interactive/tui-renderer.js +67 -0
- package/dist/modes/interactive/tui-renderer.js.map +1 -0
- package/dist/modes/rpc/connection-handler.d.ts.map +1 -1
- package/dist/modes/rpc/connection-handler.js +8 -2
- package/dist/modes/rpc/connection-handler.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +11 -1
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +2 -1
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js +1 -0
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/dist/modes/rpc/session-path-reservations.d.ts +30 -0
- package/dist/modes/rpc/session-path-reservations.d.ts.map +1 -0
- package/dist/modes/rpc/session-path-reservations.js +58 -0
- package/dist/modes/rpc/session-path-reservations.js.map +1 -0
- package/dist/modes/rpc/session-registry.d.ts +3 -1
- package/dist/modes/rpc/session-registry.d.ts.map +1 -1
- package/dist/modes/rpc/session-registry.js.map +1 -1
- package/dist/modes/rpc/session-worker-client.d.ts +10 -8
- package/dist/modes/rpc/session-worker-client.d.ts.map +1 -1
- package/dist/modes/rpc/session-worker-client.js +14 -23
- package/dist/modes/rpc/session-worker-client.js.map +1 -1
- package/dist/modes/rpc/session-worker-credit.d.ts +17 -0
- package/dist/modes/rpc/session-worker-credit.d.ts.map +1 -0
- package/dist/modes/rpc/session-worker-credit.js +39 -0
- package/dist/modes/rpc/session-worker-credit.js.map +1 -0
- package/dist/modes/rpc/session-worker-protocol.d.ts +10 -0
- package/dist/modes/rpc/session-worker-protocol.d.ts.map +1 -1
- package/dist/modes/rpc/session-worker-protocol.js +2 -0
- package/dist/modes/rpc/session-worker-protocol.js.map +1 -1
- package/dist/modes/rpc/session-worker-signals.d.ts +7 -0
- package/dist/modes/rpc/session-worker-signals.d.ts.map +1 -0
- package/dist/modes/rpc/session-worker-signals.js +19 -0
- package/dist/modes/rpc/session-worker-signals.js.map +1 -0
- package/dist/modes/rpc/session-worker.js +12 -16
- package/dist/modes/rpc/session-worker.js.map +1 -1
- package/dist/modes/rpc/worker-session-registry.d.ts +12 -0
- package/dist/modes/rpc/worker-session-registry.d.ts.map +1 -1
- package/dist/modes/rpc/worker-session-registry.js +51 -24
- package/dist/modes/rpc/worker-session-registry.js.map +1 -1
- package/dist/senpi +3 -0
- package/dist/utils/clipboard-command.d.ts +7 -0
- package/dist/utils/clipboard-command.d.ts.map +1 -0
- package/dist/utils/clipboard-command.js +45 -0
- package/dist/utils/clipboard-command.js.map +1 -0
- package/dist/utils/clipboard-image.d.ts.map +1 -1
- package/dist/utils/clipboard-image.js +52 -69
- package/dist/utils/clipboard-image.js.map +1 -1
- package/dist/utils/clipboard.d.ts.map +1 -1
- package/dist/utils/clipboard.js +49 -126
- package/dist/utils/clipboard.js.map +1 -1
- package/dist/utils/exif-orientation.d.ts.map +1 -1
- package/dist/utils/exif-orientation.js +2 -3
- package/dist/utils/exif-orientation.js.map +1 -1
- package/dist/utils/tools-manager.d.ts +1 -0
- package/dist/utils/tools-manager.d.ts.map +1 -1
- package/dist/utils/tools-manager.js +41 -19
- package/dist/utils/tools-manager.js.map +1 -1
- package/docs/compaction.md +39 -13
- package/docs/containerization.md +45 -0
- package/docs/development.md +19 -0
- package/docs/docs.json +4 -0
- package/docs/environment-variables.md +2 -0
- package/docs/extensions.md +21 -10
- package/docs/keybindings.md +7 -2
- package/docs/models.md +1 -1
- package/docs/providers.md +1 -1
- package/docs/rpc.md +16 -8
- package/docs/sdk.md +7 -0
- package/docs/session-format.md +52 -38
- package/docs/settings.md +40 -4
- package/docs/skills.md +1 -1
- package/docs/termux.md +0 -1
- package/docs/themes.md +8 -6
- package/docs/tui.md +22 -3
- package/examples/README.md +3 -0
- package/examples/extensions/dynamic-resources/dynamic.json +2 -0
- package/examples/plugins/pi-example-plugin/README.md +38 -0
- package/examples/plugins/pi-example-plugin/package.json +10 -0
- package/examples/plugins/pi-example-plugin/src/contract.ts +13 -0
- package/examples/plugins/pi-example-plugin/src/session.ts +23 -0
- package/examples/plugins/pi-example-plugin/src/tui.ts +31 -0
- package/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js +1 -1
- package/node_modules/@aws-sdk/client-bedrock-runtime/package.json +3 -3
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/util/index.js +5 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/util/hasOwn.js +3 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/util/index.js +1 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/util/hasOwn.d.ts +4 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/util/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/util/hasOwn.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/util/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/package.json +1 -1
- package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-http/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +9 -9
- package/node_modules/@aws-sdk/credential-provider-login/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-node/dist-cjs/index.js +2 -0
- package/node_modules/@aws-sdk/credential-provider-node/dist-es/runtime/memoize-chain.js +2 -0
- package/node_modules/@aws-sdk/credential-provider-node/package.json +7 -7
- package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/LICENSE +201 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/README.md +62 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +158 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/constants.js +2 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromEnvSigningName.js +16 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +84 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromStatic.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getNewSsoOidcToken.js +11 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getSsoOidcClient.js +10 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/index.js +4 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/nodeProvider.js +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenExpiry.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenKey.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/writeSSOTokenToFile.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/constants.d.ts +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/fromEnvSigningName.d.ts +18 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/fromSso.d.ts +12 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/fromStatic.d.ts +9 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/getNewSsoOidcToken.d.ts +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/getSsoOidcClient.d.ts +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/index.d.ts +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/nodeProvider.d.ts +18 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/constants.d.ts +3 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/fromEnvSigningName.d.ts +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/fromSso.d.ts +10 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/fromStatic.d.ts +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/getNewSsoOidcToken.d.ts +9 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/getSsoOidcClient.d.ts +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/index.d.ts +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/nodeProvider.d.ts +3 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/validateTokenExpiry.d.ts +2 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/validateTokenKey.d.ts +1 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/ts3.4/writeSSOTokenToFile.d.ts +2 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/validateTokenExpiry.d.ts +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/validateTokenKey.d.ts +4 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-types/writeSSOTokenToFile.d.ts +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/package.json +69 -0
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +1 -1
- package/node_modules/@aws-sdk/nested-clients/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +1 -1
- package/node_modules/@code-yeongyu/senpi-codemode/CHANGELOG.md +36 -0
- package/node_modules/@code-yeongyu/senpi-codemode/package.json +5 -5
- package/node_modules/@earendil-works/chord/README.md +205 -0
- package/node_modules/@earendil-works/chord/dist/api.d.ts +15 -0
- package/node_modules/@earendil-works/chord/dist/api.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/api.js +72 -0
- package/node_modules/@earendil-works/chord/dist/api.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/bundler.d.ts +6 -0
- package/node_modules/@earendil-works/chord/dist/bundler.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/bundler.js +3 -0
- package/node_modules/@earendil-works/chord/dist/bundler.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/context/index.d.ts +24 -0
- package/node_modules/@earendil-works/chord/dist/context/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/context/index.js +97 -0
- package/node_modules/@earendil-works/chord/dist/context/index.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/delta/index.d.ts +119 -0
- package/node_modules/@earendil-works/chord/dist/delta/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/delta/index.js +1209 -0
- package/node_modules/@earendil-works/chord/dist/delta/index.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/facets/host.d.ts +12 -0
- package/node_modules/@earendil-works/chord/dist/facets/host.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/facets/host.js +762 -0
- package/node_modules/@earendil-works/chord/dist/facets/host.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/facets/loader.d.ts +3 -0
- package/node_modules/@earendil-works/chord/dist/facets/loader.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/facets/loader.js +5 -0
- package/node_modules/@earendil-works/chord/dist/facets/loader.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/index.d.ts +11 -0
- package/node_modules/@earendil-works/chord/dist/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/index.js +10 -0
- package/node_modules/@earendil-works/chord/dist/index.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/json.d.ts +4 -0
- package/node_modules/@earendil-works/chord/dist/json.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/json.js +57 -0
- package/node_modules/@earendil-works/chord/dist/json.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle-loader.d.ts +30 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle-loader.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle-loader.js +377 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle-loader.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle.d.ts +26 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle.js +183 -0
- package/node_modules/@earendil-works/chord/dist/node/bundle.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/manifest.d.ts +36 -0
- package/node_modules/@earendil-works/chord/dist/node/manifest.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/manifest.js +6 -0
- package/node_modules/@earendil-works/chord/dist/node/manifest.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/package.d.ts +15 -0
- package/node_modules/@earendil-works/chord/dist/node/package.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node/package.js +199 -0
- package/node_modules/@earendil-works/chord/dist/node/package.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node.d.ts +5 -0
- package/node_modules/@earendil-works/chord/dist/node.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/node.js +3 -0
- package/node_modules/@earendil-works/chord/dist/node.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/consumer.d.ts +11 -0
- package/node_modules/@earendil-works/chord/dist/services/consumer.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/consumer.js +535 -0
- package/node_modules/@earendil-works/chord/dist/services/consumer.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/errors.d.ts +8 -0
- package/node_modules/@earendil-works/chord/dist/services/errors.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/errors.js +21 -0
- package/node_modules/@earendil-works/chord/dist/services/errors.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/handle.d.ts +15 -0
- package/node_modules/@earendil-works/chord/dist/services/handle.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/handle.js +99 -0
- package/node_modules/@earendil-works/chord/dist/services/handle.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/instances.d.ts +25 -0
- package/node_modules/@earendil-works/chord/dist/services/instances.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/instances.js +137 -0
- package/node_modules/@earendil-works/chord/dist/services/instances.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/loopback.d.ts +5 -0
- package/node_modules/@earendil-works/chord/dist/services/loopback.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/loopback.js +15 -0
- package/node_modules/@earendil-works/chord/dist/services/loopback.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/provider.d.ts +37 -0
- package/node_modules/@earendil-works/chord/dist/services/provider.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/provider.js +472 -0
- package/node_modules/@earendil-works/chord/dist/services/provider.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state-codec.d.ts +15 -0
- package/node_modules/@earendil-works/chord/dist/services/state-codec.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state-codec.js +115 -0
- package/node_modules/@earendil-works/chord/dist/services/state-codec.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state-internals.d.ts +11 -0
- package/node_modules/@earendil-works/chord/dist/services/state-internals.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state-internals.js +10 -0
- package/node_modules/@earendil-works/chord/dist/services/state-internals.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state.d.ts +23 -0
- package/node_modules/@earendil-works/chord/dist/services/state.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/state.js +124 -0
- package/node_modules/@earendil-works/chord/dist/services/state.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/wire.d.ts +60 -0
- package/node_modules/@earendil-works/chord/dist/services/wire.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/services/wire.js +173 -0
- package/node_modules/@earendil-works/chord/dist/services/wire.js.map +1 -0
- package/node_modules/@earendil-works/chord/dist/types.d.ts +203 -0
- package/node_modules/@earendil-works/chord/dist/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/chord/dist/types.js +2 -0
- package/node_modules/@earendil-works/chord/dist/types.js.map +1 -0
- package/node_modules/@earendil-works/chord/package.json +73 -0
- package/node_modules/@earendil-works/pi-agent-core/README.md +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.d.ts +639 -384
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.js +5 -250
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.d.ts +12 -6
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.js +33 -27
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.d.ts +30 -8
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.js +53 -64
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/config.d.ts +9 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/config.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/config.js +35 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/config.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/context.d.ts +9 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/context.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/context.js +13 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/context.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.d.ts +25 -28
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.js +368 -125
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/events.d.ts +20 -38
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/events.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/events.js +233 -55
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/events.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/assistant.d.ts +42 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/assistant.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/assistant.js +82 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/assistant.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/effect-gate.d.ts +22 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/effect-gate.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/effect-gate.js +48 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/effect-gate.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/tools.d.ts +67 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/tools.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/tools.js +121 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution/tools.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/hooks.d.ts +38 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/hooks.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/hooks.js +404 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/hooks.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.d.ts +2 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.d.ts +3 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.js +17 -17
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/result.d.ts +93 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/result.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/result.js +39 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/result.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/boundary.d.ts +28 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/boundary.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/boundary.js +173 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/boundary.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/checkpoint.d.ts +8 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/checkpoint.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/checkpoint.js +133 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/checkpoint.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/deferred.d.ts +15 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/deferred.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/deferred.js +179 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/deferred.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/generation.d.ts +8 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/generation.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/generation.js +205 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/generation.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/reconcile.d.ts +5 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/reconcile.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/reconcile.js +140 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/reconcile.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/recovery.d.ts +8 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/recovery.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/recovery.js +85 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/recovery.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/response.d.ts +23 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/response.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/response.js +394 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/response.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/retry.d.ts +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/retry.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/retry.js +34 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/retry.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/structural.d.ts +32 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/structural.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/structural.js +929 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/structural.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/terminal.d.ts +7 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/terminal.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/terminal.js +49 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/terminal.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tool-placement.d.ts +14 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tool-placement.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tool-placement.js +244 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tool-placement.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tools.d.ts +6 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tools.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tools.js +449 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive/tools.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive.d.ts +6 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive.js +93 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/drive.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/harness.d.ts +59 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/harness.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/harness.js +302 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/harness.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/index.d.ts +2 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/index.js +2 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/lane.d.ts +118 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/lane.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/lane.js +1559 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/lane.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/progress.d.ts +15 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/progress.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/progress.js +66 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/progress.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/reducer.d.ts +5 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/reducer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/reducer.js +240 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/reducer.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/restore.d.ts +24 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/restore.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/restore.js +117 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/restore.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/transcript.d.ts +21 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/transcript.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/transcript.js +72 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/transcript.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/types.d.ts +105 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/types.js +50 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/runtime/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/commit.d.ts +53 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/commit.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/commit.js +57 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/commit.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/context.d.ts +6 -19
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/context.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/context.js +31 -53
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/context.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork-policy.d.ts +21 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork-policy.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork-policy.js +55 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork-policy.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork.d.ts +16 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork.js +79 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/fork.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/in-memory-storage-state.d.ts +39 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/in-memory-storage-state.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/in-memory-storage-state.js +269 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/in-memory-storage-state.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/index.d.ts +9 -5
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/index.js +7 -4
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/codec.d.ts +19 -8
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/codec.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/codec.js +34 -219
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/codec.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/fork.d.ts +38 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/fork.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/fork.js +266 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/fork.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/index.d.ts +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/index.js +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/io.d.ts +14 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/io.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/io.js +86 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/io.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/legacy-v3.d.ts +44 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/legacy-v3.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/legacy-v3.js +454 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/legacy-v3.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/repo.d.ts +27 -24
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/repo.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/repo.js +276 -151
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/repo.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/storage.d.ts +39 -41
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/storage.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/storage.js +175 -196
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/storage.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/types.d.ts +23 -22
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/types.js +2 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory.d.ts +44 -40
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory.js +333 -115
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/mutation-line.d.ts +8 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/mutation-line.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/mutation-line.js +22 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/mutation-line.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.d.ts +78 -51
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.js +327 -207
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/datasets.d.ts +12 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/datasets.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/datasets.js +24 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/datasets.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/session-repo.d.ts +42 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/session-repo.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/session-repo.js +127 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/session-repo.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/storage.d.ts +25 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/storage.js +114 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/benchmark/storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/session-repo.d.ts +23 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/session-repo.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/session-repo.js +809 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/session-repo.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/storage.d.ts +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/storage.js +600 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance/storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/gating-storage.d.ts +26 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/gating-storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/gating-storage.js +103 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/gating-storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/index.d.ts +9 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/index.js +8 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/instrumented-storage.d.ts +11 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/instrumented-storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/instrumented-storage.js +19 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/instrumented-storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/storage-decorator.d.ts +20 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/storage-decorator.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/storage-decorator.js +40 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/storage-decorator.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/types.d.ts +5 -7
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/types.d.ts +425 -265
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/types.js +7 -7
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/values.d.ts +95 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/values.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/values.js +81 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/values.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.d.ts +3 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.js +29 -26
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/telemetry.d.ts +64 -43
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/telemetry.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/telemetry.js +45 -26
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/telemetry.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/bash.d.ts +4 -4
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/bash.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/bash.js +66 -93
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/bash.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/edit.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/edit.js +17 -13
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/edit.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/file-mutation-queue.d.ts +2 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/file-mutation-queue.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/file-mutation-queue.js +5 -5
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/file-mutation-queue.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/path-utils.d.ts +3 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/path-utils.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/path-utils.js +5 -5
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/path-utils.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/read.d.ts +2 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/read.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/read.js +4 -6
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/read.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/write.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/write.js +12 -8
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/tools/write.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.d.ts +128 -45
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/adaptive-publisher.d.ts +24 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/adaptive-publisher.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/adaptive-publisher.js +79 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/adaptive-publisher.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/output-capture.d.ts +31 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/output-capture.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/output-capture.js +217 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/output-capture.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.d.ts +19 -5
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.js +65 -192
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.d.ts +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.js +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/usage.d.ts +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/usage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/usage.js +33 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/usage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/index.d.ts +4 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/index.js +3 -6
- package/node_modules/@earendil-works/pi-agent-core/dist/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/search/index.d.ts +24 -16
- package/node_modules/@earendil-works/pi-agent-core/dist/search/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/search/index.js +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/search/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/types.d.ts +2 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-agent-core/package.json +27 -6
- package/node_modules/@earendil-works/pi-ai/README.md +39 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/anthropic-messages.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/anthropic-messages.js +8 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/anthropic-messages.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-ai-binding.d.ts +77 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-ai-binding.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-ai-binding.js +72 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-ai-binding.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent/measure.d.ts +11 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent/measure.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent/measure.js +18 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent/measure.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent.d.ts +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent.js +5 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cursor-agent.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/discovery.d.ts +2 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/discovery.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/discovery.js +96 -51
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/discovery.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/gen/cascade_pb.d.ts +389 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/gen/cascade_pb.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/gen/cascade_pb.js +132 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/gen/cascade_pb.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/metadata.d.ts +34 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/metadata.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/metadata.js +41 -8
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/metadata.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/paths.d.ts +20 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/paths.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/paths.js +20 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/paths.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/request.d.ts +18 -6
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/request.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/request.js +77 -35
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/request.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/stream-state.d.ts +9 -3
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/stream-state.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/stream-state.js +30 -38
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/stream-state.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/trailer.d.ts +16 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/trailer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/trailer.js +69 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/trailer.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/unary.d.ts +26 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/unary.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/unary.js +61 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/unary.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/wire.d.ts +6 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/wire.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/wire.js +6 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent/wire.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent.d.ts +13 -5
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent.js +76 -21
- package/node_modules/@earendil-works/pi-ai/dist/api/devin-agent.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/mistral-conversations.js +4 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/mistral-conversations.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-codex-responses.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-codex-responses.js +6 -3
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-codex-responses.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses-shared.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses-shared.js +4 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses-shared.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses.js +13 -3
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/devin.d.ts +5 -0
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/devin.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/devin.js +7 -2
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/devin.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/cursor/context-limit-store.d.ts +32 -0
- package/node_modules/@earendil-works/pi-ai/dist/cursor/context-limit-store.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/cursor/context-limit-store.js +62 -0
- package/node_modules/@earendil-works/pi-ai/dist/cursor/context-limit-store.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/cursor/store-migration.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/cursor/store-migration.js +2 -1
- package/node_modules/@earendil-works/pi-ai/dist/cursor/store-migration.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/index.d.ts +2 -1
- package/node_modules/@earendil-works/pi-ai/dist/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/index.js +2 -1
- package/node_modules/@earendil-works/pi-ai/dist/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/model.d.ts +11 -1
- package/node_modules/@earendil-works/pi-ai/dist/model.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/model.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/models.d.ts +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/models.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/models.js +5 -2
- package/node_modules/@earendil-works/pi-ai/dist/models.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/openai-responses-compat.d.ts +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/openai-responses-compat.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/openai-responses-compat.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-ai-gateway.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-ai-gateway.js +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-ai-gateway.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/cursor.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/cursor.js +2 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/cursor.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/.manifest.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/amazon-bedrock.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/azure-openai-responses.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/baseten.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/deepseek.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/fireworks.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/github-copilot.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/openai-codex.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/openrouter.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan-individual.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/venice.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/vercel-ai-gateway.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.js +3 -3
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.models.d.ts +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.models.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.models.js +18 -9
- package/node_modules/@earendil-works/pi-ai/dist/providers/devin.models.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/faux.js +5 -5
- package/node_modules/@earendil-works/pi-ai/dist/providers/faux.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-go.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-go.js +4 -3
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-go.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-headers.d.ts +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-headers.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-headers.js +22 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-headers.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.js +5 -4
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/types.d.ts +16 -6
- package/node_modules/@earendil-works/pi-ai/dist/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/assistant-message-frame.d.ts +77 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/assistant-message-frame.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/assistant-message-frame.js +427 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/assistant-message-frame.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/cursor-context-limit.d.ts +12 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/cursor-context-limit.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/cursor-context-limit.js +93 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/cursor-context-limit.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/event-stream.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/event-stream.js +25 -5
- package/node_modules/@earendil-works/pi-ai/dist/utils/event-stream.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/prompt-cache-ttl.d.ts +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/prompt-cache-ttl.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/prompt-cache-ttl.js +5 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/prompt-cache-ttl.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry-profile/types.d.ts +10 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry-profile/types.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry-profile/types.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry.d.ts +13 -2
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry.js +18 -7
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/uuid.d.ts +2 -2
- package/node_modules/@earendil-works/pi-ai/dist/utils/uuid.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/utils/uuid.js +36 -31
- package/node_modules/@earendil-works/pi-ai/dist/utils/uuid.js.map +1 -1
- package/node_modules/@earendil-works/pi-ai/package.json +6 -6
- package/node_modules/@earendil-works/pi-pty/package.json +1 -1
- package/node_modules/@earendil-works/pi-telemetry/package.json +1 -1
- package/node_modules/@earendil-works/pi-tui/README.md +53 -4
- package/node_modules/@earendil-works/pi-tui/dist/alt-screen-search.d.ts +21 -1
- package/node_modules/@earendil-works/pi-tui/dist/alt-screen-search.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/alt-screen-search.js +199 -42
- package/node_modules/@earendil-works/pi-tui/dist/alt-screen-search.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/box.d.ts +3 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/box.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/box.js +28 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/box.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.d.ts +6 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.js +98 -18
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/input.d.ts +12 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/input.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/input.js +40 -6
- package/node_modules/@earendil-works/pi-tui/dist/components/input.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/latex.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/latex.js +7 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/latex.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.d.ts +3 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.js +20 -8
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/mouse-region.d.ts +12 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/mouse-region.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/mouse-region.js +19 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/mouse-region.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/scroll-view.d.ts +6 -3
- package/node_modules/@earendil-works/pi-tui/dist/components/scroll-view.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/scroll-view.js +6 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/scroll-view.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.d.ts +4 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.js +48 -2
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.d.ts +5 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.js +54 -5
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/index.d.ts +3 -1
- package/node_modules/@earendil-works/pi-tui/dist/index.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/index.js +3 -0
- package/node_modules/@earendil-works/pi-tui/dist/index.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/layout.d.ts +3 -1
- package/node_modules/@earendil-works/pi-tui/dist/layout.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/layout.js +32 -9
- package/node_modules/@earendil-works/pi-tui/dist/layout.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.d.ts +2 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.js +3 -44
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-platform.d.ts +18 -0
- package/node_modules/@earendil-works/pi-tui/dist/native-platform.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/native-platform.js +42 -0
- package/node_modules/@earendil-works/pi-tui/dist/native-platform.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/terminal.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/terminal.js +2 -20
- package/node_modules/@earendil-works/pi-tui/dist/terminal.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui-alt-screen.d.ts +31 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui-alt-screen.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui-alt-screen.js +335 -41
- package/node_modules/@earendil-works/pi-tui/dist/tui-alt-screen.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui.d.ts +83 -5
- package/node_modules/@earendil-works/pi-tui/dist/tui.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui.js +118 -4
- package/node_modules/@earendil-works/pi-tui/dist/tui.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/utils.d.ts +2 -0
- package/node_modules/@earendil-works/pi-tui/dist/utils.d.ts.map +1 -1
- package/node_modules/@earendil-works/pi-tui/dist/utils.js +9 -0
- package/node_modules/@earendil-works/pi-tui/dist/utils.js.map +1 -1
- package/node_modules/@earendil-works/pi-tui/native/clipboard.h +170 -0
- package/node_modules/@earendil-works/pi-tui/native/darwin/README.md +8 -6
- package/node_modules/@earendil-works/pi-tui/native/darwin/build.sh +12 -5
- package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-arm64/{darwin-modifiers.node → darwin-platform.node} +0 -0
- package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-x64/{darwin-modifiers.node → darwin-platform.node} +0 -0
- package/node_modules/@earendil-works/pi-tui/native/darwin/src/darwin-platform.m +93 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/README.md +23 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/build.sh +65 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/prebuilds/linux-arm64/linux-platform-x11.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/prebuilds/linux-x64/linux-platform-x11.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/src/clipboard-worker.h +70 -0
- package/node_modules/@earendil-works/pi-tui/native/linux/src/linux-platform-x11.c +274 -0
- package/node_modules/@earendil-works/pi-tui/native/napi.h +89 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/README.md +18 -7
- package/node_modules/@earendil-works/pi-tui/native/win32/build.mjs +7 -4
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-arm64/win32-platform.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-x64/win32-platform.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/src/win32-platform.c +241 -0
- package/node_modules/@earendil-works/pi-tui/package.json +10 -3
- package/node_modules/@google/genai/dist/genai.d.ts +1799 -289
- package/node_modules/@google/genai/dist/index.cjs +319 -299
- package/node_modules/@google/genai/dist/index.mjs +319 -299
- package/node_modules/@google/genai/dist/index.mjs.map +1 -1
- package/node_modules/@google/genai/dist/node/index.cjs +320 -300
- package/node_modules/@google/genai/dist/node/index.mjs +320 -300
- package/node_modules/@google/genai/dist/node/index.mjs.map +1 -1
- package/node_modules/@google/genai/dist/node/node.d.ts +1799 -289
- package/node_modules/@google/genai/dist/tokenizer/node.cjs +49 -2
- package/node_modules/@google/genai/dist/tokenizer/node.d.ts +43 -3
- package/node_modules/@google/genai/dist/tokenizer/node.mjs +49 -2
- package/node_modules/@google/genai/dist/tokenizer/node.mjs.map +1 -1
- package/node_modules/@google/genai/dist/vertex_internal/index.cjs +39 -3
- package/node_modules/@google/genai/dist/vertex_internal/index.cjs.map +1 -1
- package/node_modules/@google/genai/dist/vertex_internal/index.d.ts +51 -9
- package/node_modules/@google/genai/dist/vertex_internal/index.js +39 -3
- package/node_modules/@google/genai/dist/vertex_internal/index.js.map +1 -1
- package/node_modules/@google/genai/dist/web/index.mjs +319 -299
- package/node_modules/@google/genai/dist/web/index.mjs.map +1 -1
- package/node_modules/@google/genai/dist/web/web.d.ts +1799 -289
- package/node_modules/@google/genai/package.json +1 -1
- package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +11 -4
- package/node_modules/@smithy/node-http-handler/dist-es/http2/ClientHttp2SessionRef.js +1 -0
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-connection-manager.js +2 -3
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-handler.js +8 -1
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/LICENSE +201 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/README.md +115 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-cjs/index.js +96 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/abort-handler.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/abort.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/HttpApiKeyAuth.js +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/HttpAuthScheme.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/HttpAuthSchemeProvider.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/HttpSigner.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/IdentityProviderConfig.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/auth.js +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/auth/index.js +2 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/blob/blob-payload-input-types.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/checksum.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/client.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/command.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/connection/config.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/connection/index.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/connection/manager.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/connection/pool.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/crypto.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/downlevel-ts3.4/transform/type-transform.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/encode.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoint.js +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/EndpointParameterInstructions.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/EndpointRuleObject.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/ErrorRuleObject.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/RuleSetObject.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/TreeRuleObject.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/index.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/endpoints/shared.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/eventStream.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/extensions/checksum.js +38 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/extensions/defaultClientConfiguration.js +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/extensions/defaultExtensionConfiguration.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/extensions/index.js +2 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/extensions/retry.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/externals-check/browser-externals-check.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/feature-ids.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/http/httpHandlerInitialization.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/http.js +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/identity/apiKeyIdentity.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/identity/awsCredentialIdentity.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/identity/identity.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/identity/index.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/identity/tokenIdentity.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/index.js +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/logger.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/metrics.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/middleware.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/pagination.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/profile.js +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/response.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/retry.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/schema/schema-deprecated.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/schema/schema.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/schema/sentinels.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/schema/static-schemas.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/schema/traits.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/serde.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/shapes.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/signature.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/stream.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/streaming-payload/streaming-blob-common-types.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/streaming-payload/streaming-blob-payload-input-types.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/streaming-payload/streaming-blob-payload-output-types.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transfer.js +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/client-method-transforms.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/client-payload-blob-type-narrow.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/exact.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/mutable.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/no-undefined.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/transform/type-transform.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/uri.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/util.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-es/waiter.js +1 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/abort-handler.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/abort.d.ts +48 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/HttpApiKeyAuth.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/HttpAuthScheme.d.ts +49 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/HttpAuthSchemeProvider.d.ts +20 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/HttpSigner.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/IdentityProviderConfig.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/auth.d.ts +59 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/auth/index.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/blob/blob-payload-input-types.d.ts +37 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/checksum.d.ts +61 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/client.d.ts +57 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/command.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/connection/config.d.ts +15 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/connection/index.d.ts +3 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/connection/manager.d.ts +34 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/connection/pool.d.ts +32 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/crypto.d.ts +58 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/downlevel-ts3.4/transform/type-transform.d.ts +24 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/encode.d.ts +31 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoint.d.ts +77 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/EndpointParameterInstructions.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/EndpointRuleObject.d.ts +27 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/ErrorRuleObject.d.ts +10 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/RuleSetObject.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/TreeRuleObject.d.ts +16 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/index.d.ts +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/endpoints/shared.d.ts +55 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/eventStream.d.ts +137 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/extensions/checksum.d.ts +58 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/extensions/defaultClientConfiguration.d.ts +32 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/extensions/defaultExtensionConfiguration.d.ts +9 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/extensions/index.d.ts +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/extensions/retry.d.ts +18 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/externals-check/browser-externals-check.d.ts +35 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/feature-ids.d.ts +16 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/http/httpHandlerInitialization.d.ts +142 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/http.d.ts +110 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/identity/apiKeyIdentity.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/identity/awsCredentialIdentity.d.ts +31 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/identity/identity.d.ts +15 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/identity/index.d.ts +4 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/identity/tokenIdentity.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/index.d.ts +52 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/logger.d.ts +13 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/metrics.d.ts +93 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/middleware.d.ts +541 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/pagination.d.ts +33 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/profile.d.ts +30 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/response.d.ts +40 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/retry.d.ts +162 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/schema/schema-deprecated.d.ts +143 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/schema/schema.d.ts +236 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/schema/sentinels.d.ts +65 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/schema/static-schemas.d.ts +99 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/schema/traits.d.ts +46 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/serde.d.ts +114 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/shapes.d.ts +79 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/signature.d.ts +172 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/stream.d.ts +22 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/streaming-payload/streaming-blob-common-types.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/streaming-payload/streaming-blob-payload-input-types.d.ts +54 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/streaming-payload/streaming-blob-payload-output-types.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transfer.d.ts +42 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/client-method-transforms.d.ts +26 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/client-payload-blob-type-narrow.d.ts +73 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/exact.d.ts +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/mutable.d.ts +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/no-undefined.d.ts +68 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/transform/type-transform.d.ts +39 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/abort-handler.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/abort.d.ts +45 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/HttpApiKeyAuth.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/HttpAuthScheme.d.ts +49 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/HttpAuthSchemeProvider.d.ts +20 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/HttpSigner.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/IdentityProviderConfig.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/auth.d.ts +59 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/auth/index.d.ts +7 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/blob/blob-payload-input-types.d.ts +37 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/checksum.d.ts +61 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/client.d.ts +57 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/command.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/connection/config.d.ts +15 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/connection/index.d.ts +3 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/connection/manager.d.ts +34 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/connection/pool.d.ts +32 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/crypto.d.ts +58 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/downlevel-ts3.4/transform/type-transform.d.ts +40 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/encode.d.ts +31 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoint.d.ts +77 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/EndpointParameterInstructions.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/EndpointRuleObject.d.ts +27 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/ErrorRuleObject.d.ts +10 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/RuleSetObject.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/TreeRuleObject.d.ts +16 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/index.d.ts +5 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/endpoints/shared.d.ts +55 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/eventStream.d.ts +137 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/extensions/checksum.d.ts +58 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/extensions/defaultClientConfiguration.d.ts +32 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/extensions/defaultExtensionConfiguration.d.ts +9 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/extensions/index.d.ts +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/extensions/retry.d.ts +18 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/externals-check/browser-externals-check.d.ts +35 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/feature-ids.d.ts +16 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/http/httpHandlerInitialization.d.ts +142 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/http.d.ts +110 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/identity/apiKeyIdentity.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/identity/awsCredentialIdentity.d.ts +31 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/identity/identity.d.ts +15 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/identity/index.d.ts +4 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/identity/tokenIdentity.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/index.d.ts +52 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/logger.d.ts +13 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/metrics.d.ts +93 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/middleware.d.ts +541 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/pagination.d.ts +33 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/profile.d.ts +30 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/response.d.ts +40 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/retry.d.ts +162 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/schema/schema-deprecated.d.ts +149 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/schema/schema.d.ts +251 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/schema/sentinels.d.ts +65 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/schema/static-schemas.d.ts +118 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/schema/traits.d.ts +46 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/serde.d.ts +114 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/shapes.d.ts +79 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/signature.d.ts +172 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/stream.d.ts +22 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/streaming-payload/streaming-blob-common-types.d.ts +28 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/streaming-payload/streaming-blob-payload-input-types.d.ts +54 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/streaming-payload/streaming-blob-payload-output-types.d.ts +41 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transfer.d.ts +42 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/client-method-transforms.d.ts +26 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/client-payload-blob-type-narrow.d.ts +77 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/exact.d.ts +14 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/mutable.d.ts +6 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/no-undefined.d.ts +88 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/transform/type-transform.d.ts +40 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/uri.d.ts +17 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/util.d.ts +192 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/ts3.4/waiter.d.ts +35 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/uri.d.ts +17 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/util.d.ts +176 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/dist-types/waiter.d.ts +35 -0
- package/node_modules/@smithy/node-http-handler/node_modules/@smithy/types/package.json +50 -0
- package/node_modules/@smithy/node-http-handler/package.json +2 -2
- package/node_modules/esbuild/LICENSE.md +21 -0
- package/node_modules/esbuild/README.md +3 -0
- package/node_modules/esbuild/bin/esbuild +223 -0
- package/node_modules/esbuild/install.js +300 -0
- package/node_modules/esbuild/lib/main.d.ts +720 -0
- package/node_modules/esbuild/lib/main.js +2536 -0
- package/node_modules/esbuild/package.json +47 -0
- package/node_modules/ignore/README.md +52 -0
- package/node_modules/ignore/index.js +785 -129
- package/node_modules/ignore/legacy.js +660 -98
- package/node_modules/ignore/package.json +10 -4
- package/node_modules/marked/README.md +1 -0
- package/node_modules/marked/lib/marked.d.ts +7 -0
- package/node_modules/marked/lib/marked.esm.js +30 -30
- package/node_modules/marked/lib/marked.esm.js.map +3 -3
- package/node_modules/marked/lib/marked.umd.js +30 -30
- package/node_modules/marked/lib/marked.umd.js.map +3 -3
- package/node_modules/marked/man/marked.1 +1 -1
- package/node_modules/marked/package.json +2 -2
- package/node_modules/typebox/build/compile/validator.d.mts +1 -1
- package/node_modules/typebox/build/compile/validator.mjs +1 -1
- package/node_modules/typebox/build/format/idna/idn-hostname.mjs +7 -5
- package/node_modules/typebox/build/format/iri.mjs +5 -1
- package/node_modules/typebox/build/guard/emit.mjs +2 -4
- package/node_modules/typebox/build/guard/guard.mjs +6 -18
- package/node_modules/typebox/build/guard/string.mjs +16 -24
- package/node_modules/typebox/build/schema/compile.d.mts +3 -2
- package/node_modules/typebox/build/schema/compile.mjs +8 -8
- package/node_modules/typebox/build/schema/engine/_context.d.mts +1 -6
- package/node_modules/typebox/build/schema/engine/_context.mjs +9 -14
- package/node_modules/typebox/build/schema/engine/_functions.mjs +1 -1
- package/node_modules/typebox/build/schema/engine/_stack.d.mts +6 -2
- package/node_modules/typebox/build/schema/engine/_stack.mjs +135 -32
- package/node_modules/typebox/build/schema/engine/additionalProperties.mjs +16 -4
- package/node_modules/typebox/build/schema/engine/allOf.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/anyOf.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/if.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/oneOf.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/propertyNames.mjs +1 -3
- package/node_modules/typebox/build/schema/engine/ref.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/schema.mjs +6 -0
- package/node_modules/typebox/build/schema/engine/unevaluatedItems.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/unevaluatedProperties.mjs +2 -2
- package/node_modules/typebox/build/schema/errors.d.mts +2 -2
- package/node_modules/typebox/build/schema/errors.mjs +7 -13
- package/node_modules/typebox/build/schema/intern/index.d.mts +1 -0
- package/node_modules/typebox/build/schema/intern/index.mjs +1 -0
- package/node_modules/typebox/build/schema/intern/intern.d.mts +14 -0
- package/node_modules/typebox/build/schema/intern/intern.mjs +259 -0
- package/node_modules/typebox/build/schema/parse.d.mts +1 -0
- package/node_modules/typebox/build/schema/parse.mjs +10 -5
- package/node_modules/typebox/build/schema/resolve/resolve.d.mts +34 -3
- package/node_modules/typebox/build/schema/resolve/resolve.mjs +198 -73
- package/node_modules/typebox/build/schema/schema.d.mts +1 -0
- package/node_modules/typebox/build/schema/schema.mjs +1 -0
- package/node_modules/typebox/build/value/errors/errors.d.mts +2 -12
- package/node_modules/typebox/build/value/errors/errors.mjs +2 -7
- package/node_modules/typebox/package.json +1 -1
- package/node_modules/typebox/readme.md +9 -5
- package/node_modules/undici/docs/docs/api/Client.md +4 -0
- package/node_modules/undici/docs/docs/api/EnvHttpProxyAgent.md +3 -2
- package/node_modules/undici/docs/docs/api/EventSource.md +4 -0
- package/node_modules/undici/docs/docs/api/Interceptors.md +7 -3
- package/node_modules/undici/docs/docs/api/Socks5ProxyAgent.md +7 -1
- package/node_modules/undici/lib/cache/memory-cache-store.js +2 -2
- package/node_modules/undici/lib/core/symbols.js +2 -0
- package/node_modules/undici/lib/dispatcher/agent.js +7 -2
- package/node_modules/undici/lib/dispatcher/balanced-pool.js +7 -4
- package/node_modules/undici/lib/dispatcher/client-h1.js +12 -4
- package/node_modules/undici/lib/dispatcher/client-h2.js +43 -3
- package/node_modules/undici/lib/dispatcher/client.js +3 -2
- package/node_modules/undici/lib/dispatcher/dispatcher-base.js +13 -1
- package/node_modules/undici/lib/dispatcher/dispatcher.js +15 -1
- package/node_modules/undici/lib/dispatcher/dispatcher1-wrapper.js +3 -0
- package/node_modules/undici/lib/dispatcher/env-http-proxy-agent.js +10 -3
- package/node_modules/undici/lib/dispatcher/proxy-agent.js +18 -1
- package/node_modules/undici/lib/dispatcher/retry-agent.js +3 -0
- package/node_modules/undici/lib/dispatcher/round-robin-pool.js +1 -1
- package/node_modules/undici/lib/dispatcher/socks5-proxy-agent.js +91 -21
- package/node_modules/undici/lib/handler/cache-handler.js +29 -5
- package/node_modules/undici/lib/handler/decorator-handler.js +7 -1
- package/node_modules/undici/lib/handler/deduplication-handler.js +12 -6
- package/node_modules/undici/lib/handler/redirect-handler.js +21 -4
- package/node_modules/undici/lib/handler/retry-handler.js +148 -30
- package/node_modules/undici/lib/interceptor/cache.js +65 -12
- package/node_modules/undici/lib/interceptor/decompress.js +115 -13
- package/node_modules/undici/lib/interceptor/deduplicate.js +5 -4
- package/node_modules/undici/lib/interceptor/dns.js +7 -0
- package/node_modules/undici/lib/interceptor/dump.js +10 -23
- package/node_modules/undici/lib/mock/mock-agent.js +13 -1
- package/node_modules/undici/lib/mock/mock-utils.js +11 -10
- package/node_modules/undici/lib/util/cache.js +45 -3
- package/node_modules/undici/lib/web/cookies/parse.js +150 -147
- package/node_modules/undici/lib/web/eventsource/eventsource-stream.js +28 -1
- package/node_modules/undici/lib/web/eventsource/eventsource.js +13 -3
- package/node_modules/undici/lib/web/fetch/index.js +6 -0
- package/node_modules/undici/lib/web/fetch/request.js +2 -3
- package/node_modules/undici/lib/web/fetch/util.js +6 -1
- package/node_modules/undici/lib/web/webidl/index.js +3 -3
- package/node_modules/undici/lib/web/websocket/connection.js +1 -1
- package/node_modules/undici/lib/web/websocket/permessage-deflate.js +5 -0
- package/node_modules/undici/lib/web/websocket/stream/websocketstream.js +8 -10
- package/node_modules/undici/package.json +3 -3
- package/node_modules/undici/types/client.d.ts +10 -0
- package/node_modules/undici/types/interceptors.d.ts +2 -0
- package/node_modules/undici/types/mock-agent.d.ts +11 -10
- package/node_modules/undici/types/socks5-proxy-agent.d.ts +2 -0
- package/package.json +70 -49
- package/vendor/pi-client/client.d.ts +20 -15
- package/vendor/pi-client/client.d.ts.map +1 -1
- package/vendor/pi-client/client.js +248 -245
- package/vendor/pi-client/client.js.map +1 -1
- package/vendor/pi-client/connection.d.ts +4 -3
- package/vendor/pi-client/connection.d.ts.map +1 -1
- package/vendor/pi-client/connection.js +13 -9
- package/vendor/pi-client/connection.js.map +1 -1
- package/vendor/pi-client/errors.d.ts +6 -15
- package/vendor/pi-client/errors.d.ts.map +1 -1
- package/vendor/pi-client/errors.js +10 -25
- package/vendor/pi-client/errors.js.map +1 -1
- package/vendor/pi-client/index.d.ts +3 -4
- package/vendor/pi-client/index.d.ts.map +1 -1
- package/vendor/pi-client/index.js +2 -2
- package/vendor/pi-client/index.js.map +1 -1
- package/vendor/pi-client/types.d.ts +14 -8
- package/vendor/pi-client/types.d.ts.map +1 -1
- package/vendor/pi-client/types.js.map +1 -1
- package/vendor/pi-client/unix.d.ts +14 -1
- package/vendor/pi-client/unix.d.ts.map +1 -1
- package/vendor/pi-client/unix.js +138 -8
- package/vendor/pi-client/unix.js.map +1 -1
- package/vendor/pi-protocol/codec.d.ts +2 -4
- package/vendor/pi-protocol/codec.d.ts.map +1 -1
- package/vendor/pi-protocol/codec.js +7 -34
- package/vendor/pi-protocol/codec.js.map +1 -1
- package/vendor/pi-protocol/framing.d.ts +0 -2
- package/vendor/pi-protocol/framing.d.ts.map +1 -1
- package/vendor/pi-protocol/framing.js +0 -15
- package/vendor/pi-protocol/framing.js.map +1 -1
- package/vendor/pi-protocol/index.d.ts +1 -1
- package/vendor/pi-protocol/index.d.ts.map +1 -1
- package/vendor/pi-protocol/index.js +1 -1
- package/vendor/pi-protocol/index.js.map +1 -1
- package/vendor/pi-protocol/protocol.d.ts +167 -0
- package/vendor/pi-protocol/protocol.d.ts.map +1 -0
- package/vendor/pi-protocol/protocol.js +85 -0
- package/vendor/pi-protocol/protocol.js.map +1 -0
- package/dist/bun/register-bedrock.d.ts +0 -2
- package/dist/bun/register-bedrock.d.ts.map +0 -1
- package/dist/bun/register-bedrock.js +0 -4
- package/dist/bun/register-bedrock.js.map +0 -1
- package/dist/cli/experimental/auth.d.ts +0 -16
- package/dist/cli/experimental/auth.d.ts.map +0 -1
- package/dist/cli/experimental/auth.js +0 -13
- package/dist/cli/experimental/auth.js.map +0 -1
- package/dist/cli/experimental/cli.d.ts +0 -6
- package/dist/cli/experimental/cli.d.ts.map +0 -1
- package/dist/cli/experimental/cli.js +0 -5
- package/dist/cli/experimental/cli.js.map +0 -1
- package/dist/cli/experimental/command-options.d.ts +0 -17
- package/dist/cli/experimental/command-options.d.ts.map +0 -1
- package/dist/cli/experimental/command-options.js +0 -35
- package/dist/cli/experimental/command-options.js.map +0 -1
- package/dist/cli/experimental/command.d.ts +0 -63
- package/dist/cli/experimental/command.d.ts.map +0 -1
- package/dist/cli/experimental/command.js +0 -127
- package/dist/cli/experimental/command.js.map +0 -1
- package/dist/cli/experimental/commands/client.d.ts +0 -13
- package/dist/cli/experimental/commands/client.d.ts.map +0 -1
- package/dist/cli/experimental/commands/client.js +0 -25
- package/dist/cli/experimental/commands/client.js.map +0 -1
- package/dist/cli/experimental/commands/pi.d.ts +0 -15
- package/dist/cli/experimental/commands/pi.d.ts.map +0 -1
- package/dist/cli/experimental/commands/pi.js +0 -28
- package/dist/cli/experimental/commands/pi.js.map +0 -1
- package/dist/cli/experimental/commands/server.d.ts +0 -13
- package/dist/cli/experimental/commands/server.d.ts.map +0 -1
- package/dist/cli/experimental/commands/server.js +0 -25
- package/dist/cli/experimental/commands/server.js.map +0 -1
- package/dist/cli/experimental/transport-address.d.ts +0 -10
- package/dist/cli/experimental/transport-address.d.ts.map +0 -1
- package/dist/cli/experimental/transport-address.js +0 -38
- package/dist/cli/experimental/transport-address.js.map +0 -1
- package/dist/client/remote-session.d.ts +0 -53
- package/dist/client/remote-session.d.ts.map +0 -1
- package/dist/client/remote-session.js +0 -340
- package/dist/client/remote-session.js.map +0 -1
- package/dist/client/transcript.d.ts +0 -12
- package/dist/client/transcript.d.ts.map +0 -1
- package/dist/client/transcript.js +0 -98
- package/dist/client/transcript.js.map +0 -1
- package/dist/server/create-harness.d.ts +0 -26
- package/dist/server/create-harness.d.ts.map +0 -1
- package/dist/server/create-harness.js +0 -106
- package/dist/server/create-harness.js.map +0 -1
- package/dist/utils/clipboard-native.d.ts +0 -11
- package/dist/utils/clipboard-native.d.ts.map +0 -1
- package/dist/utils/clipboard-native.js +0 -20
- package/dist/utils/clipboard-native.js.map +0 -1
- package/docs/AGENTS.md +0 -67
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/reducer.d.ts +0 -100
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/reducer.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/reducer.js +0 -420
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/reducer.js.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/errors.d.ts +0 -9
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/errors.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/errors.js +0 -18
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl/errors.js.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl.d.ts +0 -3
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl.js +0 -2
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl.js.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/state.d.ts +0 -65
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/state.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/state.js +0 -320
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/state.js.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance.d.ts +0 -4
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance.js +0 -762
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/testing/conformance.js.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/search/scanning.d.ts +0 -29
- package/node_modules/@earendil-works/pi-agent-core/dist/search/scanning.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-agent-core/dist/search/scanning.js +0 -103
- package/node_modules/@earendil-works/pi-agent-core/dist/search/scanning.js.map +0 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-gateway-binding.d.ts +0 -69
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-gateway-binding.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-gateway-binding.js +0 -159
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-gateway-binding.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/native/darwin/src/darwin-modifiers.c +0 -70
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-arm64/win32-console-mode.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-x64/win32-console-mode.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/src/win32-console-mode.c +0 -119
- package/node_modules/@mariozechner/clipboard/.yarnrc.yml +0 -1
- package/node_modules/@mariozechner/clipboard/Cargo.toml +0 -45
- package/node_modules/@mariozechner/clipboard/README.md +0 -60
- package/node_modules/@mariozechner/clipboard/build.rs +0 -5
- package/node_modules/@mariozechner/clipboard/exp.ts +0 -12
- package/node_modules/@mariozechner/clipboard/index.d.ts +0 -37
- package/node_modules/@mariozechner/clipboard/index.js +0 -606
- package/node_modules/@mariozechner/clipboard/package.json +0 -45
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/common.rs +0 -307
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/mod.rs +0 -93
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/ios.rs +0 -313
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/macos.rs +0 -471
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/mod.rs +0 -252
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/wayland.rs +0 -431
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/win.rs +0 -712
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/x11.rs +0 -916
- package/node_modules/@mariozechner/clipboard/src/lib.rs +0 -194
- package/vendor/pi-client/session-handle.d.ts +0 -54
- package/vendor/pi-client/session-handle.d.ts.map +0 -1
- package/vendor/pi-client/session-handle.js +0 -50
- package/vendor/pi-client/session-handle.js.map +0 -1
- package/vendor/pi-client/state.d.ts +0 -22
- package/vendor/pi-client/state.d.ts.map +0 -1
- package/vendor/pi-client/state.js +0 -145
- package/vendor/pi-client/state.js.map +0 -1
- package/vendor/pi-protocol/schemas.d.ts +0 -13739
- package/vendor/pi-protocol/schemas.d.ts.map +0 -1
- package/vendor/pi-protocol/schemas.js +0 -386
- package/vendor/pi-protocol/schemas.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"turn-adapter.js","sourceRoot":"","sources":["../../../src/modes/app-server/turn-adapter.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,oCAAoC,EAAE,MAAM,uBAAuB,CAAC;AAM7E,OAAO,EAAE,UAAU,EAA0B,MAAM,yBAAyB,CAAC;AAE7E,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAEtH,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAK5D,MAAM,UAAU,mBAAmB,CAAC,OAAuB;IAC1D,OAAO,IAAI,aAAa,CAAC,OAAO,CAAC,CAAC;AACnC,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,OAAmB;IAClD,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;IACrC,OAAO;QACN,QAAQ,EAAE,mBAAmB,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC;QAC1D,mBAAmB,EAAE,2BAA2B,CAAC,MAAM,CAAC,mBAAmB,EAAE,qBAAqB,CAAC;QACnG,KAAK,EAAE,mBAAmB,CAAC,MAAM,CAAC,KAAK,CAAC;KACxC,CAAC;AACH,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,OAAmB;IAClD,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;IACrC,OAAO;QACN,QAAQ,EAAE,mBAAmB,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC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CAAC,KAAK,CAAC,CAAC,CAAC;IACvD,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC;IACvB,QAAQ,IAAI,EAAE,CAAC;QACd,KAAK,MAAM;YACV,OAAO;gBACN,IAAI;gBACJ,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC;gBAClD,aAAa,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE;aAC1E,CAAC;QACH,KAAK,OAAO;YACX,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,mBAAmB,CAAC,IAAI,CAAC,GAAG,EAAE,WAAW,CAAC,EAAE,CAAC;QAClE,KAAK,YAAY;YAChB,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,EAAE,CAAC;QACrE,KAAK,OAAO,CAAC;QACb,KAAK,SAAS;YACb,OAAO;gBACN,IAAI;gBACJ,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC;gBAClD,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC;aAClD,CAAC;QACH;YACC,MAAM,IAAI,eAAe,CAAC,EAAE,IAAI,EAAE,CAAC,KAAK,EAAE,OAAO,EAAE,6CAA6C,EAAE,CAAC,CAAC;IACtG,CAAC;AACF,CAAC;AAED,SAAS,eAAe,CAAC,SAAwB;IAChD,QAAQ,SAAS,EAAE,CAAC;QACnB,KAAK,OAAO;YACX,OAAO,OAAO,CAAC;QAChB,KAAK,WAAW;YACf,OAAO,IAAI,CAAC;QACb,KAAK,MAAM;YACV,OAAO,MAAM,CAAC;IAChB,CAAC;AACF,CAAC","sourcesContent":["import type { AgentSession } from \"../../core/agent-session.ts\";\nimport type { TurnInterruptParams, TurnStartParams, TurnSteerParams, UserInput } from \"./protocol/index.ts\";\nimport { ADDITIVE_CLIENT_NOTIFICATION_METHODS } from \"./protocol/methods.ts\";\nimport type { ClassifiedIncoming, RpcResponse } from \"./rpc/envelope.ts\";\nimport type { MethodRegistry, RpcRequest } from \"./rpc/registry.ts\";\nimport type { ApprovalBridge } from \"./server/approvals.ts\";\nimport type { Connection, ConnectionId, ConnectionInput, TransportKind } from \"./server/connection.ts\";\nimport type { ConnectionTransport, NotificationRouter } from \"./server/notifications.ts\";\nimport { ServerCore, type ServerCoreOptions } from \"./server/server-core.ts\";\nimport type { UserInputBridge } from \"./server/user-input-bridge.ts\";\nimport { UserInputProtocolError } from \"./server/user-input-types.ts\";\nimport { decodeCursor, encodeCursor, objectValue, optionalNumber, optionalString } from \"./threads/handler-params.ts\";\nimport type { ThreadEntry, ThreadRegistry } from \"./threads/registry.ts\";\nimport { TurnEngineError } from \"./threads/turn-runtime.ts\";\nimport type { TurnEngineSession, TurnEngineStore, TurnEngineThreadEntry } from \"./threads/turns.ts\";\n\ntype ModeTurnEntry = TurnEngineThreadEntry;\n\nexport function createModeTurnStore(threads: ThreadRegistry): TurnEngineStore<ModeTurnEntry> {\n\treturn new ModeTurnStore(threads);\n}\n\nexport function turnStartParams(request: RpcRequest): TurnStartParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\tclientUserMessageId: optionalNullableStringParam(params.clientUserMessageId, \"clientUserMessageId\"),\n\t\tinput: userInputArrayParam(params.input),\n\t};\n}\n\nexport function turnSteerParams(request: RpcRequest): TurnSteerParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\texpectedTurnId: requiredStringParam(params.expectedTurnId, \"expectedTurnId\"),\n\t\tclientUserMessageId: optionalNullableStringParam(params.clientUserMessageId, \"clientUserMessageId\"),\n\t\tinput: userInputArrayParam(params.input),\n\t};\n}\n\nexport function turnInterruptParams(request: RpcRequest): TurnInterruptParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\tturnId: requiredStringParam(params.turnId, \"turnId\"),\n\t};\n}\n\nexport function createRoutedServerCore(\n\tregistry: MethodRegistry,\n\tnotifications: NotificationRouter,\n\tapprovals: ApprovalBridge,\n\tonThreadSubscribersEmpty?: (threadId: string) => void,\n\toptions: Omit<ServerCoreOptions, \"registry\"> = {},\n\tuserInput?: UserInputBridge,\n): ServerCore {\n\treturn new RoutedServerCore(registry, notifications, approvals, onThreadSubscribersEmpty, options, userInput);\n}\n\nexport function registerLoadedThreadObjectListHandler(registry: MethodRegistry, threads: ThreadRegistry): void {\n\tregistry.register(\"thread/loaded/list\", {\n\t\tscope: \"thread\",\n\t\thandler: (context) => {\n\t\t\tconst params = objectValue(context.request.params);\n\t\t\tconst cursor = decodeCursor(optionalString(params.cursor) ?? null);\n\t\t\tconst limit = optionalNumber(params.limit) ?? Number.POSITIVE_INFINITY;\n\t\t\tconst loaded = threads.listLoaded().map((thread) => thread.id);\n\t\t\tconst data = loaded.slice(cursor, cursor + limit);\n\t\t\tconst nextOffset = cursor + data.length;\n\t\t\treturn {\n\t\t\t\tdata,\n\t\t\t\tnextCursor: nextOffset < loaded.length ? encodeCursor(nextOffset) : null,\n\t\t\t};\n\t\t},\n\t});\n}\n\nclass RoutedServerCore extends ServerCore {\n\tprivate readonly notifications: NotificationRouter;\n\tprivate readonly approvals: ApprovalBridge;\n\tprivate readonly userInput: UserInputBridge | undefined;\n\tprivate readonly onThreadSubscribersEmpty: ((threadId: string) => void) | undefined;\n\n\tconstructor(\n\t\tregistry: MethodRegistry,\n\t\tnotifications: NotificationRouter,\n\t\tapprovals: ApprovalBridge,\n\t\tonThreadSubscribersEmpty?: (threadId: string) => void,\n\t\toptions: Omit<ServerCoreOptions, \"registry\"> = {},\n\t\tuserInput?: UserInputBridge,\n\t) {\n\t\tsuper({ ...options, registry });\n\t\tthis.notifications = notifications;\n\t\tthis.approvals = approvals;\n\t\tthis.userInput = userInput;\n\t\tthis.onThreadSubscribersEmpty = onThreadSubscribersEmpty;\n\t}\n\n\toverride addConnection(input: ConnectionInput): Connection {\n\t\tconst connection = super.addConnection(input);\n\t\tthis.notifications.addConnection({\n\t\t\tid: connection.id,\n\t\t\tget initialized() {\n\t\t\t\treturn connection.initialized;\n\t\t\t},\n\t\t\tget transport() {\n\t\t\t\treturn routerTransport(connection.transportKind);\n\t\t\t},\n\t\t\tget capabilities() {\n\t\t\t\treturn connection.capabilities;\n\t\t\t},\n\t\t\tget optOutNotificationMethods() {\n\t\t\t\treturn [...connection.optOutNotificationMethods];\n\t\t\t},\n\t\t\tsend: (message) => connection.send(message),\n\t\t\tclose: () => {\n\t\t\t\tvoid connection.close(\"slow-client\");\n\t\t\t},\n\t\t});\n\t\treturn connection;\n\t}\n\n\toverride removeConnection(id: ConnectionId): void {\n\t\tconst emptiedThreadIds = this.notifications.removeConnection(id);\n\t\tsuper.removeConnection(id);\n\t\tfor (const threadId of emptiedThreadIds) {\n\t\t\tthis.onThreadSubscribersEmpty?.(threadId);\n\t\t}\n\t}\n\n\toverride async receive(connectionId: ConnectionId, envelope: ClassifiedIncoming): Promise<void> {\n\t\tconst connection = this.getConnection(connectionId);\n\t\tif (connection?.initialized && this.userInput) {\n\t\t\ttry {\n\t\t\t\tif (\n\t\t\t\t\tenvelope.kind === \"notification\" &&\n\t\t\t\t\tenvelope.message.method === ADDITIVE_CLIENT_NOTIFICATION_METHODS[0]\n\t\t\t\t) {\n\t\t\t\t\tthis.userInput.progress(envelope.message.params);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tif (envelope.kind === \"response\" && envelope.message.id !== null) {\n\t\t\t\t\tconst response = { ...envelope.message, id: envelope.message.id };\n\t\t\t\t\tif (this.userInput.resolveResponse(response) || this.resolveApproval(response)) return;\n\t\t\t\t\tawait connection.send({\n\t\t\t\t\t\tid: envelope.message.id,\n\t\t\t\t\t\terror: { code: -32600, message: \"Unknown server request id\" },\n\t\t\t\t\t});\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tif (!(error instanceof UserInputProtocolError)) throw error;\n\t\t\t\tawait connection.send({\n\t\t\t\t\tid: envelope.kind === \"response\" ? envelope.message.id : null,\n\t\t\t\t\terror: { code: -32602, message: error.message },\n\t\t\t\t});\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\tif (!this.userInput && envelope.kind === \"response\" && this.resolveApproval(envelope.message)) return;\n\t\tawait super.receive(connectionId, envelope);\n\t}\n\n\tprivate resolveApproval(response: RpcResponse): boolean {\n\t\tconst id = response.id;\n\t\tif (id === null) {\n\t\t\treturn false;\n\t\t}\n\t\tif (\"result\" in response) {\n\t\t\treturn this.approvals.resolveResponse({ id, result: response.result });\n\t\t}\n\t\treturn this.approvals.resolveResponse({ id, error: response.error });\n\t}\n}\n\nclass ModeTurnStore implements TurnEngineStore<ModeTurnEntry> {\n\tprivate readonly threads: ThreadRegistry;\n\n\tconstructor(threads: ThreadRegistry) {\n\t\tthis.threads = threads;\n\t}\n\n\tgetLoadedThread(threadId: string): ModeTurnEntry {\n\t\treturn new ModeTurnThreadEntry(this.threads.getLoadedThread(threadId));\n\t}\n\n\trunThreadTask<T>(threadId: string, task: () => Promise<T> | T): Promise<T> {\n\t\treturn this.threads.runThreadTask(threadId, task);\n\t}\n}\n\nclass ModeTurnThreadEntry implements TurnEngineThreadEntry {\n\tprivate readonly entry: ThreadEntry;\n\tprivate readonly sessionAdapter: TurnEngineSession;\n\n\tconstructor(entry: ThreadEntry) {\n\t\tthis.entry = entry;\n\t\tthis.sessionAdapter = new ModeTurnSession(entry.session);\n\t}\n\n\tget id(): string {\n\t\treturn this.entry.id;\n\t}\n\n\tget cwd(): string {\n\t\treturn this.entry.cwd;\n\t}\n\n\tget session(): TurnEngineSession {\n\t\treturn this.sessionAdapter;\n\t}\n\n\tget activeTurn() {\n\t\treturn this.entry.activeTurn;\n\t}\n\n\tset activeTurn(value) {\n\t\tthis.entry.activeTurn = value;\n\t}\n\n\tget status() {\n\t\treturn this.entry.status;\n\t}\n\n\tset status(value) {\n\t\tthis.entry.status = value;\n\t}\n\n\tget updatedAt(): string {\n\t\treturn this.entry.updatedAt;\n\t}\n\n\tset updatedAt(value: string) {\n\t\tthis.entry.updatedAt = value;\n\t}\n}\n\nclass ModeTurnSession implements TurnEngineSession {\n\tprivate readonly session: AgentSession;\n\n\tconstructor(session: AgentSession) {\n\t\tthis.session = session;\n\t}\n\n\tprompt(\n\t\ttext: string,\n\t\toptions?: { readonly source?: \"rpc\"; readonly preflightResult?: (success: boolean) => void },\n\t): Promise<void> {\n\t\treturn this.session.prompt(text, options);\n\t}\n\n\tsteer(text: string): Promise<void> {\n\t\treturn this.session.steer(text);\n\t}\n\n\tabort(): Promise<void> {\n\t\treturn this.session.abort();\n\t}\n\n\tsubscribe(listener: (event: { readonly type: string }) => void): () => void {\n\t\t// Pass the full AgentSessionEvent through: the turn engine projects these\n\t\t// into item/* notifications, so stripping payloads here would silence the\n\t\t// entire assistant/tool item stream.\n\t\treturn this.session.subscribe(listener);\n\t}\n}\n\nfunction objectParams(request: RpcRequest): Readonly<Record<string, unknown>> {\n\tif (typeof request.params === \"object\" && request.params !== null && !Array.isArray(request.params)) {\n\t\treturn Object.fromEntries(Object.entries(request.params));\n\t}\n\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params\" });\n}\n\nfunction requiredStringParam(value: unknown, name: string): string {\n\tif (typeof value !== \"string\" || value.length === 0) {\n\t\tthrow new TurnEngineError({ code: -32602, message: `Invalid params: ${name} is required` });\n\t}\n\treturn value;\n}\n\nfunction optionalNullableStringParam(value: unknown, name: string): string | null | undefined {\n\tif (value === undefined || value === null) return value;\n\tif (typeof value !== \"string\") {\n\t\tthrow new TurnEngineError({ code: -32602, message: `Invalid params: ${name} must be a string` });\n\t}\n\treturn value;\n}\n\nfunction userInputArrayParam(value: unknown): readonly UserInput[] {\n\tif (!Array.isArray(value)) {\n\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: input must be an array\" });\n\t}\n\treturn value.map(userInputParam);\n}\n\nfunction userInputParam(value: unknown): UserInput {\n\tif (typeof value !== \"object\" || value === null || Array.isArray(value)) {\n\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: input item must be an object\" });\n\t}\n\tconst item = Object.fromEntries(Object.entries(value));\n\tconst type = item.type;\n\tswitch (type) {\n\t\tcase \"text\":\n\t\t\treturn {\n\t\t\t\ttype,\n\t\t\t\ttext: requiredStringParam(item.text, \"input.text\"),\n\t\t\t\ttext_elements: Array.isArray(item.text_elements) ? item.text_elements : [],\n\t\t\t};\n\t\tcase \"image\":\n\t\t\treturn { type, url: requiredStringParam(item.url, \"input.url\") };\n\t\tcase \"localImage\":\n\t\t\treturn { type, path: requiredStringParam(item.path, \"input.path\") };\n\t\tcase \"skill\":\n\t\tcase \"mention\":\n\t\t\treturn {\n\t\t\t\ttype,\n\t\t\t\tname: requiredStringParam(item.name, \"input.name\"),\n\t\t\t\tpath: requiredStringParam(item.path, \"input.path\"),\n\t\t\t};\n\t\tdefault:\n\t\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: unsupported input item type\" });\n\t}\n}\n\nfunction routerTransport(transport: TransportKind): ConnectionTransport {\n\tswitch (transport) {\n\t\tcase \"stdio\":\n\t\t\treturn \"stdio\";\n\t\tcase \"websocket\":\n\t\t\treturn \"ws\";\n\t\tcase \"unix\":\n\t\t\treturn \"unix\";\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"file":"turn-adapter.js","sourceRoot":"","sources":["../../../src/modes/app-server/turn-adapter.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,oCAAoC,EAAE,MAAM,uBAAuB,CAAC;AAM7E,OAAO,EAAE,UAAU,EAA0B,MAAM,yBAAyB,CAAC;AAE7E,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAAE,YAAY,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AE,IAAI,EAAE,GAAG,EAAE,mBAAmB,CAAC,IAAI,CAAC,GAAG,EAAE,WAAW,CAAC,EAAE,CAAC;QAClE,KAAK,YAAY;YAChB,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,EAAE,CAAC;QACrE,KAAK,OAAO,CAAC;QACb,KAAK,SAAS;YACb,OAAO;gBACN,IAAI;gBACJ,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC;gBAClD,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC;aAClD,CAAC;QACH;YACC,MAAM,IAAI,eAAe,CAAC,EAAE,IAAI,EAAE,CAAC,KAAK,EAAE,OAAO,EAAE,6CAA6C,EAAE,CAAC,CAAC;IACtG,CAAC;AACF,CAAC;AAED,SAAS,eAAe,CAAC,SAAwB;IAChD,QAAQ,SAAS,EAAE,CAAC;QACnB,KAAK,OAAO;YACX,OAAO,OAAO,CAAC;QAChB,KAAK,WAAW;YACf,OAAO,IAAI,CAAC;QACb,KAAK,MAAM;YACV,OAAO,MAAM,CAAC;IAChB,CAAC;AACF,CAAC","sourcesContent":["import type { AgentSession } from \"../../core/agent-session.ts\";\nimport type { TurnInterruptParams, TurnStartParams, TurnSteerParams, UserInput } from \"./protocol/index.ts\";\nimport { ADDITIVE_CLIENT_NOTIFICATION_METHODS } from \"./protocol/methods.ts\";\nimport type { ClassifiedIncoming, RpcResponse } from \"./rpc/envelope.ts\";\nimport type { MethodRegistry, RpcRequest } from \"./rpc/registry.ts\";\nimport type { ApprovalBridge } from \"./server/approvals.ts\";\nimport type { Connection, ConnectionId, ConnectionInput, TransportKind } from \"./server/connection.ts\";\nimport type { ConnectionTransport, NotificationRouter } from \"./server/notifications.ts\";\nimport { ServerCore, type ServerCoreOptions } from \"./server/server-core.ts\";\nimport type { UserInputBridge } from \"./server/user-input-bridge.ts\";\nimport { UserInputProtocolError } from \"./server/user-input-types.ts\";\nimport { decodeCursor, encodeCursor, objectValue, optionalNumber, optionalString } from \"./threads/handler-params.ts\";\nimport type { ThreadEntry, ThreadRegistry } from \"./threads/registry.ts\";\nimport { TurnEngineError } from \"./threads/turn-runtime.ts\";\nimport type { TurnEngineSession, TurnEngineStore, TurnEngineThreadEntry } from \"./threads/turns.ts\";\n\ntype ModeTurnEntry = TurnEngineThreadEntry;\n\nexport function createModeTurnStore(threads: ThreadRegistry): TurnEngineStore<ModeTurnEntry> {\n\treturn new ModeTurnStore(threads);\n}\n\nexport function turnStartParams(request: RpcRequest): TurnStartParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\tclientUserMessageId: optionalNullableStringParam(params.clientUserMessageId, \"clientUserMessageId\"),\n\t\tinput: userInputArrayParam(params.input),\n\t};\n}\n\nexport function turnSteerParams(request: RpcRequest): TurnSteerParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\texpectedTurnId: requiredStringParam(params.expectedTurnId, \"expectedTurnId\"),\n\t\tclientUserMessageId: optionalNullableStringParam(params.clientUserMessageId, \"clientUserMessageId\"),\n\t\tinput: userInputArrayParam(params.input),\n\t};\n}\n\nexport function turnInterruptParams(request: RpcRequest): TurnInterruptParams {\n\tconst params = objectParams(request);\n\treturn {\n\t\tthreadId: requiredStringParam(params.threadId, \"threadId\"),\n\t\tturnId: requiredStringParam(params.turnId, \"turnId\"),\n\t};\n}\n\nexport function createRoutedServerCore(\n\tregistry: MethodRegistry,\n\tnotifications: NotificationRouter,\n\tapprovals: ApprovalBridge,\n\tonThreadSubscribersEmpty?: (threadId: string) => void,\n\toptions: Omit<ServerCoreOptions, \"registry\"> = {},\n\tuserInput?: UserInputBridge,\n): ServerCore {\n\treturn new RoutedServerCore(registry, notifications, approvals, onThreadSubscribersEmpty, options, userInput);\n}\n\nexport function registerLoadedThreadObjectListHandler(registry: MethodRegistry, threads: ThreadRegistry): void {\n\tregistry.register(\"thread/loaded/list\", {\n\t\tscope: \"thread\",\n\t\thandler: (context) => {\n\t\t\tconst params = objectValue(context.request.params);\n\t\t\tconst cursor = decodeCursor(optionalString(params.cursor) ?? null);\n\t\t\tconst limit = optionalNumber(params.limit) ?? Number.POSITIVE_INFINITY;\n\t\t\tconst loaded = threads.listLoaded().map((thread) => thread.id);\n\t\t\tconst data = loaded.slice(cursor, cursor + limit);\n\t\t\tconst nextOffset = cursor + data.length;\n\t\t\treturn {\n\t\t\t\tdata,\n\t\t\t\tnextCursor: nextOffset < loaded.length ? encodeCursor(nextOffset) : null,\n\t\t\t};\n\t\t},\n\t});\n}\n\nclass RoutedServerCore extends ServerCore {\n\tprivate readonly notifications: NotificationRouter;\n\tprivate readonly approvals: ApprovalBridge;\n\tprivate readonly userInput: UserInputBridge | undefined;\n\tprivate readonly onThreadSubscribersEmpty: ((threadId: string) => void) | undefined;\n\n\tconstructor(\n\t\tregistry: MethodRegistry,\n\t\tnotifications: NotificationRouter,\n\t\tapprovals: ApprovalBridge,\n\t\tonThreadSubscribersEmpty?: (threadId: string) => void,\n\t\toptions: Omit<ServerCoreOptions, \"registry\"> = {},\n\t\tuserInput?: UserInputBridge,\n\t) {\n\t\tsuper({ ...options, registry });\n\t\tthis.notifications = notifications;\n\t\tthis.approvals = approvals;\n\t\tthis.userInput = userInput;\n\t\tthis.onThreadSubscribersEmpty = onThreadSubscribersEmpty;\n\t}\n\n\toverride addConnection(input: ConnectionInput): Connection {\n\t\tconst connection = super.addConnection(input);\n\t\tthis.notifications.addConnection({\n\t\t\tid: connection.id,\n\t\t\tget initialized() {\n\t\t\t\treturn connection.initialized;\n\t\t\t},\n\t\t\tget transport() {\n\t\t\t\treturn routerTransport(connection.transportKind);\n\t\t\t},\n\t\t\tget capabilities() {\n\t\t\t\treturn connection.capabilities;\n\t\t\t},\n\t\t\tget optOutNotificationMethods() {\n\t\t\t\treturn [...connection.optOutNotificationMethods];\n\t\t\t},\n\t\t\tsend: (message) => connection.send(message),\n\t\t\tclose: () => {\n\t\t\t\tvoid connection.close(\"slow-client\");\n\t\t\t},\n\t\t});\n\t\treturn connection;\n\t}\n\n\toverride removeConnection(id: ConnectionId): void {\n\t\tconst emptiedThreadIds = this.notifications.removeConnection(id);\n\t\tsuper.removeConnection(id);\n\t\tfor (const threadId of emptiedThreadIds) {\n\t\t\tthis.onThreadSubscribersEmpty?.(threadId);\n\t\t}\n\t}\n\n\toverride async receive(connectionId: ConnectionId, envelope: ClassifiedIncoming): Promise<void> {\n\t\tconst connection = this.getConnection(connectionId);\n\t\tif (connection?.initialized && this.userInput) {\n\t\t\ttry {\n\t\t\t\tif (\n\t\t\t\t\tenvelope.kind === \"notification\" &&\n\t\t\t\t\tenvelope.message.method === ADDITIVE_CLIENT_NOTIFICATION_METHODS[0]\n\t\t\t\t) {\n\t\t\t\t\tthis.userInput.progress(envelope.message.params);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tif (envelope.kind === \"response\" && envelope.message.id !== null) {\n\t\t\t\t\tconst response = { ...envelope.message, id: envelope.message.id };\n\t\t\t\t\tif (this.userInput.resolveResponse(response) || this.resolveApproval(response)) return;\n\t\t\t\t\tawait connection.send({\n\t\t\t\t\t\tid: envelope.message.id,\n\t\t\t\t\t\terror: { code: -32600, message: \"Unknown server request id\" },\n\t\t\t\t\t});\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tif (!(error instanceof UserInputProtocolError)) throw error;\n\t\t\t\tawait connection.send({\n\t\t\t\t\tid: envelope.kind === \"response\" ? envelope.message.id : null,\n\t\t\t\t\terror: { code: -32602, message: error.message },\n\t\t\t\t});\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\tif (!this.userInput && envelope.kind === \"response\" && this.resolveApproval(envelope.message)) return;\n\t\tawait super.receive(connectionId, envelope);\n\t}\n\n\tprivate resolveApproval(response: RpcResponse): boolean {\n\t\tconst id = response.id;\n\t\tif (id === null) {\n\t\t\treturn false;\n\t\t}\n\t\tif (\"result\" in response) {\n\t\t\treturn this.approvals.resolveResponse({ id, result: response.result });\n\t\t}\n\t\treturn this.approvals.resolveResponse({ id, error: response.error });\n\t}\n}\n\nclass ModeTurnStore implements TurnEngineStore<ModeTurnEntry> {\n\tprivate readonly threads: ThreadRegistry;\n\n\tconstructor(threads: ThreadRegistry) {\n\t\tthis.threads = threads;\n\t}\n\n\tgetLoadedThread(threadId: string): ModeTurnEntry {\n\t\treturn new ModeTurnThreadEntry(this.threads.getLoadedThread(threadId));\n\t}\n\n\trunThreadTask<T>(threadId: string, task: () => Promise<T> | T): Promise<T> {\n\t\treturn this.threads.runThreadTask(threadId, task);\n\t}\n}\n\nclass ModeTurnThreadEntry implements TurnEngineThreadEntry {\n\tprivate readonly entry: ThreadEntry;\n\tprivate readonly sessionAdapter: TurnEngineSession;\n\n\tconstructor(entry: ThreadEntry) {\n\t\tthis.entry = entry;\n\t\tthis.sessionAdapter = new ModeTurnSession(entry.session);\n\t}\n\n\tget id(): string {\n\t\treturn this.entry.id;\n\t}\n\n\tget cwd(): string {\n\t\treturn this.entry.cwd;\n\t}\n\n\tget session(): TurnEngineSession {\n\t\treturn this.sessionAdapter;\n\t}\n\n\tget activeTurn() {\n\t\treturn this.entry.activeTurn;\n\t}\n\n\tset activeTurn(value) {\n\t\tthis.entry.activeTurn = value;\n\t}\n\n\tget status() {\n\t\treturn this.entry.status;\n\t}\n\n\tset status(value) {\n\t\tthis.entry.status = value;\n\t}\n\n\tget updatedAt(): string {\n\t\treturn this.entry.updatedAt;\n\t}\n\n\tset updatedAt(value: string) {\n\t\tthis.entry.updatedAt = value;\n\t}\n}\n\nclass ModeTurnSession implements TurnEngineSession {\n\tprivate readonly session: AgentSession;\n\n\tconstructor(session: AgentSession) {\n\t\tthis.session = session;\n\t}\n\n\tprompt(\n\t\ttext: string,\n\t\toptions?: { readonly source?: \"rpc\"; readonly preflightResult?: (success: boolean) => void },\n\t): Promise<void> {\n\t\treturn this.session.prompt(text, options);\n\t}\n\n\tsteer(text: string, options?: { readonly source?: \"rpc\" }): Promise<void> {\n\t\t// App-server steering is client-driven input, exactly like its prompts:\n\t\t// tag it \"rpc\" so extension `input` handlers see the real source.\n\t\treturn this.session.steer(text, undefined, { source: options?.source ?? \"rpc\" });\n\t}\n\n\tabort(): Promise<void> {\n\t\treturn this.session.abort();\n\t}\n\n\tsubscribe(listener: (event: { readonly type: string }) => void): () => void {\n\t\t// Pass the full AgentSessionEvent through: the turn engine projects these\n\t\t// into item/* notifications, so stripping payloads here would silence the\n\t\t// entire assistant/tool item stream.\n\t\treturn this.session.subscribe(listener);\n\t}\n}\n\nfunction objectParams(request: RpcRequest): Readonly<Record<string, unknown>> {\n\tif (typeof request.params === \"object\" && request.params !== null && !Array.isArray(request.params)) {\n\t\treturn Object.fromEntries(Object.entries(request.params));\n\t}\n\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params\" });\n}\n\nfunction requiredStringParam(value: unknown, name: string): string {\n\tif (typeof value !== \"string\" || value.length === 0) {\n\t\tthrow new TurnEngineError({ code: -32602, message: `Invalid params: ${name} is required` });\n\t}\n\treturn value;\n}\n\nfunction optionalNullableStringParam(value: unknown, name: string): string | null | undefined {\n\tif (value === undefined || value === null) return value;\n\tif (typeof value !== \"string\") {\n\t\tthrow new TurnEngineError({ code: -32602, message: `Invalid params: ${name} must be a string` });\n\t}\n\treturn value;\n}\n\nfunction userInputArrayParam(value: unknown): readonly UserInput[] {\n\tif (!Array.isArray(value)) {\n\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: input must be an array\" });\n\t}\n\treturn value.map(userInputParam);\n}\n\nfunction userInputParam(value: unknown): UserInput {\n\tif (typeof value !== \"object\" || value === null || Array.isArray(value)) {\n\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: input item must be an object\" });\n\t}\n\tconst item = Object.fromEntries(Object.entries(value));\n\tconst type = item.type;\n\tswitch (type) {\n\t\tcase \"text\":\n\t\t\treturn {\n\t\t\t\ttype,\n\t\t\t\ttext: requiredStringParam(item.text, \"input.text\"),\n\t\t\t\ttext_elements: Array.isArray(item.text_elements) ? item.text_elements : [],\n\t\t\t};\n\t\tcase \"image\":\n\t\t\treturn { type, url: requiredStringParam(item.url, \"input.url\") };\n\t\tcase \"localImage\":\n\t\t\treturn { type, path: requiredStringParam(item.path, \"input.path\") };\n\t\tcase \"skill\":\n\t\tcase \"mention\":\n\t\t\treturn {\n\t\t\t\ttype,\n\t\t\t\tname: requiredStringParam(item.name, \"input.name\"),\n\t\t\t\tpath: requiredStringParam(item.path, \"input.path\"),\n\t\t\t};\n\t\tdefault:\n\t\t\tthrow new TurnEngineError({ code: -32602, message: \"Invalid params: unsupported input item type\" });\n\t}\n}\n\nfunction routerTransport(transport: TransportKind): ConnectionTransport {\n\tswitch (transport) {\n\t\tcase \"stdio\":\n\t\t\treturn \"stdio\";\n\t\tcase \"websocket\":\n\t\t\treturn \"ws\";\n\t\tcase \"unix\":\n\t\t\treturn \"unix\";\n\t}\n}\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type Component, ScrollView, type ScrollViewScrollbar } from "@earendil-works/pi-tui";
|
|
2
|
+
export interface ChatViewportOptions {
|
|
3
|
+
readonly document: Component;
|
|
4
|
+
readonly pendingMessages: Component;
|
|
5
|
+
readonly status: Component;
|
|
6
|
+
/** Tool-hook status rows shown between the session status and the widgets above the editor. */
|
|
7
|
+
readonly hookStatus?: Component;
|
|
8
|
+
readonly editor: Component;
|
|
9
|
+
readonly footer: Component;
|
|
10
|
+
readonly widgetsAbove?: Component;
|
|
11
|
+
readonly widgetsBelow?: Component;
|
|
12
|
+
readonly scrollbar?: ScrollViewScrollbar;
|
|
13
|
+
readonly scrollbarTrackStyle?: (text: string) => string;
|
|
14
|
+
readonly scrollbarThumbStyle?: (text: string) => string;
|
|
15
|
+
}
|
|
16
|
+
export interface ChatViewport {
|
|
17
|
+
readonly root: Component;
|
|
18
|
+
readonly transcript: ScrollView;
|
|
19
|
+
}
|
|
20
|
+
/** Shared fullscreen transcript and fixed input-dock layout. */
|
|
21
|
+
export declare function createChatViewport(options: ChatViewportOptions): ChatViewport;
|
|
22
|
+
//# sourceMappingURL=chat-viewport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chat-viewport.d.ts","sourceRoot":"","sources":["../../../src/modes/interactive/chat-viewport.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,UAAU,EAAE,KAAK,mBAAmB,EAAU,MAAM,wBAAwB,CAAC;AAEtG,MAAM,WAAW,mBAAmB;IACnC,QAAQ,CAAC,QAAQ,EAAE,SAAS,CAAC;IAC7B,QAAQ,CAAC,eAAe,EAAE,SAAS,CAAC;IACpC,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,+FAA+F;IAC/F,QAAQ,CAAC,UAAU,CAAC,EAAE,SAAS,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,YAAY,CAAC,EAAE,SAAS,CAAC;IAClC,QAAQ,CAAC,YAAY,CAAC,EAAE,SAAS,CAAC;IAClC,QAAQ,CAAC,SAAS,CAAC,EAAE,mBAAmB,CAAC;IACzC,QAAQ,CAAC,mBAAmB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC;IACxD,QAAQ,CAAC,mBAAmB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC;CACxD;AAED,MAAM,WAAW,YAAY;IAC5B,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC;IACzB,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;CAChC;AAED,gEAAgE;AAChE,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,mBAAmB,GAAG,YAAY,CAyB7E"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ScrollView, VStack } from "@earendil-works/pi-tui";
|
|
2
|
+
/** Shared fullscreen transcript and fixed input-dock layout. */
|
|
3
|
+
export function createChatViewport(options) {
|
|
4
|
+
const transcript = new ScrollView(options.document, {
|
|
5
|
+
follow: "end",
|
|
6
|
+
primary: true,
|
|
7
|
+
overscroll: "chain",
|
|
8
|
+
scrollbar: options.scrollbar ?? "auto",
|
|
9
|
+
...(options.scrollbarTrackStyle === undefined ? {} : { scrollbarTrackStyle: options.scrollbarTrackStyle }),
|
|
10
|
+
...(options.scrollbarThumbStyle === undefined ? {} : { scrollbarThumbStyle: options.scrollbarThumbStyle }),
|
|
11
|
+
});
|
|
12
|
+
const dock = new VStack([
|
|
13
|
+
{ component: options.pendingMessages, shrink: 1, minSize: 0 },
|
|
14
|
+
{ component: options.status, shrink: 1, minSize: 0 },
|
|
15
|
+
...(options.hookStatus === undefined ? [] : [{ component: options.hookStatus, shrink: 1, minSize: 0 }]),
|
|
16
|
+
...(options.widgetsAbove === undefined ? [] : [{ component: options.widgetsAbove, shrink: 1, minSize: 0 }]),
|
|
17
|
+
{ component: options.editor, shrink: 1, minSize: 3 },
|
|
18
|
+
...(options.widgetsBelow === undefined ? [] : [{ component: options.widgetsBelow, shrink: 1, minSize: 0 }]),
|
|
19
|
+
{ component: options.footer, shrink: 1, minSize: 0 },
|
|
20
|
+
]);
|
|
21
|
+
return {
|
|
22
|
+
transcript,
|
|
23
|
+
root: new VStack([
|
|
24
|
+
{ component: transcript, basis: 0, grow: 1, shrink: 1, minSize: 1 },
|
|
25
|
+
{ component: dock, basis: "auto", grow: 0, shrink: 1, minSize: 1 },
|
|
26
|
+
]),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=chat-viewport.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chat-viewport.js","sourceRoot":"","sources":["../../../src/modes/interactive/chat-vi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AAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;QAC3G,EAAE,SAAS,EAAE,OAAO,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;QACpD,GAAG,CAAC,OAAO,CAAC,YAAY,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,OAAO,CAAC,YAAY,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;QAC3G,EAAE,SAAS,EAAE,OAAO,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;KACpD,CAAC,CAAC;IACH,OAAO;QACN,UAAU;QACV,IAAI,EAAE,IAAI,MAAM,CAAC;YAChB,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;YACnE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;SAClE,CAAC;KACF,CAAC;AACH,CAAC","sourcesContent":["import { type Component, ScrollView, type ScrollViewScrollbar, VStack } from \"@earendil-works/pi-tui\";\n\nexport interface ChatViewportOptions {\n\treadonly document: Component;\n\treadonly pendingMessages: Component;\n\treadonly status: Component;\n\t/** Tool-hook status rows shown between the session status and the widgets above the editor. */\n\treadonly hookStatus?: Component;\n\treadonly editor: Component;\n\treadonly footer: Component;\n\treadonly widgetsAbove?: Component;\n\treadonly widgetsBelow?: Component;\n\treadonly scrollbar?: ScrollViewScrollbar;\n\treadonly scrollbarTrackStyle?: (text: string) => string;\n\treadonly scrollbarThumbStyle?: (text: string) => string;\n}\n\nexport interface ChatViewport {\n\treadonly root: Component;\n\treadonly transcript: ScrollView;\n}\n\n/** Shared fullscreen transcript and fixed input-dock layout. */\nexport function createChatViewport(options: ChatViewportOptions): ChatViewport {\n\tconst transcript = new ScrollView(options.document, {\n\t\tfollow: \"end\",\n\t\tprimary: true,\n\t\toverscroll: \"chain\",\n\t\tscrollbar: options.scrollbar ?? \"auto\",\n\t\t...(options.scrollbarTrackStyle === undefined ? {} : { scrollbarTrackStyle: options.scrollbarTrackStyle }),\n\t\t...(options.scrollbarThumbStyle === undefined ? {} : { scrollbarThumbStyle: options.scrollbarThumbStyle }),\n\t});\n\tconst dock = new VStack([\n\t\t{ component: options.pendingMessages, shrink: 1, minSize: 0 },\n\t\t{ component: options.status, shrink: 1, minSize: 0 },\n\t\t...(options.hookStatus === undefined ? [] : [{ component: options.hookStatus, shrink: 1, minSize: 0 }]),\n\t\t...(options.widgetsAbove === undefined ? [] : [{ component: options.widgetsAbove, shrink: 1, minSize: 0 }]),\n\t\t{ component: options.editor, shrink: 1, minSize: 3 },\n\t\t...(options.widgetsBelow === undefined ? [] : [{ component: options.widgetsBelow, shrink: 1, minSize: 0 }]),\n\t\t{ component: options.footer, shrink: 1, minSize: 0 },\n\t]);\n\treturn {\n\t\ttranscript,\n\t\troot: new VStack([\n\t\t\t{ component: transcript, basis: 0, grow: 1, shrink: 1, minSize: 1 },\n\t\t\t{ component: dock, basis: \"auto\", grow: 0, shrink: 1, minSize: 1 },\n\t\t]),\n\t};\n}\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The editor shortcut that expands a pending async (waitForAnswer=false)
|
|
3
|
+
* question into the full AskUserQuestionComponent: a rebindable keybinding
|
|
4
|
+
* action plus the macOS Option-compose glyphs that stand in for it when the
|
|
5
|
+
* terminal does not report Option as Alt.
|
|
6
|
+
*/
|
|
7
|
+
import { type KeybindingsManager, type KeyId } from "@earendil-works/pi-tui";
|
|
8
|
+
/** Keybinding action (default `alt+a`, rebindable in keybindings.json) that expands the pending question. */
|
|
9
|
+
export declare const ASK_USER_ANSWER_KEYBINDING = "app.question.answer";
|
|
10
|
+
/** Glyphs the bound `alt+<letter>` chords type on darwin when Option composes. */
|
|
11
|
+
export declare function darwinOptionGlyphs(keys: readonly KeyId[]): ReadonlySet<string>;
|
|
12
|
+
/** True when `data` is the editor input that expands the pending question on `platform`. */
|
|
13
|
+
export declare function matchesAskUserAnswerKey(data: string, platform?: NodeJS.Platform, keybindings?: KeybindingsManager): boolean;
|
|
14
|
+
//# sourceMappingURL=ask-user-answer-key.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ask-user-answer-key.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-answer-key.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAwC,KAAK,kBAAkB,EAAE,KAAK,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAEnH,6GAA6G;AAC7G,eAAO,MAAM,0BAA0B,wBAAwB,CAAC;AAsChE,kFAAkF;AAClF,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,SAAS,KAAK,EAAE,GAAG,WAAW,CAAC,MAAM,CAAC,CAQ9E;AAED,4FAA4F;AAC5F,wBAAgB,uBAAuB,CACtC,IAAI,EAAE,MAAM,EACZ,QAAQ,GAAE,MAAM,CAAC,QAA2B,EAC5C,WAAW,GAAE,kBAAqC,GAChD,OAAO,CAIT"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The editor shortcut that expands a pending async (waitForAnswer=false)
|
|
3
|
+
* question into the full AskUserQuestionComponent: a rebindable keybinding
|
|
4
|
+
* action plus the macOS Option-compose glyphs that stand in for it when the
|
|
5
|
+
* terminal does not report Option as Alt.
|
|
6
|
+
*/
|
|
7
|
+
import { decodeKittyPrintable, getKeybindings } from "@earendil-works/pi-tui";
|
|
8
|
+
/** Keybinding action (default `alt+a`, rebindable in keybindings.json) that expands the pending question. */
|
|
9
|
+
export const ASK_USER_ANSWER_KEYBINDING = "app.question.answer";
|
|
10
|
+
/**
|
|
11
|
+
* What each letter key types on a US-layout macOS keyboard while Option is
|
|
12
|
+
* held and the terminal lets Option compose characters instead of sending
|
|
13
|
+
* Alt (the default in Terminal.app, iTerm2, Ghostty and kitty), as
|
|
14
|
+
* `[Option+letter, Option+Shift+letter]`. Accepting the glyphs of the bound
|
|
15
|
+
* `alt+<letter>` chords keeps the advertised shortcut working without a
|
|
16
|
+
* terminal-settings detour; other platforms never see Option this way, so
|
|
17
|
+
* they keep treating the glyphs as text. The dead keys `e`, `i`, `n` and `u`
|
|
18
|
+
* compose with the next keystroke instead of typing a glyph, so a binding on
|
|
19
|
+
* one of them needs the terminal's Option-as-Meta setting.
|
|
20
|
+
*/
|
|
21
|
+
const DARWIN_OPTION_GLYPHS = {
|
|
22
|
+
a: ["å", "Å"],
|
|
23
|
+
b: ["∫", "ı"],
|
|
24
|
+
c: ["ç", "Ç"],
|
|
25
|
+
d: ["∂", "Î"],
|
|
26
|
+
f: ["ƒ", "Ï"],
|
|
27
|
+
g: ["©", "˝"],
|
|
28
|
+
h: ["˙", "Ó"],
|
|
29
|
+
j: ["∆", "Ô"],
|
|
30
|
+
k: ["˚", "\uf8ff"],
|
|
31
|
+
l: ["¬", "Ò"],
|
|
32
|
+
m: ["µ", "Â"],
|
|
33
|
+
o: ["ø", "Ø"],
|
|
34
|
+
p: ["π", "∏"],
|
|
35
|
+
q: ["œ", "Œ"],
|
|
36
|
+
r: ["®", "‰"],
|
|
37
|
+
s: ["ß", "Í"],
|
|
38
|
+
t: ["†", "ˇ"],
|
|
39
|
+
v: ["√", "◊"],
|
|
40
|
+
w: ["∑", "„"],
|
|
41
|
+
x: ["≈", "˛"],
|
|
42
|
+
y: ["¥", "Á"],
|
|
43
|
+
z: ["Ω", "¸"],
|
|
44
|
+
};
|
|
45
|
+
/** Glyphs the bound `alt+<letter>` chords type on darwin when Option composes. */
|
|
46
|
+
export function darwinOptionGlyphs(keys) {
|
|
47
|
+
const glyphs = new Set();
|
|
48
|
+
for (const key of keys) {
|
|
49
|
+
const letter = /^alt\+([a-z])$/i.exec(key)?.[1]?.toLowerCase();
|
|
50
|
+
if (letter === undefined)
|
|
51
|
+
continue;
|
|
52
|
+
for (const glyph of DARWIN_OPTION_GLYPHS[letter] ?? [])
|
|
53
|
+
glyphs.add(glyph);
|
|
54
|
+
}
|
|
55
|
+
return glyphs;
|
|
56
|
+
}
|
|
57
|
+
/** True when `data` is the editor input that expands the pending question on `platform`. */
|
|
58
|
+
export function matchesAskUserAnswerKey(data, platform = process.platform, keybindings = getKeybindings()) {
|
|
59
|
+
if (keybindings.matches(data, ASK_USER_ANSWER_KEYBINDING))
|
|
60
|
+
return true;
|
|
61
|
+
if (platform !== "darwin")
|
|
62
|
+
return false;
|
|
63
|
+
return darwinOptionGlyphs(keybindings.getKeys(ASK_USER_ANSWER_KEYBINDING)).has(decodeKittyPrintable(data) ?? data);
|
|
64
|
+
}
|
|
65
|
+
//# sourceMappingURL=ask-user-answer-key.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ask-user-answer-key.js","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-answer-key.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,oBAAoB,EAAE,cAAc,EAAuC,MAAM,wBAAwB,CAAC;AAEnH,6GAA6G;AAC7G,MAAM,CAAC,MAAM,0BAA0B,GAAG,qBAAqB,CAAC;AAEhE;;;;;;;;;;GAUG;AACH,MAAM,oBAAoB,GAAwD;IACjF,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACb,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACb,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACb,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACb,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACb,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG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,CAAC;AAED,4FAA4F;AAC5F,MAAM,UAAU,uBAAuB,CACtC,IAAY,EACZ,QAAQ,GAAoB,OAAO,CAAC,QAAQ,EAC5C,WAAW,GAAuB,cAAc,EAAE;IAElD,IAAI,WAAW,CAAC,OAAO,CAAC,IAAI,EAAE,0BAA0B,CAAC;QAAE,OAAO,IAAI,CAAC;IACvE,IAAI,QAAQ,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IACxC,OAAO,kBAAkB,CAAC,WAAW,CAAC,OAAO,CAAC,0BAA0B,CAAC,CAAC,CAAC,GAAG,CAAC,oBAAoB,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,CAAC;AACpH,CAAC","sourcesContent":["/**\n * The editor shortcut that expands a pending async (waitForAnswer=false)\n * question into the full AskUserQuestionComponent: a rebindable keybinding\n * action plus the macOS Option-compose glyphs that stand in for it when the\n * terminal does not report Option as Alt.\n */\n\nimport { decodeKittyPrintable, getKeybindings, type KeybindingsManager, type KeyId } from \"@earendil-works/pi-tui\";\n\n/** Keybinding action (default `alt+a`, rebindable in keybindings.json) that expands the pending question. */\nexport const ASK_USER_ANSWER_KEYBINDING = \"app.question.answer\";\n\n/**\n * What each letter key types on a US-layout macOS keyboard while Option is\n * held and the terminal lets Option compose characters instead of sending\n * Alt (the default in Terminal.app, iTerm2, Ghostty and kitty), as\n * `[Option+letter, Option+Shift+letter]`. Accepting the glyphs of the bound\n * `alt+<letter>` chords keeps the advertised shortcut working without a\n * terminal-settings detour; other platforms never see Option this way, so\n * they keep treating the glyphs as text. The dead keys `e`, `i`, `n` and `u`\n * compose with the next keystroke instead of typing a glyph, so a binding on\n * one of them needs the terminal's Option-as-Meta setting.\n */\nconst DARWIN_OPTION_GLYPHS: Readonly<Record<string, readonly [string, string]>> = {\n\ta: [\"å\", \"Å\"],\n\tb: [\"∫\", \"ı\"],\n\tc: [\"ç\", \"Ç\"],\n\td: [\"∂\", \"Î\"],\n\tf: [\"ƒ\", \"Ï\"],\n\tg: [\"©\", \"˝\"],\n\th: [\"˙\", \"Ó\"],\n\tj: [\"∆\", \"Ô\"],\n\tk: [\"˚\", \"\\uf8ff\"],\n\tl: [\"¬\", \"Ò\"],\n\tm: [\"µ\", \"Â\"],\n\to: [\"ø\", \"Ø\"],\n\tp: [\"π\", \"∏\"],\n\tq: [\"œ\", \"Œ\"],\n\tr: [\"®\", \"‰\"],\n\ts: [\"ß\", \"Í\"],\n\tt: [\"†\", \"ˇ\"],\n\tv: [\"√\", \"◊\"],\n\tw: [\"∑\", \"„\"],\n\tx: [\"≈\", \"˛\"],\n\ty: [\"¥\", \"Á\"],\n\tz: [\"Ω\", \"¸\"],\n};\n\n/** Glyphs the bound `alt+<letter>` chords type on darwin when Option composes. */\nexport function darwinOptionGlyphs(keys: readonly KeyId[]): ReadonlySet<string> {\n\tconst glyphs = new Set<string>();\n\tfor (const key of keys) {\n\t\tconst letter = /^alt\\+([a-z])$/i.exec(key)?.[1]?.toLowerCase();\n\t\tif (letter === undefined) continue;\n\t\tfor (const glyph of DARWIN_OPTION_GLYPHS[letter] ?? []) glyphs.add(glyph);\n\t}\n\treturn glyphs;\n}\n\n/** True when `data` is the editor input that expands the pending question on `platform`. */\nexport function matchesAskUserAnswerKey(\n\tdata: string,\n\tplatform: NodeJS.Platform = process.platform,\n\tkeybindings: KeybindingsManager = getKeybindings(),\n): boolean {\n\tif (keybindings.matches(data, ASK_USER_ANSWER_KEYBINDING)) return true;\n\tif (platform !== \"darwin\") return false;\n\treturn darwinOptionGlyphs(keybindings.getKeys(ASK_USER_ANSWER_KEYBINDING)).has(decodeKittyPrintable(data) ?? data);\n}\n"]}
|
|
@@ -1,39 +1,44 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Collapsed
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* AskUserQuestionComponent. The response-building helpers here
|
|
6
|
-
* interactive-mode can turn ordinary composer text into the
|
|
2
|
+
* Collapsed widget for a pending async (waitForAnswer=false) question: it
|
|
3
|
+
* sits above the editor and shows the unanswered count with the idle
|
|
4
|
+
* countdown, the first unanswered question with its options, and every way
|
|
5
|
+
* into the full AskUserQuestionComponent. The response-building helpers here
|
|
6
|
+
* are pure so interactive-mode can turn ordinary composer text into the
|
|
7
|
+
* comment answer.
|
|
7
8
|
*/
|
|
8
9
|
import { Container, type TUI } from "@earendil-works/pi-tui";
|
|
9
10
|
import type { QuestionRequest, QuestionResponse } from "../../../core/extensions/types.ts";
|
|
10
11
|
import { type QuestionDraft } from "./ask-user-question-state.ts";
|
|
11
12
|
/** Widget slot key used with `setWidget`; one pending async question at a time. */
|
|
12
13
|
export declare const ASK_USER_WIDGET_KEY = "ask-user";
|
|
13
|
-
|
|
14
|
-
export declare const ASK_USER_ANSWER_KEY = "alt+a";
|
|
14
|
+
type Question = QuestionRequest["questions"][number];
|
|
15
15
|
/** Question ids the draft has not answered yet. */
|
|
16
16
|
export declare function unansweredIds(request: QuestionRequest, draft: QuestionDraft): string[];
|
|
17
17
|
/** Response for composer text typed while the question is pending: the text is the comment. */
|
|
18
18
|
export declare function buildCommentResponse(request: QuestionRequest, draft: QuestionDraft, comment: string): QuestionResponse;
|
|
19
19
|
/** Response for an idle countdown that expired while the widget was collapsed. */
|
|
20
20
|
export declare function buildTimedOutResponse(request: QuestionRequest, draft: QuestionDraft, autoResolvedAfterMs: number): QuestionResponse;
|
|
21
|
-
export declare function
|
|
21
|
+
export declare function renderStatusLine(unanswered: number, countdownLabel: string): string;
|
|
22
|
+
export declare function renderQuestionLine(question: Question): string;
|
|
23
|
+
export declare function renderOptionsLine(question: Question, remaining: number): string;
|
|
24
|
+
/** Hint naming every way into the pending question; the shortcut segment follows the effective binding. */
|
|
25
|
+
export declare function renderAnswerHint(): string;
|
|
22
26
|
export interface AskUserAsyncWidgetOptions {
|
|
23
|
-
|
|
27
|
+
request: QuestionRequest;
|
|
28
|
+
draft: QuestionDraft;
|
|
24
29
|
/** Idle countdown shown in the line; 0 disables it. */
|
|
25
30
|
timeoutMs: number;
|
|
26
31
|
tui?: TUI;
|
|
27
32
|
onExpire: () => void;
|
|
28
33
|
}
|
|
29
34
|
export declare class AskUserAsyncWidget extends Container {
|
|
30
|
-
private readonly
|
|
35
|
+
private readonly request;
|
|
36
|
+
private readonly draft;
|
|
31
37
|
private readonly countdown;
|
|
32
|
-
private unanswered;
|
|
33
38
|
private countdownLabel;
|
|
34
39
|
constructor(options: AskUserAsyncWidgetOptions);
|
|
35
|
-
setUnanswered(count: number): void;
|
|
36
40
|
dispose(): void;
|
|
37
41
|
private update;
|
|
38
42
|
}
|
|
43
|
+
export {};
|
|
39
44
|
//# sourceMappingURL=ask-user-async-widget.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ask-user-async-widget.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-async-widget.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"ask-user-async-widget.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-async-widget.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,SAAS,EAAuB,KAAK,GAAG,EAAE,MAAM,wBAAwB,CAAC;AAClF,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAG3F,OAAO,EAAwB,KAAK,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAIxF,mFAAmF;AACnF,eAAO,MAAM,mBAAmB,aAAa,CAAC;AAE9C,KAAK,QAAQ,GAAG,eAAe,CAAC,WAAW,CAAC,CAAC,MAAM,CAAC,CAAC;AAUrD,mDAAmD;AACnD,wBAAgB,aAAa,CAAC,OAAO,EAAE,eAAe,EAAE,KAAK,EAAE,aAAa,GAAG,MAAM,EAAE,CAEtF;AAED,+FAA+F;AAC/F,wBAAgB,oBAAoB,CACnC,OAAO,EAAE,eAAe,EACxB,KAAK,EAAE,aAAa,EACpB,OAAO,EAAE,MAAM,GACb,gBAAgB,CAOlB;AAED,kFAAkF;AAClF,wBAAgB,qBAAqB,CACpC,OAAO,EAAE,eAAe,EACxB,KAAK,EAAE,aAAa,EACpB,mBAAmB,EAAE,MAAM,GACzB,gBAAgB,CASlB;AAED,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,GAAG,MAAM,CAKnF;AAED,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,QAAQ,GAAG,MAAM,CAO7D;AAED,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAO/E;AAED,2GAA2G;AAC3G,wBAAgB,gBAAgB,IAAI,MAAM,CAQzC;AAED,MAAM,WAAW,yBAAyB;IACzC,OAAO,EAAE,eAAe,CAAC;IACzB,KAAK,EAAE,aAAa,CAAC;IACrB,uDAAuD;IACvD,SAAS,EAAE,MAAM,CAAC;IAClB,GAAG,CAAC,EAAE,GAAG,CAAC;IACV,QAAQ,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,qBAAa,kBAAmB,SAAQ,SAAS;IAChD,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAkB;IAC1C,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAgB;IACtC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAA6B;IACvD,OAAO,CAAC,cAAc,CAAM;IAE5B,YAAY,OAAO,EAAE,yBAAyB,EAgB7C;IAED,OAAO,IAAI,IAAI,CAGd;IAED,OAAO,CAAC,MAAM;CAWd"}
|
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Collapsed
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* AskUserQuestionComponent. The response-building helpers here
|
|
6
|
-
* interactive-mode can turn ordinary composer text into the
|
|
2
|
+
* Collapsed widget for a pending async (waitForAnswer=false) question: it
|
|
3
|
+
* sits above the editor and shows the unanswered count with the idle
|
|
4
|
+
* countdown, the first unanswered question with its options, and every way
|
|
5
|
+
* into the full AskUserQuestionComponent. The response-building helpers here
|
|
6
|
+
* are pure so interactive-mode can turn ordinary composer text into the
|
|
7
|
+
* comment answer.
|
|
7
8
|
*/
|
|
8
|
-
import { Container, Text } from "@earendil-works/pi-tui";
|
|
9
|
+
import { Container, Text, TruncatedText } from "@earendil-works/pi-tui";
|
|
9
10
|
import { theme } from "../theme/theme.js";
|
|
11
|
+
import { ASK_USER_ANSWER_KEYBINDING } from "./ask-user-answer-key.js";
|
|
10
12
|
import { formatCountdownLabel } from "./ask-user-question-state.js";
|
|
11
13
|
import { CountdownTimer } from "./countdown-timer.js";
|
|
12
|
-
import {
|
|
14
|
+
import { keyText } from "./keybinding-hints.js";
|
|
13
15
|
/** Widget slot key used with `setWidget`; one pending async question at a time. */
|
|
14
16
|
export const ASK_USER_WIDGET_KEY = "ask-user";
|
|
15
|
-
|
|
16
|
-
export const ASK_USER_ANSWER_KEY = "alt+a";
|
|
17
|
+
const INDENT = " ";
|
|
17
18
|
function hasAnswer(answer) {
|
|
18
19
|
if (!answer)
|
|
19
20
|
return false;
|
|
@@ -45,21 +46,39 @@ export function buildTimedOutResponse(request, draft, autoResolvedAfterMs) {
|
|
|
45
46
|
autoResolvedAfterMs,
|
|
46
47
|
};
|
|
47
48
|
}
|
|
48
|
-
export function
|
|
49
|
+
export function renderStatusLine(unanswered, countdownLabel) {
|
|
49
50
|
const countdown = countdownLabel === "" ? "" : theme.fg("muted", ` · ${countdownLabel}`);
|
|
50
|
-
return (theme.fg("accent", theme.bold("?")) +
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
51
|
+
return (theme.fg("accent", theme.bold("?")) + theme.fg("text", ` Question pending (${unanswered} unanswered)`) + countdown);
|
|
52
|
+
}
|
|
53
|
+
export function renderQuestionLine(question) {
|
|
54
|
+
return (INDENT +
|
|
55
|
+
theme.fg("text", theme.bold(question.header)) +
|
|
56
|
+
theme.fg("muted", " — ") +
|
|
57
|
+
theme.fg("text", question.question));
|
|
58
|
+
}
|
|
59
|
+
export function renderOptionsLine(question, remaining) {
|
|
60
|
+
const parts = question.options.map((option, index) => theme.fg("dim", `${index + 1}`) + theme.fg("muted", ` ${option.label}`));
|
|
61
|
+
parts.push(theme.fg("muted", "own answer"));
|
|
62
|
+
if (remaining > 0)
|
|
63
|
+
parts.push(theme.fg("muted", `+${remaining} more question${remaining === 1 ? "" : "s"}`));
|
|
64
|
+
return INDENT + parts.join(theme.fg("muted", " · "));
|
|
65
|
+
}
|
|
66
|
+
/** Hint naming every way into the pending question; the shortcut segment follows the effective binding. */
|
|
67
|
+
export function renderAnswerHint() {
|
|
68
|
+
const shortcut = keyText(ASK_USER_ANSWER_KEYBINDING);
|
|
69
|
+
const keys = shortcut === "" ? "enter" : `enter or ${shortcut}`;
|
|
70
|
+
return [
|
|
71
|
+
theme.fg("dim", keys) + theme.fg("muted", " to answer"),
|
|
72
|
+
theme.fg("dim", "/answer"),
|
|
73
|
+
theme.fg("muted", "or just type your reply"),
|
|
74
|
+
].join(theme.fg("muted", " · "));
|
|
55
75
|
}
|
|
56
76
|
export class AskUserAsyncWidget extends Container {
|
|
57
77
|
constructor(options) {
|
|
58
78
|
super();
|
|
59
|
-
this.line = new Text("", 1, 0);
|
|
60
79
|
this.countdownLabel = "";
|
|
61
|
-
this.
|
|
62
|
-
this.
|
|
80
|
+
this.request = options.request;
|
|
81
|
+
this.draft = options.draft;
|
|
63
82
|
if (options.timeoutMs > 0) {
|
|
64
83
|
this.countdown = new CountdownTimer(options.timeoutMs, options.tui, (seconds) => {
|
|
65
84
|
this.countdownLabel = formatCountdownLabel(seconds * 1000);
|
|
@@ -68,15 +87,20 @@ export class AskUserAsyncWidget extends Container {
|
|
|
68
87
|
}
|
|
69
88
|
this.update();
|
|
70
89
|
}
|
|
71
|
-
setUnanswered(count) {
|
|
72
|
-
this.unanswered = count;
|
|
73
|
-
this.update();
|
|
74
|
-
}
|
|
75
90
|
dispose() {
|
|
76
91
|
this.countdown?.dispose();
|
|
92
|
+
super.dispose();
|
|
77
93
|
}
|
|
78
94
|
update() {
|
|
79
|
-
|
|
95
|
+
const pending = unansweredIds(this.request, this.draft);
|
|
96
|
+
const shown = this.request.questions.find((question) => question.id === pending[0]);
|
|
97
|
+
this.clear();
|
|
98
|
+
this.addChild(new Text(renderStatusLine(pending.length, this.countdownLabel), 1, 0));
|
|
99
|
+
if (shown) {
|
|
100
|
+
this.addChild(new TruncatedText(renderQuestionLine(shown), 1, 0));
|
|
101
|
+
this.addChild(new TruncatedText(renderOptionsLine(shown, pending.length - 1), 1, 0));
|
|
102
|
+
}
|
|
103
|
+
this.addChild(new Text(INDENT + renderAnswerHint(), 1, 0));
|
|
80
104
|
}
|
|
81
105
|
}
|
|
82
106
|
//# sourceMappingURL=ask-user-async-widget.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ask-user-async-widget.js","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-async-widget.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,SAAS,EAAE,IAAI,EAAY,MAAM,wBAAwB,CAAC;AAEnE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,oBAAoB,EAAsB,MAAM,8BAA8B,CAAC;AACxF,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAEnD,mFAAmF;AACnF,MAAM,CAAC,MAAM,mBAAmB,GAAG,UAAU,CAAC;AAC9C,iFAAiF;AACjF,MAAM,CAAC,MAAM,mBAAmB,GAAG,OAAO,CAAC;AAE3C,SAAS,SAAS,CAAC,MAAuD;IACzE,IAAI,CAAC,MAAM;QAAE,OAAO,KAAK,CAAC;IAC1B,IAAI,MAAM,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC;QAAE,OAAO,IAAI,CAAC;IAC5C,OAAO,CAAC,MAAM,CA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MAAM;QACb,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,uBAAuB,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC,CAAC;IAClF,CAAC;CACD","sourcesContent":["/**\n * Collapsed one-line widget for a pending async (waitForAnswer=false)\n * question: it sits above the editor, shows the unanswered count and the\n * idle countdown, and names the shortcut that expands the full\n * AskUserQuestionComponent. The response-building helpers here are pure so\n * interactive-mode can turn ordinary composer text into the comment answer.\n */\n\nimport { Container, Text, type TUI } from \"@earendil-works/pi-tui\";\nimport type { QuestionRequest, QuestionResponse } from \"../../../core/extensions/types.ts\";\nimport { theme } from \"../theme/theme.ts\";\nimport { formatCountdownLabel, type QuestionDraft } from \"./ask-user-question-state.ts\";\nimport { CountdownTimer } from \"./countdown-timer.ts\";\nimport { rawKeyHint } from \"./keybinding-hints.ts\";\n\n/** Widget slot key used with `setWidget`; one pending async question at a time. */\nexport const ASK_USER_WIDGET_KEY = \"ask-user\";\n/** Editor shortcut that expands the pending question into the full component. */\nexport const ASK_USER_ANSWER_KEY = \"alt+a\";\n\nfunction hasAnswer(answer: QuestionResponse[\"answers\"][string] | undefined): boolean {\n\tif (!answer) return false;\n\tif (answer.selected.length > 0) return true;\n\treturn (answer.text ?? \"\").trim() !== \"\";\n}\n\n/** Question ids the draft has not answered yet. */\nexport function unansweredIds(request: QuestionRequest, draft: QuestionDraft): string[] {\n\treturn request.questions.filter((question) => !hasAnswer(draft.answers?.[question.id])).map((q) => q.id);\n}\n\n/** Response for composer text typed while the question is pending: the text is the comment. */\nexport function buildCommentResponse(\n\trequest: QuestionRequest,\n\tdraft: QuestionDraft,\n\tcomment: string,\n): QuestionResponse {\n\treturn {\n\t\tstatus: \"comment-submitted\",\n\t\tanswers: draft.answers ?? {},\n\t\tcomment,\n\t\tunanswered: unansweredIds(request, draft),\n\t};\n}\n\n/** Response for an idle countdown that expired while the widget was collapsed. */\nexport function buildTimedOutResponse(\n\trequest: QuestionRequest,\n\tdraft: QuestionDraft,\n\tautoResolvedAfterMs: number,\n): QuestionResponse {\n\tconst comment = draft.comment?.trim();\n\treturn {\n\t\tstatus: \"timed_out\",\n\t\tanswers: draft.answers ?? {},\n\t\t...(comment ? { comment } : {}),\n\t\tunanswered: unansweredIds(request, draft),\n\t\tautoResolvedAfterMs,\n\t};\n}\n\nexport function renderAsyncQuestionLine(unanswered: number, countdownLabel: string): string {\n\tconst countdown = countdownLabel === \"\" ? \"\" : theme.fg(\"muted\", ` · ${countdownLabel}`);\n\treturn (\n\t\ttheme.fg(\"accent\", theme.bold(\"?\")) +\n\t\ttheme.fg(\"text\", ` Question pending (${unanswered} unanswered)`) +\n\t\ttheme.fg(\"muted\", \" - \") +\n\t\trawKeyHint(ASK_USER_ANSWER_KEY, \"to answer, or just type your reply\") +\n\t\tcountdown\n\t);\n}\n\nexport interface AskUserAsyncWidgetOptions {\n\tunanswered: number;\n\t/** Idle countdown shown in the line; 0 disables it. */\n\ttimeoutMs: number;\n\ttui?: TUI;\n\tonExpire: () => void;\n}\n\nexport class AskUserAsyncWidget extends Container {\n\tprivate readonly line = new Text(\"\", 1, 0);\n\tprivate readonly countdown: CountdownTimer | undefined;\n\tprivate unanswered: number;\n\tprivate countdownLabel = \"\";\n\n\tconstructor(options: AskUserAsyncWidgetOptions) {\n\t\tsuper();\n\t\tthis.unanswered = options.unanswered;\n\t\tthis.addChild(this.line);\n\t\tif (options.timeoutMs > 0) {\n\t\t\tthis.countdown = new CountdownTimer(\n\t\t\t\toptions.timeoutMs,\n\t\t\t\toptions.tui,\n\t\t\t\t(seconds) => {\n\t\t\t\t\tthis.countdownLabel = formatCountdownLabel(seconds * 1000);\n\t\t\t\t\tthis.update();\n\t\t\t\t},\n\t\t\t\toptions.onExpire,\n\t\t\t);\n\t\t}\n\t\tthis.update();\n\t}\n\n\tsetUnanswered(count: number): void {\n\t\tthis.unanswered = count;\n\t\tthis.update();\n\t}\n\n\tdispose(): void {\n\t\tthis.countdown?.dispose();\n\t}\n\n\tprivate update(): void {\n\t\tthis.line.setText(renderAsyncQuestionLine(this.unanswered, this.countdownLabel));\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"file":"ask-user-async-widget.js","sourceRoot":"","sources":["../../../../src/modes/interactive/components/ask-user-async-widget.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,aAAa,EAAY,MAAM,wBAAwB,CAAC;AAElF,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,EAAE,oBAAoB,EAAsB,MAAM,8BAA8B,CAAC;AACxF,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAEhD,mFAAmF;AACnF,MAAM,CAAC,MAAM,mBAAmB,GAAG,UAAU,CAAC;AAI9C,MAAM,MAAM,GAAG,IAAI,CAAC;AAEpB,SAAS,SAAS,CAAC,MAAuD;IACzE,IAAI,CAAC,MAAM;QAAE,OAAO,KAAK,CAAC;IAC1B,IAAI,MAAM,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC;QAAE,OAAO,IAAI,CAAC;IAC5C,OAAO,CAAC,MAAM,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,CAAC;AAC1C,CAAC;AAED,mDAAmD;AACnD,MAAM,UAAU,aAAa,CAAC,OAAwB,EAAE,KAAoB;IAC3E,OAAO,OAAO,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,SAAS,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;AAC1G,CAAC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AAC,QAAQ,CAAC,IAAI,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,MAAM,EAAE,IAAI,CAAC,cAAc,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;QACrF,IAAI,KAAK,EAAE,CAAC;YACX,IAAI,CAAC,QAAQ,CAAC,IAAI,aAAa,CAAC,kBAAkB,CAAC,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;YAClE,IAAI,CAAC,QAAQ,CAAC,IAAI,aAAa,CAAC,iBAAiB,CAAC,KAAK,EAAE,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;QACtF,CAAC;QACD,IAAI,CAAC,QAAQ,CAAC,IAAI,IAAI,CAAC,MAAM,GAAG,gBAAgB,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IAC5D,CAAC;CACD","sourcesContent":["/**\n * Collapsed widget for a pending async (waitForAnswer=false) question: it\n * sits above the editor and shows the unanswered count with the idle\n * countdown, the first unanswered question with its options, and every way\n * into the full AskUserQuestionComponent. The response-building helpers here\n * are pure so interactive-mode can turn ordinary composer text into the\n * comment answer.\n */\n\nimport { Container, Text, TruncatedText, type TUI } from \"@earendil-works/pi-tui\";\nimport type { QuestionRequest, QuestionResponse } from \"../../../core/extensions/types.ts\";\nimport { theme } from \"../theme/theme.ts\";\nimport { ASK_USER_ANSWER_KEYBINDING } from \"./ask-user-answer-key.ts\";\nimport { formatCountdownLabel, type QuestionDraft } from \"./ask-user-question-state.ts\";\nimport { CountdownTimer } from \"./countdown-timer.ts\";\nimport { keyText } from \"./keybinding-hints.ts\";\n\n/** Widget slot key used with `setWidget`; one pending async question at a time. */\nexport const ASK_USER_WIDGET_KEY = \"ask-user\";\n\ntype Question = QuestionRequest[\"questions\"][number];\n\nconst INDENT = \" \";\n\nfunction hasAnswer(answer: QuestionResponse[\"answers\"][string] | undefined): boolean {\n\tif (!answer) return false;\n\tif (answer.selected.length > 0) return true;\n\treturn (answer.text ?? \"\").trim() !== \"\";\n}\n\n/** Question ids the draft has not answered yet. */\nexport function unansweredIds(request: QuestionRequest, draft: QuestionDraft): string[] {\n\treturn request.questions.filter((question) => !hasAnswer(draft.answers?.[question.id])).map((q) => q.id);\n}\n\n/** Response for composer text typed while the question is pending: the text is the comment. */\nexport function buildCommentResponse(\n\trequest: QuestionRequest,\n\tdraft: QuestionDraft,\n\tcomment: string,\n): QuestionResponse {\n\treturn {\n\t\tstatus: \"comment-submitted\",\n\t\tanswers: draft.answers ?? {},\n\t\tcomment,\n\t\tunanswered: unansweredIds(request, draft),\n\t};\n}\n\n/** Response for an idle countdown that expired while the widget was collapsed. */\nexport function buildTimedOutResponse(\n\trequest: QuestionRequest,\n\tdraft: QuestionDraft,\n\tautoResolvedAfterMs: number,\n): QuestionResponse {\n\tconst comment = draft.comment?.trim();\n\treturn {\n\t\tstatus: \"timed_out\",\n\t\tanswers: draft.answers ?? {},\n\t\t...(comment ? { comment } : {}),\n\t\tunanswered: unansweredIds(request, draft),\n\t\tautoResolvedAfterMs,\n\t};\n}\n\nexport function renderStatusLine(unanswered: number, countdownLabel: string): string {\n\tconst countdown = countdownLabel === \"\" ? \"\" : theme.fg(\"muted\", ` · ${countdownLabel}`);\n\treturn (\n\t\ttheme.fg(\"accent\", theme.bold(\"?\")) + theme.fg(\"text\", ` Question pending (${unanswered} unanswered)`) + countdown\n\t);\n}\n\nexport function renderQuestionLine(question: Question): string {\n\treturn (\n\t\tINDENT +\n\t\ttheme.fg(\"text\", theme.bold(question.header)) +\n\t\ttheme.fg(\"muted\", \" — \") +\n\t\ttheme.fg(\"text\", question.question)\n\t);\n}\n\nexport function renderOptionsLine(question: Question, remaining: number): string {\n\tconst parts = question.options.map(\n\t\t(option, index) => theme.fg(\"dim\", `${index + 1}`) + theme.fg(\"muted\", ` ${option.label}`),\n\t);\n\tparts.push(theme.fg(\"muted\", \"own answer\"));\n\tif (remaining > 0) parts.push(theme.fg(\"muted\", `+${remaining} more question${remaining === 1 ? \"\" : \"s\"}`));\n\treturn INDENT + parts.join(theme.fg(\"muted\", \" · \"));\n}\n\n/** Hint naming every way into the pending question; the shortcut segment follows the effective binding. */\nexport function renderAnswerHint(): string {\n\tconst shortcut = keyText(ASK_USER_ANSWER_KEYBINDING);\n\tconst keys = shortcut === \"\" ? \"enter\" : `enter or ${shortcut}`;\n\treturn [\n\t\ttheme.fg(\"dim\", keys) + theme.fg(\"muted\", \" to answer\"),\n\t\ttheme.fg(\"dim\", \"/answer\"),\n\t\ttheme.fg(\"muted\", \"or just type your reply\"),\n\t].join(theme.fg(\"muted\", \" · \"));\n}\n\nexport interface AskUserAsyncWidgetOptions {\n\trequest: QuestionRequest;\n\tdraft: QuestionDraft;\n\t/** Idle countdown shown in the line; 0 disables it. */\n\ttimeoutMs: number;\n\ttui?: TUI;\n\tonExpire: () => void;\n}\n\nexport class AskUserAsyncWidget extends Container {\n\tprivate readonly request: QuestionRequest;\n\tprivate readonly draft: QuestionDraft;\n\tprivate readonly countdown: CountdownTimer | undefined;\n\tprivate countdownLabel = \"\";\n\n\tconstructor(options: AskUserAsyncWidgetOptions) {\n\t\tsuper();\n\t\tthis.request = options.request;\n\t\tthis.draft = options.draft;\n\t\tif (options.timeoutMs > 0) {\n\t\t\tthis.countdown = new CountdownTimer(\n\t\t\t\toptions.timeoutMs,\n\t\t\t\toptions.tui,\n\t\t\t\t(seconds) => {\n\t\t\t\t\tthis.countdownLabel = formatCountdownLabel(seconds * 1000);\n\t\t\t\t\tthis.update();\n\t\t\t\t},\n\t\t\t\toptions.onExpire,\n\t\t\t);\n\t\t}\n\t\tthis.update();\n\t}\n\n\tdispose(): void {\n\t\tthis.countdown?.dispose();\n\t\tsuper.dispose();\n\t}\n\n\tprivate update(): void {\n\t\tconst pending = unansweredIds(this.request, this.draft);\n\t\tconst shown = this.request.questions.find((question) => question.id === pending[0]);\n\t\tthis.clear();\n\t\tthis.addChild(new Text(renderStatusLine(pending.length, this.countdownLabel), 1, 0));\n\t\tif (shown) {\n\t\t\tthis.addChild(new TruncatedText(renderQuestionLine(shown), 1, 0));\n\t\t\tthis.addChild(new TruncatedText(renderOptionsLine(shown, pending.length - 1), 1, 0));\n\t\t}\n\t\tthis.addChild(new Text(INDENT + renderAnswerHint(), 1, 0));\n\t}\n}\n"]}
|
|
@@ -15,6 +15,7 @@ export declare class AssistantMessageComponent extends Container {
|
|
|
15
15
|
private hasToolCalls;
|
|
16
16
|
private expanded;
|
|
17
17
|
private isStreaming;
|
|
18
|
+
private thinkingVisibilityOverrides;
|
|
18
19
|
constructor(message?: AssistantMessage, hideThinkingBlock?: boolean, markdownTheme?: MarkdownTheme, hiddenThinkingLabel?: string, outputPad?: number, markdownTransformers?: readonly MarkdownTransformer[]);
|
|
19
20
|
invalidate(): void;
|
|
20
21
|
setHideThinkingBlock(hide: boolean): void;
|
|
@@ -25,6 +26,12 @@ export declare class AssistantMessageComponent extends Container {
|
|
|
25
26
|
updateContent(message: AssistantMessage, isStreaming?: boolean): void;
|
|
26
27
|
private reconcileRenderDescriptors;
|
|
27
28
|
private createRenderChild;
|
|
29
|
+
/**
|
|
30
|
+
* Left-clicking a thinking run toggles that run between its label and its body (upstream
|
|
31
|
+
* 71026970a). The mouse handler is attached to the Markdown/Text child itself so the
|
|
32
|
+
* incremental reconciler still sees the same child types it updates in place.
|
|
33
|
+
*/
|
|
34
|
+
private withThinkingToggle;
|
|
28
35
|
private createMessageSignature;
|
|
29
36
|
private cacheRender;
|
|
30
37
|
private refreshContent;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assistant-message.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/assistant-message.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAkB,SAAS,EAAY,KAAK,aAAa,EAAgB,MAAM,wBAAwB,CAAC;AAC/G,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAC;AAc7E,qBAAa,yBAA0B,SAAQ,SAAS;IACvD,OAAO,CAAC,WAAW,CAAC,CAAmF;IACvG,OAAO,CAAC,gBAAgB,CAAY;IACpC,OAAO,CAAC,iBAAiB,CAAU;IACnC,OAAO,CAAC,aAAa,CAAgB;IACrC,OAAO,CAAC,mBAAmB,CAAS;IACpC,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,oBAAoB,CAAiC;IAC7D,OAAO,CAAC,WAAW,CAAC,CAAmB;IACvC,OAAO,CAAC,oBAAoB,CAAC,CAAS;IACtC,OAAO,CAAC,iBAAiB,CAA4C;IACrE,OAAO,CAAC,YAAY,CAAS;IAC7B,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,WAAW,CAAS;
|
|
1
|
+
{"version":3,"file":"assistant-message.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/assistant-message.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAkB,SAAS,EAAY,KAAK,aAAa,EAAgB,MAAM,wBAAwB,CAAC;AAC/G,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAC;AAc7E,qBAAa,yBAA0B,SAAQ,SAAS;IACvD,OAAO,CAAC,WAAW,CAAC,CAAmF;IACvG,OAAO,CAAC,gBAAgB,CAAY;IACpC,OAAO,CAAC,iBAAiB,CAAU;IACnC,OAAO,CAAC,aAAa,CAAgB;IACrC,OAAO,CAAC,mBAAmB,CAAS;IACpC,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,oBAAoB,CAAiC;IAC7D,OAAO,CAAC,WAAW,CAAC,CAAmB;IACvC,OAAO,CAAC,oBAAoB,CAAC,CAAS;IACtC,OAAO,CAAC,iBAAiB,CAA4C;IACrE,OAAO,CAAC,YAAY,CAAS;IAC7B,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,2BAA2B,CAA8B;IAEjE,YACC,OAAO,CAAC,EAAE,gBAAgB,EAC1B,iBAAiB,UAAQ,EACzB,aAAa,GAAE,aAAkC,EACjD,mBAAmB,SAAgB,EACnC,SAAS,SAAI,EACb,oBAAoB,GAAE,SAAS,mBAAmB,EAAO,EAezD;IAEQ,UAAU,IAAI,IAAI,CAK1B;IAED,oBAAoB,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,CAKxC;IAED,sBAAsB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAI1C;IAED,WAAW,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAInC;IAED,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAIlC;IAEQ,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAgBvC;IAED,aAAa,CAAC,OAAO,EAAE,gBAAgB,EAAE,WAAW,UAAmB,GAAG,IAAI,CAqB7E;IAED,OAAO,CAAC,0BAA0B;IAqBlC,OAAO,CAAC,iBAAiB;IA0CzB;;;;OAIG;IACH,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,sBAAsB;IAW9B,OAAO,CAAC,WAAW;IAInB,OAAO,CAAC,cAAc;CAKtB"}
|
|
@@ -16,6 +16,7 @@ export class AssistantMessageComponent extends Container {
|
|
|
16
16
|
this.hasToolCalls = false;
|
|
17
17
|
this.expanded = false;
|
|
18
18
|
this.isStreaming = false;
|
|
19
|
+
this.thinkingVisibilityOverrides = new Map();
|
|
19
20
|
this.hideThinkingBlock = hideThinkingBlock;
|
|
20
21
|
this.markdownTheme = markdownTheme;
|
|
21
22
|
this.hiddenThinkingLabel = hiddenThinkingLabel;
|
|
@@ -37,6 +38,7 @@ export class AssistantMessageComponent extends Container {
|
|
|
37
38
|
if (this.hideThinkingBlock === hide)
|
|
38
39
|
return;
|
|
39
40
|
this.hideThinkingBlock = hide;
|
|
41
|
+
this.thinkingVisibilityOverrides.clear();
|
|
40
42
|
this.refreshContent();
|
|
41
43
|
}
|
|
42
44
|
setHiddenThinkingLabel(label) {
|
|
@@ -89,6 +91,7 @@ export class AssistantMessageComponent extends Container {
|
|
|
89
91
|
expanded: this.expanded,
|
|
90
92
|
hiddenThinkingLabel: this.hiddenThinkingLabel,
|
|
91
93
|
hideThinkingBlock: this.hideThinkingBlock,
|
|
94
|
+
thinkingVisibilityOverrides: this.thinkingVisibilityOverrides,
|
|
92
95
|
hasToolCalls: this.hasToolCalls,
|
|
93
96
|
});
|
|
94
97
|
this.reconcileRenderDescriptors(descriptors);
|
|
@@ -126,13 +129,14 @@ export class AssistantMessageComponent extends Container {
|
|
|
126
129
|
transform: createMarkdownTransform("assistant", this.isStreaming, this.markdownTransformers),
|
|
127
130
|
});
|
|
128
131
|
case "thinking-md":
|
|
129
|
-
return new Markdown(descriptor.text, this.outputPad, 0, this.markdownTheme, {
|
|
132
|
+
return this.withThinkingToggle(new Markdown(descriptor.text, this.outputPad, 0, this.markdownTheme, {
|
|
130
133
|
color: (text) => theme.fg("thinkingText", text),
|
|
131
134
|
italic: true,
|
|
132
135
|
}, {
|
|
133
136
|
transform: createMarkdownTransform("assistant-thinking", this.isStreaming, this.markdownTransformers),
|
|
134
|
-
});
|
|
137
|
+
}), descriptor);
|
|
135
138
|
case "thinking-label":
|
|
139
|
+
return this.withThinkingToggle(new Text(descriptor.text, this.outputPad, 0), descriptor);
|
|
136
140
|
case "error-text":
|
|
137
141
|
return new Text(descriptor.text, this.outputPad, 0);
|
|
138
142
|
case "provider-native-summary":
|
|
@@ -143,11 +147,31 @@ export class AssistantMessageComponent extends Container {
|
|
|
143
147
|
return assertNever(descriptor.kind);
|
|
144
148
|
}
|
|
145
149
|
}
|
|
150
|
+
/**
|
|
151
|
+
* Left-clicking a thinking run toggles that run between its label and its body (upstream
|
|
152
|
+
* 71026970a). The mouse handler is attached to the Markdown/Text child itself so the
|
|
153
|
+
* incremental reconciler still sees the same child types it updates in place.
|
|
154
|
+
*/
|
|
155
|
+
withThinkingToggle(component, descriptor) {
|
|
156
|
+
const runIndex = descriptor.thinkingRun;
|
|
157
|
+
if (runIndex === undefined)
|
|
158
|
+
return component;
|
|
159
|
+
component.handleMouse = (event) => {
|
|
160
|
+
if (event.type !== "click" || event.button !== "left")
|
|
161
|
+
return undefined;
|
|
162
|
+
const hidden = this.thinkingVisibilityOverrides.get(runIndex) ?? this.hideThinkingBlock;
|
|
163
|
+
this.thinkingVisibilityOverrides.set(runIndex, !hidden);
|
|
164
|
+
this.refreshContent();
|
|
165
|
+
return { handled: true };
|
|
166
|
+
};
|
|
167
|
+
return component;
|
|
168
|
+
}
|
|
146
169
|
createMessageSignature(message) {
|
|
147
170
|
return createBoundedRenderSignature({
|
|
148
171
|
content: message.content,
|
|
149
172
|
hiddenThinkingLabel: this.hiddenThinkingLabel,
|
|
150
173
|
hideThinkingBlock: this.hideThinkingBlock,
|
|
174
|
+
thinkingVisibilityOverrides: [...this.thinkingVisibilityOverrides],
|
|
151
175
|
errorState: [message.diagnostics, message.errorMessage],
|
|
152
176
|
stopReason: message.stopReason,
|
|
153
177
|
});
|