@ashx-j/lunr 0.2.26 → 0.2.27
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 +16 -1
- package/LICENSE +22 -0
- package/dist/builtin-extensions/ashxj-thinking.d.ts +1 -1
- package/dist/builtin-extensions/ashxj-thinking.d.ts.map +1 -1
- package/dist/builtin-extensions/ashxj-thinking.js +1 -1
- package/dist/builtin-extensions/ashxj-thinking.js.map +1 -1
- package/dist/builtin-extensions/ashxj-tui.d.ts +11 -1
- package/dist/builtin-extensions/ashxj-tui.d.ts.map +1 -1
- package/dist/builtin-extensions/ashxj-tui.js +6 -10
- package/dist/builtin-extensions/ashxj-tui.js.map +1 -1
- package/dist/builtin-extensions/lunr-cron.d.ts +4 -5
- package/dist/builtin-extensions/lunr-cron.d.ts.map +1 -1
- package/dist/builtin-extensions/lunr-cron.js +94 -108
- package/dist/builtin-extensions/lunr-cron.js.map +1 -1
- package/dist/builtin-extensions/lunr-local-providers/local-servers.d.ts.map +1 -1
- package/dist/builtin-extensions/lunr-local-providers/local-servers.js +3 -1
- package/dist/builtin-extensions/lunr-local-providers/local-servers.js.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/commands.d.ts.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/commands.js +2 -2
- package/dist/builtin-extensions/narumiruna-pi-goal/src/commands.js.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/goal.d.ts.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/goal.js +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/goal.js.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/runtime.d.ts.map +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/runtime.js +1 -1
- package/dist/builtin-extensions/narumiruna-pi-goal/src/runtime.js.map +1 -1
- package/dist/builtin-extensions/pi-intercom/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-intercom/index.js +2 -2
- package/dist/builtin-extensions/pi-intercom/index.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/bemol-extension/index.d.ts +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/bemol-extension/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/bemol-extension/index.js +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/bemol-extension/index.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/index.js +1 -15
- package/dist/builtin-extensions/pi-lsp-extension/src/index.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-client.d.ts +6 -0
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-client.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-client.js +187 -132
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-client.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-manager.d.ts +8 -0
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-manager.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-manager.js +142 -112
- package/dist/builtin-extensions/pi-lsp-extension/src/lsp-manager.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tools/code-rewrite.d.ts +12 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tools/code-rewrite.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tools/code-rewrite.js +14 -7
- package/dist/builtin-extensions/pi-lsp-extension/src/tools/code-rewrite.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/rewrite-engine.d.ts +11 -3
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/rewrite-engine.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/rewrite-engine.js +67 -41
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/rewrite-engine.js.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/search-engine.d.ts +4 -2
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/search-engine.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/search-engine.js +3 -0
- package/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/search-engine.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/commands.d.ts +2 -1
- package/dist/builtin-extensions/pi-mcp-adapter/commands.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/commands.js +6 -6
- package/dist/builtin-extensions/pi-mcp-adapter/commands.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/config.d.ts +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/config.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/config.js +11 -5
- package/dist/builtin-extensions/pi-mcp-adapter/config.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/direct-tool-executor.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/direct-tool-executor.js +2 -2
- package/dist/builtin-extensions/pi-mcp-adapter/direct-tool-executor.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/host-html-template.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/host-html-template.js +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/host-html-template.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/index.js +48 -40
- package/dist/builtin-extensions/pi-mcp-adapter/index.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/init.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/init.js +3 -1
- package/dist/builtin-extensions/pi-mcp-adapter/init.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-auth-flow.d.ts +12 -40
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-auth-flow.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-auth-flow.js +166 -235
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-auth-flow.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-callback-server.d.ts +5 -0
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-callback-server.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-callback-server.js +43 -13
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-callback-server.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-oauth-provider.d.ts +14 -3
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-oauth-provider.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-oauth-provider.js +73 -21
- package/dist/builtin-extensions/pi-mcp-adapter/mcp-oauth-provider.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/proxy-modes.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/proxy-modes.js +4 -4
- package/dist/builtin-extensions/pi-mcp-adapter/proxy-modes.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/server-manager.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/server-manager.js +2 -2
- package/dist/builtin-extensions/pi-mcp-adapter/server-manager.js.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/state.d.ts +2 -0
- package/dist/builtin-extensions/pi-mcp-adapter/state.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-mcp-adapter/state.js.map +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/index.d.ts +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/index.js +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/index.js.map +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/models.d.ts +11 -5
- package/dist/builtin-extensions/pi-ollama-cloud/models.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-ollama-cloud/models.js +12 -32
- package/dist/builtin-extensions/pi-ollama-cloud/models.js.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/index.js +5 -3
- package/dist/builtin-extensions/pi-prompt-template-model/index.js.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/prompt-loader.d.ts +2 -1
- package/dist/builtin-extensions/pi-prompt-template-model/prompt-loader.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/prompt-loader.js +21 -12
- package/dist/builtin-extensions/pi-prompt-template-model/prompt-loader.js.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/tool-manager.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-prompt-template-model/tool-manager.js +7 -24
- package/dist/builtin-extensions/pi-prompt-template-model/tool-manager.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/extension/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/extension/index.js +39 -77
- package/dist/builtin-extensions/pi-subagents/src/extension/index.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/notify.d.ts +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/notify.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/notify.js +15 -31
- package/dist/builtin-extensions/pi-subagents/src/runs/background/notify.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/result-watcher.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/result-watcher.js +7 -2
- package/dist/builtin-extensions/pi-subagents/src/runs/background/result-watcher.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/subagent-runner.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/background/subagent-runner.js +10 -2
- package/dist/builtin-extensions/pi-subagents/src/runs/background/subagent-runner.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/chain-execution.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/chain-execution.js +8 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/chain-execution.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/execution.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/execution.js +106 -24
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/execution.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/subagent-executor.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/subagent-executor.js +25 -5
- package/dist/builtin-extensions/pi-subagents/src/runs/foreground/subagent-executor.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/model-fallback.d.ts +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/model-fallback.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/model-fallback.js +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/model-fallback.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/parallel-utils.d.ts +7 -8
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/parallel-utils.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/parallel-utils.js +60 -32
- package/dist/builtin-extensions/pi-subagents/src/runs/shared/parallel-utils.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/shared/utils.d.ts +1 -1
- package/dist/builtin-extensions/pi-subagents/src/shared/utils.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/shared/utils.js +15 -5
- package/dist/builtin-extensions/pi-subagents/src/shared/utils.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/slash/prompt-workflows.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/slash/prompt-workflows.js +4 -3
- package/dist/builtin-extensions/pi-subagents/src/slash/prompt-workflows.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/tui/render.d.ts +1 -1
- package/dist/builtin-extensions/pi-subagents/src/tui/render.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/tui/render.js +17 -8
- package/dist/builtin-extensions/pi-subagents/src/tui/render.js.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/watchdog/review.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-subagents/src/watchdog/review.js +3 -3
- package/dist/builtin-extensions/pi-subagents/src/watchdog/review.js.map +1 -1
- package/dist/builtin-extensions/pi-tps.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-tps.js +20 -17
- package/dist/builtin-extensions/pi-tps.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/activity.d.ts +1 -0
- package/dist/builtin-extensions/pi-web-access/activity.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/activity.js +27 -5
- package/dist/builtin-extensions/pi-web-access/activity.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/bounded-body.d.ts +3 -0
- package/dist/builtin-extensions/pi-web-access/bounded-body.d.ts.map +1 -0
- package/dist/builtin-extensions/pi-web-access/bounded-body.js +43 -0
- package/dist/builtin-extensions/pi-web-access/bounded-body.js.map +1 -0
- package/dist/builtin-extensions/pi-web-access/content-page.d.ts +24 -0
- package/dist/builtin-extensions/pi-web-access/content-page.d.ts.map +1 -0
- package/dist/builtin-extensions/pi-web-access/content-page.js +57 -0
- package/dist/builtin-extensions/pi-web-access/content-page.js.map +1 -0
- package/dist/builtin-extensions/pi-web-access/extract.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/extract.js +7 -2
- package/dist/builtin-extensions/pi-web-access/extract.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/github-extract.d.ts +0 -1
- package/dist/builtin-extensions/pi-web-access/github-extract.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/github-extract.js +147 -36
- package/dist/builtin-extensions/pi-web-access/github-extract.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/index.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/index.js +48 -73
- package/dist/builtin-extensions/pi-web-access/index.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/session-cleanup.d.ts +12 -4
- package/dist/builtin-extensions/pi-web-access/session-cleanup.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/session-cleanup.js +35 -12
- package/dist/builtin-extensions/pi-web-access/session-cleanup.js.map +1 -1
- package/dist/builtin-extensions/pi-web-access/storage.d.ts +9 -6
- package/dist/builtin-extensions/pi-web-access/storage.d.ts.map +1 -1
- package/dist/builtin-extensions/pi-web-access/storage.js +36 -24
- package/dist/builtin-extensions/pi-web-access/storage.js.map +1 -1
- package/dist/builtin-extensions/simple-pi-memory.d.ts +1 -1
- package/dist/builtin-extensions/simple-pi-memory.d.ts.map +1 -1
- package/dist/builtin-extensions/simple-pi-memory.js +1 -1
- package/dist/builtin-extensions/simple-pi-memory.js.map +1 -1
- package/dist/cli/install-cli.d.ts.map +1 -1
- package/dist/cli/install-cli.js +38 -30
- package/dist/cli/install-cli.js.map +1 -1
- package/dist/core/agent-session-runtime.d.ts +13 -0
- package/dist/core/agent-session-runtime.d.ts.map +1 -1
- package/dist/core/agent-session-runtime.js +75 -11
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session-services.d.ts +1 -0
- package/dist/core/agent-session-services.d.ts.map +1 -1
- package/dist/core/agent-session-services.js +1 -0
- package/dist/core/agent-session-services.js.map +1 -1
- package/dist/core/agent-session.d.ts +40 -6
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +309 -76
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/browser/runtime.d.ts +2 -0
- package/dist/core/browser/runtime.d.ts.map +1 -1
- package/dist/core/browser/runtime.js +80 -45
- package/dist/core/browser/runtime.js.map +1 -1
- package/dist/core/browser/setup.d.ts.map +1 -1
- package/dist/core/browser/setup.js +12 -1
- package/dist/core/browser/setup.js.map +1 -1
- package/dist/core/computer-use/adapter.d.ts.map +1 -1
- package/dist/core/computer-use/adapter.js +7 -2
- package/dist/core/computer-use/adapter.js.map +1 -1
- package/dist/core/computer-use/image.d.ts.map +1 -1
- package/dist/core/computer-use/image.js +17 -5
- package/dist/core/computer-use/image.js.map +1 -1
- package/dist/core/computer-use/schemas.d.ts.map +1 -1
- package/dist/core/computer-use/schemas.js +23 -6
- package/dist/core/computer-use/schemas.js.map +1 -1
- package/dist/core/computer-use/workflow.d.ts.map +1 -1
- package/dist/core/computer-use/workflow.js +459 -119
- package/dist/core/computer-use/workflow.js.map +1 -1
- package/dist/core/cron/jobs.d.ts +26 -8
- package/dist/core/cron/jobs.d.ts.map +1 -1
- package/dist/core/cron/jobs.js +357 -232
- package/dist/core/cron/jobs.js.map +1 -1
- package/dist/core/cron/origin-context.d.ts +1 -0
- package/dist/core/cron/origin-context.d.ts.map +1 -1
- package/dist/core/cron/origin-context.js.map +1 -1
- package/dist/core/cron/scheduler.d.ts +22 -17
- package/dist/core/cron/scheduler.d.ts.map +1 -1
- package/dist/core/cron/scheduler.js +153 -73
- package/dist/core/cron/scheduler.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +1 -0
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +8 -0
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/types.d.ts +8 -0
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/footer-data-provider.d.ts +4 -0
- package/dist/core/footer-data-provider.d.ts.map +1 -1
- package/dist/core/footer-data-provider.js +22 -1
- package/dist/core/footer-data-provider.js.map +1 -1
- package/dist/core/large-subagent-launch.d.ts +1 -1
- package/dist/core/large-subagent-launch.d.ts.map +1 -1
- package/dist/core/large-subagent-launch.js +7 -7
- package/dist/core/large-subagent-launch.js.map +1 -1
- package/dist/core/model-registry.d.ts +2 -0
- package/dist/core/model-registry.d.ts.map +1 -1
- package/dist/core/model-registry.js +5 -0
- package/dist/core/model-registry.js.map +1 -1
- package/dist/core/model-runtime.d.ts +4 -1
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +40 -4
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/package-manager.d.ts.map +1 -1
- package/dist/core/package-manager.js.map +1 -1
- package/dist/core/permissions.d.ts +3 -3
- package/dist/core/permissions.d.ts.map +1 -1
- package/dist/core/permissions.js +11 -35
- package/dist/core/permissions.js.map +1 -1
- package/dist/core/plan-mode.d.ts +5 -13
- package/dist/core/plan-mode.d.ts.map +1 -1
- package/dist/core/plan-mode.js +126 -116
- package/dist/core/plan-mode.js.map +1 -1
- package/dist/core/project-trust.d.ts.map +1 -1
- package/dist/core/project-trust.js +1 -1
- package/dist/core/project-trust.js.map +1 -1
- package/dist/core/prompt-resource-bridge.d.ts +12 -0
- package/dist/core/prompt-resource-bridge.d.ts.map +1 -0
- package/dist/core/prompt-resource-bridge.js +9 -0
- package/dist/core/prompt-resource-bridge.js.map +1 -0
- package/dist/core/protected-targets.d.ts +6 -0
- package/dist/core/protected-targets.d.ts.map +1 -0
- package/dist/core/protected-targets.js +45 -0
- package/dist/core/protected-targets.js.map +1 -0
- package/dist/core/resource-loader.d.ts.map +1 -1
- package/dist/core/resource-loader.js +7 -0
- package/dist/core/resource-loader.js.map +1 -1
- package/dist/core/rollback.d.ts +19 -3
- package/dist/core/rollback.d.ts.map +1 -1
- package/dist/core/rollback.js +172 -56
- package/dist/core/rollback.js.map +1 -1
- package/dist/core/runtime-credentials.d.ts +3 -0
- package/dist/core/runtime-credentials.d.ts.map +1 -1
- package/dist/core/runtime-credentials.js +14 -1
- package/dist/core/runtime-credentials.js.map +1 -1
- package/dist/core/sdk.d.ts +3 -0
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +1 -0
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-manager.d.ts +6 -0
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +95 -32
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/session-ownership.d.ts.map +1 -1
- package/dist/core/session-ownership.js +8 -3
- package/dist/core/session-ownership.js.map +1 -1
- package/dist/core/session-retention.d.ts.map +1 -1
- package/dist/core/session-retention.js +18 -7
- package/dist/core/session-retention.js.map +1 -1
- package/dist/core/session-startup-settings.d.ts +10 -0
- package/dist/core/session-startup-settings.d.ts.map +1 -0
- package/dist/core/session-startup-settings.js +70 -0
- package/dist/core/session-startup-settings.js.map +1 -0
- package/dist/core/subscriptions.d.ts +16 -7
- package/dist/core/subscriptions.d.ts.map +1 -1
- package/dist/core/subscriptions.js +96 -55
- package/dist/core/subscriptions.js.map +1 -1
- package/dist/core/trust-manager.d.ts +2 -1
- package/dist/core/trust-manager.d.ts.map +1 -1
- package/dist/core/trust-manager.js +6 -1
- package/dist/core/trust-manager.js.map +1 -1
- package/dist/core/update-check.d.ts.map +1 -1
- package/dist/core/update-check.js.map +1 -1
- package/dist/core/usage-adapters/kimi-coding.d.ts +2 -2
- package/dist/core/usage-adapters/kimi-coding.d.ts.map +1 -1
- package/dist/core/usage-adapters/kimi-coding.js +2 -2
- package/dist/core/usage-adapters/kimi-coding.js.map +1 -1
- package/dist/core/usage-adapters/openai-codex.d.ts +3 -2
- package/dist/core/usage-adapters/openai-codex.d.ts.map +1 -1
- package/dist/core/usage-adapters/openai-codex.js +3 -3
- package/dist/core/usage-adapters/openai-codex.js.map +1 -1
- package/dist/core/usage-adapters/xai.d.ts +2 -2
- package/dist/core/usage-adapters/xai.d.ts.map +1 -1
- package/dist/core/usage-adapters/xai.js +3 -3
- package/dist/core/usage-adapters/xai.js.map +1 -1
- package/dist/core/usage-adapters/zai.d.ts +2 -2
- package/dist/core/usage-adapters/zai.d.ts.map +1 -1
- package/dist/core/usage-adapters/zai.js +2 -2
- package/dist/core/usage-adapters/zai.js.map +1 -1
- package/dist/core/usage-service.d.ts +9 -2
- package/dist/core/usage-service.d.ts.map +1 -1
- package/dist/core/usage-service.js +95 -50
- package/dist/core/usage-service.js.map +1 -1
- package/dist/gateway/agent-bridge.d.ts +9 -1
- package/dist/gateway/agent-bridge.d.ts.map +1 -1
- package/dist/gateway/agent-bridge.js +91 -37
- package/dist/gateway/agent-bridge.js.map +1 -1
- package/dist/gateway/buttons.d.ts +8 -1
- package/dist/gateway/buttons.d.ts.map +1 -1
- package/dist/gateway/buttons.js +76 -18
- package/dist/gateway/buttons.js.map +1 -1
- package/dist/gateway/commands.d.ts +1 -0
- package/dist/gateway/commands.d.ts.map +1 -1
- package/dist/gateway/commands.js +10 -4
- package/dist/gateway/commands.js.map +1 -1
- package/dist/gateway/cron.d.ts +12 -11
- package/dist/gateway/cron.d.ts.map +1 -1
- package/dist/gateway/cron.js +65 -56
- package/dist/gateway/cron.js.map +1 -1
- package/dist/gateway/index.d.ts.map +1 -1
- package/dist/gateway/index.js +2 -1
- package/dist/gateway/index.js.map +1 -1
- package/dist/gateway/mobile-commands.d.ts +1 -0
- package/dist/gateway/mobile-commands.d.ts.map +1 -1
- package/dist/gateway/mobile-commands.js +56 -14
- package/dist/gateway/mobile-commands.js.map +1 -1
- package/dist/gateway/presenter.d.ts +12 -2
- package/dist/gateway/presenter.d.ts.map +1 -1
- package/dist/gateway/presenter.js +73 -38
- package/dist/gateway/presenter.js.map +1 -1
- package/dist/gateway/router.d.ts +2 -2
- package/dist/gateway/router.d.ts.map +1 -1
- package/dist/gateway/router.js +17 -2
- package/dist/gateway/router.js.map +1 -1
- package/dist/gateway/service.d.ts +2 -0
- package/dist/gateway/service.d.ts.map +1 -1
- package/dist/gateway/service.js +153 -0
- package/dist/gateway/service.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +86 -33
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +6 -4
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/copyable-text.d.ts.map +1 -1
- package/dist/modes/interactive/components/copyable-text.js +3 -2
- package/dist/modes/interactive/components/copyable-text.js.map +1 -1
- package/dist/modes/interactive/components/extension-editor.d.ts.map +1 -1
- package/dist/modes/interactive/components/extension-editor.js +1 -1
- package/dist/modes/interactive/components/extension-editor.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +2 -2
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +96 -109
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/smooth-streaming.d.ts.map +1 -1
- package/dist/modes/interactive/smooth-streaming.js.map +1 -1
- package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-mode.js +2 -1
- package/dist/modes/rpc/rpc-mode.js.map +1 -1
- package/dist/node-runtime/{adapter-VFG7WNPX.js → adapter-247RTYLS.js} +4 -5
- package/dist/node-runtime/agent-session-services-KDMSPQDY.js +53 -0
- package/dist/node-runtime/{brave-UWDA3I22.js → brave-2AFFAXNN.js} +1 -1
- package/dist/node-runtime/{builtin-extensions-I2HIFEMY.js → builtin-extensions-OX6KELNX.js} +8 -7
- package/dist/node-runtime/{chunk-QH6YL7VK.js → chunk-252ZVPPF.js} +3 -3
- package/dist/node-runtime/{chunk-PCEW76PM.js → chunk-2OIPYKLZ.js} +6 -6
- package/dist/node-runtime/{chunk-XBWPBZBN.js → chunk-2SWW7KMW.js} +1 -1
- package/dist/node-runtime/{chunk-UQUCFAJ3.js → chunk-2VIW3IMF.js} +40 -7
- package/dist/node-runtime/{chunk-UOEDI7RP.js → chunk-4KNKQGHM.js} +2 -2
- package/dist/node-runtime/{chunk-FQMM2EZ2.js → chunk-64XTQNLA.js} +29 -7
- package/dist/node-runtime/{chunk-SPVDBUOS.js → chunk-6O3IW3IA.js} +2 -2
- package/dist/node-runtime/{chunk-5ZQXRPMC.js → chunk-6ZZHGUSA.js} +2 -2
- package/dist/node-runtime/chunk-A2WO6WIN.js +1197 -0
- package/dist/node-runtime/{chunk-WIF24I7G.js → chunk-APVM5NEU.js} +149 -144
- package/dist/node-runtime/{chunk-RCR3XAQY.js → chunk-AYHH7YSD.js} +177 -144
- package/dist/node-runtime/{chunk-LWYIVUGV.js → chunk-B2IBAXNX.js} +48 -31
- package/dist/node-runtime/{chunk-M3LZLQW2.js → chunk-BDRGN3L2.js} +1 -0
- package/dist/node-runtime/{chunk-GJ2RDBRL.js → chunk-BYC6RKCN.js} +4 -2
- package/dist/node-runtime/{chunk-UVWCDQYF.js → chunk-C3P6Q3B2.js} +455 -278
- package/dist/node-runtime/{chunk-SN2KSMPQ.js → chunk-DQSCFU7R.js} +13 -7
- package/dist/node-runtime/{chunk-4SBQAI4T.js → chunk-EBLAZVSA.js} +2058 -73
- package/dist/node-runtime/{chunk-2KIPT4HJ.js → chunk-EPR2F3GU.js} +68 -20
- package/dist/node-runtime/{chunk-CSFI6YXL.js → chunk-ES6PBSIE.js} +1 -1
- package/dist/node-runtime/{chunk-IF24A3FH.js → chunk-EVM653DD.js} +4 -4
- package/dist/node-runtime/{chunk-HTFRRDSF.js → chunk-F2SMQ6ES.js} +3 -2
- package/dist/node-runtime/chunk-F2V2F4ZG.js +114 -0
- package/dist/node-runtime/{chunk-IKU6Y7DL.js → chunk-FE3WZI7F.js} +9 -6
- package/dist/node-runtime/{chunk-GYIXXQAO.js → chunk-FIRA54AC.js} +2 -5
- package/dist/node-runtime/{chunk-6VYZ5UFP.js → chunk-FLGEEH27.js} +1 -1
- package/dist/node-runtime/{chunk-5EFIU3OM.js → chunk-FTKEZL27.js} +1 -1
- package/dist/node-runtime/{chunk-RGQAEOM5.js → chunk-FYIFPFXE.js} +23 -6
- package/dist/node-runtime/{chunk-HMBGROQK.js → chunk-GLDXBBL6.js} +3 -3
- package/dist/node-runtime/{chunk-KWA4OC2J.js → chunk-H6YBCWKG.js} +1 -1
- package/dist/node-runtime/{chunk-2MI5OPMN.js → chunk-HNNHHJAB.js} +68 -50
- package/dist/node-runtime/{chunk-I74LN5JG.js → chunk-HUD2RFJW.js} +2 -2
- package/dist/node-runtime/{chunk-I54LGHWM.js → chunk-I2H5QMWW.js} +3 -3
- package/dist/node-runtime/{chunk-XHIRAZ26.js → chunk-IAZSK7KK.js} +1 -1
- package/dist/node-runtime/{chunk-X3PGBLQ7.js → chunk-IHHTWSXN.js} +9 -9
- package/dist/node-runtime/{chunk-DAPBPCBP.js → chunk-IPP5BIV5.js} +25 -3
- package/dist/node-runtime/{chunk-QFWG2RVL.js → chunk-IXG6F4NT.js} +11 -0
- package/dist/node-runtime/{chunk-RDDAZOMU.js → chunk-JL4HYQXK.js} +1 -1
- package/dist/node-runtime/{chunk-CDVHZOOK.js → chunk-JQYNHAKX.js} +1 -1
- package/dist/node-runtime/{chunk-L24TPBS4.js → chunk-JWEVT363.js} +37 -29
- package/dist/node-runtime/{chunk-2HMIRK7W.js → chunk-LHV3V67B.js} +5 -5
- package/dist/node-runtime/{chunk-UAEOTO52.js → chunk-MNQXDFPV.js} +6 -2
- package/dist/node-runtime/{chunk-T4DA4XE7.js → chunk-MQPKUHRN.js} +162 -82
- package/dist/node-runtime/{chunk-MPKSOJBT.js → chunk-NHATCSOI.js} +4 -7
- package/dist/node-runtime/{chunk-RMQZU2YU.js → chunk-NNNR3QIY.js} +1 -1
- package/dist/node-runtime/{chunk-RWTKOC3B.js → chunk-QBTJG3UM.js} +1 -1
- package/dist/node-runtime/{chunk-P7XBVXGT.js → chunk-QNVMKNNN.js} +18 -14
- package/dist/node-runtime/{chunk-GS42T6MX.js → chunk-QW3AAHWN.js} +1 -1
- package/dist/node-runtime/{chunk-DVQSHCVP.js → chunk-R4WSB2MQ.js} +5 -5
- package/dist/node-runtime/{chunk-B4HP6ZWM.js → chunk-RHCGYWO7.js} +1 -1
- package/dist/node-runtime/{chunk-2CFDTH5B.js → chunk-RLGY2QIL.js} +45 -59
- package/dist/node-runtime/{chunk-KKUTQQV7.js → chunk-RYRGL7P4.js} +1 -1
- package/dist/node-runtime/{chunk-5Q4A37RB.js → chunk-TCT6PCUR.js} +32 -11
- package/dist/node-runtime/{chunk-D5UCKPBQ.js → chunk-UBWW2PID.js} +1 -1
- package/dist/node-runtime/{chunk-E75WFZ33.js → chunk-UNUZICC4.js} +3 -3
- package/dist/node-runtime/{chunk-RAK2QA2B.js → chunk-UYRKUKFE.js} +4 -4
- package/dist/node-runtime/{chunk-LWJXTA6Z.js → chunk-VSUEAI7O.js} +1377 -45
- package/dist/node-runtime/{chunk-NAY6UUQZ.js → chunk-WDIVLMOH.js} +1 -1
- package/dist/node-runtime/{chunk-E24EO34J.js → chunk-WPXUR3HE.js} +1 -1
- package/dist/node-runtime/{chunk-SLVOAQOY.js → chunk-WXYNALHD.js} +113 -1
- package/dist/node-runtime/{chunk-KJ6DWS3K.js → chunk-XEOCUEUJ.js} +121 -60
- package/dist/node-runtime/chunk-YD3IZAZ7.js +47 -0
- package/dist/node-runtime/chunk-YSB6URMT.js +41 -0
- package/dist/node-runtime/{chunk-LJTIVM7I.js → chunk-ZDJUR45D.js} +427 -126
- package/dist/node-runtime/{chunk-YWOJIGFY.js → chunk-ZEVFBFNF.js} +95 -142
- package/dist/node-runtime/{chunk-5B6VKFEV.js → chunk-ZIQUS5QO.js} +1 -1
- package/dist/node-runtime/cli-runtime.js +4 -4
- package/dist/node-runtime/{command-FSBU2EVZ.js → command-3HMSY6W2.js} +5 -5
- package/dist/node-runtime/{commands-EMBQQVVT.js → commands-D6A6H4TS.js} +11 -18
- package/dist/node-runtime/{commands-NAAL7KNT.js → commands-OCSSEEWJ.js} +16 -16
- package/dist/node-runtime/{config-QDD5PUE2.js → config-CU7M7BTK.js} +1 -1
- package/dist/node-runtime/{config-D4QUPAHX.js → config-DS7XLMEM.js} +2 -2
- package/dist/node-runtime/{direct-tool-executor-4D7UXYU4.js → direct-tool-executor-2QJXVQD2.js} +6 -11
- package/dist/node-runtime/{exa-LL64QZR2.js → exa-6VBZNPGE.js} +1 -1
- package/dist/node-runtime/{export-html-VM4J2MNR.js → export-html-BRWF5AHI.js} +4 -4
- package/dist/node-runtime/{extension-input-E7BJZ35H.js → extension-input-VBBMX7YV.js} +5 -5
- package/dist/node-runtime/{extension-selector-WU42XDTU.js → extension-selector-T5AOG5XB.js} +5 -5
- package/dist/node-runtime/{extract-EQJE7FZZ.js → extract-BFX2N35A.js} +3 -3
- package/dist/node-runtime/{gateway-DQM333YV.js → gateway-6623C2U3.js} +51 -42
- package/dist/node-runtime/{gemini-search-35OCRFLN.js → gemini-search-C66QHDT6.js} +2 -2
- package/dist/node-runtime/{gemini-url-context-UQY3PHHW.js → gemini-url-context-T7DEK73R.js} +3 -3
- package/dist/node-runtime/{github-extract-F64RZOEA.js → github-extract-HOGE3D6F.js} +107 -38
- package/dist/node-runtime/{goal-NJEE5CTU.js → goal-AIHEDUYA.js} +5 -5
- package/dist/node-runtime/index.js +50 -48
- package/dist/node-runtime/{init-P5AUV77I.js → init-JBQJIPYI.js} +3 -6
- package/dist/node-runtime/{install-cli-NN4YAU44.js → install-cli-INGHIVBY.js} +30 -25
- package/dist/node-runtime/interactive-mode-FM5DNUSW.js +74 -0
- package/dist/node-runtime/{interactive-view-NGFAMHPW.js → interactive-view-K33PM4OS.js} +8 -8
- package/dist/node-runtime/{lsp-manager-3ASUSO4T.js → lsp-manager-S554V5HR.js} +240 -155
- package/dist/node-runtime/{lunr-browser-IR7TL3J7.js → lunr-browser-H4FDOR3C.js} +7 -7
- package/dist/node-runtime/{lunr-computer-use-Y23CCDIJ.js → lunr-computer-use-VDP2QNRQ.js} +9 -9
- package/dist/node-runtime/{lunr-cron-USHC4LXH.js → lunr-cron-LKVA5CZZ.js} +93 -80
- package/dist/node-runtime/main.js +42 -41
- package/dist/node-runtime/{mobile-commands-O5LCHL32.js → mobile-commands-XT3NQXLD.js} +12 -12
- package/dist/node-runtime/{model-runtime-OO5HFLWE.js → model-runtime-MZ2JMDV4.js} +4 -4
- package/dist/node-runtime/{openai-search-B3MSNCQA.js → openai-search-K72LJDYN.js} +1 -1
- package/dist/node-runtime/{package-manager-cli-Q7BL6KZO.js → package-manager-cli-CYM262SI.js} +20 -20
- package/dist/node-runtime/{parallel-AI2MNSCU.js → parallel-X724NCNU.js} +1 -1
- package/dist/node-runtime/{perplexity-QVJW3I35.js → perplexity-RDHQHVMK.js} +2 -2
- package/dist/node-runtime/{pi-intercom-QM53RLTS.js → pi-intercom-NHHEPBMI.js} +2 -2
- package/dist/node-runtime/{pi-mcp-adapter-3PHF4KZ4.js → pi-mcp-adapter-PP3GQJQ2.js} +98 -94
- package/dist/node-runtime/{pi-ollama-cloud-2F3Y2QNM.js → pi-ollama-cloud-4MNWIMFN.js} +11 -24
- package/dist/node-runtime/{pi-prompt-template-model-QWTCGLJU.js → pi-prompt-template-model-FTGELLS5.js} +32 -36
- package/dist/node-runtime/{pi-subagents-7IBSSGEW.js → pi-subagents-LT3CTO4E.js} +98 -106
- package/dist/node-runtime/{pi-web-access-WTGMNZ32.js → pi-web-access-Z3LP246C.js} +144 -108
- package/dist/node-runtime/{print-mode-XQ76CYMT.js → print-mode-2XHN5SUA.js} +3 -3
- package/dist/node-runtime/{process-registry-4FAKZQOL.js → process-registry-Q4QWIU33.js} +3 -3
- package/dist/node-runtime/{proxy-modes-5FAPSZEZ.js → proxy-modes-VEGC6QG5.js} +8 -15
- package/dist/node-runtime/rpc-entry.js +42 -41
- package/dist/node-runtime/{rpc-mode-O3XV4SID.js → rpc-mode-32DHJPEJ.js} +4 -4
- package/dist/node-runtime/{runtime-4VA6JKNF.js → runtime-EDUUGAQD.js} +56 -46
- package/dist/node-runtime/{runtime-EFPPD2UW.js → runtime-UGXM4NPQ.js} +2 -2
- package/dist/node-runtime/{runtime-bridges-7WVCLI76.js → runtime-bridges-DNKMNJCF.js} +7 -7
- package/dist/node-runtime/{service-MDQIPQ26.js → service-IHLGFLBT.js} +6 -4
- package/dist/node-runtime/{session-handoff-GWARVEWT.js → session-handoff-LNSPDTKY.js} +4 -4
- package/dist/node-runtime/{session-manager-JB5J6XBN.js → session-manager-YIFIAVGC.js} +3 -3
- package/dist/node-runtime/{session-selector-GIM4DHQ2.js → session-selector-I73U3EIO.js} +7 -7
- package/dist/node-runtime/{settings-manager-DJDM5AHM.js → settings-manager-P2TKGYTR.js} +5 -5
- package/dist/node-runtime/{setup-JBKOLJ6F.js → setup-H7CCELIL.js} +15 -1
- package/dist/node-runtime/{setup-PFBWRNUI.js → setup-OLQ4GXWS.js} +17 -17
- package/dist/node-runtime/{src-IVPNZ2BX.js → src-6RV4PXKJ.js} +64 -36
- package/dist/node-runtime/{subagent-executor-LPZ4BHWE.js → subagent-executor-Q5F7DBVM.js} +119 -58
- package/dist/node-runtime/{tavily-WEZFVFP7.js → tavily-KZBFYQB6.js} +1 -1
- package/dist/node-runtime/{theme-UOO5RVFN.js → theme-YLVZKKZD.js} +2 -2
- package/dist/node-runtime/{trust-manager-MMISNCYO.js → trust-manager-ZCU76D23.js} +2 -2
- package/dist/node-runtime/{update-cli-HNMOTNGX.js → update-cli-F3XXJANQ.js} +6 -6
- package/dist/node-runtime/{usage-service-LFB2SWYV.js → usage-service-CPAGBED5.js} +1 -1
- package/dist/node-runtime/{video-extract-OOZHR7SU.js → video-extract-UPKYIBW3.js} +3 -3
- package/dist/node-runtime/{workflow-OHPBEFO4.js → workflow-ICDI4N3J.js} +208 -78
- package/dist/node-runtime/{youtube-extract-FNPAUNHU.js → youtube-extract-77NT7FWH.js} +4 -4
- package/dist/utils/clipboard-image.d.ts.map +1 -1
- package/dist/utils/clipboard-image.js.map +1 -1
- package/dist/utils/exif-orientation.d.ts.map +1 -1
- package/dist/utils/exif-orientation.js +25 -10
- package/dist/utils/exif-orientation.js.map +1 -1
- package/dist/utils/image-resize-core.d.ts.map +1 -1
- package/dist/utils/image-resize-core.js +2 -0
- package/dist/utils/image-resize-core.js.map +1 -1
- package/dist/utils/paths.d.ts +4 -0
- package/dist/utils/paths.d.ts.map +1 -1
- package/dist/utils/paths.js +33 -2
- package/dist/utils/paths.js.map +1 -1
- package/dist/utils/sanitize-terminal-text.d.ts +7 -0
- package/dist/utils/sanitize-terminal-text.d.ts.map +1 -0
- package/dist/utils/sanitize-terminal-text.js +67 -0
- package/dist/utils/sanitize-terminal-text.js.map +1 -0
- package/docs/browser.md +1 -1
- package/docs/custom-provider.md +3 -3
- package/docs/extensions.md +8 -4
- package/docs/features.md +15 -7
- package/docs/keybindings.md +1 -1
- package/docs/models.md +5 -5
- package/docs/packages.md +1 -1
- package/docs/providers.md +2 -2
- package/docs/rpc.md +7 -7
- package/docs/security.md +10 -5
- package/docs/sessions.md +2 -2
- package/docs/skills.md +1 -1
- package/docs/terminal-setup.md +7 -7
- package/docs/themes.md +1 -1
- package/docs/usage.md +1 -1
- package/examples/extensions/auto-commit-on-exit.ts +1 -1
- package/examples/extensions/bash-spawn-hook.ts +1 -1
- package/examples/extensions/built-in-tool-renderer.ts +1 -1
- package/examples/extensions/claude-rules.ts +1 -1
- package/examples/extensions/commands.ts +1 -1
- package/examples/extensions/custom-compaction.ts +1 -1
- package/examples/extensions/custom-provider-anthropic/index.ts +3 -3
- package/examples/extensions/custom-provider-anthropic/package-lock.json +2 -2
- package/examples/extensions/custom-provider-anthropic/package.json +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/index.ts +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
- package/examples/extensions/doom-overlay/index.ts +1 -1
- package/examples/extensions/git-merge-and-resolve.ts +2 -2
- package/examples/extensions/gondolin/index.ts +1 -1
- package/examples/extensions/gondolin/package-lock.json +2 -2
- package/examples/extensions/gondolin/package.json +1 -1
- package/examples/extensions/hidden-thinking-label.ts +1 -1
- package/examples/extensions/inline-bash.ts +2 -2
- package/examples/extensions/input-transform-streaming.ts +2 -2
- package/examples/extensions/input-transform.ts +2 -2
- package/examples/extensions/interactive-shell.ts +1 -1
- package/examples/extensions/kimi-deferred-tools.ts +1 -1
- package/examples/extensions/mac-system-theme.ts +1 -1
- package/examples/extensions/minimal-mode.ts +1 -1
- package/examples/extensions/modal-editor.ts +1 -1
- package/examples/extensions/model-status.ts +1 -1
- package/examples/extensions/notify.ts +3 -3
- package/examples/extensions/overlay-qa-tests.ts +1 -1
- package/examples/extensions/overlay-test.ts +1 -1
- package/examples/extensions/pirate.ts +1 -1
- package/examples/extensions/preset.ts +3 -3
- package/examples/extensions/project-trust.ts +4 -4
- package/examples/extensions/prompt-customizer.ts +1 -1
- package/examples/extensions/rainbow-editor.ts +1 -1
- package/examples/extensions/rpc-demo.ts +1 -1
- package/examples/extensions/sandbox/index.ts +7 -7
- package/examples/extensions/sandbox/package-lock.json +2 -2
- package/examples/extensions/sandbox/package.json +1 -1
- package/examples/extensions/shutdown-command.ts +5 -5
- package/examples/extensions/ssh.ts +2 -2
- package/examples/extensions/subagent/README.md +3 -3
- package/examples/extensions/subagent/index.ts +2 -2
- package/examples/extensions/titlebar-spinner.ts +1 -1
- package/examples/extensions/tool-override.ts +1 -1
- package/examples/extensions/tools.ts +1 -1
- package/examples/extensions/with-deps/package-lock.json +2 -2
- package/examples/extensions/with-deps/package.json +1 -1
- package/examples/extensions/working-indicator.ts +1 -1
- package/examples/extensions/working-message-test.ts +1 -1
- package/examples/sdk/01-minimal.ts +1 -1
- package/examples/sdk/03-custom-prompt.ts +1 -1
- package/examples/sdk/04-skills.ts +1 -1
- package/examples/sdk/06-extensions.ts +2 -2
- package/examples/sdk/08-prompt-templates.ts +1 -1
- package/install-lock/package-lock.json +24 -24
- package/install-lock/package.json +2 -2
- package/npm-shrinkwrap.json +60 -24
- package/package.json +9 -9
- package/dist/modes/interactive/components/exit-card.d.ts +0 -22
- package/dist/modes/interactive/components/exit-card.d.ts.map +0 -1
- package/dist/modes/interactive/components/exit-card.js +0 -69
- package/dist/modes/interactive/components/exit-card.js.map +0 -1
- package/dist/node-runtime/agent-session-services-5YXS2PLF.js +0 -51
- package/dist/node-runtime/chunk-2IDTZAG5.js +0 -1415
- package/dist/node-runtime/chunk-3MISGG4S.js +0 -769
- package/dist/node-runtime/chunk-4HXHDDCF.js +0 -16
- package/dist/node-runtime/chunk-5B5QN3ZQ.js +0 -356
- package/dist/node-runtime/chunk-7IQGBKBJ.js +0 -2033
- package/dist/node-runtime/chunk-AUXVGBO4.js +0 -19
- package/dist/node-runtime/chunk-PTFBPO3C.js +0 -50
- package/dist/node-runtime/interactive-mode-YOHZVMKX.js +0 -74
- package/dist/node-runtime/mcp-auth-flow-QVLFVLEO.js +0 -33
|
@@ -121,6 +121,13 @@ Connection: close\r
|
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
// packages/coding-agent/dist/core/browser/runtime.js
|
|
124
|
+
function closeOwnedResources(owner) {
|
|
125
|
+
return owner?.browser && (owner.browserClose ??= Promise.resolve().then(() => owner.browser.close())), owner?.proxy && (owner.proxyClose ??= Promise.resolve().then(() => owner.proxy.close())), Promise.allSettled([owner?.browserClose, owner?.proxyClose]).then((results) => {
|
|
126
|
+
for (let result of results)
|
|
127
|
+
if (result.status === "rejected")
|
|
128
|
+
throw result.reason;
|
|
129
|
+
});
|
|
130
|
+
}
|
|
124
131
|
function boundedBrowserText(text) {
|
|
125
132
|
let result = truncateHead(text.replace(/[\x00-\x08\x0b-\x1f\x7f-\x9f]/g, ""), { maxBytes: 16384, maxLines: 300 });
|
|
126
133
|
return result.content + (result.truncated ? `
|
|
@@ -141,6 +148,8 @@ async function uniqueTarget(page, input) {
|
|
|
141
148
|
}
|
|
142
149
|
var BrowserSession = class {
|
|
143
150
|
resources;
|
|
151
|
+
owner;
|
|
152
|
+
activeCancellation;
|
|
144
153
|
queue = Promise.resolve();
|
|
145
154
|
closing = Promise.resolve();
|
|
146
155
|
generation = 0;
|
|
@@ -152,20 +161,11 @@ var BrowserSession = class {
|
|
|
152
161
|
this.allowPrivate = allowPrivate, this.idleMs = idleMs;
|
|
153
162
|
}
|
|
154
163
|
async close() {
|
|
155
|
-
this.generation++, clearTimeout(this.idle);
|
|
156
|
-
let
|
|
157
|
-
this.resources = void 0;
|
|
158
|
-
let
|
|
159
|
-
|
|
160
|
-
let resources = await pending?.catch(() => {
|
|
161
|
-
});
|
|
162
|
-
if (resources)
|
|
163
|
-
try {
|
|
164
|
-
await resources.browser.close();
|
|
165
|
-
} finally {
|
|
166
|
-
await resources.proxy.close();
|
|
167
|
-
}
|
|
168
|
-
})();
|
|
164
|
+
this.generation++, clearTimeout(this.idle), this.activeCancellation?.abort();
|
|
165
|
+
let owner = this.owner;
|
|
166
|
+
this.owner = void 0, this.resources = void 0;
|
|
167
|
+
let closing = Promise.all([this.closing, closeOwnedResources(owner)]).then(() => {
|
|
168
|
+
});
|
|
169
169
|
return this.closing = closing.catch(() => {
|
|
170
170
|
}), closing;
|
|
171
171
|
}
|
|
@@ -178,38 +178,40 @@ var BrowserSession = class {
|
|
|
178
178
|
if (signal?.aborted || generation !== this.generation)
|
|
179
179
|
throw new Error("Browser operation cancelled; navigate again in a new call.");
|
|
180
180
|
clearTimeout(this.idle);
|
|
181
|
-
let cancellation = new AbortController()
|
|
182
|
-
|
|
181
|
+
let cancellation = new AbortController();
|
|
182
|
+
this.activeCancellation = cancellation;
|
|
183
|
+
let ownedGeneration = generation, abort = () => {
|
|
184
|
+
cancellation.abort(), ownedGeneration === this.generation && this.close().catch(() => {
|
|
183
185
|
});
|
|
184
|
-
};
|
|
186
|
+
}, cancellationError = new Error("Browser cancelled or exceeded 30s; browser cleanup requested. External effects may already have occurred."), checkCurrent = () => {
|
|
187
|
+
if (cancellation.signal.aborted || generation !== this.generation)
|
|
188
|
+
throw cancellationError;
|
|
189
|
+
}, rejectCancellation, interrupted = new Promise((_resolve, reject) => {
|
|
190
|
+
rejectCancellation = () => reject(cancellationError), cancellation.signal.addEventListener("abort", rejectCancellation, { once: !0 });
|
|
191
|
+
}), wait = (pending) => Promise.race([pending, interrupted]);
|
|
185
192
|
signal?.addEventListener("abort", abort, { once: !0 });
|
|
186
193
|
let deadline = setTimeout(abort, 3e4);
|
|
187
194
|
try {
|
|
188
|
-
if (input.action === "close")
|
|
189
|
-
|
|
195
|
+
if (input.action === "close") {
|
|
196
|
+
this.activeCancellation = void 0;
|
|
197
|
+
let closing = this.close();
|
|
198
|
+
return ownedGeneration = this.generation, await wait(closing), {
|
|
190
199
|
content: [{ type: "text", text: "Browser closed; ephemeral cookies and tabs discarded." }],
|
|
191
200
|
details: { action: input.action }
|
|
192
201
|
};
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
if (!this.resources && input.action !== "navigate" && !(input.action === "tabs" && input.operation === "create"))
|
|
202
|
+
}
|
|
203
|
+
if (await wait(this.closing), checkCurrent(), !this.resources && input.action !== "navigate" && !(input.action === "tabs" && input.operation === "create"))
|
|
196
204
|
throw new Error("No browser is open. Use navigate or tabs/create first. Idle cleanup discards tabs after 5 minutes.");
|
|
197
|
-
this.resources
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
let
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
cancellation.signal.aborted ? cancelled() : cancellation.signal.addEventListener("abort", cancelled, { once: !0 });
|
|
208
|
-
})
|
|
209
|
-
]);
|
|
210
|
-
if (signal?.aborted || generation !== this.generation)
|
|
211
|
-
throw new Error("Browser operation cancelled; external effects may already have occurred. Inspect before retrying.");
|
|
212
|
-
return this.idle = setTimeout(() => {
|
|
205
|
+
if (!this.resources) {
|
|
206
|
+
let owner = { generation };
|
|
207
|
+
this.owner = owner, this.resources = this.open(owner).catch((error) => {
|
|
208
|
+
throw this.owner === owner && (this.resources = void 0, this.owner = void 0), error;
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
let resources = await wait(this.resources);
|
|
212
|
+
checkCurrent();
|
|
213
|
+
let content = await wait(this.perform(resources, input));
|
|
214
|
+
return checkCurrent(), this.idle = setTimeout(() => {
|
|
213
215
|
this.close().catch(() => {
|
|
214
216
|
});
|
|
215
217
|
}, this.idleMs), this.idle.unref(), { content, details: { action: input.action } };
|
|
@@ -221,7 +223,7 @@ var BrowserSession = class {
|
|
|
221
223
|
let message = error instanceof Error ? error.message : String(error);
|
|
222
224
|
throw new Error(boundedBrowserText(message));
|
|
223
225
|
} finally {
|
|
224
|
-
clearTimeout(deadline), signal?.removeEventListener("abort", abort);
|
|
226
|
+
clearTimeout(deadline), signal?.removeEventListener("abort", abort), cancellation.signal.removeEventListener("abort", rejectCancellation), this.activeCancellation === cancellation && (this.activeCancellation = void 0);
|
|
225
227
|
}
|
|
226
228
|
});
|
|
227
229
|
this.queue = operation.catch(() => {
|
|
@@ -232,31 +234,39 @@ var BrowserSession = class {
|
|
|
232
234
|
this.queued--;
|
|
233
235
|
}
|
|
234
236
|
}
|
|
235
|
-
async open() {
|
|
236
|
-
let
|
|
237
|
+
async open(owner) {
|
|
238
|
+
let checkCurrent = () => {
|
|
239
|
+
if (owner.generation !== this.generation)
|
|
240
|
+
throw new Error("Browser operation cancelled.");
|
|
241
|
+
};
|
|
237
242
|
try {
|
|
243
|
+
let proxy = await createBrowserProxy(this.allowPrivate);
|
|
244
|
+
owner.proxy = proxy, checkCurrent();
|
|
238
245
|
let { chromium } = await import("playwright-core");
|
|
239
|
-
|
|
246
|
+
checkCurrent();
|
|
247
|
+
let browser = await chromium.launch({
|
|
240
248
|
headless: !0,
|
|
241
249
|
timeout: 15e3,
|
|
242
250
|
chromiumSandbox: !0,
|
|
243
251
|
proxy: { server: proxy.url, bypass: "<-loopback>" },
|
|
244
252
|
args: ["--disable-quic", "--force-webrtc-ip-handling-policy=disable_non_proxied_udp"]
|
|
245
253
|
});
|
|
254
|
+
owner.browser = browser, checkCurrent();
|
|
246
255
|
let context = await browser.newContext({
|
|
247
256
|
acceptDownloads: !1,
|
|
248
257
|
serviceWorkers: "block",
|
|
249
258
|
permissions: [],
|
|
250
259
|
viewport: { width: 1280, height: 800 }
|
|
251
260
|
});
|
|
252
|
-
|
|
261
|
+
owner.generation !== this.generation && (context.close().catch(() => {
|
|
262
|
+
}), checkCurrent()), context.setDefaultTimeout(1e4), context.setDefaultNavigationTimeout(15e3), await context.route("**/*", async (route) => {
|
|
253
263
|
try {
|
|
254
264
|
browserUrl(route.request().url()), await route.continue();
|
|
255
265
|
} catch {
|
|
256
266
|
await route.abort().catch(() => {
|
|
257
267
|
});
|
|
258
268
|
}
|
|
259
|
-
}), await context.routeWebSocket("**/*", (socket) => socket.close());
|
|
269
|
+
}), checkCurrent(), await context.routeWebSocket("**/*", (socket) => socket.close()), checkCurrent();
|
|
260
270
|
let resources = { browser, context, proxy, pages: /* @__PURE__ */ new Map(), nextId: 1 };
|
|
261
271
|
return context.on("page", (page) => {
|
|
262
272
|
if (resources.pages.size >= 4) {
|
|
@@ -274,8 +284,8 @@ var BrowserSession = class {
|
|
|
274
284
|
});
|
|
275
285
|
}), resources;
|
|
276
286
|
} catch (error) {
|
|
277
|
-
await
|
|
278
|
-
})
|
|
287
|
+
await closeOwnedResources(owner).catch(() => {
|
|
288
|
+
});
|
|
279
289
|
let message = error instanceof Error ? error.message : String(error);
|
|
280
290
|
throw new Error(`Browser launch failed. Matching Chromium may be missing after --ignore-scripts or offline installation. Ask the user to run lunr browser install when online. Nothing was installed by this call. ${message}`);
|
|
281
291
|
}
|
|
@@ -6,9 +6,9 @@ import {
|
|
|
6
6
|
resolveRuntimeArchive,
|
|
7
7
|
runtimeEnvironment,
|
|
8
8
|
runtimeInventory
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-ZIQUS5QO.js";
|
|
10
10
|
import "./chunk-URD2SLIT.js";
|
|
11
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-64XTQNLA.js";
|
|
12
12
|
import "./chunk-Q4Q6D4IY.js";
|
|
13
13
|
import "./chunk-BRJX2PRC.js";
|
|
14
14
|
export {
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { createRequire as __lunrRequire } from "node:module"; const require = __lunrRequire(import.meta.url);
|
|
2
2
|
import {
|
|
3
3
|
bindRuntimeBridges
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-6O3IW3IA.js";
|
|
5
|
+
import "./chunk-HUD2RFJW.js";
|
|
6
|
+
import "./chunk-4KNKQGHM.js";
|
|
7
|
+
import "./chunk-LHV3V67B.js";
|
|
8
8
|
import "./chunk-URD2SLIT.js";
|
|
9
9
|
import "./chunk-FY4A63RK.js";
|
|
10
10
|
import "./chunk-4EULYYR4.js";
|
|
11
11
|
import "./chunk-UJOCPOMX.js";
|
|
12
12
|
import "./chunk-2TKODGBZ.js";
|
|
13
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-HNNHHJAB.js";
|
|
14
14
|
import "./chunk-IMLCWLPI.js";
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
15
|
+
import "./chunk-RHCGYWO7.js";
|
|
16
|
+
import "./chunk-64XTQNLA.js";
|
|
17
17
|
import "./chunk-Q4Q6D4IY.js";
|
|
18
18
|
import "./chunk-BRJX2PRC.js";
|
|
19
19
|
export {
|
|
@@ -13,9 +13,10 @@ import {
|
|
|
13
13
|
serviceStatusText,
|
|
14
14
|
startGatewayService,
|
|
15
15
|
startupSpec,
|
|
16
|
-
stopGatewayService
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
stopGatewayService,
|
|
17
|
+
teardownGatewayService
|
|
18
|
+
} from "./chunk-WXYNALHD.js";
|
|
19
|
+
import "./chunk-64XTQNLA.js";
|
|
19
20
|
import "./chunk-Q4Q6D4IY.js";
|
|
20
21
|
import "./chunk-BRJX2PRC.js";
|
|
21
22
|
export {
|
|
@@ -32,5 +33,6 @@ export {
|
|
|
32
33
|
serviceStatusText,
|
|
33
34
|
startGatewayService,
|
|
34
35
|
startupSpec,
|
|
35
|
-
stopGatewayService
|
|
36
|
+
stopGatewayService,
|
|
37
|
+
teardownGatewayService
|
|
36
38
|
};
|
|
@@ -11,11 +11,11 @@ import {
|
|
|
11
11
|
recordTuiActivity,
|
|
12
12
|
registerTransferHandler,
|
|
13
13
|
requestSessionTransfer
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-I2H5QMWW.js";
|
|
15
|
+
import "./chunk-EPR2F3GU.js";
|
|
16
16
|
import "./chunk-FVDOXRUD.js";
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-MNQXDFPV.js";
|
|
18
|
+
import "./chunk-64XTQNLA.js";
|
|
19
19
|
import "./chunk-Q4Q6D4IY.js";
|
|
20
20
|
import "./chunk-BRJX2PRC.js";
|
|
21
21
|
export {
|
|
@@ -12,10 +12,10 @@ import {
|
|
|
12
12
|
migrateSessionEntries,
|
|
13
13
|
parseSessionEntries,
|
|
14
14
|
sessionEntryToContextMessages
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-EPR2F3GU.js";
|
|
16
16
|
import "./chunk-FVDOXRUD.js";
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-MNQXDFPV.js";
|
|
18
|
+
import "./chunk-64XTQNLA.js";
|
|
19
19
|
import "./chunk-Q4Q6D4IY.js";
|
|
20
20
|
import "./chunk-BRJX2PRC.js";
|
|
21
21
|
export {
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { createRequire as __lunrRequire } from "node:module"; const require = __lunrRequire(import.meta.url);
|
|
2
2
|
import {
|
|
3
3
|
SessionSelectorComponent
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-2OIPYKLZ.js";
|
|
5
|
+
import "./chunk-MNQXDFPV.js";
|
|
6
|
+
import "./chunk-FTKEZL27.js";
|
|
7
|
+
import "./chunk-FLGEEH27.js";
|
|
8
|
+
import "./chunk-QW3AAHWN.js";
|
|
9
|
+
import "./chunk-JL4HYQXK.js";
|
|
10
|
+
import "./chunk-64XTQNLA.js";
|
|
11
11
|
import "./chunk-Q4Q6D4IY.js";
|
|
12
12
|
import "./chunk-BRJX2PRC.js";
|
|
13
13
|
export {
|
|
@@ -8,15 +8,15 @@ import {
|
|
|
8
8
|
bindSubagentCommunicationSetting,
|
|
9
9
|
parseSkillTagCharacter,
|
|
10
10
|
subagentCommunicationEnabled
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
11
|
+
} from "./chunk-HUD2RFJW.js";
|
|
12
|
+
import "./chunk-4KNKQGHM.js";
|
|
13
|
+
import "./chunk-LHV3V67B.js";
|
|
14
14
|
import "./chunk-URD2SLIT.js";
|
|
15
15
|
import "./chunk-FY4A63RK.js";
|
|
16
16
|
import "./chunk-UJOCPOMX.js";
|
|
17
17
|
import "./chunk-IMLCWLPI.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-RHCGYWO7.js";
|
|
19
|
+
import "./chunk-64XTQNLA.js";
|
|
20
20
|
import "./chunk-Q4Q6D4IY.js";
|
|
21
21
|
import "./chunk-BRJX2PRC.js";
|
|
22
22
|
export {
|
|
@@ -1,13 +1,27 @@
|
|
|
1
1
|
import { createRequire as __lunrRequire } from "node:module"; const require = __lunrRequire(import.meta.url);
|
|
2
|
+
import {
|
|
3
|
+
isBunBinary
|
|
4
|
+
} from "./chunk-64XTQNLA.js";
|
|
5
|
+
import "./chunk-Q4Q6D4IY.js";
|
|
2
6
|
import "./chunk-BRJX2PRC.js";
|
|
3
7
|
|
|
4
8
|
// packages/coding-agent/dist/core/browser/setup.js
|
|
5
9
|
import { spawn } from "node:child_process";
|
|
6
10
|
import { fileURLToPath } from "node:url";
|
|
7
11
|
async function installBrowser(explicit = !0) {
|
|
12
|
+
if (isBunBinary) {
|
|
13
|
+
let notice = "Chromium installation is unavailable in the compiled standalone executable. Install the same lunR version through npm and run lunr browser install there. Use the same PLAYWRIGHT_BROWSERS_PATH for installation and standalone execution.";
|
|
14
|
+
if (explicit)
|
|
15
|
+
throw new Error(notice);
|
|
16
|
+
console.warn(notice);
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
8
19
|
let script = fileURLToPath(new URL("../../../scripts/install-browser.mjs", new URL("../core/browser/setup.js", import.meta.url).href));
|
|
9
20
|
await new Promise((resolve, reject) => {
|
|
10
|
-
let child = spawn(process.execPath, [script, ...explicit ? ["--explicit"] : []], {
|
|
21
|
+
let child = spawn(process.execPath, [script, ...explicit ? ["--explicit"] : []], {
|
|
22
|
+
stdio: "inherit",
|
|
23
|
+
windowsHide: !0
|
|
24
|
+
});
|
|
11
25
|
child.once("error", reject), child.once("exit", (code) => {
|
|
12
26
|
code === 0 ? resolve() : reject(new Error(`Chromium setup failed (${code}). Retry lunr browser install when online.`));
|
|
13
27
|
});
|
|
@@ -4,49 +4,49 @@ import {
|
|
|
4
4
|
} from "./chunk-H4K3JDRB.js";
|
|
5
5
|
import {
|
|
6
6
|
createPairingStore
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-NNNR3QIY.js";
|
|
8
8
|
import {
|
|
9
9
|
configureStartup,
|
|
10
10
|
loadServiceSettings,
|
|
11
11
|
startGatewayService
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-WXYNALHD.js";
|
|
13
13
|
import {
|
|
14
14
|
createStartupTui,
|
|
15
15
|
showStartupInput,
|
|
16
16
|
startStartupTui
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-IHHTWSXN.js";
|
|
18
18
|
import "./chunk-YPHAIRZT.js";
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-DVGWF6A2.js";
|
|
19
|
+
import "./chunk-UYRKUKFE.js";
|
|
21
20
|
import "./chunk-OBMWP3I5.js";
|
|
21
|
+
import "./chunk-DVGWF6A2.js";
|
|
22
22
|
import {
|
|
23
23
|
SettingsManager
|
|
24
|
-
} from "./chunk-
|
|
25
|
-
import "./chunk-
|
|
24
|
+
} from "./chunk-HUD2RFJW.js";
|
|
25
|
+
import "./chunk-4KNKQGHM.js";
|
|
26
26
|
import {
|
|
27
27
|
loadInstallFeatures,
|
|
28
28
|
saveInstallFeatures
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-LHV3V67B.js";
|
|
30
30
|
import "./chunk-URD2SLIT.js";
|
|
31
31
|
import "./chunk-CGBXPL3E.js";
|
|
32
32
|
import "./chunk-FY4A63RK.js";
|
|
33
33
|
import "./chunk-UJOCPOMX.js";
|
|
34
34
|
import "./chunk-IMLCWLPI.js";
|
|
35
|
-
import "./chunk-
|
|
35
|
+
import "./chunk-FTKEZL27.js";
|
|
36
36
|
import {
|
|
37
37
|
loadGatewayConfig,
|
|
38
38
|
saveGatewayConfig
|
|
39
|
-
} from "./chunk-
|
|
40
|
-
import "./chunk-
|
|
41
|
-
import "./chunk-
|
|
39
|
+
} from "./chunk-RHCGYWO7.js";
|
|
40
|
+
import "./chunk-252ZVPPF.js";
|
|
41
|
+
import "./chunk-GLDXBBL6.js";
|
|
42
42
|
import "./chunk-I6R76AG7.js";
|
|
43
|
-
import "./chunk-
|
|
44
|
-
import "./chunk-
|
|
43
|
+
import "./chunk-FLGEEH27.js";
|
|
44
|
+
import "./chunk-QW3AAHWN.js";
|
|
45
45
|
import {
|
|
46
46
|
getSelectListTheme,
|
|
47
47
|
theme
|
|
48
|
-
} from "./chunk-
|
|
49
|
-
import "./chunk-
|
|
48
|
+
} from "./chunk-JL4HYQXK.js";
|
|
49
|
+
import "./chunk-64XTQNLA.js";
|
|
50
50
|
import "./chunk-Q4Q6D4IY.js";
|
|
51
51
|
import "./chunk-BRJX2PRC.js";
|
|
52
52
|
|
|
@@ -157,7 +157,7 @@ Guide: https://docs.discord.com/developers/quick-start/getting-started`);
|
|
|
157
157
|
{ label: "When the computer boots", value: "boot" }
|
|
158
158
|
], loadServiceSettings().startup);
|
|
159
159
|
startup === "boot" && console.log("Boot startup may require administrator permission or OS-managed account credentials. lunR does not save your account password.");
|
|
160
|
-
let { ModelRuntime } = await import("./model-runtime-
|
|
160
|
+
let { ModelRuntime } = await import("./model-runtime-MZ2JMDV4.js"), models = await (await ModelRuntime.create({ allowModelNetwork: !1 })).getAvailable();
|
|
161
161
|
if (!models.length)
|
|
162
162
|
throw new Error("No saved model credentials found. Open lunr locally and use /login, then rerun gateway setup. Nothing saved.");
|
|
163
163
|
let settings = SettingsManager.create(cfg.defaultProject), providers = [...new Set(models.map((model2) => model2.provider))], provider = await choose("Model provider", providers.map((value) => ({ label: value, value })), settings.getDefaultProvider()), choices = models.filter((model2) => model2.provider === provider), model = await choose("Model", choices.map((value) => ({ label: value.id, value })), choices.find((model2) => model2.id === settings.getDefaultModel()));
|
|
@@ -22,16 +22,26 @@ import {
|
|
|
22
22
|
import {
|
|
23
23
|
typebox_exports
|
|
24
24
|
} from "./chunk-PL6JKXWI.js";
|
|
25
|
+
import {
|
|
26
|
+
withFileMutationQueue
|
|
27
|
+
} from "./chunk-YSB6URMT.js";
|
|
25
28
|
import {
|
|
26
29
|
DEFAULT_MAX_BYTES,
|
|
27
30
|
DEFAULT_MAX_LINES,
|
|
28
31
|
truncateHead
|
|
29
32
|
} from "./chunk-53YJI7JU.js";
|
|
33
|
+
import {
|
|
34
|
+
protectedTargetWriteReason,
|
|
35
|
+
resolveToCwd
|
|
36
|
+
} from "./chunk-F2V2F4ZG.js";
|
|
37
|
+
import "./chunk-BDRGN3L2.js";
|
|
30
38
|
import {
|
|
31
39
|
isEditToolResult,
|
|
32
40
|
isReadToolResult,
|
|
33
41
|
isWriteToolResult
|
|
34
42
|
} from "./chunk-OR4L3IB2.js";
|
|
43
|
+
import "./chunk-64XTQNLA.js";
|
|
44
|
+
import "./chunk-Q4Q6D4IY.js";
|
|
35
45
|
import {
|
|
36
46
|
__toESM
|
|
37
47
|
} from "./chunk-BRJX2PRC.js";
|
|
@@ -41,7 +51,7 @@ var import_vscode_languageserver_protocol3 = __toESM(require_api(), 1);
|
|
|
41
51
|
|
|
42
52
|
// packages/coding-agent/dist/builtin-extensions/pi-lsp-extension/src/runtime.js
|
|
43
53
|
var defaultLoaders = {
|
|
44
|
-
loadLspManager: () => import("./lsp-manager-
|
|
54
|
+
loadLspManager: () => import("./lsp-manager-S554V5HR.js"),
|
|
45
55
|
loadFileSync: () => import("./file-sync-HCOP2QVF.js"),
|
|
46
56
|
loadTreeSitter: () => import("./parser-manager-TQHWYDH7.js"),
|
|
47
57
|
loadWorkspaceIndex: () => import("./workspace-index-6DBXSTJ6.js")
|
|
@@ -1587,6 +1597,7 @@ function hasErrors(node) {
|
|
|
1587
1597
|
}
|
|
1588
1598
|
|
|
1589
1599
|
// packages/coding-agent/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/search-engine.js
|
|
1600
|
+
import { createHash } from "node:crypto";
|
|
1590
1601
|
import { resolve as resolve2 } from "node:path";
|
|
1591
1602
|
import { readdir as readdir2, readFile as readFile8, stat } from "node:fs/promises";
|
|
1592
1603
|
async function searchFiles(pattern, rootDir, treeSitter, options = {}) {
|
|
@@ -1600,12 +1611,13 @@ async function searchFiles(pattern, rootDir, treeSitter, options = {}) {
|
|
|
1600
1611
|
let content = await readFile8(file, "utf-8"), tree = await treeSitter.parseWithLanguage(file, content, pattern.languageId);
|
|
1601
1612
|
if (!tree)
|
|
1602
1613
|
continue;
|
|
1603
|
-
let fileMatches = findMatches(tree.rootNode, pattern.root);
|
|
1614
|
+
let sourceHash = createHash("sha256").update(content).digest("hex"), fileMatches = findMatches(tree.rootNode, pattern.root);
|
|
1604
1615
|
for (let m of fileMatches) {
|
|
1605
1616
|
if (matches.length >= maxResults)
|
|
1606
1617
|
break;
|
|
1607
1618
|
matches.push({
|
|
1608
1619
|
file,
|
|
1620
|
+
sourceHash,
|
|
1609
1621
|
line: m.node.startPosition.row + 1,
|
|
1610
1622
|
column: m.node.startPosition.column + 1,
|
|
1611
1623
|
matchedText: m.node.text,
|
|
@@ -1800,6 +1812,8 @@ function createCodeSearchTool(rootDirOrGetter, treeSitter) {
|
|
|
1800
1812
|
import { relative as relative8 } from "node:path";
|
|
1801
1813
|
|
|
1802
1814
|
// packages/coding-agent/dist/builtin-extensions/pi-lsp-extension/src/tree-sitter/rewrite-engine.js
|
|
1815
|
+
import { createHash as createHash2 } from "node:crypto";
|
|
1816
|
+
import { dirname } from "node:path";
|
|
1803
1817
|
import { readFile as readFile9, writeFile } from "node:fs/promises";
|
|
1804
1818
|
var METAVAR_REF_RE = /\$\$\$([A-Z_][A-Z0-9_]*)|\$([A-Z_][A-Z0-9_]*)/g;
|
|
1805
1819
|
function substituteCaptures(template, captures) {
|
|
@@ -1824,28 +1838,47 @@ function computeRewrites(matches, replacementTemplate) {
|
|
|
1824
1838
|
};
|
|
1825
1839
|
});
|
|
1826
1840
|
}
|
|
1827
|
-
async function applyRewrites(matches, replacementTemplate) {
|
|
1841
|
+
async function applyRewrites(matches, replacementTemplate, cwd) {
|
|
1828
1842
|
let byFile = /* @__PURE__ */ new Map();
|
|
1829
|
-
for (let
|
|
1830
|
-
let existing = byFile.get(
|
|
1831
|
-
existing ? existing.push(
|
|
1843
|
+
for (let match of matches) {
|
|
1844
|
+
let existing = byFile.get(match.file);
|
|
1845
|
+
existing ? existing.push(match) : byFile.set(match.file, [match]);
|
|
1846
|
+
}
|
|
1847
|
+
let result = { changes: [], filesModified: 0, modifiedFiles: [], failures: [], skippedFiles: [] }, files = [...byFile.keys()];
|
|
1848
|
+
for (let file of files) {
|
|
1849
|
+
let reason = protectedTargetWriteReason(file, cwd ?? dirname(file));
|
|
1850
|
+
reason && result.failures.push({ file, reason });
|
|
1832
1851
|
}
|
|
1833
|
-
|
|
1852
|
+
if (result.failures.length)
|
|
1853
|
+
return result.skippedFiles = files.filter((file) => !result.failures.some((failure) => failure.file === file)), result;
|
|
1834
1854
|
for (let [file, fileMatches] of byFile) {
|
|
1835
|
-
let
|
|
1836
|
-
|
|
1837
|
-
let
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1855
|
+
let writeAttempted = !1;
|
|
1856
|
+
try {
|
|
1857
|
+
let applied = await withFileMutationQueue(file, async () => {
|
|
1858
|
+
let reason = protectedTargetWriteReason(file, cwd ?? dirname(file));
|
|
1859
|
+
if (reason)
|
|
1860
|
+
throw new Error(reason);
|
|
1861
|
+
let source = await readFile9(file, "utf-8"), sourceHash = createHash2("sha256").update(source).digest("hex"), sorted = [...fileMatches].sort((a, b) => b.startIndex - a.startIndex), nextStart = source.length;
|
|
1862
|
+
for (let match of sorted) {
|
|
1863
|
+
if (match.sourceHash !== sourceHash || !Number.isInteger(match.startIndex) || !Number.isInteger(match.endIndex) || match.startIndex < 0 || match.endIndex > nextStart || match.startIndex > match.endIndex || source.slice(match.startIndex, match.endIndex) !== match.matchedText)
|
|
1864
|
+
throw new Error("Source changed or match offsets are invalid. Search again before applying a rewrite.");
|
|
1865
|
+
nextStart = match.startIndex;
|
|
1866
|
+
}
|
|
1867
|
+
let content = source, changes = [];
|
|
1868
|
+
for (let match of sorted) {
|
|
1869
|
+
let raw = substituteCaptures(replacementTemplate, match.captures), replacement = preserveTrailingSemicolon(match.matchedText, raw);
|
|
1870
|
+
content = content.slice(0, match.startIndex) + replacement + content.slice(match.endIndex), changes.push({ file, line: match.line, column: match.column, before: match.matchedText, after: replacement });
|
|
1871
|
+
}
|
|
1872
|
+
let modified = content !== source;
|
|
1873
|
+
return modified && (writeAttempted = !0, await writeFile(file, content, "utf-8")), { changes: changes.reverse(), modified };
|
|
1844
1874
|
});
|
|
1875
|
+
result.changes.push(...applied.changes), applied.modified && result.modifiedFiles.push(file);
|
|
1876
|
+
} catch (error) {
|
|
1877
|
+
result.failures.push({ file, reason: error instanceof Error ? error.message : String(error), writeAttempted }), result.skippedFiles = files.slice(files.indexOf(file) + 1);
|
|
1878
|
+
break;
|
|
1845
1879
|
}
|
|
1846
|
-
modified && (await writeFile(file, content, "utf-8"), filesModified++);
|
|
1847
1880
|
}
|
|
1848
|
-
return
|
|
1881
|
+
return result.filesModified = result.modifiedFiles.length, result;
|
|
1849
1882
|
}
|
|
1850
1883
|
|
|
1851
1884
|
// packages/coding-agent/dist/builtin-extensions/pi-lsp-extension/src/tools/code-rewrite.js
|
|
@@ -1861,7 +1894,7 @@ function createCodeRewriteTool(rootDirOrGetter, treeSitter, fileChangeCallback)
|
|
|
1861
1894
|
return {
|
|
1862
1895
|
name: "code_rewrite",
|
|
1863
1896
|
label: "Code Rewrite",
|
|
1864
|
-
description: "Transform code matching a structural pattern into a replacement. Use $NAME to capture and reuse single nodes, $$$NAME for sequences. Defaults to dry-run mode (preview only). Set dry_run=false to apply changes. For symbol renames, prefer lsp_rename instead (semantically correct).",
|
|
1897
|
+
description: "Transform code matching a structural pattern into a replacement. Use $NAME to capture and reuse single nodes, $$$NAME for sequences. Defaults to dry-run mode (preview only). Set dry_run=false to apply changes. Apply rejects protected targets and stale source snapshots. Files apply sequentially; a later failure leaves earlier changes in place and reports skipped files. Search again after a stale-source failure. Inspect failed writes before retrying. For symbol renames, prefer lsp_rename instead (semantically correct).",
|
|
1865
1898
|
parameters: RewriteParams,
|
|
1866
1899
|
async execute(_toolCallId, params) {
|
|
1867
1900
|
let rootDir = getRootDir(), { pattern: patternStr, replacement, language, path, dry_run } = params, isDryRun = dry_run !== !1, compiled;
|
|
@@ -1869,7 +1902,7 @@ function createCodeRewriteTool(rootDirOrGetter, treeSitter, fileChangeCallback)
|
|
|
1869
1902
|
compiled = await compilePattern(patternStr, language, treeSitter);
|
|
1870
1903
|
} catch (e) {
|
|
1871
1904
|
return {
|
|
1872
|
-
content: [{ type: "text", text: `Error: ${e.message}` }],
|
|
1905
|
+
content: [{ type: "text", text: `Error: ${e instanceof Error ? e.message : String(e)}` }],
|
|
1873
1906
|
details: { matchCount: 0, filesModified: 0, dryRun: isDryRun }
|
|
1874
1907
|
};
|
|
1875
1908
|
}
|
|
@@ -1883,7 +1916,7 @@ function createCodeRewriteTool(rootDirOrGetter, treeSitter, fileChangeCallback)
|
|
|
1883
1916
|
};
|
|
1884
1917
|
}
|
|
1885
1918
|
let matches = await searchFiles(compiled, rootDir, treeSitter, {
|
|
1886
|
-
path,
|
|
1919
|
+
path: path ? resolveToCwd(path, rootDir) : void 0,
|
|
1887
1920
|
maxResults: 500
|
|
1888
1921
|
});
|
|
1889
1922
|
if (matches.length === 0)
|
|
@@ -1919,13 +1952,16 @@ function createCodeRewriteTool(rootDirOrGetter, treeSitter, fileChangeCallback)
|
|
|
1919
1952
|
details: { matchCount: matches.length, filesModified: uniqueFiles.size, dryRun: !0 }
|
|
1920
1953
|
};
|
|
1921
1954
|
}
|
|
1922
|
-
let result = await applyRewrites(matches, replacement);
|
|
1923
|
-
if (fileChangeCallback && result.filesModified > 0)
|
|
1924
|
-
let
|
|
1925
|
-
for (let file of modifiedFiles)
|
|
1955
|
+
let result = await applyRewrites(matches, replacement, rootDir);
|
|
1956
|
+
if (fileChangeCallback && result.filesModified > 0)
|
|
1957
|
+
for (let file of result.modifiedFiles)
|
|
1926
1958
|
fileChangeCallback.onFileModified(file);
|
|
1927
|
-
}
|
|
1928
1959
|
let lines = [];
|
|
1960
|
+
if (result.failures.length) {
|
|
1961
|
+
lines.push(`Rewrite stopped. ${result.filesModified} file(s) changed before failure; earlier changes remain. ${result.skippedFiles.length} file(s) skipped.`), result.failures.some((failure) => failure.writeAttempted) && lines.push("A failed write may have partially changed its target. Inspect that file before retrying.");
|
|
1962
|
+
for (let failure of result.failures)
|
|
1963
|
+
lines.push(`${relative8(rootDir, failure.file)}: ${failure.reason}`);
|
|
1964
|
+
}
|
|
1929
1965
|
lines.push(`Applied ${result.changes.length} change${result.changes.length !== 1 ? "s" : ""} across ${result.filesModified} file${result.filesModified !== 1 ? "s" : ""}:
|
|
1930
1966
|
`);
|
|
1931
1967
|
for (let c of result.changes) {
|
|
@@ -1938,7 +1974,7 @@ function createCodeRewriteTool(rootDirOrGetter, treeSitter, fileChangeCallback)
|
|
|
1938
1974
|
|
|
1939
1975
|
[Truncated: showing ${truncation.outputLines} of ${truncation.totalLines} lines]`), {
|
|
1940
1976
|
content: [{ type: "text", text: output }],
|
|
1941
|
-
details: { matchCount: matches.length, filesModified: result.filesModified, dryRun: !1 }
|
|
1977
|
+
details: { matchCount: matches.length, filesModified: result.filesModified, dryRun: !1, failures: result.failures, skippedFiles: result.skippedFiles }
|
|
1942
1978
|
};
|
|
1943
1979
|
}
|
|
1944
1980
|
};
|
|
@@ -2141,14 +2177,6 @@ function registerToolWithRuntime(pi, tool, ensure, host) {
|
|
|
2141
2177
|
});
|
|
2142
2178
|
}
|
|
2143
2179
|
function lspExtension(pi) {
|
|
2144
|
-
let origListeners = process.listeners("uncaughtException");
|
|
2145
|
-
process.on("uncaughtException", (err) => {
|
|
2146
|
-
if (err?.code !== "EPIPE") {
|
|
2147
|
-
for (let listener of origListeners)
|
|
2148
|
-
listener(err);
|
|
2149
|
-
origListeners.length === 0 && console.error("[LSP] Uncaught exception:", err);
|
|
2150
|
-
}
|
|
2151
|
-
});
|
|
2152
2180
|
let host = new LspRuntimeHost(), pendingProvider = null, latestCtx = null, projectConfig = null, sessionCwd = process.cwd(), withLatestCtx = (fn) => {
|
|
2153
2181
|
let ctx = latestCtx;
|
|
2154
2182
|
if (ctx)
|
|
@@ -2219,7 +2247,7 @@ function lspExtension(pi) {
|
|
|
2219
2247
|
}
|
|
2220
2248
|
}), ensureRuntime = async () => host.ensureServices(buildBindOptions(sessionCwd || process.cwd()));
|
|
2221
2249
|
pi.on("session_start", async (_event, ctx) => {
|
|
2222
|
-
latestCtx = ctx, sessionCwd = ctx.cwd, projectConfig = loadProjectConfig(ctx.cwd), await host.bindSession(buildBindOptions(ctx.cwd));
|
|
2250
|
+
latestCtx = ctx, sessionCwd = ctx.cwd, projectConfig = ctx.isProjectTrusted() ? loadProjectConfig(ctx.cwd) : null, await host.bindSession(buildBindOptions(ctx.cwd));
|
|
2223
2251
|
let statusText = pendingProvider?.getStatusText?.() ?? "";
|
|
2224
2252
|
if (statusText ? ctx.ui.setStatus("lsp", ctx.ui.theme.fg("accent", `LSP: ${statusText}`)) : ctx.ui.setStatus("lsp", ctx.ui.theme.fg("dim", "LSP: idle")), projectConfig?.autoStart && projectConfig.autoStart.length > 0) {
|
|
2225
2253
|
let langs = projectConfig.autoStart, generation = host.getGeneration();
|