@averyyy/pi-coding-agent 0.80.3-piclient.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4848 -0
- package/README.md +689 -0
- package/dist/bun/cli.d.ts +3 -0
- package/dist/bun/cli.d.ts.map +1 -0
- package/dist/bun/cli.js +9 -0
- package/dist/bun/cli.js.map +1 -0
- package/dist/bun/register-bedrock.d.ts +2 -0
- package/dist/bun/register-bedrock.d.ts.map +1 -0
- package/dist/bun/register-bedrock.js +4 -0
- package/dist/bun/register-bedrock.js.map +1 -0
- package/dist/bun/restore-sandbox-env.d.ts +17 -0
- package/dist/bun/restore-sandbox-env.d.ts.map +1 -0
- package/dist/bun/restore-sandbox-env.js +36 -0
- package/dist/bun/restore-sandbox-env.js.map +1 -0
- package/dist/cli/args.d.ts +57 -0
- package/dist/cli/args.d.ts.map +1 -0
- package/dist/cli/args.js +379 -0
- package/dist/cli/args.js.map +1 -0
- package/dist/cli/config-selector.d.ts +14 -0
- package/dist/cli/config-selector.d.ts.map +1 -0
- package/dist/cli/config-selector.js +31 -0
- package/dist/cli/config-selector.js.map +1 -0
- package/dist/cli/file-processor.d.ts +15 -0
- package/dist/cli/file-processor.d.ts.map +1 -0
- package/dist/cli/file-processor.js +70 -0
- package/dist/cli/file-processor.js.map +1 -0
- package/dist/cli/initial-message.d.ts +18 -0
- package/dist/cli/initial-message.d.ts.map +1 -0
- package/dist/cli/initial-message.js +22 -0
- package/dist/cli/initial-message.js.map +1 -0
- package/dist/cli/list-models.d.ts +9 -0
- package/dist/cli/list-models.d.ts.map +1 -0
- package/dist/cli/list-models.js +98 -0
- package/dist/cli/list-models.js.map +1 -0
- package/dist/cli/project-trust.d.ts +10 -0
- package/dist/cli/project-trust.d.ts.map +1 -0
- package/dist/cli/project-trust.js +48 -0
- package/dist/cli/project-trust.js.map +1 -0
- package/dist/cli/session-picker.d.ts +10 -0
- package/dist/cli/session-picker.d.ts.map +1 -0
- package/dist/cli/session-picker.js +36 -0
- package/dist/cli/session-picker.js.map +1 -0
- package/dist/cli/startup-ui.d.ts +20 -0
- package/dist/cli/startup-ui.d.ts.map +1 -0
- package/dist/cli/startup-ui.js +184 -0
- package/dist/cli/startup-ui.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +18 -0
- package/dist/cli.js.map +1 -0
- package/dist/config.d.ts +96 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +455 -0
- package/dist/config.js.map +1 -0
- package/dist/core/agent-session-runtime.d.ts +119 -0
- package/dist/core/agent-session-runtime.d.ts.map +1 -0
- package/dist/core/agent-session-runtime.js +307 -0
- package/dist/core/agent-session-runtime.js.map +1 -0
- package/dist/core/agent-session-services.d.ts +88 -0
- package/dist/core/agent-session-services.d.ts.map +1 -0
- package/dist/core/agent-session-services.js +119 -0
- package/dist/core/agent-session-services.js.map +1 -0
- package/dist/core/agent-session.d.ts +620 -0
- package/dist/core/agent-session.d.ts.map +1 -0
- package/dist/core/agent-session.js +2728 -0
- package/dist/core/agent-session.js.map +1 -0
- package/dist/core/auth-guidance.d.ts +5 -0
- package/dist/core/auth-guidance.d.ts.map +1 -0
- package/dist/core/auth-guidance.js +21 -0
- package/dist/core/auth-guidance.js.map +1 -0
- package/dist/core/auth-storage.d.ts +140 -0
- package/dist/core/auth-storage.d.ts.map +1 -0
- package/dist/core/auth-storage.js +434 -0
- package/dist/core/auth-storage.js.map +1 -0
- package/dist/core/bash-executor.d.ts +32 -0
- package/dist/core/bash-executor.d.ts.map +1 -0
- package/dist/core/bash-executor.js +111 -0
- package/dist/core/bash-executor.js.map +1 -0
- package/dist/core/compaction/branch-summarization.d.ts +92 -0
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -0
- package/dist/core/compaction/branch-summarization.js +241 -0
- package/dist/core/compaction/branch-summarization.js.map +1 -0
- package/dist/core/compaction/compaction.d.ts +123 -0
- package/dist/core/compaction/compaction.d.ts.map +1 -0
- package/dist/core/compaction/compaction.js +682 -0
- package/dist/core/compaction/compaction.js.map +1 -0
- package/dist/core/compaction/index.d.ts +7 -0
- package/dist/core/compaction/index.d.ts.map +1 -0
- package/dist/core/compaction/index.js +7 -0
- package/dist/core/compaction/index.js.map +1 -0
- package/dist/core/compaction/utils.d.ts +38 -0
- package/dist/core/compaction/utils.d.ts.map +1 -0
- package/dist/core/compaction/utils.js +153 -0
- package/dist/core/compaction/utils.js.map +1 -0
- package/dist/core/defaults.d.ts +3 -0
- package/dist/core/defaults.d.ts.map +1 -0
- package/dist/core/defaults.js +2 -0
- package/dist/core/defaults.js.map +1 -0
- package/dist/core/diagnostics.d.ts +15 -0
- package/dist/core/diagnostics.d.ts.map +1 -0
- package/dist/core/diagnostics.js +2 -0
- package/dist/core/diagnostics.js.map +1 -0
- package/dist/core/event-bus.d.ts +9 -0
- package/dist/core/event-bus.d.ts.map +1 -0
- package/dist/core/event-bus.js +25 -0
- package/dist/core/event-bus.js.map +1 -0
- package/dist/core/exec.d.ts +29 -0
- package/dist/core/exec.d.ts.map +1 -0
- package/dist/core/exec.js +75 -0
- package/dist/core/exec.js.map +1 -0
- package/dist/core/experimental.d.ts +2 -0
- package/dist/core/experimental.d.ts.map +1 -0
- package/dist/core/experimental.js +4 -0
- package/dist/core/experimental.js.map +1 -0
- package/dist/core/export-html/ansi-to-html.d.ts +22 -0
- package/dist/core/export-html/ansi-to-html.d.ts.map +1 -0
- package/dist/core/export-html/ansi-to-html.js +249 -0
- package/dist/core/export-html/ansi-to-html.js.map +1 -0
- package/dist/core/export-html/index.d.ts +37 -0
- package/dist/core/export-html/index.d.ts.map +1 -0
- package/dist/core/export-html/index.js +226 -0
- package/dist/core/export-html/index.js.map +1 -0
- package/dist/core/export-html/template.css +1066 -0
- package/dist/core/export-html/template.html +55 -0
- package/dist/core/export-html/template.js +1864 -0
- package/dist/core/export-html/tool-renderer.d.ts +34 -0
- package/dist/core/export-html/tool-renderer.d.ts.map +1 -0
- package/dist/core/export-html/tool-renderer.js +108 -0
- package/dist/core/export-html/tool-renderer.js.map +1 -0
- package/dist/core/export-html/vendor/highlight.min.js +1213 -0
- package/dist/core/export-html/vendor/marked.min.js +78 -0
- package/dist/core/extensions/index.d.ts +12 -0
- package/dist/core/extensions/index.d.ts.map +1 -0
- package/dist/core/extensions/index.js +9 -0
- package/dist/core/extensions/index.js.map +1 -0
- package/dist/core/extensions/loader.d.ts +23 -0
- package/dist/core/extensions/loader.d.ts.map +1 -0
- package/dist/core/extensions/loader.js +535 -0
- package/dist/core/extensions/loader.js.map +1 -0
- package/dist/core/extensions/runner.d.ts +166 -0
- package/dist/core/extensions/runner.d.ts.map +1 -0
- package/dist/core/extensions/runner.js +876 -0
- package/dist/core/extensions/runner.js.map +1 -0
- package/dist/core/extensions/types.d.ts +1216 -0
- package/dist/core/extensions/types.d.ts.map +1 -0
- package/dist/core/extensions/types.js +45 -0
- package/dist/core/extensions/types.js.map +1 -0
- package/dist/core/extensions/wrapper.d.ts +20 -0
- package/dist/core/extensions/wrapper.d.ts.map +1 -0
- package/dist/core/extensions/wrapper.js +22 -0
- package/dist/core/extensions/wrapper.js.map +1 -0
- package/dist/core/footer-data-provider.d.ts +54 -0
- package/dist/core/footer-data-provider.d.ts.map +1 -0
- package/dist/core/footer-data-provider.js +338 -0
- package/dist/core/footer-data-provider.js.map +1 -0
- package/dist/core/http-dispatcher.d.ts +22 -0
- package/dist/core/http-dispatcher.d.ts.map +1 -0
- package/dist/core/http-dispatcher.js +91 -0
- package/dist/core/http-dispatcher.js.map +1 -0
- package/dist/core/index.d.ts +13 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +13 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/keybindings.d.ts +353 -0
- package/dist/core/keybindings.d.ts.map +1 -0
- package/dist/core/keybindings.js +295 -0
- package/dist/core/keybindings.js.map +1 -0
- package/dist/core/messages.d.ts +77 -0
- package/dist/core/messages.d.ts.map +1 -0
- package/dist/core/messages.js +123 -0
- package/dist/core/messages.js.map +1 -0
- package/dist/core/model-registry.d.ts +151 -0
- package/dist/core/model-registry.d.ts.map +1 -0
- package/dist/core/model-registry.js +750 -0
- package/dist/core/model-registry.js.map +1 -0
- package/dist/core/model-resolver.d.ts +111 -0
- package/dist/core/model-resolver.d.ts.map +1 -0
- package/dist/core/model-resolver.js +534 -0
- package/dist/core/model-resolver.js.map +1 -0
- package/dist/core/output-guard.d.ts +7 -0
- package/dist/core/output-guard.d.ts.map +1 -0
- package/dist/core/output-guard.js +89 -0
- package/dist/core/output-guard.js.map +1 -0
- package/dist/core/package-manager.d.ts +207 -0
- package/dist/core/package-manager.d.ts.map +1 -0
- package/dist/core/package-manager.js +2088 -0
- package/dist/core/package-manager.js.map +1 -0
- package/dist/core/pi-server-client.d.ts +47 -0
- package/dist/core/pi-server-client.d.ts.map +1 -0
- package/dist/core/pi-server-client.js +571 -0
- package/dist/core/pi-server-client.js.map +1 -0
- package/dist/core/pi-server-request.d.ts +14 -0
- package/dist/core/pi-server-request.d.ts.map +1 -0
- package/dist/core/pi-server-request.js +204 -0
- package/dist/core/pi-server-request.js.map +1 -0
- package/dist/core/project-trust.d.ts +15 -0
- package/dist/core/project-trust.d.ts.map +1 -0
- package/dist/core/project-trust.js +59 -0
- package/dist/core/project-trust.js.map +1 -0
- package/dist/core/prompt-templates.d.ts +53 -0
- package/dist/core/prompt-templates.d.ts.map +1 -0
- package/dist/core/prompt-templates.js +236 -0
- package/dist/core/prompt-templates.js.map +1 -0
- package/dist/core/provider-attribution.d.ts +4 -0
- package/dist/core/provider-attribution.d.ts.map +1 -0
- package/dist/core/provider-attribution.js +82 -0
- package/dist/core/provider-attribution.js.map +1 -0
- package/dist/core/provider-display-names.d.ts +2 -0
- package/dist/core/provider-display-names.d.ts.map +1 -0
- package/dist/core/provider-display-names.js +36 -0
- package/dist/core/provider-display-names.js.map +1 -0
- package/dist/core/resolve-config-value.d.ts +30 -0
- package/dist/core/resolve-config-value.d.ts.map +1 -0
- package/dist/core/resolve-config-value.js +247 -0
- package/dist/core/resolve-config-value.js.map +1 -0
- package/dist/core/resource-loader.d.ts +206 -0
- package/dist/core/resource-loader.d.ts.map +1 -0
- package/dist/core/resource-loader.js +817 -0
- package/dist/core/resource-loader.js.map +1 -0
- package/dist/core/sdk.d.ts +109 -0
- package/dist/core/sdk.d.ts.map +1 -0
- package/dist/core/sdk.js +313 -0
- package/dist/core/sdk.js.map +1 -0
- package/dist/core/session-cwd.d.ts +19 -0
- package/dist/core/session-cwd.d.ts.map +1 -0
- package/dist/core/session-cwd.js +38 -0
- package/dist/core/session-cwd.js.map +1 -0
- package/dist/core/session-manager.d.ts +334 -0
- package/dist/core/session-manager.d.ts.map +1 -0
- package/dist/core/session-manager.js +1284 -0
- package/dist/core/session-manager.js.map +1 -0
- package/dist/core/settings-manager.d.ts +291 -0
- package/dist/core/settings-manager.d.ts.map +1 -0
- package/dist/core/settings-manager.js +893 -0
- package/dist/core/settings-manager.js.map +1 -0
- package/dist/core/skills.d.ts +60 -0
- package/dist/core/skills.d.ts.map +1 -0
- package/dist/core/skills.js +387 -0
- package/dist/core/skills.js.map +1 -0
- package/dist/core/slash-commands.d.ts +14 -0
- package/dist/core/slash-commands.d.ts.map +1 -0
- package/dist/core/slash-commands.js +26 -0
- package/dist/core/slash-commands.js.map +1 -0
- package/dist/core/source-info.d.ts +18 -0
- package/dist/core/source-info.d.ts.map +1 -0
- package/dist/core/source-info.js +19 -0
- package/dist/core/source-info.js.map +1 -0
- package/dist/core/system-prompt.d.ts +28 -0
- package/dist/core/system-prompt.d.ts.map +1 -0
- package/dist/core/system-prompt.js +120 -0
- package/dist/core/system-prompt.js.map +1 -0
- package/dist/core/telemetry.d.ts +3 -0
- package/dist/core/telemetry.d.ts.map +1 -0
- package/dist/core/telemetry.js +9 -0
- package/dist/core/telemetry.js.map +1 -0
- package/dist/core/timings.d.ts +10 -0
- package/dist/core/timings.d.ts.map +1 -0
- package/dist/core/timings.js +41 -0
- package/dist/core/timings.js.map +1 -0
- package/dist/core/tools/bash.d.ts +68 -0
- package/dist/core/tools/bash.d.ts.map +1 -0
- package/dist/core/tools/bash.js +361 -0
- package/dist/core/tools/bash.js.map +1 -0
- package/dist/core/tools/edit-diff.d.ts +106 -0
- package/dist/core/tools/edit-diff.d.ts.map +1 -0
- package/dist/core/tools/edit-diff.js +424 -0
- package/dist/core/tools/edit-diff.js.map +1 -0
- package/dist/core/tools/edit.d.ts +51 -0
- package/dist/core/tools/edit.d.ts.map +1 -0
- package/dist/core/tools/edit.js +284 -0
- package/dist/core/tools/edit.js.map +1 -0
- package/dist/core/tools/file-mutation-queue.d.ts +6 -0
- package/dist/core/tools/file-mutation-queue.d.ts.map +1 -0
- package/dist/core/tools/file-mutation-queue.js +52 -0
- package/dist/core/tools/file-mutation-queue.js.map +1 -0
- package/dist/core/tools/find.d.ts +35 -0
- package/dist/core/tools/find.d.ts.map +1 -0
- package/dist/core/tools/find.js +305 -0
- package/dist/core/tools/find.js.map +1 -0
- package/dist/core/tools/grep.d.ts +37 -0
- package/dist/core/tools/grep.d.ts.map +1 -0
- package/dist/core/tools/grep.js +304 -0
- package/dist/core/tools/grep.js.map +1 -0
- package/dist/core/tools/index.d.ts +40 -0
- package/dist/core/tools/index.d.ts.map +1 -0
- package/dist/core/tools/index.js +112 -0
- package/dist/core/tools/index.js.map +1 -0
- package/dist/core/tools/ls.d.ts +37 -0
- package/dist/core/tools/ls.d.ts.map +1 -0
- package/dist/core/tools/ls.js +167 -0
- package/dist/core/tools/ls.js.map +1 -0
- package/dist/core/tools/output-accumulator.d.ts +52 -0
- package/dist/core/tools/output-accumulator.d.ts.map +1 -0
- package/dist/core/tools/output-accumulator.js +184 -0
- package/dist/core/tools/output-accumulator.js.map +1 -0
- package/dist/core/tools/path-utils.d.ts +10 -0
- package/dist/core/tools/path-utils.d.ts.map +1 -0
- package/dist/core/tools/path-utils.js +99 -0
- package/dist/core/tools/path-utils.js.map +1 -0
- package/dist/core/tools/read.d.ts +35 -0
- package/dist/core/tools/read.d.ts.map +1 -0
- package/dist/core/tools/read.js +276 -0
- package/dist/core/tools/read.js.map +1 -0
- package/dist/core/tools/render-utils.d.ts +24 -0
- package/dist/core/tools/render-utils.d.ts.map +1 -0
- package/dist/core/tools/render-utils.js +65 -0
- package/dist/core/tools/render-utils.js.map +1 -0
- package/dist/core/tools/tool-definition-wrapper.d.ts +14 -0
- package/dist/core/tools/tool-definition-wrapper.d.ts.map +1 -0
- package/dist/core/tools/tool-definition-wrapper.js +34 -0
- package/dist/core/tools/tool-definition-wrapper.js.map +1 -0
- package/dist/core/tools/truncate.d.ts +70 -0
- package/dist/core/tools/truncate.d.ts.map +1 -0
- package/dist/core/tools/truncate.js +215 -0
- package/dist/core/tools/truncate.js.map +1 -0
- package/dist/core/tools/write.d.ts +26 -0
- package/dist/core/tools/write.d.ts.map +1 -0
- package/dist/core/tools/write.js +197 -0
- package/dist/core/tools/write.js.map +1 -0
- package/dist/core/trust-manager.d.ts +36 -0
- package/dist/core/trust-manager.d.ts.map +1 -0
- package/dist/core/trust-manager.js +202 -0
- package/dist/core/trust-manager.js.map +1 -0
- package/dist/index.d.ts +33 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +46 -0
- package/dist/index.js.map +1 -0
- package/dist/main.d.ts +12 -0
- package/dist/main.d.ts.map +1 -0
- package/dist/main.js +699 -0
- package/dist/main.js.map +1 -0
- package/dist/migrations.d.ts +33 -0
- package/dist/migrations.d.ts.map +1 -0
- package/dist/migrations.js +281 -0
- package/dist/migrations.js.map +1 -0
- package/dist/modes/index.d.ts +9 -0
- package/dist/modes/index.d.ts.map +1 -0
- package/dist/modes/index.js +8 -0
- package/dist/modes/index.js.map +1 -0
- package/dist/modes/interactive/assets/clankolas.png +0 -0
- package/dist/modes/interactive/components/armin.d.ts +34 -0
- package/dist/modes/interactive/components/armin.d.ts.map +1 -0
- package/dist/modes/interactive/components/armin.js +333 -0
- package/dist/modes/interactive/components/armin.js.map +1 -0
- package/dist/modes/interactive/components/assistant-message.d.ts +22 -0
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/assistant-message.js +129 -0
- package/dist/modes/interactive/components/assistant-message.js.map +1 -0
- package/dist/modes/interactive/components/bash-execution.d.ts +34 -0
- package/dist/modes/interactive/components/bash-execution.d.ts.map +1 -0
- package/dist/modes/interactive/components/bash-execution.js +175 -0
- package/dist/modes/interactive/components/bash-execution.js.map +1 -0
- package/dist/modes/interactive/components/bordered-loader.d.ts +16 -0
- package/dist/modes/interactive/components/bordered-loader.d.ts.map +1 -0
- package/dist/modes/interactive/components/bordered-loader.js +54 -0
- package/dist/modes/interactive/components/bordered-loader.js.map +1 -0
- package/dist/modes/interactive/components/branch-summary-message.d.ts +16 -0
- package/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/branch-summary-message.js +44 -0
- package/dist/modes/interactive/components/branch-summary-message.js.map +1 -0
- package/dist/modes/interactive/components/compaction-summary-message.d.ts +16 -0
- package/dist/modes/interactive/components/compaction-summary-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/compaction-summary-message.js +45 -0
- package/dist/modes/interactive/components/compaction-summary-message.js.map +1 -0
- package/dist/modes/interactive/components/config-selector.d.ts +71 -0
- package/dist/modes/interactive/components/config-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/config-selector.js +506 -0
- package/dist/modes/interactive/components/config-selector.js.map +1 -0
- package/dist/modes/interactive/components/countdown-timer.d.ts +14 -0
- package/dist/modes/interactive/components/countdown-timer.d.ts.map +1 -0
- package/dist/modes/interactive/components/countdown-timer.js +33 -0
- package/dist/modes/interactive/components/countdown-timer.js.map +1 -0
- package/dist/modes/interactive/components/custom-editor.d.ts +21 -0
- package/dist/modes/interactive/components/custom-editor.d.ts.map +1 -0
- package/dist/modes/interactive/components/custom-editor.js +70 -0
- package/dist/modes/interactive/components/custom-editor.js.map +1 -0
- package/dist/modes/interactive/components/custom-message.d.ts +20 -0
- package/dist/modes/interactive/components/custom-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/custom-message.js +79 -0
- package/dist/modes/interactive/components/custom-message.js.map +1 -0
- package/dist/modes/interactive/components/daxnuts.d.ts +23 -0
- package/dist/modes/interactive/components/daxnuts.d.ts.map +1 -0
- package/dist/modes/interactive/components/daxnuts.js +140 -0
- package/dist/modes/interactive/components/daxnuts.js.map +1 -0
- package/dist/modes/interactive/components/diff.d.ts +12 -0
- package/dist/modes/interactive/components/diff.d.ts.map +1 -0
- package/dist/modes/interactive/components/diff.js +133 -0
- package/dist/modes/interactive/components/diff.js.map +1 -0
- package/dist/modes/interactive/components/dynamic-border.d.ts +15 -0
- package/dist/modes/interactive/components/dynamic-border.d.ts.map +1 -0
- package/dist/modes/interactive/components/dynamic-border.js +21 -0
- package/dist/modes/interactive/components/dynamic-border.js.map +1 -0
- package/dist/modes/interactive/components/earendil-announcement.d.ts +5 -0
- package/dist/modes/interactive/components/earendil-announcement.d.ts.map +1 -0
- package/dist/modes/interactive/components/earendil-announcement.js +40 -0
- package/dist/modes/interactive/components/earendil-announcement.js.map +1 -0
- package/dist/modes/interactive/components/extension-editor.d.ts +22 -0
- package/dist/modes/interactive/components/extension-editor.d.ts.map +1 -0
- package/dist/modes/interactive/components/extension-editor.js +128 -0
- package/dist/modes/interactive/components/extension-editor.js.map +1 -0
- package/dist/modes/interactive/components/extension-input.d.ts +23 -0
- package/dist/modes/interactive/components/extension-input.d.ts.map +1 -0
- package/dist/modes/interactive/components/extension-input.js +61 -0
- package/dist/modes/interactive/components/extension-input.js.map +1 -0
- package/dist/modes/interactive/components/extension-selector.d.ts +26 -0
- package/dist/modes/interactive/components/extension-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/extension-selector.js +83 -0
- package/dist/modes/interactive/components/extension-selector.js.map +1 -0
- package/dist/modes/interactive/components/first-time-setup.d.ts +25 -0
- package/dist/modes/interactive/components/first-time-setup.d.ts.map +1 -0
- package/dist/modes/interactive/components/first-time-setup.js +103 -0
- package/dist/modes/interactive/components/first-time-setup.js.map +1 -0
- package/dist/modes/interactive/components/footer.d.ts +28 -0
- package/dist/modes/interactive/components/footer.d.ts.map +1 -0
- package/dist/modes/interactive/components/footer.js +221 -0
- package/dist/modes/interactive/components/footer.js.map +1 -0
- package/dist/modes/interactive/components/index.d.ts +34 -0
- package/dist/modes/interactive/components/index.d.ts.map +1 -0
- package/dist/modes/interactive/components/index.js +35 -0
- package/dist/modes/interactive/components/index.js.map +1 -0
- package/dist/modes/interactive/components/keybinding-hints.d.ts +13 -0
- package/dist/modes/interactive/components/keybinding-hints.d.ts.map +1 -0
- package/dist/modes/interactive/components/keybinding-hints.js +36 -0
- package/dist/modes/interactive/components/keybinding-hints.js.map +1 -0
- package/dist/modes/interactive/components/login-dialog.d.ts +52 -0
- package/dist/modes/interactive/components/login-dialog.d.ts.map +1 -0
- package/dist/modes/interactive/components/login-dialog.js +179 -0
- package/dist/modes/interactive/components/login-dialog.js.map +1 -0
- package/dist/modes/interactive/components/model-selector.d.ts +47 -0
- package/dist/modes/interactive/components/model-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/model-selector.js +279 -0
- package/dist/modes/interactive/components/model-selector.js.map +1 -0
- package/dist/modes/interactive/components/oauth-selector.d.ts +31 -0
- package/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/oauth-selector.js +165 -0
- package/dist/modes/interactive/components/oauth-selector.js.map +1 -0
- package/dist/modes/interactive/components/scoped-models-selector.d.ts +42 -0
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/scoped-models-selector.js +293 -0
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -0
- package/dist/modes/interactive/components/session-selector-search.d.ts +23 -0
- package/dist/modes/interactive/components/session-selector-search.d.ts.map +1 -0
- package/dist/modes/interactive/components/session-selector-search.js +155 -0
- package/dist/modes/interactive/components/session-selector-search.js.map +1 -0
- package/dist/modes/interactive/components/session-selector.d.ts +95 -0
- package/dist/modes/interactive/components/session-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/session-selector.js +867 -0
- package/dist/modes/interactive/components/session-selector.js.map +1 -0
- package/dist/modes/interactive/components/settings-selector.d.ts +75 -0
- package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/settings-selector.js +582 -0
- package/dist/modes/interactive/components/settings-selector.js.map +1 -0
- package/dist/modes/interactive/components/show-images-selector.d.ts +10 -0
- package/dist/modes/interactive/components/show-images-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/show-images-selector.js +39 -0
- package/dist/modes/interactive/components/show-images-selector.js.map +1 -0
- package/dist/modes/interactive/components/skill-invocation-message.d.ts +17 -0
- package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/skill-invocation-message.js +47 -0
- package/dist/modes/interactive/components/skill-invocation-message.js.map +1 -0
- package/dist/modes/interactive/components/status-indicator.d.ts +28 -0
- package/dist/modes/interactive/components/status-indicator.d.ts.map +1 -0
- package/dist/modes/interactive/components/status-indicator.js +60 -0
- package/dist/modes/interactive/components/status-indicator.js.map +1 -0
- package/dist/modes/interactive/components/theme-selector.d.ts +11 -0
- package/dist/modes/interactive/components/theme-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/theme-selector.js +50 -0
- package/dist/modes/interactive/components/theme-selector.js.map +1 -0
- package/dist/modes/interactive/components/thinking-selector.d.ts +11 -0
- package/dist/modes/interactive/components/thinking-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/thinking-selector.js +51 -0
- package/dist/modes/interactive/components/thinking-selector.js.map +1 -0
- package/dist/modes/interactive/components/tool-execution.d.ts +63 -0
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -0
- package/dist/modes/interactive/components/tool-execution.js +317 -0
- package/dist/modes/interactive/components/tool-execution.js.map +1 -0
- package/dist/modes/interactive/components/tree-selector.d.ts +89 -0
- package/dist/modes/interactive/components/tree-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/tree-selector.js +1208 -0
- package/dist/modes/interactive/components/tree-selector.js.map +1 -0
- package/dist/modes/interactive/components/trust-selector.d.ts +23 -0
- package/dist/modes/interactive/components/trust-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/trust-selector.js +91 -0
- package/dist/modes/interactive/components/trust-selector.js.map +1 -0
- package/dist/modes/interactive/components/user-message-selector.d.ts +30 -0
- package/dist/modes/interactive/components/user-message-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/user-message-selector.js +114 -0
- package/dist/modes/interactive/components/user-message-selector.js.map +1 -0
- package/dist/modes/interactive/components/user-message.d.ts +14 -0
- package/dist/modes/interactive/components/user-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/user-message.js +42 -0
- package/dist/modes/interactive/components/user-message.js.map +1 -0
- package/dist/modes/interactive/components/visual-truncate.d.ts +24 -0
- package/dist/modes/interactive/components/visual-truncate.d.ts.map +1 -0
- package/dist/modes/interactive/components/visual-truncate.js +33 -0
- package/dist/modes/interactive/components/visual-truncate.js.map +1 -0
- package/dist/modes/interactive/interactive-mode.d.ts +380 -0
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -0
- package/dist/modes/interactive/interactive-mode.js +4782 -0
- package/dist/modes/interactive/interactive-mode.js.map +1 -0
- package/dist/modes/interactive/model-search.d.ts +12 -0
- package/dist/modes/interactive/model-search.d.ts.map +1 -0
- package/dist/modes/interactive/model-search.js +15 -0
- package/dist/modes/interactive/model-search.js.map +1 -0
- package/dist/modes/interactive/theme/dark.json +86 -0
- package/dist/modes/interactive/theme/light.json +85 -0
- package/dist/modes/interactive/theme/theme-controller.d.ts +29 -0
- package/dist/modes/interactive/theme/theme-controller.d.ts.map +1 -0
- package/dist/modes/interactive/theme/theme-controller.js +102 -0
- package/dist/modes/interactive/theme/theme-controller.js.map +1 -0
- package/dist/modes/interactive/theme/theme-schema.json +336 -0
- package/dist/modes/interactive/theme/theme.d.ts +119 -0
- package/dist/modes/interactive/theme/theme.d.ts.map +1 -0
- package/dist/modes/interactive/theme/theme.js +1056 -0
- package/dist/modes/interactive/theme/theme.js.map +1 -0
- package/dist/modes/print-mode.d.ts +28 -0
- package/dist/modes/print-mode.d.ts.map +1 -0
- package/dist/modes/print-mode.js +132 -0
- package/dist/modes/print-mode.js.map +1 -0
- package/dist/modes/rpc/jsonl.d.ts +17 -0
- package/dist/modes/rpc/jsonl.d.ts.map +1 -0
- package/dist/modes/rpc/jsonl.js +49 -0
- package/dist/modes/rpc/jsonl.js.map +1 -0
- package/dist/modes/rpc/rpc-client.d.ts +242 -0
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -0
- package/dist/modes/rpc/rpc-client.js +481 -0
- package/dist/modes/rpc/rpc-client.js.map +1 -0
- package/dist/modes/rpc/rpc-mode.d.ts +20 -0
- package/dist/modes/rpc/rpc-mode.d.ts.map +1 -0
- package/dist/modes/rpc/rpc-mode.js +632 -0
- package/dist/modes/rpc/rpc-mode.js.map +1 -0
- package/dist/modes/rpc/rpc-types.d.ts +446 -0
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -0
- package/dist/modes/rpc/rpc-types.js +8 -0
- package/dist/modes/rpc/rpc-types.js.map +1 -0
- package/dist/package-manager-cli.d.ts +8 -0
- package/dist/package-manager-cli.d.ts.map +1 -0
- package/dist/package-manager-cli.js +659 -0
- package/dist/package-manager-cli.js.map +1 -0
- package/dist/pi-client-cli.d.ts +3 -0
- package/dist/pi-client-cli.d.ts.map +1 -0
- package/dist/pi-client-cli.js +10 -0
- package/dist/pi-client-cli.js.map +1 -0
- package/dist/rpc-entry.d.ts +3 -0
- package/dist/rpc-entry.d.ts.map +1 -0
- package/dist/rpc-entry.js +10 -0
- package/dist/rpc-entry.js.map +1 -0
- package/dist/utils/ansi.d.ts +2 -0
- package/dist/utils/ansi.d.ts.map +1 -0
- package/dist/utils/ansi.js +52 -0
- package/dist/utils/ansi.js.map +1 -0
- package/dist/utils/changelog.d.ts +22 -0
- package/dist/utils/changelog.d.ts.map +1 -0
- package/dist/utils/changelog.js +165 -0
- package/dist/utils/changelog.js.map +1 -0
- package/dist/utils/child-process.d.ts +18 -0
- package/dist/utils/child-process.d.ts.map +1 -0
- package/dist/utils/child-process.js +106 -0
- package/dist/utils/child-process.js.map +1 -0
- package/dist/utils/clipboard-image.d.ts +11 -0
- package/dist/utils/clipboard-image.d.ts.map +1 -0
- package/dist/utils/clipboard-image.js +245 -0
- package/dist/utils/clipboard-image.js.map +1 -0
- package/dist/utils/clipboard-native.d.ts +10 -0
- package/dist/utils/clipboard-native.d.ts.map +1 -0
- package/dist/utils/clipboard-native.js +20 -0
- package/dist/utils/clipboard-native.js.map +1 -0
- package/dist/utils/clipboard.d.ts +2 -0
- package/dist/utils/clipboard.d.ts.map +1 -0
- package/dist/utils/clipboard.js +117 -0
- package/dist/utils/clipboard.js.map +1 -0
- package/dist/utils/deprecation.d.ts +4 -0
- package/dist/utils/deprecation.d.ts.map +1 -0
- package/dist/utils/deprecation.js +13 -0
- package/dist/utils/deprecation.js.map +1 -0
- package/dist/utils/exif-orientation.d.ts +5 -0
- package/dist/utils/exif-orientation.d.ts.map +1 -0
- package/dist/utils/exif-orientation.js +158 -0
- package/dist/utils/exif-orientation.js.map +1 -0
- package/dist/utils/frontmatter.d.ts +8 -0
- package/dist/utils/frontmatter.d.ts.map +1 -0
- package/dist/utils/frontmatter.js +26 -0
- package/dist/utils/frontmatter.js.map +1 -0
- package/dist/utils/fs-watch.d.ts +5 -0
- package/dist/utils/fs-watch.d.ts.map +1 -0
- package/dist/utils/fs-watch.js +25 -0
- package/dist/utils/fs-watch.js.map +1 -0
- package/dist/utils/git.d.ts +26 -0
- package/dist/utils/git.d.ts.map +1 -0
- package/dist/utils/git.js +195 -0
- package/dist/utils/git.js.map +1 -0
- package/dist/utils/html.d.ts +7 -0
- package/dist/utils/html.d.ts.map +1 -0
- package/dist/utils/html.js +40 -0
- package/dist/utils/html.js.map +1 -0
- package/dist/utils/image-convert.d.ts +10 -0
- package/dist/utils/image-convert.d.ts.map +1 -0
- package/dist/utils/image-convert.js +45 -0
- package/dist/utils/image-convert.js.map +1 -0
- package/dist/utils/image-process.d.ts +18 -0
- package/dist/utils/image-process.d.ts.map +1 -0
- package/dist/utils/image-process.js +83 -0
- package/dist/utils/image-process.js.map +1 -0
- package/dist/utils/image-resize-core.d.ts +30 -0
- package/dist/utils/image-resize-core.d.ts.map +1 -0
- package/dist/utils/image-resize-core.js +124 -0
- package/dist/utils/image-resize-core.js.map +1 -0
- package/dist/utils/image-resize-worker.d.ts +2 -0
- package/dist/utils/image-resize-worker.d.ts.map +1 -0
- package/dist/utils/image-resize-worker.js +31 -0
- package/dist/utils/image-resize-worker.js.map +1 -0
- package/dist/utils/image-resize.d.ts +16 -0
- package/dist/utils/image-resize.d.ts.map +1 -0
- package/dist/utils/image-resize.js +97 -0
- package/dist/utils/image-resize.js.map +1 -0
- package/dist/utils/json.d.ts +3 -0
- package/dist/utils/json.d.ts.map +1 -0
- package/dist/utils/json.js +7 -0
- package/dist/utils/json.js.map +1 -0
- package/dist/utils/mime.d.ts +3 -0
- package/dist/utils/mime.d.ts.map +1 -0
- package/dist/utils/mime.js +110 -0
- package/dist/utils/mime.js.map +1 -0
- package/dist/utils/open-browser.d.ts +9 -0
- package/dist/utils/open-browser.d.ts.map +1 -0
- package/dist/utils/open-browser.js +22 -0
- package/dist/utils/open-browser.js.map +1 -0
- package/dist/utils/paths.d.ts +31 -0
- package/dist/utils/paths.d.ts.map +1 -0
- package/dist/utils/paths.js +92 -0
- package/dist/utils/paths.js.map +1 -0
- package/dist/utils/photon.d.ts +21 -0
- package/dist/utils/photon.d.ts.map +1 -0
- package/dist/utils/photon.js +121 -0
- package/dist/utils/photon.js.map +1 -0
- package/dist/utils/pi-user-agent.d.ts +2 -0
- package/dist/utils/pi-user-agent.d.ts.map +1 -0
- package/dist/utils/pi-user-agent.js +5 -0
- package/dist/utils/pi-user-agent.js.map +1 -0
- package/dist/utils/shell.d.ts +31 -0
- package/dist/utils/shell.d.ts.map +1 -0
- package/dist/utils/shell.js +202 -0
- package/dist/utils/shell.js.map +1 -0
- package/dist/utils/sleep.d.ts +5 -0
- package/dist/utils/sleep.d.ts.map +1 -0
- package/dist/utils/sleep.js +17 -0
- package/dist/utils/sleep.js.map +1 -0
- package/dist/utils/syntax-highlight.d.ts +12 -0
- package/dist/utils/syntax-highlight.d.ts.map +1 -0
- package/dist/utils/syntax-highlight.js +118 -0
- package/dist/utils/syntax-highlight.js.map +1 -0
- package/dist/utils/tools-manager.d.ts +3 -0
- package/dist/utils/tools-manager.d.ts.map +1 -0
- package/dist/utils/tools-manager.js +328 -0
- package/dist/utils/tools-manager.js.map +1 -0
- package/dist/utils/version-check.d.ts +15 -0
- package/dist/utils/version-check.d.ts.map +1 -0
- package/dist/utils/version-check.js +59 -0
- package/dist/utils/version-check.js.map +1 -0
- package/dist/utils/windows-self-update.d.ts +3 -0
- package/dist/utils/windows-self-update.d.ts.map +1 -0
- package/dist/utils/windows-self-update.js +77 -0
- package/dist/utils/windows-self-update.js.map +1 -0
- package/docs/compaction.md +396 -0
- package/docs/containerization.md +111 -0
- package/docs/custom-provider.md +737 -0
- package/docs/development.md +71 -0
- package/docs/docs.json +156 -0
- package/docs/extensions.md +2695 -0
- package/docs/images/doom-extension.png +0 -0
- package/docs/images/exy.png +0 -0
- package/docs/images/interactive-mode.png +0 -0
- package/docs/images/tree-view.png +0 -0
- package/docs/index.md +82 -0
- package/docs/json.md +82 -0
- package/docs/keybindings.md +197 -0
- package/docs/models.md +495 -0
- package/docs/packages.md +227 -0
- package/docs/prompt-templates.md +95 -0
- package/docs/providers.md +275 -0
- package/docs/quickstart.md +165 -0
- package/docs/rpc.md +1470 -0
- package/docs/sdk.md +1143 -0
- package/docs/security.md +59 -0
- package/docs/session-format.md +412 -0
- package/docs/sessions.md +145 -0
- package/docs/settings.md +318 -0
- package/docs/shell-aliases.md +13 -0
- package/docs/skills.md +231 -0
- package/docs/terminal-setup.md +142 -0
- package/docs/termux.md +127 -0
- package/docs/themes.md +295 -0
- package/docs/tmux.md +63 -0
- package/docs/tui.md +927 -0
- package/docs/usage.md +308 -0
- package/docs/windows.md +17 -0
- package/examples/README.md +25 -0
- package/examples/extensions/README.md +211 -0
- package/examples/extensions/auto-commit-on-exit.ts +49 -0
- package/examples/extensions/bash-spawn-hook.ts +30 -0
- package/examples/extensions/bookmark.ts +50 -0
- package/examples/extensions/border-status-editor.ts +150 -0
- package/examples/extensions/built-in-tool-renderer.ts +249 -0
- package/examples/extensions/claude-rules.ts +86 -0
- package/examples/extensions/commands.ts +72 -0
- package/examples/extensions/confirm-destructive.ts +59 -0
- package/examples/extensions/custom-compaction.ts +128 -0
- package/examples/extensions/custom-footer.ts +64 -0
- package/examples/extensions/custom-header.ts +73 -0
- package/examples/extensions/custom-provider-anthropic/index.ts +604 -0
- package/examples/extensions/custom-provider-anthropic/package-lock.json +24 -0
- package/examples/extensions/custom-provider-anthropic/package.json +19 -0
- package/examples/extensions/custom-provider-gitlab-duo/index.ts +404 -0
- package/examples/extensions/custom-provider-gitlab-duo/package.json +16 -0
- package/examples/extensions/custom-provider-gitlab-duo/test.ts +82 -0
- package/examples/extensions/dirty-repo-guard.ts +56 -0
- package/examples/extensions/doom-overlay/README.md +46 -0
- package/examples/extensions/doom-overlay/doom/build/doom.js +21 -0
- package/examples/extensions/doom-overlay/doom/build/doom.wasm +0 -0
- package/examples/extensions/doom-overlay/doom/build.sh +152 -0
- package/examples/extensions/doom-overlay/doom/doomgeneric_pi.c +72 -0
- package/examples/extensions/doom-overlay/doom-component.ts +132 -0
- package/examples/extensions/doom-overlay/doom-engine.ts +173 -0
- package/examples/extensions/doom-overlay/doom-keys.ts +104 -0
- package/examples/extensions/doom-overlay/index.ts +74 -0
- package/examples/extensions/doom-overlay/wad-finder.ts +51 -0
- package/examples/extensions/dynamic-resources/SKILL.md +8 -0
- package/examples/extensions/dynamic-resources/dynamic.json +79 -0
- package/examples/extensions/dynamic-resources/dynamic.md +5 -0
- package/examples/extensions/dynamic-resources/index.ts +15 -0
- package/examples/extensions/dynamic-tools.ts +74 -0
- package/examples/extensions/event-bus.ts +43 -0
- package/examples/extensions/file-trigger.ts +41 -0
- package/examples/extensions/git-checkpoint.ts +53 -0
- package/examples/extensions/git-merge-and-resolve.ts +115 -0
- package/examples/extensions/github-issue-autocomplete.ts +185 -0
- package/examples/extensions/gondolin/index.ts +531 -0
- package/examples/extensions/gondolin/package-lock.json +185 -0
- package/examples/extensions/gondolin/package.json +19 -0
- package/examples/extensions/handoff.ts +191 -0
- package/examples/extensions/hello.ts +26 -0
- package/examples/extensions/hidden-thinking-label.ts +53 -0
- package/examples/extensions/inline-bash.ts +94 -0
- package/examples/extensions/input-transform-streaming.ts +39 -0
- package/examples/extensions/input-transform.ts +43 -0
- package/examples/extensions/interactive-shell.ts +196 -0
- package/examples/extensions/mac-system-theme.ts +47 -0
- package/examples/extensions/message-renderer.ts +59 -0
- package/examples/extensions/minimal-mode.ts +426 -0
- package/examples/extensions/modal-editor.ts +85 -0
- package/examples/extensions/model-status.ts +31 -0
- package/examples/extensions/notify.ts +55 -0
- package/examples/extensions/overlay-qa-tests.ts +1450 -0
- package/examples/extensions/overlay-test.ts +153 -0
- package/examples/extensions/permission-gate.ts +34 -0
- package/examples/extensions/pirate.ts +47 -0
- package/examples/extensions/plan-mode/README.md +66 -0
- package/examples/extensions/plan-mode/index.ts +390 -0
- package/examples/extensions/plan-mode/utils.ts +168 -0
- package/examples/extensions/preset.ts +436 -0
- package/examples/extensions/project-trust.ts +64 -0
- package/examples/extensions/prompt-customizer.ts +97 -0
- package/examples/extensions/protected-paths.ts +30 -0
- package/examples/extensions/provider-payload.ts +18 -0
- package/examples/extensions/qna.ts +122 -0
- package/examples/extensions/question.ts +285 -0
- package/examples/extensions/questionnaire.ts +448 -0
- package/examples/extensions/rainbow-editor.ts +88 -0
- package/examples/extensions/reload-runtime.ts +37 -0
- package/examples/extensions/rpc-demo.ts +118 -0
- package/examples/extensions/sandbox/index.ts +321 -0
- package/examples/extensions/sandbox/package-lock.json +92 -0
- package/examples/extensions/sandbox/package.json +19 -0
- package/examples/extensions/send-user-message.ts +97 -0
- package/examples/extensions/session-name.ts +27 -0
- package/examples/extensions/shutdown-command.ts +63 -0
- package/examples/extensions/snake.ts +343 -0
- package/examples/extensions/space-invaders.ts +560 -0
- package/examples/extensions/ssh.ts +220 -0
- package/examples/extensions/status-line.ts +32 -0
- package/examples/extensions/structured-output.ts +65 -0
- package/examples/extensions/subagent/README.md +175 -0
- package/examples/extensions/subagent/agents/planner.md +37 -0
- package/examples/extensions/subagent/agents/reviewer.md +35 -0
- package/examples/extensions/subagent/agents/scout.md +50 -0
- package/examples/extensions/subagent/agents/worker.md +24 -0
- package/examples/extensions/subagent/agents.ts +126 -0
- package/examples/extensions/subagent/index.ts +1015 -0
- package/examples/extensions/subagent/prompts/implement-and-review.md +10 -0
- package/examples/extensions/subagent/prompts/implement.md +10 -0
- package/examples/extensions/subagent/prompts/scout-and-plan.md +9 -0
- package/examples/extensions/summarize.ts +207 -0
- package/examples/extensions/system-prompt-header.ts +17 -0
- package/examples/extensions/tic-tac-toe.ts +1008 -0
- package/examples/extensions/timed-confirm.ts +70 -0
- package/examples/extensions/titlebar-spinner.ts +58 -0
- package/examples/extensions/todo.ts +297 -0
- package/examples/extensions/tool-override.ts +144 -0
- package/examples/extensions/tools.ts +146 -0
- package/examples/extensions/trigger-compact.ts +50 -0
- package/examples/extensions/truncated-tool.ts +195 -0
- package/examples/extensions/widget-placement.ts +9 -0
- package/examples/extensions/with-deps/index.ts +32 -0
- package/examples/extensions/with-deps/package-lock.json +31 -0
- package/examples/extensions/with-deps/package.json +22 -0
- package/examples/extensions/working-indicator.ts +123 -0
- package/examples/extensions/working-message-test.ts +25 -0
- package/examples/rpc-extension-ui.ts +632 -0
- package/examples/sdk/01-minimal.ts +26 -0
- package/examples/sdk/02-custom-model.ts +53 -0
- package/examples/sdk/03-custom-prompt.ts +75 -0
- package/examples/sdk/04-skills.ts +55 -0
- package/examples/sdk/05-tools.ts +48 -0
- package/examples/sdk/06-extensions.ts +99 -0
- package/examples/sdk/07-context-files.ts +47 -0
- package/examples/sdk/08-prompt-templates.ts +51 -0
- package/examples/sdk/09-api-keys-and-oauth.ts +52 -0
- package/examples/sdk/10-settings.ts +53 -0
- package/examples/sdk/11-sessions.ts +52 -0
- package/examples/sdk/12-full-control.ts +77 -0
- package/examples/sdk/13-session-runtime.ts +67 -0
- package/examples/sdk/README.md +144 -0
- package/npm-shrinkwrap.json +1824 -0
- package/package.json +103 -0
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
# Terminal Setup
|
|
2
|
+
|
|
3
|
+
Pi uses the [Kitty keyboard protocol](https://sw.kovidgoyal.net/kitty/keyboard-protocol/) for reliable modifier key detection. Most modern terminals support this protocol, but some require configuration.
|
|
4
|
+
|
|
5
|
+
## Kitty, iTerm2
|
|
6
|
+
|
|
7
|
+
Work out of the box.
|
|
8
|
+
|
|
9
|
+
## Apple Terminal
|
|
10
|
+
|
|
11
|
+
Pi enables enhanced key reporting when available. If Terminal.app still sends plain Return for `Shift+Enter`, pi uses a local macOS modifier fallback to treat that Return as `Shift+Enter`.
|
|
12
|
+
|
|
13
|
+
This fallback only works when pi runs on the same Mac as Terminal.app. It cannot detect the local keyboard over remote SSH.
|
|
14
|
+
|
|
15
|
+
## Ghostty
|
|
16
|
+
|
|
17
|
+
Add to your Ghostty config (`~/Library/Application Support/com.mitchellh.ghostty/config` on macOS, `~/.config/ghostty/config` on Linux):
|
|
18
|
+
|
|
19
|
+
```
|
|
20
|
+
keybind = alt+backspace=text:\x1b\x7f
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
Older Claude Code versions may have added this Ghostty mapping:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
keybind = shift+enter=text:\n
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
That mapping sends a raw linefeed byte. Inside pi, that is indistinguishable from `Ctrl+J`, so tmux and pi no longer see a real `shift+enter` key event.
|
|
30
|
+
|
|
31
|
+
If Claude Code 2.x or newer is the only reason you added that mapping, you can remove it, unless you want to use Claude Code in tmux, where it still requires that Ghostty mapping.
|
|
32
|
+
|
|
33
|
+
Pi binds `Ctrl+J` as a default newline alias, so `Shift+Enter` keeps working in tmux via that remap without extra pi configuration.
|
|
34
|
+
|
|
35
|
+
## WezTerm
|
|
36
|
+
|
|
37
|
+
WezTerm usually works out of the box for `Shift+Enter` via xterm modifyOtherKeys. To use the Kitty keyboard protocol explicitly, create `~/.wezterm.lua`:
|
|
38
|
+
|
|
39
|
+
```lua
|
|
40
|
+
local wezterm = require 'wezterm'
|
|
41
|
+
local config = wezterm.config_builder()
|
|
42
|
+
config.enable_kitty_keyboard = true
|
|
43
|
+
return config
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
On macOS, WezTerm binds `Option+Enter` to fullscreen by default. To use `Option+Enter` for pi follow-up queueing, add this key override:
|
|
47
|
+
|
|
48
|
+
```lua
|
|
49
|
+
local wezterm = require 'wezterm'
|
|
50
|
+
local config = wezterm.config_builder()
|
|
51
|
+
config.keys = {
|
|
52
|
+
{
|
|
53
|
+
key = 'Enter',
|
|
54
|
+
mods = 'ALT',
|
|
55
|
+
action = wezterm.action.SendString('\x1b[13;3u'),
|
|
56
|
+
},
|
|
57
|
+
}
|
|
58
|
+
return config
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
If you already have a `config.keys` table, add the entry to it.
|
|
62
|
+
|
|
63
|
+
On WSL, WezTerm may require a visible hardware cursor for IME candidate window positioning. If CJK IME candidates do not follow the text cursor, set `PI_HARDWARE_CURSOR=1` before running pi or set `showHardwareCursor` to `true` in settings.
|
|
64
|
+
|
|
65
|
+
## Alacritty
|
|
66
|
+
|
|
67
|
+
Alacritty usually works out of the box for `Shift+Enter`. On macOS, `Option+Enter` may arrive as plain `Enter`. To use `Option+Enter` for pi follow-up queueing, add to `~/.config/alacritty/alacritty.toml`:
|
|
68
|
+
|
|
69
|
+
```toml
|
|
70
|
+
[[keyboard.bindings]]
|
|
71
|
+
key = "Enter"
|
|
72
|
+
mods = "Alt"
|
|
73
|
+
chars = "\u001b[13;3u"
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Restart Alacritty after changing the config.
|
|
77
|
+
|
|
78
|
+
## VS Code (Integrated Terminal)
|
|
79
|
+
|
|
80
|
+
VS Code 1.109.5 and newer enable Kitty keyboard protocol in the integrated terminal by default, so `Shift+Enter` should work out of the box.
|
|
81
|
+
|
|
82
|
+
VS Code versions older than 1.109.5 need an explicit terminal keybinding for `Shift+Enter`.
|
|
83
|
+
|
|
84
|
+
`keybindings.json` locations:
|
|
85
|
+
- macOS: `~/Library/Application Support/Code/User/keybindings.json`
|
|
86
|
+
- Linux: `~/.config/Code/User/keybindings.json`
|
|
87
|
+
- Windows: `%APPDATA%\\Code\\User\\keybindings.json`
|
|
88
|
+
|
|
89
|
+
Add to `keybindings.json`:
|
|
90
|
+
|
|
91
|
+
```json
|
|
92
|
+
{
|
|
93
|
+
"key": "shift+enter",
|
|
94
|
+
"command": "workbench.action.terminal.sendSequence",
|
|
95
|
+
"args": { "text": "\u001b[13;2u" },
|
|
96
|
+
"when": "terminalFocus"
|
|
97
|
+
}
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## Windows Terminal
|
|
101
|
+
|
|
102
|
+
Add to `settings.json` (Ctrl+Shift+, or Settings → Open JSON file) to forward the modified Enter keys pi uses:
|
|
103
|
+
|
|
104
|
+
```json
|
|
105
|
+
{
|
|
106
|
+
"actions": [
|
|
107
|
+
{
|
|
108
|
+
"command": { "action": "sendInput", "input": "\u001b[13;2u" },
|
|
109
|
+
"keys": "shift+enter"
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
"command": { "action": "sendInput", "input": "\u001b[13;3u" },
|
|
113
|
+
"keys": "alt+enter"
|
|
114
|
+
}
|
|
115
|
+
]
|
|
116
|
+
}
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
- `Shift+Enter` inserts a new line.
|
|
120
|
+
- Windows Terminal binds `Alt+Enter` to fullscreen by default. That prevents pi from receiving `Alt+Enter` for follow-up queueing.
|
|
121
|
+
- Remapping `Alt+Enter` to `sendInput` forwards the real key chord to pi instead.
|
|
122
|
+
|
|
123
|
+
If you already have an `actions` array, add the objects to it. If the old fullscreen behavior persists, fully close and reopen Windows Terminal.
|
|
124
|
+
|
|
125
|
+
## xfce4-terminal, terminator
|
|
126
|
+
|
|
127
|
+
These terminals have limited escape sequence support. Modified Enter keys like `Ctrl+Enter` and `Shift+Enter` cannot be distinguished from plain `Enter`, preventing custom keybindings such as `submit: ["ctrl+enter"]` from working.
|
|
128
|
+
|
|
129
|
+
For the best experience, use a terminal that supports the Kitty keyboard protocol:
|
|
130
|
+
- [Kitty](https://sw.kovidgoyal.net/kitty/)
|
|
131
|
+
- [Ghostty](https://ghostty.org/)
|
|
132
|
+
- [WezTerm](https://wezfurlong.org/wezterm/)
|
|
133
|
+
- [iTerm2](https://iterm2.com/)
|
|
134
|
+
- [Alacritty](https://github.com/alacritty/alacritty) (requires compilation with Kitty protocol support)
|
|
135
|
+
|
|
136
|
+
## IntelliJ IDEA (Integrated Terminal)
|
|
137
|
+
|
|
138
|
+
The built-in terminal has limited escape sequence support. Shift+Enter cannot be distinguished from Enter in IntelliJ's terminal.
|
|
139
|
+
|
|
140
|
+
If you want the hardware cursor visible, set `PI_HARDWARE_CURSOR=1` before running pi (disabled by default for compatibility).
|
|
141
|
+
|
|
142
|
+
Consider using a dedicated terminal emulator for the best experience.
|
package/docs/termux.md
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
# Termux (Android) Setup
|
|
2
|
+
|
|
3
|
+
Pi runs on Android via [Termux](https://termux.dev/), a terminal emulator and Linux environment for Android.
|
|
4
|
+
|
|
5
|
+
## Prerequisites
|
|
6
|
+
|
|
7
|
+
1. Install [Termux](https://github.com/termux/termux-app#installation) from GitHub or F-Droid (not Google Play, that version is deprecated)
|
|
8
|
+
2. Install [Termux:API](https://github.com/termux/termux-api#installation) from GitHub or F-Droid for clipboard and other device integrations
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
# Update packages
|
|
14
|
+
pkg update && pkg upgrade
|
|
15
|
+
|
|
16
|
+
# Install dependencies
|
|
17
|
+
pkg install nodejs termux-api git
|
|
18
|
+
|
|
19
|
+
# Install pi
|
|
20
|
+
npm install -g --ignore-scripts @earendil-works/pi-coding-agent
|
|
21
|
+
|
|
22
|
+
# Create config directory
|
|
23
|
+
mkdir -p ~/.pi/agent
|
|
24
|
+
|
|
25
|
+
# Run pi
|
|
26
|
+
pi
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Clipboard Support
|
|
30
|
+
|
|
31
|
+
Clipboard operations use `termux-clipboard-set` and `termux-clipboard-get` when running in Termux. The Termux:API app must be installed for these to work.
|
|
32
|
+
|
|
33
|
+
Image clipboard is not supported on Termux (the `ctrl+v` image paste feature will not work).
|
|
34
|
+
|
|
35
|
+
## Example AGENTS.md for Termux
|
|
36
|
+
|
|
37
|
+
Create `~/.pi/agent/AGENTS.md` to help the agent understand the Termux environment:
|
|
38
|
+
|
|
39
|
+
````markdown
|
|
40
|
+
# Agent Environment: Termux on Android
|
|
41
|
+
|
|
42
|
+
## Location
|
|
43
|
+
- **OS**: Android (Termux terminal emulator)
|
|
44
|
+
- **Home**: `/data/data/com.termux/files/home`
|
|
45
|
+
- **Prefix**: `/data/data/com.termux/files/usr`
|
|
46
|
+
- **Shared storage**: `/storage/emulated/0` (Downloads, Documents, etc.)
|
|
47
|
+
|
|
48
|
+
## Opening URLs
|
|
49
|
+
```bash
|
|
50
|
+
termux-open-url "https://example.com"
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Opening Files
|
|
54
|
+
```bash
|
|
55
|
+
termux-open file.pdf # Opens with default app
|
|
56
|
+
termux-open --chooser image.jpg # Choose app
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Clipboard
|
|
60
|
+
```bash
|
|
61
|
+
termux-clipboard-set "text" # Copy
|
|
62
|
+
termux-clipboard-get # Paste
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## Notifications
|
|
66
|
+
```bash
|
|
67
|
+
termux-notification -t "Title" -c "Content"
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Device Info
|
|
71
|
+
```bash
|
|
72
|
+
termux-battery-status # Battery info
|
|
73
|
+
termux-wifi-connectioninfo # WiFi info
|
|
74
|
+
termux-telephony-deviceinfo # Device info
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Sharing
|
|
78
|
+
```bash
|
|
79
|
+
termux-share -a send file.txt # Share file
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Other Useful Commands
|
|
83
|
+
```bash
|
|
84
|
+
termux-toast "message" # Quick toast popup
|
|
85
|
+
termux-vibrate # Vibrate device
|
|
86
|
+
termux-tts-speak "hello" # Text to speech
|
|
87
|
+
termux-camera-photo out.jpg # Take photo
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Notes
|
|
91
|
+
- Termux:API app must be installed for `termux-*` commands
|
|
92
|
+
- Use `pkg install termux-api` for the command-line tools
|
|
93
|
+
- Storage permission needed for `/storage/emulated/0` access
|
|
94
|
+
````
|
|
95
|
+
|
|
96
|
+
## Limitations
|
|
97
|
+
|
|
98
|
+
- **No image clipboard**: Termux clipboard API only supports text
|
|
99
|
+
- **No native binaries**: Some optional native dependencies (like the clipboard module) are unavailable on Android ARM64 and are skipped during installation
|
|
100
|
+
- **Storage access**: To access files in `/storage/emulated/0` (Downloads, etc.), run `termux-setup-storage` once to grant permissions
|
|
101
|
+
|
|
102
|
+
## Troubleshooting
|
|
103
|
+
|
|
104
|
+
### Clipboard not working
|
|
105
|
+
|
|
106
|
+
Ensure both apps are installed:
|
|
107
|
+
1. Termux (from GitHub or F-Droid)
|
|
108
|
+
2. Termux:API (from GitHub or F-Droid)
|
|
109
|
+
|
|
110
|
+
Then install the CLI tools:
|
|
111
|
+
```bash
|
|
112
|
+
pkg install termux-api
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### Permission denied for shared storage
|
|
116
|
+
|
|
117
|
+
Run once to grant storage permissions:
|
|
118
|
+
```bash
|
|
119
|
+
termux-setup-storage
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
### Node.js installation issues
|
|
123
|
+
|
|
124
|
+
If npm fails, try clearing the cache:
|
|
125
|
+
```bash
|
|
126
|
+
npm cache clean --force
|
|
127
|
+
```
|
package/docs/themes.md
ADDED
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
> pi can create themes. Ask it to build one for your setup.
|
|
2
|
+
|
|
3
|
+
# Themes
|
|
4
|
+
|
|
5
|
+
Themes are JSON files that define colors for the TUI.
|
|
6
|
+
|
|
7
|
+
## Table of Contents
|
|
8
|
+
|
|
9
|
+
- [Locations](#locations)
|
|
10
|
+
- [Selecting a Theme](#selecting-a-theme)
|
|
11
|
+
- [Creating a Custom Theme](#creating-a-custom-theme)
|
|
12
|
+
- [Theme Format](#theme-format)
|
|
13
|
+
- [Color Tokens](#color-tokens)
|
|
14
|
+
- [Color Values](#color-values)
|
|
15
|
+
- [Tips](#tips)
|
|
16
|
+
|
|
17
|
+
## Locations
|
|
18
|
+
|
|
19
|
+
Pi loads themes from:
|
|
20
|
+
|
|
21
|
+
- Built-in: `dark`, `light`
|
|
22
|
+
- Global: `~/.pi/agent/themes/*.json`
|
|
23
|
+
- Project: `.pi/themes/*.json` (only after the project is trusted)
|
|
24
|
+
- Packages: `themes/` directories or `pi.themes` entries in `package.json`
|
|
25
|
+
- Settings: `themes` array with files or directories
|
|
26
|
+
- CLI: `--theme <path>` (repeatable)
|
|
27
|
+
|
|
28
|
+
Disable discovery with `--no-themes`.
|
|
29
|
+
|
|
30
|
+
## Selecting a Theme
|
|
31
|
+
|
|
32
|
+
Select a theme via `/settings` or in `settings.json`:
|
|
33
|
+
|
|
34
|
+
```json
|
|
35
|
+
{
|
|
36
|
+
"theme": "my-theme"
|
|
37
|
+
}
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
On first run, pi detects your terminal background and defaults to `dark` or `light`.
|
|
41
|
+
|
|
42
|
+
## Creating a Custom Theme
|
|
43
|
+
|
|
44
|
+
1. Create a theme file:
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
mkdir -p ~/.pi/agent/themes
|
|
48
|
+
vim ~/.pi/agent/themes/my-theme.json
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
2. Define the theme with all required colors (see [Color Tokens](#color-tokens)):
|
|
52
|
+
|
|
53
|
+
```json
|
|
54
|
+
{
|
|
55
|
+
"$schema": "https://raw.githubusercontent.com/earendil-works/pi/main/packages/coding-agent/src/modes/interactive/theme/theme-schema.json",
|
|
56
|
+
"name": "my-theme",
|
|
57
|
+
"vars": {
|
|
58
|
+
"primary": "#00aaff",
|
|
59
|
+
"secondary": 242
|
|
60
|
+
},
|
|
61
|
+
"colors": {
|
|
62
|
+
"accent": "primary",
|
|
63
|
+
"border": "primary",
|
|
64
|
+
"borderAccent": "#00ffff",
|
|
65
|
+
"borderMuted": "secondary",
|
|
66
|
+
"success": "#00ff00",
|
|
67
|
+
"error": "#ff0000",
|
|
68
|
+
"warning": "#ffff00",
|
|
69
|
+
"muted": "secondary",
|
|
70
|
+
"dim": 240,
|
|
71
|
+
"text": "",
|
|
72
|
+
"thinkingText": "secondary",
|
|
73
|
+
"selectedBg": "#2d2d30",
|
|
74
|
+
"userMessageBg": "#2d2d30",
|
|
75
|
+
"userMessageText": "",
|
|
76
|
+
"customMessageBg": "#2d2d30",
|
|
77
|
+
"customMessageText": "",
|
|
78
|
+
"customMessageLabel": "primary",
|
|
79
|
+
"toolPendingBg": "#1e1e2e",
|
|
80
|
+
"toolSuccessBg": "#1e2e1e",
|
|
81
|
+
"toolErrorBg": "#2e1e1e",
|
|
82
|
+
"toolTitle": "primary",
|
|
83
|
+
"toolOutput": "",
|
|
84
|
+
"mdHeading": "#ffaa00",
|
|
85
|
+
"mdLink": "primary",
|
|
86
|
+
"mdLinkUrl": "secondary",
|
|
87
|
+
"mdCode": "#00ffff",
|
|
88
|
+
"mdCodeBlock": "",
|
|
89
|
+
"mdCodeBlockBorder": "secondary",
|
|
90
|
+
"mdQuote": "secondary",
|
|
91
|
+
"mdQuoteBorder": "secondary",
|
|
92
|
+
"mdHr": "secondary",
|
|
93
|
+
"mdListBullet": "#00ffff",
|
|
94
|
+
"toolDiffAdded": "#00ff00",
|
|
95
|
+
"toolDiffRemoved": "#ff0000",
|
|
96
|
+
"toolDiffContext": "secondary",
|
|
97
|
+
"syntaxComment": "secondary",
|
|
98
|
+
"syntaxKeyword": "primary",
|
|
99
|
+
"syntaxFunction": "#00aaff",
|
|
100
|
+
"syntaxVariable": "#ffaa00",
|
|
101
|
+
"syntaxString": "#00ff00",
|
|
102
|
+
"syntaxNumber": "#ff00ff",
|
|
103
|
+
"syntaxType": "#00aaff",
|
|
104
|
+
"syntaxOperator": "primary",
|
|
105
|
+
"syntaxPunctuation": "secondary",
|
|
106
|
+
"thinkingOff": "secondary",
|
|
107
|
+
"thinkingMinimal": "primary",
|
|
108
|
+
"thinkingLow": "#00aaff",
|
|
109
|
+
"thinkingMedium": "#00ffff",
|
|
110
|
+
"thinkingHigh": "#ff00ff",
|
|
111
|
+
"thinkingXhigh": "#ff0000",
|
|
112
|
+
"bashMode": "#ffaa00"
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
3. Select the theme via `/settings`.
|
|
118
|
+
|
|
119
|
+
**Hot reload:** When you edit the currently active custom theme file, pi reloads it automatically for immediate visual feedback.
|
|
120
|
+
|
|
121
|
+
## Theme Format
|
|
122
|
+
|
|
123
|
+
```json
|
|
124
|
+
{
|
|
125
|
+
"$schema": "https://raw.githubusercontent.com/earendil-works/pi/main/packages/coding-agent/src/modes/interactive/theme/theme-schema.json",
|
|
126
|
+
"name": "my-theme",
|
|
127
|
+
"vars": {
|
|
128
|
+
"blue": "#0066cc",
|
|
129
|
+
"gray": 242
|
|
130
|
+
},
|
|
131
|
+
"colors": {
|
|
132
|
+
"accent": "blue",
|
|
133
|
+
"muted": "gray",
|
|
134
|
+
"text": "",
|
|
135
|
+
...
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
- `name` is required, must be unique, and must not contain `/`.
|
|
141
|
+
- `vars` is optional. Define reusable colors here, then reference them in `colors`.
|
|
142
|
+
- `colors` must define all 51 required tokens.
|
|
143
|
+
|
|
144
|
+
The `$schema` field enables editor auto-completion and validation.
|
|
145
|
+
|
|
146
|
+
## Color Tokens
|
|
147
|
+
|
|
148
|
+
Every theme must define all 51 color tokens. There are no optional colors.
|
|
149
|
+
|
|
150
|
+
### Core UI (11 colors)
|
|
151
|
+
|
|
152
|
+
| Token | Purpose |
|
|
153
|
+
|-------|---------|
|
|
154
|
+
| `accent` | Primary accent (logo, selected items, cursor) |
|
|
155
|
+
| `border` | Normal borders |
|
|
156
|
+
| `borderAccent` | Highlighted borders |
|
|
157
|
+
| `borderMuted` | Subtle borders (editor) |
|
|
158
|
+
| `success` | Success states |
|
|
159
|
+
| `error` | Error states |
|
|
160
|
+
| `warning` | Warning states |
|
|
161
|
+
| `muted` | Secondary text |
|
|
162
|
+
| `dim` | Tertiary text |
|
|
163
|
+
| `text` | Default text (usually `""`) |
|
|
164
|
+
| `thinkingText` | Thinking block text |
|
|
165
|
+
|
|
166
|
+
### Backgrounds & Content (11 colors)
|
|
167
|
+
|
|
168
|
+
| Token | Purpose |
|
|
169
|
+
|-------|---------|
|
|
170
|
+
| `selectedBg` | Selected line background |
|
|
171
|
+
| `userMessageBg` | User message background |
|
|
172
|
+
| `userMessageText` | User message text |
|
|
173
|
+
| `customMessageBg` | Extension message background |
|
|
174
|
+
| `customMessageText` | Extension message text |
|
|
175
|
+
| `customMessageLabel` | Extension message label |
|
|
176
|
+
| `toolPendingBg` | Tool box (pending) |
|
|
177
|
+
| `toolSuccessBg` | Tool box (success) |
|
|
178
|
+
| `toolErrorBg` | Tool box (error) |
|
|
179
|
+
| `toolTitle` | Tool title |
|
|
180
|
+
| `toolOutput` | Tool output text |
|
|
181
|
+
|
|
182
|
+
### Markdown (10 colors)
|
|
183
|
+
|
|
184
|
+
| Token | Purpose |
|
|
185
|
+
|-------|---------|
|
|
186
|
+
| `mdHeading` | Headings |
|
|
187
|
+
| `mdLink` | Link text |
|
|
188
|
+
| `mdLinkUrl` | Link URL |
|
|
189
|
+
| `mdCode` | Inline code |
|
|
190
|
+
| `mdCodeBlock` | Code block content |
|
|
191
|
+
| `mdCodeBlockBorder` | Code block fences |
|
|
192
|
+
| `mdQuote` | Blockquote text |
|
|
193
|
+
| `mdQuoteBorder` | Blockquote border |
|
|
194
|
+
| `mdHr` | Horizontal rule |
|
|
195
|
+
| `mdListBullet` | List bullets |
|
|
196
|
+
|
|
197
|
+
### Tool Diffs (3 colors)
|
|
198
|
+
|
|
199
|
+
| Token | Purpose |
|
|
200
|
+
|-------|---------|
|
|
201
|
+
| `toolDiffAdded` | Added lines |
|
|
202
|
+
| `toolDiffRemoved` | Removed lines |
|
|
203
|
+
| `toolDiffContext` | Context lines |
|
|
204
|
+
|
|
205
|
+
### Syntax Highlighting (9 colors)
|
|
206
|
+
|
|
207
|
+
| Token | Purpose |
|
|
208
|
+
|-------|---------|
|
|
209
|
+
| `syntaxComment` | Comments |
|
|
210
|
+
| `syntaxKeyword` | Keywords |
|
|
211
|
+
| `syntaxFunction` | Function names |
|
|
212
|
+
| `syntaxVariable` | Variables |
|
|
213
|
+
| `syntaxString` | Strings |
|
|
214
|
+
| `syntaxNumber` | Numbers |
|
|
215
|
+
| `syntaxType` | Types |
|
|
216
|
+
| `syntaxOperator` | Operators |
|
|
217
|
+
| `syntaxPunctuation` | Punctuation |
|
|
218
|
+
|
|
219
|
+
### Thinking Level Borders (6 colors)
|
|
220
|
+
|
|
221
|
+
Editor border colors indicating thinking level (visual hierarchy from subtle to prominent):
|
|
222
|
+
|
|
223
|
+
| Token | Purpose |
|
|
224
|
+
|-------|---------|
|
|
225
|
+
| `thinkingOff` | Thinking off |
|
|
226
|
+
| `thinkingMinimal` | Minimal thinking |
|
|
227
|
+
| `thinkingLow` | Low thinking |
|
|
228
|
+
| `thinkingMedium` | Medium thinking |
|
|
229
|
+
| `thinkingHigh` | High thinking |
|
|
230
|
+
| `thinkingXhigh` | Extra high thinking |
|
|
231
|
+
|
|
232
|
+
### Bash Mode (1 color)
|
|
233
|
+
|
|
234
|
+
| Token | Purpose |
|
|
235
|
+
|-------|---------|
|
|
236
|
+
| `bashMode` | Editor border in bash mode (`!` prefix) |
|
|
237
|
+
|
|
238
|
+
### HTML Export (optional)
|
|
239
|
+
|
|
240
|
+
The `export` section controls colors for `/export` HTML output. If omitted, colors are derived from `userMessageBg`.
|
|
241
|
+
|
|
242
|
+
```json
|
|
243
|
+
{
|
|
244
|
+
"export": {
|
|
245
|
+
"pageBg": "#18181e",
|
|
246
|
+
"cardBg": "#1e1e24",
|
|
247
|
+
"infoBg": "#3c3728"
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
## Color Values
|
|
253
|
+
|
|
254
|
+
Four formats are supported:
|
|
255
|
+
|
|
256
|
+
| Format | Example | Description |
|
|
257
|
+
|--------|---------|-------------|
|
|
258
|
+
| Hex | `"#ff0000"` | 6-digit hex RGB |
|
|
259
|
+
| 256-color | `39` | xterm 256-color palette index (0-255) |
|
|
260
|
+
| Variable | `"primary"` | Reference to a `vars` entry |
|
|
261
|
+
| Default | `""` | Terminal's default color |
|
|
262
|
+
|
|
263
|
+
### 256-Color Palette
|
|
264
|
+
|
|
265
|
+
- `0-15`: Basic ANSI colors (terminal-dependent)
|
|
266
|
+
- `16-231`: 6×6×6 RGB cube (`16 + 36×R + 6×G + B` where R,G,B are 0-5)
|
|
267
|
+
- `232-255`: Grayscale ramp
|
|
268
|
+
|
|
269
|
+
### Terminal Compatibility
|
|
270
|
+
|
|
271
|
+
Pi uses 24-bit RGB colors. Most modern terminals support this (iTerm2, Kitty, WezTerm, Windows Terminal, VS Code). For older terminals with only 256-color support, pi falls back to the nearest approximation.
|
|
272
|
+
|
|
273
|
+
Check truecolor support:
|
|
274
|
+
|
|
275
|
+
```bash
|
|
276
|
+
echo $COLORTERM # Should output "truecolor" or "24bit"
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
## Tips
|
|
280
|
+
|
|
281
|
+
**Dark terminals:** Use bright, saturated colors with higher contrast.
|
|
282
|
+
|
|
283
|
+
**Light terminals:** Use darker, muted colors with lower contrast.
|
|
284
|
+
|
|
285
|
+
**Color harmony:** Start with a base palette (Nord, Gruvbox, Tokyo Night), define it in `vars`, and reference consistently.
|
|
286
|
+
|
|
287
|
+
**Testing:** Check your theme with different message types, tool states, markdown content, and long wrapped text.
|
|
288
|
+
|
|
289
|
+
**VS Code:** Set `terminal.integrated.minimumContrastRatio` to `1` for accurate colors.
|
|
290
|
+
|
|
291
|
+
## Examples
|
|
292
|
+
|
|
293
|
+
See the built-in themes:
|
|
294
|
+
- [dark.json](../src/modes/interactive/theme/dark.json)
|
|
295
|
+
- [light.json](../src/modes/interactive/theme/light.json)
|
package/docs/tmux.md
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# tmux Setup
|
|
2
|
+
|
|
3
|
+
Pi works inside tmux, but tmux strips modifier information from certain keys by default. Without configuration, `Shift+Enter` and `Ctrl+Enter` are usually indistinguishable from plain `Enter`.
|
|
4
|
+
|
|
5
|
+
## Recommended Configuration
|
|
6
|
+
|
|
7
|
+
Add to `~/.tmux.conf`:
|
|
8
|
+
|
|
9
|
+
```tmux
|
|
10
|
+
set -g extended-keys on
|
|
11
|
+
set -g extended-keys-format csi-u
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
Then restart tmux fully:
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
tmux kill-server
|
|
18
|
+
tmux
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Pi requests extended key reporting automatically when Kitty keyboard protocol is not available. With `extended-keys-format csi-u`, tmux forwards modified keys in CSI-u format, which is the most reliable configuration. The `extended-keys-format` option requires tmux 3.5 or later.
|
|
22
|
+
|
|
23
|
+
## Why `csi-u` Is Recommended
|
|
24
|
+
|
|
25
|
+
With only:
|
|
26
|
+
|
|
27
|
+
```tmux
|
|
28
|
+
set -g extended-keys on
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
tmux defaults to `extended-keys-format xterm`. When an application requests extended key reporting, modified keys are forwarded in xterm `modifyOtherKeys` format such as:
|
|
32
|
+
|
|
33
|
+
- `Ctrl+C` → `\x1b[27;5;99~`
|
|
34
|
+
- `Ctrl+D` → `\x1b[27;5;100~`
|
|
35
|
+
- `Ctrl+Enter` → `\x1b[27;5;13~`
|
|
36
|
+
|
|
37
|
+
With `extended-keys-format csi-u`, the same keys are forwarded as:
|
|
38
|
+
|
|
39
|
+
- `Ctrl+C` → `\x1b[99;5u`
|
|
40
|
+
- `Ctrl+D` → `\x1b[100;5u`
|
|
41
|
+
- `Ctrl+Enter` → `\x1b[13;5u`
|
|
42
|
+
|
|
43
|
+
Pi supports both formats, but `csi-u` is the recommended tmux setup.
|
|
44
|
+
|
|
45
|
+
## What This Fixes
|
|
46
|
+
|
|
47
|
+
Without tmux extended keys, modified Enter keys collapse to legacy sequences:
|
|
48
|
+
|
|
49
|
+
| Key | Without extkeys | With `csi-u` |
|
|
50
|
+
|-----|-----------------|--------------|
|
|
51
|
+
| Enter | `\r` | `\r` |
|
|
52
|
+
| Shift+Enter | `\r` | `\x1b[13;2u` |
|
|
53
|
+
| Ctrl+Enter | `\r` | `\x1b[13;5u` |
|
|
54
|
+
| Alt/Option+Enter | `\x1b\r` | `\x1b[13;3u` |
|
|
55
|
+
|
|
56
|
+
This affects the default keybindings (`Enter` to submit, `Shift+Enter` for newline) and any custom keybindings using modified Enter.
|
|
57
|
+
|
|
58
|
+
## Requirements
|
|
59
|
+
|
|
60
|
+
- tmux 3.5 or later for `extended-keys-format csi-u` (run `tmux -V` to check)
|
|
61
|
+
- A terminal emulator that supports extended keys (Ghostty, Kitty, iTerm2, WezTerm, Windows Terminal)
|
|
62
|
+
|
|
63
|
+
With tmux 3.2 through 3.4, omit `extended-keys-format csi-u`; Pi still supports tmux's default xterm `modifyOtherKeys` format.
|