@entelligentsia/forgecli 0.7.6 → 0.7.9
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 +59 -0
- package/README.md +105 -215
- package/dist/CHANGELOG-forge-plugin.md +1233 -0
- package/dist/CHANGELOG-pi.md +4205 -0
- package/dist/bin/forge.js +2 -2
- package/dist/extensions/forgecli/approve.d.ts +1 -1
- package/dist/extensions/forgecli/ask-user-tool.d.ts +1 -1
- package/dist/extensions/forgecli/audience-gate.d.ts +1 -1
- package/dist/extensions/forgecli/collate.d.ts +1 -1
- package/dist/extensions/forgecli/commit.d.ts +1 -1
- package/dist/extensions/forgecli/enhance.d.ts +1 -1
- package/dist/extensions/forgecli/fix-bug.d.ts +1 -1
- package/dist/extensions/forgecli/forge-commands.d.ts +1 -1
- package/dist/extensions/forgecli/forge-header.d.ts +3 -3
- package/dist/extensions/forgecli/forge-header.js +12 -6
- package/dist/extensions/forgecli/forge-header.js.map +1 -1
- package/dist/extensions/forgecli/forge-init.d.ts +1 -1
- package/dist/extensions/forgecli/forge-subagent.d.ts +3 -3
- package/dist/extensions/forgecli/forge-subagent.js +2 -2
- package/dist/extensions/forgecli/forge-tools.d.ts +1 -1
- package/dist/extensions/forgecli/forge-update-command.d.ts +1 -1
- package/dist/extensions/forgecli/hook-dispatcher.d.ts +1 -1
- package/dist/extensions/forgecli/hook-dispatcher.js +1 -1
- package/dist/extensions/forgecli/hooks/post-init-hook.d.ts +1 -1
- package/dist/extensions/forgecli/hooks/post-sprint-hook.d.ts +1 -1
- package/dist/extensions/forgecli/implement.d.ts +1 -1
- package/dist/extensions/forgecli/index.d.ts +1 -1
- package/dist/extensions/forgecli/index.js +41 -6
- package/dist/extensions/forgecli/index.js.map +1 -1
- package/dist/extensions/forgecli/kickoff.d.ts +1 -1
- package/dist/extensions/forgecli/plan.d.ts +1 -1
- package/dist/extensions/forgecli/read-command.d.ts +1 -1
- package/dist/extensions/forgecli/regenerate.d.ts +1 -1
- package/dist/extensions/forgecli/review-code.d.ts +1 -1
- package/dist/extensions/forgecli/review-plan.d.ts +1 -1
- package/dist/extensions/forgecli/run-sprint.d.ts +2 -2
- package/dist/extensions/forgecli/run-task.d.ts +2 -2
- package/dist/extensions/forgecli/sprint-intake.d.ts +1 -1
- package/dist/extensions/forgecli/sprint-plan.d.ts +1 -1
- package/dist/extensions/forgecli/store-resolver.d.ts +1 -1
- package/dist/extensions/forgecli/subagent/agents.js +1 -1
- package/dist/extensions/forgecli/subagent/index.d.ts +1 -1
- package/dist/extensions/forgecli/subagent/index.js +3 -3
- package/dist/extensions/forgecli/test-orchestrate.d.ts +1 -1
- package/dist/extensions/forgecli/thread-switcher.d.ts +1 -1
- package/dist/extensions/forgecli/thread-switcher.js +1 -1
- package/dist/extensions/forgecli/usage-hook.d.ts +1 -1
- package/dist/extensions/forgecli/validate.d.ts +1 -1
- package/dist/extensions/forgecli/wf-engine/register.d.ts +1 -1
- package/dist/extensions/forgecli/wf-engine/worker.d.ts +1 -1
- package/dist/extensions/forgecli/wf-engine/worker.js +1 -1
- package/dist/extensions/forgecli/whats-new-widget.d.ts +21 -0
- package/dist/extensions/forgecli/whats-new-widget.js +303 -0
- package/dist/extensions/forgecli/whats-new-widget.js.map +1 -0
- package/dist/extensions/forgecli/whats-new.d.ts +120 -0
- package/dist/extensions/forgecli/whats-new.js +469 -0
- package/dist/extensions/forgecli/whats-new.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/README.md +488 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent-loop.d.ts +24 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent-loop.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent-loop.js +479 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent-loop.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent.d.ts +118 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent.js +402 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/agent.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.d.ts +92 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.js +900 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/agent-harness.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.d.ts +53 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.js +174 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/branch-summarization.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.d.ts +95 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.js +533 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/utils.d.ts +25 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/utils.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/utils.js +131 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/utils.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.d.ts +51 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.js +481 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution-env.d.ts +4 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution-env.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution-env.js +3 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/execution-env.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.d.ts +51 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.js +102 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/messages.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.d.ts +48 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.js +230 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/prompt-templates.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-repo.d.ts +26 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-repo.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-repo.js +101 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-repo.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-storage.d.ts +33 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-storage.js +231 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/jsonl-storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-repo.d.ts +18 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-repo.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-repo.js +42 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-repo.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-storage.d.ts +25 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-storage.js +114 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/memory-storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/jsonl.d.ts +20 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/jsonl.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/jsonl.js +92 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/jsonl.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/memory.d.ts +18 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/memory.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/memory.js +42 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/memory.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/shared.d.ts +10 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/shared.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/shared.js +31 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo/shared.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo-utils.d.ts +11 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo-utils.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo-utils.js +39 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/repo-utils.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.d.ts +32 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.js +197 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/session.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/jsonl.d.ts +30 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/jsonl.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/jsonl.js +170 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/jsonl.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/memory.d.ts +26 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/memory.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/memory.js +90 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/storage/memory.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/uuid.d.ts +2 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/uuid.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/uuid.js +50 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/session/uuid.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.d.ts +44 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.js +311 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/skills.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/system-prompt.d.ts +3 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/system-prompt.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/system-prompt.js +30 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/system-prompt.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.d.ts +613 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.js +100 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.d.ts +14 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.js +126 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/shell-output.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.js +288 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/harness/utils/truncate.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/index.d.ts +20 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/index.js +25 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/node.d.ts +3 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/node.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/node.js +3 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/node.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/proxy.d.ts +69 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/proxy.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/proxy.js +278 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/proxy.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/types.d.ts +393 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/dist/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-agent-core/package.json +61 -0
- package/node_modules/@earendil-works/pi-ai/README.md +1383 -0
- package/node_modules/@earendil-works/pi-ai/dist/cli.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/cli.js +116 -0
- package/node_modules/@earendil-works/pi-ai/dist/cli.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/env-api-keys.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/env-api-keys.js +170 -0
- package/node_modules/@earendil-works/pi-ai/dist/env-api-keys.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.d.ts +10 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.d.ts +425 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.js +427 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.js +23 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/images-api-registry.d.ts +14 -0
- package/node_modules/@earendil-works/pi-ai/dist/images-api-registry.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/images-api-registry.js +22 -0
- package/node_modules/@earendil-works/pi-ai/dist/images-api-registry.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/images.d.ts +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/images.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/images.js +14 -0
- package/node_modules/@earendil-works/pi-ai/dist/images.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/index.d.ts +32 -0
- package/node_modules/@earendil-works/pi-ai/dist/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/index.js +20 -0
- package/node_modules/@earendil-works/pi-ai/dist/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/models.generated.d.ts +17435 -0
- package/node_modules/@earendil-works/pi-ai/dist/models.generated.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/models.generated.js +16383 -0
- package/node_modules/@earendil-works/pi-ai/dist/models.generated.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/amazon-bedrock.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/amazon-bedrock.js +750 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/amazon-bedrock.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/anthropic.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/anthropic.js +960 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/anthropic.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/openrouter.d.ts +3 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/openrouter.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/openrouter.js +129 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/openrouter.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/register-builtins.d.ts +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/register-builtins.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/register-builtins.js +34 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/images/register-builtins.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-codex-responses.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-codex-responses.js +1080 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-codex-responses.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-completions.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-completions.js +943 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-completions.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/simple-options.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/simple-options.js +39 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/simple-options.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/types.d.ts +488 -0
- package/node_modules/@earendil-works/pi-ai/dist/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/node-http-proxy.d.ts +10 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/node-http-proxy.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/node-http-proxy.js +97 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/node-http-proxy.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/overflow.d.ts +56 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/overflow.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/overflow.js +151 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/overflow.js.map +1 -0
- package/node_modules/@earendil-works/pi-ai/package.json +107 -0
- package/node_modules/@earendil-works/pi-coding-agent/CHANGELOG.md +4205 -0
- package/node_modules/@earendil-works/pi-coding-agent/README.md +653 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/bun/register-bedrock.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/bun/register-bedrock.js +4 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/bun/register-bedrock.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/args.d.ts +53 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/args.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/args.js +341 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/args.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/config-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/config-selector.js +31 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/config-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/file-processor.d.ts +15 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/file-processor.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/file-processor.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/initial-message.d.ts +18 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/initial-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/initial-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/list-models.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/list-models.js +98 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/list-models.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/session-picker.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/session-picker.js +35 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli/session-picker.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli.js +28 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/cli.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/config.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/config.js +399 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/config.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session-services.d.ts +86 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session-services.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session-services.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session.d.ts +595 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session.js +2521 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/auth-storage.d.ts +141 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/auth-storage.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/auth-storage.js +441 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/auth-storage.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/bash-executor.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/bash-executor.js +111 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/bash-executor.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/branch-summarization.d.ts +88 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/branch-summarization.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/branch-summarization.js +243 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/branch-summarization.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/compaction.d.ts +121 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/compaction.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/compaction.js +615 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/compaction.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/utils.d.ts +38 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/utils.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/utils.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/defaults.d.ts +3 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/defaults.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/defaults.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/export-html/index.d.ts +37 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/export-html/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/export-html/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/export-html/tool-renderer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/export-html/tool-renderer.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/loader.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/loader.js +498 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/loader.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/runner.d.ts +159 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/runner.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/runner.js +825 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/runner.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/types.d.ts +1187 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/wrapper.d.ts +20 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/wrapper.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/wrapper.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/keybindings.d.ts +353 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/keybindings.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/keybindings.js +295 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/keybindings.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/messages.d.ts +77 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/messages.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/messages.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-registry.d.ts +150 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-registry.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-registry.js +728 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-registry.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-resolver.d.ts +110 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-resolver.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-resolver.js +495 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-resolver.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/package-manager.d.ts +199 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/package-manager.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/package-manager.js +1996 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/package-manager.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/prompt-templates.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/prompt-templates.js +252 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/prompt-templates.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/provider-display-names.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/provider-display-names.js +33 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/provider-display-names.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/sdk.d.ts +107 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/sdk.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/sdk.js +282 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/sdk.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/session-manager.d.ts +333 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/session-manager.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/session-manager.js +1139 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/session-manager.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/settings-manager.d.ts +261 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/settings-manager.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/settings-manager.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/skills.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/skills.js +401 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/skills.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/bash.d.ts +68 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/bash.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/bash.js +335 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/bash.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/edit.d.ts +49 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/edit.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/edit.js +324 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/edit.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/find.d.ts +35 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/find.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/find.js +298 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/find.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/grep.d.ts +37 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/grep.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/grep.js +304 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/grep.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/index.d.ts +40 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/ls.d.ts +37 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/ls.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/ls.js +169 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/ls.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/read.d.ts +35 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/read.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/read.js +289 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/read.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/render-utils.d.ts +21 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/render-utils.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/render-utils.js +49 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/render-utils.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/tool-definition-wrapper.d.ts +14 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/tool-definition-wrapper.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/tool-definition-wrapper.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/truncate.d.ts +70 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/write.d.ts +26 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/write.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/write.js +213 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/write.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/main.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/main.js +573 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/main.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/armin.d.ts +34 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/armin.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/armin.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/assistant-message.d.ts +20 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/assistant-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/assistant-message.js +121 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/assistant-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bash-execution.d.ts +34 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bash-execution.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bash-execution.js +175 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bash-execution.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bordered-loader.d.ts +16 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bordered-loader.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bordered-loader.js +54 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/bordered-loader.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.d.ts +16 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.js +44 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.d.ts +16 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.js +45 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/config-selector.d.ts +71 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/config-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/config-selector.js +503 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/config-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/countdown-timer.d.ts +14 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/countdown-timer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/countdown-timer.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-editor.d.ts +21 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-editor.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-editor.js +70 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-editor.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-message.d.ts +20 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-message.js +79 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/daxnuts.d.ts +23 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/daxnuts.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/daxnuts.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/dynamic-border.d.ts +15 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/dynamic-border.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/dynamic-border.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.d.ts +5 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.js +40 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-editor.d.ts +20 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-editor.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-editor.js +111 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-editor.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-input.d.ts +23 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-input.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-input.js +61 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-input.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-selector.d.ts +26 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-selector.js +83 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/extension-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/footer.d.ts +27 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/footer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/footer.js +201 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/footer.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.d.ts +13 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.js +36 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/login-dialog.d.ts +46 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/login-dialog.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/login-dialog.js +160 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/login-dialog.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts +47 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/model-selector.js +278 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/model-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/oauth-selector.d.ts +31 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/oauth-selector.js +165 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/oauth-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.d.ts +42 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.js +290 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector-search.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector-search.js +155 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector-search.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts +96 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector.js +861 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/session-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/settings-selector.d.ts +67 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/settings-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/settings-selector.js +375 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/settings-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/show-images-selector.d.ts +10 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/show-images-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/show-images-selector.js +39 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/show-images-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts +17 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js +47 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/theme-selector.d.ts +11 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/theme-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/theme-selector.js +50 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/theme-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/thinking-selector.d.ts +11 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/thinking-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/thinking-selector.js +51 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/thinking-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tool-execution.d.ts +63 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tool-execution.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tool-execution.js +295 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tool-execution.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tree-selector.d.ts +89 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tree-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tree-selector.js +1093 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/tree-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message-selector.d.ts +30 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message-selector.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message-selector.js +114 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message-selector.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message.d.ts +10 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message.js +29 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/visual-truncate.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/visual-truncate.js +33 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/visual-truncate.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.d.ts +382 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.js +4668 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/dark.json +85 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/light.json +84 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts +81 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/theme.js +973 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/theme/theme.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/print-mode.d.ts +28 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/print-mode.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/print-mode.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-client.d.ts +224 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-client.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-client.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-mode.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-mode.js +605 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-mode.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-types.d.ts +419 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/modes/rpc/rpc-types.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/ansi.d.ts +2 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/ansi.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/ansi.js +52 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/ansi.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/html.d.ts +7 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/html.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/html.js +40 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/html.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/image-resize.d.ts +36 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/image-resize.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/image-resize.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/mime.d.ts +3 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/mime.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/mime.js +69 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/mime.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/syntax-highlight.d.ts +12 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/syntax-highlight.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/syntax-highlight.js +118 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/syntax-highlight.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/tools-manager.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/tools-manager.js +328 -0
- package/node_modules/@earendil-works/pi-coding-agent/dist/utils/tools-manager.js.map +1 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/compaction.md +394 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/custom-provider.md +701 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/extensions.md +2596 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/index.md +70 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/models.md +474 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/packages.md +223 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/providers.md +243 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/quickstart.md +142 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/rpc.md +1407 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/sdk.md +1129 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/session-format.md +412 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/skills.md +231 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/termux.md +127 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/themes.md +295 -0
- package/node_modules/@earendil-works/pi-coding-agent/docs/tui.md +918 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/README.md +208 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/auto-commit-on-exit.ts +49 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/bash-spawn-hook.ts +30 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/bookmark.ts +50 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/border-status-editor.ts +150 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/built-in-tool-renderer.ts +249 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/claude-rules.ts +86 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/commands.ts +72 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/confirm-destructive.ts +59 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-compaction.ts +127 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-footer.ts +64 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-header.ts +73 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-anthropic/index.ts +604 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-anthropic/package-lock.json +24 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-anthropic/package.json +19 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/index.ts +349 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/package.json +16 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/test.ts +82 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/dirty-repo-guard.ts +56 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/doom-overlay/doom-component.ts +132 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/doom-overlay/doom-keys.ts +104 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/doom-overlay/index.ts +74 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/dynamic-resources/dynamic.json +79 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/dynamic-resources/index.ts +15 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/dynamic-tools.ts +74 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/event-bus.ts +43 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/file-trigger.ts +41 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/git-checkpoint.ts +53 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/github-issue-autocomplete.ts +185 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/handoff.ts +191 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/hello.ts +26 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/hidden-thinking-label.ts +53 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/inline-bash.ts +94 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/input-transform.ts +43 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/interactive-shell.ts +196 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/mac-system-theme.ts +47 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/message-renderer.ts +59 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/minimal-mode.ts +426 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/modal-editor.ts +85 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/model-status.ts +31 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/notify.ts +55 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/overlay-qa-tests.ts +1348 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/overlay-test.ts +150 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/permission-gate.ts +34 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/pirate.ts +47 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/plan-mode/index.ts +340 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/preset.ts +430 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/prompt-customizer.ts +97 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/protected-paths.ts +30 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/provider-payload.ts +18 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/qna.ts +122 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/question.ts +264 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/questionnaire.ts +427 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/rainbow-editor.ts +88 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/reload-runtime.ts +37 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/rpc-demo.ts +118 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/sandbox/index.ts +321 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/sandbox/package-lock.json +92 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/sandbox/package.json +19 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/send-user-message.ts +97 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/session-name.ts +27 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/shutdown-command.ts +63 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/snake.ts +343 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/space-invaders.ts +560 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/ssh.ts +220 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/status-line.ts +32 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/structured-output.ts +65 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/subagent/agents.ts +126 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/subagent/index.ts +987 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/summarize.ts +206 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/system-prompt-header.ts +17 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/tic-tac-toe.ts +1008 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/timed-confirm.ts +70 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/titlebar-spinner.ts +58 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/todo.ts +297 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/tool-override.ts +144 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/tools.ts +141 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/trigger-compact.ts +50 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/truncated-tool.ts +195 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/widget-placement.ts +9 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/with-deps/index.ts +32 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/with-deps/package-lock.json +31 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/with-deps/package.json +22 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/working-indicator.ts +123 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/extensions/working-message-test.ts +25 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/rpc-extension-ui.ts +632 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/01-minimal.ts +26 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/02-custom-model.ts +53 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/03-custom-prompt.ts +75 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/04-skills.ts +55 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/05-tools.ts +48 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/06-extensions.ts +99 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/07-context-files.ts +47 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/08-prompt-templates.ts +51 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/09-api-keys-and-oauth.ts +52 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/10-settings.ts +53 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/11-sessions.ts +52 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/12-full-control.ts +77 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/13-session-runtime.ts +67 -0
- package/node_modules/@earendil-works/pi-coding-agent/examples/sdk/README.md +144 -0
- package/node_modules/@earendil-works/pi-coding-agent/package.json +95 -0
- package/node_modules/@earendil-works/pi-tui/README.md +779 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/image.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/image.js +89 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/image.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.d.ts +90 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.js +634 -0
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.js +361 -0
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.d.ts +90 -0
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.js +337 -0
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.js.map +1 -0
- package/node_modules/@earendil-works/pi-tui/package.json +50 -0
- package/node_modules/@mariozechner/clipboard/.yarnrc.yml +1 -0
- package/node_modules/@mariozechner/clipboard/Cargo.toml +45 -0
- package/node_modules/@mariozechner/clipboard/README.md +60 -0
- package/node_modules/@mariozechner/clipboard/build.rs +5 -0
- package/node_modules/@mariozechner/clipboard/exp.ts +12 -0
- package/node_modules/@mariozechner/clipboard/index.d.ts +23 -0
- package/node_modules/@mariozechner/clipboard/index.js +317 -0
- package/node_modules/@mariozechner/clipboard/package.json +47 -0
- package/node_modules/@mariozechner/clipboard/package.json.prepack-backup +56 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/common.rs +307 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/mod.rs +93 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/ios.rs +313 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/macos.rs +471 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/mod.rs +252 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/wayland.rs +431 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/win.rs +712 -0
- package/node_modules/@mariozechner/clipboard/src/clipboard_rs/platform/x11.rs +916 -0
- package/node_modules/@mariozechner/clipboard/src/lib.rs +199 -0
- package/node_modules/@mariozechner/clipboard-linux-x64-gnu/README.md +3 -0
- package/node_modules/@mariozechner/clipboard-linux-x64-gnu/clipboard.linux-x64-gnu.node +0 -0
- package/node_modules/@mariozechner/clipboard-linux-x64-gnu/package.json +25 -0
- package/node_modules/koffi/CHANGELOG.md +1093 -0
- package/node_modules/koffi/LICENSE.txt +22 -0
- package/node_modules/koffi/README.md +43 -0
- package/node_modules/koffi/build/koffi/darwin_arm64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/darwin_x64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/freebsd_arm64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/freebsd_ia32/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/freebsd_x64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_arm64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_armhf/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_ia32/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_loong64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_riscv64d/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/linux_x64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/musl_arm64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/musl_x64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/openbsd_ia32/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/openbsd_x64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/win32_arm64/koffi.exp +0 -0
- package/node_modules/koffi/build/koffi/win32_arm64/koffi.lib +0 -0
- package/node_modules/koffi/build/koffi/win32_arm64/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/win32_ia32/koffi.exp +0 -0
- package/node_modules/koffi/build/koffi/win32_ia32/koffi.lib +0 -0
- package/node_modules/koffi/build/koffi/win32_ia32/koffi.node +0 -0
- package/node_modules/koffi/build/koffi/win32_x64/koffi.exp +0 -0
- package/node_modules/koffi/build/koffi/win32_x64/koffi.lib +0 -0
- package/node_modules/koffi/build/koffi/win32_x64/koffi.node +0 -0
- package/node_modules/koffi/doc/benchmarks.md +126 -0
- package/node_modules/koffi/doc/callbacks.md +210 -0
- package/node_modules/koffi/doc/contribute.md +148 -0
- package/node_modules/koffi/doc/functions.md +250 -0
- package/node_modules/koffi/doc/index.md +61 -0
- package/node_modules/koffi/doc/input.md +471 -0
- package/node_modules/koffi/doc/migration.md +159 -0
- package/node_modules/koffi/doc/misc.md +180 -0
- package/node_modules/koffi/doc/output.md +305 -0
- package/node_modules/koffi/doc/packaging.md +88 -0
- package/node_modules/koffi/doc/platforms.md +36 -0
- package/node_modules/koffi/doc/pointers.md +328 -0
- package/node_modules/koffi/doc/start.md +118 -0
- package/node_modules/koffi/doc/unions.md +186 -0
- package/node_modules/koffi/doc/variables.md +102 -0
- package/node_modules/koffi/index.d.ts +288 -0
- package/node_modules/koffi/index.js +634 -0
- package/node_modules/koffi/indirect.js +533 -0
- package/node_modules/koffi/lib/native/base/base.cc +11015 -0
- package/node_modules/koffi/lib/native/base/base.hh +6003 -0
- package/node_modules/koffi/lib/native/base/crc.inc +2214 -0
- package/node_modules/koffi/lib/native/base/crc_gen.py +72 -0
- package/node_modules/koffi/lib/native/base/mimetypes.inc +1248 -0
- package/node_modules/koffi/lib/native/base/mimetypes_gen.py +58 -0
- package/node_modules/koffi/lib/native/base/tower.cc +821 -0
- package/node_modules/koffi/lib/native/base/tower.hh +81 -0
- package/node_modules/koffi/lib/native/base/unicode.inc +408 -0
- package/node_modules/koffi/lib/native/base/unicode_gen.py +152 -0
- package/node_modules/koffi/package.json +38 -0
- package/node_modules/koffi/src/cnoke/LICENSE.txt +22 -0
- package/node_modules/koffi/src/cnoke/README.md +99 -0
- package/node_modules/koffi/src/cnoke/assets/FindCNoke.cmake +127 -0
- package/node_modules/koffi/src/cnoke/assets/toolchains.json +126 -0
- package/node_modules/koffi/src/cnoke/assets/win_delay_hook.c +36 -0
- package/node_modules/koffi/src/cnoke/cnoke.js +170 -0
- package/node_modules/koffi/src/cnoke/package.json +24 -0
- package/node_modules/koffi/src/cnoke/src/builder.js +511 -0
- package/node_modules/koffi/src/cnoke/src/index.js +10 -0
- package/node_modules/koffi/src/cnoke/src/tools.js +407 -0
- package/node_modules/koffi/src/koffi/CMakeLists.txt +182 -0
- package/node_modules/koffi/src/koffi/src/abi_arm32.cc +1018 -0
- package/node_modules/koffi/src/koffi/src/abi_arm32_asm.S +169 -0
- package/node_modules/koffi/src/koffi/src/abi_arm64.cc +1295 -0
- package/node_modules/koffi/src/koffi/src/abi_arm64_asm.S +195 -0
- package/node_modules/koffi/src/koffi/src/abi_arm64_asm.asm +174 -0
- package/node_modules/koffi/src/koffi/src/abi_loong64.cc +5 -0
- package/node_modules/koffi/src/koffi/src/abi_loong64_asm.S +204 -0
- package/node_modules/koffi/src/koffi/src/abi_riscv64.cc +915 -0
- package/node_modules/koffi/src/koffi/src/abi_riscv64_asm.S +203 -0
- package/node_modules/koffi/src/koffi/src/abi_x64_sysv.cc +939 -0
- package/node_modules/koffi/src/koffi/src/abi_x64_sysv_asm.S +231 -0
- package/node_modules/koffi/src/koffi/src/abi_x64_win.cc +715 -0
- package/node_modules/koffi/src/koffi/src/abi_x64_win_asm.S +166 -0
- package/node_modules/koffi/src/koffi/src/abi_x64_win_asm.asm +192 -0
- package/node_modules/koffi/src/koffi/src/abi_x86.cc +860 -0
- package/node_modules/koffi/src/koffi/src/abi_x86_asm.S +193 -0
- package/node_modules/koffi/src/koffi/src/abi_x86_asm.asm +177 -0
- package/node_modules/koffi/src/koffi/src/call.cc +1326 -0
- package/node_modules/koffi/src/koffi/src/call.hh +179 -0
- package/node_modules/koffi/src/koffi/src/errno.inc +462 -0
- package/node_modules/koffi/src/koffi/src/ffi.cc +2702 -0
- package/node_modules/koffi/src/koffi/src/ffi.hh +354 -0
- package/node_modules/koffi/src/koffi/src/init.js +105 -0
- package/node_modules/koffi/src/koffi/src/parser.cc +220 -0
- package/node_modules/koffi/src/koffi/src/parser.hh +54 -0
- package/node_modules/koffi/src/koffi/src/util.cc +1807 -0
- package/node_modules/koffi/src/koffi/src/util.hh +221 -0
- package/node_modules/koffi/src/koffi/src/uv.cc +193 -0
- package/node_modules/koffi/src/koffi/src/uv.def +10 -0
- package/node_modules/koffi/src/koffi/src/uv.hh +40 -0
- package/node_modules/koffi/src/koffi/src/win32.cc +198 -0
- package/node_modules/koffi/src/koffi/src/win32.hh +119 -0
- package/node_modules/koffi/src/koffi/tools/write_trampolines.js +77 -0
- package/node_modules/koffi/vendor/node-addon-api/LICENSE.md +9 -0
- package/node_modules/koffi/vendor/node-addon-api/README.md +95 -0
- package/node_modules/koffi/vendor/node-addon-api/napi-inl.deprecated.h +186 -0
- package/node_modules/koffi/vendor/node-addon-api/napi-inl.h +7033 -0
- package/node_modules/koffi/vendor/node-addon-api/napi.h +3309 -0
- package/node_modules/koffi/vendor/node-api-headers/LICENSE +21 -0
- package/node_modules/koffi/vendor/node-api-headers/README.md +95 -0
- package/node_modules/koffi/vendor/node-api-headers/def/js_native_api.def +125 -0
- package/node_modules/koffi/vendor/node-api-headers/def/node_api.def +157 -0
- package/node_modules/koffi/vendor/node-api-headers/include/js_native_api.h +591 -0
- package/node_modules/koffi/vendor/node-api-headers/include/js_native_api_types.h +210 -0
- package/node_modules/koffi/vendor/node-api-headers/include/node_api.h +265 -0
- package/node_modules/koffi/vendor/node-api-headers/include/node_api_types.h +58 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/aix.h +32 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/bsd.h +34 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/darwin.h +61 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/errno.h +483 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/linux.h +34 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/os390.h +33 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/posix.h +31 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/sunos.h +44 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/threadpool.h +37 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/tree.h +521 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/unix.h +512 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/version.h +43 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv/win.h +698 -0
- package/node_modules/koffi/vendor/node-api-headers/include/uv.h +1990 -0
- package/package.json +12 -12
- package/themes/forge-matrix.json +89 -0
- package/themes/forge-mono.json +86 -0
- package/node_modules/@borewit/text-codec/LICENSE.txt +0 -9
- package/node_modules/@borewit/text-codec/README.md +0 -87
- package/node_modules/@borewit/text-codec/lib/index.d.ts +0 -6
- package/node_modules/@borewit/text-codec/lib/index.js +0 -380
- package/node_modules/@borewit/text-codec/package.json +0 -70
- package/node_modules/@entelligentsia/pi-agent-core/README.md +0 -488
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent-loop.d.ts +0 -24
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent-loop.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent-loop.js +0 -458
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent-loop.js.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent.d.ts +0 -117
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent.js +0 -398
- package/node_modules/@entelligentsia/pi-agent-core/dist/agent.js.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/index.d.ts +0 -5
- package/node_modules/@entelligentsia/pi-agent-core/dist/index.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/index.js +0 -9
- package/node_modules/@entelligentsia/pi-agent-core/dist/index.js.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/proxy.d.ts +0 -69
- package/node_modules/@entelligentsia/pi-agent-core/dist/proxy.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/proxy.js +0 -278
- package/node_modules/@entelligentsia/pi-agent-core/dist/proxy.js.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/types.d.ts +0 -369
- package/node_modules/@entelligentsia/pi-agent-core/dist/types.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/dist/types.js.map +0 -1
- package/node_modules/@entelligentsia/pi-agent-core/package.json +0 -45
- package/node_modules/@entelligentsia/pi-ai/README.md +0 -1313
- package/node_modules/@entelligentsia/pi-ai/dist/cli.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/cli.js +0 -116
- package/node_modules/@entelligentsia/pi-ai/dist/cli.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/env-api-keys.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/env-api-keys.js +0 -169
- package/node_modules/@entelligentsia/pi-ai/dist/env-api-keys.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/index.d.ts +0 -28
- package/node_modules/@entelligentsia/pi-ai/dist/index.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/index.js +0 -16
- package/node_modules/@entelligentsia/pi-ai/dist/index.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/models.generated.d.ts +0 -17265
- package/node_modules/@entelligentsia/pi-ai/dist/models.generated.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/models.generated.js +0 -16500
- package/node_modules/@entelligentsia/pi-ai/dist/models.generated.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/amazon-bedrock.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/amazon-bedrock.js +0 -759
- package/node_modules/@entelligentsia/pi-ai/dist/providers/amazon-bedrock.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/anthropic.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/anthropic.js +0 -951
- package/node_modules/@entelligentsia/pi-ai/dist/providers/anthropic.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-codex-responses.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-codex-responses.js +0 -1034
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-codex-responses.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-completions.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-completions.js +0 -925
- package/node_modules/@entelligentsia/pi-ai/dist/providers/openai-completions.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/simple-options.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/providers/simple-options.js +0 -39
- package/node_modules/@entelligentsia/pi-ai/dist/providers/simple-options.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/types.d.ts +0 -405
- package/node_modules/@entelligentsia/pi-ai/dist/types.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/types.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/utils/overflow.d.ts +0 -55
- package/node_modules/@entelligentsia/pi-ai/dist/utils/overflow.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/dist/utils/overflow.js +0 -146
- package/node_modules/@entelligentsia/pi-ai/dist/utils/overflow.js.map +0 -1
- package/node_modules/@entelligentsia/pi-ai/package.json +0 -108
- package/node_modules/@entelligentsia/pi-coding-agent/CHANGELOG.md +0 -4166
- package/node_modules/@entelligentsia/pi-coding-agent/README.md +0 -652
- package/node_modules/@entelligentsia/pi-coding-agent/dist/bun/register-bedrock.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/bun/register-bedrock.js +0 -4
- package/node_modules/@entelligentsia/pi-coding-agent/dist/bun/register-bedrock.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/args.d.ts +0 -53
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/args.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/args.js +0 -340
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/args.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/config-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/config-selector.js +0 -31
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/config-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/file-processor.d.ts +0 -15
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/file-processor.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/file-processor.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/initial-message.d.ts +0 -18
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/initial-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/initial-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/list-models.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/list-models.js +0 -98
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/list-models.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/session-picker.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/session-picker.js +0 -35
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli/session-picker.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli.js +0 -20
- package/node_modules/@entelligentsia/pi-coding-agent/dist/cli.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/config.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/config.js +0 -399
- package/node_modules/@entelligentsia/pi-coding-agent/dist/config.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session-services.d.ts +0 -86
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session-services.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session-services.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session.d.ts +0 -595
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session.js +0 -2521
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/agent-session.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/auth-storage.d.ts +0 -141
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/auth-storage.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/auth-storage.js +0 -441
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/auth-storage.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/bash-executor.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/bash-executor.js +0 -111
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/bash-executor.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/branch-summarization.d.ts +0 -88
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/branch-summarization.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/branch-summarization.js +0 -243
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/branch-summarization.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/compaction.d.ts +0 -121
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/compaction.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/compaction.js +0 -615
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/compaction.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/utils.d.ts +0 -38
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/utils.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/compaction/utils.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/defaults.d.ts +0 -3
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/defaults.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/defaults.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/export-html/index.d.ts +0 -37
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/export-html/index.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/export-html/index.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/export-html/tool-renderer.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/export-html/tool-renderer.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/loader.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/loader.js +0 -498
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/loader.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/runner.d.ts +0 -159
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/runner.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/runner.js +0 -825
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/runner.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/types.d.ts +0 -1187
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/types.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/types.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/wrapper.d.ts +0 -20
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/wrapper.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/extensions/wrapper.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/keybindings.d.ts +0 -353
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/keybindings.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/keybindings.js +0 -295
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/keybindings.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/messages.d.ts +0 -77
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/messages.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/messages.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-registry.d.ts +0 -150
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-registry.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-registry.js +0 -727
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-registry.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-resolver.d.ts +0 -110
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-resolver.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-resolver.js +0 -494
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/model-resolver.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/package-manager.d.ts +0 -198
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/package-manager.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/package-manager.js +0 -1958
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/package-manager.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/prompt-templates.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/prompt-templates.js +0 -250
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/prompt-templates.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/provider-display-names.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/provider-display-names.js +0 -32
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/provider-display-names.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/sdk.d.ts +0 -107
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/sdk.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/sdk.js +0 -282
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/sdk.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/session-manager.d.ts +0 -333
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/session-manager.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/session-manager.js +0 -1109
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/session-manager.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/settings-manager.d.ts +0 -261
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/settings-manager.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/settings-manager.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/skills.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/skills.js +0 -404
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/skills.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/bash.d.ts +0 -68
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/bash.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/bash.js +0 -335
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/bash.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/edit.d.ts +0 -49
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/edit.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/edit.js +0 -324
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/edit.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/find.d.ts +0 -35
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/find.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/find.js +0 -298
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/find.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/grep.d.ts +0 -37
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/grep.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/grep.js +0 -304
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/grep.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/index.d.ts +0 -40
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/index.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/index.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/ls.d.ts +0 -37
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/ls.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/ls.js +0 -169
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/ls.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/read.d.ts +0 -35
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/read.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/read.js +0 -289
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/read.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/render-utils.d.ts +0 -21
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/render-utils.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/render-utils.js +0 -49
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/render-utils.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/tool-definition-wrapper.d.ts +0 -14
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/tool-definition-wrapper.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/tool-definition-wrapper.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/write.d.ts +0 -26
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/write.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/write.js +0 -213
- package/node_modules/@entelligentsia/pi-coding-agent/dist/core/tools/write.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/main.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/main.js +0 -583
- package/node_modules/@entelligentsia/pi-coding-agent/dist/main.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/armin.d.ts +0 -34
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/armin.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/armin.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/assistant-message.d.ts +0 -20
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/assistant-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/assistant-message.js +0 -121
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/assistant-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bash-execution.d.ts +0 -34
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bash-execution.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bash-execution.js +0 -175
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bash-execution.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bordered-loader.d.ts +0 -16
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bordered-loader.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bordered-loader.js +0 -54
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/bordered-loader.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.d.ts +0 -16
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.js +0 -44
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/branch-summary-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.d.ts +0 -16
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.js +0 -45
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/compaction-summary-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/config-selector.d.ts +0 -71
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/config-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/config-selector.js +0 -481
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/config-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/countdown-timer.d.ts +0 -14
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/countdown-timer.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/countdown-timer.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-editor.d.ts +0 -21
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-editor.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-editor.js +0 -70
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-editor.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-message.d.ts +0 -20
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-message.js +0 -79
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/custom-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/daxnuts.d.ts +0 -23
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/daxnuts.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/daxnuts.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/dynamic-border.d.ts +0 -15
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/dynamic-border.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/dynamic-border.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.d.ts +0 -5
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.js +0 -40
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/earendil-announcement.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-editor.d.ts +0 -20
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-editor.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-editor.js +0 -111
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-editor.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-input.d.ts +0 -23
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-input.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-input.js +0 -61
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-input.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-selector.d.ts +0 -24
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-selector.js +0 -78
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/extension-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/footer.d.ts +0 -27
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/footer.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/footer.js +0 -201
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/footer.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.d.ts +0 -8
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.js +0 -22
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/keybinding-hints.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/login-dialog.d.ts +0 -46
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/login-dialog.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/login-dialog.js +0 -160
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/login-dialog.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts +0 -47
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/model-selector.js +0 -278
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/model-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/oauth-selector.d.ts +0 -31
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/oauth-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/oauth-selector.js +0 -165
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/oauth-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.d.ts +0 -42
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.js +0 -290
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/scoped-models-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector-search.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector-search.js +0 -155
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector-search.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts +0 -96
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector.js +0 -861
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/session-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/settings-selector.d.ts +0 -67
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/settings-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/settings-selector.js +0 -373
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/settings-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/show-images-selector.d.ts +0 -10
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/show-images-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/show-images-selector.js +0 -39
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/show-images-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts +0 -17
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js +0 -47
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/theme-selector.d.ts +0 -11
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/theme-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/theme-selector.js +0 -50
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/theme-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/thinking-selector.d.ts +0 -11
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/thinking-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/thinking-selector.js +0 -51
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/thinking-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tool-execution.d.ts +0 -63
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tool-execution.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tool-execution.js +0 -295
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tool-execution.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tree-selector.d.ts +0 -89
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tree-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tree-selector.js +0 -1092
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/tree-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message-selector.d.ts +0 -30
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message-selector.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message-selector.js +0 -114
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message-selector.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message.d.ts +0 -10
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message.js +0 -29
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/user-message.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/visual-truncate.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/visual-truncate.js +0 -33
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/components/visual-truncate.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/interactive-mode.d.ts +0 -374
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/interactive-mode.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/interactive-mode.js +0 -4625
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/interactive-mode.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/dark.json +0 -85
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/light.json +0 -84
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts +0 -81
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/theme.js +0 -971
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/interactive/theme/theme.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/print-mode.d.ts +0 -28
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/print-mode.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/print-mode.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-client.d.ts +0 -224
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-client.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-client.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-mode.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-mode.js +0 -604
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-mode.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-types.d.ts +0 -419
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-types.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/modes/rpc/rpc-types.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/image-resize.d.ts +0 -36
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/image-resize.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/image-resize.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/mime.d.ts +0 -2
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/mime.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/mime.js +0 -26
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/mime.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/tools-manager.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/tools-manager.js +0 -256
- package/node_modules/@entelligentsia/pi-coding-agent/dist/utils/tools-manager.js.map +0 -1
- package/node_modules/@entelligentsia/pi-coding-agent/docs/compaction.md +0 -394
- package/node_modules/@entelligentsia/pi-coding-agent/docs/custom-provider.md +0 -646
- package/node_modules/@entelligentsia/pi-coding-agent/docs/extensions.md +0 -2596
- package/node_modules/@entelligentsia/pi-coding-agent/docs/index.md +0 -70
- package/node_modules/@entelligentsia/pi-coding-agent/docs/models.md +0 -474
- package/node_modules/@entelligentsia/pi-coding-agent/docs/packages.md +0 -223
- package/node_modules/@entelligentsia/pi-coding-agent/docs/providers.md +0 -241
- package/node_modules/@entelligentsia/pi-coding-agent/docs/quickstart.md +0 -142
- package/node_modules/@entelligentsia/pi-coding-agent/docs/rpc.md +0 -1407
- package/node_modules/@entelligentsia/pi-coding-agent/docs/sdk.md +0 -1149
- package/node_modules/@entelligentsia/pi-coding-agent/docs/session-format.md +0 -412
- package/node_modules/@entelligentsia/pi-coding-agent/docs/skills.md +0 -232
- package/node_modules/@entelligentsia/pi-coding-agent/docs/termux.md +0 -127
- package/node_modules/@entelligentsia/pi-coding-agent/docs/themes.md +0 -295
- package/node_modules/@entelligentsia/pi-coding-agent/docs/tui.md +0 -918
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/README.md +0 -208
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/auto-commit-on-exit.ts +0 -49
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/bash-spawn-hook.ts +0 -30
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/bookmark.ts +0 -50
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/border-status-editor.ts +0 -150
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/built-in-tool-renderer.ts +0 -249
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/claude-rules.ts +0 -86
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/commands.ts +0 -72
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/confirm-destructive.ts +0 -59
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-compaction.ts +0 -127
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-footer.ts +0 -64
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-header.ts +0 -73
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-anthropic/index.ts +0 -604
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-anthropic/package-lock.json +0 -24
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-anthropic/package.json +0 -19
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/index.ts +0 -349
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/package.json +0 -16
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/custom-provider-gitlab-duo/test.ts +0 -82
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/dirty-repo-guard.ts +0 -56
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/doom-overlay/doom-component.ts +0 -132
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/doom-overlay/doom-keys.ts +0 -104
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/doom-overlay/index.ts +0 -74
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/dynamic-resources/dynamic.json +0 -79
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/dynamic-resources/index.ts +0 -15
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/dynamic-tools.ts +0 -74
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/event-bus.ts +0 -43
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/file-trigger.ts +0 -41
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/git-checkpoint.ts +0 -53
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/github-issue-autocomplete.ts +0 -185
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/handoff.ts +0 -191
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/hello.ts +0 -26
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/hidden-thinking-label.ts +0 -53
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/inline-bash.ts +0 -94
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/input-transform.ts +0 -43
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/interactive-shell.ts +0 -196
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/mac-system-theme.ts +0 -47
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/message-renderer.ts +0 -59
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/minimal-mode.ts +0 -426
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/modal-editor.ts +0 -85
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/model-status.ts +0 -31
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/notify.ts +0 -55
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/overlay-qa-tests.ts +0 -1348
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/overlay-test.ts +0 -150
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/permission-gate.ts +0 -34
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/pirate.ts +0 -47
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/plan-mode/index.ts +0 -340
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/preset.ts +0 -430
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/prompt-customizer.ts +0 -97
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/protected-paths.ts +0 -30
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/provider-payload.ts +0 -18
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/qna.ts +0 -122
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/question.ts +0 -264
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/questionnaire.ts +0 -427
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/rainbow-editor.ts +0 -88
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/reload-runtime.ts +0 -37
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/rpc-demo.ts +0 -118
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/sandbox/index.ts +0 -321
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/sandbox/package-lock.json +0 -92
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/sandbox/package.json +0 -19
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/send-user-message.ts +0 -97
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/session-name.ts +0 -27
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/shutdown-command.ts +0 -63
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/snake.ts +0 -343
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/space-invaders.ts +0 -560
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/ssh.ts +0 -220
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/status-line.ts +0 -32
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/structured-output.ts +0 -65
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/subagent/agents.ts +0 -126
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/subagent/index.ts +0 -987
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/summarize.ts +0 -206
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/system-prompt-header.ts +0 -17
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/tic-tac-toe.ts +0 -1008
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/timed-confirm.ts +0 -70
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/titlebar-spinner.ts +0 -58
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/todo.ts +0 -297
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/tool-override.ts +0 -144
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/tools.ts +0 -141
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/trigger-compact.ts +0 -50
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/truncated-tool.ts +0 -195
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/widget-placement.ts +0 -9
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/with-deps/index.ts +0 -32
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/with-deps/package-lock.json +0 -31
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/with-deps/package.json +0 -22
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/working-indicator.ts +0 -123
- package/node_modules/@entelligentsia/pi-coding-agent/examples/extensions/working-message-test.ts +0 -25
- package/node_modules/@entelligentsia/pi-coding-agent/examples/rpc-extension-ui.ts +0 -632
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/01-minimal.ts +0 -22
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/02-custom-model.ts +0 -49
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/03-custom-prompt.ts +0 -67
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/04-skills.ts +0 -55
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/05-tools.ts +0 -44
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/06-extensions.ts +0 -95
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/07-context-files.ts +0 -47
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/08-prompt-templates.ts +0 -51
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/09-api-keys-and-oauth.ts +0 -48
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/10-settings.ts +0 -53
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/11-sessions.ts +0 -48
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/12-full-control.ts +0 -73
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/13-session-runtime.ts +0 -67
- package/node_modules/@entelligentsia/pi-coding-agent/examples/sdk/README.md +0 -147
- package/node_modules/@entelligentsia/pi-coding-agent/package.json +0 -97
- package/node_modules/@entelligentsia/pi-tui/README.md +0 -779
- package/node_modules/@entelligentsia/pi-tui/dist/components/image.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/components/image.js +0 -76
- package/node_modules/@entelligentsia/pi-tui/dist/components/image.js.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/components/markdown.d.ts +0 -95
- package/node_modules/@entelligentsia/pi-tui/dist/components/markdown.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/components/markdown.js +0 -688
- package/node_modules/@entelligentsia/pi-tui/dist/components/markdown.js.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/stdin-buffer.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/stdin-buffer.js +0 -339
- package/node_modules/@entelligentsia/pi-tui/dist/stdin-buffer.js.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/terminal-image.d.ts +0 -85
- package/node_modules/@entelligentsia/pi-tui/dist/terminal-image.d.ts.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/dist/terminal-image.js +0 -324
- package/node_modules/@entelligentsia/pi-tui/dist/terminal-image.js.map +0 -1
- package/node_modules/@entelligentsia/pi-tui/package.json +0 -49
- package/node_modules/@tokenizer/inflate/LICENSE +0 -15
- package/node_modules/@tokenizer/inflate/README.md +0 -114
- package/node_modules/@tokenizer/inflate/lib/GzipHandler.d.ts +0 -6
- package/node_modules/@tokenizer/inflate/lib/GzipHandler.js +0 -19
- package/node_modules/@tokenizer/inflate/lib/ZipHandler.d.ts +0 -26
- package/node_modules/@tokenizer/inflate/lib/ZipHandler.js +0 -233
- package/node_modules/@tokenizer/inflate/lib/ZipToken.d.ts +0 -94
- package/node_modules/@tokenizer/inflate/lib/ZipToken.js +0 -117
- package/node_modules/@tokenizer/inflate/lib/index.d.ts +0 -3
- package/node_modules/@tokenizer/inflate/lib/index.js +0 -2
- package/node_modules/@tokenizer/inflate/package.json +0 -76
- package/node_modules/@tokenizer/token/README.md +0 -19
- package/node_modules/@tokenizer/token/index.d.ts +0 -30
- package/node_modules/@tokenizer/token/package.json +0 -33
- package/node_modules/@tootallnate/quickjs-emscripten/LICENSE +0 -21
- package/node_modules/@tootallnate/quickjs-emscripten/README.md +0 -597
- package/node_modules/@tootallnate/quickjs-emscripten/c/interface.c +0 -819
- package/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.d.ts +0 -24
- package/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js +0 -53
- package/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.d.ts +0 -48
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js +0 -58
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context.d.ts +0 -371
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context.js +0 -691
- package/node_modules/@tootallnate/quickjs-emscripten/dist/context.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/debug.d.ts +0 -5
- package/node_modules/@tootallnate/quickjs-emscripten/dist/debug.js +0 -6
- package/node_modules/@tootallnate/quickjs-emscripten/dist/debug.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/deferred-promise.d.ts +0 -75
- package/node_modules/@tootallnate/quickjs-emscripten/dist/deferred-promise.js +0 -96
- package/node_modules/@tootallnate/quickjs-emscripten/dist/deferred-promise.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/emscripten-types.d.ts +0 -97
- package/node_modules/@tootallnate/quickjs-emscripten/dist/emscripten-types.js +0 -15
- package/node_modules/@tootallnate/quickjs-emscripten/dist/emscripten-types.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/errors.d.ts +0 -28
- package/node_modules/@tootallnate/quickjs-emscripten/dist/errors.js +0 -58
- package/node_modules/@tootallnate/quickjs-emscripten/dist/errors.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/esmHelpers.d.ts +0 -9
- package/node_modules/@tootallnate/quickjs-emscripten/dist/esmHelpers.js +0 -19
- package/node_modules/@tootallnate/quickjs-emscripten/dist/esmHelpers.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/emscripten-module.WASM_RELEASE_SYNC.d.ts +0 -5
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/emscripten-module.WASM_RELEASE_SYNC.js +0 -387
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/emscripten-module.WASM_RELEASE_SYNC.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/ffi.WASM_RELEASE_SYNC.d.ts +0 -67
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/ffi.WASM_RELEASE_SYNC.js +0 -71
- package/node_modules/@tootallnate/quickjs-emscripten/dist/generated/ffi.WASM_RELEASE_SYNC.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/index.d.ts +0 -75
- package/node_modules/@tootallnate/quickjs-emscripten/dist/index.js +0 -128
- package/node_modules/@tootallnate/quickjs-emscripten/dist/index.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/lifetime.d.ts +0 -115
- package/node_modules/@tootallnate/quickjs-emscripten/dist/lifetime.js +0 -227
- package/node_modules/@tootallnate/quickjs-emscripten/dist/lifetime.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/memory.d.ts +0 -18
- package/node_modules/@tootallnate/quickjs-emscripten/dist/memory.js +0 -41
- package/node_modules/@tootallnate/quickjs-emscripten/dist/memory.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-asyncify.d.ts +0 -53
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-asyncify.js +0 -97
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-asyncify.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-test.d.ts +0 -27
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-test.js +0 -77
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module-test.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module.d.ts +0 -152
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module.js +0 -302
- package/node_modules/@tootallnate/quickjs-emscripten/dist/module.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime-asyncify.d.ts +0 -38
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime-asyncify.js +0 -49
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime-asyncify.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime.d.ts +0 -174
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime.js +0 -300
- package/node_modules/@tootallnate/quickjs-emscripten/dist/runtime.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types-ffi.d.ts +0 -114
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types-ffi.js +0 -38
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types-ffi.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types.d.ts +0 -158
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types.js +0 -58
- package/node_modules/@tootallnate/quickjs-emscripten/dist/types.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/variants.d.ts +0 -113
- package/node_modules/@tootallnate/quickjs-emscripten/dist/variants.js +0 -169
- package/node_modules/@tootallnate/quickjs-emscripten/dist/variants.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/dist/vm-interface.d.ts +0 -68
- package/node_modules/@tootallnate/quickjs-emscripten/dist/vm-interface.js +0 -12
- package/node_modules/@tootallnate/quickjs-emscripten/dist/vm-interface.js.map +0 -1
- package/node_modules/@tootallnate/quickjs-emscripten/package.json +0 -60
- package/node_modules/@types/mime-types/LICENSE +0 -21
- package/node_modules/@types/mime-types/README.md +0 -28
- package/node_modules/@types/mime-types/index.d.ts +0 -9
- package/node_modules/@types/mime-types/package.json +0 -25
- package/node_modules/@types/yauzl/LICENSE +0 -21
- package/node_modules/@types/yauzl/README.md +0 -15
- package/node_modules/@types/yauzl/index.d.ts +0 -110
- package/node_modules/@types/yauzl/package.json +0 -27
- package/node_modules/ansi-regex/index.d.ts +0 -33
- package/node_modules/ansi-regex/index.js +0 -14
- package/node_modules/ansi-regex/license +0 -9
- package/node_modules/ansi-regex/package.json +0 -61
- package/node_modules/ansi-regex/readme.md +0 -66
- package/node_modules/ansi-styles/index.d.ts +0 -345
- package/node_modules/ansi-styles/index.js +0 -163
- package/node_modules/ansi-styles/license +0 -9
- package/node_modules/ansi-styles/package.json +0 -56
- package/node_modules/ansi-styles/readme.md +0 -152
- package/node_modules/any-promise/.jshintrc +0 -4
- package/node_modules/any-promise/.npmignore +0 -7
- package/node_modules/any-promise/LICENSE +0 -19
- package/node_modules/any-promise/README.md +0 -161
- package/node_modules/any-promise/implementation.d.ts +0 -3
- package/node_modules/any-promise/implementation.js +0 -1
- package/node_modules/any-promise/index.d.ts +0 -73
- package/node_modules/any-promise/index.js +0 -1
- package/node_modules/any-promise/loader.js +0 -78
- package/node_modules/any-promise/optional.js +0 -6
- package/node_modules/any-promise/package.json +0 -45
- package/node_modules/any-promise/register/bluebird.d.ts +0 -1
- package/node_modules/any-promise/register/bluebird.js +0 -2
- package/node_modules/any-promise/register/es6-promise.d.ts +0 -1
- package/node_modules/any-promise/register/es6-promise.js +0 -2
- package/node_modules/any-promise/register/lie.d.ts +0 -1
- package/node_modules/any-promise/register/lie.js +0 -2
- package/node_modules/any-promise/register/native-promise-only.d.ts +0 -1
- package/node_modules/any-promise/register/native-promise-only.js +0 -2
- package/node_modules/any-promise/register/pinkie.d.ts +0 -1
- package/node_modules/any-promise/register/pinkie.js +0 -2
- package/node_modules/any-promise/register/promise.d.ts +0 -1
- package/node_modules/any-promise/register/promise.js +0 -2
- package/node_modules/any-promise/register/q.d.ts +0 -1
- package/node_modules/any-promise/register/q.js +0 -2
- package/node_modules/any-promise/register/rsvp.d.ts +0 -1
- package/node_modules/any-promise/register/rsvp.js +0 -2
- package/node_modules/any-promise/register/vow.d.ts +0 -1
- package/node_modules/any-promise/register/vow.js +0 -2
- package/node_modules/any-promise/register/when.d.ts +0 -1
- package/node_modules/any-promise/register/when.js +0 -2
- package/node_modules/any-promise/register-shim.js +0 -18
- package/node_modules/any-promise/register.d.ts +0 -17
- package/node_modules/any-promise/register.js +0 -94
- package/node_modules/argparse/CHANGELOG.md +0 -216
- package/node_modules/ast-types/.github/dependabot.yml +0 -9
- package/node_modules/ast-types/.github/workflows/main.yml +0 -29
- package/node_modules/ast-types/LICENSE +0 -20
- package/node_modules/ast-types/README.md +0 -512
- package/node_modules/ast-types/def/babel-core.d.ts +0 -2
- package/node_modules/ast-types/def/babel-core.js +0 -256
- package/node_modules/ast-types/def/babel.d.ts +0 -2
- package/node_modules/ast-types/def/babel.js +0 -11
- package/node_modules/ast-types/def/core.d.ts +0 -2
- package/node_modules/ast-types/def/core.js +0 -298
- package/node_modules/ast-types/def/es-proposals.d.ts +0 -2
- package/node_modules/ast-types/def/es-proposals.js +0 -33
- package/node_modules/ast-types/def/es2020.d.ts +0 -2
- package/node_modules/ast-types/def/es2020.js +0 -16
- package/node_modules/ast-types/def/es6.d.ts +0 -2
- package/node_modules/ast-types/def/es6.js +0 -210
- package/node_modules/ast-types/def/es7.d.ts +0 -2
- package/node_modules/ast-types/def/es7.js +0 -34
- package/node_modules/ast-types/def/esprima.d.ts +0 -2
- package/node_modules/ast-types/def/esprima.js +0 -49
- package/node_modules/ast-types/def/flow.d.ts +0 -2
- package/node_modules/ast-types/def/flow.js +0 -292
- package/node_modules/ast-types/def/jsx.d.ts +0 -2
- package/node_modules/ast-types/def/jsx.js +0 -103
- package/node_modules/ast-types/def/type-annotations.d.ts +0 -7
- package/node_modules/ast-types/def/type-annotations.js +0 -40
- package/node_modules/ast-types/def/typescript.d.ts +0 -2
- package/node_modules/ast-types/def/typescript.js +0 -344
- package/node_modules/ast-types/fork.d.ts +0 -42
- package/node_modules/ast-types/fork.js +0 -52
- package/node_modules/ast-types/gen/builders.d.ts +0 -2584
- package/node_modules/ast-types/gen/builders.js +0 -2
- package/node_modules/ast-types/gen/kinds.d.ts +0 -264
- package/node_modules/ast-types/gen/kinds.js +0 -2
- package/node_modules/ast-types/gen/namedTypes.d.ts +0 -1809
- package/node_modules/ast-types/gen/namedTypes.js +0 -6
- package/node_modules/ast-types/gen/visitor.d.ts +0 -268
- package/node_modules/ast-types/gen/visitor.js +0 -2
- package/node_modules/ast-types/lib/equiv.d.ts +0 -5
- package/node_modules/ast-types/lib/equiv.js +0 -154
- package/node_modules/ast-types/lib/node-path.d.ts +0 -22
- package/node_modules/ast-types/lib/node-path.js +0 -411
- package/node_modules/ast-types/lib/path-visitor.d.ts +0 -52
- package/node_modules/ast-types/lib/path-visitor.js +0 -343
- package/node_modules/ast-types/lib/path.d.ts +0 -25
- package/node_modules/ast-types/lib/path.js +0 -331
- package/node_modules/ast-types/lib/scope.d.ts +0 -26
- package/node_modules/ast-types/lib/scope.js +0 -318
- package/node_modules/ast-types/lib/shared.d.ts +0 -13
- package/node_modules/ast-types/lib/shared.js +0 -47
- package/node_modules/ast-types/lib/types.d.ts +0 -136
- package/node_modules/ast-types/lib/types.js +0 -780
- package/node_modules/ast-types/main.d.ts +0 -28
- package/node_modules/ast-types/main.js +0 -53
- package/node_modules/ast-types/package.json +0 -65
- package/node_modules/ast-types/tsconfig.json +0 -21
- package/node_modules/ast-types/types.d.ts +0 -6
- package/node_modules/ast-types/types.js +0 -2
- package/node_modules/basic-ftp/LICENSE.txt +0 -19
- package/node_modules/basic-ftp/README.md +0 -244
- package/node_modules/basic-ftp/dist/Client.d.ts +0 -340
- package/node_modules/basic-ftp/dist/Client.js +0 -785
- package/node_modules/basic-ftp/dist/FileInfo.d.ts +0 -80
- package/node_modules/basic-ftp/dist/FileInfo.js +0 -92
- package/node_modules/basic-ftp/dist/FtpContext.d.ts +0 -175
- package/node_modules/basic-ftp/dist/FtpContext.js +0 -375
- package/node_modules/basic-ftp/dist/ProgressTracker.d.ts +0 -45
- package/node_modules/basic-ftp/dist/ProgressTracker.js +0 -72
- package/node_modules/basic-ftp/dist/StringEncoding.d.ts +0 -1
- package/node_modules/basic-ftp/dist/StringEncoding.js +0 -2
- package/node_modules/basic-ftp/dist/StringWriter.d.ts +0 -10
- package/node_modules/basic-ftp/dist/StringWriter.js +0 -29
- package/node_modules/basic-ftp/dist/index.d.ts +0 -9
- package/node_modules/basic-ftp/dist/index.js +0 -28
- package/node_modules/basic-ftp/dist/netUtils.d.ts +0 -21
- package/node_modules/basic-ftp/dist/netUtils.js +0 -66
- package/node_modules/basic-ftp/dist/parseControlResponse.d.ts +0 -22
- package/node_modules/basic-ftp/dist/parseControlResponse.js +0 -66
- package/node_modules/basic-ftp/dist/parseList.d.ts +0 -5
- package/node_modules/basic-ftp/dist/parseList.js +0 -79
- package/node_modules/basic-ftp/dist/parseListDOS.d.ts +0 -12
- package/node_modules/basic-ftp/dist/parseListDOS.js +0 -52
- package/node_modules/basic-ftp/dist/parseListMLSD.d.ts +0 -20
- package/node_modules/basic-ftp/dist/parseListMLSD.js +0 -187
- package/node_modules/basic-ftp/dist/parseListUnix.d.ts +0 -12
- package/node_modules/basic-ftp/dist/parseListUnix.js +0 -155
- package/node_modules/basic-ftp/dist/transfer.d.ts +0 -39
- package/node_modules/basic-ftp/dist/transfer.js +0 -318
- package/node_modules/basic-ftp/package.json +0 -52
- package/node_modules/buffer-crc32/LICENSE +0 -19
- package/node_modules/buffer-crc32/README.md +0 -47
- package/node_modules/buffer-crc32/index.js +0 -111
- package/node_modules/buffer-crc32/package.json +0 -39
- package/node_modules/cli-highlight/LICENSE.txt +0 -15
- package/node_modules/cli-highlight/README.md +0 -88
- package/node_modules/cli-highlight/bin/highlight +0 -2
- package/node_modules/cli-highlight/dist/cli.d.ts +0 -1
- package/node_modules/cli-highlight/dist/cli.js +0 -102
- package/node_modules/cli-highlight/dist/cli.js.map +0 -1
- package/node_modules/cli-highlight/dist/index.d.ts +0 -53
- package/node_modules/cli-highlight/dist/index.js +0 -112
- package/node_modules/cli-highlight/dist/index.js.map +0 -1
- package/node_modules/cli-highlight/dist/test/test.d.ts +0 -1
- package/node_modules/cli-highlight/dist/test/test.js +0 -62
- package/node_modules/cli-highlight/dist/test/test.js.map +0 -1
- package/node_modules/cli-highlight/dist/theme.d.ts +0 -270
- package/node_modules/cli-highlight/dist/theme.js +0 -265
- package/node_modules/cli-highlight/dist/theme.js.map +0 -1
- package/node_modules/cli-highlight/node_modules/chalk/index.d.ts +0 -415
- package/node_modules/cli-highlight/node_modules/chalk/license +0 -9
- package/node_modules/cli-highlight/node_modules/chalk/package.json +0 -68
- package/node_modules/cli-highlight/node_modules/chalk/readme.md +0 -341
- package/node_modules/cli-highlight/node_modules/chalk/source/index.js +0 -229
- package/node_modules/cli-highlight/node_modules/chalk/source/templates.js +0 -134
- package/node_modules/cli-highlight/node_modules/chalk/source/util.js +0 -39
- package/node_modules/cli-highlight/package.json +0 -129
- package/node_modules/cliui/CHANGELOG.md +0 -121
- package/node_modules/cliui/LICENSE.txt +0 -14
- package/node_modules/cliui/README.md +0 -141
- package/node_modules/cliui/build/index.cjs +0 -302
- package/node_modules/cliui/build/lib/index.js +0 -287
- package/node_modules/cliui/build/lib/string-utils.js +0 -27
- package/node_modules/cliui/index.mjs +0 -13
- package/node_modules/cliui/node_modules/ansi-regex/index.d.ts +0 -37
- package/node_modules/cliui/node_modules/ansi-regex/index.js +0 -10
- package/node_modules/cliui/node_modules/ansi-regex/license +0 -9
- package/node_modules/cliui/node_modules/ansi-regex/package.json +0 -55
- package/node_modules/cliui/node_modules/ansi-regex/readme.md +0 -78
- package/node_modules/cliui/node_modules/strip-ansi/index.d.ts +0 -17
- package/node_modules/cliui/node_modules/strip-ansi/index.js +0 -4
- package/node_modules/cliui/node_modules/strip-ansi/license +0 -9
- package/node_modules/cliui/node_modules/strip-ansi/package.json +0 -54
- package/node_modules/cliui/node_modules/strip-ansi/readme.md +0 -46
- package/node_modules/cliui/package.json +0 -83
- package/node_modules/color-convert/CHANGELOG.md +0 -54
- package/node_modules/color-convert/LICENSE +0 -21
- package/node_modules/color-convert/README.md +0 -68
- package/node_modules/color-convert/conversions.js +0 -839
- package/node_modules/color-convert/index.js +0 -81
- package/node_modules/color-convert/package.json +0 -48
- package/node_modules/color-convert/route.js +0 -97
- package/node_modules/color-name/LICENSE +0 -8
- package/node_modules/color-name/README.md +0 -11
- package/node_modules/color-name/index.js +0 -152
- package/node_modules/color-name/package.json +0 -28
- package/node_modules/degenerator/README.md +0 -117
- package/node_modules/degenerator/dist/compile.d.ts +0 -11
- package/node_modules/degenerator/dist/compile.d.ts.map +0 -1
- package/node_modules/degenerator/dist/compile.js +0 -107
- package/node_modules/degenerator/dist/compile.js.map +0 -1
- package/node_modules/degenerator/dist/degenerator.d.ts +0 -12
- package/node_modules/degenerator/dist/degenerator.d.ts.map +0 -1
- package/node_modules/degenerator/dist/degenerator.js +0 -156
- package/node_modules/degenerator/dist/degenerator.js.map +0 -1
- package/node_modules/degenerator/dist/index.d.ts +0 -3
- package/node_modules/degenerator/dist/index.d.ts.map +0 -1
- package/node_modules/degenerator/dist/index.js +0 -19
- package/node_modules/degenerator/dist/index.js.map +0 -1
- package/node_modules/degenerator/package.json +0 -42
- package/node_modules/emoji-regex/LICENSE-MIT.txt +0 -20
- package/node_modules/emoji-regex/README.md +0 -73
- package/node_modules/emoji-regex/es2015/index.js +0 -6
- package/node_modules/emoji-regex/es2015/text.js +0 -6
- package/node_modules/emoji-regex/index.d.ts +0 -23
- package/node_modules/emoji-regex/index.js +0 -6
- package/node_modules/emoji-regex/package.json +0 -50
- package/node_modules/emoji-regex/text.js +0 -6
- package/node_modules/end-of-stream/LICENSE +0 -21
- package/node_modules/end-of-stream/README.md +0 -54
- package/node_modules/end-of-stream/index.js +0 -96
- package/node_modules/end-of-stream/package.json +0 -37
- package/node_modules/escalade/dist/index.js +0 -22
- package/node_modules/escalade/dist/index.mjs +0 -22
- package/node_modules/escalade/index.d.mts +0 -11
- package/node_modules/escalade/index.d.ts +0 -15
- package/node_modules/escalade/license +0 -9
- package/node_modules/escalade/package.json +0 -74
- package/node_modules/escalade/readme.md +0 -211
- package/node_modules/escalade/sync/index.d.mts +0 -9
- package/node_modules/escalade/sync/index.d.ts +0 -13
- package/node_modules/escalade/sync/index.js +0 -18
- package/node_modules/escalade/sync/index.mjs +0 -18
- package/node_modules/escodegen/LICENSE.BSD +0 -21
- package/node_modules/escodegen/README.md +0 -84
- package/node_modules/escodegen/bin/escodegen.js +0 -77
- package/node_modules/escodegen/bin/esgenerate.js +0 -64
- package/node_modules/escodegen/escodegen.js +0 -2667
- package/node_modules/escodegen/package.json +0 -63
- package/node_modules/esprima/ChangeLog +0 -235
- package/node_modules/esprima/LICENSE.BSD +0 -21
- package/node_modules/esprima/README.md +0 -46
- package/node_modules/esprima/bin/esparse.js +0 -139
- package/node_modules/esprima/bin/esvalidate.js +0 -236
- package/node_modules/esprima/dist/esprima.js +0 -6709
- package/node_modules/esprima/package.json +0 -112
- package/node_modules/estraverse/.jshintrc +0 -16
- package/node_modules/estraverse/LICENSE.BSD +0 -19
- package/node_modules/estraverse/README.md +0 -153
- package/node_modules/estraverse/estraverse.js +0 -805
- package/node_modules/estraverse/gulpfile.js +0 -70
- package/node_modules/estraverse/package.json +0 -40
- package/node_modules/esutils/LICENSE.BSD +0 -19
- package/node_modules/esutils/README.md +0 -174
- package/node_modules/esutils/lib/ast.js +0 -144
- package/node_modules/esutils/lib/code.js +0 -135
- package/node_modules/esutils/lib/keyword.js +0 -165
- package/node_modules/esutils/lib/utils.js +0 -33
- package/node_modules/esutils/package.json +0 -44
- package/node_modules/extract-zip/LICENSE +0 -23
- package/node_modules/extract-zip/cli.js +0 -19
- package/node_modules/extract-zip/index.d.ts +0 -21
- package/node_modules/extract-zip/index.js +0 -173
- package/node_modules/extract-zip/package.json +0 -80
- package/node_modules/extract-zip/readme.md +0 -57
- package/node_modules/fd-slicer/.npmignore +0 -2
- package/node_modules/fd-slicer/.travis.yml +0 -7
- package/node_modules/fd-slicer/CHANGELOG.md +0 -49
- package/node_modules/fd-slicer/LICENSE +0 -21
- package/node_modules/fd-slicer/README.md +0 -199
- package/node_modules/fd-slicer/index.js +0 -296
- package/node_modules/fd-slicer/package.json +0 -36
- package/node_modules/fd-slicer/test/test.js +0 -350
- package/node_modules/file-type/core.d.ts +0 -253
- package/node_modules/file-type/core.js +0 -2899
- package/node_modules/file-type/index.d.ts +0 -98
- package/node_modules/file-type/index.js +0 -163
- package/node_modules/file-type/license +0 -9
- package/node_modules/file-type/package.json +0 -290
- package/node_modules/file-type/readme.md +0 -667
- package/node_modules/file-type/supported.js +0 -360
- package/node_modules/file-type/util.js +0 -60
- package/node_modules/get-caller-file/LICENSE.md +0 -6
- package/node_modules/get-caller-file/README.md +0 -41
- package/node_modules/get-caller-file/index.d.ts +0 -2
- package/node_modules/get-caller-file/index.js +0 -22
- package/node_modules/get-caller-file/index.js.map +0 -1
- package/node_modules/get-caller-file/package.json +0 -42
- package/node_modules/get-stream/buffer-stream.js +0 -52
- package/node_modules/get-stream/index.d.ts +0 -108
- package/node_modules/get-stream/index.js +0 -60
- package/node_modules/get-stream/license +0 -9
- package/node_modules/get-stream/package.json +0 -50
- package/node_modules/get-stream/readme.md +0 -124
- package/node_modules/get-uri/LICENSE +0 -22
- package/node_modules/get-uri/README.md +0 -109
- package/node_modules/get-uri/dist/data.d.ts +0 -16
- package/node_modules/get-uri/dist/data.js +0 -43
- package/node_modules/get-uri/dist/data.js.map +0 -1
- package/node_modules/get-uri/dist/file.d.ts +0 -17
- package/node_modules/get-uri/dist/file.js +0 -57
- package/node_modules/get-uri/dist/file.js.map +0 -1
- package/node_modules/get-uri/dist/ftp.d.ts +0 -14
- package/node_modules/get-uri/dist/ftp.js +0 -93
- package/node_modules/get-uri/dist/ftp.js.map +0 -1
- package/node_modules/get-uri/dist/http-error.d.ts +0 -8
- package/node_modules/get-uri/dist/http-error.js +0 -15
- package/node_modules/get-uri/dist/http-error.js.map +0 -1
- package/node_modules/get-uri/dist/http.d.ts +0 -29
- package/node_modules/get-uri/dist/http.js +0 -191
- package/node_modules/get-uri/dist/http.js.map +0 -1
- package/node_modules/get-uri/dist/https.d.ts +0 -6
- package/node_modules/get-uri/dist/https.js +0 -16
- package/node_modules/get-uri/dist/https.js.map +0 -1
- package/node_modules/get-uri/dist/index.d.ts +0 -37
- package/node_modules/get-uri/dist/index.js +0 -57
- package/node_modules/get-uri/dist/index.js.map +0 -1
- package/node_modules/get-uri/dist/notfound.d.ts +0 -10
- package/node_modules/get-uri/dist/notfound.js +0 -16
- package/node_modules/get-uri/dist/notfound.js.map +0 -1
- package/node_modules/get-uri/dist/notmodified.d.ts +0 -10
- package/node_modules/get-uri/dist/notmodified.js +0 -17
- package/node_modules/get-uri/dist/notmodified.js.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/LICENSE +0 -22
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/README.md +0 -61
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/common.d.ts +0 -17
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/common.d.ts.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/common.js +0 -54
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/common.js.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/index.d.ts +0 -8
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/index.d.ts.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/index.js +0 -48
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/index.js.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/node.d.ts +0 -8
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/node.d.ts.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/node.js +0 -26
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/dist/node.js.map +0 -1
- package/node_modules/get-uri/node_modules/data-uri-to-buffer/package.json +0 -48
- package/node_modules/get-uri/package.json +0 -58
- package/node_modules/has-flag/index.d.ts +0 -39
- package/node_modules/has-flag/index.js +0 -8
- package/node_modules/has-flag/license +0 -9
- package/node_modules/has-flag/package.json +0 -46
- package/node_modules/has-flag/readme.md +0 -89
- package/node_modules/ieee754/LICENSE +0 -11
- package/node_modules/ieee754/README.md +0 -51
- package/node_modules/ieee754/index.d.ts +0 -10
- package/node_modules/ieee754/index.js +0 -85
- package/node_modules/ieee754/package.json +0 -52
- package/node_modules/ip-address/LICENSE +0 -19
- package/node_modules/ip-address/README.md +0 -278
- package/node_modules/ip-address/dist/address-error.d.ts +0 -4
- package/node_modules/ip-address/dist/address-error.js +0 -12
- package/node_modules/ip-address/dist/address-error.js.map +0 -1
- package/node_modules/ip-address/dist/common.d.ts +0 -20
- package/node_modules/ip-address/dist/common.js +0 -67
- package/node_modules/ip-address/dist/common.js.map +0 -1
- package/node_modules/ip-address/dist/ip-address.d.ts +0 -7
- package/node_modules/ip-address/dist/ip-address.js +0 -35
- package/node_modules/ip-address/dist/ip-address.js.map +0 -1
- package/node_modules/ip-address/dist/ipv4.d.ts +0 -267
- package/node_modules/ip-address/dist/ipv4.js +0 -485
- package/node_modules/ip-address/dist/ipv4.js.map +0 -1
- package/node_modules/ip-address/dist/ipv6.d.ts +0 -489
- package/node_modules/ip-address/dist/ipv6.js +0 -1217
- package/node_modules/ip-address/dist/ipv6.js.map +0 -1
- package/node_modules/ip-address/dist/v4/constants.d.ts +0 -4
- package/node_modules/ip-address/dist/v4/constants.js +0 -8
- package/node_modules/ip-address/dist/v4/constants.js.map +0 -1
- package/node_modules/ip-address/dist/v6/constants.d.ts +0 -44
- package/node_modules/ip-address/dist/v6/constants.js +0 -81
- package/node_modules/ip-address/dist/v6/constants.js.map +0 -1
- package/node_modules/ip-address/dist/v6/helpers.d.ts +0 -18
- package/node_modules/ip-address/dist/v6/helpers.js +0 -54
- package/node_modules/ip-address/dist/v6/helpers.js.map +0 -1
- package/node_modules/ip-address/dist/v6/regular-expressions.d.ts +0 -5
- package/node_modules/ip-address/dist/v6/regular-expressions.js +0 -95
- package/node_modules/ip-address/dist/v6/regular-expressions.js.map +0 -1
- package/node_modules/ip-address/package.json +0 -88
- package/node_modules/is-fullwidth-code-point/index.d.ts +0 -17
- package/node_modules/is-fullwidth-code-point/index.js +0 -50
- package/node_modules/is-fullwidth-code-point/license +0 -9
- package/node_modules/is-fullwidth-code-point/package.json +0 -42
- package/node_modules/is-fullwidth-code-point/readme.md +0 -39
- package/node_modules/mime-db/HISTORY.md +0 -541
- package/node_modules/mime-db/LICENSE +0 -23
- package/node_modules/mime-db/README.md +0 -109
- package/node_modules/mime-db/db.json +0 -9342
- package/node_modules/mime-db/index.js +0 -12
- package/node_modules/mime-db/package.json +0 -56
- package/node_modules/mime-types/HISTORY.md +0 -428
- package/node_modules/mime-types/LICENSE +0 -23
- package/node_modules/mime-types/README.md +0 -126
- package/node_modules/mime-types/index.js +0 -211
- package/node_modules/mime-types/mimeScore.js +0 -57
- package/node_modules/mime-types/package.json +0 -49
- package/node_modules/mz/HISTORY.md +0 -66
- package/node_modules/mz/LICENSE +0 -22
- package/node_modules/mz/README.md +0 -106
- package/node_modules/mz/child_process.js +0 -8
- package/node_modules/mz/crypto.js +0 -9
- package/node_modules/mz/dns.js +0 -16
- package/node_modules/mz/fs.js +0 -62
- package/node_modules/mz/index.js +0 -8
- package/node_modules/mz/package.json +0 -44
- package/node_modules/mz/readline.js +0 -64
- package/node_modules/mz/zlib.js +0 -13
- package/node_modules/netmask/CHANGELOG.md +0 -66
- package/node_modules/netmask/LICENSE.md +0 -21
- package/node_modules/netmask/README.md +0 -112
- package/node_modules/netmask/dist/netmask.d.ts +0 -21
- package/node_modules/netmask/dist/netmask.js +0 -68
- package/node_modules/netmask/dist/netmask4.d.ts +0 -20
- package/node_modules/netmask/dist/netmask4.js +0 -189
- package/node_modules/netmask/dist/netmask6.d.ts +0 -20
- package/node_modules/netmask/dist/netmask6.js +0 -187
- package/node_modules/netmask/package.json +0 -45
- package/node_modules/object-assign/index.js +0 -90
- package/node_modules/object-assign/license +0 -21
- package/node_modules/object-assign/package.json +0 -42
- package/node_modules/object-assign/readme.md +0 -61
- package/node_modules/once/LICENSE +0 -15
- package/node_modules/once/README.md +0 -79
- package/node_modules/once/once.js +0 -42
- package/node_modules/once/package.json +0 -33
- package/node_modules/pac-proxy-agent/LICENSE +0 -22
- package/node_modules/pac-proxy-agent/README.md +0 -27
- package/node_modules/pac-proxy-agent/dist/index.d.ts +0 -60
- package/node_modules/pac-proxy-agent/dist/index.d.ts.map +0 -1
- package/node_modules/pac-proxy-agent/dist/index.js +0 -238
- package/node_modules/pac-proxy-agent/dist/index.js.map +0 -1
- package/node_modules/pac-proxy-agent/package.json +0 -58
- package/node_modules/pac-resolver/LICENSE +0 -22
- package/node_modules/pac-resolver/README.md +0 -59
- package/node_modules/pac-resolver/dist/dateRange.d.ts +0 -67
- package/node_modules/pac-resolver/dist/dateRange.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/dateRange.js +0 -73
- package/node_modules/pac-resolver/dist/dateRange.js.map +0 -1
- package/node_modules/pac-resolver/dist/dnsDomainIs.d.ts +0 -23
- package/node_modules/pac-resolver/dist/dnsDomainIs.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/dnsDomainIs.js +0 -30
- package/node_modules/pac-resolver/dist/dnsDomainIs.js.map +0 -1
- package/node_modules/pac-resolver/dist/dnsDomainLevels.d.ts +0 -18
- package/node_modules/pac-resolver/dist/dnsDomainLevels.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/dnsDomainLevels.js +0 -28
- package/node_modules/pac-resolver/dist/dnsDomainLevels.js.map +0 -1
- package/node_modules/pac-resolver/dist/dnsResolve.d.ts +0 -16
- package/node_modules/pac-resolver/dist/dnsResolve.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/dnsResolve.js +0 -32
- package/node_modules/pac-resolver/dist/dnsResolve.js.map +0 -1
- package/node_modules/pac-resolver/dist/index.d.ts +0 -50
- package/node_modules/pac-resolver/dist/index.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/index.js +0 -87
- package/node_modules/pac-resolver/dist/index.js.map +0 -1
- package/node_modules/pac-resolver/dist/ip.d.ts +0 -8
- package/node_modules/pac-resolver/dist/ip.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/ip.js +0 -50
- package/node_modules/pac-resolver/dist/ip.js.map +0 -1
- package/node_modules/pac-resolver/dist/isInNet.d.ts +0 -24
- package/node_modules/pac-resolver/dist/isInNet.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/isInNet.js +0 -42
- package/node_modules/pac-resolver/dist/isInNet.js.map +0 -1
- package/node_modules/pac-resolver/dist/isPlainHostName.d.ts +0 -18
- package/node_modules/pac-resolver/dist/isPlainHostName.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/isPlainHostName.js +0 -23
- package/node_modules/pac-resolver/dist/isPlainHostName.js.map +0 -1
- package/node_modules/pac-resolver/dist/isResolvable.d.ts +0 -8
- package/node_modules/pac-resolver/dist/isResolvable.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/isResolvable.js +0 -23
- package/node_modules/pac-resolver/dist/isResolvable.js.map +0 -1
- package/node_modules/pac-resolver/dist/localHostOrDomainIs.d.ts +0 -26
- package/node_modules/pac-resolver/dist/localHostOrDomainIs.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/localHostOrDomainIs.js +0 -40
- package/node_modules/pac-resolver/dist/localHostOrDomainIs.js.map +0 -1
- package/node_modules/pac-resolver/dist/myIpAddress.d.ts +0 -16
- package/node_modules/pac-resolver/dist/myIpAddress.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/myIpAddress.js +0 -50
- package/node_modules/pac-resolver/dist/myIpAddress.js.map +0 -1
- package/node_modules/pac-resolver/dist/shExpMatch.d.ts +0 -23
- package/node_modules/pac-resolver/dist/shExpMatch.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/shExpMatch.js +0 -41
- package/node_modules/pac-resolver/dist/shExpMatch.js.map +0 -1
- package/node_modules/pac-resolver/dist/timeRange.d.ts +0 -43
- package/node_modules/pac-resolver/dist/timeRange.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/timeRange.js +0 -92
- package/node_modules/pac-resolver/dist/timeRange.js.map +0 -1
- package/node_modules/pac-resolver/dist/util.d.ts +0 -6
- package/node_modules/pac-resolver/dist/util.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/util.js +0 -22
- package/node_modules/pac-resolver/dist/util.js.map +0 -1
- package/node_modules/pac-resolver/dist/weekdayRange.d.ts +0 -45
- package/node_modules/pac-resolver/dist/weekdayRange.d.ts.map +0 -1
- package/node_modules/pac-resolver/dist/weekdayRange.js +0 -91
- package/node_modules/pac-resolver/dist/weekdayRange.js.map +0 -1
- package/node_modules/pac-resolver/package.json +0 -47
- package/node_modules/parse5/LICENSE +0 -19
- package/node_modules/parse5/README.md +0 -38
- package/node_modules/parse5/lib/common/doctype.js +0 -162
- package/node_modules/parse5/lib/common/error-codes.js +0 -65
- package/node_modules/parse5/lib/common/foreign-content.js +0 -265
- package/node_modules/parse5/lib/common/html.js +0 -272
- package/node_modules/parse5/lib/common/unicode.js +0 -109
- package/node_modules/parse5/lib/extensions/error-reporting/mixin-base.js +0 -43
- package/node_modules/parse5/lib/extensions/error-reporting/parser-mixin.js +0 -52
- package/node_modules/parse5/lib/extensions/error-reporting/preprocessor-mixin.js +0 -24
- package/node_modules/parse5/lib/extensions/error-reporting/tokenizer-mixin.js +0 -17
- package/node_modules/parse5/lib/extensions/location-info/open-element-stack-mixin.js +0 -35
- package/node_modules/parse5/lib/extensions/location-info/parser-mixin.js +0 -222
- package/node_modules/parse5/lib/extensions/location-info/tokenizer-mixin.js +0 -146
- package/node_modules/parse5/lib/extensions/position-tracking/preprocessor-mixin.js +0 -64
- package/node_modules/parse5/lib/index.js +0 -29
- package/node_modules/parse5/lib/parser/formatting-element-list.js +0 -181
- package/node_modules/parse5/lib/parser/index.js +0 -2956
- package/node_modules/parse5/lib/parser/open-element-stack.js +0 -482
- package/node_modules/parse5/lib/serializer/index.js +0 -176
- package/node_modules/parse5/lib/tokenizer/index.js +0 -2196
- package/node_modules/parse5/lib/tokenizer/named-entity-data.js +0 -5
- package/node_modules/parse5/lib/tokenizer/preprocessor.js +0 -159
- package/node_modules/parse5/lib/tree-adapters/default.js +0 -217
- package/node_modules/parse5/lib/utils/merge-options.js +0 -13
- package/node_modules/parse5/lib/utils/mixin.js +0 -39
- package/node_modules/parse5/package.json +0 -35
- package/node_modules/parse5-htmlparser2-tree-adapter/LICENSE +0 -19
- package/node_modules/parse5-htmlparser2-tree-adapter/README.md +0 -34
- package/node_modules/parse5-htmlparser2-tree-adapter/lib/index.js +0 -348
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/LICENSE +0 -19
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/README.md +0 -38
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/common/doctype.js +0 -162
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/common/error-codes.js +0 -65
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/common/foreign-content.js +0 -265
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/common/html.js +0 -272
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/common/unicode.js +0 -109
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/error-reporting/mixin-base.js +0 -43
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/error-reporting/parser-mixin.js +0 -52
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/error-reporting/preprocessor-mixin.js +0 -24
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/error-reporting/tokenizer-mixin.js +0 -17
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/location-info/open-element-stack-mixin.js +0 -35
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/location-info/parser-mixin.js +0 -223
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/location-info/tokenizer-mixin.js +0 -146
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/extensions/position-tracking/preprocessor-mixin.js +0 -64
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/index.js +0 -29
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/parser/formatting-element-list.js +0 -181
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/parser/index.js +0 -2956
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/parser/open-element-stack.js +0 -482
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/serializer/index.js +0 -176
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/tokenizer/index.js +0 -2196
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/tokenizer/named-entity-data.js +0 -5
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/tokenizer/preprocessor.js +0 -159
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/tree-adapters/default.js +0 -221
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/utils/merge-options.js +0 -13
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/lib/utils/mixin.js +0 -39
- package/node_modules/parse5-htmlparser2-tree-adapter/node_modules/parse5/package.json +0 -35
- package/node_modules/parse5-htmlparser2-tree-adapter/package.json +0 -27
- package/node_modules/pend/LICENSE +0 -23
- package/node_modules/pend/README.md +0 -41
- package/node_modules/pend/index.js +0 -55
- package/node_modules/pend/package.json +0 -18
- package/node_modules/pend/test.js +0 -137
- package/node_modules/proper-lockfile/CHANGELOG.md +0 -108
- package/node_modules/proxy-agent/LICENSE +0 -22
- package/node_modules/proxy-agent/README.md +0 -59
- package/node_modules/proxy-agent/dist/index.d.ts +0 -62
- package/node_modules/proxy-agent/dist/index.d.ts.map +0 -1
- package/node_modules/proxy-agent/dist/index.js +0 -138
- package/node_modules/proxy-agent/dist/index.js.map +0 -1
- package/node_modules/proxy-agent/node_modules/lru-cache/LICENSE +0 -15
- package/node_modules/proxy-agent/node_modules/lru-cache/README.md +0 -1117
- package/node_modules/proxy-agent/node_modules/lru-cache/index.d.ts +0 -869
- package/node_modules/proxy-agent/node_modules/lru-cache/index.js +0 -1227
- package/node_modules/proxy-agent/node_modules/lru-cache/index.mjs +0 -1227
- package/node_modules/proxy-agent/node_modules/lru-cache/package.json +0 -96
- package/node_modules/proxy-agent/package.json +0 -60
- package/node_modules/proxy-from-env/.eslintrc +0 -29
- package/node_modules/proxy-from-env/.travis.yml +0 -10
- package/node_modules/proxy-from-env/LICENSE +0 -20
- package/node_modules/proxy-from-env/README.md +0 -131
- package/node_modules/proxy-from-env/index.js +0 -108
- package/node_modules/proxy-from-env/package.json +0 -34
- package/node_modules/proxy-from-env/test.js +0 -483
- package/node_modules/pump/.github/FUNDING.yml +0 -2
- package/node_modules/pump/.travis.yml +0 -5
- package/node_modules/pump/LICENSE +0 -21
- package/node_modules/pump/README.md +0 -74
- package/node_modules/pump/SECURITY.md +0 -5
- package/node_modules/pump/empty.js +0 -1
- package/node_modules/pump/index.js +0 -86
- package/node_modules/pump/package.json +0 -30
- package/node_modules/pump/test-browser.js +0 -66
- package/node_modules/pump/test-node.js +0 -53
- package/node_modules/require-directory/.jshintrc +0 -67
- package/node_modules/require-directory/.npmignore +0 -1
- package/node_modules/require-directory/.travis.yml +0 -3
- package/node_modules/require-directory/LICENSE +0 -22
- package/node_modules/require-directory/README.markdown +0 -184
- package/node_modules/require-directory/index.js +0 -86
- package/node_modules/require-directory/package.json +0 -40
- package/node_modules/smart-buffer/.prettierrc.yaml +0 -5
- package/node_modules/smart-buffer/.travis.yml +0 -13
- package/node_modules/smart-buffer/LICENSE +0 -20
- package/node_modules/smart-buffer/README.md +0 -633
- package/node_modules/smart-buffer/build/smartbuffer.js +0 -1233
- package/node_modules/smart-buffer/build/smartbuffer.js.map +0 -1
- package/node_modules/smart-buffer/build/utils.js +0 -108
- package/node_modules/smart-buffer/build/utils.js.map +0 -1
- package/node_modules/smart-buffer/docs/CHANGELOG.md +0 -70
- package/node_modules/smart-buffer/docs/README_v3.md +0 -367
- package/node_modules/smart-buffer/docs/ROADMAP.md +0 -0
- package/node_modules/smart-buffer/package.json +0 -79
- package/node_modules/smart-buffer/typings/smartbuffer.d.ts +0 -755
- package/node_modules/smart-buffer/typings/utils.d.ts +0 -66
- package/node_modules/socks/.eslintrc.cjs +0 -11
- package/node_modules/socks/.prettierrc.yaml +0 -7
- package/node_modules/socks/LICENSE +0 -20
- package/node_modules/socks/README.md +0 -686
- package/node_modules/socks/build/client/socksclient.js +0 -793
- package/node_modules/socks/build/client/socksclient.js.map +0 -1
- package/node_modules/socks/build/common/constants.js +0 -108
- package/node_modules/socks/build/common/constants.js.map +0 -1
- package/node_modules/socks/build/common/helpers.js +0 -167
- package/node_modules/socks/build/common/helpers.js.map +0 -1
- package/node_modules/socks/build/common/receivebuffer.js +0 -43
- package/node_modules/socks/build/common/receivebuffer.js.map +0 -1
- package/node_modules/socks/build/common/util.js +0 -25
- package/node_modules/socks/build/common/util.js.map +0 -1
- package/node_modules/socks/build/index.js +0 -18
- package/node_modules/socks/build/index.js.map +0 -1
- package/node_modules/socks/docs/examples/index.md +0 -17
- package/node_modules/socks/docs/examples/javascript/associateExample.md +0 -90
- package/node_modules/socks/docs/examples/javascript/bindExample.md +0 -83
- package/node_modules/socks/docs/examples/javascript/connectExample.md +0 -258
- package/node_modules/socks/docs/examples/typescript/associateExample.md +0 -93
- package/node_modules/socks/docs/examples/typescript/bindExample.md +0 -86
- package/node_modules/socks/docs/examples/typescript/connectExample.md +0 -265
- package/node_modules/socks/docs/index.md +0 -5
- package/node_modules/socks/docs/migratingFromV1.md +0 -86
- package/node_modules/socks/package.json +0 -58
- package/node_modules/socks/typings/client/socksclient.d.ts +0 -162
- package/node_modules/socks/typings/common/constants.d.ts +0 -151
- package/node_modules/socks/typings/common/helpers.d.ts +0 -17
- package/node_modules/socks/typings/common/receivebuffer.d.ts +0 -12
- package/node_modules/socks/typings/common/util.d.ts +0 -14
- package/node_modules/socks/typings/index.d.ts +0 -1
- package/node_modules/socks-proxy-agent/LICENSE +0 -22
- package/node_modules/socks-proxy-agent/README.md +0 -50
- package/node_modules/socks-proxy-agent/dist/index.d.ts +0 -27
- package/node_modules/socks-proxy-agent/dist/index.d.ts.map +0 -1
- package/node_modules/socks-proxy-agent/dist/index.js +0 -195
- package/node_modules/socks-proxy-agent/dist/index.js.map +0 -1
- package/node_modules/socks-proxy-agent/package.json +0 -142
- package/node_modules/source-map/CHANGELOG.md +0 -301
- package/node_modules/source-map/LICENSE +0 -28
- package/node_modules/source-map/README.md +0 -742
- package/node_modules/source-map/dist/source-map.debug.js +0 -3234
- package/node_modules/source-map/dist/source-map.js +0 -3233
- package/node_modules/source-map/dist/source-map.min.js +0 -2
- package/node_modules/source-map/dist/source-map.min.js.map +0 -1
- package/node_modules/source-map/lib/array-set.js +0 -121
- package/node_modules/source-map/lib/base64-vlq.js +0 -140
- package/node_modules/source-map/lib/base64.js +0 -67
- package/node_modules/source-map/lib/binary-search.js +0 -111
- package/node_modules/source-map/lib/mapping-list.js +0 -79
- package/node_modules/source-map/lib/quick-sort.js +0 -114
- package/node_modules/source-map/lib/source-map-consumer.js +0 -1145
- package/node_modules/source-map/lib/source-map-generator.js +0 -425
- package/node_modules/source-map/lib/source-node.js +0 -413
- package/node_modules/source-map/lib/util.js +0 -488
- package/node_modules/source-map/package.json +0 -73
- package/node_modules/source-map/source-map.d.ts +0 -98
- package/node_modules/source-map/source-map.js +0 -8
- package/node_modules/string-width/index.d.ts +0 -29
- package/node_modules/string-width/index.js +0 -47
- package/node_modules/string-width/license +0 -9
- package/node_modules/string-width/node_modules/ansi-regex/index.d.ts +0 -37
- package/node_modules/string-width/node_modules/ansi-regex/index.js +0 -10
- package/node_modules/string-width/node_modules/ansi-regex/license +0 -9
- package/node_modules/string-width/node_modules/ansi-regex/package.json +0 -55
- package/node_modules/string-width/node_modules/ansi-regex/readme.md +0 -78
- package/node_modules/string-width/node_modules/strip-ansi/index.d.ts +0 -17
- package/node_modules/string-width/node_modules/strip-ansi/index.js +0 -4
- package/node_modules/string-width/node_modules/strip-ansi/license +0 -9
- package/node_modules/string-width/node_modules/strip-ansi/package.json +0 -54
- package/node_modules/string-width/node_modules/strip-ansi/readme.md +0 -46
- package/node_modules/string-width/package.json +0 -56
- package/node_modules/string-width/readme.md +0 -50
- package/node_modules/strip-ansi/index.d.ts +0 -15
- package/node_modules/strip-ansi/index.js +0 -19
- package/node_modules/strip-ansi/license +0 -9
- package/node_modules/strip-ansi/package.json +0 -59
- package/node_modules/strip-ansi/readme.md +0 -37
- package/node_modules/strtok3/LICENSE.txt +0 -21
- package/node_modules/strtok3/README.md +0 -399
- package/node_modules/strtok3/lib/AbstractTokenizer.d.ts +0 -76
- package/node_modules/strtok3/lib/AbstractTokenizer.js +0 -111
- package/node_modules/strtok3/lib/BlobTokenizer.d.ts +0 -29
- package/node_modules/strtok3/lib/BlobTokenizer.js +0 -53
- package/node_modules/strtok3/lib/BufferTokenizer.d.ts +0 -29
- package/node_modules/strtok3/lib/BufferTokenizer.js +0 -52
- package/node_modules/strtok3/lib/FileTokenizer.d.ts +0 -37
- package/node_modules/strtok3/lib/FileTokenizer.js +0 -61
- package/node_modules/strtok3/lib/ReadStreamTokenizer.d.ts +0 -34
- package/node_modules/strtok3/lib/ReadStreamTokenizer.js +0 -107
- package/node_modules/strtok3/lib/core.d.ts +0 -40
- package/node_modules/strtok3/lib/core.js +0 -62
- package/node_modules/strtok3/lib/index.d.ts +0 -16
- package/node_modules/strtok3/lib/index.js +0 -22
- package/node_modules/strtok3/lib/stream/AbstractStreamReader.d.ts +0 -54
- package/node_modules/strtok3/lib/stream/AbstractStreamReader.js +0 -71
- package/node_modules/strtok3/lib/stream/Deferred.d.ts +0 -6
- package/node_modules/strtok3/lib/stream/Deferred.js +0 -10
- package/node_modules/strtok3/lib/stream/Errors.d.ts +0 -10
- package/node_modules/strtok3/lib/stream/Errors.js +0 -16
- package/node_modules/strtok3/lib/stream/StreamReader.d.ts +0 -29
- package/node_modules/strtok3/lib/stream/StreamReader.js +0 -83
- package/node_modules/strtok3/lib/stream/WebStreamByobReader.d.ts +0 -14
- package/node_modules/strtok3/lib/stream/WebStreamByobReader.js +0 -27
- package/node_modules/strtok3/lib/stream/WebStreamDefaultReader.d.ts +0 -19
- package/node_modules/strtok3/lib/stream/WebStreamDefaultReader.js +0 -62
- package/node_modules/strtok3/lib/stream/WebStreamReader.d.ts +0 -14
- package/node_modules/strtok3/lib/stream/WebStreamReader.js +0 -13
- package/node_modules/strtok3/lib/stream/WebStreamReaderFactory.d.ts +0 -5
- package/node_modules/strtok3/lib/stream/WebStreamReaderFactory.js +0 -19
- package/node_modules/strtok3/lib/stream/index.d.ts +0 -6
- package/node_modules/strtok3/lib/stream/index.js +0 -5
- package/node_modules/strtok3/lib/types.d.ts +0 -139
- package/node_modules/strtok3/lib/types.js +0 -1
- package/node_modules/strtok3/package.json +0 -94
- package/node_modules/supports-color/browser.js +0 -5
- package/node_modules/supports-color/index.js +0 -135
- package/node_modules/supports-color/license +0 -9
- package/node_modules/supports-color/package.json +0 -53
- package/node_modules/supports-color/readme.md +0 -76
- package/node_modules/thenify/History.md +0 -11
- package/node_modules/thenify/LICENSE +0 -22
- package/node_modules/thenify/README.md +0 -120
- package/node_modules/thenify/index.js +0 -77
- package/node_modules/thenify/package.json +0 -31
- package/node_modules/thenify-all/History.md +0 -11
- package/node_modules/thenify-all/LICENSE +0 -22
- package/node_modules/thenify-all/README.md +0 -66
- package/node_modules/thenify-all/index.js +0 -73
- package/node_modules/thenify-all/package.json +0 -34
- package/node_modules/token-types/LICENSE.txt +0 -9
- package/node_modules/token-types/README.md +0 -120
- package/node_modules/token-types/lib/index.d.ts +0 -135
- package/node_modules/token-types/lib/index.js +0 -401
- package/node_modules/token-types/package.json +0 -81
- package/node_modules/uint8array-extras/index.d.ts +0 -331
- package/node_modules/uint8array-extras/index.js +0 -318
- package/node_modules/uint8array-extras/license +0 -9
- package/node_modules/uint8array-extras/package.json +0 -54
- package/node_modules/uint8array-extras/readme.md +0 -318
- package/node_modules/uuid/LICENSE.md +0 -9
- package/node_modules/uuid/README.md +0 -491
- package/node_modules/uuid/dist/index.d.ts +0 -15
- package/node_modules/uuid/dist/index.js +0 -14
- package/node_modules/uuid/dist/max.d.ts +0 -2
- package/node_modules/uuid/dist/max.js +0 -1
- package/node_modules/uuid/dist/md5.d.ts +0 -2
- package/node_modules/uuid/dist/md5.js +0 -135
- package/node_modules/uuid/dist/nil.d.ts +0 -2
- package/node_modules/uuid/dist/nil.js +0 -1
- package/node_modules/uuid/dist/parse.d.ts +0 -3
- package/node_modules/uuid/dist/parse.js +0 -9
- package/node_modules/uuid/dist/regex.d.ts +0 -2
- package/node_modules/uuid/dist/regex.js +0 -1
- package/node_modules/uuid/dist/rng.d.ts +0 -1
- package/node_modules/uuid/dist/rng.js +0 -4
- package/node_modules/uuid/dist/sha1.d.ts +0 -2
- package/node_modules/uuid/dist/sha1.js +0 -70
- package/node_modules/uuid/dist/stringify.d.ts +0 -3
- package/node_modules/uuid/dist/stringify.js +0 -35
- package/node_modules/uuid/dist/types.d.ts +0 -22
- package/node_modules/uuid/dist/types.js +0 -1
- package/node_modules/uuid/dist/uuid-bin.d.ts +0 -1
- package/node_modules/uuid/dist/uuid-bin.js +0 -70
- package/node_modules/uuid/dist/v1.d.ts +0 -11
- package/node_modules/uuid/dist/v1.js +0 -83
- package/node_modules/uuid/dist/v1ToV6.d.ts +0 -3
- package/node_modules/uuid/dist/v1ToV6.js +0 -10
- package/node_modules/uuid/dist/v3.d.ts +0 -9
- package/node_modules/uuid/dist/v3.js +0 -9
- package/node_modules/uuid/dist/v35.d.ts +0 -7
- package/node_modules/uuid/dist/v35.js +0 -39
- package/node_modules/uuid/dist/v4.d.ts +0 -4
- package/node_modules/uuid/dist/v4.js +0 -29
- package/node_modules/uuid/dist/v5.d.ts +0 -9
- package/node_modules/uuid/dist/v5.js +0 -9
- package/node_modules/uuid/dist/v6.d.ts +0 -4
- package/node_modules/uuid/dist/v6.js +0 -20
- package/node_modules/uuid/dist/v6ToV1.d.ts +0 -2
- package/node_modules/uuid/dist/v6ToV1.js +0 -10
- package/node_modules/uuid/dist/v7.d.ts +0 -9
- package/node_modules/uuid/dist/v7.js +0 -65
- package/node_modules/uuid/dist/validate.d.ts +0 -2
- package/node_modules/uuid/dist/validate.js +0 -5
- package/node_modules/uuid/dist/version.d.ts +0 -2
- package/node_modules/uuid/dist/version.js +0 -8
- package/node_modules/uuid/dist-node/bin/uuid +0 -2
- package/node_modules/uuid/dist-node/index.js +0 -14
- package/node_modules/uuid/dist-node/max.js +0 -1
- package/node_modules/uuid/dist-node/md5.js +0 -11
- package/node_modules/uuid/dist-node/nil.js +0 -1
- package/node_modules/uuid/dist-node/parse.js +0 -9
- package/node_modules/uuid/dist-node/regex.js +0 -1
- package/node_modules/uuid/dist-node/rng.js +0 -4
- package/node_modules/uuid/dist-node/sha1.js +0 -11
- package/node_modules/uuid/dist-node/stringify.js +0 -35
- package/node_modules/uuid/dist-node/types.js +0 -1
- package/node_modules/uuid/dist-node/uuid-bin.js +0 -70
- package/node_modules/uuid/dist-node/v1.js +0 -83
- package/node_modules/uuid/dist-node/v1ToV6.js +0 -10
- package/node_modules/uuid/dist-node/v3.js +0 -9
- package/node_modules/uuid/dist-node/v35.js +0 -39
- package/node_modules/uuid/dist-node/v4.js +0 -29
- package/node_modules/uuid/dist-node/v5.js +0 -9
- package/node_modules/uuid/dist-node/v6.js +0 -20
- package/node_modules/uuid/dist-node/v6ToV1.js +0 -10
- package/node_modules/uuid/dist-node/v7.js +0 -65
- package/node_modules/uuid/dist-node/validate.js +0 -5
- package/node_modules/uuid/dist-node/version.js +0 -8
- package/node_modules/uuid/package.json +0 -110
- package/node_modules/wrap-ansi/index.js +0 -216
- package/node_modules/wrap-ansi/license +0 -9
- package/node_modules/wrap-ansi/node_modules/ansi-regex/index.d.ts +0 -37
- package/node_modules/wrap-ansi/node_modules/ansi-regex/index.js +0 -10
- package/node_modules/wrap-ansi/node_modules/ansi-regex/license +0 -9
- package/node_modules/wrap-ansi/node_modules/ansi-regex/package.json +0 -55
- package/node_modules/wrap-ansi/node_modules/ansi-regex/readme.md +0 -78
- package/node_modules/wrap-ansi/node_modules/strip-ansi/index.d.ts +0 -17
- package/node_modules/wrap-ansi/node_modules/strip-ansi/index.js +0 -4
- package/node_modules/wrap-ansi/node_modules/strip-ansi/license +0 -9
- package/node_modules/wrap-ansi/node_modules/strip-ansi/package.json +0 -54
- package/node_modules/wrap-ansi/node_modules/strip-ansi/readme.md +0 -46
- package/node_modules/wrap-ansi/package.json +0 -62
- package/node_modules/wrap-ansi/readme.md +0 -91
- package/node_modules/wrappy/LICENSE +0 -15
- package/node_modules/wrappy/README.md +0 -36
- package/node_modules/wrappy/package.json +0 -29
- package/node_modules/wrappy/wrappy.js +0 -33
- package/node_modules/y18n/CHANGELOG.md +0 -100
- package/node_modules/y18n/LICENSE +0 -13
- package/node_modules/y18n/README.md +0 -127
- package/node_modules/y18n/build/index.cjs +0 -203
- package/node_modules/y18n/build/lib/cjs.js +0 -6
- package/node_modules/y18n/build/lib/index.js +0 -174
- package/node_modules/y18n/build/lib/platform-shims/node.js +0 -19
- package/node_modules/y18n/index.mjs +0 -8
- package/node_modules/y18n/package.json +0 -70
- package/node_modules/yargs/CHANGELOG.md +0 -88
- package/node_modules/yargs/LICENSE +0 -21
- package/node_modules/yargs/README.md +0 -202
- package/node_modules/yargs/browser.mjs +0 -7
- package/node_modules/yargs/build/index.cjs +0 -2920
- package/node_modules/yargs/build/lib/argsert.js +0 -62
- package/node_modules/yargs/build/lib/command.js +0 -382
- package/node_modules/yargs/build/lib/completion-templates.js +0 -47
- package/node_modules/yargs/build/lib/completion.js +0 -128
- package/node_modules/yargs/build/lib/middleware.js +0 -53
- package/node_modules/yargs/build/lib/parse-command.js +0 -32
- package/node_modules/yargs/build/lib/typings/common-types.js +0 -9
- package/node_modules/yargs/build/lib/typings/yargs-parser-types.js +0 -1
- package/node_modules/yargs/build/lib/usage.js +0 -548
- package/node_modules/yargs/build/lib/utils/apply-extends.js +0 -59
- package/node_modules/yargs/build/lib/utils/is-promise.js +0 -5
- package/node_modules/yargs/build/lib/utils/levenshtein.js +0 -26
- package/node_modules/yargs/build/lib/utils/obj-filter.js +0 -10
- package/node_modules/yargs/build/lib/utils/process-argv.js +0 -17
- package/node_modules/yargs/build/lib/utils/set-blocking.js +0 -12
- package/node_modules/yargs/build/lib/utils/which-module.js +0 -10
- package/node_modules/yargs/build/lib/validation.js +0 -308
- package/node_modules/yargs/build/lib/yargs-factory.js +0 -1143
- package/node_modules/yargs/build/lib/yerror.js +0 -7
- package/node_modules/yargs/helpers/helpers.mjs +0 -10
- package/node_modules/yargs/helpers/index.js +0 -14
- package/node_modules/yargs/helpers/package.json +0 -3
- package/node_modules/yargs/index.cjs +0 -39
- package/node_modules/yargs/index.mjs +0 -8
- package/node_modules/yargs/lib/platform-shims/browser.mjs +0 -92
- package/node_modules/yargs/lib/platform-shims/esm.mjs +0 -67
- package/node_modules/yargs/locales/be.json +0 -46
- package/node_modules/yargs/locales/de.json +0 -46
- package/node_modules/yargs/locales/en.json +0 -51
- package/node_modules/yargs/locales/es.json +0 -46
- package/node_modules/yargs/locales/fi.json +0 -49
- package/node_modules/yargs/locales/fr.json +0 -53
- package/node_modules/yargs/locales/hi.json +0 -49
- package/node_modules/yargs/locales/hu.json +0 -46
- package/node_modules/yargs/locales/id.json +0 -50
- package/node_modules/yargs/locales/it.json +0 -46
- package/node_modules/yargs/locales/ja.json +0 -51
- package/node_modules/yargs/locales/ko.json +0 -49
- package/node_modules/yargs/locales/nb.json +0 -44
- package/node_modules/yargs/locales/nl.json +0 -49
- package/node_modules/yargs/locales/nn.json +0 -44
- package/node_modules/yargs/locales/pirate.json +0 -13
- package/node_modules/yargs/locales/pl.json +0 -49
- package/node_modules/yargs/locales/pt.json +0 -45
- package/node_modules/yargs/locales/pt_BR.json +0 -48
- package/node_modules/yargs/locales/ru.json +0 -46
- package/node_modules/yargs/locales/th.json +0 -46
- package/node_modules/yargs/locales/tr.json +0 -48
- package/node_modules/yargs/locales/zh_CN.json +0 -48
- package/node_modules/yargs/locales/zh_TW.json +0 -47
- package/node_modules/yargs/package.json +0 -122
- package/node_modules/yargs/yargs +0 -9
- package/node_modules/yargs-parser/CHANGELOG.md +0 -263
- package/node_modules/yargs-parser/LICENSE.txt +0 -14
- package/node_modules/yargs-parser/README.md +0 -518
- package/node_modules/yargs-parser/browser.js +0 -29
- package/node_modules/yargs-parser/build/index.cjs +0 -1042
- package/node_modules/yargs-parser/build/lib/index.js +0 -59
- package/node_modules/yargs-parser/build/lib/string-utils.js +0 -65
- package/node_modules/yargs-parser/build/lib/tokenize-arg-string.js +0 -40
- package/node_modules/yargs-parser/build/lib/yargs-parser-types.js +0 -12
- package/node_modules/yargs-parser/build/lib/yargs-parser.js +0 -1037
- package/node_modules/yargs-parser/package.json +0 -87
- package/node_modules/yauzl/LICENSE +0 -21
- package/node_modules/yauzl/README.md +0 -658
- package/node_modules/yauzl/index.js +0 -796
- package/node_modules/yauzl/package.json +0 -40
- /package/node_modules/{@entelligentsia/pi-coding-agent/dist/core/tools → @earendil-works/pi-agent-core/dist/harness/utils}/truncate.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-agent-core/dist/types.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/api-registry.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/api-registry.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/api-registry.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/api-registry.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/bedrock-provider.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/bedrock-provider.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/bedrock-provider.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/bedrock-provider.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/cli.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/env-api-keys.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/models.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/models.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/models.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/models.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/oauth.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/oauth.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/oauth.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/oauth.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/amazon-bedrock.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/anthropic.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/azure-openai-responses.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/azure-openai-responses.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/azure-openai-responses.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/azure-openai-responses.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/cloudflare.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/cloudflare.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/cloudflare.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/cloudflare.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/faux.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/faux.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/faux.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/faux.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/github-copilot-headers.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/github-copilot-headers.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/github-copilot-headers.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/github-copilot-headers.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-shared.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-shared.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-shared.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-shared.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-vertex.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-vertex.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-vertex.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google-vertex.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/google.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/mistral.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/mistral.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/mistral.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/mistral.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-codex-responses.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-completions.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses-shared.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses-shared.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses-shared.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses-shared.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/openai-responses.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/register-builtins.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/register-builtins.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/register-builtins.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/register-builtins.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/simple-options.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/transform-messages.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/transform-messages.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/transform-messages.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/providers/transform-messages.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/session-resources.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/session-resources.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/session-resources.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/session-resources.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/stream.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/stream.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/stream.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/stream.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/types.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/diagnostics.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/diagnostics.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/diagnostics.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/diagnostics.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/event-stream.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/event-stream.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/event-stream.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/event-stream.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/hash.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/hash.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/hash.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/hash.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/headers.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/headers.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/headers.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/headers.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/json-parse.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/json-parse.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/json-parse.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/json-parse.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/anthropic.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/anthropic.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/anthropic.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/anthropic.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/github-copilot.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/github-copilot.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/github-copilot.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/github-copilot.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/oauth-page.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/oauth-page.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/oauth-page.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/oauth-page.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/openai-codex.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/openai-codex.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/openai-codex.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/openai-codex.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/pkce.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/pkce.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/pkce.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/pkce.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/types.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/types.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/types.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/oauth/types.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/sanitize-unicode.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/sanitize-unicode.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/sanitize-unicode.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/sanitize-unicode.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/typebox-helpers.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/typebox-helpers.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/typebox-helpers.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/typebox-helpers.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/validation.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/validation.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/validation.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-ai/dist/utils/validation.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/cli.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/cli.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/cli.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/cli.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/register-bedrock.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/restore-sandbox-env.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/restore-sandbox-env.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/restore-sandbox-env.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/bun/restore-sandbox-env.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli/config-selector.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli/file-processor.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli/initial-message.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli/list-models.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli/session-picker.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/cli.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/config.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/agent-session-runtime.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/agent-session-runtime.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/agent-session-runtime.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/agent-session-runtime.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/agent-session-services.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/auth-guidance.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/auth-guidance.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/auth-guidance.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/auth-guidance.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/bash-executor.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/compaction/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/compaction/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/compaction/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/compaction/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/compaction/utils.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/defaults.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/diagnostics.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/diagnostics.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/diagnostics.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/diagnostics.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/event-bus.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/event-bus.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/event-bus.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/event-bus.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/exec.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/exec.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/exec.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/exec.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/ansi-to-html.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/ansi-to-html.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/ansi-to-html.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/ansi-to-html.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/template.css +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/template.html +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/template.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/tool-renderer.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/tool-renderer.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/vendor/highlight.min.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/export-html/vendor/marked.min.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/loader.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/types.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/extensions/wrapper.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/footer-data-provider.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/footer-data-provider.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/footer-data-provider.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/footer-data-provider.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/messages.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/output-guard.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/output-guard.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/output-guard.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/output-guard.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/prompt-templates.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/provider-display-names.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resolve-config-value.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resolve-config-value.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resolve-config-value.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resolve-config-value.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resource-loader.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resource-loader.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resource-loader.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/resource-loader.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/session-cwd.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/session-cwd.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/session-cwd.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/session-cwd.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/settings-manager.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/skills.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/slash-commands.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/slash-commands.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/slash-commands.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/slash-commands.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/source-info.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/source-info.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/source-info.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/source-info.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/system-prompt.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/system-prompt.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/system-prompt.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/system-prompt.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/telemetry.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/telemetry.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/telemetry.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/telemetry.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/timings.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/timings.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/timings.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/timings.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/edit-diff.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/edit-diff.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/edit-diff.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/edit-diff.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/file-mutation-queue.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/file-mutation-queue.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/file-mutation-queue.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/file-mutation-queue.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/output-accumulator.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/output-accumulator.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/output-accumulator.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/output-accumulator.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/path-utils.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/path-utils.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/path-utils.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/path-utils.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/tool-definition-wrapper.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/truncate.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/truncate.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/core/tools/truncate.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/main.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/migrations.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/migrations.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/migrations.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/migrations.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/assets/clankolas.png +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/armin.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/countdown-timer.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/daxnuts.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/diff.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/diff.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/diff.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/diff.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/dynamic-border.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/session-selector-search.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/components/visual-truncate.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/interactive/theme/theme-schema.json +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/print-mode.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/jsonl.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/jsonl.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/jsonl.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/jsonl.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/rpc-client.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/rpc-mode.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/modes/rpc/rpc-types.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/package-manager-cli.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/package-manager-cli.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/package-manager-cli.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/package-manager-cli.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/changelog.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/changelog.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/changelog.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/changelog.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/child-process.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/child-process.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/child-process.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/child-process.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-image.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-image.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-image.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-image.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-native.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-native.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-native.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard-native.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/clipboard.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/exif-orientation.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/exif-orientation.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/exif-orientation.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/exif-orientation.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/frontmatter.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/frontmatter.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/frontmatter.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/frontmatter.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/fs-watch.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/fs-watch.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/fs-watch.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/fs-watch.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/git.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/git.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/git.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/git.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/image-convert.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/image-convert.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/image-convert.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/image-convert.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/image-resize.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/paths.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/paths.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/paths.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/paths.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/photon.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/photon.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/photon.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/photon.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/pi-user-agent.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/pi-user-agent.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/pi-user-agent.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/pi-user-agent.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/shell.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/shell.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/shell.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/shell.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/sleep.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/sleep.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/sleep.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/sleep.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/tools-manager.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/version-check.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/version-check.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/version-check.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/dist/utils/version-check.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/development.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/docs.json +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/images/doom-extension.png +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/images/exy.png +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/images/interactive-mode.png +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/images/tree-view.png +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/json.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/keybindings.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/prompt-templates.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/sessions.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/settings.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/shell-aliases.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/terminal-setup.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/tmux.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/usage.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/docs/windows.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/README.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/README.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/doom/build/doom.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/doom/build/doom.wasm +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/doom/build.sh +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/doom/doomgeneric_pi.c +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/doom-engine.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/doom-overlay/wad-finder.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/dynamic-resources/SKILL.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/dynamic-resources/dynamic.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/plan-mode/README.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/plan-mode/utils.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/README.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/agents/planner.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/agents/reviewer.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/agents/scout.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/agents/worker.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/prompts/implement-and-review.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/prompts/implement.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-coding-agent/examples/extensions/subagent/prompts/scout-and-plan.md +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/autocomplete.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/autocomplete.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/autocomplete.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/autocomplete.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/box.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/box.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/box.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/box.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/cancellable-loader.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/cancellable-loader.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/cancellable-loader.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/cancellable-loader.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/editor.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/editor.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/editor.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/editor.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/image.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/input.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/input.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/input.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/input.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/loader.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/loader.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/loader.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/loader.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/select-list.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/select-list.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/select-list.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/select-list.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/settings-list.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/settings-list.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/settings-list.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/settings-list.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/spacer.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/spacer.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/spacer.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/spacer.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/text.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/text.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/text.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/text.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/truncated-text.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/truncated-text.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/truncated-text.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/components/truncated-text.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/editor-component.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/editor-component.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/editor-component.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/editor-component.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/fuzzy.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/fuzzy.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/fuzzy.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/fuzzy.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/index.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/index.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/index.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/index.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keybindings.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keybindings.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keybindings.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keybindings.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keys.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keys.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keys.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/keys.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/kill-ring.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/kill-ring.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/kill-ring.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/kill-ring.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/stdin-buffer.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/terminal.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/terminal.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/terminal.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/terminal.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/tui.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/tui.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/tui.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/tui.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/undo-stack.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/undo-stack.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/undo-stack.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/undo-stack.js.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/utils.d.ts +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/utils.d.ts.map +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/utils.js +0 -0
- /package/node_modules/{@entelligentsia → @earendil-works}/pi-tui/dist/utils.js.map +0 -0
package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.js
ADDED
|
@@ -0,0 +1,4668 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Interactive mode for the coding agent.
|
|
3
|
+
* Handles TUI rendering and user interaction, delegating business logic to AgentSession.
|
|
4
|
+
*/
|
|
5
|
+
import * as crypto from "node:crypto";
|
|
6
|
+
import * as fs from "node:fs";
|
|
7
|
+
import * as os from "node:os";
|
|
8
|
+
import * as path from "node:path";
|
|
9
|
+
import { getProviders, } from "@earendil-works/pi-ai";
|
|
10
|
+
import { CombinedAutocompleteProvider, Container, fuzzyFilter, getCapabilities, hyperlink, Loader, Markdown, matchesKey, ProcessTerminal, Spacer, setKeybindings, Text, TruncatedText, TUI, visibleWidth, } from "@earendil-works/pi-tui";
|
|
11
|
+
import { spawn, spawnSync } from "child_process";
|
|
12
|
+
import { APP_NAME, APP_TITLE, getAgentDir, getAuthPath, getDebugLogPath, getDocsPath, getShareViewerUrl, VERSION, } from "../../config.js";
|
|
13
|
+
import { parseSkillBlock } from "../../core/agent-session.js";
|
|
14
|
+
import { SessionImportFileNotFoundError } from "../../core/agent-session-runtime.js";
|
|
15
|
+
import { FooterDataProvider } from "../../core/footer-data-provider.js";
|
|
16
|
+
import { KeybindingsManager } from "../../core/keybindings.js";
|
|
17
|
+
import { createCompactionSummaryMessage } from "../../core/messages.js";
|
|
18
|
+
import { defaultModelPerProvider, findExactModelReferenceMatch, resolveModelScope } from "../../core/model-resolver.js";
|
|
19
|
+
import { DefaultPackageManager } from "../../core/package-manager.js";
|
|
20
|
+
import { BUILT_IN_PROVIDER_DISPLAY_NAMES } from "../../core/provider-display-names.js";
|
|
21
|
+
import { formatMissingSessionCwdPrompt, MissingSessionCwdError } from "../../core/session-cwd.js";
|
|
22
|
+
import { SessionManager } from "../../core/session-manager.js";
|
|
23
|
+
import { BUILTIN_SLASH_COMMANDS } from "../../core/slash-commands.js";
|
|
24
|
+
import { isInstallTelemetryEnabled } from "../../core/telemetry.js";
|
|
25
|
+
import { getChangelogPath, getNewEntries, parseChangelog } from "../../utils/changelog.js";
|
|
26
|
+
import { copyToClipboard } from "../../utils/clipboard.js";
|
|
27
|
+
import { extensionForImageMimeType, readClipboardImage } from "../../utils/clipboard-image.js";
|
|
28
|
+
import { parseGitUrl } from "../../utils/git.js";
|
|
29
|
+
import { getCwdRelativePath } from "../../utils/paths.js";
|
|
30
|
+
import { getPiUserAgent } from "../../utils/pi-user-agent.js";
|
|
31
|
+
import { killTrackedDetachedChildren } from "../../utils/shell.js";
|
|
32
|
+
import { ensureTool } from "../../utils/tools-manager.js";
|
|
33
|
+
import { checkForNewPiVersion } from "../../utils/version-check.js";
|
|
34
|
+
import { ArminComponent } from "./components/armin.js";
|
|
35
|
+
import { AssistantMessageComponent } from "./components/assistant-message.js";
|
|
36
|
+
import { BashExecutionComponent } from "./components/bash-execution.js";
|
|
37
|
+
import { BorderedLoader } from "./components/bordered-loader.js";
|
|
38
|
+
import { BranchSummaryMessageComponent } from "./components/branch-summary-message.js";
|
|
39
|
+
import { CompactionSummaryMessageComponent } from "./components/compaction-summary-message.js";
|
|
40
|
+
import { CountdownTimer } from "./components/countdown-timer.js";
|
|
41
|
+
import { CustomEditor } from "./components/custom-editor.js";
|
|
42
|
+
import { CustomMessageComponent } from "./components/custom-message.js";
|
|
43
|
+
import { DaxnutsComponent } from "./components/daxnuts.js";
|
|
44
|
+
import { DynamicBorder } from "./components/dynamic-border.js";
|
|
45
|
+
import { EarendilAnnouncementComponent } from "./components/earendil-announcement.js";
|
|
46
|
+
import { ExtensionEditorComponent } from "./components/extension-editor.js";
|
|
47
|
+
import { ExtensionInputComponent } from "./components/extension-input.js";
|
|
48
|
+
import { ExtensionSelectorComponent } from "./components/extension-selector.js";
|
|
49
|
+
import { FooterComponent } from "./components/footer.js";
|
|
50
|
+
import { formatKeyText, keyDisplayText, keyHint, keyText, rawKeyHint } from "./components/keybinding-hints.js";
|
|
51
|
+
import { LoginDialogComponent } from "./components/login-dialog.js";
|
|
52
|
+
import { ModelSelectorComponent } from "./components/model-selector.js";
|
|
53
|
+
import { OAuthSelectorComponent } from "./components/oauth-selector.js";
|
|
54
|
+
import { ScopedModelsSelectorComponent } from "./components/scoped-models-selector.js";
|
|
55
|
+
import { SessionSelectorComponent } from "./components/session-selector.js";
|
|
56
|
+
import { SettingsSelectorComponent } from "./components/settings-selector.js";
|
|
57
|
+
import { SkillInvocationMessageComponent } from "./components/skill-invocation-message.js";
|
|
58
|
+
import { ToolExecutionComponent } from "./components/tool-execution.js";
|
|
59
|
+
import { TreeSelectorComponent } from "./components/tree-selector.js";
|
|
60
|
+
import { UserMessageComponent } from "./components/user-message.js";
|
|
61
|
+
import { UserMessageSelectorComponent } from "./components/user-message-selector.js";
|
|
62
|
+
import { getAvailableThemes, getAvailableThemesWithPaths, getEditorTheme, getMarkdownTheme, getThemeByName, initTheme, onThemeChange, setRegisteredThemes, setTheme, setThemeInstance, stopThemeWatcher, Theme, theme, } from "./theme/theme.js";
|
|
63
|
+
function isExpandable(obj) {
|
|
64
|
+
return typeof obj === "object" && obj !== null && "setExpanded" in obj && typeof obj.setExpanded === "function";
|
|
65
|
+
}
|
|
66
|
+
class ExpandableText extends Text {
|
|
67
|
+
getCollapsedText;
|
|
68
|
+
getExpandedText;
|
|
69
|
+
constructor(getCollapsedText, getExpandedText, expanded = false, paddingX = 0, paddingY = 0) {
|
|
70
|
+
super(expanded ? getExpandedText() : getCollapsedText(), paddingX, paddingY);
|
|
71
|
+
this.getCollapsedText = getCollapsedText;
|
|
72
|
+
this.getExpandedText = getExpandedText;
|
|
73
|
+
}
|
|
74
|
+
setExpanded(expanded) {
|
|
75
|
+
this.setText(expanded ? this.getExpandedText() : this.getCollapsedText());
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Container that can have its rendered output overridden by a single Component.
|
|
80
|
+
*
|
|
81
|
+
* Used for the chat output viewport. By default it renders its children (the
|
|
82
|
+
* normal message history). When `sourceOverride` is set, it delegates rendering
|
|
83
|
+
* to that component instead, while preserving the original children so the
|
|
84
|
+
* override can be cleared without rebuilding history.
|
|
85
|
+
*
|
|
86
|
+
* Drives the extension-side `ctx.ui.setOutputSource(component)` API — extensions
|
|
87
|
+
* that mount a swap-target (e.g. a thread-switcher viewing a subagent tail) can
|
|
88
|
+
* take over the main chat viewport on user command and restore it on dismiss.
|
|
89
|
+
*/
|
|
90
|
+
class SourceOverridableContainer extends Container {
|
|
91
|
+
sourceOverride = null;
|
|
92
|
+
render(width) {
|
|
93
|
+
if (this.sourceOverride) {
|
|
94
|
+
return this.sourceOverride.render(width);
|
|
95
|
+
}
|
|
96
|
+
return super.render(width);
|
|
97
|
+
}
|
|
98
|
+
invalidate() {
|
|
99
|
+
this.sourceOverride?.invalidate?.();
|
|
100
|
+
super.invalidate();
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
const DEAD_TERMINAL_ERROR_CODES = new Set(["EIO", "EPIPE", "ENOTCONN"]);
|
|
104
|
+
function isDeadTerminalError(error) {
|
|
105
|
+
if (!error || typeof error !== "object" || !("code" in error)) {
|
|
106
|
+
return false;
|
|
107
|
+
}
|
|
108
|
+
const code = error.code;
|
|
109
|
+
return code !== undefined && DEAD_TERMINAL_ERROR_CODES.has(code);
|
|
110
|
+
}
|
|
111
|
+
const ANTHROPIC_SUBSCRIPTION_AUTH_WARNING = "Anthropic subscription auth is active. Third-party harness usage draws from extra usage and is billed per token, not your Claude plan limits. Manage extra usage at https://claude.ai/settings/usage.";
|
|
112
|
+
function isAnthropicSubscriptionAuthKey(apiKey) {
|
|
113
|
+
return typeof apiKey === "string" && apiKey.startsWith("sk-ant-oat");
|
|
114
|
+
}
|
|
115
|
+
function isUnknownModel(model) {
|
|
116
|
+
return !!model && model.provider === "unknown" && model.id === "unknown" && model.api === "unknown";
|
|
117
|
+
}
|
|
118
|
+
function hasDefaultModelProvider(providerId) {
|
|
119
|
+
return providerId in defaultModelPerProvider;
|
|
120
|
+
}
|
|
121
|
+
const BEDROCK_PROVIDER_ID = "amazon-bedrock";
|
|
122
|
+
const BUILT_IN_MODEL_PROVIDERS = new Set(getProviders());
|
|
123
|
+
export function isApiKeyLoginProvider(providerId, oauthProviderIds, builtInProviderIds = BUILT_IN_MODEL_PROVIDERS) {
|
|
124
|
+
if (BUILT_IN_PROVIDER_DISPLAY_NAMES[providerId]) {
|
|
125
|
+
return true;
|
|
126
|
+
}
|
|
127
|
+
if (builtInProviderIds.has(providerId)) {
|
|
128
|
+
return false;
|
|
129
|
+
}
|
|
130
|
+
return !oauthProviderIds.has(providerId);
|
|
131
|
+
}
|
|
132
|
+
export class InteractiveMode {
|
|
133
|
+
options;
|
|
134
|
+
runtimeHost;
|
|
135
|
+
ui;
|
|
136
|
+
chatContainer;
|
|
137
|
+
pendingMessagesContainer;
|
|
138
|
+
statusContainer;
|
|
139
|
+
defaultEditor;
|
|
140
|
+
editor;
|
|
141
|
+
editorComponentFactory;
|
|
142
|
+
autocompleteProvider;
|
|
143
|
+
autocompleteProviderWrappers = [];
|
|
144
|
+
fdPath;
|
|
145
|
+
editorContainer;
|
|
146
|
+
footer;
|
|
147
|
+
footerDataProvider;
|
|
148
|
+
// Stored so the same manager can be injected into custom editors, selectors, and extension UI.
|
|
149
|
+
keybindings;
|
|
150
|
+
version;
|
|
151
|
+
isInitialized = false;
|
|
152
|
+
onInputCallback;
|
|
153
|
+
loadingAnimation = undefined;
|
|
154
|
+
workingMessage = undefined;
|
|
155
|
+
workingVisible = true;
|
|
156
|
+
workingIndicatorOptions = undefined;
|
|
157
|
+
defaultWorkingMessage = "Working...";
|
|
158
|
+
defaultHiddenThinkingLabel = "Thinking...";
|
|
159
|
+
hiddenThinkingLabel = this.defaultHiddenThinkingLabel;
|
|
160
|
+
lastSigintTime = 0;
|
|
161
|
+
lastEscapeTime = 0;
|
|
162
|
+
changelogMarkdown = undefined;
|
|
163
|
+
startupNoticesShown = false;
|
|
164
|
+
anthropicSubscriptionWarningShown = false;
|
|
165
|
+
// Status line tracking (for mutating immediately-sequential status updates)
|
|
166
|
+
lastStatusSpacer = undefined;
|
|
167
|
+
lastStatusText = undefined;
|
|
168
|
+
// Streaming message tracking
|
|
169
|
+
streamingComponent = undefined;
|
|
170
|
+
streamingMessage = undefined;
|
|
171
|
+
// Tool execution tracking: toolCallId -> component
|
|
172
|
+
pendingTools = new Map();
|
|
173
|
+
// Tool output expansion state
|
|
174
|
+
toolOutputExpanded = false;
|
|
175
|
+
// Thinking block visibility state
|
|
176
|
+
hideThinkingBlock = false;
|
|
177
|
+
// Skill commands: command name -> skill file path
|
|
178
|
+
skillCommands = new Map();
|
|
179
|
+
// Agent subscription unsubscribe function
|
|
180
|
+
unsubscribe;
|
|
181
|
+
signalCleanupHandlers = [];
|
|
182
|
+
// Track if editor is in bash mode (text starts with !)
|
|
183
|
+
isBashMode = false;
|
|
184
|
+
// Track current bash execution component
|
|
185
|
+
bashComponent = undefined;
|
|
186
|
+
// Track pending bash components (shown in pending area, moved to chat on submit)
|
|
187
|
+
pendingBashComponents = [];
|
|
188
|
+
// Auto-compaction state
|
|
189
|
+
autoCompactionLoader = undefined;
|
|
190
|
+
autoCompactionEscapeHandler;
|
|
191
|
+
// Auto-retry state
|
|
192
|
+
retryLoader = undefined;
|
|
193
|
+
retryCountdown = undefined;
|
|
194
|
+
retryEscapeHandler;
|
|
195
|
+
// Messages queued while compaction is running
|
|
196
|
+
compactionQueuedMessages = [];
|
|
197
|
+
// Shutdown state
|
|
198
|
+
shutdownRequested = false;
|
|
199
|
+
// Extension UI state
|
|
200
|
+
extensionSelector = undefined;
|
|
201
|
+
extensionInput = undefined;
|
|
202
|
+
extensionEditor = undefined;
|
|
203
|
+
extensionTerminalInputUnsubscribers = new Set();
|
|
204
|
+
// Extension widgets (components rendered above/below the editor)
|
|
205
|
+
extensionWidgetsAbove = new Map();
|
|
206
|
+
extensionWidgetsBelow = new Map();
|
|
207
|
+
widgetContainerAbove;
|
|
208
|
+
widgetContainerBelow;
|
|
209
|
+
// Custom footer from extension (undefined = use built-in footer)
|
|
210
|
+
customFooter = undefined;
|
|
211
|
+
// Header container that holds the built-in or custom header
|
|
212
|
+
headerContainer;
|
|
213
|
+
// Built-in header (logo + keybinding hints + changelog)
|
|
214
|
+
builtInHeader = undefined;
|
|
215
|
+
// Custom header from extension (undefined = use built-in header)
|
|
216
|
+
customHeader = undefined;
|
|
217
|
+
// Convenience accessors
|
|
218
|
+
get session() {
|
|
219
|
+
return this.runtimeHost.session;
|
|
220
|
+
}
|
|
221
|
+
get agent() {
|
|
222
|
+
return this.session.agent;
|
|
223
|
+
}
|
|
224
|
+
get sessionManager() {
|
|
225
|
+
return this.session.sessionManager;
|
|
226
|
+
}
|
|
227
|
+
get settingsManager() {
|
|
228
|
+
return this.session.settingsManager;
|
|
229
|
+
}
|
|
230
|
+
constructor(runtimeHost, options = {}) {
|
|
231
|
+
this.options = options;
|
|
232
|
+
this.runtimeHost = runtimeHost;
|
|
233
|
+
this.runtimeHost.setBeforeSessionInvalidate(() => {
|
|
234
|
+
this.resetExtensionUI();
|
|
235
|
+
});
|
|
236
|
+
this.runtimeHost.setRebindSession(async () => {
|
|
237
|
+
await this.rebindCurrentSession();
|
|
238
|
+
});
|
|
239
|
+
this.version = VERSION;
|
|
240
|
+
this.ui = new TUI(new ProcessTerminal(), this.settingsManager.getShowHardwareCursor());
|
|
241
|
+
this.ui.setClearOnShrink(this.settingsManager.getClearOnShrink());
|
|
242
|
+
this.headerContainer = new Container();
|
|
243
|
+
this.chatContainer = new SourceOverridableContainer();
|
|
244
|
+
this.pendingMessagesContainer = new Container();
|
|
245
|
+
this.statusContainer = new Container();
|
|
246
|
+
this.widgetContainerAbove = new Container();
|
|
247
|
+
this.widgetContainerBelow = new Container();
|
|
248
|
+
this.keybindings = KeybindingsManager.create();
|
|
249
|
+
setKeybindings(this.keybindings);
|
|
250
|
+
const editorPaddingX = this.settingsManager.getEditorPaddingX();
|
|
251
|
+
const autocompleteMaxVisible = this.settingsManager.getAutocompleteMaxVisible();
|
|
252
|
+
this.defaultEditor = new CustomEditor(this.ui, getEditorTheme(), this.keybindings, {
|
|
253
|
+
paddingX: editorPaddingX,
|
|
254
|
+
autocompleteMaxVisible,
|
|
255
|
+
});
|
|
256
|
+
this.editor = this.defaultEditor;
|
|
257
|
+
this.editorContainer = new Container();
|
|
258
|
+
this.editorContainer.addChild(this.editor);
|
|
259
|
+
this.footerDataProvider = new FooterDataProvider(this.sessionManager.getCwd());
|
|
260
|
+
this.footer = new FooterComponent(this.session, this.footerDataProvider);
|
|
261
|
+
this.footer.setAutoCompactEnabled(this.session.autoCompactionEnabled);
|
|
262
|
+
// Load hide thinking block setting
|
|
263
|
+
this.hideThinkingBlock = this.settingsManager.getHideThinkingBlock();
|
|
264
|
+
// Register themes from resource loader and initialize
|
|
265
|
+
setRegisteredThemes(this.session.resourceLoader.getThemes().themes);
|
|
266
|
+
initTheme(this.settingsManager.getTheme(), true);
|
|
267
|
+
}
|
|
268
|
+
getAutocompleteSourceTag(sourceInfo) {
|
|
269
|
+
if (!sourceInfo) {
|
|
270
|
+
return undefined;
|
|
271
|
+
}
|
|
272
|
+
const scopePrefix = sourceInfo.scope === "user" ? "u" : sourceInfo.scope === "project" ? "p" : "t";
|
|
273
|
+
const source = sourceInfo.source.trim();
|
|
274
|
+
if (source === "auto" || source === "local" || source === "cli") {
|
|
275
|
+
return scopePrefix;
|
|
276
|
+
}
|
|
277
|
+
if (source.startsWith("npm:")) {
|
|
278
|
+
return `${scopePrefix}:${source}`;
|
|
279
|
+
}
|
|
280
|
+
const gitSource = parseGitUrl(source);
|
|
281
|
+
if (gitSource) {
|
|
282
|
+
const ref = gitSource.ref ? `@${gitSource.ref}` : "";
|
|
283
|
+
return `${scopePrefix}:git:${gitSource.host}/${gitSource.path}${ref}`;
|
|
284
|
+
}
|
|
285
|
+
return scopePrefix;
|
|
286
|
+
}
|
|
287
|
+
prefixAutocompleteDescription(description, sourceInfo) {
|
|
288
|
+
const sourceTag = this.getAutocompleteSourceTag(sourceInfo);
|
|
289
|
+
if (!sourceTag) {
|
|
290
|
+
return description;
|
|
291
|
+
}
|
|
292
|
+
return description ? `[${sourceTag}] ${description}` : `[${sourceTag}]`;
|
|
293
|
+
}
|
|
294
|
+
getBuiltInCommandConflictDiagnostics(extensionRunner) {
|
|
295
|
+
const builtinNames = new Set(BUILTIN_SLASH_COMMANDS.map((command) => command.name));
|
|
296
|
+
return extensionRunner
|
|
297
|
+
.getRegisteredCommands()
|
|
298
|
+
.filter((command) => builtinNames.has(command.name))
|
|
299
|
+
.map((command) => ({
|
|
300
|
+
type: "warning",
|
|
301
|
+
message: command.invocationName === command.name
|
|
302
|
+
? `Extension command '/${command.name}' conflicts with built-in interactive command. Skipping in autocomplete.`
|
|
303
|
+
: `Extension command '/${command.name}' conflicts with built-in interactive command. Available as '/${command.invocationName}'.`,
|
|
304
|
+
path: command.sourceInfo.path,
|
|
305
|
+
}));
|
|
306
|
+
}
|
|
307
|
+
createBaseAutocompleteProvider() {
|
|
308
|
+
// Define commands for autocomplete
|
|
309
|
+
const slashCommands = BUILTIN_SLASH_COMMANDS.map((command) => ({
|
|
310
|
+
name: command.name,
|
|
311
|
+
description: command.description,
|
|
312
|
+
}));
|
|
313
|
+
const modelCommand = slashCommands.find((command) => command.name === "model");
|
|
314
|
+
if (modelCommand) {
|
|
315
|
+
modelCommand.getArgumentCompletions = (prefix) => {
|
|
316
|
+
// Get available models (scoped or from registry)
|
|
317
|
+
const models = this.session.scopedModels.length > 0
|
|
318
|
+
? this.session.scopedModels.map((s) => s.model)
|
|
319
|
+
: this.session.modelRegistry.getAvailable();
|
|
320
|
+
if (models.length === 0)
|
|
321
|
+
return null;
|
|
322
|
+
// Create items with provider/id format
|
|
323
|
+
const items = models.map((m) => ({
|
|
324
|
+
id: m.id,
|
|
325
|
+
provider: m.provider,
|
|
326
|
+
label: `${m.provider}/${m.id}`,
|
|
327
|
+
}));
|
|
328
|
+
// Fuzzy filter by model ID + provider (allows "opus anthropic" to match)
|
|
329
|
+
const filtered = fuzzyFilter(items, prefix, (item) => `${item.id} ${item.provider}`);
|
|
330
|
+
if (filtered.length === 0)
|
|
331
|
+
return null;
|
|
332
|
+
return filtered.map((item) => ({
|
|
333
|
+
value: item.label,
|
|
334
|
+
label: item.id,
|
|
335
|
+
description: item.provider,
|
|
336
|
+
}));
|
|
337
|
+
};
|
|
338
|
+
}
|
|
339
|
+
// Convert prompt templates to SlashCommand format for autocomplete
|
|
340
|
+
const templateCommands = this.session.promptTemplates.map((cmd) => ({
|
|
341
|
+
name: cmd.name,
|
|
342
|
+
description: this.prefixAutocompleteDescription(cmd.description, cmd.sourceInfo),
|
|
343
|
+
...(cmd.argumentHint && { argumentHint: cmd.argumentHint }),
|
|
344
|
+
}));
|
|
345
|
+
// Convert extension commands to SlashCommand format
|
|
346
|
+
const builtinCommandNames = new Set(slashCommands.map((c) => c.name));
|
|
347
|
+
const extensionCommands = this.session.extensionRunner
|
|
348
|
+
.getRegisteredCommands()
|
|
349
|
+
.filter((cmd) => !builtinCommandNames.has(cmd.name))
|
|
350
|
+
.map((cmd) => ({
|
|
351
|
+
name: cmd.invocationName,
|
|
352
|
+
description: this.prefixAutocompleteDescription(cmd.description, cmd.sourceInfo),
|
|
353
|
+
getArgumentCompletions: cmd.getArgumentCompletions,
|
|
354
|
+
}));
|
|
355
|
+
// Build skill commands from session.skills (if enabled)
|
|
356
|
+
this.skillCommands.clear();
|
|
357
|
+
const skillCommandList = [];
|
|
358
|
+
if (this.settingsManager.getEnableSkillCommands()) {
|
|
359
|
+
for (const skill of this.session.resourceLoader.getSkills().skills) {
|
|
360
|
+
const commandName = `skill:${skill.name}`;
|
|
361
|
+
this.skillCommands.set(commandName, skill.filePath);
|
|
362
|
+
skillCommandList.push({
|
|
363
|
+
name: commandName,
|
|
364
|
+
description: this.prefixAutocompleteDescription(skill.description, skill.sourceInfo),
|
|
365
|
+
});
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
return new CombinedAutocompleteProvider([...slashCommands, ...templateCommands, ...extensionCommands, ...skillCommandList], this.sessionManager.getCwd(), this.fdPath);
|
|
369
|
+
}
|
|
370
|
+
setupAutocompleteProvider() {
|
|
371
|
+
let provider = this.createBaseAutocompleteProvider();
|
|
372
|
+
for (const wrapProvider of this.autocompleteProviderWrappers) {
|
|
373
|
+
provider = wrapProvider(provider);
|
|
374
|
+
}
|
|
375
|
+
this.autocompleteProvider = provider;
|
|
376
|
+
this.defaultEditor.setAutocompleteProvider(provider);
|
|
377
|
+
if (this.editor !== this.defaultEditor) {
|
|
378
|
+
this.editor.setAutocompleteProvider?.(provider);
|
|
379
|
+
}
|
|
380
|
+
}
|
|
381
|
+
showStartupNoticesIfNeeded() {
|
|
382
|
+
if (this.startupNoticesShown) {
|
|
383
|
+
return;
|
|
384
|
+
}
|
|
385
|
+
this.startupNoticesShown = true;
|
|
386
|
+
if (!this.changelogMarkdown) {
|
|
387
|
+
return;
|
|
388
|
+
}
|
|
389
|
+
if (this.chatContainer.children.length > 0) {
|
|
390
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
391
|
+
}
|
|
392
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
393
|
+
if (this.settingsManager.getCollapseChangelog()) {
|
|
394
|
+
const versionMatch = this.changelogMarkdown.match(/##\s+\[?(\d+\.\d+\.\d+)\]?/);
|
|
395
|
+
const latestVersion = versionMatch ? versionMatch[1] : this.version;
|
|
396
|
+
const condensedText = `Updated to v${latestVersion}. Use ${theme.bold("/changelog")} to view full changelog.`;
|
|
397
|
+
this.chatContainer.addChild(new Text(condensedText, 1, 0));
|
|
398
|
+
}
|
|
399
|
+
else {
|
|
400
|
+
this.chatContainer.addChild(new Text(theme.bold(theme.fg("accent", "What's New")), 1, 0));
|
|
401
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
402
|
+
this.chatContainer.addChild(new Markdown(this.changelogMarkdown.trim(), 1, 0, this.getMarkdownThemeWithSettings()));
|
|
403
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
404
|
+
}
|
|
405
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
406
|
+
}
|
|
407
|
+
async init() {
|
|
408
|
+
if (this.isInitialized)
|
|
409
|
+
return;
|
|
410
|
+
this.registerSignalHandlers();
|
|
411
|
+
// Load changelog (only show new entries, skip for resumed sessions)
|
|
412
|
+
this.changelogMarkdown = this.getChangelogForDisplay();
|
|
413
|
+
// Ensure fd and rg are available (downloads if missing, adds to PATH via getBinDir)
|
|
414
|
+
// Both are needed: fd for autocomplete, rg for grep tool and bash commands
|
|
415
|
+
const [fdPath] = await Promise.all([ensureTool("fd"), ensureTool("rg")]);
|
|
416
|
+
this.fdPath = fdPath;
|
|
417
|
+
if (this.session.scopedModels.length > 0 && (this.options.verbose || !this.settingsManager.getQuietStartup())) {
|
|
418
|
+
const modelList = this.session.scopedModels
|
|
419
|
+
.map((sm) => {
|
|
420
|
+
const thinkingStr = sm.thinkingLevel ? `:${sm.thinkingLevel}` : "";
|
|
421
|
+
return `${sm.model.id}${thinkingStr}`;
|
|
422
|
+
})
|
|
423
|
+
.join(", ");
|
|
424
|
+
const cycleKeys = this.keybindings.getKeys("app.model.cycleForward");
|
|
425
|
+
const cycleHint = cycleKeys.length > 0
|
|
426
|
+
? theme.fg("muted", ` (${formatKeyText(cycleKeys.join("/"), { capitalize: true })} to cycle)`)
|
|
427
|
+
: "";
|
|
428
|
+
console.log(theme.fg("dim", `Model scope: ${modelList}${cycleHint}`));
|
|
429
|
+
}
|
|
430
|
+
// Add header container as first child
|
|
431
|
+
this.ui.addChild(this.headerContainer);
|
|
432
|
+
// Add header with keybindings from config (unless silenced)
|
|
433
|
+
if (this.options.verbose || !this.settingsManager.getQuietStartup()) {
|
|
434
|
+
const logo = theme.bold(theme.fg("accent", APP_NAME)) + theme.fg("dim", ` v${this.version}`);
|
|
435
|
+
// Build startup instructions using keybinding hint helpers
|
|
436
|
+
const hint = (keybinding, description) => keyHint(keybinding, description);
|
|
437
|
+
const expandedInstructions = [
|
|
438
|
+
hint("app.interrupt", "to interrupt"),
|
|
439
|
+
hint("app.clear", "to clear"),
|
|
440
|
+
rawKeyHint(`${keyText("app.clear")} twice`, "to exit"),
|
|
441
|
+
hint("app.exit", "to exit (empty)"),
|
|
442
|
+
hint("app.suspend", "to suspend"),
|
|
443
|
+
keyHint("tui.editor.deleteToLineEnd", "to delete to end"),
|
|
444
|
+
hint("app.thinking.cycle", "to cycle thinking level"),
|
|
445
|
+
rawKeyHint(`${keyText("app.model.cycleForward")}/${keyText("app.model.cycleBackward")}`, "to cycle models"),
|
|
446
|
+
hint("app.model.select", "to select model"),
|
|
447
|
+
hint("app.tools.expand", "to expand tools"),
|
|
448
|
+
hint("app.thinking.toggle", "to expand thinking"),
|
|
449
|
+
hint("app.editor.external", "for external editor"),
|
|
450
|
+
rawKeyHint("/", "for commands"),
|
|
451
|
+
rawKeyHint("!", "to run bash"),
|
|
452
|
+
rawKeyHint("!!", "to run bash (no context)"),
|
|
453
|
+
hint("app.message.followUp", "to queue follow-up"),
|
|
454
|
+
hint("app.message.dequeue", "to edit all queued messages"),
|
|
455
|
+
hint("app.clipboard.pasteImage", "to paste image"),
|
|
456
|
+
rawKeyHint("drop files", "to attach"),
|
|
457
|
+
].join("\n");
|
|
458
|
+
const compactInstructions = [
|
|
459
|
+
hint("app.interrupt", "interrupt"),
|
|
460
|
+
rawKeyHint(`${keyText("app.clear")}/${keyText("app.exit")}`, "clear/exit"),
|
|
461
|
+
rawKeyHint("/", "commands"),
|
|
462
|
+
rawKeyHint("!", "bash"),
|
|
463
|
+
hint("app.tools.expand", "more"),
|
|
464
|
+
].join(theme.fg("muted", " · "));
|
|
465
|
+
const compactOnboarding = theme.fg("dim", `Press ${keyText("app.tools.expand")} to show full startup help and loaded resources.`);
|
|
466
|
+
const onboarding = theme.fg("dim", `Pi can explain its own features and look up its docs. Ask it how to use or extend Pi.`);
|
|
467
|
+
this.builtInHeader = new ExpandableText(() => `${logo}\n${compactInstructions}\n${compactOnboarding}\n\n${onboarding}`, () => `${logo}\n${expandedInstructions}\n\n${onboarding}`, this.getStartupExpansionState(), 1, 0);
|
|
468
|
+
// Setup UI layout
|
|
469
|
+
this.headerContainer.addChild(new Spacer(1));
|
|
470
|
+
this.headerContainer.addChild(this.builtInHeader);
|
|
471
|
+
this.headerContainer.addChild(new Spacer(1));
|
|
472
|
+
}
|
|
473
|
+
else {
|
|
474
|
+
// Minimal header when silenced
|
|
475
|
+
this.builtInHeader = new Text("", 0, 0);
|
|
476
|
+
this.headerContainer.addChild(this.builtInHeader);
|
|
477
|
+
}
|
|
478
|
+
this.ui.addChild(this.chatContainer);
|
|
479
|
+
this.ui.addChild(this.pendingMessagesContainer);
|
|
480
|
+
this.ui.addChild(this.statusContainer);
|
|
481
|
+
this.renderWidgets(); // Initialize with default spacer
|
|
482
|
+
this.ui.addChild(this.widgetContainerAbove);
|
|
483
|
+
this.ui.addChild(this.editorContainer);
|
|
484
|
+
this.ui.addChild(this.widgetContainerBelow);
|
|
485
|
+
this.ui.addChild(this.footer);
|
|
486
|
+
this.ui.setFocus(this.editor);
|
|
487
|
+
this.setupKeyHandlers();
|
|
488
|
+
this.setupEditorSubmitHandler();
|
|
489
|
+
// Start the UI before initializing extensions so session_start handlers can use interactive dialogs
|
|
490
|
+
this.ui.start();
|
|
491
|
+
this.isInitialized = true;
|
|
492
|
+
// Initialize extensions first so resources are shown before messages
|
|
493
|
+
await this.rebindCurrentSession();
|
|
494
|
+
// Render initial messages AFTER showing loaded resources
|
|
495
|
+
this.renderInitialMessages();
|
|
496
|
+
// Set up theme file watcher
|
|
497
|
+
onThemeChange(() => {
|
|
498
|
+
this.ui.invalidate();
|
|
499
|
+
this.updateEditorBorderColor();
|
|
500
|
+
this.ui.requestRender();
|
|
501
|
+
});
|
|
502
|
+
// Set up git branch watcher (uses provider instead of footer)
|
|
503
|
+
this.footerDataProvider.onBranchChange(() => {
|
|
504
|
+
this.ui.requestRender();
|
|
505
|
+
});
|
|
506
|
+
// Initialize available provider count for footer display
|
|
507
|
+
await this.updateAvailableProviderCount();
|
|
508
|
+
}
|
|
509
|
+
/**
|
|
510
|
+
* Update terminal title with session name and cwd.
|
|
511
|
+
*/
|
|
512
|
+
updateTerminalTitle() {
|
|
513
|
+
const cwdBasename = path.basename(this.sessionManager.getCwd());
|
|
514
|
+
const sessionName = this.sessionManager.getSessionName();
|
|
515
|
+
if (sessionName) {
|
|
516
|
+
this.ui.terminal.setTitle(`${APP_TITLE} - ${sessionName} - ${cwdBasename}`);
|
|
517
|
+
}
|
|
518
|
+
else {
|
|
519
|
+
this.ui.terminal.setTitle(`${APP_TITLE} - ${cwdBasename}`);
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
/**
|
|
523
|
+
* Run the interactive mode. This is the main entry point.
|
|
524
|
+
* Initializes the UI, shows warnings, processes initial messages, and starts the interactive loop.
|
|
525
|
+
*/
|
|
526
|
+
async run() {
|
|
527
|
+
await this.init();
|
|
528
|
+
// Start version check asynchronously
|
|
529
|
+
checkForNewPiVersion(this.version).then((newVersion) => {
|
|
530
|
+
if (newVersion) {
|
|
531
|
+
this.showNewVersionNotification(newVersion);
|
|
532
|
+
}
|
|
533
|
+
});
|
|
534
|
+
// Start package update check asynchronously
|
|
535
|
+
this.checkForPackageUpdates().then((updates) => {
|
|
536
|
+
if (updates.length > 0) {
|
|
537
|
+
this.showPackageUpdateNotification(updates);
|
|
538
|
+
}
|
|
539
|
+
});
|
|
540
|
+
// Check tmux keyboard setup asynchronously
|
|
541
|
+
this.checkTmuxKeyboardSetup().then((warning) => {
|
|
542
|
+
if (warning) {
|
|
543
|
+
this.showWarning(warning);
|
|
544
|
+
}
|
|
545
|
+
});
|
|
546
|
+
// Show startup warnings
|
|
547
|
+
const { migratedProviders, modelFallbackMessage, initialMessage, initialImages, initialMessages } = this.options;
|
|
548
|
+
if (migratedProviders && migratedProviders.length > 0) {
|
|
549
|
+
this.showWarning(`Migrated credentials to auth.json: ${migratedProviders.join(", ")}`);
|
|
550
|
+
}
|
|
551
|
+
const modelsJsonError = this.session.modelRegistry.getError();
|
|
552
|
+
if (modelsJsonError) {
|
|
553
|
+
this.showError(`models.json error: ${modelsJsonError}`);
|
|
554
|
+
}
|
|
555
|
+
if (modelFallbackMessage) {
|
|
556
|
+
this.showWarning(modelFallbackMessage);
|
|
557
|
+
}
|
|
558
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth();
|
|
559
|
+
// Process initial messages
|
|
560
|
+
if (initialMessage) {
|
|
561
|
+
try {
|
|
562
|
+
await this.session.prompt(initialMessage, { images: initialImages });
|
|
563
|
+
}
|
|
564
|
+
catch (error) {
|
|
565
|
+
const errorMessage = error instanceof Error ? error.message : "Unknown error occurred";
|
|
566
|
+
this.showError(errorMessage);
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
if (initialMessages) {
|
|
570
|
+
for (const message of initialMessages) {
|
|
571
|
+
try {
|
|
572
|
+
await this.session.prompt(message);
|
|
573
|
+
}
|
|
574
|
+
catch (error) {
|
|
575
|
+
const errorMessage = error instanceof Error ? error.message : "Unknown error occurred";
|
|
576
|
+
this.showError(errorMessage);
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
}
|
|
580
|
+
// Main interactive loop
|
|
581
|
+
while (true) {
|
|
582
|
+
const userInput = await this.getUserInput();
|
|
583
|
+
try {
|
|
584
|
+
await this.session.prompt(userInput);
|
|
585
|
+
}
|
|
586
|
+
catch (error) {
|
|
587
|
+
const errorMessage = error instanceof Error ? error.message : "Unknown error occurred";
|
|
588
|
+
this.showError(errorMessage);
|
|
589
|
+
}
|
|
590
|
+
}
|
|
591
|
+
}
|
|
592
|
+
async checkForPackageUpdates() {
|
|
593
|
+
if (process.env.PI_OFFLINE) {
|
|
594
|
+
return [];
|
|
595
|
+
}
|
|
596
|
+
try {
|
|
597
|
+
const packageManager = new DefaultPackageManager({
|
|
598
|
+
cwd: this.sessionManager.getCwd(),
|
|
599
|
+
agentDir: getAgentDir(),
|
|
600
|
+
settingsManager: this.settingsManager,
|
|
601
|
+
});
|
|
602
|
+
const updates = await packageManager.checkForAvailableUpdates();
|
|
603
|
+
return updates.map((update) => update.displayName);
|
|
604
|
+
}
|
|
605
|
+
catch {
|
|
606
|
+
return [];
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
async checkTmuxKeyboardSetup() {
|
|
610
|
+
if (!process.env.TMUX)
|
|
611
|
+
return undefined;
|
|
612
|
+
const runTmuxShow = (option) => {
|
|
613
|
+
return new Promise((resolve) => {
|
|
614
|
+
const proc = spawn("tmux", ["show", "-gv", option], {
|
|
615
|
+
stdio: ["ignore", "pipe", "ignore"],
|
|
616
|
+
});
|
|
617
|
+
let stdout = "";
|
|
618
|
+
const timer = setTimeout(() => {
|
|
619
|
+
proc.kill();
|
|
620
|
+
resolve(undefined);
|
|
621
|
+
}, 2000);
|
|
622
|
+
proc.stdout?.on("data", (data) => {
|
|
623
|
+
stdout += data.toString();
|
|
624
|
+
});
|
|
625
|
+
proc.on("error", () => {
|
|
626
|
+
clearTimeout(timer);
|
|
627
|
+
resolve(undefined);
|
|
628
|
+
});
|
|
629
|
+
proc.on("close", (code) => {
|
|
630
|
+
clearTimeout(timer);
|
|
631
|
+
resolve(code === 0 ? stdout.trim() : undefined);
|
|
632
|
+
});
|
|
633
|
+
});
|
|
634
|
+
};
|
|
635
|
+
const [extendedKeys, extendedKeysFormat] = await Promise.all([
|
|
636
|
+
runTmuxShow("extended-keys"),
|
|
637
|
+
runTmuxShow("extended-keys-format"),
|
|
638
|
+
]);
|
|
639
|
+
// If we couldn't query tmux (timeout, sandbox, etc.), don't warn
|
|
640
|
+
if (extendedKeys === undefined)
|
|
641
|
+
return undefined;
|
|
642
|
+
if (extendedKeys !== "on" && extendedKeys !== "always") {
|
|
643
|
+
return "tmux extended-keys is off. Modified Enter keys may not work. Add `set -g extended-keys on` to ~/.tmux.conf and restart tmux.";
|
|
644
|
+
}
|
|
645
|
+
if (extendedKeysFormat === "xterm") {
|
|
646
|
+
return "tmux extended-keys-format is xterm. Pi works best with csi-u. Add `set -g extended-keys-format csi-u` to ~/.tmux.conf and restart tmux.";
|
|
647
|
+
}
|
|
648
|
+
return undefined;
|
|
649
|
+
}
|
|
650
|
+
/**
|
|
651
|
+
* Get changelog entries to display on startup.
|
|
652
|
+
* Only shows new entries since last seen version, skips for resumed sessions.
|
|
653
|
+
*/
|
|
654
|
+
getChangelogForDisplay() {
|
|
655
|
+
// Skip changelog for resumed/continued sessions (already have messages)
|
|
656
|
+
if (this.session.state.messages.length > 0) {
|
|
657
|
+
return undefined;
|
|
658
|
+
}
|
|
659
|
+
const lastVersion = this.settingsManager.getLastChangelogVersion();
|
|
660
|
+
const changelogPath = getChangelogPath();
|
|
661
|
+
const entries = parseChangelog(changelogPath);
|
|
662
|
+
if (!lastVersion) {
|
|
663
|
+
// Fresh install - record the version, send telemetry, don't show changelog
|
|
664
|
+
this.settingsManager.setLastChangelogVersion(VERSION);
|
|
665
|
+
this.reportInstallTelemetry(VERSION);
|
|
666
|
+
return undefined;
|
|
667
|
+
}
|
|
668
|
+
const newEntries = getNewEntries(entries, lastVersion);
|
|
669
|
+
if (newEntries.length > 0) {
|
|
670
|
+
this.settingsManager.setLastChangelogVersion(VERSION);
|
|
671
|
+
this.reportInstallTelemetry(VERSION);
|
|
672
|
+
return newEntries.map((e) => e.content).join("\n\n");
|
|
673
|
+
}
|
|
674
|
+
return undefined;
|
|
675
|
+
}
|
|
676
|
+
reportInstallTelemetry(version) {
|
|
677
|
+
if (process.env.PI_OFFLINE) {
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
680
|
+
if (!isInstallTelemetryEnabled(this.settingsManager)) {
|
|
681
|
+
return;
|
|
682
|
+
}
|
|
683
|
+
void fetch(`https://pi.dev/api/report-install?version=${encodeURIComponent(version)}`, {
|
|
684
|
+
headers: {
|
|
685
|
+
"User-Agent": getPiUserAgent(version),
|
|
686
|
+
},
|
|
687
|
+
signal: AbortSignal.timeout(5000),
|
|
688
|
+
})
|
|
689
|
+
.then(() => undefined)
|
|
690
|
+
.catch(() => undefined);
|
|
691
|
+
}
|
|
692
|
+
getMarkdownThemeWithSettings() {
|
|
693
|
+
return {
|
|
694
|
+
...getMarkdownTheme(),
|
|
695
|
+
codeBlockIndent: this.settingsManager.getCodeBlockIndent(),
|
|
696
|
+
};
|
|
697
|
+
}
|
|
698
|
+
// =========================================================================
|
|
699
|
+
// Extension System
|
|
700
|
+
// =========================================================================
|
|
701
|
+
formatDisplayPath(p) {
|
|
702
|
+
const home = os.homedir();
|
|
703
|
+
let result = p;
|
|
704
|
+
// Replace home directory with ~
|
|
705
|
+
if (result.startsWith(home)) {
|
|
706
|
+
result = `~${result.slice(home.length)}`;
|
|
707
|
+
}
|
|
708
|
+
return result;
|
|
709
|
+
}
|
|
710
|
+
formatExtensionDisplayPath(path) {
|
|
711
|
+
let result = this.formatDisplayPath(path);
|
|
712
|
+
result = result.replace(/\/index\.ts$/, "").replace(/\/index\.js$/, "");
|
|
713
|
+
return result;
|
|
714
|
+
}
|
|
715
|
+
formatContextPath(p) {
|
|
716
|
+
const cwd = path.resolve(this.sessionManager.getCwd());
|
|
717
|
+
const absolutePath = path.isAbsolute(p) ? path.resolve(p) : path.resolve(cwd, p);
|
|
718
|
+
const relativePath = getCwdRelativePath(absolutePath, cwd);
|
|
719
|
+
if (relativePath !== undefined) {
|
|
720
|
+
return relativePath;
|
|
721
|
+
}
|
|
722
|
+
return this.formatDisplayPath(absolutePath);
|
|
723
|
+
}
|
|
724
|
+
getStartupExpansionState() {
|
|
725
|
+
return this.options.verbose || this.toolOutputExpanded;
|
|
726
|
+
}
|
|
727
|
+
/**
|
|
728
|
+
* Get a short path relative to the package root for display.
|
|
729
|
+
*/
|
|
730
|
+
getShortPath(fullPath, sourceInfo) {
|
|
731
|
+
const baseDir = sourceInfo?.baseDir;
|
|
732
|
+
if (baseDir && this.isPackageSource(sourceInfo)) {
|
|
733
|
+
const relativePath = path.relative(path.resolve(baseDir), path.resolve(fullPath));
|
|
734
|
+
if (relativePath &&
|
|
735
|
+
relativePath !== "." &&
|
|
736
|
+
!relativePath.startsWith("..") &&
|
|
737
|
+
!relativePath.startsWith(`..${path.sep}`) &&
|
|
738
|
+
!path.isAbsolute(relativePath)) {
|
|
739
|
+
return relativePath.replace(/\\/g, "/");
|
|
740
|
+
}
|
|
741
|
+
}
|
|
742
|
+
const source = sourceInfo?.source ?? "";
|
|
743
|
+
const npmMatch = fullPath.match(/node_modules\/(@?[^/]+(?:\/[^/]+)?)\/(.*)/);
|
|
744
|
+
if (npmMatch && source.startsWith("npm:")) {
|
|
745
|
+
return npmMatch[2];
|
|
746
|
+
}
|
|
747
|
+
const gitMatch = fullPath.match(/git\/[^/]+\/[^/]+\/(.*)/);
|
|
748
|
+
if (gitMatch && source.startsWith("git:")) {
|
|
749
|
+
return gitMatch[1];
|
|
750
|
+
}
|
|
751
|
+
return this.formatDisplayPath(fullPath);
|
|
752
|
+
}
|
|
753
|
+
getCompactPathLabel(resourcePath, sourceInfo) {
|
|
754
|
+
const shortPath = this.getShortPath(resourcePath, sourceInfo);
|
|
755
|
+
const normalizedPath = shortPath.replace(/\\/g, "/");
|
|
756
|
+
const segments = normalizedPath.split("/").filter((segment) => segment.length > 0 && segment !== "~");
|
|
757
|
+
if (segments.length > 0) {
|
|
758
|
+
return segments[segments.length - 1];
|
|
759
|
+
}
|
|
760
|
+
return shortPath;
|
|
761
|
+
}
|
|
762
|
+
getCompactPackageSourceLabel(sourceInfo) {
|
|
763
|
+
const source = sourceInfo?.source ?? "";
|
|
764
|
+
if (source.startsWith("npm:")) {
|
|
765
|
+
return source.slice("npm:".length) || source;
|
|
766
|
+
}
|
|
767
|
+
const gitSource = parseGitUrl(source);
|
|
768
|
+
if (gitSource) {
|
|
769
|
+
return gitSource.path || source;
|
|
770
|
+
}
|
|
771
|
+
return source;
|
|
772
|
+
}
|
|
773
|
+
getCompactExtensionLabel(resourcePath, sourceInfo) {
|
|
774
|
+
if (!this.isPackageSource(sourceInfo)) {
|
|
775
|
+
return this.getCompactPathLabel(resourcePath, sourceInfo);
|
|
776
|
+
}
|
|
777
|
+
const sourceLabel = this.getCompactPackageSourceLabel(sourceInfo);
|
|
778
|
+
if (!sourceLabel) {
|
|
779
|
+
return this.getCompactPathLabel(resourcePath, sourceInfo);
|
|
780
|
+
}
|
|
781
|
+
const shortPath = this.getShortPath(resourcePath, sourceInfo).replace(/\\/g, "/");
|
|
782
|
+
const packagePath = shortPath.startsWith("extensions/") ? shortPath.slice("extensions/".length) : shortPath;
|
|
783
|
+
const parsedPath = path.posix.parse(packagePath);
|
|
784
|
+
if (parsedPath.name === "index") {
|
|
785
|
+
return !parsedPath.dir || parsedPath.dir === "." ? sourceLabel : `${sourceLabel}:${parsedPath.dir}`;
|
|
786
|
+
}
|
|
787
|
+
return `${sourceLabel}:${packagePath}`;
|
|
788
|
+
}
|
|
789
|
+
getCompactDisplayPathSegments(resourcePath) {
|
|
790
|
+
return this.formatDisplayPath(resourcePath)
|
|
791
|
+
.replace(/\\/g, "/")
|
|
792
|
+
.split("/")
|
|
793
|
+
.filter((segment) => segment.length > 0 && segment !== "~");
|
|
794
|
+
}
|
|
795
|
+
getCompactNonPackageExtensionLabel(resourcePath, index, allPaths) {
|
|
796
|
+
const segments = allPaths[index]?.segments;
|
|
797
|
+
if (!segments || segments.length === 0) {
|
|
798
|
+
return this.getCompactPathLabel(resourcePath);
|
|
799
|
+
}
|
|
800
|
+
for (let segmentCount = 1; segmentCount <= segments.length; segmentCount += 1) {
|
|
801
|
+
const candidate = segments.slice(-segmentCount).join("/");
|
|
802
|
+
const isUnique = allPaths.every((item, itemIndex) => {
|
|
803
|
+
if (itemIndex === index) {
|
|
804
|
+
return true;
|
|
805
|
+
}
|
|
806
|
+
return item.segments.slice(-segmentCount).join("/") !== candidate;
|
|
807
|
+
});
|
|
808
|
+
if (isUnique) {
|
|
809
|
+
return candidate;
|
|
810
|
+
}
|
|
811
|
+
}
|
|
812
|
+
return segments.join("/");
|
|
813
|
+
}
|
|
814
|
+
getCompactExtensionLabels(extensions) {
|
|
815
|
+
const nonPackageExtensions = extensions
|
|
816
|
+
.map((extension) => {
|
|
817
|
+
const segments = this.getCompactDisplayPathSegments(extension.path);
|
|
818
|
+
const lastSegment = segments[segments.length - 1];
|
|
819
|
+
if (segments.length > 1 && (lastSegment === "index.ts" || lastSegment === "index.js")) {
|
|
820
|
+
segments.pop();
|
|
821
|
+
}
|
|
822
|
+
return {
|
|
823
|
+
path: extension.path,
|
|
824
|
+
sourceInfo: extension.sourceInfo,
|
|
825
|
+
segments,
|
|
826
|
+
};
|
|
827
|
+
})
|
|
828
|
+
.filter((extension) => !this.isPackageSource(extension.sourceInfo));
|
|
829
|
+
return extensions.map((extension) => {
|
|
830
|
+
if (this.isPackageSource(extension.sourceInfo)) {
|
|
831
|
+
return this.getCompactExtensionLabel(extension.path, extension.sourceInfo);
|
|
832
|
+
}
|
|
833
|
+
const nonPackageIndex = nonPackageExtensions.findIndex((item) => item.path === extension.path);
|
|
834
|
+
if (nonPackageIndex === -1) {
|
|
835
|
+
return this.getCompactPathLabel(extension.path, extension.sourceInfo);
|
|
836
|
+
}
|
|
837
|
+
return this.getCompactNonPackageExtensionLabel(extension.path, nonPackageIndex, nonPackageExtensions);
|
|
838
|
+
});
|
|
839
|
+
}
|
|
840
|
+
getDisplaySourceInfo(sourceInfo) {
|
|
841
|
+
const source = sourceInfo?.source ?? "local";
|
|
842
|
+
const scope = sourceInfo?.scope ?? "project";
|
|
843
|
+
if (source === "local") {
|
|
844
|
+
if (scope === "user") {
|
|
845
|
+
return { label: "user", color: "muted" };
|
|
846
|
+
}
|
|
847
|
+
if (scope === "project") {
|
|
848
|
+
return { label: "project", color: "muted" };
|
|
849
|
+
}
|
|
850
|
+
if (scope === "temporary") {
|
|
851
|
+
return { label: "path", scopeLabel: "temp", color: "muted" };
|
|
852
|
+
}
|
|
853
|
+
return { label: "path", color: "muted" };
|
|
854
|
+
}
|
|
855
|
+
if (source === "cli") {
|
|
856
|
+
return { label: "path", scopeLabel: scope === "temporary" ? "temp" : undefined, color: "muted" };
|
|
857
|
+
}
|
|
858
|
+
const scopeLabel = scope === "user" ? "user" : scope === "project" ? "project" : scope === "temporary" ? "temp" : undefined;
|
|
859
|
+
return { label: source, scopeLabel, color: "accent" };
|
|
860
|
+
}
|
|
861
|
+
getScopeGroup(sourceInfo) {
|
|
862
|
+
const source = sourceInfo?.source ?? "local";
|
|
863
|
+
const scope = sourceInfo?.scope ?? "project";
|
|
864
|
+
if (source === "cli" || scope === "temporary")
|
|
865
|
+
return "path";
|
|
866
|
+
if (scope === "user")
|
|
867
|
+
return "user";
|
|
868
|
+
if (scope === "project")
|
|
869
|
+
return "project";
|
|
870
|
+
return "path";
|
|
871
|
+
}
|
|
872
|
+
isPackageSource(sourceInfo) {
|
|
873
|
+
const source = sourceInfo?.source ?? "";
|
|
874
|
+
return source.startsWith("npm:") || source.startsWith("git:");
|
|
875
|
+
}
|
|
876
|
+
buildScopeGroups(items) {
|
|
877
|
+
const groups = {
|
|
878
|
+
user: { scope: "user", paths: [], packages: new Map() },
|
|
879
|
+
project: { scope: "project", paths: [], packages: new Map() },
|
|
880
|
+
path: { scope: "path", paths: [], packages: new Map() },
|
|
881
|
+
};
|
|
882
|
+
for (const item of items) {
|
|
883
|
+
const groupKey = this.getScopeGroup(item.sourceInfo);
|
|
884
|
+
const group = groups[groupKey];
|
|
885
|
+
const source = item.sourceInfo?.source ?? "local";
|
|
886
|
+
if (this.isPackageSource(item.sourceInfo)) {
|
|
887
|
+
const list = group.packages.get(source) ?? [];
|
|
888
|
+
list.push(item);
|
|
889
|
+
group.packages.set(source, list);
|
|
890
|
+
}
|
|
891
|
+
else {
|
|
892
|
+
group.paths.push(item);
|
|
893
|
+
}
|
|
894
|
+
}
|
|
895
|
+
return [groups.project, groups.user, groups.path].filter((group) => group.paths.length > 0 || group.packages.size > 0);
|
|
896
|
+
}
|
|
897
|
+
formatScopeGroups(groups, options) {
|
|
898
|
+
const lines = [];
|
|
899
|
+
for (const group of groups) {
|
|
900
|
+
lines.push(` ${theme.fg("accent", group.scope)}`);
|
|
901
|
+
const sortedPaths = [...group.paths].sort((a, b) => a.path.localeCompare(b.path));
|
|
902
|
+
for (const item of sortedPaths) {
|
|
903
|
+
lines.push(theme.fg("dim", ` ${options.formatPath(item)}`));
|
|
904
|
+
}
|
|
905
|
+
const sortedPackages = Array.from(group.packages.entries()).sort(([a], [b]) => a.localeCompare(b));
|
|
906
|
+
for (const [source, items] of sortedPackages) {
|
|
907
|
+
lines.push(` ${theme.fg("mdLink", source)}`);
|
|
908
|
+
const sortedPackagePaths = [...items].sort((a, b) => a.path.localeCompare(b.path));
|
|
909
|
+
for (const item of sortedPackagePaths) {
|
|
910
|
+
lines.push(theme.fg("dim", ` ${options.formatPackagePath(item, source)}`));
|
|
911
|
+
}
|
|
912
|
+
}
|
|
913
|
+
}
|
|
914
|
+
return lines.join("\n");
|
|
915
|
+
}
|
|
916
|
+
findSourceInfoForPath(p, sourceInfos) {
|
|
917
|
+
const exact = sourceInfos.get(p);
|
|
918
|
+
if (exact)
|
|
919
|
+
return exact;
|
|
920
|
+
let current = p;
|
|
921
|
+
while (current.includes("/")) {
|
|
922
|
+
current = current.substring(0, current.lastIndexOf("/"));
|
|
923
|
+
const parent = sourceInfos.get(current);
|
|
924
|
+
if (parent)
|
|
925
|
+
return parent;
|
|
926
|
+
}
|
|
927
|
+
return undefined;
|
|
928
|
+
}
|
|
929
|
+
formatPathWithSource(p, sourceInfo) {
|
|
930
|
+
if (sourceInfo) {
|
|
931
|
+
const shortPath = this.getShortPath(p, sourceInfo);
|
|
932
|
+
const { label, scopeLabel } = this.getDisplaySourceInfo(sourceInfo);
|
|
933
|
+
const labelText = scopeLabel ? `${label} (${scopeLabel})` : label;
|
|
934
|
+
return `${labelText} ${shortPath}`;
|
|
935
|
+
}
|
|
936
|
+
return this.formatDisplayPath(p);
|
|
937
|
+
}
|
|
938
|
+
formatDiagnostics(diagnostics, sourceInfos) {
|
|
939
|
+
const lines = [];
|
|
940
|
+
// Group collision diagnostics by name
|
|
941
|
+
const collisions = new Map();
|
|
942
|
+
const otherDiagnostics = [];
|
|
943
|
+
for (const d of diagnostics) {
|
|
944
|
+
if (d.type === "collision" && d.collision) {
|
|
945
|
+
const list = collisions.get(d.collision.name) ?? [];
|
|
946
|
+
list.push(d);
|
|
947
|
+
collisions.set(d.collision.name, list);
|
|
948
|
+
}
|
|
949
|
+
else {
|
|
950
|
+
otherDiagnostics.push(d);
|
|
951
|
+
}
|
|
952
|
+
}
|
|
953
|
+
// Format collision diagnostics grouped by name
|
|
954
|
+
for (const [name, collisionList] of collisions) {
|
|
955
|
+
const first = collisionList[0]?.collision;
|
|
956
|
+
if (!first)
|
|
957
|
+
continue;
|
|
958
|
+
lines.push(theme.fg("warning", ` "${name}" collision:`));
|
|
959
|
+
lines.push(theme.fg("dim", ` ${theme.fg("success", "✓")} ${this.formatPathWithSource(first.winnerPath, this.findSourceInfoForPath(first.winnerPath, sourceInfos))}`));
|
|
960
|
+
for (const d of collisionList) {
|
|
961
|
+
if (d.collision) {
|
|
962
|
+
lines.push(theme.fg("dim", ` ${theme.fg("warning", "✗")} ${this.formatPathWithSource(d.collision.loserPath, this.findSourceInfoForPath(d.collision.loserPath, sourceInfos))} (skipped)`));
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
}
|
|
966
|
+
for (const d of otherDiagnostics) {
|
|
967
|
+
if (d.path) {
|
|
968
|
+
const formattedPath = this.formatPathWithSource(d.path, this.findSourceInfoForPath(d.path, sourceInfos));
|
|
969
|
+
lines.push(theme.fg(d.type === "error" ? "error" : "warning", ` ${formattedPath}`));
|
|
970
|
+
lines.push(theme.fg(d.type === "error" ? "error" : "warning", ` ${d.message}`));
|
|
971
|
+
}
|
|
972
|
+
else {
|
|
973
|
+
lines.push(theme.fg(d.type === "error" ? "error" : "warning", ` ${d.message}`));
|
|
974
|
+
}
|
|
975
|
+
}
|
|
976
|
+
return lines.join("\n");
|
|
977
|
+
}
|
|
978
|
+
showLoadedResources(options) {
|
|
979
|
+
const showListing = options?.force || this.options.verbose || !this.settingsManager.getQuietStartup();
|
|
980
|
+
const showDiagnostics = showListing || options?.showDiagnosticsWhenQuiet === true;
|
|
981
|
+
if (!showListing && !showDiagnostics) {
|
|
982
|
+
return;
|
|
983
|
+
}
|
|
984
|
+
const sectionHeader = (name, color = "mdHeading") => theme.fg(color, `[${name}]`);
|
|
985
|
+
const formatCompactList = (items, options) => {
|
|
986
|
+
const labels = items.map((item) => item.trim()).filter((item) => item.length > 0);
|
|
987
|
+
if (options?.sort !== false) {
|
|
988
|
+
labels.sort((a, b) => a.localeCompare(b));
|
|
989
|
+
}
|
|
990
|
+
return theme.fg("dim", ` ${labels.join(", ")}`);
|
|
991
|
+
};
|
|
992
|
+
const addLoadedSection = (name, collapsedBody, expandedBody = collapsedBody, color = "mdHeading") => {
|
|
993
|
+
const section = new ExpandableText(() => `${sectionHeader(name, color)}\n${collapsedBody}`, () => `${sectionHeader(name, color)}\n${expandedBody}`, this.getStartupExpansionState(), 0, 0);
|
|
994
|
+
this.chatContainer.addChild(section);
|
|
995
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
996
|
+
};
|
|
997
|
+
const skillsResult = this.session.resourceLoader.getSkills();
|
|
998
|
+
const promptsResult = this.session.resourceLoader.getPrompts();
|
|
999
|
+
const themesResult = this.session.resourceLoader.getThemes();
|
|
1000
|
+
const extensions = options?.extensions ??
|
|
1001
|
+
this.session.resourceLoader.getExtensions().extensions.map((extension) => ({
|
|
1002
|
+
path: extension.path,
|
|
1003
|
+
sourceInfo: extension.sourceInfo,
|
|
1004
|
+
}));
|
|
1005
|
+
const sourceInfos = new Map();
|
|
1006
|
+
for (const extension of extensions) {
|
|
1007
|
+
if (extension.sourceInfo) {
|
|
1008
|
+
sourceInfos.set(extension.path, extension.sourceInfo);
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
for (const skill of skillsResult.skills) {
|
|
1012
|
+
if (skill.sourceInfo) {
|
|
1013
|
+
sourceInfos.set(skill.filePath, skill.sourceInfo);
|
|
1014
|
+
}
|
|
1015
|
+
}
|
|
1016
|
+
for (const prompt of promptsResult.prompts) {
|
|
1017
|
+
if (prompt.sourceInfo) {
|
|
1018
|
+
sourceInfos.set(prompt.filePath, prompt.sourceInfo);
|
|
1019
|
+
}
|
|
1020
|
+
}
|
|
1021
|
+
for (const loadedTheme of themesResult.themes) {
|
|
1022
|
+
if (loadedTheme.sourcePath && loadedTheme.sourceInfo) {
|
|
1023
|
+
sourceInfos.set(loadedTheme.sourcePath, loadedTheme.sourceInfo);
|
|
1024
|
+
}
|
|
1025
|
+
}
|
|
1026
|
+
if (showListing) {
|
|
1027
|
+
const contextFiles = this.session.resourceLoader.getAgentsFiles().agentsFiles;
|
|
1028
|
+
if (contextFiles.length > 0) {
|
|
1029
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
1030
|
+
const contextList = contextFiles
|
|
1031
|
+
.map((f) => theme.fg("dim", ` ${this.formatDisplayPath(f.path)}`))
|
|
1032
|
+
.join("\n");
|
|
1033
|
+
const contextCompactList = formatCompactList(contextFiles.map((contextFile) => this.formatContextPath(contextFile.path)), { sort: false });
|
|
1034
|
+
addLoadedSection("Context", contextCompactList, contextList);
|
|
1035
|
+
}
|
|
1036
|
+
const skills = skillsResult.skills;
|
|
1037
|
+
if (skills.length > 0) {
|
|
1038
|
+
const groups = this.buildScopeGroups(skills.map((skill) => ({ path: skill.filePath, sourceInfo: skill.sourceInfo })));
|
|
1039
|
+
const skillList = this.formatScopeGroups(groups, {
|
|
1040
|
+
formatPath: (item) => this.formatDisplayPath(item.path),
|
|
1041
|
+
formatPackagePath: (item) => this.getShortPath(item.path, item.sourceInfo),
|
|
1042
|
+
});
|
|
1043
|
+
const skillCompactList = formatCompactList(skills.map((skill) => skill.name));
|
|
1044
|
+
addLoadedSection("Skills", skillCompactList, skillList);
|
|
1045
|
+
}
|
|
1046
|
+
const templates = this.session.promptTemplates;
|
|
1047
|
+
if (templates.length > 0) {
|
|
1048
|
+
const groups = this.buildScopeGroups(templates.map((template) => ({ path: template.filePath, sourceInfo: template.sourceInfo })));
|
|
1049
|
+
const templateByPath = new Map(templates.map((t) => [t.filePath, t]));
|
|
1050
|
+
const templateList = this.formatScopeGroups(groups, {
|
|
1051
|
+
formatPath: (item) => {
|
|
1052
|
+
const template = templateByPath.get(item.path);
|
|
1053
|
+
return template ? `/${template.name}` : this.formatDisplayPath(item.path);
|
|
1054
|
+
},
|
|
1055
|
+
formatPackagePath: (item) => {
|
|
1056
|
+
const template = templateByPath.get(item.path);
|
|
1057
|
+
return template ? `/${template.name}` : this.formatDisplayPath(item.path);
|
|
1058
|
+
},
|
|
1059
|
+
});
|
|
1060
|
+
const promptCompactList = formatCompactList(templates.map((template) => `/${template.name}`));
|
|
1061
|
+
addLoadedSection("Prompts", promptCompactList, templateList);
|
|
1062
|
+
}
|
|
1063
|
+
if (extensions.length > 0) {
|
|
1064
|
+
const groups = this.buildScopeGroups(extensions);
|
|
1065
|
+
const extList = this.formatScopeGroups(groups, {
|
|
1066
|
+
formatPath: (item) => this.formatExtensionDisplayPath(item.path),
|
|
1067
|
+
formatPackagePath: (item) => this.formatExtensionDisplayPath(this.getShortPath(item.path, item.sourceInfo)),
|
|
1068
|
+
});
|
|
1069
|
+
const extensionCompactList = formatCompactList(this.getCompactExtensionLabels(extensions));
|
|
1070
|
+
addLoadedSection("Extensions", extensionCompactList, extList, "mdHeading");
|
|
1071
|
+
}
|
|
1072
|
+
// Show loaded themes (excluding built-in)
|
|
1073
|
+
const loadedThemes = themesResult.themes;
|
|
1074
|
+
const customThemes = loadedThemes.filter((t) => t.sourcePath);
|
|
1075
|
+
if (customThemes.length > 0) {
|
|
1076
|
+
const groups = this.buildScopeGroups(customThemes.map((loadedTheme) => ({
|
|
1077
|
+
path: loadedTheme.sourcePath,
|
|
1078
|
+
sourceInfo: loadedTheme.sourceInfo,
|
|
1079
|
+
})));
|
|
1080
|
+
const themeList = this.formatScopeGroups(groups, {
|
|
1081
|
+
formatPath: (item) => this.formatDisplayPath(item.path),
|
|
1082
|
+
formatPackagePath: (item) => this.getShortPath(item.path, item.sourceInfo),
|
|
1083
|
+
});
|
|
1084
|
+
const themeCompactList = formatCompactList(customThemes.map((loadedTheme) => loadedTheme.name ?? this.getCompactPathLabel(loadedTheme.sourcePath, loadedTheme.sourceInfo)));
|
|
1085
|
+
addLoadedSection("Themes", themeCompactList, themeList);
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
if (showDiagnostics) {
|
|
1089
|
+
const skillDiagnostics = skillsResult.diagnostics;
|
|
1090
|
+
if (skillDiagnostics.length > 0) {
|
|
1091
|
+
const warningLines = this.formatDiagnostics(skillDiagnostics, sourceInfos);
|
|
1092
|
+
this.chatContainer.addChild(new Text(`${theme.fg("warning", "[Skill conflicts]")}\n${warningLines}`, 0, 0));
|
|
1093
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
1094
|
+
}
|
|
1095
|
+
const promptDiagnostics = promptsResult.diagnostics;
|
|
1096
|
+
if (promptDiagnostics.length > 0) {
|
|
1097
|
+
const warningLines = this.formatDiagnostics(promptDiagnostics, sourceInfos);
|
|
1098
|
+
this.chatContainer.addChild(new Text(`${theme.fg("warning", "[Prompt conflicts]")}\n${warningLines}`, 0, 0));
|
|
1099
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
1100
|
+
}
|
|
1101
|
+
const extensionDiagnostics = [];
|
|
1102
|
+
const extensionErrors = this.session.resourceLoader.getExtensions().errors;
|
|
1103
|
+
if (extensionErrors.length > 0) {
|
|
1104
|
+
for (const error of extensionErrors) {
|
|
1105
|
+
extensionDiagnostics.push({ type: "error", message: error.error, path: error.path });
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
const commandDiagnostics = this.session.extensionRunner.getCommandDiagnostics();
|
|
1109
|
+
extensionDiagnostics.push(...commandDiagnostics);
|
|
1110
|
+
extensionDiagnostics.push(...this.getBuiltInCommandConflictDiagnostics(this.session.extensionRunner));
|
|
1111
|
+
const shortcutDiagnostics = this.session.extensionRunner.getShortcutDiagnostics();
|
|
1112
|
+
extensionDiagnostics.push(...shortcutDiagnostics);
|
|
1113
|
+
if (extensionDiagnostics.length > 0) {
|
|
1114
|
+
const warningLines = this.formatDiagnostics(extensionDiagnostics, sourceInfos);
|
|
1115
|
+
this.chatContainer.addChild(new Text(`${theme.fg("warning", "[Extension issues]")}\n${warningLines}`, 0, 0));
|
|
1116
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
1117
|
+
}
|
|
1118
|
+
const themeDiagnostics = themesResult.diagnostics;
|
|
1119
|
+
if (themeDiagnostics.length > 0) {
|
|
1120
|
+
const warningLines = this.formatDiagnostics(themeDiagnostics, sourceInfos);
|
|
1121
|
+
this.chatContainer.addChild(new Text(`${theme.fg("warning", "[Theme conflicts]")}\n${warningLines}`, 0, 0));
|
|
1122
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
1123
|
+
}
|
|
1124
|
+
}
|
|
1125
|
+
}
|
|
1126
|
+
/**
|
|
1127
|
+
* Initialize the extension system with TUI-based UI context.
|
|
1128
|
+
*/
|
|
1129
|
+
async bindCurrentSessionExtensions() {
|
|
1130
|
+
const uiContext = this.createExtensionUIContext();
|
|
1131
|
+
await this.session.bindExtensions({
|
|
1132
|
+
uiContext,
|
|
1133
|
+
commandContextActions: {
|
|
1134
|
+
waitForIdle: () => this.session.agent.waitForIdle(),
|
|
1135
|
+
newSession: async (options) => {
|
|
1136
|
+
if (this.loadingAnimation) {
|
|
1137
|
+
this.loadingAnimation.stop();
|
|
1138
|
+
this.loadingAnimation = undefined;
|
|
1139
|
+
}
|
|
1140
|
+
this.statusContainer.clear();
|
|
1141
|
+
try {
|
|
1142
|
+
const result = await this.runtimeHost.newSession(options);
|
|
1143
|
+
if (!result.cancelled) {
|
|
1144
|
+
this.renderCurrentSessionState();
|
|
1145
|
+
this.ui.requestRender();
|
|
1146
|
+
}
|
|
1147
|
+
return result;
|
|
1148
|
+
}
|
|
1149
|
+
catch (error) {
|
|
1150
|
+
return this.handleFatalRuntimeError("Failed to create session", error);
|
|
1151
|
+
}
|
|
1152
|
+
},
|
|
1153
|
+
fork: async (entryId, options) => {
|
|
1154
|
+
try {
|
|
1155
|
+
const result = await this.runtimeHost.fork(entryId, options);
|
|
1156
|
+
if (!result.cancelled) {
|
|
1157
|
+
this.renderCurrentSessionState();
|
|
1158
|
+
this.editor.setText(result.selectedText ?? "");
|
|
1159
|
+
this.showStatus("Forked to new session");
|
|
1160
|
+
}
|
|
1161
|
+
return { cancelled: result.cancelled };
|
|
1162
|
+
}
|
|
1163
|
+
catch (error) {
|
|
1164
|
+
return this.handleFatalRuntimeError("Failed to fork session", error);
|
|
1165
|
+
}
|
|
1166
|
+
},
|
|
1167
|
+
navigateTree: async (targetId, options) => {
|
|
1168
|
+
const result = await this.session.navigateTree(targetId, {
|
|
1169
|
+
summarize: options?.summarize,
|
|
1170
|
+
customInstructions: options?.customInstructions,
|
|
1171
|
+
replaceInstructions: options?.replaceInstructions,
|
|
1172
|
+
label: options?.label,
|
|
1173
|
+
});
|
|
1174
|
+
if (result.cancelled) {
|
|
1175
|
+
return { cancelled: true };
|
|
1176
|
+
}
|
|
1177
|
+
this.chatContainer.clear();
|
|
1178
|
+
this.renderInitialMessages();
|
|
1179
|
+
if (result.editorText && !this.editor.getText().trim()) {
|
|
1180
|
+
this.editor.setText(result.editorText);
|
|
1181
|
+
}
|
|
1182
|
+
this.showStatus("Navigated to selected point");
|
|
1183
|
+
void this.flushCompactionQueue({ willRetry: false });
|
|
1184
|
+
return { cancelled: false };
|
|
1185
|
+
},
|
|
1186
|
+
switchSession: async (sessionPath, options) => {
|
|
1187
|
+
return this.handleResumeSession(sessionPath, options);
|
|
1188
|
+
},
|
|
1189
|
+
reload: async () => {
|
|
1190
|
+
await this.handleReloadCommand();
|
|
1191
|
+
},
|
|
1192
|
+
},
|
|
1193
|
+
shutdownHandler: () => {
|
|
1194
|
+
this.shutdownRequested = true;
|
|
1195
|
+
if (!this.session.isStreaming) {
|
|
1196
|
+
void this.shutdown();
|
|
1197
|
+
}
|
|
1198
|
+
},
|
|
1199
|
+
onError: (error) => {
|
|
1200
|
+
this.showExtensionError(error.extensionPath, error.error, error.stack);
|
|
1201
|
+
},
|
|
1202
|
+
});
|
|
1203
|
+
setRegisteredThemes(this.session.resourceLoader.getThemes().themes);
|
|
1204
|
+
this.setupAutocompleteProvider();
|
|
1205
|
+
const extensionRunner = this.session.extensionRunner;
|
|
1206
|
+
this.setupExtensionShortcuts(extensionRunner);
|
|
1207
|
+
this.showLoadedResources({ force: false, showDiagnosticsWhenQuiet: true });
|
|
1208
|
+
this.showStartupNoticesIfNeeded();
|
|
1209
|
+
}
|
|
1210
|
+
applyRuntimeSettings() {
|
|
1211
|
+
this.footer.setSession(this.session);
|
|
1212
|
+
this.footer.setAutoCompactEnabled(this.session.autoCompactionEnabled);
|
|
1213
|
+
this.footerDataProvider.setCwd(this.sessionManager.getCwd());
|
|
1214
|
+
this.hideThinkingBlock = this.settingsManager.getHideThinkingBlock();
|
|
1215
|
+
this.ui.setShowHardwareCursor(this.settingsManager.getShowHardwareCursor());
|
|
1216
|
+
this.ui.setClearOnShrink(this.settingsManager.getClearOnShrink());
|
|
1217
|
+
const editorPaddingX = this.settingsManager.getEditorPaddingX();
|
|
1218
|
+
const autocompleteMaxVisible = this.settingsManager.getAutocompleteMaxVisible();
|
|
1219
|
+
this.defaultEditor.setPaddingX(editorPaddingX);
|
|
1220
|
+
this.defaultEditor.setAutocompleteMaxVisible(autocompleteMaxVisible);
|
|
1221
|
+
if (this.editor !== this.defaultEditor) {
|
|
1222
|
+
this.editor.setPaddingX?.(editorPaddingX);
|
|
1223
|
+
this.editor.setAutocompleteMaxVisible?.(autocompleteMaxVisible);
|
|
1224
|
+
}
|
|
1225
|
+
}
|
|
1226
|
+
async rebindCurrentSession() {
|
|
1227
|
+
this.unsubscribe?.();
|
|
1228
|
+
this.unsubscribe = undefined;
|
|
1229
|
+
this.applyRuntimeSettings();
|
|
1230
|
+
await this.bindCurrentSessionExtensions();
|
|
1231
|
+
this.subscribeToAgent();
|
|
1232
|
+
await this.updateAvailableProviderCount();
|
|
1233
|
+
this.updateEditorBorderColor();
|
|
1234
|
+
this.updateTerminalTitle();
|
|
1235
|
+
}
|
|
1236
|
+
async handleFatalRuntimeError(prefix, error) {
|
|
1237
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
1238
|
+
this.showError(`${prefix}: ${message}`);
|
|
1239
|
+
stopThemeWatcher();
|
|
1240
|
+
this.stop();
|
|
1241
|
+
process.exit(1);
|
|
1242
|
+
}
|
|
1243
|
+
renderCurrentSessionState() {
|
|
1244
|
+
this.chatContainer.clear();
|
|
1245
|
+
this.pendingMessagesContainer.clear();
|
|
1246
|
+
this.compactionQueuedMessages = [];
|
|
1247
|
+
this.streamingComponent = undefined;
|
|
1248
|
+
this.streamingMessage = undefined;
|
|
1249
|
+
this.pendingTools.clear();
|
|
1250
|
+
this.renderInitialMessages();
|
|
1251
|
+
}
|
|
1252
|
+
/**
|
|
1253
|
+
* Get a registered tool definition by name (for custom rendering).
|
|
1254
|
+
*/
|
|
1255
|
+
getRegisteredToolDefinition(toolName) {
|
|
1256
|
+
return this.session.getToolDefinition(toolName);
|
|
1257
|
+
}
|
|
1258
|
+
/**
|
|
1259
|
+
* Set up keyboard shortcuts registered by extensions.
|
|
1260
|
+
*/
|
|
1261
|
+
setupExtensionShortcuts(extensionRunner) {
|
|
1262
|
+
const shortcuts = extensionRunner.getShortcuts(this.keybindings.getEffectiveConfig());
|
|
1263
|
+
if (shortcuts.size === 0)
|
|
1264
|
+
return;
|
|
1265
|
+
// Create a context for shortcut handlers
|
|
1266
|
+
const createContext = () => ({
|
|
1267
|
+
ui: this.createExtensionUIContext(),
|
|
1268
|
+
hasUI: true,
|
|
1269
|
+
cwd: this.sessionManager.getCwd(),
|
|
1270
|
+
sessionManager: this.sessionManager,
|
|
1271
|
+
modelRegistry: this.session.modelRegistry,
|
|
1272
|
+
model: this.session.model,
|
|
1273
|
+
isIdle: () => !this.session.isStreaming,
|
|
1274
|
+
signal: this.session.agent.signal,
|
|
1275
|
+
abort: () => this.session.abort(),
|
|
1276
|
+
hasPendingMessages: () => this.session.pendingMessageCount > 0,
|
|
1277
|
+
shutdown: () => {
|
|
1278
|
+
this.shutdownRequested = true;
|
|
1279
|
+
},
|
|
1280
|
+
getContextUsage: () => this.session.getContextUsage(),
|
|
1281
|
+
compact: (options) => {
|
|
1282
|
+
void (async () => {
|
|
1283
|
+
try {
|
|
1284
|
+
const result = await this.session.compact(options?.customInstructions);
|
|
1285
|
+
options?.onComplete?.(result);
|
|
1286
|
+
}
|
|
1287
|
+
catch (error) {
|
|
1288
|
+
const err = error instanceof Error ? error : new Error(String(error));
|
|
1289
|
+
options?.onError?.(err);
|
|
1290
|
+
}
|
|
1291
|
+
})();
|
|
1292
|
+
},
|
|
1293
|
+
getSystemPrompt: () => this.session.systemPrompt,
|
|
1294
|
+
});
|
|
1295
|
+
// Set up the extension shortcut handler on the default editor
|
|
1296
|
+
this.defaultEditor.onExtensionShortcut = (data) => {
|
|
1297
|
+
for (const [shortcutStr, shortcut] of shortcuts) {
|
|
1298
|
+
// Cast to KeyId - extension shortcuts use the same format
|
|
1299
|
+
if (matchesKey(data, shortcutStr)) {
|
|
1300
|
+
// Run handler async, don't block input
|
|
1301
|
+
Promise.resolve(shortcut.handler(createContext())).catch((err) => {
|
|
1302
|
+
this.showError(`Shortcut handler error: ${err instanceof Error ? err.message : String(err)}`);
|
|
1303
|
+
});
|
|
1304
|
+
return true;
|
|
1305
|
+
}
|
|
1306
|
+
}
|
|
1307
|
+
return false;
|
|
1308
|
+
};
|
|
1309
|
+
}
|
|
1310
|
+
/**
|
|
1311
|
+
* Set extension status text in the footer.
|
|
1312
|
+
*/
|
|
1313
|
+
setExtensionStatus(key, text) {
|
|
1314
|
+
this.footerDataProvider.setExtensionStatus(key, text);
|
|
1315
|
+
this.ui.requestRender();
|
|
1316
|
+
}
|
|
1317
|
+
getWorkingLoaderMessage() {
|
|
1318
|
+
return this.workingMessage ?? this.defaultWorkingMessage;
|
|
1319
|
+
}
|
|
1320
|
+
createWorkingLoader() {
|
|
1321
|
+
return new Loader(this.ui, (spinner) => theme.fg("accent", spinner), (text) => theme.fg("muted", text), this.getWorkingLoaderMessage(), this.workingIndicatorOptions);
|
|
1322
|
+
}
|
|
1323
|
+
stopWorkingLoader() {
|
|
1324
|
+
if (this.loadingAnimation) {
|
|
1325
|
+
this.loadingAnimation.stop();
|
|
1326
|
+
this.loadingAnimation = undefined;
|
|
1327
|
+
}
|
|
1328
|
+
this.statusContainer.clear();
|
|
1329
|
+
}
|
|
1330
|
+
setWorkingVisible(visible) {
|
|
1331
|
+
this.workingVisible = visible;
|
|
1332
|
+
if (!visible) {
|
|
1333
|
+
this.stopWorkingLoader();
|
|
1334
|
+
this.ui.requestRender();
|
|
1335
|
+
return;
|
|
1336
|
+
}
|
|
1337
|
+
if (this.session.isStreaming && !this.loadingAnimation) {
|
|
1338
|
+
this.statusContainer.clear();
|
|
1339
|
+
this.loadingAnimation = this.createWorkingLoader();
|
|
1340
|
+
this.statusContainer.addChild(this.loadingAnimation);
|
|
1341
|
+
}
|
|
1342
|
+
this.ui.requestRender();
|
|
1343
|
+
}
|
|
1344
|
+
setWorkingIndicator(options) {
|
|
1345
|
+
this.workingIndicatorOptions = options;
|
|
1346
|
+
this.loadingAnimation?.setIndicator(options);
|
|
1347
|
+
this.ui.requestRender();
|
|
1348
|
+
}
|
|
1349
|
+
setHiddenThinkingLabel(label) {
|
|
1350
|
+
this.hiddenThinkingLabel = label ?? this.defaultHiddenThinkingLabel;
|
|
1351
|
+
for (const child of this.chatContainer.children) {
|
|
1352
|
+
if (child instanceof AssistantMessageComponent) {
|
|
1353
|
+
child.setHiddenThinkingLabel(this.hiddenThinkingLabel);
|
|
1354
|
+
}
|
|
1355
|
+
}
|
|
1356
|
+
if (this.streamingComponent) {
|
|
1357
|
+
this.streamingComponent.setHiddenThinkingLabel(this.hiddenThinkingLabel);
|
|
1358
|
+
}
|
|
1359
|
+
this.ui.requestRender();
|
|
1360
|
+
}
|
|
1361
|
+
/**
|
|
1362
|
+
* Set an extension widget (string array or custom component).
|
|
1363
|
+
*/
|
|
1364
|
+
setExtensionWidget(key, content, options) {
|
|
1365
|
+
const placement = options?.placement ?? "aboveEditor";
|
|
1366
|
+
const removeExisting = (map) => {
|
|
1367
|
+
const existing = map.get(key);
|
|
1368
|
+
if (existing?.dispose)
|
|
1369
|
+
existing.dispose();
|
|
1370
|
+
map.delete(key);
|
|
1371
|
+
};
|
|
1372
|
+
removeExisting(this.extensionWidgetsAbove);
|
|
1373
|
+
removeExisting(this.extensionWidgetsBelow);
|
|
1374
|
+
if (content === undefined) {
|
|
1375
|
+
this.renderWidgets();
|
|
1376
|
+
return;
|
|
1377
|
+
}
|
|
1378
|
+
let component;
|
|
1379
|
+
if (Array.isArray(content)) {
|
|
1380
|
+
// Wrap string array in a Container with Text components
|
|
1381
|
+
const container = new Container();
|
|
1382
|
+
for (const line of content.slice(0, InteractiveMode.MAX_WIDGET_LINES)) {
|
|
1383
|
+
container.addChild(new Text(line, 1, 0));
|
|
1384
|
+
}
|
|
1385
|
+
if (content.length > InteractiveMode.MAX_WIDGET_LINES) {
|
|
1386
|
+
container.addChild(new Text(theme.fg("muted", "... (widget truncated)"), 1, 0));
|
|
1387
|
+
}
|
|
1388
|
+
component = container;
|
|
1389
|
+
}
|
|
1390
|
+
else {
|
|
1391
|
+
// Factory function - create component
|
|
1392
|
+
component = content(this.ui, theme);
|
|
1393
|
+
}
|
|
1394
|
+
const targetMap = placement === "belowEditor" ? this.extensionWidgetsBelow : this.extensionWidgetsAbove;
|
|
1395
|
+
targetMap.set(key, component);
|
|
1396
|
+
this.renderWidgets();
|
|
1397
|
+
}
|
|
1398
|
+
clearExtensionWidgets() {
|
|
1399
|
+
for (const widget of this.extensionWidgetsAbove.values()) {
|
|
1400
|
+
widget.dispose?.();
|
|
1401
|
+
}
|
|
1402
|
+
for (const widget of this.extensionWidgetsBelow.values()) {
|
|
1403
|
+
widget.dispose?.();
|
|
1404
|
+
}
|
|
1405
|
+
this.extensionWidgetsAbove.clear();
|
|
1406
|
+
this.extensionWidgetsBelow.clear();
|
|
1407
|
+
this.renderWidgets();
|
|
1408
|
+
}
|
|
1409
|
+
resetExtensionUI() {
|
|
1410
|
+
if (this.extensionSelector) {
|
|
1411
|
+
this.hideExtensionSelector();
|
|
1412
|
+
}
|
|
1413
|
+
if (this.extensionInput) {
|
|
1414
|
+
this.hideExtensionInput();
|
|
1415
|
+
}
|
|
1416
|
+
if (this.extensionEditor) {
|
|
1417
|
+
this.hideExtensionEditor();
|
|
1418
|
+
}
|
|
1419
|
+
this.ui.hideOverlay();
|
|
1420
|
+
this.clearExtensionTerminalInputListeners();
|
|
1421
|
+
this.setExtensionFooter(undefined);
|
|
1422
|
+
this.setExtensionHeader(undefined);
|
|
1423
|
+
this.clearExtensionWidgets();
|
|
1424
|
+
this.footerDataProvider.clearExtensionStatuses();
|
|
1425
|
+
this.footer.invalidate();
|
|
1426
|
+
this.autocompleteProviderWrappers = [];
|
|
1427
|
+
this.setCustomEditorComponent(undefined);
|
|
1428
|
+
this.setupAutocompleteProvider();
|
|
1429
|
+
this.defaultEditor.onExtensionShortcut = undefined;
|
|
1430
|
+
this.updateTerminalTitle();
|
|
1431
|
+
this.workingMessage = undefined;
|
|
1432
|
+
this.workingVisible = true;
|
|
1433
|
+
this.setWorkingIndicator();
|
|
1434
|
+
if (this.loadingAnimation) {
|
|
1435
|
+
this.loadingAnimation.setMessage(`${this.defaultWorkingMessage} (${keyText("app.interrupt")} to interrupt)`);
|
|
1436
|
+
}
|
|
1437
|
+
this.setHiddenThinkingLabel();
|
|
1438
|
+
}
|
|
1439
|
+
// Maximum total widget lines to prevent viewport overflow
|
|
1440
|
+
static MAX_WIDGET_LINES = 10;
|
|
1441
|
+
/**
|
|
1442
|
+
* Render all extension widgets to the widget container.
|
|
1443
|
+
*/
|
|
1444
|
+
renderWidgets() {
|
|
1445
|
+
if (!this.widgetContainerAbove || !this.widgetContainerBelow)
|
|
1446
|
+
return;
|
|
1447
|
+
this.renderWidgetContainer(this.widgetContainerAbove, this.extensionWidgetsAbove, true, true);
|
|
1448
|
+
this.renderWidgetContainer(this.widgetContainerBelow, this.extensionWidgetsBelow, false, false);
|
|
1449
|
+
this.ui.requestRender();
|
|
1450
|
+
}
|
|
1451
|
+
renderWidgetContainer(container, widgets, spacerWhenEmpty, leadingSpacer) {
|
|
1452
|
+
container.clear();
|
|
1453
|
+
if (widgets.size === 0) {
|
|
1454
|
+
if (spacerWhenEmpty) {
|
|
1455
|
+
container.addChild(new Spacer(1));
|
|
1456
|
+
}
|
|
1457
|
+
return;
|
|
1458
|
+
}
|
|
1459
|
+
if (leadingSpacer) {
|
|
1460
|
+
container.addChild(new Spacer(1));
|
|
1461
|
+
}
|
|
1462
|
+
for (const component of widgets.values()) {
|
|
1463
|
+
container.addChild(component);
|
|
1464
|
+
}
|
|
1465
|
+
}
|
|
1466
|
+
/**
|
|
1467
|
+
* Set a custom footer component, or restore the built-in footer.
|
|
1468
|
+
*/
|
|
1469
|
+
setExtensionFooter(factory) {
|
|
1470
|
+
// Dispose existing custom footer
|
|
1471
|
+
if (this.customFooter?.dispose) {
|
|
1472
|
+
this.customFooter.dispose();
|
|
1473
|
+
}
|
|
1474
|
+
// Remove current footer from UI
|
|
1475
|
+
if (this.customFooter) {
|
|
1476
|
+
this.ui.removeChild(this.customFooter);
|
|
1477
|
+
}
|
|
1478
|
+
else {
|
|
1479
|
+
this.ui.removeChild(this.footer);
|
|
1480
|
+
}
|
|
1481
|
+
if (factory) {
|
|
1482
|
+
// Create and add custom footer, passing the data provider
|
|
1483
|
+
this.customFooter = factory(this.ui, theme, this.footerDataProvider);
|
|
1484
|
+
this.ui.addChild(this.customFooter);
|
|
1485
|
+
}
|
|
1486
|
+
else {
|
|
1487
|
+
// Restore built-in footer
|
|
1488
|
+
this.customFooter = undefined;
|
|
1489
|
+
this.ui.addChild(this.footer);
|
|
1490
|
+
}
|
|
1491
|
+
this.ui.requestRender();
|
|
1492
|
+
}
|
|
1493
|
+
/**
|
|
1494
|
+
* Implements ctx.ui.setOutputSource — swap the chat viewport's rendering source.
|
|
1495
|
+
*
|
|
1496
|
+
* Passing a Component delegates the chat viewport's render() to it; the
|
|
1497
|
+
* original message-history children are preserved. Passing null restores
|
|
1498
|
+
* the default child-rendering behaviour.
|
|
1499
|
+
*
|
|
1500
|
+
* Extensions that own a tail buffer (e.g. forge-cli's thread-switcher
|
|
1501
|
+
* targeting a subagent log) supply a Component that yields lines from
|
|
1502
|
+
* that buffer; the user sees that content in the main viewport until the
|
|
1503
|
+
* extension calls setOutputSource(null).
|
|
1504
|
+
*/
|
|
1505
|
+
setChatOutputSource(component) {
|
|
1506
|
+
this.chatContainer.sourceOverride = component;
|
|
1507
|
+
this.chatContainer.invalidate();
|
|
1508
|
+
this.ui.requestRender();
|
|
1509
|
+
}
|
|
1510
|
+
/**
|
|
1511
|
+
* Set a custom header component, or restore the built-in header.
|
|
1512
|
+
*/
|
|
1513
|
+
setExtensionHeader(factory) {
|
|
1514
|
+
// Header may not be initialized yet if called during early initialization
|
|
1515
|
+
if (!this.builtInHeader) {
|
|
1516
|
+
return;
|
|
1517
|
+
}
|
|
1518
|
+
// Dispose existing custom header
|
|
1519
|
+
if (this.customHeader?.dispose) {
|
|
1520
|
+
this.customHeader.dispose();
|
|
1521
|
+
}
|
|
1522
|
+
// Find the index of the current header in the header container
|
|
1523
|
+
const currentHeader = this.customHeader || this.builtInHeader;
|
|
1524
|
+
const index = this.headerContainer.children.indexOf(currentHeader);
|
|
1525
|
+
if (factory) {
|
|
1526
|
+
// Create and add custom header
|
|
1527
|
+
this.customHeader = factory(this.ui, theme);
|
|
1528
|
+
if (isExpandable(this.customHeader)) {
|
|
1529
|
+
this.customHeader.setExpanded(this.toolOutputExpanded);
|
|
1530
|
+
}
|
|
1531
|
+
if (index !== -1) {
|
|
1532
|
+
this.headerContainer.children[index] = this.customHeader;
|
|
1533
|
+
}
|
|
1534
|
+
else {
|
|
1535
|
+
// If not found (e.g. builtInHeader was never added), add at the top
|
|
1536
|
+
this.headerContainer.children.unshift(this.customHeader);
|
|
1537
|
+
}
|
|
1538
|
+
}
|
|
1539
|
+
else {
|
|
1540
|
+
// Restore built-in header
|
|
1541
|
+
this.customHeader = undefined;
|
|
1542
|
+
if (isExpandable(this.builtInHeader)) {
|
|
1543
|
+
this.builtInHeader.setExpanded(this.toolOutputExpanded);
|
|
1544
|
+
}
|
|
1545
|
+
if (index !== -1) {
|
|
1546
|
+
this.headerContainer.children[index] = this.builtInHeader;
|
|
1547
|
+
}
|
|
1548
|
+
}
|
|
1549
|
+
this.ui.requestRender();
|
|
1550
|
+
}
|
|
1551
|
+
addExtensionTerminalInputListener(handler) {
|
|
1552
|
+
const unsubscribe = this.ui.addInputListener(handler);
|
|
1553
|
+
this.extensionTerminalInputUnsubscribers.add(unsubscribe);
|
|
1554
|
+
return () => {
|
|
1555
|
+
unsubscribe();
|
|
1556
|
+
this.extensionTerminalInputUnsubscribers.delete(unsubscribe);
|
|
1557
|
+
};
|
|
1558
|
+
}
|
|
1559
|
+
clearExtensionTerminalInputListeners() {
|
|
1560
|
+
for (const unsubscribe of this.extensionTerminalInputUnsubscribers) {
|
|
1561
|
+
unsubscribe();
|
|
1562
|
+
}
|
|
1563
|
+
this.extensionTerminalInputUnsubscribers.clear();
|
|
1564
|
+
}
|
|
1565
|
+
/**
|
|
1566
|
+
* Create the ExtensionUIContext for extensions.
|
|
1567
|
+
*/
|
|
1568
|
+
createExtensionUIContext() {
|
|
1569
|
+
return {
|
|
1570
|
+
select: (title, options, opts) => this.showExtensionSelector(title, options, opts),
|
|
1571
|
+
confirm: (title, message, opts) => this.showExtensionConfirm(title, message, opts),
|
|
1572
|
+
input: (title, placeholder, opts) => this.showExtensionInput(title, placeholder, opts),
|
|
1573
|
+
notify: (message, type) => this.showExtensionNotify(message, type),
|
|
1574
|
+
onTerminalInput: (handler) => this.addExtensionTerminalInputListener(handler),
|
|
1575
|
+
setStatus: (key, text) => this.setExtensionStatus(key, text),
|
|
1576
|
+
setWorkingMessage: (message) => {
|
|
1577
|
+
this.workingMessage = message;
|
|
1578
|
+
if (this.loadingAnimation) {
|
|
1579
|
+
this.loadingAnimation.setMessage(message ?? this.defaultWorkingMessage);
|
|
1580
|
+
}
|
|
1581
|
+
},
|
|
1582
|
+
setWorkingVisible: (visible) => this.setWorkingVisible(visible),
|
|
1583
|
+
setWorkingIndicator: (options) => this.setWorkingIndicator(options),
|
|
1584
|
+
setHiddenThinkingLabel: (label) => this.setHiddenThinkingLabel(label),
|
|
1585
|
+
setWidget: (key, content, options) => this.setExtensionWidget(key, content, options),
|
|
1586
|
+
setFooter: (factory) => this.setExtensionFooter(factory),
|
|
1587
|
+
setHeader: (factory) => this.setExtensionHeader(factory),
|
|
1588
|
+
setTitle: (title) => this.ui.terminal.setTitle(title),
|
|
1589
|
+
setOutputSource: (component) => this.setChatOutputSource(component),
|
|
1590
|
+
custom: (factory, options) => this.showExtensionCustom(factory, options),
|
|
1591
|
+
pasteToEditor: (text) => this.editor.handleInput(`\x1b[200~${text}\x1b[201~`),
|
|
1592
|
+
setEditorText: (text) => this.editor.setText(text),
|
|
1593
|
+
getEditorText: () => this.editor.getExpandedText?.() ?? this.editor.getText(),
|
|
1594
|
+
editor: (title, prefill) => this.showExtensionEditor(title, prefill),
|
|
1595
|
+
addAutocompleteProvider: (factory) => {
|
|
1596
|
+
this.autocompleteProviderWrappers.push(factory);
|
|
1597
|
+
this.setupAutocompleteProvider();
|
|
1598
|
+
},
|
|
1599
|
+
setEditorComponent: (factory) => this.setCustomEditorComponent(factory),
|
|
1600
|
+
getEditorComponent: () => this.editorComponentFactory,
|
|
1601
|
+
get theme() {
|
|
1602
|
+
return theme;
|
|
1603
|
+
},
|
|
1604
|
+
getAllThemes: () => getAvailableThemesWithPaths(),
|
|
1605
|
+
getTheme: (name) => getThemeByName(name),
|
|
1606
|
+
setTheme: (themeOrName) => {
|
|
1607
|
+
if (themeOrName instanceof Theme) {
|
|
1608
|
+
setThemeInstance(themeOrName);
|
|
1609
|
+
this.ui.requestRender();
|
|
1610
|
+
return { success: true };
|
|
1611
|
+
}
|
|
1612
|
+
const result = setTheme(themeOrName, true);
|
|
1613
|
+
if (result.success) {
|
|
1614
|
+
if (this.settingsManager.getTheme() !== themeOrName) {
|
|
1615
|
+
this.settingsManager.setTheme(themeOrName);
|
|
1616
|
+
}
|
|
1617
|
+
this.ui.requestRender();
|
|
1618
|
+
}
|
|
1619
|
+
return result;
|
|
1620
|
+
},
|
|
1621
|
+
getToolsExpanded: () => this.toolOutputExpanded,
|
|
1622
|
+
setToolsExpanded: (expanded) => this.setToolsExpanded(expanded),
|
|
1623
|
+
};
|
|
1624
|
+
}
|
|
1625
|
+
/**
|
|
1626
|
+
* Show a selector for extensions.
|
|
1627
|
+
*/
|
|
1628
|
+
showExtensionSelector(title, options, opts) {
|
|
1629
|
+
return new Promise((resolve) => {
|
|
1630
|
+
if (opts?.signal?.aborted) {
|
|
1631
|
+
resolve(undefined);
|
|
1632
|
+
return;
|
|
1633
|
+
}
|
|
1634
|
+
const onAbort = () => {
|
|
1635
|
+
this.hideExtensionSelector();
|
|
1636
|
+
resolve(undefined);
|
|
1637
|
+
};
|
|
1638
|
+
opts?.signal?.addEventListener("abort", onAbort, { once: true });
|
|
1639
|
+
this.extensionSelector = new ExtensionSelectorComponent(title, options, (option) => {
|
|
1640
|
+
opts?.signal?.removeEventListener("abort", onAbort);
|
|
1641
|
+
this.hideExtensionSelector();
|
|
1642
|
+
resolve(option);
|
|
1643
|
+
}, () => {
|
|
1644
|
+
opts?.signal?.removeEventListener("abort", onAbort);
|
|
1645
|
+
this.hideExtensionSelector();
|
|
1646
|
+
resolve(undefined);
|
|
1647
|
+
}, { tui: this.ui, timeout: opts?.timeout, onToggleToolsExpanded: () => this.toggleToolOutputExpansion() });
|
|
1648
|
+
this.editorContainer.clear();
|
|
1649
|
+
this.editorContainer.addChild(this.extensionSelector);
|
|
1650
|
+
this.ui.setFocus(this.extensionSelector);
|
|
1651
|
+
this.ui.requestRender();
|
|
1652
|
+
});
|
|
1653
|
+
}
|
|
1654
|
+
/**
|
|
1655
|
+
* Hide the extension selector.
|
|
1656
|
+
*/
|
|
1657
|
+
hideExtensionSelector() {
|
|
1658
|
+
this.extensionSelector?.dispose();
|
|
1659
|
+
this.editorContainer.clear();
|
|
1660
|
+
this.editorContainer.addChild(this.editor);
|
|
1661
|
+
this.extensionSelector = undefined;
|
|
1662
|
+
this.ui.setFocus(this.editor);
|
|
1663
|
+
this.ui.requestRender();
|
|
1664
|
+
}
|
|
1665
|
+
/**
|
|
1666
|
+
* Show a confirmation dialog for extensions.
|
|
1667
|
+
*/
|
|
1668
|
+
async showExtensionConfirm(title, message, opts) {
|
|
1669
|
+
const result = await this.showExtensionSelector(`${title}\n${message}`, ["Yes", "No"], opts);
|
|
1670
|
+
return result === "Yes";
|
|
1671
|
+
}
|
|
1672
|
+
async promptForMissingSessionCwd(error) {
|
|
1673
|
+
const confirmed = await this.showExtensionConfirm("Session cwd not found", formatMissingSessionCwdPrompt(error.issue));
|
|
1674
|
+
return confirmed ? error.issue.fallbackCwd : undefined;
|
|
1675
|
+
}
|
|
1676
|
+
/**
|
|
1677
|
+
* Show a text input for extensions.
|
|
1678
|
+
*/
|
|
1679
|
+
showExtensionInput(title, placeholder, opts) {
|
|
1680
|
+
return new Promise((resolve) => {
|
|
1681
|
+
if (opts?.signal?.aborted) {
|
|
1682
|
+
resolve(undefined);
|
|
1683
|
+
return;
|
|
1684
|
+
}
|
|
1685
|
+
const onAbort = () => {
|
|
1686
|
+
this.hideExtensionInput();
|
|
1687
|
+
resolve(undefined);
|
|
1688
|
+
};
|
|
1689
|
+
opts?.signal?.addEventListener("abort", onAbort, { once: true });
|
|
1690
|
+
this.extensionInput = new ExtensionInputComponent(title, placeholder, (value) => {
|
|
1691
|
+
opts?.signal?.removeEventListener("abort", onAbort);
|
|
1692
|
+
this.hideExtensionInput();
|
|
1693
|
+
resolve(value);
|
|
1694
|
+
}, () => {
|
|
1695
|
+
opts?.signal?.removeEventListener("abort", onAbort);
|
|
1696
|
+
this.hideExtensionInput();
|
|
1697
|
+
resolve(undefined);
|
|
1698
|
+
}, { tui: this.ui, timeout: opts?.timeout });
|
|
1699
|
+
this.editorContainer.clear();
|
|
1700
|
+
this.editorContainer.addChild(this.extensionInput);
|
|
1701
|
+
this.ui.setFocus(this.extensionInput);
|
|
1702
|
+
this.ui.requestRender();
|
|
1703
|
+
});
|
|
1704
|
+
}
|
|
1705
|
+
/**
|
|
1706
|
+
* Hide the extension input.
|
|
1707
|
+
*/
|
|
1708
|
+
hideExtensionInput() {
|
|
1709
|
+
this.extensionInput?.dispose();
|
|
1710
|
+
this.editorContainer.clear();
|
|
1711
|
+
this.editorContainer.addChild(this.editor);
|
|
1712
|
+
this.extensionInput = undefined;
|
|
1713
|
+
this.ui.setFocus(this.editor);
|
|
1714
|
+
this.ui.requestRender();
|
|
1715
|
+
}
|
|
1716
|
+
/**
|
|
1717
|
+
* Show a multi-line editor for extensions (with Ctrl+G support).
|
|
1718
|
+
*/
|
|
1719
|
+
showExtensionEditor(title, prefill) {
|
|
1720
|
+
return new Promise((resolve) => {
|
|
1721
|
+
this.extensionEditor = new ExtensionEditorComponent(this.ui, this.keybindings, title, prefill, (value) => {
|
|
1722
|
+
this.hideExtensionEditor();
|
|
1723
|
+
resolve(value);
|
|
1724
|
+
}, () => {
|
|
1725
|
+
this.hideExtensionEditor();
|
|
1726
|
+
resolve(undefined);
|
|
1727
|
+
});
|
|
1728
|
+
this.editorContainer.clear();
|
|
1729
|
+
this.editorContainer.addChild(this.extensionEditor);
|
|
1730
|
+
this.ui.setFocus(this.extensionEditor);
|
|
1731
|
+
this.ui.requestRender();
|
|
1732
|
+
});
|
|
1733
|
+
}
|
|
1734
|
+
/**
|
|
1735
|
+
* Hide the extension editor.
|
|
1736
|
+
*/
|
|
1737
|
+
hideExtensionEditor() {
|
|
1738
|
+
this.editorContainer.clear();
|
|
1739
|
+
this.editorContainer.addChild(this.editor);
|
|
1740
|
+
this.extensionEditor = undefined;
|
|
1741
|
+
this.ui.setFocus(this.editor);
|
|
1742
|
+
this.ui.requestRender();
|
|
1743
|
+
}
|
|
1744
|
+
/**
|
|
1745
|
+
* Set a custom editor component from an extension.
|
|
1746
|
+
* Pass undefined to restore the default editor.
|
|
1747
|
+
*/
|
|
1748
|
+
setCustomEditorComponent(factory) {
|
|
1749
|
+
this.editorComponentFactory = factory;
|
|
1750
|
+
// Save text from current editor before switching
|
|
1751
|
+
const currentText = this.editor.getText();
|
|
1752
|
+
this.editorContainer.clear();
|
|
1753
|
+
if (factory) {
|
|
1754
|
+
// Create the custom editor with tui, theme, and keybindings
|
|
1755
|
+
const newEditor = factory(this.ui, getEditorTheme(), this.keybindings);
|
|
1756
|
+
// Wire up callbacks from the default editor
|
|
1757
|
+
newEditor.onSubmit = this.defaultEditor.onSubmit;
|
|
1758
|
+
newEditor.onChange = this.defaultEditor.onChange;
|
|
1759
|
+
// Copy text from previous editor
|
|
1760
|
+
newEditor.setText(currentText);
|
|
1761
|
+
// Copy appearance settings if supported
|
|
1762
|
+
if (newEditor.borderColor !== undefined) {
|
|
1763
|
+
newEditor.borderColor = this.defaultEditor.borderColor;
|
|
1764
|
+
}
|
|
1765
|
+
if (newEditor.setPaddingX !== undefined) {
|
|
1766
|
+
newEditor.setPaddingX(this.defaultEditor.getPaddingX());
|
|
1767
|
+
}
|
|
1768
|
+
// Set autocomplete if supported
|
|
1769
|
+
if (newEditor.setAutocompleteProvider && this.autocompleteProvider) {
|
|
1770
|
+
newEditor.setAutocompleteProvider(this.autocompleteProvider);
|
|
1771
|
+
}
|
|
1772
|
+
// If extending CustomEditor, copy app-level handlers
|
|
1773
|
+
// Use duck typing since instanceof fails across jiti module boundaries
|
|
1774
|
+
const customEditor = newEditor;
|
|
1775
|
+
if ("actionHandlers" in customEditor && customEditor.actionHandlers instanceof Map) {
|
|
1776
|
+
if (!customEditor.onEscape) {
|
|
1777
|
+
customEditor.onEscape = () => this.defaultEditor.onEscape?.();
|
|
1778
|
+
}
|
|
1779
|
+
if (!customEditor.onCtrlD) {
|
|
1780
|
+
customEditor.onCtrlD = () => this.defaultEditor.onCtrlD?.();
|
|
1781
|
+
}
|
|
1782
|
+
if (!customEditor.onPasteImage) {
|
|
1783
|
+
customEditor.onPasteImage = () => this.defaultEditor.onPasteImage?.();
|
|
1784
|
+
}
|
|
1785
|
+
if (!customEditor.onExtensionShortcut) {
|
|
1786
|
+
customEditor.onExtensionShortcut = (data) => this.defaultEditor.onExtensionShortcut?.(data);
|
|
1787
|
+
}
|
|
1788
|
+
// Copy action handlers (clear, suspend, model switching, etc.)
|
|
1789
|
+
for (const [action, handler] of this.defaultEditor.actionHandlers) {
|
|
1790
|
+
customEditor.actionHandlers.set(action, handler);
|
|
1791
|
+
}
|
|
1792
|
+
}
|
|
1793
|
+
this.editor = newEditor;
|
|
1794
|
+
}
|
|
1795
|
+
else {
|
|
1796
|
+
// Restore default editor with text from custom editor
|
|
1797
|
+
this.defaultEditor.setText(currentText);
|
|
1798
|
+
this.editor = this.defaultEditor;
|
|
1799
|
+
}
|
|
1800
|
+
this.editorContainer.addChild(this.editor);
|
|
1801
|
+
this.ui.setFocus(this.editor);
|
|
1802
|
+
this.ui.requestRender();
|
|
1803
|
+
}
|
|
1804
|
+
/**
|
|
1805
|
+
* Show a notification for extensions.
|
|
1806
|
+
*/
|
|
1807
|
+
showExtensionNotify(message, type) {
|
|
1808
|
+
if (type === "error") {
|
|
1809
|
+
this.showError(message);
|
|
1810
|
+
}
|
|
1811
|
+
else if (type === "warning") {
|
|
1812
|
+
this.showWarning(message);
|
|
1813
|
+
}
|
|
1814
|
+
else {
|
|
1815
|
+
this.showStatus(message);
|
|
1816
|
+
}
|
|
1817
|
+
}
|
|
1818
|
+
/** Show a custom component with keyboard focus. Overlay mode renders on top of existing content. */
|
|
1819
|
+
async showExtensionCustom(factory, options) {
|
|
1820
|
+
const savedText = this.editor.getText();
|
|
1821
|
+
const isOverlay = options?.overlay ?? false;
|
|
1822
|
+
const restoreEditor = () => {
|
|
1823
|
+
this.editorContainer.clear();
|
|
1824
|
+
this.editorContainer.addChild(this.editor);
|
|
1825
|
+
this.editor.setText(savedText);
|
|
1826
|
+
this.ui.setFocus(this.editor);
|
|
1827
|
+
this.ui.requestRender();
|
|
1828
|
+
};
|
|
1829
|
+
return new Promise((resolve, reject) => {
|
|
1830
|
+
let component;
|
|
1831
|
+
let closed = false;
|
|
1832
|
+
const close = (result) => {
|
|
1833
|
+
if (closed)
|
|
1834
|
+
return;
|
|
1835
|
+
closed = true;
|
|
1836
|
+
if (isOverlay)
|
|
1837
|
+
this.ui.hideOverlay();
|
|
1838
|
+
else
|
|
1839
|
+
restoreEditor();
|
|
1840
|
+
// Note: both branches above already call requestRender
|
|
1841
|
+
resolve(result);
|
|
1842
|
+
try {
|
|
1843
|
+
component?.dispose?.();
|
|
1844
|
+
}
|
|
1845
|
+
catch {
|
|
1846
|
+
/* ignore dispose errors */
|
|
1847
|
+
}
|
|
1848
|
+
};
|
|
1849
|
+
Promise.resolve(factory(this.ui, theme, this.keybindings, close))
|
|
1850
|
+
.then((c) => {
|
|
1851
|
+
if (closed)
|
|
1852
|
+
return;
|
|
1853
|
+
component = c;
|
|
1854
|
+
if (isOverlay) {
|
|
1855
|
+
// Resolve overlay options - can be static or dynamic function
|
|
1856
|
+
const resolveOptions = () => {
|
|
1857
|
+
if (options?.overlayOptions) {
|
|
1858
|
+
const opts = typeof options.overlayOptions === "function"
|
|
1859
|
+
? options.overlayOptions()
|
|
1860
|
+
: options.overlayOptions;
|
|
1861
|
+
return opts;
|
|
1862
|
+
}
|
|
1863
|
+
// Fallback: use component's width property if available
|
|
1864
|
+
const w = component.width;
|
|
1865
|
+
return w ? { width: w } : undefined;
|
|
1866
|
+
};
|
|
1867
|
+
const handle = this.ui.showOverlay(component, resolveOptions());
|
|
1868
|
+
// Expose handle to caller for visibility control
|
|
1869
|
+
options?.onHandle?.(handle);
|
|
1870
|
+
}
|
|
1871
|
+
else {
|
|
1872
|
+
this.editorContainer.clear();
|
|
1873
|
+
this.editorContainer.addChild(component);
|
|
1874
|
+
this.ui.setFocus(component);
|
|
1875
|
+
this.ui.requestRender();
|
|
1876
|
+
}
|
|
1877
|
+
})
|
|
1878
|
+
.catch((err) => {
|
|
1879
|
+
if (closed)
|
|
1880
|
+
return;
|
|
1881
|
+
if (!isOverlay)
|
|
1882
|
+
restoreEditor();
|
|
1883
|
+
reject(err);
|
|
1884
|
+
});
|
|
1885
|
+
});
|
|
1886
|
+
}
|
|
1887
|
+
/**
|
|
1888
|
+
* Show an extension error in the UI.
|
|
1889
|
+
*/
|
|
1890
|
+
showExtensionError(extensionPath, error, stack) {
|
|
1891
|
+
const errorMsg = `Extension "${extensionPath}" error: ${error}`;
|
|
1892
|
+
const errorText = new Text(theme.fg("error", errorMsg), 1, 0);
|
|
1893
|
+
this.chatContainer.addChild(errorText);
|
|
1894
|
+
if (stack) {
|
|
1895
|
+
// Show stack trace in dim color, indented
|
|
1896
|
+
const stackLines = stack
|
|
1897
|
+
.split("\n")
|
|
1898
|
+
.slice(1) // Skip first line (duplicates error message)
|
|
1899
|
+
.map((line) => theme.fg("dim", ` ${line.trim()}`))
|
|
1900
|
+
.join("\n");
|
|
1901
|
+
if (stackLines) {
|
|
1902
|
+
this.chatContainer.addChild(new Text(stackLines, 1, 0));
|
|
1903
|
+
}
|
|
1904
|
+
}
|
|
1905
|
+
this.ui.requestRender();
|
|
1906
|
+
}
|
|
1907
|
+
// =========================================================================
|
|
1908
|
+
// Key Handlers
|
|
1909
|
+
// =========================================================================
|
|
1910
|
+
setupKeyHandlers() {
|
|
1911
|
+
// Set up handlers on defaultEditor - they use this.editor for text access
|
|
1912
|
+
// so they work correctly regardless of which editor is active
|
|
1913
|
+
this.defaultEditor.onEscape = () => {
|
|
1914
|
+
if (this.session.isStreaming) {
|
|
1915
|
+
this.restoreQueuedMessagesToEditor({ abort: true });
|
|
1916
|
+
}
|
|
1917
|
+
else if (this.session.isBashRunning) {
|
|
1918
|
+
this.session.abortBash();
|
|
1919
|
+
}
|
|
1920
|
+
else if (this.isBashMode) {
|
|
1921
|
+
this.editor.setText("");
|
|
1922
|
+
this.isBashMode = false;
|
|
1923
|
+
this.updateEditorBorderColor();
|
|
1924
|
+
}
|
|
1925
|
+
else if (!this.editor.getText().trim()) {
|
|
1926
|
+
// Double-escape with empty editor triggers /tree, /fork, or nothing based on setting
|
|
1927
|
+
const action = this.settingsManager.getDoubleEscapeAction();
|
|
1928
|
+
if (action !== "none") {
|
|
1929
|
+
const now = Date.now();
|
|
1930
|
+
if (now - this.lastEscapeTime < 500) {
|
|
1931
|
+
if (action === "tree") {
|
|
1932
|
+
this.showTreeSelector();
|
|
1933
|
+
}
|
|
1934
|
+
else {
|
|
1935
|
+
this.showUserMessageSelector();
|
|
1936
|
+
}
|
|
1937
|
+
this.lastEscapeTime = 0;
|
|
1938
|
+
}
|
|
1939
|
+
else {
|
|
1940
|
+
this.lastEscapeTime = now;
|
|
1941
|
+
}
|
|
1942
|
+
}
|
|
1943
|
+
}
|
|
1944
|
+
};
|
|
1945
|
+
// Register app action handlers
|
|
1946
|
+
this.defaultEditor.onAction("app.clear", () => this.handleCtrlC());
|
|
1947
|
+
this.defaultEditor.onCtrlD = () => this.handleCtrlD();
|
|
1948
|
+
this.defaultEditor.onAction("app.suspend", () => this.handleCtrlZ());
|
|
1949
|
+
this.defaultEditor.onAction("app.thinking.cycle", () => this.cycleThinkingLevel());
|
|
1950
|
+
this.defaultEditor.onAction("app.model.cycleForward", () => this.cycleModel("forward"));
|
|
1951
|
+
this.defaultEditor.onAction("app.model.cycleBackward", () => this.cycleModel("backward"));
|
|
1952
|
+
// Global debug handler on TUI (works regardless of focus)
|
|
1953
|
+
this.ui.onDebug = () => this.handleDebugCommand();
|
|
1954
|
+
this.defaultEditor.onAction("app.model.select", () => this.showModelSelector());
|
|
1955
|
+
this.defaultEditor.onAction("app.tools.expand", () => this.toggleToolOutputExpansion());
|
|
1956
|
+
this.defaultEditor.onAction("app.thinking.toggle", () => this.toggleThinkingBlockVisibility());
|
|
1957
|
+
this.defaultEditor.onAction("app.editor.external", () => this.openExternalEditor());
|
|
1958
|
+
this.defaultEditor.onAction("app.message.followUp", () => this.handleFollowUp());
|
|
1959
|
+
this.defaultEditor.onAction("app.message.dequeue", () => this.handleDequeue());
|
|
1960
|
+
this.defaultEditor.onAction("app.session.new", () => this.handleClearCommand());
|
|
1961
|
+
this.defaultEditor.onAction("app.session.tree", () => this.showTreeSelector());
|
|
1962
|
+
this.defaultEditor.onAction("app.session.fork", () => this.showUserMessageSelector());
|
|
1963
|
+
this.defaultEditor.onAction("app.session.resume", () => this.showSessionSelector());
|
|
1964
|
+
this.defaultEditor.onChange = (text) => {
|
|
1965
|
+
const wasBashMode = this.isBashMode;
|
|
1966
|
+
this.isBashMode = text.trimStart().startsWith("!");
|
|
1967
|
+
if (wasBashMode !== this.isBashMode) {
|
|
1968
|
+
this.updateEditorBorderColor();
|
|
1969
|
+
}
|
|
1970
|
+
};
|
|
1971
|
+
// Handle clipboard image paste (triggered on Ctrl+V)
|
|
1972
|
+
this.defaultEditor.onPasteImage = () => {
|
|
1973
|
+
this.handleClipboardImagePaste();
|
|
1974
|
+
};
|
|
1975
|
+
}
|
|
1976
|
+
async handleClipboardImagePaste() {
|
|
1977
|
+
try {
|
|
1978
|
+
const image = await readClipboardImage();
|
|
1979
|
+
if (!image) {
|
|
1980
|
+
return;
|
|
1981
|
+
}
|
|
1982
|
+
// Write to temp file
|
|
1983
|
+
const tmpDir = os.tmpdir();
|
|
1984
|
+
const ext = extensionForImageMimeType(image.mimeType) ?? "png";
|
|
1985
|
+
const fileName = `pi-clipboard-${crypto.randomUUID()}.${ext}`;
|
|
1986
|
+
const filePath = path.join(tmpDir, fileName);
|
|
1987
|
+
fs.writeFileSync(filePath, Buffer.from(image.bytes));
|
|
1988
|
+
// Insert file path directly
|
|
1989
|
+
this.editor.insertTextAtCursor?.(filePath);
|
|
1990
|
+
this.ui.requestRender();
|
|
1991
|
+
}
|
|
1992
|
+
catch {
|
|
1993
|
+
// Silently ignore clipboard errors (may not have permission, etc.)
|
|
1994
|
+
}
|
|
1995
|
+
}
|
|
1996
|
+
setupEditorSubmitHandler() {
|
|
1997
|
+
this.defaultEditor.onSubmit = async (text) => {
|
|
1998
|
+
text = text.trim();
|
|
1999
|
+
if (!text)
|
|
2000
|
+
return;
|
|
2001
|
+
// Handle commands
|
|
2002
|
+
if (text === "/settings") {
|
|
2003
|
+
this.showSettingsSelector();
|
|
2004
|
+
this.editor.setText("");
|
|
2005
|
+
return;
|
|
2006
|
+
}
|
|
2007
|
+
if (text === "/scoped-models") {
|
|
2008
|
+
this.editor.setText("");
|
|
2009
|
+
await this.showModelsSelector();
|
|
2010
|
+
return;
|
|
2011
|
+
}
|
|
2012
|
+
if (text === "/model" || text.startsWith("/model ")) {
|
|
2013
|
+
const searchTerm = text.startsWith("/model ") ? text.slice(7).trim() : undefined;
|
|
2014
|
+
this.editor.setText("");
|
|
2015
|
+
await this.handleModelCommand(searchTerm);
|
|
2016
|
+
return;
|
|
2017
|
+
}
|
|
2018
|
+
if (text === "/export" || text.startsWith("/export ")) {
|
|
2019
|
+
await this.handleExportCommand(text);
|
|
2020
|
+
this.editor.setText("");
|
|
2021
|
+
return;
|
|
2022
|
+
}
|
|
2023
|
+
if (text === "/import" || text.startsWith("/import ")) {
|
|
2024
|
+
await this.handleImportCommand(text);
|
|
2025
|
+
this.editor.setText("");
|
|
2026
|
+
return;
|
|
2027
|
+
}
|
|
2028
|
+
if (text === "/share") {
|
|
2029
|
+
await this.handleShareCommand();
|
|
2030
|
+
this.editor.setText("");
|
|
2031
|
+
return;
|
|
2032
|
+
}
|
|
2033
|
+
if (text === "/copy") {
|
|
2034
|
+
await this.handleCopyCommand();
|
|
2035
|
+
this.editor.setText("");
|
|
2036
|
+
return;
|
|
2037
|
+
}
|
|
2038
|
+
if (text === "/name" || text.startsWith("/name ")) {
|
|
2039
|
+
this.handleNameCommand(text);
|
|
2040
|
+
this.editor.setText("");
|
|
2041
|
+
return;
|
|
2042
|
+
}
|
|
2043
|
+
if (text === "/session") {
|
|
2044
|
+
this.handleSessionCommand();
|
|
2045
|
+
this.editor.setText("");
|
|
2046
|
+
return;
|
|
2047
|
+
}
|
|
2048
|
+
if (text === "/changelog") {
|
|
2049
|
+
this.handleChangelogCommand();
|
|
2050
|
+
this.editor.setText("");
|
|
2051
|
+
return;
|
|
2052
|
+
}
|
|
2053
|
+
if (text === "/hotkeys") {
|
|
2054
|
+
this.handleHotkeysCommand();
|
|
2055
|
+
this.editor.setText("");
|
|
2056
|
+
return;
|
|
2057
|
+
}
|
|
2058
|
+
if (text === "/fork") {
|
|
2059
|
+
this.showUserMessageSelector();
|
|
2060
|
+
this.editor.setText("");
|
|
2061
|
+
return;
|
|
2062
|
+
}
|
|
2063
|
+
if (text === "/clone") {
|
|
2064
|
+
this.editor.setText("");
|
|
2065
|
+
await this.handleCloneCommand();
|
|
2066
|
+
return;
|
|
2067
|
+
}
|
|
2068
|
+
if (text === "/tree") {
|
|
2069
|
+
this.showTreeSelector();
|
|
2070
|
+
this.editor.setText("");
|
|
2071
|
+
return;
|
|
2072
|
+
}
|
|
2073
|
+
if (text === "/login") {
|
|
2074
|
+
this.showOAuthSelector("login");
|
|
2075
|
+
this.editor.setText("");
|
|
2076
|
+
return;
|
|
2077
|
+
}
|
|
2078
|
+
if (text === "/logout") {
|
|
2079
|
+
this.showOAuthSelector("logout");
|
|
2080
|
+
this.editor.setText("");
|
|
2081
|
+
return;
|
|
2082
|
+
}
|
|
2083
|
+
if (text === "/new") {
|
|
2084
|
+
this.editor.setText("");
|
|
2085
|
+
await this.handleClearCommand();
|
|
2086
|
+
return;
|
|
2087
|
+
}
|
|
2088
|
+
if (text === "/compact" || text.startsWith("/compact ")) {
|
|
2089
|
+
const customInstructions = text.startsWith("/compact ") ? text.slice(9).trim() : undefined;
|
|
2090
|
+
this.editor.setText("");
|
|
2091
|
+
await this.handleCompactCommand(customInstructions);
|
|
2092
|
+
return;
|
|
2093
|
+
}
|
|
2094
|
+
if (text === "/reload") {
|
|
2095
|
+
this.editor.setText("");
|
|
2096
|
+
await this.handleReloadCommand();
|
|
2097
|
+
return;
|
|
2098
|
+
}
|
|
2099
|
+
if (text === "/debug") {
|
|
2100
|
+
this.handleDebugCommand();
|
|
2101
|
+
this.editor.setText("");
|
|
2102
|
+
return;
|
|
2103
|
+
}
|
|
2104
|
+
if (text === "/arminsayshi") {
|
|
2105
|
+
this.handleArminSaysHi();
|
|
2106
|
+
this.editor.setText("");
|
|
2107
|
+
return;
|
|
2108
|
+
}
|
|
2109
|
+
if (text === "/dementedelves") {
|
|
2110
|
+
this.handleDementedDelves();
|
|
2111
|
+
this.editor.setText("");
|
|
2112
|
+
return;
|
|
2113
|
+
}
|
|
2114
|
+
if (text === "/resume") {
|
|
2115
|
+
this.showSessionSelector();
|
|
2116
|
+
this.editor.setText("");
|
|
2117
|
+
return;
|
|
2118
|
+
}
|
|
2119
|
+
if (text === "/quit") {
|
|
2120
|
+
this.editor.setText("");
|
|
2121
|
+
await this.shutdown();
|
|
2122
|
+
return;
|
|
2123
|
+
}
|
|
2124
|
+
// Handle bash command (! for normal, !! for excluded from context)
|
|
2125
|
+
if (text.startsWith("!")) {
|
|
2126
|
+
const isExcluded = text.startsWith("!!");
|
|
2127
|
+
const command = isExcluded ? text.slice(2).trim() : text.slice(1).trim();
|
|
2128
|
+
if (command) {
|
|
2129
|
+
if (this.session.isBashRunning) {
|
|
2130
|
+
this.showWarning("A bash command is already running. Press Esc to cancel it first.");
|
|
2131
|
+
this.editor.setText(text);
|
|
2132
|
+
return;
|
|
2133
|
+
}
|
|
2134
|
+
this.editor.addToHistory?.(text);
|
|
2135
|
+
await this.handleBashCommand(command, isExcluded);
|
|
2136
|
+
this.isBashMode = false;
|
|
2137
|
+
this.updateEditorBorderColor();
|
|
2138
|
+
return;
|
|
2139
|
+
}
|
|
2140
|
+
}
|
|
2141
|
+
// Queue input during compaction (extension commands execute immediately)
|
|
2142
|
+
if (this.session.isCompacting) {
|
|
2143
|
+
if (this.isExtensionCommand(text)) {
|
|
2144
|
+
this.editor.addToHistory?.(text);
|
|
2145
|
+
this.editor.setText("");
|
|
2146
|
+
await this.session.prompt(text);
|
|
2147
|
+
}
|
|
2148
|
+
else {
|
|
2149
|
+
this.queueCompactionMessage(text, "steer");
|
|
2150
|
+
}
|
|
2151
|
+
return;
|
|
2152
|
+
}
|
|
2153
|
+
// If streaming, use prompt() with steer behavior
|
|
2154
|
+
// This handles extension commands (execute immediately), prompt template expansion, and queueing
|
|
2155
|
+
if (this.session.isStreaming) {
|
|
2156
|
+
this.editor.addToHistory?.(text);
|
|
2157
|
+
this.editor.setText("");
|
|
2158
|
+
await this.session.prompt(text, { streamingBehavior: "steer" });
|
|
2159
|
+
this.updatePendingMessagesDisplay();
|
|
2160
|
+
this.ui.requestRender();
|
|
2161
|
+
return;
|
|
2162
|
+
}
|
|
2163
|
+
// Normal message submission
|
|
2164
|
+
// First, move any pending bash components to chat
|
|
2165
|
+
this.flushPendingBashComponents();
|
|
2166
|
+
if (this.onInputCallback) {
|
|
2167
|
+
this.onInputCallback(text);
|
|
2168
|
+
}
|
|
2169
|
+
this.editor.addToHistory?.(text);
|
|
2170
|
+
};
|
|
2171
|
+
}
|
|
2172
|
+
subscribeToAgent() {
|
|
2173
|
+
this.unsubscribe = this.session.subscribe(async (event) => {
|
|
2174
|
+
await this.handleEvent(event);
|
|
2175
|
+
});
|
|
2176
|
+
}
|
|
2177
|
+
async handleEvent(event) {
|
|
2178
|
+
if (!this.isInitialized) {
|
|
2179
|
+
await this.init();
|
|
2180
|
+
}
|
|
2181
|
+
this.footer.invalidate();
|
|
2182
|
+
switch (event.type) {
|
|
2183
|
+
case "agent_start":
|
|
2184
|
+
this.pendingTools.clear();
|
|
2185
|
+
if (this.settingsManager.getShowTerminalProgress()) {
|
|
2186
|
+
this.ui.terminal.setProgress(true);
|
|
2187
|
+
}
|
|
2188
|
+
// Restore main escape handler if retry handler is still active
|
|
2189
|
+
// (retry success event fires later, but we need main handler now)
|
|
2190
|
+
if (this.retryEscapeHandler) {
|
|
2191
|
+
this.defaultEditor.onEscape = this.retryEscapeHandler;
|
|
2192
|
+
this.retryEscapeHandler = undefined;
|
|
2193
|
+
}
|
|
2194
|
+
if (this.retryCountdown) {
|
|
2195
|
+
this.retryCountdown.dispose();
|
|
2196
|
+
this.retryCountdown = undefined;
|
|
2197
|
+
}
|
|
2198
|
+
if (this.retryLoader) {
|
|
2199
|
+
this.retryLoader.stop();
|
|
2200
|
+
this.retryLoader = undefined;
|
|
2201
|
+
}
|
|
2202
|
+
this.stopWorkingLoader();
|
|
2203
|
+
if (this.workingVisible) {
|
|
2204
|
+
this.loadingAnimation = this.createWorkingLoader();
|
|
2205
|
+
this.statusContainer.addChild(this.loadingAnimation);
|
|
2206
|
+
}
|
|
2207
|
+
this.ui.requestRender();
|
|
2208
|
+
break;
|
|
2209
|
+
case "queue_update":
|
|
2210
|
+
this.updatePendingMessagesDisplay();
|
|
2211
|
+
this.ui.requestRender();
|
|
2212
|
+
break;
|
|
2213
|
+
case "session_info_changed":
|
|
2214
|
+
this.updateTerminalTitle();
|
|
2215
|
+
this.footer.invalidate();
|
|
2216
|
+
this.ui.requestRender();
|
|
2217
|
+
break;
|
|
2218
|
+
case "thinking_level_changed":
|
|
2219
|
+
this.footer.invalidate();
|
|
2220
|
+
this.updateEditorBorderColor();
|
|
2221
|
+
break;
|
|
2222
|
+
case "message_start":
|
|
2223
|
+
if (event.message.role === "custom") {
|
|
2224
|
+
this.addMessageToChat(event.message);
|
|
2225
|
+
this.ui.requestRender();
|
|
2226
|
+
}
|
|
2227
|
+
else if (event.message.role === "user") {
|
|
2228
|
+
this.addMessageToChat(event.message);
|
|
2229
|
+
this.updatePendingMessagesDisplay();
|
|
2230
|
+
this.ui.requestRender();
|
|
2231
|
+
}
|
|
2232
|
+
else if (event.message.role === "assistant") {
|
|
2233
|
+
this.streamingComponent = new AssistantMessageComponent(undefined, this.hideThinkingBlock, this.getMarkdownThemeWithSettings(), this.hiddenThinkingLabel);
|
|
2234
|
+
this.streamingMessage = event.message;
|
|
2235
|
+
this.chatContainer.addChild(this.streamingComponent);
|
|
2236
|
+
this.streamingComponent.updateContent(this.streamingMessage);
|
|
2237
|
+
this.ui.requestRender();
|
|
2238
|
+
}
|
|
2239
|
+
break;
|
|
2240
|
+
case "message_update":
|
|
2241
|
+
if (this.streamingComponent && event.message.role === "assistant") {
|
|
2242
|
+
this.streamingMessage = event.message;
|
|
2243
|
+
this.streamingComponent.updateContent(this.streamingMessage);
|
|
2244
|
+
for (const content of this.streamingMessage.content) {
|
|
2245
|
+
if (content.type === "toolCall") {
|
|
2246
|
+
if (!this.pendingTools.has(content.id)) {
|
|
2247
|
+
const component = new ToolExecutionComponent(content.name, content.id, content.arguments, {
|
|
2248
|
+
showImages: this.settingsManager.getShowImages(),
|
|
2249
|
+
imageWidthCells: this.settingsManager.getImageWidthCells(),
|
|
2250
|
+
}, this.getRegisteredToolDefinition(content.name), this.ui, this.sessionManager.getCwd());
|
|
2251
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2252
|
+
this.chatContainer.addChild(component);
|
|
2253
|
+
this.pendingTools.set(content.id, component);
|
|
2254
|
+
}
|
|
2255
|
+
else {
|
|
2256
|
+
const component = this.pendingTools.get(content.id);
|
|
2257
|
+
if (component) {
|
|
2258
|
+
component.updateArgs(content.arguments);
|
|
2259
|
+
}
|
|
2260
|
+
}
|
|
2261
|
+
}
|
|
2262
|
+
}
|
|
2263
|
+
this.ui.requestRender();
|
|
2264
|
+
}
|
|
2265
|
+
break;
|
|
2266
|
+
case "message_end":
|
|
2267
|
+
if (event.message.role === "user")
|
|
2268
|
+
break;
|
|
2269
|
+
if (this.streamingComponent && event.message.role === "assistant") {
|
|
2270
|
+
this.streamingMessage = event.message;
|
|
2271
|
+
let errorMessage;
|
|
2272
|
+
if (this.streamingMessage.stopReason === "aborted") {
|
|
2273
|
+
const retryAttempt = this.session.retryAttempt;
|
|
2274
|
+
errorMessage =
|
|
2275
|
+
retryAttempt > 0
|
|
2276
|
+
? `Aborted after ${retryAttempt} retry attempt${retryAttempt > 1 ? "s" : ""}`
|
|
2277
|
+
: "Operation aborted";
|
|
2278
|
+
this.streamingMessage.errorMessage = errorMessage;
|
|
2279
|
+
}
|
|
2280
|
+
this.streamingComponent.updateContent(this.streamingMessage);
|
|
2281
|
+
if (this.streamingMessage.stopReason === "aborted" || this.streamingMessage.stopReason === "error") {
|
|
2282
|
+
if (!errorMessage) {
|
|
2283
|
+
errorMessage = this.streamingMessage.errorMessage || "Error";
|
|
2284
|
+
}
|
|
2285
|
+
for (const [, component] of this.pendingTools.entries()) {
|
|
2286
|
+
component.updateResult({
|
|
2287
|
+
content: [{ type: "text", text: errorMessage }],
|
|
2288
|
+
isError: true,
|
|
2289
|
+
});
|
|
2290
|
+
}
|
|
2291
|
+
this.pendingTools.clear();
|
|
2292
|
+
}
|
|
2293
|
+
else {
|
|
2294
|
+
// Args are now complete - trigger diff computation for edit tools
|
|
2295
|
+
for (const [, component] of this.pendingTools.entries()) {
|
|
2296
|
+
component.setArgsComplete();
|
|
2297
|
+
}
|
|
2298
|
+
}
|
|
2299
|
+
this.streamingComponent = undefined;
|
|
2300
|
+
this.streamingMessage = undefined;
|
|
2301
|
+
this.footer.invalidate();
|
|
2302
|
+
}
|
|
2303
|
+
this.ui.requestRender();
|
|
2304
|
+
break;
|
|
2305
|
+
case "tool_execution_start": {
|
|
2306
|
+
let component = this.pendingTools.get(event.toolCallId);
|
|
2307
|
+
if (!component) {
|
|
2308
|
+
component = new ToolExecutionComponent(event.toolName, event.toolCallId, event.args, {
|
|
2309
|
+
showImages: this.settingsManager.getShowImages(),
|
|
2310
|
+
imageWidthCells: this.settingsManager.getImageWidthCells(),
|
|
2311
|
+
}, this.getRegisteredToolDefinition(event.toolName), this.ui, this.sessionManager.getCwd());
|
|
2312
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2313
|
+
this.chatContainer.addChild(component);
|
|
2314
|
+
this.pendingTools.set(event.toolCallId, component);
|
|
2315
|
+
}
|
|
2316
|
+
component.markExecutionStarted();
|
|
2317
|
+
this.ui.requestRender();
|
|
2318
|
+
break;
|
|
2319
|
+
}
|
|
2320
|
+
case "tool_execution_update": {
|
|
2321
|
+
const component = this.pendingTools.get(event.toolCallId);
|
|
2322
|
+
if (component) {
|
|
2323
|
+
component.updateResult({ ...event.partialResult, isError: false }, true);
|
|
2324
|
+
this.ui.requestRender();
|
|
2325
|
+
}
|
|
2326
|
+
break;
|
|
2327
|
+
}
|
|
2328
|
+
case "tool_execution_end": {
|
|
2329
|
+
const component = this.pendingTools.get(event.toolCallId);
|
|
2330
|
+
if (component) {
|
|
2331
|
+
component.updateResult({ ...event.result, isError: event.isError });
|
|
2332
|
+
this.pendingTools.delete(event.toolCallId);
|
|
2333
|
+
this.ui.requestRender();
|
|
2334
|
+
}
|
|
2335
|
+
break;
|
|
2336
|
+
}
|
|
2337
|
+
case "agent_end":
|
|
2338
|
+
if (this.settingsManager.getShowTerminalProgress()) {
|
|
2339
|
+
this.ui.terminal.setProgress(false);
|
|
2340
|
+
}
|
|
2341
|
+
if (this.loadingAnimation) {
|
|
2342
|
+
this.loadingAnimation.stop();
|
|
2343
|
+
this.loadingAnimation = undefined;
|
|
2344
|
+
this.statusContainer.clear();
|
|
2345
|
+
}
|
|
2346
|
+
if (this.streamingComponent) {
|
|
2347
|
+
this.chatContainer.removeChild(this.streamingComponent);
|
|
2348
|
+
this.streamingComponent = undefined;
|
|
2349
|
+
this.streamingMessage = undefined;
|
|
2350
|
+
}
|
|
2351
|
+
this.pendingTools.clear();
|
|
2352
|
+
await this.checkShutdownRequested();
|
|
2353
|
+
this.ui.requestRender();
|
|
2354
|
+
break;
|
|
2355
|
+
case "compaction_start": {
|
|
2356
|
+
if (this.settingsManager.getShowTerminalProgress()) {
|
|
2357
|
+
this.ui.terminal.setProgress(true);
|
|
2358
|
+
}
|
|
2359
|
+
// Keep editor active; submissions are queued during compaction.
|
|
2360
|
+
this.autoCompactionEscapeHandler = this.defaultEditor.onEscape;
|
|
2361
|
+
this.defaultEditor.onEscape = () => {
|
|
2362
|
+
this.session.abortCompaction();
|
|
2363
|
+
};
|
|
2364
|
+
this.statusContainer.clear();
|
|
2365
|
+
const cancelHint = `(${keyText("app.interrupt")} to cancel)`;
|
|
2366
|
+
const label = event.reason === "manual"
|
|
2367
|
+
? `Compacting context... ${cancelHint}`
|
|
2368
|
+
: `${event.reason === "overflow" ? "Context overflow detected, " : ""}Auto-compacting... ${cancelHint}`;
|
|
2369
|
+
this.autoCompactionLoader = new Loader(this.ui, (spinner) => theme.fg("accent", spinner), (text) => theme.fg("muted", text), label);
|
|
2370
|
+
this.statusContainer.addChild(this.autoCompactionLoader);
|
|
2371
|
+
this.ui.requestRender();
|
|
2372
|
+
break;
|
|
2373
|
+
}
|
|
2374
|
+
case "compaction_end": {
|
|
2375
|
+
if (this.settingsManager.getShowTerminalProgress()) {
|
|
2376
|
+
this.ui.terminal.setProgress(false);
|
|
2377
|
+
}
|
|
2378
|
+
if (this.autoCompactionEscapeHandler) {
|
|
2379
|
+
this.defaultEditor.onEscape = this.autoCompactionEscapeHandler;
|
|
2380
|
+
this.autoCompactionEscapeHandler = undefined;
|
|
2381
|
+
}
|
|
2382
|
+
if (this.autoCompactionLoader) {
|
|
2383
|
+
this.autoCompactionLoader.stop();
|
|
2384
|
+
this.autoCompactionLoader = undefined;
|
|
2385
|
+
this.statusContainer.clear();
|
|
2386
|
+
}
|
|
2387
|
+
if (event.aborted) {
|
|
2388
|
+
if (event.reason === "manual") {
|
|
2389
|
+
this.showError("Compaction cancelled");
|
|
2390
|
+
}
|
|
2391
|
+
else {
|
|
2392
|
+
this.showStatus("Auto-compaction cancelled");
|
|
2393
|
+
}
|
|
2394
|
+
}
|
|
2395
|
+
else if (event.result) {
|
|
2396
|
+
this.chatContainer.clear();
|
|
2397
|
+
this.rebuildChatFromMessages();
|
|
2398
|
+
this.addMessageToChat(createCompactionSummaryMessage(event.result.summary, event.result.tokensBefore, new Date().toISOString()));
|
|
2399
|
+
this.footer.invalidate();
|
|
2400
|
+
}
|
|
2401
|
+
else if (event.errorMessage) {
|
|
2402
|
+
if (event.reason === "manual") {
|
|
2403
|
+
this.showError(event.errorMessage);
|
|
2404
|
+
}
|
|
2405
|
+
else {
|
|
2406
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2407
|
+
this.chatContainer.addChild(new Text(theme.fg("error", event.errorMessage), 1, 0));
|
|
2408
|
+
}
|
|
2409
|
+
}
|
|
2410
|
+
void this.flushCompactionQueue({ willRetry: event.willRetry });
|
|
2411
|
+
this.ui.requestRender();
|
|
2412
|
+
break;
|
|
2413
|
+
}
|
|
2414
|
+
case "auto_retry_start": {
|
|
2415
|
+
// Set up escape to abort retry
|
|
2416
|
+
this.retryEscapeHandler = this.defaultEditor.onEscape;
|
|
2417
|
+
this.defaultEditor.onEscape = () => {
|
|
2418
|
+
this.session.abortRetry();
|
|
2419
|
+
};
|
|
2420
|
+
// Show retry indicator
|
|
2421
|
+
this.statusContainer.clear();
|
|
2422
|
+
this.retryCountdown?.dispose();
|
|
2423
|
+
const retryMessage = (seconds) => `Retrying (${event.attempt}/${event.maxAttempts}) in ${seconds}s... (${keyText("app.interrupt")} to cancel)`;
|
|
2424
|
+
this.retryLoader = new Loader(this.ui, (spinner) => theme.fg("warning", spinner), (text) => theme.fg("muted", text), retryMessage(Math.ceil(event.delayMs / 1000)));
|
|
2425
|
+
this.retryCountdown = new CountdownTimer(event.delayMs, this.ui, (seconds) => {
|
|
2426
|
+
this.retryLoader?.setMessage(retryMessage(seconds));
|
|
2427
|
+
}, () => {
|
|
2428
|
+
this.retryCountdown = undefined;
|
|
2429
|
+
});
|
|
2430
|
+
this.statusContainer.addChild(this.retryLoader);
|
|
2431
|
+
this.ui.requestRender();
|
|
2432
|
+
break;
|
|
2433
|
+
}
|
|
2434
|
+
case "auto_retry_end": {
|
|
2435
|
+
// Restore escape handler
|
|
2436
|
+
if (this.retryEscapeHandler) {
|
|
2437
|
+
this.defaultEditor.onEscape = this.retryEscapeHandler;
|
|
2438
|
+
this.retryEscapeHandler = undefined;
|
|
2439
|
+
}
|
|
2440
|
+
if (this.retryCountdown) {
|
|
2441
|
+
this.retryCountdown.dispose();
|
|
2442
|
+
this.retryCountdown = undefined;
|
|
2443
|
+
}
|
|
2444
|
+
// Stop loader
|
|
2445
|
+
if (this.retryLoader) {
|
|
2446
|
+
this.retryLoader.stop();
|
|
2447
|
+
this.retryLoader = undefined;
|
|
2448
|
+
this.statusContainer.clear();
|
|
2449
|
+
}
|
|
2450
|
+
// Show error only on final failure (success shows normal response)
|
|
2451
|
+
if (!event.success) {
|
|
2452
|
+
this.showError(`Retry failed after ${event.attempt} attempts: ${event.finalError || "Unknown error"}`);
|
|
2453
|
+
}
|
|
2454
|
+
this.ui.requestRender();
|
|
2455
|
+
break;
|
|
2456
|
+
}
|
|
2457
|
+
}
|
|
2458
|
+
}
|
|
2459
|
+
/** Extract text content from a user message */
|
|
2460
|
+
getUserMessageText(message) {
|
|
2461
|
+
if (message.role !== "user")
|
|
2462
|
+
return "";
|
|
2463
|
+
const textBlocks = typeof message.content === "string"
|
|
2464
|
+
? [{ type: "text", text: message.content }]
|
|
2465
|
+
: message.content.filter((c) => c.type === "text");
|
|
2466
|
+
return textBlocks.map((c) => c.text).join("");
|
|
2467
|
+
}
|
|
2468
|
+
/**
|
|
2469
|
+
* Show a status message in the chat.
|
|
2470
|
+
*
|
|
2471
|
+
* If multiple status messages are emitted back-to-back (without anything else being added to the chat),
|
|
2472
|
+
* we update the previous status line instead of appending new ones to avoid log spam.
|
|
2473
|
+
*/
|
|
2474
|
+
showStatus(message) {
|
|
2475
|
+
const children = this.chatContainer.children;
|
|
2476
|
+
const last = children.length > 0 ? children[children.length - 1] : undefined;
|
|
2477
|
+
const secondLast = children.length > 1 ? children[children.length - 2] : undefined;
|
|
2478
|
+
if (last && secondLast && last === this.lastStatusText && secondLast === this.lastStatusSpacer) {
|
|
2479
|
+
this.lastStatusText.setText(theme.fg("dim", message));
|
|
2480
|
+
this.ui.requestRender();
|
|
2481
|
+
return;
|
|
2482
|
+
}
|
|
2483
|
+
const spacer = new Spacer(1);
|
|
2484
|
+
const text = new Text(theme.fg("dim", message), 1, 0);
|
|
2485
|
+
this.chatContainer.addChild(spacer);
|
|
2486
|
+
this.chatContainer.addChild(text);
|
|
2487
|
+
this.lastStatusSpacer = spacer;
|
|
2488
|
+
this.lastStatusText = text;
|
|
2489
|
+
this.ui.requestRender();
|
|
2490
|
+
}
|
|
2491
|
+
addMessageToChat(message, options) {
|
|
2492
|
+
switch (message.role) {
|
|
2493
|
+
case "bashExecution": {
|
|
2494
|
+
const component = new BashExecutionComponent(message.command, this.ui, message.excludeFromContext);
|
|
2495
|
+
if (message.output) {
|
|
2496
|
+
component.appendOutput(message.output);
|
|
2497
|
+
}
|
|
2498
|
+
component.setComplete(message.exitCode, message.cancelled, message.truncated ? { truncated: true } : undefined, message.fullOutputPath);
|
|
2499
|
+
this.chatContainer.addChild(component);
|
|
2500
|
+
break;
|
|
2501
|
+
}
|
|
2502
|
+
case "custom": {
|
|
2503
|
+
if (message.display) {
|
|
2504
|
+
const renderer = this.session.extensionRunner.getMessageRenderer(message.customType);
|
|
2505
|
+
const component = new CustomMessageComponent(message, renderer, this.getMarkdownThemeWithSettings());
|
|
2506
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2507
|
+
this.chatContainer.addChild(component);
|
|
2508
|
+
}
|
|
2509
|
+
break;
|
|
2510
|
+
}
|
|
2511
|
+
case "compactionSummary": {
|
|
2512
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2513
|
+
const component = new CompactionSummaryMessageComponent(message, this.getMarkdownThemeWithSettings());
|
|
2514
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2515
|
+
this.chatContainer.addChild(component);
|
|
2516
|
+
break;
|
|
2517
|
+
}
|
|
2518
|
+
case "branchSummary": {
|
|
2519
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2520
|
+
const component = new BranchSummaryMessageComponent(message, this.getMarkdownThemeWithSettings());
|
|
2521
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2522
|
+
this.chatContainer.addChild(component);
|
|
2523
|
+
break;
|
|
2524
|
+
}
|
|
2525
|
+
case "user": {
|
|
2526
|
+
const textContent = this.getUserMessageText(message);
|
|
2527
|
+
if (textContent) {
|
|
2528
|
+
if (this.chatContainer.children.length > 0) {
|
|
2529
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2530
|
+
}
|
|
2531
|
+
const skillBlock = parseSkillBlock(textContent);
|
|
2532
|
+
if (skillBlock) {
|
|
2533
|
+
// Render skill block (collapsible)
|
|
2534
|
+
const component = new SkillInvocationMessageComponent(skillBlock, this.getMarkdownThemeWithSettings());
|
|
2535
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2536
|
+
this.chatContainer.addChild(component);
|
|
2537
|
+
// Render user message separately if present
|
|
2538
|
+
if (skillBlock.userMessage) {
|
|
2539
|
+
const userComponent = new UserMessageComponent(skillBlock.userMessage, this.getMarkdownThemeWithSettings());
|
|
2540
|
+
this.chatContainer.addChild(userComponent);
|
|
2541
|
+
}
|
|
2542
|
+
}
|
|
2543
|
+
else {
|
|
2544
|
+
const userComponent = new UserMessageComponent(textContent, this.getMarkdownThemeWithSettings());
|
|
2545
|
+
this.chatContainer.addChild(userComponent);
|
|
2546
|
+
}
|
|
2547
|
+
if (options?.populateHistory) {
|
|
2548
|
+
this.editor.addToHistory?.(textContent);
|
|
2549
|
+
}
|
|
2550
|
+
}
|
|
2551
|
+
break;
|
|
2552
|
+
}
|
|
2553
|
+
case "assistant": {
|
|
2554
|
+
const assistantComponent = new AssistantMessageComponent(message, this.hideThinkingBlock, this.getMarkdownThemeWithSettings(), this.hiddenThinkingLabel);
|
|
2555
|
+
this.chatContainer.addChild(assistantComponent);
|
|
2556
|
+
break;
|
|
2557
|
+
}
|
|
2558
|
+
case "toolResult": {
|
|
2559
|
+
// Tool results are rendered inline with tool calls, handled separately
|
|
2560
|
+
break;
|
|
2561
|
+
}
|
|
2562
|
+
default: {
|
|
2563
|
+
const _exhaustive = message;
|
|
2564
|
+
}
|
|
2565
|
+
}
|
|
2566
|
+
}
|
|
2567
|
+
/**
|
|
2568
|
+
* Render session context to chat. Used for initial load and rebuild after compaction.
|
|
2569
|
+
* @param sessionContext Session context to render
|
|
2570
|
+
* @param options.updateFooter Update footer state
|
|
2571
|
+
* @param options.populateHistory Add user messages to editor history
|
|
2572
|
+
*/
|
|
2573
|
+
renderSessionContext(sessionContext, options = {}) {
|
|
2574
|
+
this.pendingTools.clear();
|
|
2575
|
+
const renderedPendingTools = new Map();
|
|
2576
|
+
if (options.updateFooter) {
|
|
2577
|
+
this.footer.invalidate();
|
|
2578
|
+
this.updateEditorBorderColor();
|
|
2579
|
+
}
|
|
2580
|
+
for (const message of sessionContext.messages) {
|
|
2581
|
+
// Assistant messages need special handling for tool calls
|
|
2582
|
+
if (message.role === "assistant") {
|
|
2583
|
+
this.addMessageToChat(message);
|
|
2584
|
+
// Render tool call components
|
|
2585
|
+
for (const content of message.content) {
|
|
2586
|
+
if (content.type === "toolCall") {
|
|
2587
|
+
const component = new ToolExecutionComponent(content.name, content.id, content.arguments, {
|
|
2588
|
+
showImages: this.settingsManager.getShowImages(),
|
|
2589
|
+
imageWidthCells: this.settingsManager.getImageWidthCells(),
|
|
2590
|
+
}, this.getRegisteredToolDefinition(content.name), this.ui, this.sessionManager.getCwd());
|
|
2591
|
+
component.setExpanded(this.toolOutputExpanded);
|
|
2592
|
+
this.chatContainer.addChild(component);
|
|
2593
|
+
if (message.stopReason === "aborted" || message.stopReason === "error") {
|
|
2594
|
+
let errorMessage;
|
|
2595
|
+
if (message.stopReason === "aborted") {
|
|
2596
|
+
const retryAttempt = this.session.retryAttempt;
|
|
2597
|
+
errorMessage =
|
|
2598
|
+
retryAttempt > 0
|
|
2599
|
+
? `Aborted after ${retryAttempt} retry attempt${retryAttempt > 1 ? "s" : ""}`
|
|
2600
|
+
: "Operation aborted";
|
|
2601
|
+
}
|
|
2602
|
+
else {
|
|
2603
|
+
errorMessage = message.errorMessage || "Error";
|
|
2604
|
+
}
|
|
2605
|
+
component.updateResult({ content: [{ type: "text", text: errorMessage }], isError: true });
|
|
2606
|
+
}
|
|
2607
|
+
else {
|
|
2608
|
+
renderedPendingTools.set(content.id, component);
|
|
2609
|
+
}
|
|
2610
|
+
}
|
|
2611
|
+
}
|
|
2612
|
+
}
|
|
2613
|
+
else if (message.role === "toolResult") {
|
|
2614
|
+
// Match tool results to pending tool components
|
|
2615
|
+
const component = renderedPendingTools.get(message.toolCallId);
|
|
2616
|
+
if (component) {
|
|
2617
|
+
component.updateResult(message);
|
|
2618
|
+
renderedPendingTools.delete(message.toolCallId);
|
|
2619
|
+
}
|
|
2620
|
+
}
|
|
2621
|
+
else {
|
|
2622
|
+
// All other messages use standard rendering
|
|
2623
|
+
this.addMessageToChat(message, options);
|
|
2624
|
+
}
|
|
2625
|
+
}
|
|
2626
|
+
for (const [toolCallId, component] of renderedPendingTools) {
|
|
2627
|
+
this.pendingTools.set(toolCallId, component);
|
|
2628
|
+
}
|
|
2629
|
+
this.ui.requestRender();
|
|
2630
|
+
}
|
|
2631
|
+
renderInitialMessages() {
|
|
2632
|
+
// Get aligned messages and entries from session context
|
|
2633
|
+
const context = this.sessionManager.buildSessionContext();
|
|
2634
|
+
this.renderSessionContext(context, {
|
|
2635
|
+
updateFooter: true,
|
|
2636
|
+
populateHistory: true,
|
|
2637
|
+
});
|
|
2638
|
+
// Show compaction info if session was compacted
|
|
2639
|
+
const allEntries = this.sessionManager.getEntries();
|
|
2640
|
+
const compactionCount = allEntries.filter((e) => e.type === "compaction").length;
|
|
2641
|
+
if (compactionCount > 0) {
|
|
2642
|
+
const times = compactionCount === 1 ? "1 time" : `${compactionCount} times`;
|
|
2643
|
+
this.showStatus(`Session compacted ${times}`);
|
|
2644
|
+
}
|
|
2645
|
+
}
|
|
2646
|
+
async getUserInput() {
|
|
2647
|
+
return new Promise((resolve) => {
|
|
2648
|
+
this.onInputCallback = (text) => {
|
|
2649
|
+
this.onInputCallback = undefined;
|
|
2650
|
+
resolve(text);
|
|
2651
|
+
};
|
|
2652
|
+
});
|
|
2653
|
+
}
|
|
2654
|
+
rebuildChatFromMessages() {
|
|
2655
|
+
this.chatContainer.clear();
|
|
2656
|
+
const context = this.sessionManager.buildSessionContext();
|
|
2657
|
+
this.renderSessionContext(context);
|
|
2658
|
+
}
|
|
2659
|
+
// =========================================================================
|
|
2660
|
+
// Key handlers
|
|
2661
|
+
// =========================================================================
|
|
2662
|
+
handleCtrlC() {
|
|
2663
|
+
const now = Date.now();
|
|
2664
|
+
if (now - this.lastSigintTime < 500) {
|
|
2665
|
+
void this.shutdown();
|
|
2666
|
+
}
|
|
2667
|
+
else {
|
|
2668
|
+
this.clearEditor();
|
|
2669
|
+
this.lastSigintTime = now;
|
|
2670
|
+
}
|
|
2671
|
+
}
|
|
2672
|
+
handleCtrlD() {
|
|
2673
|
+
// Only called when editor is empty (enforced by CustomEditor)
|
|
2674
|
+
void this.shutdown();
|
|
2675
|
+
}
|
|
2676
|
+
/**
|
|
2677
|
+
* Gracefully shutdown the agent.
|
|
2678
|
+
* Stops the TUI before emitting shutdown events so extension UI cleanup cannot
|
|
2679
|
+
* repaint the final frame while the process is exiting.
|
|
2680
|
+
*/
|
|
2681
|
+
isShuttingDown = false;
|
|
2682
|
+
async shutdown() {
|
|
2683
|
+
if (this.isShuttingDown)
|
|
2684
|
+
return;
|
|
2685
|
+
this.isShuttingDown = true;
|
|
2686
|
+
this.unregisterSignalHandlers();
|
|
2687
|
+
// Drain any in-flight Kitty key release events before stopping.
|
|
2688
|
+
// This prevents escape sequences from leaking to the parent shell over slow SSH.
|
|
2689
|
+
await this.ui.terminal.drainInput(1000);
|
|
2690
|
+
this.stop();
|
|
2691
|
+
await this.runtimeHost.dispose();
|
|
2692
|
+
process.exit(0);
|
|
2693
|
+
}
|
|
2694
|
+
emergencyTerminalExit() {
|
|
2695
|
+
this.isShuttingDown = true;
|
|
2696
|
+
this.unregisterSignalHandlers();
|
|
2697
|
+
killTrackedDetachedChildren();
|
|
2698
|
+
// The terminal is gone. Do not run normal shutdown because TUI and
|
|
2699
|
+
// extension cleanup can write restore sequences and re-trigger EIO.
|
|
2700
|
+
process.exit(129);
|
|
2701
|
+
}
|
|
2702
|
+
/**
|
|
2703
|
+
* Last-resort handler for uncaught exceptions. The TUI puts stdin into raw
|
|
2704
|
+
* mode and hides the cursor; without this handler, an uncaught throw from
|
|
2705
|
+
* anywhere (e.g. an extension's async `ChildProcess.on("exit")` callback)
|
|
2706
|
+
* tears down the process while leaving the terminal in raw mode with no
|
|
2707
|
+
* cursor, requiring `stty sane && reset` to recover.
|
|
2708
|
+
*
|
|
2709
|
+
* Unlike emergencyTerminalExit, the terminal is still alive here, so we
|
|
2710
|
+
* call ui.stop() to restore cooked mode, the cursor, and disable bracketed
|
|
2711
|
+
* paste / Kitty / modifyOtherKeys sequences.
|
|
2712
|
+
*/
|
|
2713
|
+
uncaughtCrash(error) {
|
|
2714
|
+
if (this.isShuttingDown) {
|
|
2715
|
+
process.exit(1);
|
|
2716
|
+
}
|
|
2717
|
+
this.isShuttingDown = true;
|
|
2718
|
+
try {
|
|
2719
|
+
this.unregisterSignalHandlers();
|
|
2720
|
+
}
|
|
2721
|
+
catch { }
|
|
2722
|
+
try {
|
|
2723
|
+
killTrackedDetachedChildren();
|
|
2724
|
+
}
|
|
2725
|
+
catch { }
|
|
2726
|
+
try {
|
|
2727
|
+
this.ui.stop();
|
|
2728
|
+
}
|
|
2729
|
+
catch { }
|
|
2730
|
+
console.error("pi exiting due to uncaughtException:");
|
|
2731
|
+
console.error(error);
|
|
2732
|
+
process.exit(1);
|
|
2733
|
+
}
|
|
2734
|
+
/**
|
|
2735
|
+
* Check if shutdown was requested and perform shutdown if so.
|
|
2736
|
+
*/
|
|
2737
|
+
async checkShutdownRequested() {
|
|
2738
|
+
if (!this.shutdownRequested)
|
|
2739
|
+
return;
|
|
2740
|
+
await this.shutdown();
|
|
2741
|
+
}
|
|
2742
|
+
registerSignalHandlers() {
|
|
2743
|
+
this.unregisterSignalHandlers();
|
|
2744
|
+
const signals = ["SIGTERM"];
|
|
2745
|
+
if (process.platform !== "win32") {
|
|
2746
|
+
signals.push("SIGHUP");
|
|
2747
|
+
}
|
|
2748
|
+
for (const signal of signals) {
|
|
2749
|
+
const handler = () => {
|
|
2750
|
+
if (signal === "SIGHUP") {
|
|
2751
|
+
this.emergencyTerminalExit();
|
|
2752
|
+
}
|
|
2753
|
+
killTrackedDetachedChildren();
|
|
2754
|
+
void this.shutdown();
|
|
2755
|
+
};
|
|
2756
|
+
process.prependListener(signal, handler);
|
|
2757
|
+
this.signalCleanupHandlers.push(() => process.off(signal, handler));
|
|
2758
|
+
}
|
|
2759
|
+
const terminalErrorHandler = (error) => {
|
|
2760
|
+
if (isDeadTerminalError(error)) {
|
|
2761
|
+
this.emergencyTerminalExit();
|
|
2762
|
+
}
|
|
2763
|
+
throw error;
|
|
2764
|
+
};
|
|
2765
|
+
process.stdout.on("error", terminalErrorHandler);
|
|
2766
|
+
process.stderr.on("error", terminalErrorHandler);
|
|
2767
|
+
this.signalCleanupHandlers.push(() => process.stdout.off("error", terminalErrorHandler));
|
|
2768
|
+
this.signalCleanupHandlers.push(() => process.stderr.off("error", terminalErrorHandler));
|
|
2769
|
+
// Restore the terminal before the process dies on any uncaught throw.
|
|
2770
|
+
// Without this, an unhandled exception from extension code (or anywhere
|
|
2771
|
+
// in pi) leaves the terminal in raw mode with no cursor.
|
|
2772
|
+
const uncaughtExceptionHandler = (error) => this.uncaughtCrash(error);
|
|
2773
|
+
process.prependListener("uncaughtException", uncaughtExceptionHandler);
|
|
2774
|
+
this.signalCleanupHandlers.push(() => process.off("uncaughtException", uncaughtExceptionHandler));
|
|
2775
|
+
}
|
|
2776
|
+
unregisterSignalHandlers() {
|
|
2777
|
+
for (const cleanup of this.signalCleanupHandlers) {
|
|
2778
|
+
cleanup();
|
|
2779
|
+
}
|
|
2780
|
+
this.signalCleanupHandlers = [];
|
|
2781
|
+
}
|
|
2782
|
+
handleCtrlZ() {
|
|
2783
|
+
if (process.platform === "win32") {
|
|
2784
|
+
this.showStatus("Suspend to background is not supported on Windows");
|
|
2785
|
+
return;
|
|
2786
|
+
}
|
|
2787
|
+
// Keep the event loop alive while suspended. Without this, stopping the TUI
|
|
2788
|
+
// can leave Node with no ref'ed handles, causing the process to exit on fg
|
|
2789
|
+
// before the SIGCONT handler gets a chance to restore the terminal.
|
|
2790
|
+
const suspendKeepAlive = setInterval(() => { }, 2 ** 30);
|
|
2791
|
+
// Ignore SIGINT while suspended so Ctrl+C in the terminal does not
|
|
2792
|
+
// kill the backgrounded process. The handler is removed on resume.
|
|
2793
|
+
const ignoreSigint = () => { };
|
|
2794
|
+
process.on("SIGINT", ignoreSigint);
|
|
2795
|
+
// Set up handler to restore TUI when resumed
|
|
2796
|
+
process.once("SIGCONT", () => {
|
|
2797
|
+
clearInterval(suspendKeepAlive);
|
|
2798
|
+
process.removeListener("SIGINT", ignoreSigint);
|
|
2799
|
+
this.ui.start();
|
|
2800
|
+
this.ui.requestRender(true);
|
|
2801
|
+
});
|
|
2802
|
+
try {
|
|
2803
|
+
// Stop the TUI (restore terminal to normal mode)
|
|
2804
|
+
this.ui.stop();
|
|
2805
|
+
// Send SIGTSTP to process group (pid=0 means all processes in group)
|
|
2806
|
+
process.kill(0, "SIGTSTP");
|
|
2807
|
+
}
|
|
2808
|
+
catch (error) {
|
|
2809
|
+
clearInterval(suspendKeepAlive);
|
|
2810
|
+
process.removeListener("SIGINT", ignoreSigint);
|
|
2811
|
+
throw error;
|
|
2812
|
+
}
|
|
2813
|
+
}
|
|
2814
|
+
async handleFollowUp() {
|
|
2815
|
+
const text = (this.editor.getExpandedText?.() ?? this.editor.getText()).trim();
|
|
2816
|
+
if (!text)
|
|
2817
|
+
return;
|
|
2818
|
+
// Queue input during compaction (extension commands execute immediately)
|
|
2819
|
+
if (this.session.isCompacting) {
|
|
2820
|
+
if (this.isExtensionCommand(text)) {
|
|
2821
|
+
this.editor.addToHistory?.(text);
|
|
2822
|
+
this.editor.setText("");
|
|
2823
|
+
await this.session.prompt(text);
|
|
2824
|
+
}
|
|
2825
|
+
else {
|
|
2826
|
+
this.queueCompactionMessage(text, "followUp");
|
|
2827
|
+
}
|
|
2828
|
+
return;
|
|
2829
|
+
}
|
|
2830
|
+
// Alt+Enter queues a follow-up message (waits until agent finishes)
|
|
2831
|
+
// This handles extension commands (execute immediately), prompt template expansion, and queueing
|
|
2832
|
+
if (this.session.isStreaming) {
|
|
2833
|
+
this.editor.addToHistory?.(text);
|
|
2834
|
+
this.editor.setText("");
|
|
2835
|
+
await this.session.prompt(text, { streamingBehavior: "followUp" });
|
|
2836
|
+
this.updatePendingMessagesDisplay();
|
|
2837
|
+
this.ui.requestRender();
|
|
2838
|
+
}
|
|
2839
|
+
// If not streaming, Alt+Enter acts like regular Enter (trigger onSubmit)
|
|
2840
|
+
else if (this.editor.onSubmit) {
|
|
2841
|
+
this.editor.setText("");
|
|
2842
|
+
this.editor.onSubmit(text);
|
|
2843
|
+
}
|
|
2844
|
+
}
|
|
2845
|
+
handleDequeue() {
|
|
2846
|
+
const restored = this.restoreQueuedMessagesToEditor();
|
|
2847
|
+
if (restored === 0) {
|
|
2848
|
+
this.showStatus("No queued messages to restore");
|
|
2849
|
+
}
|
|
2850
|
+
else {
|
|
2851
|
+
this.showStatus(`Restored ${restored} queued message${restored > 1 ? "s" : ""} to editor`);
|
|
2852
|
+
}
|
|
2853
|
+
}
|
|
2854
|
+
updateEditorBorderColor() {
|
|
2855
|
+
if (this.isBashMode) {
|
|
2856
|
+
this.editor.borderColor = theme.getBashModeBorderColor();
|
|
2857
|
+
}
|
|
2858
|
+
else {
|
|
2859
|
+
const level = this.session.thinkingLevel || "off";
|
|
2860
|
+
this.editor.borderColor = theme.getThinkingBorderColor(level);
|
|
2861
|
+
}
|
|
2862
|
+
this.ui.requestRender();
|
|
2863
|
+
}
|
|
2864
|
+
cycleThinkingLevel() {
|
|
2865
|
+
const newLevel = this.session.cycleThinkingLevel();
|
|
2866
|
+
if (newLevel === undefined) {
|
|
2867
|
+
this.showStatus("Current model does not support thinking");
|
|
2868
|
+
}
|
|
2869
|
+
else {
|
|
2870
|
+
this.footer.invalidate();
|
|
2871
|
+
this.updateEditorBorderColor();
|
|
2872
|
+
this.showStatus(`Thinking level: ${newLevel}`);
|
|
2873
|
+
}
|
|
2874
|
+
}
|
|
2875
|
+
async cycleModel(direction) {
|
|
2876
|
+
try {
|
|
2877
|
+
const result = await this.session.cycleModel(direction);
|
|
2878
|
+
if (result === undefined) {
|
|
2879
|
+
const msg = this.session.scopedModels.length > 0 ? "Only one model in scope" : "Only one model available";
|
|
2880
|
+
this.showStatus(msg);
|
|
2881
|
+
}
|
|
2882
|
+
else {
|
|
2883
|
+
this.footer.invalidate();
|
|
2884
|
+
this.updateEditorBorderColor();
|
|
2885
|
+
const thinkingStr = result.model.reasoning && result.thinkingLevel !== "off" ? ` (thinking: ${result.thinkingLevel})` : "";
|
|
2886
|
+
this.showStatus(`Switched to ${result.model.name || result.model.id}${thinkingStr}`);
|
|
2887
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth(result.model);
|
|
2888
|
+
}
|
|
2889
|
+
}
|
|
2890
|
+
catch (error) {
|
|
2891
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
2892
|
+
}
|
|
2893
|
+
}
|
|
2894
|
+
toggleToolOutputExpansion() {
|
|
2895
|
+
this.setToolsExpanded(!this.toolOutputExpanded);
|
|
2896
|
+
}
|
|
2897
|
+
setToolsExpanded(expanded) {
|
|
2898
|
+
this.toolOutputExpanded = expanded;
|
|
2899
|
+
const activeHeader = this.customHeader ?? this.builtInHeader;
|
|
2900
|
+
if (isExpandable(activeHeader)) {
|
|
2901
|
+
activeHeader.setExpanded(expanded);
|
|
2902
|
+
}
|
|
2903
|
+
for (const child of this.chatContainer.children) {
|
|
2904
|
+
if (isExpandable(child)) {
|
|
2905
|
+
child.setExpanded(expanded);
|
|
2906
|
+
}
|
|
2907
|
+
}
|
|
2908
|
+
this.ui.requestRender();
|
|
2909
|
+
}
|
|
2910
|
+
toggleThinkingBlockVisibility() {
|
|
2911
|
+
this.hideThinkingBlock = !this.hideThinkingBlock;
|
|
2912
|
+
this.settingsManager.setHideThinkingBlock(this.hideThinkingBlock);
|
|
2913
|
+
// Rebuild chat from session messages
|
|
2914
|
+
this.chatContainer.clear();
|
|
2915
|
+
this.rebuildChatFromMessages();
|
|
2916
|
+
// If streaming, re-add the streaming component with updated visibility and re-render
|
|
2917
|
+
if (this.streamingComponent && this.streamingMessage) {
|
|
2918
|
+
this.streamingComponent.setHideThinkingBlock(this.hideThinkingBlock);
|
|
2919
|
+
this.streamingComponent.updateContent(this.streamingMessage);
|
|
2920
|
+
this.chatContainer.addChild(this.streamingComponent);
|
|
2921
|
+
}
|
|
2922
|
+
this.showStatus(`Thinking blocks: ${this.hideThinkingBlock ? "hidden" : "visible"}`);
|
|
2923
|
+
}
|
|
2924
|
+
openExternalEditor() {
|
|
2925
|
+
// Determine editor (respect $VISUAL, then $EDITOR)
|
|
2926
|
+
const editorCmd = process.env.VISUAL || process.env.EDITOR;
|
|
2927
|
+
if (!editorCmd) {
|
|
2928
|
+
this.showWarning("No editor configured. Set $VISUAL or $EDITOR environment variable.");
|
|
2929
|
+
return;
|
|
2930
|
+
}
|
|
2931
|
+
const currentText = this.editor.getExpandedText?.() ?? this.editor.getText();
|
|
2932
|
+
const tmpFile = path.join(os.tmpdir(), `pi-editor-${Date.now()}.pi.md`);
|
|
2933
|
+
try {
|
|
2934
|
+
// Write current content to temp file
|
|
2935
|
+
fs.writeFileSync(tmpFile, currentText, "utf-8");
|
|
2936
|
+
// Stop TUI to release terminal
|
|
2937
|
+
this.ui.stop();
|
|
2938
|
+
// Split by space to support editor arguments (e.g., "code --wait")
|
|
2939
|
+
const [editor, ...editorArgs] = editorCmd.split(" ");
|
|
2940
|
+
// Spawn editor synchronously with inherited stdio for interactive editing
|
|
2941
|
+
const result = spawnSync(editor, [...editorArgs, tmpFile], {
|
|
2942
|
+
stdio: "inherit",
|
|
2943
|
+
shell: process.platform === "win32",
|
|
2944
|
+
});
|
|
2945
|
+
// On successful exit (status 0), replace editor content
|
|
2946
|
+
if (result.status === 0) {
|
|
2947
|
+
const newContent = fs.readFileSync(tmpFile, "utf-8").replace(/\n$/, "");
|
|
2948
|
+
this.editor.setText(newContent);
|
|
2949
|
+
}
|
|
2950
|
+
// On non-zero exit, keep original text (no action needed)
|
|
2951
|
+
}
|
|
2952
|
+
finally {
|
|
2953
|
+
// Clean up temp file
|
|
2954
|
+
try {
|
|
2955
|
+
fs.unlinkSync(tmpFile);
|
|
2956
|
+
}
|
|
2957
|
+
catch {
|
|
2958
|
+
// Ignore cleanup errors
|
|
2959
|
+
}
|
|
2960
|
+
// Restart TUI
|
|
2961
|
+
this.ui.start();
|
|
2962
|
+
// Force full re-render since external editor uses alternate screen
|
|
2963
|
+
this.ui.requestRender(true);
|
|
2964
|
+
}
|
|
2965
|
+
}
|
|
2966
|
+
// =========================================================================
|
|
2967
|
+
// UI helpers
|
|
2968
|
+
// =========================================================================
|
|
2969
|
+
clearEditor() {
|
|
2970
|
+
this.editor.setText("");
|
|
2971
|
+
this.ui.requestRender();
|
|
2972
|
+
}
|
|
2973
|
+
showError(errorMessage) {
|
|
2974
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2975
|
+
this.chatContainer.addChild(new Text(theme.fg("error", `Error: ${errorMessage}`), 1, 0));
|
|
2976
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2977
|
+
this.ui.requestRender();
|
|
2978
|
+
}
|
|
2979
|
+
showWarning(warningMessage) {
|
|
2980
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2981
|
+
this.chatContainer.addChild(new Text(theme.fg("warning", `Warning: ${warningMessage}`), 1, 0));
|
|
2982
|
+
this.ui.requestRender();
|
|
2983
|
+
}
|
|
2984
|
+
showNewVersionNotification(newVersion) {
|
|
2985
|
+
const action = theme.fg("accent", `${APP_NAME} update`);
|
|
2986
|
+
const updateInstruction = theme.fg("muted", `New version ${newVersion} is available. Run `) + action;
|
|
2987
|
+
const changelogUrl = "https://github.com/earendil-works/pi-mono/blob/main/packages/coding-agent/CHANGELOG.md";
|
|
2988
|
+
const changelogLink = getCapabilities().hyperlinks
|
|
2989
|
+
? hyperlink(theme.fg("accent", "open changelog"), changelogUrl)
|
|
2990
|
+
: theme.fg("accent", changelogUrl);
|
|
2991
|
+
const changelogLine = theme.fg("muted", "Changelog: ") + changelogLink;
|
|
2992
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
2993
|
+
this.chatContainer.addChild(new DynamicBorder((text) => theme.fg("warning", text)));
|
|
2994
|
+
this.chatContainer.addChild(new Text(`${theme.bold(theme.fg("warning", "Update Available"))}\n${updateInstruction}\n${changelogLine}`, 1, 0));
|
|
2995
|
+
this.chatContainer.addChild(new DynamicBorder((text) => theme.fg("warning", text)));
|
|
2996
|
+
this.ui.requestRender();
|
|
2997
|
+
}
|
|
2998
|
+
showPackageUpdateNotification(packages) {
|
|
2999
|
+
const action = theme.fg("accent", `${APP_NAME} update`);
|
|
3000
|
+
const updateInstruction = theme.fg("muted", "Package updates are available. Run ") + action;
|
|
3001
|
+
const packageLines = packages.map((pkg) => `- ${pkg}`).join("\n");
|
|
3002
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
3003
|
+
this.chatContainer.addChild(new DynamicBorder((text) => theme.fg("warning", text)));
|
|
3004
|
+
this.chatContainer.addChild(new Text(`${theme.bold(theme.fg("warning", "Package Updates Available"))}\n${updateInstruction}\n${theme.fg("muted", "Packages:")}\n${packageLines}`, 1, 0));
|
|
3005
|
+
this.chatContainer.addChild(new DynamicBorder((text) => theme.fg("warning", text)));
|
|
3006
|
+
this.ui.requestRender();
|
|
3007
|
+
}
|
|
3008
|
+
/**
|
|
3009
|
+
* Get all queued messages (read-only).
|
|
3010
|
+
* Combines session queue and compaction queue.
|
|
3011
|
+
*/
|
|
3012
|
+
getAllQueuedMessages() {
|
|
3013
|
+
return {
|
|
3014
|
+
steering: [
|
|
3015
|
+
...this.session.getSteeringMessages(),
|
|
3016
|
+
...this.compactionQueuedMessages.filter((msg) => msg.mode === "steer").map((msg) => msg.text),
|
|
3017
|
+
],
|
|
3018
|
+
followUp: [
|
|
3019
|
+
...this.session.getFollowUpMessages(),
|
|
3020
|
+
...this.compactionQueuedMessages.filter((msg) => msg.mode === "followUp").map((msg) => msg.text),
|
|
3021
|
+
],
|
|
3022
|
+
};
|
|
3023
|
+
}
|
|
3024
|
+
/**
|
|
3025
|
+
* Clear all queued messages and return their contents.
|
|
3026
|
+
* Clears both session queue and compaction queue.
|
|
3027
|
+
*/
|
|
3028
|
+
clearAllQueues() {
|
|
3029
|
+
const { steering, followUp } = this.session.clearQueue();
|
|
3030
|
+
const compactionSteering = this.compactionQueuedMessages
|
|
3031
|
+
.filter((msg) => msg.mode === "steer")
|
|
3032
|
+
.map((msg) => msg.text);
|
|
3033
|
+
const compactionFollowUp = this.compactionQueuedMessages
|
|
3034
|
+
.filter((msg) => msg.mode === "followUp")
|
|
3035
|
+
.map((msg) => msg.text);
|
|
3036
|
+
this.compactionQueuedMessages = [];
|
|
3037
|
+
return {
|
|
3038
|
+
steering: [...steering, ...compactionSteering],
|
|
3039
|
+
followUp: [...followUp, ...compactionFollowUp],
|
|
3040
|
+
};
|
|
3041
|
+
}
|
|
3042
|
+
updatePendingMessagesDisplay() {
|
|
3043
|
+
this.pendingMessagesContainer.clear();
|
|
3044
|
+
const { steering: steeringMessages, followUp: followUpMessages } = this.getAllQueuedMessages();
|
|
3045
|
+
if (steeringMessages.length > 0 || followUpMessages.length > 0) {
|
|
3046
|
+
this.pendingMessagesContainer.addChild(new Spacer(1));
|
|
3047
|
+
for (const message of steeringMessages) {
|
|
3048
|
+
const text = theme.fg("dim", `Steering: ${message}`);
|
|
3049
|
+
this.pendingMessagesContainer.addChild(new TruncatedText(text, 1, 0));
|
|
3050
|
+
}
|
|
3051
|
+
for (const message of followUpMessages) {
|
|
3052
|
+
const text = theme.fg("dim", `Follow-up: ${message}`);
|
|
3053
|
+
this.pendingMessagesContainer.addChild(new TruncatedText(text, 1, 0));
|
|
3054
|
+
}
|
|
3055
|
+
const dequeueHint = this.getAppKeyDisplay("app.message.dequeue");
|
|
3056
|
+
const hintText = theme.fg("dim", `↳ ${dequeueHint} to edit all queued messages`);
|
|
3057
|
+
this.pendingMessagesContainer.addChild(new TruncatedText(hintText, 1, 0));
|
|
3058
|
+
}
|
|
3059
|
+
}
|
|
3060
|
+
restoreQueuedMessagesToEditor(options) {
|
|
3061
|
+
const { steering, followUp } = this.clearAllQueues();
|
|
3062
|
+
const allQueued = [...steering, ...followUp];
|
|
3063
|
+
if (allQueued.length === 0) {
|
|
3064
|
+
this.updatePendingMessagesDisplay();
|
|
3065
|
+
if (options?.abort) {
|
|
3066
|
+
this.agent.abort();
|
|
3067
|
+
}
|
|
3068
|
+
return 0;
|
|
3069
|
+
}
|
|
3070
|
+
const queuedText = allQueued.join("\n\n");
|
|
3071
|
+
const currentText = options?.currentText ?? this.editor.getText();
|
|
3072
|
+
const combinedText = [queuedText, currentText].filter((t) => t.trim()).join("\n\n");
|
|
3073
|
+
this.editor.setText(combinedText);
|
|
3074
|
+
this.updatePendingMessagesDisplay();
|
|
3075
|
+
if (options?.abort) {
|
|
3076
|
+
this.agent.abort();
|
|
3077
|
+
}
|
|
3078
|
+
return allQueued.length;
|
|
3079
|
+
}
|
|
3080
|
+
queueCompactionMessage(text, mode) {
|
|
3081
|
+
this.compactionQueuedMessages.push({ text, mode });
|
|
3082
|
+
this.editor.addToHistory?.(text);
|
|
3083
|
+
this.editor.setText("");
|
|
3084
|
+
this.updatePendingMessagesDisplay();
|
|
3085
|
+
this.showStatus("Queued message for after compaction");
|
|
3086
|
+
}
|
|
3087
|
+
isExtensionCommand(text) {
|
|
3088
|
+
if (!text.startsWith("/"))
|
|
3089
|
+
return false;
|
|
3090
|
+
const extensionRunner = this.session.extensionRunner;
|
|
3091
|
+
const spaceIndex = text.indexOf(" ");
|
|
3092
|
+
const commandName = spaceIndex === -1 ? text.slice(1) : text.slice(1, spaceIndex);
|
|
3093
|
+
return !!extensionRunner.getCommand(commandName);
|
|
3094
|
+
}
|
|
3095
|
+
async flushCompactionQueue(options) {
|
|
3096
|
+
if (this.compactionQueuedMessages.length === 0) {
|
|
3097
|
+
return;
|
|
3098
|
+
}
|
|
3099
|
+
const queuedMessages = [...this.compactionQueuedMessages];
|
|
3100
|
+
this.compactionQueuedMessages = [];
|
|
3101
|
+
this.updatePendingMessagesDisplay();
|
|
3102
|
+
const restoreQueue = (error) => {
|
|
3103
|
+
this.session.clearQueue();
|
|
3104
|
+
this.compactionQueuedMessages = queuedMessages;
|
|
3105
|
+
this.updatePendingMessagesDisplay();
|
|
3106
|
+
this.showError(`Failed to send queued message${queuedMessages.length > 1 ? "s" : ""}: ${error instanceof Error ? error.message : String(error)}`);
|
|
3107
|
+
};
|
|
3108
|
+
try {
|
|
3109
|
+
if (options?.willRetry) {
|
|
3110
|
+
// When retry is pending, queue messages for the retry turn
|
|
3111
|
+
for (const message of queuedMessages) {
|
|
3112
|
+
if (this.isExtensionCommand(message.text)) {
|
|
3113
|
+
await this.session.prompt(message.text);
|
|
3114
|
+
}
|
|
3115
|
+
else if (message.mode === "followUp") {
|
|
3116
|
+
await this.session.followUp(message.text);
|
|
3117
|
+
}
|
|
3118
|
+
else {
|
|
3119
|
+
await this.session.steer(message.text);
|
|
3120
|
+
}
|
|
3121
|
+
}
|
|
3122
|
+
this.updatePendingMessagesDisplay();
|
|
3123
|
+
return;
|
|
3124
|
+
}
|
|
3125
|
+
// Find first non-extension-command message to use as prompt
|
|
3126
|
+
const firstPromptIndex = queuedMessages.findIndex((message) => !this.isExtensionCommand(message.text));
|
|
3127
|
+
if (firstPromptIndex === -1) {
|
|
3128
|
+
// All extension commands - execute them all
|
|
3129
|
+
for (const message of queuedMessages) {
|
|
3130
|
+
await this.session.prompt(message.text);
|
|
3131
|
+
}
|
|
3132
|
+
return;
|
|
3133
|
+
}
|
|
3134
|
+
// Execute any extension commands before the first prompt
|
|
3135
|
+
const preCommands = queuedMessages.slice(0, firstPromptIndex);
|
|
3136
|
+
const firstPrompt = queuedMessages[firstPromptIndex];
|
|
3137
|
+
const rest = queuedMessages.slice(firstPromptIndex + 1);
|
|
3138
|
+
for (const message of preCommands) {
|
|
3139
|
+
await this.session.prompt(message.text);
|
|
3140
|
+
}
|
|
3141
|
+
// Send first prompt (starts streaming)
|
|
3142
|
+
const promptPromise = this.session.prompt(firstPrompt.text).catch((error) => {
|
|
3143
|
+
restoreQueue(error);
|
|
3144
|
+
});
|
|
3145
|
+
// Queue remaining messages
|
|
3146
|
+
for (const message of rest) {
|
|
3147
|
+
if (this.isExtensionCommand(message.text)) {
|
|
3148
|
+
await this.session.prompt(message.text);
|
|
3149
|
+
}
|
|
3150
|
+
else if (message.mode === "followUp") {
|
|
3151
|
+
await this.session.followUp(message.text);
|
|
3152
|
+
}
|
|
3153
|
+
else {
|
|
3154
|
+
await this.session.steer(message.text);
|
|
3155
|
+
}
|
|
3156
|
+
}
|
|
3157
|
+
this.updatePendingMessagesDisplay();
|
|
3158
|
+
void promptPromise;
|
|
3159
|
+
}
|
|
3160
|
+
catch (error) {
|
|
3161
|
+
restoreQueue(error);
|
|
3162
|
+
}
|
|
3163
|
+
}
|
|
3164
|
+
/** Move pending bash components from pending area to chat */
|
|
3165
|
+
flushPendingBashComponents() {
|
|
3166
|
+
for (const component of this.pendingBashComponents) {
|
|
3167
|
+
this.pendingMessagesContainer.removeChild(component);
|
|
3168
|
+
this.chatContainer.addChild(component);
|
|
3169
|
+
}
|
|
3170
|
+
this.pendingBashComponents = [];
|
|
3171
|
+
}
|
|
3172
|
+
// =========================================================================
|
|
3173
|
+
// Selectors
|
|
3174
|
+
// =========================================================================
|
|
3175
|
+
/**
|
|
3176
|
+
* Shows a selector component in place of the editor.
|
|
3177
|
+
* @param create Factory that receives a `done` callback and returns the component and focus target
|
|
3178
|
+
*/
|
|
3179
|
+
showSelector(create) {
|
|
3180
|
+
const done = () => {
|
|
3181
|
+
this.editorContainer.clear();
|
|
3182
|
+
this.editorContainer.addChild(this.editor);
|
|
3183
|
+
this.ui.setFocus(this.editor);
|
|
3184
|
+
};
|
|
3185
|
+
const { component, focus } = create(done);
|
|
3186
|
+
this.editorContainer.clear();
|
|
3187
|
+
this.editorContainer.addChild(component);
|
|
3188
|
+
this.ui.setFocus(focus);
|
|
3189
|
+
this.ui.requestRender();
|
|
3190
|
+
}
|
|
3191
|
+
showSettingsSelector() {
|
|
3192
|
+
this.showSelector((done) => {
|
|
3193
|
+
const selector = new SettingsSelectorComponent({
|
|
3194
|
+
autoCompact: this.session.autoCompactionEnabled,
|
|
3195
|
+
showImages: this.settingsManager.getShowImages(),
|
|
3196
|
+
imageWidthCells: this.settingsManager.getImageWidthCells(),
|
|
3197
|
+
autoResizeImages: this.settingsManager.getImageAutoResize(),
|
|
3198
|
+
blockImages: this.settingsManager.getBlockImages(),
|
|
3199
|
+
enableSkillCommands: this.settingsManager.getEnableSkillCommands(),
|
|
3200
|
+
steeringMode: this.session.steeringMode,
|
|
3201
|
+
followUpMode: this.session.followUpMode,
|
|
3202
|
+
transport: this.settingsManager.getTransport(),
|
|
3203
|
+
thinkingLevel: this.session.thinkingLevel,
|
|
3204
|
+
availableThinkingLevels: this.session.getAvailableThinkingLevels(),
|
|
3205
|
+
currentTheme: this.settingsManager.getTheme() || "dark",
|
|
3206
|
+
availableThemes: getAvailableThemes(),
|
|
3207
|
+
hideThinkingBlock: this.hideThinkingBlock,
|
|
3208
|
+
collapseChangelog: this.settingsManager.getCollapseChangelog(),
|
|
3209
|
+
enableInstallTelemetry: this.settingsManager.getEnableInstallTelemetry(),
|
|
3210
|
+
doubleEscapeAction: this.settingsManager.getDoubleEscapeAction(),
|
|
3211
|
+
treeFilterMode: this.settingsManager.getTreeFilterMode(),
|
|
3212
|
+
showHardwareCursor: this.settingsManager.getShowHardwareCursor(),
|
|
3213
|
+
editorPaddingX: this.settingsManager.getEditorPaddingX(),
|
|
3214
|
+
autocompleteMaxVisible: this.settingsManager.getAutocompleteMaxVisible(),
|
|
3215
|
+
quietStartup: this.settingsManager.getQuietStartup(),
|
|
3216
|
+
clearOnShrink: this.settingsManager.getClearOnShrink(),
|
|
3217
|
+
showTerminalProgress: this.settingsManager.getShowTerminalProgress(),
|
|
3218
|
+
warnings: this.settingsManager.getWarnings(),
|
|
3219
|
+
}, {
|
|
3220
|
+
onAutoCompactChange: (enabled) => {
|
|
3221
|
+
this.session.setAutoCompactionEnabled(enabled);
|
|
3222
|
+
this.footer.setAutoCompactEnabled(enabled);
|
|
3223
|
+
},
|
|
3224
|
+
onShowImagesChange: (enabled) => {
|
|
3225
|
+
this.settingsManager.setShowImages(enabled);
|
|
3226
|
+
for (const child of this.chatContainer.children) {
|
|
3227
|
+
if (child instanceof ToolExecutionComponent) {
|
|
3228
|
+
child.setShowImages(enabled);
|
|
3229
|
+
}
|
|
3230
|
+
}
|
|
3231
|
+
},
|
|
3232
|
+
onImageWidthCellsChange: (width) => {
|
|
3233
|
+
this.settingsManager.setImageWidthCells(width);
|
|
3234
|
+
for (const child of this.chatContainer.children) {
|
|
3235
|
+
if (child instanceof ToolExecutionComponent) {
|
|
3236
|
+
child.setImageWidthCells(width);
|
|
3237
|
+
}
|
|
3238
|
+
}
|
|
3239
|
+
},
|
|
3240
|
+
onAutoResizeImagesChange: (enabled) => {
|
|
3241
|
+
this.settingsManager.setImageAutoResize(enabled);
|
|
3242
|
+
},
|
|
3243
|
+
onBlockImagesChange: (blocked) => {
|
|
3244
|
+
this.settingsManager.setBlockImages(blocked);
|
|
3245
|
+
},
|
|
3246
|
+
onEnableSkillCommandsChange: (enabled) => {
|
|
3247
|
+
this.settingsManager.setEnableSkillCommands(enabled);
|
|
3248
|
+
this.setupAutocompleteProvider();
|
|
3249
|
+
},
|
|
3250
|
+
onSteeringModeChange: (mode) => {
|
|
3251
|
+
this.session.setSteeringMode(mode);
|
|
3252
|
+
},
|
|
3253
|
+
onFollowUpModeChange: (mode) => {
|
|
3254
|
+
this.session.setFollowUpMode(mode);
|
|
3255
|
+
},
|
|
3256
|
+
onTransportChange: (transport) => {
|
|
3257
|
+
this.settingsManager.setTransport(transport);
|
|
3258
|
+
this.session.agent.transport = transport;
|
|
3259
|
+
},
|
|
3260
|
+
onThinkingLevelChange: (level) => {
|
|
3261
|
+
this.session.setThinkingLevel(level);
|
|
3262
|
+
this.footer.invalidate();
|
|
3263
|
+
this.updateEditorBorderColor();
|
|
3264
|
+
},
|
|
3265
|
+
onThemeChange: (themeName) => {
|
|
3266
|
+
const result = setTheme(themeName, true);
|
|
3267
|
+
this.settingsManager.setTheme(themeName);
|
|
3268
|
+
this.ui.invalidate();
|
|
3269
|
+
if (!result.success) {
|
|
3270
|
+
this.showError(`Failed to load theme "${themeName}": ${result.error}\nFell back to dark theme.`);
|
|
3271
|
+
}
|
|
3272
|
+
},
|
|
3273
|
+
onThemePreview: (themeName) => {
|
|
3274
|
+
const result = setTheme(themeName, true);
|
|
3275
|
+
if (result.success) {
|
|
3276
|
+
this.ui.invalidate();
|
|
3277
|
+
this.ui.requestRender();
|
|
3278
|
+
}
|
|
3279
|
+
},
|
|
3280
|
+
onHideThinkingBlockChange: (hidden) => {
|
|
3281
|
+
this.hideThinkingBlock = hidden;
|
|
3282
|
+
this.settingsManager.setHideThinkingBlock(hidden);
|
|
3283
|
+
for (const child of this.chatContainer.children) {
|
|
3284
|
+
if (child instanceof AssistantMessageComponent) {
|
|
3285
|
+
child.setHideThinkingBlock(hidden);
|
|
3286
|
+
}
|
|
3287
|
+
}
|
|
3288
|
+
this.chatContainer.clear();
|
|
3289
|
+
this.rebuildChatFromMessages();
|
|
3290
|
+
},
|
|
3291
|
+
onCollapseChangelogChange: (collapsed) => {
|
|
3292
|
+
this.settingsManager.setCollapseChangelog(collapsed);
|
|
3293
|
+
},
|
|
3294
|
+
onEnableInstallTelemetryChange: (enabled) => {
|
|
3295
|
+
this.settingsManager.setEnableInstallTelemetry(enabled);
|
|
3296
|
+
},
|
|
3297
|
+
onQuietStartupChange: (enabled) => {
|
|
3298
|
+
this.settingsManager.setQuietStartup(enabled);
|
|
3299
|
+
},
|
|
3300
|
+
onDoubleEscapeActionChange: (action) => {
|
|
3301
|
+
this.settingsManager.setDoubleEscapeAction(action);
|
|
3302
|
+
},
|
|
3303
|
+
onTreeFilterModeChange: (mode) => {
|
|
3304
|
+
this.settingsManager.setTreeFilterMode(mode);
|
|
3305
|
+
},
|
|
3306
|
+
onShowHardwareCursorChange: (enabled) => {
|
|
3307
|
+
this.settingsManager.setShowHardwareCursor(enabled);
|
|
3308
|
+
this.ui.setShowHardwareCursor(enabled);
|
|
3309
|
+
},
|
|
3310
|
+
onEditorPaddingXChange: (padding) => {
|
|
3311
|
+
this.settingsManager.setEditorPaddingX(padding);
|
|
3312
|
+
this.defaultEditor.setPaddingX(padding);
|
|
3313
|
+
if (this.editor !== this.defaultEditor && this.editor.setPaddingX !== undefined) {
|
|
3314
|
+
this.editor.setPaddingX(padding);
|
|
3315
|
+
}
|
|
3316
|
+
},
|
|
3317
|
+
onAutocompleteMaxVisibleChange: (maxVisible) => {
|
|
3318
|
+
this.settingsManager.setAutocompleteMaxVisible(maxVisible);
|
|
3319
|
+
this.defaultEditor.setAutocompleteMaxVisible(maxVisible);
|
|
3320
|
+
if (this.editor !== this.defaultEditor && this.editor.setAutocompleteMaxVisible !== undefined) {
|
|
3321
|
+
this.editor.setAutocompleteMaxVisible(maxVisible);
|
|
3322
|
+
}
|
|
3323
|
+
},
|
|
3324
|
+
onClearOnShrinkChange: (enabled) => {
|
|
3325
|
+
this.settingsManager.setClearOnShrink(enabled);
|
|
3326
|
+
this.ui.setClearOnShrink(enabled);
|
|
3327
|
+
},
|
|
3328
|
+
onShowTerminalProgressChange: (enabled) => {
|
|
3329
|
+
this.settingsManager.setShowTerminalProgress(enabled);
|
|
3330
|
+
},
|
|
3331
|
+
onWarningsChange: (warnings) => {
|
|
3332
|
+
this.settingsManager.setWarnings(warnings);
|
|
3333
|
+
},
|
|
3334
|
+
onCancel: () => {
|
|
3335
|
+
done();
|
|
3336
|
+
this.ui.requestRender();
|
|
3337
|
+
},
|
|
3338
|
+
});
|
|
3339
|
+
return { component: selector, focus: selector.getSettingsList() };
|
|
3340
|
+
});
|
|
3341
|
+
}
|
|
3342
|
+
async handleModelCommand(searchTerm) {
|
|
3343
|
+
if (!searchTerm) {
|
|
3344
|
+
this.showModelSelector();
|
|
3345
|
+
return;
|
|
3346
|
+
}
|
|
3347
|
+
const model = await this.findExactModelMatch(searchTerm);
|
|
3348
|
+
if (model) {
|
|
3349
|
+
try {
|
|
3350
|
+
await this.session.setModel(model);
|
|
3351
|
+
this.footer.invalidate();
|
|
3352
|
+
this.updateEditorBorderColor();
|
|
3353
|
+
this.showStatus(`Model: ${model.id}`);
|
|
3354
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth(model);
|
|
3355
|
+
this.checkDaxnutsEasterEgg(model);
|
|
3356
|
+
}
|
|
3357
|
+
catch (error) {
|
|
3358
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
3359
|
+
}
|
|
3360
|
+
return;
|
|
3361
|
+
}
|
|
3362
|
+
this.showModelSelector(searchTerm);
|
|
3363
|
+
}
|
|
3364
|
+
async findExactModelMatch(searchTerm) {
|
|
3365
|
+
const models = await this.getModelCandidates();
|
|
3366
|
+
return findExactModelReferenceMatch(searchTerm, models);
|
|
3367
|
+
}
|
|
3368
|
+
async getModelCandidates() {
|
|
3369
|
+
if (this.session.scopedModels.length > 0) {
|
|
3370
|
+
return this.session.scopedModels.map((scoped) => scoped.model);
|
|
3371
|
+
}
|
|
3372
|
+
this.session.modelRegistry.refresh();
|
|
3373
|
+
try {
|
|
3374
|
+
return await this.session.modelRegistry.getAvailable();
|
|
3375
|
+
}
|
|
3376
|
+
catch {
|
|
3377
|
+
return [];
|
|
3378
|
+
}
|
|
3379
|
+
}
|
|
3380
|
+
/** Update the footer's available provider count from current model candidates */
|
|
3381
|
+
async updateAvailableProviderCount() {
|
|
3382
|
+
const models = await this.getModelCandidates();
|
|
3383
|
+
const uniqueProviders = new Set(models.map((m) => m.provider));
|
|
3384
|
+
this.footerDataProvider.setAvailableProviderCount(uniqueProviders.size);
|
|
3385
|
+
}
|
|
3386
|
+
async maybeWarnAboutAnthropicSubscriptionAuth(model = this.session.model) {
|
|
3387
|
+
if (this.settingsManager.getWarnings().anthropicExtraUsage === false) {
|
|
3388
|
+
return;
|
|
3389
|
+
}
|
|
3390
|
+
if (this.anthropicSubscriptionWarningShown) {
|
|
3391
|
+
return;
|
|
3392
|
+
}
|
|
3393
|
+
if (!model || model.provider !== "anthropic") {
|
|
3394
|
+
return;
|
|
3395
|
+
}
|
|
3396
|
+
const storedCredential = this.session.modelRegistry.authStorage.get("anthropic");
|
|
3397
|
+
if (storedCredential?.type === "oauth") {
|
|
3398
|
+
this.anthropicSubscriptionWarningShown = true;
|
|
3399
|
+
this.showWarning(ANTHROPIC_SUBSCRIPTION_AUTH_WARNING);
|
|
3400
|
+
return;
|
|
3401
|
+
}
|
|
3402
|
+
try {
|
|
3403
|
+
const apiKey = await this.session.modelRegistry.getApiKeyForProvider(model.provider);
|
|
3404
|
+
if (!isAnthropicSubscriptionAuthKey(apiKey)) {
|
|
3405
|
+
return;
|
|
3406
|
+
}
|
|
3407
|
+
this.anthropicSubscriptionWarningShown = true;
|
|
3408
|
+
this.showWarning(ANTHROPIC_SUBSCRIPTION_AUTH_WARNING);
|
|
3409
|
+
}
|
|
3410
|
+
catch {
|
|
3411
|
+
// Ignore auth lookup failures for warning-only checks.
|
|
3412
|
+
}
|
|
3413
|
+
}
|
|
3414
|
+
showModelSelector(initialSearchInput) {
|
|
3415
|
+
this.showSelector((done) => {
|
|
3416
|
+
const selector = new ModelSelectorComponent(this.ui, this.session.model, this.settingsManager, this.session.modelRegistry, this.session.scopedModels, async (model) => {
|
|
3417
|
+
try {
|
|
3418
|
+
await this.session.setModel(model);
|
|
3419
|
+
this.footer.invalidate();
|
|
3420
|
+
this.updateEditorBorderColor();
|
|
3421
|
+
done();
|
|
3422
|
+
this.showStatus(`Model: ${model.id}`);
|
|
3423
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth(model);
|
|
3424
|
+
this.checkDaxnutsEasterEgg(model);
|
|
3425
|
+
}
|
|
3426
|
+
catch (error) {
|
|
3427
|
+
done();
|
|
3428
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
3429
|
+
}
|
|
3430
|
+
}, () => {
|
|
3431
|
+
done();
|
|
3432
|
+
this.ui.requestRender();
|
|
3433
|
+
}, initialSearchInput);
|
|
3434
|
+
return { component: selector, focus: selector };
|
|
3435
|
+
});
|
|
3436
|
+
}
|
|
3437
|
+
async showModelsSelector() {
|
|
3438
|
+
// Get all available models
|
|
3439
|
+
this.session.modelRegistry.refresh();
|
|
3440
|
+
const allModels = this.session.modelRegistry.getAvailable();
|
|
3441
|
+
if (allModels.length === 0) {
|
|
3442
|
+
this.showStatus("No models available");
|
|
3443
|
+
return;
|
|
3444
|
+
}
|
|
3445
|
+
// Check if session has scoped models (from previous session-only changes or CLI --models)
|
|
3446
|
+
const sessionScopedModels = this.session.scopedModels;
|
|
3447
|
+
const hasSessionScope = sessionScopedModels.length > 0;
|
|
3448
|
+
// Build enabled model IDs from session state or settings
|
|
3449
|
+
let currentEnabledIds = null;
|
|
3450
|
+
if (hasSessionScope) {
|
|
3451
|
+
// Use current session's scoped models
|
|
3452
|
+
currentEnabledIds = sessionScopedModels.map((scoped) => `${scoped.model.provider}/${scoped.model.id}`);
|
|
3453
|
+
}
|
|
3454
|
+
else {
|
|
3455
|
+
// Fall back to settings
|
|
3456
|
+
const patterns = this.settingsManager.getEnabledModels();
|
|
3457
|
+
if (patterns !== undefined && patterns.length > 0) {
|
|
3458
|
+
const scopedModels = await resolveModelScope(patterns, this.session.modelRegistry);
|
|
3459
|
+
currentEnabledIds = scopedModels.map((scoped) => `${scoped.model.provider}/${scoped.model.id}`);
|
|
3460
|
+
}
|
|
3461
|
+
}
|
|
3462
|
+
// Helper to update session's scoped models (session-only, no persist)
|
|
3463
|
+
const updateSessionModels = async (enabledIds) => {
|
|
3464
|
+
currentEnabledIds = enabledIds === null ? null : [...enabledIds];
|
|
3465
|
+
if (enabledIds && enabledIds.length > 0 && enabledIds.length < allModels.length) {
|
|
3466
|
+
const newScopedModels = await resolveModelScope(enabledIds, this.session.modelRegistry);
|
|
3467
|
+
this.session.setScopedModels(newScopedModels.map((sm) => ({
|
|
3468
|
+
model: sm.model,
|
|
3469
|
+
thinkingLevel: sm.thinkingLevel,
|
|
3470
|
+
})));
|
|
3471
|
+
}
|
|
3472
|
+
else {
|
|
3473
|
+
// All enabled or none enabled = no filter
|
|
3474
|
+
this.session.setScopedModels([]);
|
|
3475
|
+
}
|
|
3476
|
+
await this.updateAvailableProviderCount();
|
|
3477
|
+
this.ui.requestRender();
|
|
3478
|
+
};
|
|
3479
|
+
this.showSelector((done) => {
|
|
3480
|
+
const selector = new ScopedModelsSelectorComponent({
|
|
3481
|
+
allModels,
|
|
3482
|
+
enabledModelIds: currentEnabledIds,
|
|
3483
|
+
}, {
|
|
3484
|
+
onChange: async (enabledIds) => {
|
|
3485
|
+
await updateSessionModels(enabledIds);
|
|
3486
|
+
},
|
|
3487
|
+
onPersist: (enabledIds) => {
|
|
3488
|
+
// Persist to settings
|
|
3489
|
+
const newPatterns = enabledIds === null || enabledIds.length === allModels.length
|
|
3490
|
+
? undefined // All enabled = clear filter
|
|
3491
|
+
: enabledIds;
|
|
3492
|
+
this.settingsManager.setEnabledModels(newPatterns ? [...newPatterns] : undefined);
|
|
3493
|
+
this.showStatus("Model selection saved to settings");
|
|
3494
|
+
},
|
|
3495
|
+
onCancel: () => {
|
|
3496
|
+
done();
|
|
3497
|
+
this.ui.requestRender();
|
|
3498
|
+
},
|
|
3499
|
+
});
|
|
3500
|
+
return { component: selector, focus: selector };
|
|
3501
|
+
});
|
|
3502
|
+
}
|
|
3503
|
+
showUserMessageSelector() {
|
|
3504
|
+
const userMessages = this.session.getUserMessagesForForking();
|
|
3505
|
+
if (userMessages.length === 0) {
|
|
3506
|
+
this.showStatus("No messages to fork from");
|
|
3507
|
+
return;
|
|
3508
|
+
}
|
|
3509
|
+
const initialSelectedId = userMessages[userMessages.length - 1]?.entryId;
|
|
3510
|
+
this.showSelector((done) => {
|
|
3511
|
+
const selector = new UserMessageSelectorComponent(userMessages.map((m) => ({ id: m.entryId, text: m.text })), async (entryId) => {
|
|
3512
|
+
try {
|
|
3513
|
+
const result = await this.runtimeHost.fork(entryId);
|
|
3514
|
+
if (result.cancelled) {
|
|
3515
|
+
done();
|
|
3516
|
+
this.ui.requestRender();
|
|
3517
|
+
return;
|
|
3518
|
+
}
|
|
3519
|
+
this.renderCurrentSessionState();
|
|
3520
|
+
this.editor.setText(result.selectedText ?? "");
|
|
3521
|
+
done();
|
|
3522
|
+
this.showStatus("Forked to new session");
|
|
3523
|
+
}
|
|
3524
|
+
catch (error) {
|
|
3525
|
+
done();
|
|
3526
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
3527
|
+
}
|
|
3528
|
+
}, () => {
|
|
3529
|
+
done();
|
|
3530
|
+
this.ui.requestRender();
|
|
3531
|
+
}, initialSelectedId);
|
|
3532
|
+
return { component: selector, focus: selector.getMessageList() };
|
|
3533
|
+
});
|
|
3534
|
+
}
|
|
3535
|
+
async handleCloneCommand() {
|
|
3536
|
+
const leafId = this.sessionManager.getLeafId();
|
|
3537
|
+
if (!leafId) {
|
|
3538
|
+
this.showStatus("Nothing to clone yet");
|
|
3539
|
+
return;
|
|
3540
|
+
}
|
|
3541
|
+
try {
|
|
3542
|
+
const result = await this.runtimeHost.fork(leafId, { position: "at" });
|
|
3543
|
+
if (result.cancelled) {
|
|
3544
|
+
this.ui.requestRender();
|
|
3545
|
+
return;
|
|
3546
|
+
}
|
|
3547
|
+
this.renderCurrentSessionState();
|
|
3548
|
+
this.editor.setText("");
|
|
3549
|
+
this.showStatus("Cloned to new session");
|
|
3550
|
+
}
|
|
3551
|
+
catch (error) {
|
|
3552
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
3553
|
+
}
|
|
3554
|
+
}
|
|
3555
|
+
showTreeSelector(initialSelectedId) {
|
|
3556
|
+
const tree = this.sessionManager.getTree();
|
|
3557
|
+
const realLeafId = this.sessionManager.getLeafId();
|
|
3558
|
+
const initialFilterMode = this.settingsManager.getTreeFilterMode();
|
|
3559
|
+
if (tree.length === 0) {
|
|
3560
|
+
this.showStatus("No entries in session");
|
|
3561
|
+
return;
|
|
3562
|
+
}
|
|
3563
|
+
this.showSelector((done) => {
|
|
3564
|
+
const selector = new TreeSelectorComponent(tree, realLeafId, this.ui.terminal.rows, async (entryId) => {
|
|
3565
|
+
// Selecting the current leaf is a no-op (already there)
|
|
3566
|
+
if (entryId === realLeafId) {
|
|
3567
|
+
done();
|
|
3568
|
+
this.showStatus("Already at this point");
|
|
3569
|
+
return;
|
|
3570
|
+
}
|
|
3571
|
+
// Ask about summarization
|
|
3572
|
+
done(); // Close selector first
|
|
3573
|
+
// Loop until user makes a complete choice or cancels to tree
|
|
3574
|
+
let wantsSummary = false;
|
|
3575
|
+
let customInstructions;
|
|
3576
|
+
// Check if we should skip the prompt (user preference to always default to no summary)
|
|
3577
|
+
if (!this.settingsManager.getBranchSummarySkipPrompt()) {
|
|
3578
|
+
while (true) {
|
|
3579
|
+
const summaryChoice = await this.showExtensionSelector("Summarize branch?", [
|
|
3580
|
+
"No summary",
|
|
3581
|
+
"Summarize",
|
|
3582
|
+
"Summarize with custom prompt",
|
|
3583
|
+
]);
|
|
3584
|
+
if (summaryChoice === undefined) {
|
|
3585
|
+
// User pressed escape - re-show tree selector with same selection
|
|
3586
|
+
this.showTreeSelector(entryId);
|
|
3587
|
+
return;
|
|
3588
|
+
}
|
|
3589
|
+
wantsSummary = summaryChoice !== "No summary";
|
|
3590
|
+
if (summaryChoice === "Summarize with custom prompt") {
|
|
3591
|
+
customInstructions = await this.showExtensionEditor("Custom summarization instructions");
|
|
3592
|
+
if (customInstructions === undefined) {
|
|
3593
|
+
// User cancelled - loop back to summary selector
|
|
3594
|
+
continue;
|
|
3595
|
+
}
|
|
3596
|
+
}
|
|
3597
|
+
// User made a complete choice
|
|
3598
|
+
break;
|
|
3599
|
+
}
|
|
3600
|
+
}
|
|
3601
|
+
// Set up escape handler and loader if summarizing
|
|
3602
|
+
let summaryLoader;
|
|
3603
|
+
const originalOnEscape = this.defaultEditor.onEscape;
|
|
3604
|
+
if (wantsSummary) {
|
|
3605
|
+
this.defaultEditor.onEscape = () => {
|
|
3606
|
+
this.session.abortBranchSummary();
|
|
3607
|
+
};
|
|
3608
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
3609
|
+
summaryLoader = new Loader(this.ui, (spinner) => theme.fg("accent", spinner), (text) => theme.fg("muted", text), `Summarizing branch... (${keyText("app.interrupt")} to cancel)`);
|
|
3610
|
+
this.statusContainer.addChild(summaryLoader);
|
|
3611
|
+
this.ui.requestRender();
|
|
3612
|
+
}
|
|
3613
|
+
try {
|
|
3614
|
+
const result = await this.session.navigateTree(entryId, {
|
|
3615
|
+
summarize: wantsSummary,
|
|
3616
|
+
customInstructions,
|
|
3617
|
+
});
|
|
3618
|
+
if (result.aborted) {
|
|
3619
|
+
// Summarization aborted - re-show tree selector with same selection
|
|
3620
|
+
this.showStatus("Branch summarization cancelled");
|
|
3621
|
+
this.showTreeSelector(entryId);
|
|
3622
|
+
return;
|
|
3623
|
+
}
|
|
3624
|
+
if (result.cancelled) {
|
|
3625
|
+
this.showStatus("Navigation cancelled");
|
|
3626
|
+
return;
|
|
3627
|
+
}
|
|
3628
|
+
// Update UI
|
|
3629
|
+
this.chatContainer.clear();
|
|
3630
|
+
this.renderInitialMessages();
|
|
3631
|
+
if (result.editorText && !this.editor.getText().trim()) {
|
|
3632
|
+
this.editor.setText(result.editorText);
|
|
3633
|
+
}
|
|
3634
|
+
this.showStatus("Navigated to selected point");
|
|
3635
|
+
void this.flushCompactionQueue({ willRetry: false });
|
|
3636
|
+
}
|
|
3637
|
+
catch (error) {
|
|
3638
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
3639
|
+
}
|
|
3640
|
+
finally {
|
|
3641
|
+
if (summaryLoader) {
|
|
3642
|
+
summaryLoader.stop();
|
|
3643
|
+
this.statusContainer.clear();
|
|
3644
|
+
}
|
|
3645
|
+
this.defaultEditor.onEscape = originalOnEscape;
|
|
3646
|
+
}
|
|
3647
|
+
}, () => {
|
|
3648
|
+
done();
|
|
3649
|
+
this.ui.requestRender();
|
|
3650
|
+
}, (entryId, label) => {
|
|
3651
|
+
this.sessionManager.appendLabelChange(entryId, label);
|
|
3652
|
+
this.ui.requestRender();
|
|
3653
|
+
}, initialSelectedId, initialFilterMode);
|
|
3654
|
+
return { component: selector, focus: selector };
|
|
3655
|
+
});
|
|
3656
|
+
}
|
|
3657
|
+
showSessionSelector() {
|
|
3658
|
+
this.showSelector((done) => {
|
|
3659
|
+
const selector = new SessionSelectorComponent((onProgress) => SessionManager.list(this.sessionManager.getCwd(), this.sessionManager.getSessionDir(), onProgress), SessionManager.listAll, async (sessionPath) => {
|
|
3660
|
+
done();
|
|
3661
|
+
await this.handleResumeSession(sessionPath);
|
|
3662
|
+
}, () => {
|
|
3663
|
+
done();
|
|
3664
|
+
this.ui.requestRender();
|
|
3665
|
+
}, () => {
|
|
3666
|
+
void this.shutdown();
|
|
3667
|
+
}, () => this.ui.requestRender(), {
|
|
3668
|
+
renameSession: async (sessionFilePath, nextName) => {
|
|
3669
|
+
const next = (nextName ?? "").trim();
|
|
3670
|
+
if (!next)
|
|
3671
|
+
return;
|
|
3672
|
+
const mgr = SessionManager.open(sessionFilePath);
|
|
3673
|
+
mgr.appendSessionInfo(next);
|
|
3674
|
+
},
|
|
3675
|
+
showRenameHint: true,
|
|
3676
|
+
keybindings: this.keybindings,
|
|
3677
|
+
}, this.sessionManager.getSessionFile());
|
|
3678
|
+
return { component: selector, focus: selector };
|
|
3679
|
+
});
|
|
3680
|
+
}
|
|
3681
|
+
async handleResumeSession(sessionPath, options) {
|
|
3682
|
+
if (this.loadingAnimation) {
|
|
3683
|
+
this.loadingAnimation.stop();
|
|
3684
|
+
this.loadingAnimation = undefined;
|
|
3685
|
+
}
|
|
3686
|
+
this.statusContainer.clear();
|
|
3687
|
+
try {
|
|
3688
|
+
const result = await this.runtimeHost.switchSession(sessionPath, {
|
|
3689
|
+
withSession: options?.withSession,
|
|
3690
|
+
});
|
|
3691
|
+
if (result.cancelled) {
|
|
3692
|
+
return result;
|
|
3693
|
+
}
|
|
3694
|
+
this.renderCurrentSessionState();
|
|
3695
|
+
this.showStatus("Resumed session");
|
|
3696
|
+
return result;
|
|
3697
|
+
}
|
|
3698
|
+
catch (error) {
|
|
3699
|
+
if (error instanceof MissingSessionCwdError) {
|
|
3700
|
+
const selectedCwd = await this.promptForMissingSessionCwd(error);
|
|
3701
|
+
if (!selectedCwd) {
|
|
3702
|
+
this.showStatus("Resume cancelled");
|
|
3703
|
+
return { cancelled: true };
|
|
3704
|
+
}
|
|
3705
|
+
const result = await this.runtimeHost.switchSession(sessionPath, {
|
|
3706
|
+
cwdOverride: selectedCwd,
|
|
3707
|
+
withSession: options?.withSession,
|
|
3708
|
+
});
|
|
3709
|
+
if (result.cancelled) {
|
|
3710
|
+
return result;
|
|
3711
|
+
}
|
|
3712
|
+
this.renderCurrentSessionState();
|
|
3713
|
+
this.showStatus("Resumed session in current cwd");
|
|
3714
|
+
return result;
|
|
3715
|
+
}
|
|
3716
|
+
return this.handleFatalRuntimeError("Failed to resume session", error);
|
|
3717
|
+
}
|
|
3718
|
+
}
|
|
3719
|
+
getLoginProviderOptions(authType) {
|
|
3720
|
+
const authStorage = this.session.modelRegistry.authStorage;
|
|
3721
|
+
const oauthProviders = authStorage.getOAuthProviders();
|
|
3722
|
+
const oauthProviderIds = new Set(oauthProviders.map((provider) => provider.id));
|
|
3723
|
+
const options = oauthProviders.map((provider) => ({
|
|
3724
|
+
id: provider.id,
|
|
3725
|
+
name: provider.name,
|
|
3726
|
+
authType: "oauth",
|
|
3727
|
+
}));
|
|
3728
|
+
const modelProviders = new Set(this.session.modelRegistry.getAll().map((model) => model.provider));
|
|
3729
|
+
for (const providerId of modelProviders) {
|
|
3730
|
+
if (!isApiKeyLoginProvider(providerId, oauthProviderIds)) {
|
|
3731
|
+
continue;
|
|
3732
|
+
}
|
|
3733
|
+
options.push({
|
|
3734
|
+
id: providerId,
|
|
3735
|
+
name: this.session.modelRegistry.getProviderDisplayName(providerId),
|
|
3736
|
+
authType: "api_key",
|
|
3737
|
+
});
|
|
3738
|
+
}
|
|
3739
|
+
const filteredOptions = authType ? options.filter((option) => option.authType === authType) : options;
|
|
3740
|
+
return filteredOptions.sort((a, b) => a.name.localeCompare(b.name));
|
|
3741
|
+
}
|
|
3742
|
+
getLogoutProviderOptions() {
|
|
3743
|
+
const authStorage = this.session.modelRegistry.authStorage;
|
|
3744
|
+
const options = [];
|
|
3745
|
+
for (const providerId of authStorage.list()) {
|
|
3746
|
+
const credential = authStorage.get(providerId);
|
|
3747
|
+
if (!credential) {
|
|
3748
|
+
continue;
|
|
3749
|
+
}
|
|
3750
|
+
options.push({
|
|
3751
|
+
id: providerId,
|
|
3752
|
+
name: this.session.modelRegistry.getProviderDisplayName(providerId),
|
|
3753
|
+
authType: credential.type,
|
|
3754
|
+
});
|
|
3755
|
+
}
|
|
3756
|
+
return options.sort((a, b) => a.name.localeCompare(b.name));
|
|
3757
|
+
}
|
|
3758
|
+
showLoginAuthTypeSelector() {
|
|
3759
|
+
const subscriptionLabel = "Use a subscription";
|
|
3760
|
+
const apiKeyLabel = "Use an API key";
|
|
3761
|
+
this.showSelector((done) => {
|
|
3762
|
+
const selector = new ExtensionSelectorComponent("Select authentication method:", [subscriptionLabel, apiKeyLabel], (option) => {
|
|
3763
|
+
done();
|
|
3764
|
+
const authType = option === subscriptionLabel ? "oauth" : "api_key";
|
|
3765
|
+
this.showLoginProviderSelector(authType);
|
|
3766
|
+
}, () => {
|
|
3767
|
+
done();
|
|
3768
|
+
this.ui.requestRender();
|
|
3769
|
+
});
|
|
3770
|
+
return { component: selector, focus: selector };
|
|
3771
|
+
});
|
|
3772
|
+
}
|
|
3773
|
+
showLoginProviderSelector(authType) {
|
|
3774
|
+
const providerOptions = this.getLoginProviderOptions(authType);
|
|
3775
|
+
if (providerOptions.length === 0) {
|
|
3776
|
+
this.showStatus(authType === "oauth" ? "No subscription providers available." : "No API key providers available.");
|
|
3777
|
+
return;
|
|
3778
|
+
}
|
|
3779
|
+
this.showSelector((done) => {
|
|
3780
|
+
const selector = new OAuthSelectorComponent("login", this.session.modelRegistry.authStorage, providerOptions, async (providerId) => {
|
|
3781
|
+
done();
|
|
3782
|
+
const providerOption = providerOptions.find((provider) => provider.id === providerId);
|
|
3783
|
+
if (!providerOption) {
|
|
3784
|
+
return;
|
|
3785
|
+
}
|
|
3786
|
+
if (providerOption.authType === "oauth") {
|
|
3787
|
+
await this.showLoginDialog(providerOption.id, providerOption.name);
|
|
3788
|
+
}
|
|
3789
|
+
else if (providerOption.id === BEDROCK_PROVIDER_ID) {
|
|
3790
|
+
this.showBedrockSetupDialog(providerOption.id, providerOption.name);
|
|
3791
|
+
}
|
|
3792
|
+
else {
|
|
3793
|
+
await this.showApiKeyLoginDialog(providerOption.id, providerOption.name);
|
|
3794
|
+
}
|
|
3795
|
+
}, () => {
|
|
3796
|
+
done();
|
|
3797
|
+
this.showLoginAuthTypeSelector();
|
|
3798
|
+
}, (providerId) => this.session.modelRegistry.getProviderAuthStatus(providerId));
|
|
3799
|
+
return { component: selector, focus: selector };
|
|
3800
|
+
});
|
|
3801
|
+
}
|
|
3802
|
+
async showOAuthSelector(mode) {
|
|
3803
|
+
if (mode === "login") {
|
|
3804
|
+
this.showLoginAuthTypeSelector();
|
|
3805
|
+
return;
|
|
3806
|
+
}
|
|
3807
|
+
const providerOptions = this.getLogoutProviderOptions();
|
|
3808
|
+
if (providerOptions.length === 0) {
|
|
3809
|
+
this.showStatus("No stored credentials to remove. /logout only removes credentials saved by /login; environment variables and models.json config are unchanged.");
|
|
3810
|
+
return;
|
|
3811
|
+
}
|
|
3812
|
+
this.showSelector((done) => {
|
|
3813
|
+
const selector = new OAuthSelectorComponent(mode, this.session.modelRegistry.authStorage, providerOptions, async (providerId) => {
|
|
3814
|
+
done();
|
|
3815
|
+
const providerOption = providerOptions.find((provider) => provider.id === providerId);
|
|
3816
|
+
if (!providerOption) {
|
|
3817
|
+
return;
|
|
3818
|
+
}
|
|
3819
|
+
try {
|
|
3820
|
+
this.session.modelRegistry.authStorage.logout(providerOption.id);
|
|
3821
|
+
this.session.modelRegistry.refresh();
|
|
3822
|
+
await this.updateAvailableProviderCount();
|
|
3823
|
+
const message = providerOption.authType === "oauth"
|
|
3824
|
+
? `Logged out of ${providerOption.name}`
|
|
3825
|
+
: `Removed stored API key for ${providerOption.name}. Environment variables and models.json config are unchanged.`;
|
|
3826
|
+
this.showStatus(message);
|
|
3827
|
+
}
|
|
3828
|
+
catch (error) {
|
|
3829
|
+
this.showError(`Logout failed: ${error instanceof Error ? error.message : String(error)}`);
|
|
3830
|
+
}
|
|
3831
|
+
}, () => {
|
|
3832
|
+
done();
|
|
3833
|
+
this.ui.requestRender();
|
|
3834
|
+
});
|
|
3835
|
+
return { component: selector, focus: selector };
|
|
3836
|
+
});
|
|
3837
|
+
}
|
|
3838
|
+
async completeProviderAuthentication(providerId, providerName, authType, previousModel) {
|
|
3839
|
+
this.session.modelRegistry.refresh();
|
|
3840
|
+
const actionLabel = authType === "oauth" ? `Logged in to ${providerName}` : `Saved API key for ${providerName}`;
|
|
3841
|
+
let selectedModel;
|
|
3842
|
+
let selectionError;
|
|
3843
|
+
if (isUnknownModel(previousModel)) {
|
|
3844
|
+
const availableModels = this.session.modelRegistry.getAvailable();
|
|
3845
|
+
const providerModels = availableModels.filter((model) => model.provider === providerId);
|
|
3846
|
+
if (!hasDefaultModelProvider(providerId)) {
|
|
3847
|
+
selectionError = `${actionLabel}, but no default model is configured for provider "${providerId}". Use /model to select a model.`;
|
|
3848
|
+
}
|
|
3849
|
+
else if (providerModels.length === 0) {
|
|
3850
|
+
selectionError = `${actionLabel}, but no models are available for that provider. Use /model to select a model.`;
|
|
3851
|
+
}
|
|
3852
|
+
else {
|
|
3853
|
+
const defaultModelId = defaultModelPerProvider[providerId];
|
|
3854
|
+
selectedModel = providerModels.find((model) => model.id === defaultModelId);
|
|
3855
|
+
if (!selectedModel) {
|
|
3856
|
+
selectionError = `${actionLabel}, but its default model "${defaultModelId}" is not available. Use /model to select a model.`;
|
|
3857
|
+
}
|
|
3858
|
+
else {
|
|
3859
|
+
try {
|
|
3860
|
+
await this.session.setModel(selectedModel);
|
|
3861
|
+
}
|
|
3862
|
+
catch (error) {
|
|
3863
|
+
selectedModel = undefined;
|
|
3864
|
+
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
3865
|
+
selectionError = `${actionLabel}, but selecting its default model failed: ${errorMessage}. Use /model to select a model.`;
|
|
3866
|
+
}
|
|
3867
|
+
}
|
|
3868
|
+
}
|
|
3869
|
+
}
|
|
3870
|
+
await this.updateAvailableProviderCount();
|
|
3871
|
+
this.footer.invalidate();
|
|
3872
|
+
this.updateEditorBorderColor();
|
|
3873
|
+
if (selectedModel) {
|
|
3874
|
+
this.showStatus(`${actionLabel}. Selected ${selectedModel.id}. Credentials saved to ${getAuthPath()}`);
|
|
3875
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth(selectedModel);
|
|
3876
|
+
this.checkDaxnutsEasterEgg(selectedModel);
|
|
3877
|
+
}
|
|
3878
|
+
else {
|
|
3879
|
+
this.showStatus(`${actionLabel}. Credentials saved to ${getAuthPath()}`);
|
|
3880
|
+
if (selectionError) {
|
|
3881
|
+
this.showError(selectionError);
|
|
3882
|
+
}
|
|
3883
|
+
else {
|
|
3884
|
+
void this.maybeWarnAboutAnthropicSubscriptionAuth();
|
|
3885
|
+
}
|
|
3886
|
+
}
|
|
3887
|
+
}
|
|
3888
|
+
showBedrockSetupDialog(providerId, providerName) {
|
|
3889
|
+
const restoreEditor = () => {
|
|
3890
|
+
this.editorContainer.clear();
|
|
3891
|
+
this.editorContainer.addChild(this.editor);
|
|
3892
|
+
this.ui.setFocus(this.editor);
|
|
3893
|
+
this.ui.requestRender();
|
|
3894
|
+
};
|
|
3895
|
+
const dialog = new LoginDialogComponent(this.ui, providerId, () => restoreEditor(), providerName, "Amazon Bedrock setup");
|
|
3896
|
+
dialog.showInfo([
|
|
3897
|
+
theme.fg("text", "Amazon Bedrock uses AWS credentials instead of a single API key."),
|
|
3898
|
+
theme.fg("text", "Configure an AWS profile, IAM keys, bearer token, or role-based credentials."),
|
|
3899
|
+
theme.fg("muted", "See:"),
|
|
3900
|
+
theme.fg("accent", ` ${path.join(getDocsPath(), "providers.md")}`),
|
|
3901
|
+
]);
|
|
3902
|
+
this.editorContainer.clear();
|
|
3903
|
+
this.editorContainer.addChild(dialog);
|
|
3904
|
+
this.ui.setFocus(dialog);
|
|
3905
|
+
this.ui.requestRender();
|
|
3906
|
+
}
|
|
3907
|
+
async showApiKeyLoginDialog(providerId, providerName) {
|
|
3908
|
+
const previousModel = this.session.model;
|
|
3909
|
+
const dialog = new LoginDialogComponent(this.ui, providerId, (_success, _message) => {
|
|
3910
|
+
// Completion handled below
|
|
3911
|
+
}, providerName);
|
|
3912
|
+
this.editorContainer.clear();
|
|
3913
|
+
this.editorContainer.addChild(dialog);
|
|
3914
|
+
this.ui.setFocus(dialog);
|
|
3915
|
+
this.ui.requestRender();
|
|
3916
|
+
const restoreEditor = () => {
|
|
3917
|
+
this.editorContainer.clear();
|
|
3918
|
+
this.editorContainer.addChild(this.editor);
|
|
3919
|
+
this.ui.setFocus(this.editor);
|
|
3920
|
+
this.ui.requestRender();
|
|
3921
|
+
};
|
|
3922
|
+
try {
|
|
3923
|
+
const apiKey = (await dialog.showPrompt("Enter API key:")).trim();
|
|
3924
|
+
if (!apiKey) {
|
|
3925
|
+
throw new Error("API key cannot be empty.");
|
|
3926
|
+
}
|
|
3927
|
+
this.session.modelRegistry.authStorage.set(providerId, { type: "api_key", key: apiKey });
|
|
3928
|
+
restoreEditor();
|
|
3929
|
+
await this.completeProviderAuthentication(providerId, providerName, "api_key", previousModel);
|
|
3930
|
+
}
|
|
3931
|
+
catch (error) {
|
|
3932
|
+
restoreEditor();
|
|
3933
|
+
const errorMsg = error instanceof Error ? error.message : String(error);
|
|
3934
|
+
if (errorMsg !== "Login cancelled") {
|
|
3935
|
+
this.showError(`Failed to save API key for ${providerName}: ${errorMsg}`);
|
|
3936
|
+
}
|
|
3937
|
+
}
|
|
3938
|
+
}
|
|
3939
|
+
showOAuthLoginSelect(dialog, prompt) {
|
|
3940
|
+
return new Promise((resolve) => {
|
|
3941
|
+
const restoreDialog = () => {
|
|
3942
|
+
this.editorContainer.clear();
|
|
3943
|
+
this.editorContainer.addChild(dialog);
|
|
3944
|
+
this.ui.setFocus(dialog);
|
|
3945
|
+
this.ui.requestRender();
|
|
3946
|
+
};
|
|
3947
|
+
const labels = prompt.options.map((option) => option.label);
|
|
3948
|
+
const selector = new ExtensionSelectorComponent(prompt.message, labels, (optionLabel) => {
|
|
3949
|
+
restoreDialog();
|
|
3950
|
+
resolve(prompt.options.find((option) => option.label === optionLabel)?.id);
|
|
3951
|
+
}, () => {
|
|
3952
|
+
restoreDialog();
|
|
3953
|
+
resolve(undefined);
|
|
3954
|
+
});
|
|
3955
|
+
this.editorContainer.clear();
|
|
3956
|
+
this.editorContainer.addChild(selector);
|
|
3957
|
+
this.ui.setFocus(selector);
|
|
3958
|
+
this.ui.requestRender();
|
|
3959
|
+
});
|
|
3960
|
+
}
|
|
3961
|
+
async showLoginDialog(providerId, providerName) {
|
|
3962
|
+
const providerInfo = this.session.modelRegistry.authStorage
|
|
3963
|
+
.getOAuthProviders()
|
|
3964
|
+
.find((provider) => provider.id === providerId);
|
|
3965
|
+
const previousModel = this.session.model;
|
|
3966
|
+
// Providers that use callback servers (can paste redirect URL)
|
|
3967
|
+
const usesCallbackServer = providerInfo?.usesCallbackServer ?? false;
|
|
3968
|
+
// Create login dialog component
|
|
3969
|
+
const dialog = new LoginDialogComponent(this.ui, providerId, (_success, _message) => {
|
|
3970
|
+
// Completion handled below
|
|
3971
|
+
}, providerName);
|
|
3972
|
+
// Show dialog in editor container
|
|
3973
|
+
this.editorContainer.clear();
|
|
3974
|
+
this.editorContainer.addChild(dialog);
|
|
3975
|
+
this.ui.setFocus(dialog);
|
|
3976
|
+
this.ui.requestRender();
|
|
3977
|
+
// Promise for manual code input (racing with callback server)
|
|
3978
|
+
let manualCodeResolve;
|
|
3979
|
+
let manualCodeReject;
|
|
3980
|
+
const manualCodePromise = new Promise((resolve, reject) => {
|
|
3981
|
+
manualCodeResolve = resolve;
|
|
3982
|
+
manualCodeReject = reject;
|
|
3983
|
+
});
|
|
3984
|
+
// Restore editor helper
|
|
3985
|
+
const restoreEditor = () => {
|
|
3986
|
+
this.editorContainer.clear();
|
|
3987
|
+
this.editorContainer.addChild(this.editor);
|
|
3988
|
+
this.ui.setFocus(this.editor);
|
|
3989
|
+
this.ui.requestRender();
|
|
3990
|
+
};
|
|
3991
|
+
try {
|
|
3992
|
+
await this.session.modelRegistry.authStorage.login(providerId, {
|
|
3993
|
+
onAuth: (info) => {
|
|
3994
|
+
dialog.showAuth(info.url, info.instructions);
|
|
3995
|
+
if (usesCallbackServer) {
|
|
3996
|
+
// Show input for manual paste, racing with callback
|
|
3997
|
+
dialog
|
|
3998
|
+
.showManualInput("Paste redirect URL below, or complete login in browser:")
|
|
3999
|
+
.then((value) => {
|
|
4000
|
+
if (value && manualCodeResolve) {
|
|
4001
|
+
manualCodeResolve(value);
|
|
4002
|
+
manualCodeResolve = undefined;
|
|
4003
|
+
}
|
|
4004
|
+
})
|
|
4005
|
+
.catch(() => {
|
|
4006
|
+
if (manualCodeReject) {
|
|
4007
|
+
manualCodeReject(new Error("Login cancelled"));
|
|
4008
|
+
manualCodeReject = undefined;
|
|
4009
|
+
}
|
|
4010
|
+
});
|
|
4011
|
+
}
|
|
4012
|
+
else if (providerId === "github-copilot") {
|
|
4013
|
+
// GitHub Copilot polls after onAuth
|
|
4014
|
+
dialog.showWaiting("Waiting for browser authentication...");
|
|
4015
|
+
}
|
|
4016
|
+
// For Anthropic: onPrompt is called immediately after
|
|
4017
|
+
},
|
|
4018
|
+
onPrompt: async (prompt) => {
|
|
4019
|
+
return dialog.showPrompt(prompt.message, prompt.placeholder);
|
|
4020
|
+
},
|
|
4021
|
+
onProgress: (message) => {
|
|
4022
|
+
dialog.showProgress(message);
|
|
4023
|
+
},
|
|
4024
|
+
onSelect: (prompt) => this.showOAuthLoginSelect(dialog, prompt),
|
|
4025
|
+
onManualCodeInput: () => manualCodePromise,
|
|
4026
|
+
signal: dialog.signal,
|
|
4027
|
+
});
|
|
4028
|
+
// Success
|
|
4029
|
+
restoreEditor();
|
|
4030
|
+
await this.completeProviderAuthentication(providerId, providerName, "oauth", previousModel);
|
|
4031
|
+
}
|
|
4032
|
+
catch (error) {
|
|
4033
|
+
restoreEditor();
|
|
4034
|
+
const errorMsg = error instanceof Error ? error.message : String(error);
|
|
4035
|
+
if (errorMsg !== "Login cancelled") {
|
|
4036
|
+
this.showError(`Failed to login to ${providerName}: ${errorMsg}`);
|
|
4037
|
+
}
|
|
4038
|
+
}
|
|
4039
|
+
}
|
|
4040
|
+
// =========================================================================
|
|
4041
|
+
// Command handlers
|
|
4042
|
+
// =========================================================================
|
|
4043
|
+
async handleReloadCommand() {
|
|
4044
|
+
if (this.session.isStreaming) {
|
|
4045
|
+
this.showWarning("Wait for the current response to finish before reloading.");
|
|
4046
|
+
return;
|
|
4047
|
+
}
|
|
4048
|
+
if (this.session.isCompacting) {
|
|
4049
|
+
this.showWarning("Wait for compaction to finish before reloading.");
|
|
4050
|
+
return;
|
|
4051
|
+
}
|
|
4052
|
+
this.resetExtensionUI();
|
|
4053
|
+
const reloadBox = new Container();
|
|
4054
|
+
const borderColor = (s) => theme.fg("border", s);
|
|
4055
|
+
reloadBox.addChild(new DynamicBorder(borderColor));
|
|
4056
|
+
reloadBox.addChild(new Spacer(1));
|
|
4057
|
+
reloadBox.addChild(new Text(theme.fg("muted", "Reloading keybindings, extensions, skills, prompts, themes..."), 1, 0));
|
|
4058
|
+
reloadBox.addChild(new Spacer(1));
|
|
4059
|
+
reloadBox.addChild(new DynamicBorder(borderColor));
|
|
4060
|
+
const previousEditor = this.editor;
|
|
4061
|
+
this.editorContainer.clear();
|
|
4062
|
+
this.editorContainer.addChild(reloadBox);
|
|
4063
|
+
this.ui.setFocus(reloadBox);
|
|
4064
|
+
this.ui.requestRender(true);
|
|
4065
|
+
await new Promise((resolve) => process.nextTick(resolve));
|
|
4066
|
+
const dismissReloadBox = (editor) => {
|
|
4067
|
+
this.editorContainer.clear();
|
|
4068
|
+
this.editorContainer.addChild(editor);
|
|
4069
|
+
this.ui.setFocus(editor);
|
|
4070
|
+
this.ui.requestRender();
|
|
4071
|
+
};
|
|
4072
|
+
try {
|
|
4073
|
+
await this.session.reload();
|
|
4074
|
+
this.keybindings.reload();
|
|
4075
|
+
const activeHeader = this.customHeader ?? this.builtInHeader;
|
|
4076
|
+
if (isExpandable(activeHeader)) {
|
|
4077
|
+
activeHeader.setExpanded(this.toolOutputExpanded);
|
|
4078
|
+
}
|
|
4079
|
+
setRegisteredThemes(this.session.resourceLoader.getThemes().themes);
|
|
4080
|
+
this.hideThinkingBlock = this.settingsManager.getHideThinkingBlock();
|
|
4081
|
+
const themeName = this.settingsManager.getTheme();
|
|
4082
|
+
const themeResult = themeName ? setTheme(themeName, true) : { success: true };
|
|
4083
|
+
if (!themeResult.success) {
|
|
4084
|
+
this.showError(`Failed to load theme "${themeName}": ${themeResult.error}\nFell back to dark theme.`);
|
|
4085
|
+
}
|
|
4086
|
+
const editorPaddingX = this.settingsManager.getEditorPaddingX();
|
|
4087
|
+
const autocompleteMaxVisible = this.settingsManager.getAutocompleteMaxVisible();
|
|
4088
|
+
this.defaultEditor.setPaddingX(editorPaddingX);
|
|
4089
|
+
this.defaultEditor.setAutocompleteMaxVisible(autocompleteMaxVisible);
|
|
4090
|
+
if (this.editor !== this.defaultEditor) {
|
|
4091
|
+
this.editor.setPaddingX?.(editorPaddingX);
|
|
4092
|
+
this.editor.setAutocompleteMaxVisible?.(autocompleteMaxVisible);
|
|
4093
|
+
}
|
|
4094
|
+
this.ui.setShowHardwareCursor(this.settingsManager.getShowHardwareCursor());
|
|
4095
|
+
this.ui.setClearOnShrink(this.settingsManager.getClearOnShrink());
|
|
4096
|
+
this.setupAutocompleteProvider();
|
|
4097
|
+
const runner = this.session.extensionRunner;
|
|
4098
|
+
this.setupExtensionShortcuts(runner);
|
|
4099
|
+
this.rebuildChatFromMessages();
|
|
4100
|
+
dismissReloadBox(this.editor);
|
|
4101
|
+
this.showLoadedResources({
|
|
4102
|
+
force: false,
|
|
4103
|
+
showDiagnosticsWhenQuiet: true,
|
|
4104
|
+
});
|
|
4105
|
+
const modelsJsonError = this.session.modelRegistry.getError();
|
|
4106
|
+
if (modelsJsonError) {
|
|
4107
|
+
this.showError(`models.json error: ${modelsJsonError}`);
|
|
4108
|
+
}
|
|
4109
|
+
this.showStatus("Reloaded keybindings, extensions, skills, prompts, themes");
|
|
4110
|
+
}
|
|
4111
|
+
catch (error) {
|
|
4112
|
+
dismissReloadBox(previousEditor);
|
|
4113
|
+
this.showError(`Reload failed: ${error instanceof Error ? error.message : String(error)}`);
|
|
4114
|
+
}
|
|
4115
|
+
}
|
|
4116
|
+
async handleExportCommand(text) {
|
|
4117
|
+
const outputPath = this.getPathCommandArgument(text, "/export");
|
|
4118
|
+
try {
|
|
4119
|
+
if (outputPath?.endsWith(".jsonl")) {
|
|
4120
|
+
const filePath = this.session.exportToJsonl(outputPath);
|
|
4121
|
+
this.showStatus(`Session exported to: ${filePath}`);
|
|
4122
|
+
}
|
|
4123
|
+
else {
|
|
4124
|
+
const filePath = await this.session.exportToHtml(outputPath);
|
|
4125
|
+
this.showStatus(`Session exported to: ${filePath}`);
|
|
4126
|
+
}
|
|
4127
|
+
}
|
|
4128
|
+
catch (error) {
|
|
4129
|
+
this.showError(`Failed to export session: ${error instanceof Error ? error.message : "Unknown error"}`);
|
|
4130
|
+
}
|
|
4131
|
+
}
|
|
4132
|
+
getPathCommandArgument(text, command) {
|
|
4133
|
+
if (text === command) {
|
|
4134
|
+
return undefined;
|
|
4135
|
+
}
|
|
4136
|
+
if (!text.startsWith(`${command} `)) {
|
|
4137
|
+
return undefined;
|
|
4138
|
+
}
|
|
4139
|
+
const argsString = text.slice(command.length + 1).trimStart();
|
|
4140
|
+
if (!argsString) {
|
|
4141
|
+
return undefined;
|
|
4142
|
+
}
|
|
4143
|
+
const firstChar = argsString[0];
|
|
4144
|
+
if (firstChar === '"' || firstChar === "'") {
|
|
4145
|
+
const closingQuoteIndex = argsString.indexOf(firstChar, 1);
|
|
4146
|
+
if (closingQuoteIndex < 0) {
|
|
4147
|
+
return undefined;
|
|
4148
|
+
}
|
|
4149
|
+
return argsString.slice(1, closingQuoteIndex);
|
|
4150
|
+
}
|
|
4151
|
+
const firstWhitespaceIndex = argsString.search(/\s/);
|
|
4152
|
+
if (firstWhitespaceIndex < 0) {
|
|
4153
|
+
return argsString;
|
|
4154
|
+
}
|
|
4155
|
+
return argsString.slice(0, firstWhitespaceIndex);
|
|
4156
|
+
}
|
|
4157
|
+
async handleImportCommand(text) {
|
|
4158
|
+
const inputPath = this.getPathCommandArgument(text, "/import");
|
|
4159
|
+
if (!inputPath) {
|
|
4160
|
+
this.showError("Usage: /import <path.jsonl>");
|
|
4161
|
+
return;
|
|
4162
|
+
}
|
|
4163
|
+
const confirmed = await this.showExtensionConfirm("Import session", `Replace current session with ${inputPath}?`);
|
|
4164
|
+
if (!confirmed) {
|
|
4165
|
+
this.showStatus("Import cancelled");
|
|
4166
|
+
return;
|
|
4167
|
+
}
|
|
4168
|
+
try {
|
|
4169
|
+
if (this.loadingAnimation) {
|
|
4170
|
+
this.loadingAnimation.stop();
|
|
4171
|
+
this.loadingAnimation = undefined;
|
|
4172
|
+
}
|
|
4173
|
+
this.statusContainer.clear();
|
|
4174
|
+
const result = await this.runtimeHost.importFromJsonl(inputPath);
|
|
4175
|
+
if (result.cancelled) {
|
|
4176
|
+
this.showStatus("Import cancelled");
|
|
4177
|
+
return;
|
|
4178
|
+
}
|
|
4179
|
+
this.renderCurrentSessionState();
|
|
4180
|
+
this.showStatus(`Session imported from: ${inputPath}`);
|
|
4181
|
+
}
|
|
4182
|
+
catch (error) {
|
|
4183
|
+
if (error instanceof MissingSessionCwdError) {
|
|
4184
|
+
const selectedCwd = await this.promptForMissingSessionCwd(error);
|
|
4185
|
+
if (!selectedCwd) {
|
|
4186
|
+
this.showStatus("Import cancelled");
|
|
4187
|
+
return;
|
|
4188
|
+
}
|
|
4189
|
+
const result = await this.runtimeHost.importFromJsonl(inputPath, selectedCwd);
|
|
4190
|
+
if (result.cancelled) {
|
|
4191
|
+
this.showStatus("Import cancelled");
|
|
4192
|
+
return;
|
|
4193
|
+
}
|
|
4194
|
+
this.renderCurrentSessionState();
|
|
4195
|
+
this.showStatus(`Session imported from: ${inputPath}`);
|
|
4196
|
+
return;
|
|
4197
|
+
}
|
|
4198
|
+
if (error instanceof SessionImportFileNotFoundError) {
|
|
4199
|
+
this.showError(`Failed to import session: ${error.message}`);
|
|
4200
|
+
return;
|
|
4201
|
+
}
|
|
4202
|
+
await this.handleFatalRuntimeError("Failed to import session", error);
|
|
4203
|
+
}
|
|
4204
|
+
}
|
|
4205
|
+
async handleShareCommand() {
|
|
4206
|
+
// Check if gh is available and logged in
|
|
4207
|
+
try {
|
|
4208
|
+
const authResult = spawnSync("gh", ["auth", "status"], { encoding: "utf-8" });
|
|
4209
|
+
if (authResult.status !== 0) {
|
|
4210
|
+
this.showError("GitHub CLI is not logged in. Run 'gh auth login' first.");
|
|
4211
|
+
return;
|
|
4212
|
+
}
|
|
4213
|
+
}
|
|
4214
|
+
catch {
|
|
4215
|
+
this.showError("GitHub CLI (gh) is not installed. Install it from https://cli.github.com/");
|
|
4216
|
+
return;
|
|
4217
|
+
}
|
|
4218
|
+
// Export to a temp file
|
|
4219
|
+
const tmpFile = path.join(os.tmpdir(), "session.html");
|
|
4220
|
+
try {
|
|
4221
|
+
await this.session.exportToHtml(tmpFile);
|
|
4222
|
+
}
|
|
4223
|
+
catch (error) {
|
|
4224
|
+
this.showError(`Failed to export session: ${error instanceof Error ? error.message : "Unknown error"}`);
|
|
4225
|
+
return;
|
|
4226
|
+
}
|
|
4227
|
+
// Show cancellable loader, replacing the editor
|
|
4228
|
+
const loader = new BorderedLoader(this.ui, theme, "Creating gist...");
|
|
4229
|
+
this.editorContainer.clear();
|
|
4230
|
+
this.editorContainer.addChild(loader);
|
|
4231
|
+
this.ui.setFocus(loader);
|
|
4232
|
+
this.ui.requestRender();
|
|
4233
|
+
const restoreEditor = () => {
|
|
4234
|
+
loader.dispose();
|
|
4235
|
+
this.editorContainer.clear();
|
|
4236
|
+
this.editorContainer.addChild(this.editor);
|
|
4237
|
+
this.ui.setFocus(this.editor);
|
|
4238
|
+
try {
|
|
4239
|
+
fs.unlinkSync(tmpFile);
|
|
4240
|
+
}
|
|
4241
|
+
catch {
|
|
4242
|
+
// Ignore cleanup errors
|
|
4243
|
+
}
|
|
4244
|
+
};
|
|
4245
|
+
// Create a secret gist asynchronously
|
|
4246
|
+
let proc = null;
|
|
4247
|
+
loader.onAbort = () => {
|
|
4248
|
+
proc?.kill();
|
|
4249
|
+
restoreEditor();
|
|
4250
|
+
this.showStatus("Share cancelled");
|
|
4251
|
+
};
|
|
4252
|
+
try {
|
|
4253
|
+
const result = await new Promise((resolve) => {
|
|
4254
|
+
proc = spawn("gh", ["gist", "create", "--public=false", tmpFile]);
|
|
4255
|
+
let stdout = "";
|
|
4256
|
+
let stderr = "";
|
|
4257
|
+
proc.stdout?.on("data", (data) => {
|
|
4258
|
+
stdout += data.toString();
|
|
4259
|
+
});
|
|
4260
|
+
proc.stderr?.on("data", (data) => {
|
|
4261
|
+
stderr += data.toString();
|
|
4262
|
+
});
|
|
4263
|
+
proc.on("close", (code) => resolve({ stdout, stderr, code }));
|
|
4264
|
+
});
|
|
4265
|
+
if (loader.signal.aborted)
|
|
4266
|
+
return;
|
|
4267
|
+
restoreEditor();
|
|
4268
|
+
if (result.code !== 0) {
|
|
4269
|
+
const errorMsg = result.stderr?.trim() || "Unknown error";
|
|
4270
|
+
this.showError(`Failed to create gist: ${errorMsg}`);
|
|
4271
|
+
return;
|
|
4272
|
+
}
|
|
4273
|
+
// Extract gist ID from the URL returned by gh
|
|
4274
|
+
// gh returns something like: https://gist.github.com/username/GIST_ID
|
|
4275
|
+
const gistUrl = result.stdout?.trim();
|
|
4276
|
+
const gistId = gistUrl?.split("/").pop();
|
|
4277
|
+
if (!gistId) {
|
|
4278
|
+
this.showError("Failed to parse gist ID from gh output");
|
|
4279
|
+
return;
|
|
4280
|
+
}
|
|
4281
|
+
// Create the preview URL
|
|
4282
|
+
const previewUrl = getShareViewerUrl(gistId);
|
|
4283
|
+
this.showStatus(`Share URL: ${previewUrl}\nGist: ${gistUrl}`);
|
|
4284
|
+
}
|
|
4285
|
+
catch (error) {
|
|
4286
|
+
if (!loader.signal.aborted) {
|
|
4287
|
+
restoreEditor();
|
|
4288
|
+
this.showError(`Failed to create gist: ${error instanceof Error ? error.message : "Unknown error"}`);
|
|
4289
|
+
}
|
|
4290
|
+
}
|
|
4291
|
+
}
|
|
4292
|
+
async handleCopyCommand() {
|
|
4293
|
+
const text = this.session.getLastAssistantText();
|
|
4294
|
+
if (!text) {
|
|
4295
|
+
this.showError("No agent messages to copy yet.");
|
|
4296
|
+
return;
|
|
4297
|
+
}
|
|
4298
|
+
try {
|
|
4299
|
+
await copyToClipboard(text);
|
|
4300
|
+
this.showStatus("Copied last agent message to clipboard");
|
|
4301
|
+
}
|
|
4302
|
+
catch (error) {
|
|
4303
|
+
this.showError(error instanceof Error ? error.message : String(error));
|
|
4304
|
+
}
|
|
4305
|
+
}
|
|
4306
|
+
handleNameCommand(text) {
|
|
4307
|
+
const name = text.replace(/^\/name\s*/, "").trim();
|
|
4308
|
+
if (!name) {
|
|
4309
|
+
const currentName = this.sessionManager.getSessionName();
|
|
4310
|
+
if (currentName) {
|
|
4311
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4312
|
+
this.chatContainer.addChild(new Text(theme.fg("dim", `Session name: ${currentName}`), 1, 0));
|
|
4313
|
+
}
|
|
4314
|
+
else {
|
|
4315
|
+
this.showWarning("Usage: /name <name>");
|
|
4316
|
+
}
|
|
4317
|
+
this.ui.requestRender();
|
|
4318
|
+
return;
|
|
4319
|
+
}
|
|
4320
|
+
this.session.setSessionName(name);
|
|
4321
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4322
|
+
this.chatContainer.addChild(new Text(theme.fg("dim", `Session name set: ${name}`), 1, 0));
|
|
4323
|
+
this.ui.requestRender();
|
|
4324
|
+
}
|
|
4325
|
+
handleSessionCommand() {
|
|
4326
|
+
const stats = this.session.getSessionStats();
|
|
4327
|
+
const sessionName = this.sessionManager.getSessionName();
|
|
4328
|
+
let info = `${theme.bold("Session Info")}\n\n`;
|
|
4329
|
+
if (sessionName) {
|
|
4330
|
+
info += `${theme.fg("dim", "Name:")} ${sessionName}\n`;
|
|
4331
|
+
}
|
|
4332
|
+
info += `${theme.fg("dim", "File:")} ${stats.sessionFile ?? "In-memory"}\n`;
|
|
4333
|
+
info += `${theme.fg("dim", "ID:")} ${stats.sessionId}\n\n`;
|
|
4334
|
+
info += `${theme.bold("Messages")}\n`;
|
|
4335
|
+
info += `${theme.fg("dim", "User:")} ${stats.userMessages}\n`;
|
|
4336
|
+
info += `${theme.fg("dim", "Assistant:")} ${stats.assistantMessages}\n`;
|
|
4337
|
+
info += `${theme.fg("dim", "Tool Calls:")} ${stats.toolCalls}\n`;
|
|
4338
|
+
info += `${theme.fg("dim", "Tool Results:")} ${stats.toolResults}\n`;
|
|
4339
|
+
info += `${theme.fg("dim", "Total:")} ${stats.totalMessages}\n\n`;
|
|
4340
|
+
info += `${theme.bold("Tokens")}\n`;
|
|
4341
|
+
info += `${theme.fg("dim", "Input:")} ${stats.tokens.input.toLocaleString()}\n`;
|
|
4342
|
+
info += `${theme.fg("dim", "Output:")} ${stats.tokens.output.toLocaleString()}\n`;
|
|
4343
|
+
if (stats.tokens.cacheRead > 0) {
|
|
4344
|
+
info += `${theme.fg("dim", "Cache Read:")} ${stats.tokens.cacheRead.toLocaleString()}\n`;
|
|
4345
|
+
}
|
|
4346
|
+
if (stats.tokens.cacheWrite > 0) {
|
|
4347
|
+
info += `${theme.fg("dim", "Cache Write:")} ${stats.tokens.cacheWrite.toLocaleString()}\n`;
|
|
4348
|
+
}
|
|
4349
|
+
info += `${theme.fg("dim", "Total:")} ${stats.tokens.total.toLocaleString()}\n`;
|
|
4350
|
+
if (stats.cost > 0) {
|
|
4351
|
+
info += `\n${theme.bold("Cost")}\n`;
|
|
4352
|
+
info += `${theme.fg("dim", "Total:")} ${stats.cost.toFixed(4)}`;
|
|
4353
|
+
}
|
|
4354
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4355
|
+
this.chatContainer.addChild(new Text(info, 1, 0));
|
|
4356
|
+
this.ui.requestRender();
|
|
4357
|
+
}
|
|
4358
|
+
handleChangelogCommand() {
|
|
4359
|
+
const changelogPath = getChangelogPath();
|
|
4360
|
+
const allEntries = parseChangelog(changelogPath);
|
|
4361
|
+
const changelogMarkdown = allEntries.length > 0
|
|
4362
|
+
? allEntries
|
|
4363
|
+
.reverse()
|
|
4364
|
+
.map((e) => e.content)
|
|
4365
|
+
.join("\n\n")
|
|
4366
|
+
: "No changelog entries found.";
|
|
4367
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4368
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
4369
|
+
this.chatContainer.addChild(new Text(theme.bold(theme.fg("accent", "What's New")), 1, 0));
|
|
4370
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4371
|
+
this.chatContainer.addChild(new Markdown(changelogMarkdown, 1, 1, this.getMarkdownThemeWithSettings()));
|
|
4372
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
4373
|
+
this.ui.requestRender();
|
|
4374
|
+
}
|
|
4375
|
+
/**
|
|
4376
|
+
* Get capitalized display string for an app keybinding action.
|
|
4377
|
+
*/
|
|
4378
|
+
getAppKeyDisplay(action) {
|
|
4379
|
+
return keyDisplayText(action);
|
|
4380
|
+
}
|
|
4381
|
+
/**
|
|
4382
|
+
* Get capitalized display string for an editor keybinding action.
|
|
4383
|
+
*/
|
|
4384
|
+
getEditorKeyDisplay(action) {
|
|
4385
|
+
return keyDisplayText(action);
|
|
4386
|
+
}
|
|
4387
|
+
handleHotkeysCommand() {
|
|
4388
|
+
// Navigation keybindings
|
|
4389
|
+
const cursorUp = this.getEditorKeyDisplay("tui.editor.cursorUp");
|
|
4390
|
+
const cursorDown = this.getEditorKeyDisplay("tui.editor.cursorDown");
|
|
4391
|
+
const cursorLeft = this.getEditorKeyDisplay("tui.editor.cursorLeft");
|
|
4392
|
+
const cursorRight = this.getEditorKeyDisplay("tui.editor.cursorRight");
|
|
4393
|
+
const cursorWordLeft = this.getEditorKeyDisplay("tui.editor.cursorWordLeft");
|
|
4394
|
+
const cursorWordRight = this.getEditorKeyDisplay("tui.editor.cursorWordRight");
|
|
4395
|
+
const cursorLineStart = this.getEditorKeyDisplay("tui.editor.cursorLineStart");
|
|
4396
|
+
const cursorLineEnd = this.getEditorKeyDisplay("tui.editor.cursorLineEnd");
|
|
4397
|
+
const jumpForward = this.getEditorKeyDisplay("tui.editor.jumpForward");
|
|
4398
|
+
const jumpBackward = this.getEditorKeyDisplay("tui.editor.jumpBackward");
|
|
4399
|
+
const pageUp = this.getEditorKeyDisplay("tui.editor.pageUp");
|
|
4400
|
+
const pageDown = this.getEditorKeyDisplay("tui.editor.pageDown");
|
|
4401
|
+
// Editing keybindings
|
|
4402
|
+
const submit = this.getEditorKeyDisplay("tui.input.submit");
|
|
4403
|
+
const newLine = this.getEditorKeyDisplay("tui.input.newLine");
|
|
4404
|
+
const deleteWordBackward = this.getEditorKeyDisplay("tui.editor.deleteWordBackward");
|
|
4405
|
+
const deleteWordForward = this.getEditorKeyDisplay("tui.editor.deleteWordForward");
|
|
4406
|
+
const deleteToLineStart = this.getEditorKeyDisplay("tui.editor.deleteToLineStart");
|
|
4407
|
+
const deleteToLineEnd = this.getEditorKeyDisplay("tui.editor.deleteToLineEnd");
|
|
4408
|
+
const yank = this.getEditorKeyDisplay("tui.editor.yank");
|
|
4409
|
+
const yankPop = this.getEditorKeyDisplay("tui.editor.yankPop");
|
|
4410
|
+
const undo = this.getEditorKeyDisplay("tui.editor.undo");
|
|
4411
|
+
const tab = this.getEditorKeyDisplay("tui.input.tab");
|
|
4412
|
+
// App keybindings
|
|
4413
|
+
const interrupt = this.getAppKeyDisplay("app.interrupt");
|
|
4414
|
+
const clear = this.getAppKeyDisplay("app.clear");
|
|
4415
|
+
const exit = this.getAppKeyDisplay("app.exit");
|
|
4416
|
+
const suspend = this.getAppKeyDisplay("app.suspend");
|
|
4417
|
+
const cycleThinkingLevel = this.getAppKeyDisplay("app.thinking.cycle");
|
|
4418
|
+
const cycleModelForward = this.getAppKeyDisplay("app.model.cycleForward");
|
|
4419
|
+
const selectModel = this.getAppKeyDisplay("app.model.select");
|
|
4420
|
+
const expandTools = this.getAppKeyDisplay("app.tools.expand");
|
|
4421
|
+
const toggleThinking = this.getAppKeyDisplay("app.thinking.toggle");
|
|
4422
|
+
const externalEditor = this.getAppKeyDisplay("app.editor.external");
|
|
4423
|
+
const cycleModelBackward = this.getAppKeyDisplay("app.model.cycleBackward");
|
|
4424
|
+
const followUp = this.getAppKeyDisplay("app.message.followUp");
|
|
4425
|
+
const dequeue = this.getAppKeyDisplay("app.message.dequeue");
|
|
4426
|
+
const pasteImage = this.getAppKeyDisplay("app.clipboard.pasteImage");
|
|
4427
|
+
let hotkeys = `
|
|
4428
|
+
**Navigation**
|
|
4429
|
+
| Key | Action |
|
|
4430
|
+
|-----|--------|
|
|
4431
|
+
| \`${cursorUp}\` / \`${cursorDown}\` / \`${cursorLeft}\` / \`${cursorRight}\` | Move cursor / browse history (Up when empty) |
|
|
4432
|
+
| \`${cursorWordLeft}\` / \`${cursorWordRight}\` | Move by word |
|
|
4433
|
+
| \`${cursorLineStart}\` | Start of line |
|
|
4434
|
+
| \`${cursorLineEnd}\` | End of line |
|
|
4435
|
+
| \`${jumpForward}\` | Jump forward to character |
|
|
4436
|
+
| \`${jumpBackward}\` | Jump backward to character |
|
|
4437
|
+
| \`${pageUp}\` / \`${pageDown}\` | Scroll by page |
|
|
4438
|
+
|
|
4439
|
+
**Editing**
|
|
4440
|
+
| Key | Action |
|
|
4441
|
+
|-----|--------|
|
|
4442
|
+
| \`${submit}\` | Send message |
|
|
4443
|
+
| \`${newLine}\` | New line${process.platform === "win32" ? " (Ctrl+Enter on Windows Terminal)" : ""} |
|
|
4444
|
+
| \`${deleteWordBackward}\` | Delete word backwards |
|
|
4445
|
+
| \`${deleteWordForward}\` | Delete word forwards |
|
|
4446
|
+
| \`${deleteToLineStart}\` | Delete to start of line |
|
|
4447
|
+
| \`${deleteToLineEnd}\` | Delete to end of line |
|
|
4448
|
+
| \`${yank}\` | Paste the most-recently-deleted text |
|
|
4449
|
+
| \`${yankPop}\` | Cycle through the deleted text after pasting |
|
|
4450
|
+
| \`${undo}\` | Undo |
|
|
4451
|
+
|
|
4452
|
+
**Other**
|
|
4453
|
+
| Key | Action |
|
|
4454
|
+
|-----|--------|
|
|
4455
|
+
| \`${tab}\` | Path completion / accept autocomplete |
|
|
4456
|
+
| \`${interrupt}\` | Cancel autocomplete / abort streaming |
|
|
4457
|
+
| \`${clear}\` | Clear editor (first) / exit (second) |
|
|
4458
|
+
| \`${exit}\` | Exit (when editor is empty) |
|
|
4459
|
+
| \`${suspend}\` | Suspend to background |
|
|
4460
|
+
| \`${cycleThinkingLevel}\` | Cycle thinking level |
|
|
4461
|
+
| \`${cycleModelForward}\` / \`${cycleModelBackward}\` | Cycle models |
|
|
4462
|
+
| \`${selectModel}\` | Open model selector |
|
|
4463
|
+
| \`${expandTools}\` | Toggle tool output expansion |
|
|
4464
|
+
| \`${toggleThinking}\` | Toggle thinking block visibility |
|
|
4465
|
+
| \`${externalEditor}\` | Edit message in external editor |
|
|
4466
|
+
| \`${followUp}\` | Queue follow-up message |
|
|
4467
|
+
| \`${dequeue}\` | Restore queued messages |
|
|
4468
|
+
| \`${pasteImage}\` | Paste image from clipboard |
|
|
4469
|
+
| \`/\` | Slash commands |
|
|
4470
|
+
| \`!\` | Run bash command |
|
|
4471
|
+
| \`!!\` | Run bash command (excluded from context) |
|
|
4472
|
+
`;
|
|
4473
|
+
// Add extension-registered shortcuts
|
|
4474
|
+
const extensionRunner = this.session.extensionRunner;
|
|
4475
|
+
const shortcuts = extensionRunner.getShortcuts(this.keybindings.getEffectiveConfig());
|
|
4476
|
+
if (shortcuts.size > 0) {
|
|
4477
|
+
hotkeys += `
|
|
4478
|
+
**Extensions**
|
|
4479
|
+
| Key | Action |
|
|
4480
|
+
|-----|--------|
|
|
4481
|
+
`;
|
|
4482
|
+
for (const [key, shortcut] of shortcuts) {
|
|
4483
|
+
const description = shortcut.description ?? shortcut.extensionPath;
|
|
4484
|
+
const keyDisplay = formatKeyText(key, { capitalize: true });
|
|
4485
|
+
hotkeys += `| \`${keyDisplay}\` | ${description} |\n`;
|
|
4486
|
+
}
|
|
4487
|
+
}
|
|
4488
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4489
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
4490
|
+
this.chatContainer.addChild(new Text(theme.bold(theme.fg("accent", "Keyboard Shortcuts")), 1, 0));
|
|
4491
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4492
|
+
this.chatContainer.addChild(new Markdown(hotkeys.trim(), 1, 1, this.getMarkdownThemeWithSettings()));
|
|
4493
|
+
this.chatContainer.addChild(new DynamicBorder());
|
|
4494
|
+
this.ui.requestRender();
|
|
4495
|
+
}
|
|
4496
|
+
async handleClearCommand() {
|
|
4497
|
+
if (this.loadingAnimation) {
|
|
4498
|
+
this.loadingAnimation.stop();
|
|
4499
|
+
this.loadingAnimation = undefined;
|
|
4500
|
+
}
|
|
4501
|
+
this.statusContainer.clear();
|
|
4502
|
+
try {
|
|
4503
|
+
const result = await this.runtimeHost.newSession();
|
|
4504
|
+
if (result.cancelled) {
|
|
4505
|
+
return;
|
|
4506
|
+
}
|
|
4507
|
+
this.renderCurrentSessionState();
|
|
4508
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4509
|
+
this.chatContainer.addChild(new Text(`${theme.fg("accent", "✓ New session started")}`, 1, 1));
|
|
4510
|
+
this.ui.requestRender();
|
|
4511
|
+
}
|
|
4512
|
+
catch (error) {
|
|
4513
|
+
await this.handleFatalRuntimeError("Failed to create session", error);
|
|
4514
|
+
}
|
|
4515
|
+
}
|
|
4516
|
+
handleDebugCommand() {
|
|
4517
|
+
const width = this.ui.terminal.columns;
|
|
4518
|
+
const height = this.ui.terminal.rows;
|
|
4519
|
+
const allLines = this.ui.render(width);
|
|
4520
|
+
const debugLogPath = getDebugLogPath();
|
|
4521
|
+
const debugData = [
|
|
4522
|
+
`Debug output at ${new Date().toISOString()}`,
|
|
4523
|
+
`Terminal: ${width}x${height}`,
|
|
4524
|
+
`Total lines: ${allLines.length}`,
|
|
4525
|
+
"",
|
|
4526
|
+
"=== All rendered lines with visible widths ===",
|
|
4527
|
+
...allLines.map((line, idx) => {
|
|
4528
|
+
const vw = visibleWidth(line);
|
|
4529
|
+
const escaped = JSON.stringify(line);
|
|
4530
|
+
return `[${idx}] (w=${vw}) ${escaped}`;
|
|
4531
|
+
}),
|
|
4532
|
+
"",
|
|
4533
|
+
"=== Agent messages (JSONL) ===",
|
|
4534
|
+
...this.session.messages.map((msg) => JSON.stringify(msg)),
|
|
4535
|
+
"",
|
|
4536
|
+
].join("\n");
|
|
4537
|
+
fs.mkdirSync(path.dirname(debugLogPath), { recursive: true });
|
|
4538
|
+
fs.writeFileSync(debugLogPath, debugData);
|
|
4539
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4540
|
+
this.chatContainer.addChild(new Text(`${theme.fg("accent", "✓ Debug log written")}\n${theme.fg("muted", debugLogPath)}`, 1, 1));
|
|
4541
|
+
this.ui.requestRender();
|
|
4542
|
+
}
|
|
4543
|
+
handleArminSaysHi() {
|
|
4544
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4545
|
+
this.chatContainer.addChild(new ArminComponent(this.ui));
|
|
4546
|
+
this.ui.requestRender();
|
|
4547
|
+
}
|
|
4548
|
+
handleDementedDelves() {
|
|
4549
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4550
|
+
this.chatContainer.addChild(new EarendilAnnouncementComponent());
|
|
4551
|
+
this.ui.requestRender();
|
|
4552
|
+
}
|
|
4553
|
+
handleDaxnuts() {
|
|
4554
|
+
this.chatContainer.addChild(new Spacer(1));
|
|
4555
|
+
this.chatContainer.addChild(new DaxnutsComponent(this.ui));
|
|
4556
|
+
this.ui.requestRender();
|
|
4557
|
+
}
|
|
4558
|
+
checkDaxnutsEasterEgg(model) {
|
|
4559
|
+
if (model.provider === "opencode" && model.id.toLowerCase().includes("kimi-k2.5")) {
|
|
4560
|
+
this.handleDaxnuts();
|
|
4561
|
+
}
|
|
4562
|
+
}
|
|
4563
|
+
async handleBashCommand(command, excludeFromContext = false) {
|
|
4564
|
+
const extensionRunner = this.session.extensionRunner;
|
|
4565
|
+
// Emit user_bash event to let extensions intercept
|
|
4566
|
+
const eventResult = await extensionRunner.emitUserBash({
|
|
4567
|
+
type: "user_bash",
|
|
4568
|
+
command,
|
|
4569
|
+
excludeFromContext,
|
|
4570
|
+
cwd: this.sessionManager.getCwd(),
|
|
4571
|
+
});
|
|
4572
|
+
// If extension returned a full result, use it directly
|
|
4573
|
+
if (eventResult?.result) {
|
|
4574
|
+
const result = eventResult.result;
|
|
4575
|
+
// Create UI component for display
|
|
4576
|
+
this.bashComponent = new BashExecutionComponent(command, this.ui, excludeFromContext);
|
|
4577
|
+
if (this.session.isStreaming) {
|
|
4578
|
+
this.pendingMessagesContainer.addChild(this.bashComponent);
|
|
4579
|
+
this.pendingBashComponents.push(this.bashComponent);
|
|
4580
|
+
}
|
|
4581
|
+
else {
|
|
4582
|
+
this.chatContainer.addChild(this.bashComponent);
|
|
4583
|
+
}
|
|
4584
|
+
// Show output and complete
|
|
4585
|
+
if (result.output) {
|
|
4586
|
+
this.bashComponent.appendOutput(result.output);
|
|
4587
|
+
}
|
|
4588
|
+
this.bashComponent.setComplete(result.exitCode, result.cancelled, result.truncated ? { truncated: true, content: result.output } : undefined, result.fullOutputPath);
|
|
4589
|
+
// Record the result in session
|
|
4590
|
+
this.session.recordBashResult(command, result, { excludeFromContext });
|
|
4591
|
+
this.bashComponent = undefined;
|
|
4592
|
+
this.ui.requestRender();
|
|
4593
|
+
return;
|
|
4594
|
+
}
|
|
4595
|
+
// Normal execution path (possibly with custom operations)
|
|
4596
|
+
const isDeferred = this.session.isStreaming;
|
|
4597
|
+
this.bashComponent = new BashExecutionComponent(command, this.ui, excludeFromContext);
|
|
4598
|
+
if (isDeferred) {
|
|
4599
|
+
// Show in pending area when agent is streaming
|
|
4600
|
+
this.pendingMessagesContainer.addChild(this.bashComponent);
|
|
4601
|
+
this.pendingBashComponents.push(this.bashComponent);
|
|
4602
|
+
}
|
|
4603
|
+
else {
|
|
4604
|
+
// Show in chat immediately when agent is idle
|
|
4605
|
+
this.chatContainer.addChild(this.bashComponent);
|
|
4606
|
+
}
|
|
4607
|
+
this.ui.requestRender();
|
|
4608
|
+
try {
|
|
4609
|
+
const result = await this.session.executeBash(command, (chunk) => {
|
|
4610
|
+
if (this.bashComponent) {
|
|
4611
|
+
this.bashComponent.appendOutput(chunk);
|
|
4612
|
+
this.ui.requestRender();
|
|
4613
|
+
}
|
|
4614
|
+
}, { excludeFromContext, operations: eventResult?.operations });
|
|
4615
|
+
if (this.bashComponent) {
|
|
4616
|
+
this.bashComponent.setComplete(result.exitCode, result.cancelled, result.truncated ? { truncated: true, content: result.output } : undefined, result.fullOutputPath);
|
|
4617
|
+
}
|
|
4618
|
+
}
|
|
4619
|
+
catch (error) {
|
|
4620
|
+
if (this.bashComponent) {
|
|
4621
|
+
this.bashComponent.setComplete(undefined, false);
|
|
4622
|
+
}
|
|
4623
|
+
this.showError(`Bash command failed: ${error instanceof Error ? error.message : "Unknown error"}`);
|
|
4624
|
+
}
|
|
4625
|
+
this.bashComponent = undefined;
|
|
4626
|
+
this.ui.requestRender();
|
|
4627
|
+
}
|
|
4628
|
+
async handleCompactCommand(customInstructions) {
|
|
4629
|
+
const entries = this.sessionManager.getEntries();
|
|
4630
|
+
const messageCount = entries.filter((e) => e.type === "message").length;
|
|
4631
|
+
if (messageCount < 2) {
|
|
4632
|
+
this.showWarning("Nothing to compact (no messages yet)");
|
|
4633
|
+
return;
|
|
4634
|
+
}
|
|
4635
|
+
if (this.loadingAnimation) {
|
|
4636
|
+
this.loadingAnimation.stop();
|
|
4637
|
+
this.loadingAnimation = undefined;
|
|
4638
|
+
}
|
|
4639
|
+
this.statusContainer.clear();
|
|
4640
|
+
try {
|
|
4641
|
+
await this.session.compact(customInstructions);
|
|
4642
|
+
}
|
|
4643
|
+
catch {
|
|
4644
|
+
// Ignore, will be emitted as an event
|
|
4645
|
+
}
|
|
4646
|
+
}
|
|
4647
|
+
stop() {
|
|
4648
|
+
this.unregisterSignalHandlers();
|
|
4649
|
+
if (this.settingsManager.getShowTerminalProgress()) {
|
|
4650
|
+
this.ui.terminal.setProgress(false);
|
|
4651
|
+
}
|
|
4652
|
+
if (this.loadingAnimation) {
|
|
4653
|
+
this.loadingAnimation.stop();
|
|
4654
|
+
this.loadingAnimation = undefined;
|
|
4655
|
+
}
|
|
4656
|
+
this.clearExtensionTerminalInputListeners();
|
|
4657
|
+
this.footer.dispose();
|
|
4658
|
+
this.footerDataProvider.dispose();
|
|
4659
|
+
if (this.unsubscribe) {
|
|
4660
|
+
this.unsubscribe();
|
|
4661
|
+
}
|
|
4662
|
+
if (this.isInitialized) {
|
|
4663
|
+
this.ui.stop();
|
|
4664
|
+
this.isInitialized = false;
|
|
4665
|
+
}
|
|
4666
|
+
}
|
|
4667
|
+
}
|
|
4668
|
+
//# sourceMappingURL=interactive-mode.js.map
|