@draht/coding-agent 2026.7.13 → 2026.9.5-1
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 +241 -0
- package/README.md +47 -2
- package/agents/debugger.md +12 -1
- package/agents/git-committer.md +1 -0
- package/agents/implementer.md +20 -0
- package/agents/investigator.md +75 -0
- package/agents/reviewer.md +7 -0
- package/agents/spec-reviewer.md +66 -0
- package/agents/verifier.md +4 -3
- package/bin/draht-tools.cjs +472 -41
- package/dist/agents/debugger.md +12 -1
- package/dist/agents/git-committer.md +1 -0
- package/dist/agents/implementer.md +20 -0
- package/dist/agents/investigator.md +75 -0
- package/dist/agents/reviewer.md +7 -0
- package/dist/agents/spec-reviewer.md +66 -0
- package/dist/agents/verifier.md +4 -3
- package/dist/bun/cli.js +2 -0
- package/dist/bun/cli.js.map +1 -1
- package/dist/cli/args.d.ts +10 -0
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +80 -3
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/attach-mode.d.ts +61 -0
- package/dist/cli/attach-mode.d.ts.map +1 -1
- package/dist/cli/attach-mode.js +243 -5
- package/dist/cli/attach-mode.js.map +1 -1
- package/dist/cli/config-selector.js +1 -1
- package/dist/cli/config-selector.js.map +1 -1
- package/dist/cli/credential-print.d.ts +23 -0
- package/dist/cli/credential-print.d.ts.map +1 -0
- package/dist/cli/credential-print.js +117 -0
- package/dist/cli/credential-print.js.map +1 -0
- package/dist/cli/list-models.d.ts +2 -2
- package/dist/cli/list-models.d.ts.map +1 -1
- package/dist/cli/list-models.js +3 -3
- package/dist/cli/list-models.js.map +1 -1
- package/dist/cli/startup-ui.js +1 -1
- package/dist/cli/startup-ui.js.map +1 -1
- package/dist/config.d.ts +9 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +31 -4
- package/dist/config.js.map +1 -1
- package/dist/core/agent-session-runtime.d.ts +17 -1
- package/dist/core/agent-session-runtime.d.ts.map +1 -1
- package/dist/core/agent-session-runtime.js +90 -30
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session-services.d.ts +4 -7
- package/dist/core/agent-session-services.d.ts.map +1 -1
- package/dist/core/agent-session-services.js +24 -9
- package/dist/core/agent-session-services.js.map +1 -1
- package/dist/core/agent-session.d.ts +87 -27
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +337 -154
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/auth-storage.d.ts +20 -104
- package/dist/core/auth-storage.d.ts.map +1 -1
- package/dist/core/auth-storage.js +104 -260
- package/dist/core/auth-storage.js.map +1 -1
- package/dist/core/builtins/checkpoints.d.ts +20 -0
- package/dist/core/builtins/checkpoints.d.ts.map +1 -0
- package/dist/core/builtins/checkpoints.js +161 -0
- package/dist/core/builtins/checkpoints.js.map +1 -0
- package/dist/core/builtins/duet.d.ts +26 -0
- package/dist/core/builtins/duet.d.ts.map +1 -0
- package/dist/core/builtins/duet.js +660 -0
- package/dist/core/builtins/duet.js.map +1 -0
- package/dist/core/builtins/index.d.ts.map +1 -1
- package/dist/core/builtins/index.js +7 -1
- package/dist/core/builtins/index.js.map +1 -1
- package/dist/core/builtins/subagent.d.ts +24 -4
- package/dist/core/builtins/subagent.d.ts.map +1 -1
- package/dist/core/builtins/subagent.js +278 -35
- package/dist/core/builtins/subagent.js.map +1 -1
- package/dist/core/cache-stats.d.ts +2 -2
- package/dist/core/cache-stats.d.ts.map +1 -1
- package/dist/core/cache-stats.js +1 -1
- package/dist/core/cache-stats.js.map +1 -1
- package/dist/core/checkpoints/checkpoint-cli.d.ts +17 -0
- package/dist/core/checkpoints/checkpoint-cli.d.ts.map +1 -0
- package/dist/core/checkpoints/checkpoint-cli.js +78 -0
- package/dist/core/checkpoints/checkpoint-cli.js.map +1 -0
- package/dist/core/checkpoints/checkpoint-manager.d.ts +294 -0
- package/dist/core/checkpoints/checkpoint-manager.d.ts.map +1 -0
- package/dist/core/checkpoints/checkpoint-manager.js +865 -0
- package/dist/core/checkpoints/checkpoint-manager.js.map +1 -0
- package/dist/core/checkpoints/rewind.d.ts +141 -0
- package/dist/core/checkpoints/rewind.d.ts.map +1 -0
- package/dist/core/checkpoints/rewind.js +246 -0
- package/dist/core/checkpoints/rewind.js.map +1 -0
- package/dist/core/compaction/branch-summarization.d.ts +9 -3
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +16 -14
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction/compaction.d.ts +24 -3
- package/dist/core/compaction/compaction.d.ts.map +1 -1
- package/dist/core/compaction/compaction.js +96 -30
- package/dist/core/compaction/compaction.js.map +1 -1
- package/dist/core/compaction/utils.d.ts +1 -1
- package/dist/core/compaction/utils.d.ts.map +1 -1
- package/dist/core/compaction/utils.js +6 -17
- package/dist/core/compaction/utils.js.map +1 -1
- package/dist/core/context-windows.d.ts +7 -0
- package/dist/core/context-windows.d.ts.map +1 -0
- package/dist/core/context-windows.js +35 -0
- package/dist/core/context-windows.js.map +1 -0
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/loader.d.ts.map +1 -1
- package/dist/core/extensions/loader.js +101 -23
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +19 -3
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +117 -2
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/types.d.ts +236 -9
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/extensions/wrapper.d.ts.map +1 -1
- package/dist/core/extensions/wrapper.js +22 -3
- package/dist/core/extensions/wrapper.js.map +1 -1
- package/dist/core/footer-data-provider.d.ts +10 -0
- package/dist/core/footer-data-provider.d.ts.map +1 -1
- package/dist/core/footer-data-provider.js +1 -1
- package/dist/core/footer-data-provider.js.map +1 -1
- package/dist/core/http-dispatcher.d.ts.map +1 -1
- package/dist/core/http-dispatcher.js +7 -0
- package/dist/core/http-dispatcher.js.map +1 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js.map +1 -1
- package/dist/core/keybindings.d.ts +18 -3
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +12 -3
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/model-config.d.ts +542 -0
- package/dist/core/model-config.d.ts.map +1 -0
- package/dist/core/model-config.js +247 -0
- package/dist/core/model-config.js.map +1 -0
- package/dist/core/model-registry.d.ts +19 -124
- package/dist/core/model-registry.d.ts.map +1 -1
- package/dist/core/model-registry.js +56 -727
- package/dist/core/model-registry.js.map +1 -1
- package/dist/core/model-resolver.d.ts +7 -6
- package/dist/core/model-resolver.d.ts.map +1 -1
- package/dist/core/model-resolver.js +74 -27
- package/dist/core/model-resolver.js.map +1 -1
- package/dist/core/model-runtime.d.ts +89 -0
- package/dist/core/model-runtime.d.ts.map +1 -0
- package/dist/core/model-runtime.js +451 -0
- package/dist/core/model-runtime.js.map +1 -0
- package/dist/core/models-store.d.ts +17 -0
- package/dist/core/models-store.d.ts.map +1 -0
- package/dist/core/models-store.js +46 -0
- package/dist/core/models-store.js.map +1 -0
- package/dist/core/multi-agent/permission-gate.d.ts.map +1 -1
- package/dist/core/multi-agent/permission-gate.js +4 -3
- package/dist/core/multi-agent/permission-gate.js.map +1 -1
- package/dist/core/multi-agent/worktree.d.ts +2 -0
- package/dist/core/multi-agent/worktree.d.ts.map +1 -1
- package/dist/core/multi-agent/worktree.js +2 -2
- package/dist/core/multi-agent/worktree.js.map +1 -1
- package/dist/core/package-manager.d.ts +7 -1
- package/dist/core/package-manager.d.ts.map +1 -1
- package/dist/core/package-manager.js +41 -45
- package/dist/core/package-manager.js.map +1 -1
- package/dist/core/permission-relay/index.d.ts +19 -0
- package/dist/core/permission-relay/index.d.ts.map +1 -0
- package/dist/core/permission-relay/index.js +49 -0
- package/dist/core/permission-relay/index.js.map +1 -0
- package/dist/core/permission-relay/relay-ui-context.d.ts +39 -0
- package/dist/core/permission-relay/relay-ui-context.d.ts.map +1 -0
- package/dist/core/permission-relay/relay-ui-context.js +788 -0
- package/dist/core/permission-relay/relay-ui-context.js.map +1 -0
- package/dist/core/permission-relay/types.d.ts +222 -0
- package/dist/core/permission-relay/types.d.ts.map +1 -0
- package/dist/core/permission-relay/types.js +15 -0
- package/dist/core/permission-relay/types.js.map +1 -0
- package/dist/core/pi-manifest.d.ts +14 -0
- package/dist/core/pi-manifest.d.ts.map +1 -0
- package/dist/core/pi-manifest.js +35 -0
- package/dist/core/pi-manifest.js.map +1 -0
- package/dist/core/project-trust.js +2 -2
- package/dist/core/project-trust.js.map +1 -1
- package/dist/core/prompt-templates.d.ts +1 -0
- package/dist/core/prompt-templates.d.ts.map +1 -1
- package/dist/core/prompt-templates.js +4 -4
- package/dist/core/prompt-templates.js.map +1 -1
- package/dist/core/provider-composer.d.ts +55 -0
- package/dist/core/provider-composer.d.ts.map +1 -0
- package/dist/core/provider-composer.js +375 -0
- package/dist/core/provider-composer.js.map +1 -0
- package/dist/core/radius.d.ts +2 -0
- package/dist/core/radius.d.ts.map +1 -0
- package/dist/core/radius.js +2 -0
- package/dist/core/radius.js.map +1 -0
- package/dist/core/remote-catalog-provider.d.ts +5 -0
- package/dist/core/remote-catalog-provider.d.ts.map +1 -0
- package/dist/core/remote-catalog-provider.js +115 -0
- package/dist/core/remote-catalog-provider.js.map +1 -0
- package/dist/core/resource-loader.d.ts +36 -0
- package/dist/core/resource-loader.d.ts.map +1 -1
- package/dist/core/resource-loader.js +159 -27
- package/dist/core/resource-loader.js.map +1 -1
- package/dist/core/runtime-credentials.d.ts +15 -0
- package/dist/core/runtime-credentials.d.ts.map +1 -0
- package/dist/core/runtime-credentials.js +35 -0
- package/dist/core/runtime-credentials.js.map +1 -0
- package/dist/core/sandbox/bash-operations.d.ts +149 -0
- package/dist/core/sandbox/bash-operations.d.ts.map +1 -0
- package/dist/core/sandbox/bash-operations.js +163 -0
- package/dist/core/sandbox/bash-operations.js.map +1 -0
- package/dist/core/sandbox/env.d.ts +83 -0
- package/dist/core/sandbox/env.d.ts.map +1 -0
- package/dist/core/sandbox/env.js +123 -0
- package/dist/core/sandbox/env.js.map +1 -0
- package/dist/core/sandbox/executor.d.ts +104 -0
- package/dist/core/sandbox/executor.d.ts.map +1 -0
- package/dist/core/sandbox/executor.js +92 -0
- package/dist/core/sandbox/executor.js.map +1 -0
- package/dist/core/sandbox/index.d.ts +36 -0
- package/dist/core/sandbox/index.d.ts.map +1 -0
- package/dist/core/sandbox/index.js +36 -0
- package/dist/core/sandbox/index.js.map +1 -0
- package/dist/core/sandbox/linux.d.ts +121 -0
- package/dist/core/sandbox/linux.d.ts.map +1 -0
- package/dist/core/sandbox/linux.js +260 -0
- package/dist/core/sandbox/linux.js.map +1 -0
- package/dist/core/sandbox/policy.d.ts +142 -0
- package/dist/core/sandbox/policy.d.ts.map +1 -0
- package/dist/core/sandbox/policy.js +297 -0
- package/dist/core/sandbox/policy.js.map +1 -0
- package/dist/core/sandbox/real-path.d.ts +112 -0
- package/dist/core/sandbox/real-path.d.ts.map +1 -0
- package/dist/core/sandbox/real-path.js +158 -0
- package/dist/core/sandbox/real-path.js.map +1 -0
- package/dist/core/sandbox/seatbelt-profile.d.ts +95 -0
- package/dist/core/sandbox/seatbelt-profile.d.ts.map +1 -0
- package/dist/core/sandbox/seatbelt-profile.js +239 -0
- package/dist/core/sandbox/seatbelt-profile.js.map +1 -0
- package/dist/core/sandbox/seatbelt.d.ts +95 -0
- package/dist/core/sandbox/seatbelt.d.ts.map +1 -0
- package/dist/core/sandbox/seatbelt.js +154 -0
- package/dist/core/sandbox/seatbelt.js.map +1 -0
- package/dist/core/sandbox/self-test.d.ts +109 -0
- package/dist/core/sandbox/self-test.d.ts.map +1 -0
- package/dist/core/sandbox/self-test.js +369 -0
- package/dist/core/sandbox/self-test.js.map +1 -0
- package/dist/core/sandbox/spawn.d.ts +33 -0
- package/dist/core/sandbox/spawn.d.ts.map +1 -0
- package/dist/core/sandbox/spawn.js +87 -0
- package/dist/core/sandbox/spawn.js.map +1 -0
- package/dist/core/sdk.d.ts +3 -6
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +25 -22
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-manager.d.ts +74 -7
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +169 -34
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/settings-manager.d.ts +22 -1
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +36 -16
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/skills.d.ts +3 -1
- package/dist/core/skills.d.ts.map +1 -1
- package/dist/core/skills.js +19 -6
- package/dist/core/skills.js.map +1 -1
- package/dist/core/slash-commands.d.ts.map +1 -1
- package/dist/core/slash-commands.js +1 -0
- package/dist/core/slash-commands.js.map +1 -1
- package/dist/core/soak/soak-log.d.ts +298 -0
- package/dist/core/soak/soak-log.d.ts.map +1 -0
- package/dist/core/soak/soak-log.js +660 -0
- package/dist/core/soak/soak-log.js.map +1 -0
- package/dist/core/soak/soak-reader.d.ts +60 -0
- package/dist/core/soak/soak-reader.d.ts.map +1 -0
- package/dist/core/soak/soak-reader.js +106 -0
- package/dist/core/soak/soak-reader.js.map +1 -0
- package/dist/core/socket-server/discovery.d.ts +78 -1
- package/dist/core/socket-server/discovery.d.ts.map +1 -1
- package/dist/core/socket-server/discovery.js +356 -37
- package/dist/core/socket-server/discovery.js.map +1 -1
- package/dist/core/socket-server/index.d.ts +10 -4
- package/dist/core/socket-server/index.d.ts.map +1 -1
- package/dist/core/socket-server/index.js +6 -3
- package/dist/core/socket-server/index.js.map +1 -1
- package/dist/core/socket-server/permission-delivery.d.ts +125 -0
- package/dist/core/socket-server/permission-delivery.d.ts.map +1 -0
- package/dist/core/socket-server/permission-delivery.js +152 -0
- package/dist/core/socket-server/permission-delivery.js.map +1 -0
- package/dist/core/socket-server/permission-registry.d.ts +301 -0
- package/dist/core/socket-server/permission-registry.d.ts.map +1 -0
- package/dist/core/socket-server/permission-registry.js +410 -0
- package/dist/core/socket-server/permission-registry.js.map +1 -0
- package/dist/core/socket-server/permission-relay.d.ts +81 -0
- package/dist/core/socket-server/permission-relay.d.ts.map +1 -0
- package/dist/core/socket-server/permission-relay.js +528 -0
- package/dist/core/socket-server/permission-relay.js.map +1 -0
- package/dist/core/socket-server/safe-text.d.ts +83 -0
- package/dist/core/socket-server/safe-text.d.ts.map +1 -0
- package/dist/core/socket-server/safe-text.js +277 -0
- package/dist/core/socket-server/safe-text.js.map +1 -0
- package/dist/core/socket-server/session-integration.d.ts +65 -2
- package/dist/core/socket-server/session-integration.d.ts.map +1 -1
- package/dist/core/socket-server/session-integration.js +434 -32
- package/dist/core/socket-server/session-integration.js.map +1 -1
- package/dist/core/socket-server/socket-client.d.ts +21 -2
- package/dist/core/socket-server/socket-client.d.ts.map +1 -1
- package/dist/core/socket-server/socket-client.js +52 -1
- package/dist/core/socket-server/socket-client.js.map +1 -1
- package/dist/core/socket-server/socket-server.d.ts +152 -1
- package/dist/core/socket-server/socket-server.d.ts.map +1 -1
- package/dist/core/socket-server/socket-server.js +775 -26
- package/dist/core/socket-server/socket-server.js.map +1 -1
- package/dist/core/socket-server/types.d.ts +106 -2
- package/dist/core/socket-server/types.d.ts.map +1 -1
- package/dist/core/socket-server/types.js +13 -1
- package/dist/core/socket-server/types.js.map +1 -1
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +10 -21
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/core/tools/bash.d.ts +3 -1
- package/dist/core/tools/bash.d.ts.map +1 -1
- package/dist/core/tools/bash.js +39 -7
- package/dist/core/tools/bash.js.map +1 -1
- package/dist/core/tools/edit.d.ts.map +1 -1
- package/dist/core/tools/edit.js +17 -2
- package/dist/core/tools/edit.js.map +1 -1
- package/dist/core/tools/find.d.ts +3 -0
- package/dist/core/tools/find.d.ts.map +1 -1
- package/dist/core/tools/find.js +11 -18
- package/dist/core/tools/find.js.map +1 -1
- package/dist/core/tools/read.js +1 -1
- package/dist/core/tools/read.js.map +1 -1
- package/dist/core/tools/tool-definition-wrapper.d.ts.map +1 -1
- package/dist/core/tools/tool-definition-wrapper.js +3 -1
- package/dist/core/tools/tool-definition-wrapper.js.map +1 -1
- package/dist/core/trust-manager.d.ts +6 -4
- package/dist/core/trust-manager.d.ts.map +1 -1
- package/dist/core/trust-manager.js +55 -21
- package/dist/core/trust-manager.js.map +1 -1
- package/dist/core/usage-totals.d.ts +19 -0
- package/dist/core/usage-totals.d.ts.map +1 -0
- package/dist/core/usage-totals.js +52 -0
- package/dist/core/usage-totals.js.map +1 -0
- package/dist/extensions/index.d.ts +3 -0
- package/dist/extensions/index.d.ts.map +1 -0
- package/dist/extensions/index.js +7 -0
- package/dist/extensions/index.js.map +1 -0
- package/dist/extensions/llama/client.d.ts +61 -0
- package/dist/extensions/llama/client.d.ts.map +1 -0
- package/dist/extensions/llama/client.js +300 -0
- package/dist/extensions/llama/client.js.map +1 -0
- package/dist/extensions/llama/huggingface.d.ts +23 -0
- package/dist/extensions/llama/huggingface.d.ts.map +1 -0
- package/dist/extensions/llama/huggingface.js +139 -0
- package/dist/extensions/llama/huggingface.js.map +1 -0
- package/dist/extensions/llama/index.d.ts +3 -0
- package/dist/extensions/llama/index.d.ts.map +1 -0
- package/dist/extensions/llama/index.js +208 -0
- package/dist/extensions/llama/index.js.map +1 -0
- package/dist/extensions/llama/provider.d.ts +10 -0
- package/dist/extensions/llama/provider.d.ts.map +1 -0
- package/dist/extensions/llama/provider.js +111 -0
- package/dist/extensions/llama/provider.js.map +1 -0
- package/dist/extensions/llama/ui.d.ts +42 -0
- package/dist/extensions/llama/ui.d.ts.map +1 -0
- package/dist/extensions/llama/ui.js +400 -0
- package/dist/extensions/llama/ui.js.map +1 -0
- package/dist/extensions/stub-provider/index.d.ts +9 -0
- package/dist/extensions/stub-provider/index.d.ts.map +1 -0
- package/dist/extensions/stub-provider/index.js +13 -0
- package/dist/extensions/stub-provider/index.js.map +1 -0
- package/dist/extensions/stub-provider/provider.d.ts +77 -0
- package/dist/extensions/stub-provider/provider.d.ts.map +1 -0
- package/dist/extensions/stub-provider/provider.js +193 -0
- package/dist/extensions/stub-provider/provider.js.map +1 -0
- package/dist/hooks/gsd/draht-quality-gate.js +3 -3
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +305 -61
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +22 -10
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/config-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/config-selector.js +3 -2
- package/dist/modes/interactive/components/config-selector.js.map +1 -1
- package/dist/modes/interactive/components/custom-editor.js +1 -1
- package/dist/modes/interactive/components/custom-editor.js.map +1 -1
- package/dist/modes/interactive/components/custom-message.d.ts +3 -1
- package/dist/modes/interactive/components/custom-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-message.js +9 -2
- package/dist/modes/interactive/components/custom-message.js.map +1 -1
- package/dist/modes/interactive/components/extension-editor.d.ts +1 -2
- package/dist/modes/interactive/components/extension-editor.d.ts.map +1 -1
- package/dist/modes/interactive/components/extension-editor.js +16 -46
- package/dist/modes/interactive/components/extension-editor.js.map +1 -1
- package/dist/modes/interactive/components/extension-selector.d.ts +49 -0
- package/dist/modes/interactive/components/extension-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/extension-selector.js +202 -5
- package/dist/modes/interactive/components/extension-selector.js.map +1 -1
- package/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/dist/modes/interactive/components/footer.js +24 -23
- package/dist/modes/interactive/components/footer.js.map +1 -1
- package/dist/modes/interactive/components/login-dialog.d.ts +5 -5
- package/dist/modes/interactive/components/login-dialog.d.ts.map +1 -1
- package/dist/modes/interactive/components/login-dialog.js +17 -8
- package/dist/modes/interactive/components/login-dialog.js.map +1 -1
- package/dist/modes/interactive/components/model-selector.d.ts +11 -4
- package/dist/modes/interactive/components/model-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/model-selector.js +74 -41
- package/dist/modes/interactive/components/model-selector.js.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.d.ts +4 -4
- package/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.js +14 -25
- package/dist/modes/interactive/components/oauth-selector.js.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +22 -13
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -1
- package/dist/modes/interactive/components/session-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector.js +10 -2
- package/dist/modes/interactive/components/session-selector.js.map +1 -1
- package/dist/modes/interactive/components/settings-selector.d.ts +2 -0
- package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/settings-selector.js +10 -0
- package/dist/modes/interactive/components/settings-selector.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +10 -1
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector.d.ts +25 -2
- package/dist/modes/interactive/components/tree-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector.js +68 -17
- package/dist/modes/interactive/components/tree-selector.js.map +1 -1
- package/dist/modes/interactive/external-editor.d.ts +12 -0
- package/dist/modes/interactive/external-editor.d.ts.map +1 -0
- package/dist/modes/interactive/external-editor.js +37 -0
- package/dist/modes/interactive/external-editor.js.map +1 -0
- package/dist/modes/interactive/interactive-mode.d.ts +107 -10
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +763 -285
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts +4 -0
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +7 -0
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-mode.js +185 -9
- package/dist/modes/rpc/rpc-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +79 -1
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/dist/package-manager-cli.d.ts.map +1 -1
- package/dist/package-manager-cli.js +67 -5
- package/dist/package-manager-cli.js.map +1 -1
- package/dist/prompts/commands/atomic-commit.md +1 -12
- package/dist/prompts/commands/brainstorm.md +12 -15
- package/dist/prompts/commands/create-verification-skill.md +108 -0
- package/dist/prompts/commands/discuss-phase.md +3 -14
- package/dist/prompts/commands/execute-phase.md +3 -11
- package/dist/prompts/commands/fix.md +41 -18
- package/dist/prompts/commands/grill.md +66 -0
- package/dist/prompts/commands/init-project.md +5 -15
- package/dist/prompts/commands/map-codebase.md +1 -13
- package/dist/prompts/commands/new-project.md +5 -15
- package/dist/prompts/commands/next-milestone.md +1 -13
- package/dist/prompts/commands/orchestrate.md +1 -1
- package/dist/prompts/commands/pause-work.md +1 -13
- package/dist/prompts/commands/plan-phase.md +2 -11
- package/dist/prompts/commands/progress.md +0 -13
- package/dist/prompts/commands/quick.md +3 -11
- package/dist/prompts/commands/resolve-conflicts.md +71 -0
- package/dist/prompts/commands/resume-work.md +0 -13
- package/dist/prompts/commands/review.md +4 -13
- package/dist/prompts/commands/triage.md +159 -0
- package/dist/prompts/commands/verify-work.md +4 -14
- package/dist/prompts/commands/why.md +135 -0
- package/dist/skills/atomic-reasoning/SKILL.md +115 -0
- package/dist/skills/blast-radius/SKILL.md +55 -0
- package/dist/skills/epistemics/SKILL.md +99 -0
- package/dist/skills/hexagon-animation/SKILL.md +49 -0
- package/dist/skills/hexagon-animation/generate.mjs +81 -0
- package/dist/skills/hexagon-animation/template.html +361 -0
- package/dist/skills/typescript-discipline/SKILL.md +50 -0
- package/dist/skills/typescript-discipline/references/patterns.md +294 -0
- package/dist/skills/unslop/SKILL.md +101 -0
- package/dist/utils/canonical-path.d.ts +28 -0
- package/dist/utils/canonical-path.d.ts.map +1 -0
- package/dist/utils/canonical-path.js +90 -0
- package/dist/utils/canonical-path.js.map +1 -0
- package/dist/utils/child-process.d.ts +12 -1
- package/dist/utils/child-process.d.ts.map +1 -1
- package/dist/utils/child-process.js +25 -8
- package/dist/utils/child-process.js.map +1 -1
- package/dist/utils/clipboard-native.d.ts +1 -0
- package/dist/utils/clipboard-native.d.ts.map +1 -1
- package/dist/utils/clipboard-native.js.map +1 -1
- package/dist/utils/clipboard.d.ts +2 -0
- package/dist/utils/clipboard.d.ts.map +1 -1
- package/dist/utils/clipboard.js +53 -9
- package/dist/utils/clipboard.js.map +1 -1
- package/dist/utils/exif-orientation.d.ts.map +1 -1
- package/dist/utils/exif-orientation.js +2 -3
- package/dist/utils/exif-orientation.js.map +1 -1
- package/dist/utils/paths.d.ts +2 -7
- package/dist/utils/paths.d.ts.map +1 -1
- package/dist/utils/paths.js +13 -15
- package/dist/utils/paths.js.map +1 -1
- package/dist/utils/shell.d.ts.map +1 -1
- package/dist/utils/shell.js +6 -4
- package/dist/utils/shell.js.map +1 -1
- package/dist/utils/tools-manager.d.ts.map +1 -1
- package/dist/utils/tools-manager.js +3 -5
- package/dist/utils/tools-manager.js.map +1 -1
- package/dist/utils/version-check.d.ts.map +1 -1
- package/dist/utils/version-check.js +3 -1
- package/dist/utils/version-check.js.map +1 -1
- package/docs/attachable-sessions.md +79 -0
- package/docs/compaction.md +29 -24
- package/docs/containerization.md +23 -23
- package/docs/custom-provider.md +66 -32
- package/docs/development.md +9 -9
- package/docs/docs.json +6 -2
- package/docs/duet.md +42 -0
- package/docs/environment-variables.md +88 -0
- package/docs/extensions.md +278 -65
- package/docs/index.md +12 -10
- package/docs/json.md +12 -8
- package/docs/keybindings.md +8 -5
- package/docs/llama-cpp.md +99 -0
- package/docs/models.md +19 -8
- package/docs/packages.md +43 -42
- package/docs/prompt-templates.md +5 -4
- package/docs/providers.md +45 -11
- package/docs/quickstart.md +33 -33
- package/docs/rpc.md +190 -19
- package/docs/sdk.md +18 -15
- package/docs/security.md +18 -18
- package/docs/session-format.md +53 -15
- package/docs/sessions.md +17 -14
- package/docs/settings.md +26 -19
- package/docs/shell-aliases.md +2 -2
- package/docs/skills.md +12 -11
- package/docs/terminal-setup.md +12 -12
- package/docs/termux.md +6 -6
- package/docs/themes.md +11 -11
- package/docs/tmux.md +4 -4
- package/docs/tui.md +46 -31
- package/docs/usage.md +53 -63
- package/docs/windows.md +2 -2
- package/examples/extensions/custom-compaction.ts +4 -0
- package/examples/extensions/custom-provider-anthropic/index.ts +9 -3
- package/examples/extensions/custom-provider-anthropic/package.json +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
- package/examples/extensions/custom-provider-qwen-cli/package.json +1 -1
- package/examples/extensions/gondolin/package.json +2 -2
- package/examples/extensions/handoff.ts +9 -1
- package/examples/extensions/kimi-deferred-tools.ts +61 -0
- package/examples/extensions/message-renderer.ts +2 -2
- package/examples/extensions/overlay-qa-tests.ts +3 -3
- package/examples/extensions/sandbox/package.json +1 -1
- package/examples/extensions/summarize.ts +3 -0
- package/examples/extensions/with-deps/package.json +1 -1
- package/examples/sdk/02-custom-model.ts +5 -8
- package/examples/sdk/09-api-keys-and-oauth.ts +15 -31
- package/examples/sdk/12-full-control.ts +9 -12
- package/hooks/gsd/draht-quality-gate.js +3 -3
- package/package.json +14 -11
- package/prompts/commands/atomic-commit.md +1 -12
- package/prompts/commands/brainstorm.md +12 -15
- package/prompts/commands/create-verification-skill.md +108 -0
- package/prompts/commands/discuss-phase.md +3 -14
- package/prompts/commands/execute-phase.md +3 -11
- package/prompts/commands/fix.md +41 -18
- package/prompts/commands/grill.md +66 -0
- package/prompts/commands/init-project.md +5 -15
- package/prompts/commands/map-codebase.md +1 -13
- package/prompts/commands/new-project.md +5 -15
- package/prompts/commands/next-milestone.md +1 -13
- package/prompts/commands/orchestrate.md +1 -1
- package/prompts/commands/pause-work.md +1 -13
- package/prompts/commands/plan-phase.md +2 -11
- package/prompts/commands/progress.md +0 -13
- package/prompts/commands/quick.md +3 -11
- package/prompts/commands/resolve-conflicts.md +71 -0
- package/prompts/commands/resume-work.md +0 -13
- package/prompts/commands/review.md +4 -13
- package/prompts/commands/triage.md +159 -0
- package/prompts/commands/verify-work.md +4 -14
- package/prompts/commands/why.md +135 -0
- package/skills/atomic-reasoning/SKILL.md +115 -0
- package/skills/blast-radius/SKILL.md +55 -0
- package/skills/epistemics/SKILL.md +99 -0
- package/skills/hexagon-animation/SKILL.md +49 -0
- package/skills/hexagon-animation/generate.mjs +81 -0
- package/skills/hexagon-animation/template.html +361 -0
- package/skills/typescript-discipline/SKILL.md +50 -0
- package/skills/typescript-discipline/references/patterns.md +294 -0
- package/skills/unslop/SKILL.md +101 -0
- package/dist/core/provider-display-names.d.ts +0 -2
- package/dist/core/provider-display-names.d.ts.map +0 -1
- package/dist/core/provider-display-names.js +0 -36
- package/dist/core/provider-display-names.js.map +0 -1
- package/dist/prompts/agents/build.md +0 -86
- package/dist/prompts/agents/plan.md +0 -79
- package/dist/prompts/agents/verify.md +0 -69
- package/prompts/agents/build.md +0 -86
- package/prompts/agents/plan.md +0 -79
- package/prompts/agents/verify.md +0 -69
package/docs/session-format.md
CHANGED
|
@@ -5,16 +5,16 @@ Sessions are stored as JSONL (JSON Lines) files. Each line is a JSON object with
|
|
|
5
5
|
## File Location
|
|
6
6
|
|
|
7
7
|
```
|
|
8
|
-
~/.
|
|
8
|
+
~/.draht/agent/sessions/--<path>--/<timestamp>_<uuid>.jsonl
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
Where `<path>` is the working directory with `/` replaced by `-`.
|
|
12
12
|
|
|
13
13
|
## Deleting Sessions
|
|
14
14
|
|
|
15
|
-
Sessions can be removed by deleting their `.jsonl` files under `~/.
|
|
15
|
+
Sessions can be removed by deleting their `.jsonl` files under `~/.draht/agent/sessions/`.
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
draht also supports deleting sessions interactively from `/resume` (select a session and press `Ctrl+D`, then confirm). When available, draht uses the `trash` CLI to avoid permanent deletion.
|
|
18
18
|
|
|
19
19
|
## Session Version
|
|
20
20
|
|
|
@@ -28,11 +28,11 @@ Existing sessions are automatically migrated to the current version (v3) when lo
|
|
|
28
28
|
|
|
29
29
|
## Source Files
|
|
30
30
|
|
|
31
|
-
Source on GitHub ([
|
|
32
|
-
- [`packages/coding-agent/src/core/session-manager.ts`](https://github.com/
|
|
33
|
-
- [`packages/coding-agent/src/core/messages.ts`](https://github.com/
|
|
34
|
-
- [`packages/ai/src/types.ts`](https://github.com/
|
|
35
|
-
- [`packages/agent/src/types.ts`](https://github.com/
|
|
31
|
+
Source on GitHub ([draht](https://github.com/draht-dev/draht)):
|
|
32
|
+
- [`packages/coding-agent/src/core/session-manager.ts`](https://github.com/draht-dev/draht/blob/main/packages/coding-agent/src/core/session-manager.ts) - Session entry types and SessionManager
|
|
33
|
+
- [`packages/coding-agent/src/core/messages.ts`](https://github.com/draht-dev/draht/blob/main/packages/coding-agent/src/core/messages.ts) - Extended message types (BashExecutionMessage, CustomMessage, etc.)
|
|
34
|
+
- [`packages/ai/src/types.ts`](https://github.com/draht-dev/draht/blob/main/packages/ai/src/types.ts) - Base message types (UserMessage, AssistantMessage, ToolResultMessage)
|
|
35
|
+
- [`packages/agent/src/types.ts`](https://github.com/draht-dev/draht/blob/main/packages/agent/src/types.ts) - AgentMessage union type
|
|
36
36
|
|
|
37
37
|
For TypeScript definitions in your project, inspect `node_modules/@draht/coding-agent/dist/` and `node_modules/@draht/ai/dist/`.
|
|
38
38
|
|
|
@@ -69,7 +69,7 @@ interface ToolCall {
|
|
|
69
69
|
}
|
|
70
70
|
```
|
|
71
71
|
|
|
72
|
-
### Base Message Types (from
|
|
72
|
+
### Base Message Types (from @draht/ai)
|
|
73
73
|
|
|
74
74
|
```typescript
|
|
75
75
|
interface UserMessage {
|
|
@@ -96,6 +96,7 @@ interface ToolResultMessage {
|
|
|
96
96
|
toolName: string;
|
|
97
97
|
content: (TextContent | ImageContent)[];
|
|
98
98
|
details?: any; // Tool-specific metadata
|
|
99
|
+
usage?: Usage; // Nested LLM work performed by the tool
|
|
99
100
|
isError: boolean;
|
|
100
101
|
timestamp: number;
|
|
101
102
|
}
|
|
@@ -116,7 +117,9 @@ interface Usage {
|
|
|
116
117
|
}
|
|
117
118
|
```
|
|
118
119
|
|
|
119
|
-
|
|
120
|
+
The exported @draht/ai `StopReason` type also includes `"pending"`, but that value is reserved for partial messages in streaming events. Terminal `done`/`error` messages replace it with a completion reason before draht persists the assistant message, so `"pending"` should never appear in session JSONL.
|
|
121
|
+
|
|
122
|
+
### Extended Message Types (from @draht/coding-agent)
|
|
120
123
|
|
|
121
124
|
```typescript
|
|
122
125
|
interface BashExecutionMessage {
|
|
@@ -231,9 +234,18 @@ Created when context is compacted. Stores a summary of earlier messages.
|
|
|
231
234
|
{"type":"compaction","id":"f6g7h8i9","parentId":"e5f6g7h8","timestamp":"2024-12-03T14:10:00.000Z","summary":"User discussed X, Y, Z...","firstKeptEntryId":"c3d4e5f6","tokensBefore":50000}
|
|
232
235
|
```
|
|
233
236
|
|
|
237
|
+
Newer harness-generated compactions embed the retained post-compaction context directly on the entry, instead of `firstKeptEntryId`:
|
|
238
|
+
|
|
239
|
+
```json
|
|
240
|
+
{"type":"compaction","id":"f6g7h8i9","parentId":"e5f6g7h8","timestamp":"2024-12-03T14:10:00.000Z","summary":"User discussed X, Y, Z...","tokensBefore":50000,"retainedTail":[{"role":"user","content":"latest request"},{"role":"assistant","content":[{"type":"text","text":"latest reply"}],"provider":"anthropic","model":"claude-sonnet-4-5","usage":{...},"stopReason":"stop"}]}
|
|
241
|
+
```
|
|
242
|
+
|
|
234
243
|
Optional fields:
|
|
244
|
+
- `usage`: LLM usage from generating the summary; included in session token and cost totals
|
|
245
|
+
- `retainedTail`: Materialized `AgentMessage[]` kept after compaction. This is optional only for backward compatibility with older sessions. Newer harness-generated compactions include it so we can rebuild context from this checkpoint without walking older entries before the compaction entry.
|
|
235
246
|
- `details`: Implementation-specific data (e.g., `{ readFiles: string[], modifiedFiles: string[] }` for default, or custom data for extensions)
|
|
236
|
-
- `fromHook`: `true` if generated by an extension, `false`/`undefined` if
|
|
247
|
+
- `fromHook`: `true` if generated by an extension, `false`/`undefined` if draht-generated (legacy field name)
|
|
248
|
+
- `firstKeptEntryId`: for compatibility with old entry format.
|
|
237
249
|
|
|
238
250
|
### BranchSummaryEntry
|
|
239
251
|
|
|
@@ -244,8 +256,9 @@ Created when switching branches via `/tree` with an LLM generated summary of the
|
|
|
244
256
|
```
|
|
245
257
|
|
|
246
258
|
Optional fields:
|
|
259
|
+
- `usage`: LLM usage from generating the summary; included in session token and cost totals
|
|
247
260
|
- `details`: File tracking data (`{ readFiles: string[], modifiedFiles: string[] }`) for default, or custom data for extensions
|
|
248
|
-
- `fromHook`: `true` if generated by an extension, `false`/`undefined` if
|
|
261
|
+
- `fromHook`: `true` if generated by an extension, `false`/`undefined` if draht-generated (legacy field name)
|
|
249
262
|
|
|
250
263
|
### CustomEntry
|
|
251
264
|
|
|
@@ -290,6 +303,26 @@ Session metadata (e.g., user-defined display name). Set via `/name`, `--name` /
|
|
|
290
303
|
|
|
291
304
|
The session name is displayed in the session selector (`/resume`) instead of the first message when set.
|
|
292
305
|
|
|
306
|
+
### PermissionResolutionEntry
|
|
307
|
+
|
|
308
|
+
Audit record of a resolved tool-permission request: what was asked, which options were offered, what was decided, and which surface decided it. Does NOT participate in LLM context.
|
|
309
|
+
|
|
310
|
+
```json
|
|
311
|
+
{"type":"permission_resolution","id":"l2m3n4o5","parentId":"k1l2m3n4","timestamp":"2024-12-03T14:40:02.000Z","requestId":"perm_01HV","toolCallId":"call_456","toolName":"bash","cwd":"/path/to/project","detail":{"command":"rm -rf build"},"offeredOptionIds":["approve","approve-always","deny"],"decision":"approved","chosenOptionId":"approve","decidedBy":{"surface":"attach","clientId":"client-7"},"requestedAt":"2024-12-03T14:40:00.000Z","deadline":"2024-12-03T14:45:00.000Z"}
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
Fields:
|
|
315
|
+
- `requestId`: relay-scoped id of the permission request this resolves
|
|
316
|
+
- `cwd`: canonical (realpath) working directory the tool call was evaluated against
|
|
317
|
+
- `detail`: `{ command?, path?, operation? }` — the decisive part of the tool input
|
|
318
|
+
- `offeredOptionIds`: the immutable option set that was offered, in the order it was offered
|
|
319
|
+
- `decision`: `approved` | `denied` | `cancelled` | `expired`
|
|
320
|
+
- `chosenOptionId`: `null` when nothing was chosen (cancelled/expired)
|
|
321
|
+
- `decidedBy.surface`: `tui` | `attach` | `rpc` | `acp` | `system`; `clientId` is `null` for local/system decisions
|
|
322
|
+
- `deadline`: advisory expiry communicated with the ask, or `null`
|
|
323
|
+
|
|
324
|
+
This is a RECORD ONLY and must never be treated as answerable state: `createBranchedSession` copies path entries verbatim into a fork (so `requestId`/`toolCallId` can appear in more than one session), the entry becomes the leaf on reload (the next appended message parents off it), and the RPC `get_entries` command ships it verbatim to connected clients.
|
|
325
|
+
|
|
293
326
|
## Tree Structure
|
|
294
327
|
|
|
295
328
|
Entries form a tree:
|
|
@@ -311,8 +344,9 @@ Entries form a tree:
|
|
|
311
344
|
1. Collects all entries on the path
|
|
312
345
|
2. If a `CompactionEntry` is on the path:
|
|
313
346
|
- Includes the compaction entry first
|
|
314
|
-
-
|
|
315
|
-
-
|
|
347
|
+
- If `retainedTail` is present, it acts as a self-contained checkpoint and entries after the compaction are included
|
|
348
|
+
- Otherwise entries from `firstKeptEntryId` to the compaction are included
|
|
349
|
+
- Then entries after compaction are included
|
|
316
350
|
3. Preserves non-message entries in the selected range so interactive mode can render them
|
|
317
351
|
|
|
318
352
|
`buildSessionContext()` builds on that entry list to produce the message list for the LLM:
|
|
@@ -320,10 +354,13 @@ Entries form a tree:
|
|
|
320
354
|
1. Extracts current model and thinking level settings from the full path
|
|
321
355
|
2. Converts selected entries to messages:
|
|
322
356
|
- `message` -> stored `AgentMessage`
|
|
323
|
-
- `compaction` -> `compactionSummary`
|
|
357
|
+
- `compaction` -> `compactionSummary` plus `retainedTail` when present
|
|
324
358
|
- `branch_summary` -> `branchSummary`
|
|
325
359
|
- `custom_message` -> `CustomMessage`
|
|
326
360
|
- `custom` -> no context message
|
|
361
|
+
- `permission_resolution` -> no context message
|
|
362
|
+
|
|
363
|
+
This makes newer compactions act like self-contained checkpoints. `retainedTail` is optional only so older sessions that only store `firstKeptEntryId` continue to load correctly.
|
|
327
364
|
|
|
328
365
|
## Parsing Example
|
|
329
366
|
|
|
@@ -394,6 +431,7 @@ Key methods for working with sessions programmatically.
|
|
|
394
431
|
- `appendCompaction(summary, firstKeptEntryId, tokensBefore, details?, fromHook?)` - Add compaction
|
|
395
432
|
- `appendCustomEntry(customType, data?)` - Extension state (not in context)
|
|
396
433
|
- `appendSessionInfo(name)` - Set session display name
|
|
434
|
+
- `appendPermissionResolution(resolution)` - Record a resolved permission request (not in context)
|
|
397
435
|
- `appendCustomMessageEntry(customType, content, display, details?)` - Extension message (in context)
|
|
398
436
|
- `appendLabelChange(targetId, label)` - Set/clear label
|
|
399
437
|
|
package/docs/sessions.md
CHANGED
|
@@ -1,24 +1,27 @@
|
|
|
1
1
|
# Sessions
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
draht saves conversations as sessions so you can continue work, branch from earlier turns, and revisit previous paths.
|
|
4
4
|
|
|
5
5
|
## Session Storage
|
|
6
6
|
|
|
7
|
-
Sessions auto-save to `~/.
|
|
7
|
+
Sessions auto-save to `~/.draht/agent/sessions/`, organized by working directory. Each session is a JSONL file with a tree structure.
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
draht -c # Continue most recent session
|
|
11
|
+
draht -r # Browse and select from past sessions
|
|
12
|
+
draht --no-session # Ephemeral mode; do not save
|
|
13
|
+
draht --name "my task" # Set session display name at startup
|
|
14
|
+
draht --session <path|id> # Use a specific session file or partial session ID
|
|
15
|
+
draht --fork <path|id> # Fork a session file or partial session ID into a new session
|
|
16
16
|
```
|
|
17
17
|
|
|
18
18
|
Use `/session` in interactive mode to see the current session file, session ID, message count, tokens, and cost.
|
|
19
19
|
|
|
20
20
|
For the JSONL file format and SessionManager API, see [Session Format](session-format.md).
|
|
21
21
|
|
|
22
|
+
To expose a running session on a Unix socket and watch or drive it from another terminal, see
|
|
23
|
+
[Attachable Sessions](attachable-sessions.md) (`--attachable`, `--attach`, `--list-sessions`).
|
|
24
|
+
|
|
22
25
|
## Session Commands
|
|
23
26
|
|
|
24
27
|
| Command | Description |
|
|
@@ -36,7 +39,7 @@ For the JSONL file format and SessionManager API, see [Session Format](session-f
|
|
|
36
39
|
|
|
37
40
|
## Resuming and Deleting Sessions
|
|
38
41
|
|
|
39
|
-
`/resume` opens an interactive session picker for the current project. `
|
|
42
|
+
`/resume` opens an interactive session picker for the current project. `draht -r` opens the same picker at startup.
|
|
40
43
|
|
|
41
44
|
In the picker you can:
|
|
42
45
|
|
|
@@ -47,7 +50,7 @@ In the picker you can:
|
|
|
47
50
|
- rename with Ctrl+R
|
|
48
51
|
- delete with Ctrl+D, then confirm
|
|
49
52
|
|
|
50
|
-
When available,
|
|
53
|
+
When available, draht uses the `trash` CLI for deletion instead of permanently removing files.
|
|
51
54
|
|
|
52
55
|
## Naming Sessions
|
|
53
56
|
|
|
@@ -60,11 +63,11 @@ Use `/name <name>` to set a human-readable session name:
|
|
|
60
63
|
Set the name at startup with `--name` or `-n`:
|
|
61
64
|
|
|
62
65
|
```bash
|
|
63
|
-
|
|
64
|
-
|
|
66
|
+
draht --name "Refactor auth module"
|
|
67
|
+
draht --name "CI audit" -p "Review this build failure"
|
|
65
68
|
```
|
|
66
69
|
|
|
67
|
-
Named sessions are easier to find in `/resume` and `
|
|
70
|
+
Named sessions are easier to find in `/resume` and `draht -r`.
|
|
68
71
|
|
|
69
72
|
## Branching with `/tree`
|
|
70
73
|
|
|
@@ -128,7 +131,7 @@ Use `/tree` when you want to keep alternatives together. Use `/fork` or `/clone`
|
|
|
128
131
|
|
|
129
132
|
## Branch Summaries
|
|
130
133
|
|
|
131
|
-
When `/tree` switches away from one branch to another,
|
|
134
|
+
When `/tree` switches away from one branch to another, draht can summarize the abandoned branch and attach that summary at the new position. This preserves important context from the path you left without replaying the whole branch.
|
|
132
135
|
|
|
133
136
|
When prompted, choose one of:
|
|
134
137
|
|
package/docs/settings.md
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
# Settings
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
draht uses JSON settings files with project settings overriding global settings.
|
|
4
4
|
|
|
5
5
|
| Location | Scope |
|
|
6
6
|
|----------|-------|
|
|
7
|
-
| `~/.
|
|
8
|
-
| `.
|
|
7
|
+
| `~/.draht/agent/settings.json` | Global (all projects) |
|
|
8
|
+
| `.draht/settings.json` | Project (current directory) |
|
|
9
9
|
|
|
10
10
|
Edit directly or use `/settings` for common options.
|
|
11
11
|
|
|
12
12
|
## Project Trust
|
|
13
13
|
|
|
14
|
-
On interactive startup,
|
|
14
|
+
On interactive startup, draht asks before trusting a project folder that contains trust-gated project inputs and has no saved decision for the folder or a parent folder in `~/.draht/agent/trust.json`. Trusting a project allows draht to load `.draht/settings.json` and `.draht` resources, install missing project packages, and execute project extensions.
|
|
15
15
|
|
|
16
16
|
Non-interactive modes (`-p`, `--mode json`, and `--mode rpc`) do not show a trust prompt. Without an applicable saved trust decision, they use `defaultProjectTrust` from global settings: `ask` (default) and `never` ignore trust-gated project inputs, while `always` trusts them. Pass `--approve`/`-a` or `--no-approve`/`-na` to override project trust for one run.
|
|
17
17
|
|
|
18
|
-
If no extension or saved decision applies, `defaultProjectTrust` controls the fallback behavior. Set it to `"ask"`, `"always"`, or `"never"` in `~/.
|
|
18
|
+
If no extension or saved decision applies, `defaultProjectTrust` controls the fallback behavior. Set it to `"ask"`, `"always"`, or `"never"` in `~/.draht/agent/settings.json`, or change it with `/settings`.
|
|
19
19
|
|
|
20
|
-
`
|
|
20
|
+
`draht config` and package commands use the same project trust flow. Pass `--approve` to trust project-local settings for one command or `--no-approve` to ignore them.
|
|
21
21
|
|
|
22
|
-
Use `/trust` in interactive mode to save a project trust decision for future sessions, including trust for the immediate parent folder. It writes `~/.
|
|
22
|
+
Use `/trust` in interactive mode to save a project trust decision for future sessions, including trust for the immediate parent folder. It writes `~/.draht/agent/trust.json` only; the current session is not reloaded, so restart draht for changes to take effect.
|
|
23
23
|
|
|
24
24
|
## All Settings
|
|
25
25
|
|
|
@@ -66,7 +66,7 @@ Use `/trust` in interactive mode to save a project trust decision for future ses
|
|
|
66
66
|
| `autocompleteMaxVisible` | number | `5` | Max visible items in autocomplete dropdown (3-20) |
|
|
67
67
|
| `showHardwareCursor` | boolean | `false` | Show the terminal cursor while TUI positions it for IME support |
|
|
68
68
|
|
|
69
|
-
For VS Code, include `--wait` so
|
|
69
|
+
For VS Code, include `--wait` so draht resumes after the editor exits:
|
|
70
70
|
|
|
71
71
|
```json
|
|
72
72
|
{
|
|
@@ -76,9 +76,9 @@ For VS Code, include `--wait` so pi resumes after the editor exits:
|
|
|
76
76
|
|
|
77
77
|
### Telemetry and update checks
|
|
78
78
|
|
|
79
|
-
`enableInstallTelemetry` only controls the anonymous install/update ping to `https://pi.dev/api/report-install`. Opting out of telemetry does not disable update checks;
|
|
79
|
+
`enableInstallTelemetry` only controls the anonymous install/update ping to `https://pi.dev/api/report-install`. Opting out of telemetry does not disable update checks; draht can still fetch `https://pi.dev/api/latest-version` to look for the latest version.
|
|
80
80
|
|
|
81
|
-
Set `
|
|
81
|
+
Set `DRAHT_SKIP_VERSION_CHECK=1` to disable the draht version update check. Use `--offline` or `DRAHT_OFFLINE=1` to disable all startup network operations described here, including update checks, package update checks, and install/update telemetry.
|
|
82
82
|
|
|
83
83
|
### Warnings
|
|
84
84
|
|
|
@@ -119,6 +119,13 @@ Set `PI_SKIP_VERSION_CHECK=1` to disable the Pi version update check. Use `--off
|
|
|
119
119
|
| `branchSummary.reserveTokens` | number | `16384` | Tokens reserved for branch summarization |
|
|
120
120
|
| `branchSummary.skipPrompt` | boolean | `false` | Skip "Summarize branch?" prompt on `/tree` navigation (defaults to no summary) |
|
|
121
121
|
|
|
122
|
+
### Checkpoints
|
|
123
|
+
|
|
124
|
+
| Setting | Type | Default | Description |
|
|
125
|
+
|---------|------|---------|-------------|
|
|
126
|
+
| `checkpoints.retentionDays` | number | `30` | Delete checkpoint snapshots older than this on `draht checkpoint prune` |
|
|
127
|
+
| `checkpoints.maxPerSession` | number | unlimited | Keep at most this many newest snapshots per session |
|
|
128
|
+
|
|
122
129
|
### Retry
|
|
123
130
|
|
|
124
131
|
| Setting | Type | Default | Description |
|
|
@@ -130,9 +137,9 @@ Set `PI_SKIP_VERSION_CHECK=1` to disable the Pi version update check. Use `--off
|
|
|
130
137
|
| `retry.provider.maxRetries` | number | `0` | Provider/SDK retry attempts |
|
|
131
138
|
| `retry.provider.maxRetryDelayMs` | number | `60000` | Max server-requested delay before failing (60s) |
|
|
132
139
|
|
|
133
|
-
When a provider requests a retry delay longer than `retry.provider.maxRetryDelayMs
|
|
140
|
+
When a provider requests a retry delay longer than `retry.provider.maxRetryDelayMs`, the request fails immediately with an informative error instead of waiting silently. Set it to `0` to disable the limit.
|
|
134
141
|
|
|
135
|
-
Keep `retry.provider.maxRetries` at `0` unless provider-level retries are explicitly needed. Setting it above `0` can make SDK/provider retries handle out-of-usage-limit errors before
|
|
142
|
+
Keep `retry.provider.maxRetries` at `0` unless provider-level retries are explicitly needed. Setting it above `0` can make SDK/provider retries handle out-of-usage-limit errors before draht sees them, which may block the agent until the provider quota resets in some circumstances.
|
|
136
143
|
|
|
137
144
|
```json
|
|
138
145
|
{
|
|
@@ -183,7 +190,7 @@ Keep `retry.provider.maxRetries` at `0` unless provider-level retries are explic
|
|
|
183
190
|
}
|
|
184
191
|
```
|
|
185
192
|
|
|
186
|
-
`npmCommand` is used for all npm package-manager operations, including installs, uninstalls, and dependency installs inside git packages. User-scoped npm packages install under `~/.
|
|
193
|
+
`npmCommand` is used for all npm package-manager operations, including installs, uninstalls, and dependency installs inside git packages. User-scoped npm packages install under `~/.draht/agent/npm/`; project-scoped npm packages install under `.draht/npm/`. Use argv-style entries exactly as the process should be launched. When `npmCommand` is configured, git package dependency installs use plain `install` to avoid npm-specific flags in wrappers or alternate package managers.
|
|
187
194
|
|
|
188
195
|
### Sessions
|
|
189
196
|
|
|
@@ -192,10 +199,10 @@ Keep `retry.provider.maxRetries` at `0` unless provider-level retries are explic
|
|
|
192
199
|
| `sessionDir` | string | - | Directory where session files are stored. Accepts absolute or relative paths, plus `~`. |
|
|
193
200
|
|
|
194
201
|
```json
|
|
195
|
-
{ "sessionDir": ".
|
|
202
|
+
{ "sessionDir": ".draht/sessions" }
|
|
196
203
|
```
|
|
197
204
|
|
|
198
|
-
When multiple sources specify a session directory, precedence is `--session-dir`, `
|
|
205
|
+
When multiple sources specify a session directory, precedence is `--session-dir`, `DRAHT_CODING_AGENT_SESSION_DIR`, then `sessionDir` in settings.json.
|
|
199
206
|
|
|
200
207
|
### Model Cycling
|
|
201
208
|
|
|
@@ -219,7 +226,7 @@ When multiple sources specify a session directory, precedence is `--session-dir`
|
|
|
219
226
|
|
|
220
227
|
These settings define where to load extensions, skills, prompts, and themes from.
|
|
221
228
|
|
|
222
|
-
Paths in `~/.
|
|
229
|
+
Paths in `~/.draht/agent/settings.json` resolve relative to `~/.draht/agent`. Paths in `.draht/settings.json` resolve relative to `.draht`. Absolute paths and `~` are supported.
|
|
223
230
|
|
|
224
231
|
| Setting | Type | Default | Description |
|
|
225
232
|
|---------|------|---------|-------------|
|
|
@@ -285,16 +292,16 @@ See [packages.md](packages.md) for package management details.
|
|
|
285
292
|
|
|
286
293
|
## Project Overrides
|
|
287
294
|
|
|
288
|
-
Project settings (`.
|
|
295
|
+
Project settings (`.draht/settings.json`) override global settings. Nested objects are merged:
|
|
289
296
|
|
|
290
297
|
```json
|
|
291
|
-
// ~/.
|
|
298
|
+
// ~/.draht/agent/settings.json (global)
|
|
292
299
|
{
|
|
293
300
|
"theme": "dark",
|
|
294
301
|
"compaction": { "enabled": true, "reserveTokens": 16384 }
|
|
295
302
|
}
|
|
296
303
|
|
|
297
|
-
// .
|
|
304
|
+
// .draht/settings.json (project)
|
|
298
305
|
{
|
|
299
306
|
"compaction": { "reserveTokens": 8192 }
|
|
300
307
|
}
|
package/docs/shell-aliases.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Shell Aliases
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
draht runs bash in non-interactive mode (`bash -c`), which doesn't expand aliases by default.
|
|
4
4
|
|
|
5
|
-
To enable your shell aliases, add to `~/.
|
|
5
|
+
To enable your shell aliases, add to `~/.draht/agent/settings.json`:
|
|
6
6
|
|
|
7
7
|
```json
|
|
8
8
|
{
|
package/docs/skills.md
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
>
|
|
1
|
+
> draht can create skills. Ask it to build one for your use case.
|
|
2
2
|
|
|
3
3
|
# Skills
|
|
4
4
|
|
|
5
5
|
Skills are self-contained capability packages that the agent loads on-demand. A skill provides specialized workflows, setup instructions, helper scripts, and reference documentation for specific tasks.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
draht implements the [Agent Skills standard](https://agentskills.io/specification), warning about most violations but remaining lenient. draht allows skill names to differ from their parent directory even though the standard disallows it; that rule is suboptimal for shared skill directories used across multiple agent harnesses.
|
|
8
8
|
|
|
9
9
|
## Table of Contents
|
|
10
10
|
|
|
@@ -21,20 +21,21 @@ Pi implements the [Agent Skills standard](https://agentskills.io/specification),
|
|
|
21
21
|
|
|
22
22
|
> **Security:** Skills can instruct the model to perform any action and may include executable code the model invokes. Review skill content before use.
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
draht loads skills from:
|
|
25
25
|
|
|
26
|
+
- Shipped: a `skills/` directory bundled with the package (builtin skills such as `hexagon-animation`). Disabled by `--no-skills`; a user or project skill with the same name overrides a shipped skill.
|
|
26
27
|
- Global:
|
|
27
|
-
- `~/.
|
|
28
|
+
- `~/.draht/agent/skills/`
|
|
28
29
|
- `~/.agents/skills/`
|
|
29
30
|
- Project (only after the project is trusted):
|
|
30
|
-
- `.
|
|
31
|
+
- `.draht/skills/`
|
|
31
32
|
- `.agents/skills/` in `cwd` and ancestor directories (up to git repo root, or filesystem root when not in a repo)
|
|
32
33
|
- Packages: `skills/` directories or `pi.skills` entries in `package.json`
|
|
33
34
|
- Settings: `skills` array with files or directories
|
|
34
35
|
- CLI: `--skill <path>` (repeatable, additive even with `--no-skills`)
|
|
35
36
|
|
|
36
37
|
Discovery rules:
|
|
37
|
-
- In `~/.
|
|
38
|
+
- In `~/.draht/agent/skills/` and `.draht/skills/`, direct root `.md` files are discovered as individual skills
|
|
38
39
|
- In all skill locations, directories containing `SKILL.md` are discovered recursively
|
|
39
40
|
- In `~/.agents/skills/` and project `.agents/skills/`, root `.md` files are ignored
|
|
40
41
|
|
|
@@ -53,7 +54,7 @@ To use skills from Claude Code or OpenAI Codex, add their directories to setting
|
|
|
53
54
|
}
|
|
54
55
|
```
|
|
55
56
|
|
|
56
|
-
For project-level Claude Code skills, add to `.
|
|
57
|
+
For project-level Claude Code skills, add to `.draht/settings.json`:
|
|
57
58
|
|
|
58
59
|
```json
|
|
59
60
|
{
|
|
@@ -63,7 +64,7 @@ For project-level Claude Code skills, add to `.pi/settings.json`:
|
|
|
63
64
|
|
|
64
65
|
## How Skills Work
|
|
65
66
|
|
|
66
|
-
1. At startup,
|
|
67
|
+
1. At startup, draht scans skill locations and extracts names and descriptions
|
|
67
68
|
2. The system prompt includes available skills in XML format per the [specification](https://agentskills.io/integrate-skills)
|
|
68
69
|
3. When a task matches, the agent uses `read` to load the full SKILL.md (models don't always do this; use prompting or `/skill:name` to force it)
|
|
69
70
|
4. The agent follows the instructions, using relative paths to reference scripts and assets
|
|
@@ -140,7 +141,7 @@ Per the [Agent Skills specification](https://agentskills.io/specification#frontm
|
|
|
140
141
|
|
|
141
142
|
| Field | Required | Description |
|
|
142
143
|
|-------|----------|-------------|
|
|
143
|
-
| `name` | Yes | Max 64 chars. Lowercase a-z, 0-9, hyphens. Unlike the standard,
|
|
144
|
+
| `name` | Yes | Max 64 chars. Lowercase a-z, 0-9, hyphens. Unlike the standard, draht does not require this to match the parent directory because that standard requirement is suboptimal for shared skill directories. |
|
|
144
145
|
| `description` | Yes | Max 1024 chars. What the skill does and when to use it. |
|
|
145
146
|
| `license` | No | License name or reference to bundled file. |
|
|
146
147
|
| `compatibility` | No | Max 500 chars. Environment requirements. |
|
|
@@ -154,7 +155,7 @@ Per the [Agent Skills specification](https://agentskills.io/specification#frontm
|
|
|
154
155
|
- Lowercase letters, numbers, hyphens only
|
|
155
156
|
- No leading/trailing hyphens
|
|
156
157
|
- No consecutive hyphens
|
|
157
|
-
|
|
158
|
+
draht does not require the name to match the parent directory. The Agent Skills standard does, but that requirement is suboptimal for shared skill directories used by multiple tools.
|
|
158
159
|
|
|
159
160
|
Valid: `pdf-processing`, `data-analysis`, `code-review`
|
|
160
161
|
Invalid: `PDF-Processing`, `-pdf`, `pdf--processing`
|
|
@@ -175,7 +176,7 @@ description: Helps with PDFs.
|
|
|
175
176
|
|
|
176
177
|
## Validation
|
|
177
178
|
|
|
178
|
-
|
|
179
|
+
draht validates skills against the Agent Skills standard. Most issues produce warnings but still load the skill:
|
|
179
180
|
|
|
180
181
|
- Name exceeds 64 characters or contains invalid characters
|
|
181
182
|
- Name starts/ends with hyphen or has consecutive hyphens
|
package/docs/terminal-setup.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Terminal Setup
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
draht 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
4
|
|
|
5
5
|
## Kitty, iTerm2
|
|
6
6
|
|
|
@@ -8,9 +8,9 @@ Work out of the box.
|
|
|
8
8
|
|
|
9
9
|
## Apple Terminal
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
draht enables enhanced key reporting when available. If Terminal.app still sends plain Return for `Shift+Enter`, draht uses a local macOS modifier fallback to treat that Return as `Shift+Enter`.
|
|
12
12
|
|
|
13
|
-
This fallback only works when
|
|
13
|
+
This fallback only works when draht runs on the same Mac as Terminal.app. It cannot detect the local keyboard over remote SSH.
|
|
14
14
|
|
|
15
15
|
## Ghostty
|
|
16
16
|
|
|
@@ -26,11 +26,11 @@ Older Claude Code versions may have added this Ghostty mapping:
|
|
|
26
26
|
keybind = shift+enter=text:\n
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
That mapping sends a raw linefeed byte. Inside
|
|
29
|
+
That mapping sends a raw linefeed byte. Inside draht, that is indistinguishable from `Ctrl+J`, so tmux and draht no longer see a real `shift+enter` key event.
|
|
30
30
|
|
|
31
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
32
|
|
|
33
|
-
If you want `Shift+Enter` to keep working in tmux via that remap, add `ctrl+j` to your
|
|
33
|
+
If you want `Shift+Enter` to keep working in tmux via that remap, add `ctrl+j` to your draht `newLine` keybinding in `~/.draht/agent/keybindings.json`:
|
|
34
34
|
|
|
35
35
|
```json
|
|
36
36
|
{
|
|
@@ -49,7 +49,7 @@ config.enable_kitty_keyboard = true
|
|
|
49
49
|
return config
|
|
50
50
|
```
|
|
51
51
|
|
|
52
|
-
On macOS, WezTerm binds `Option+Enter` to fullscreen by default. To use `Option+Enter` for
|
|
52
|
+
On macOS, WezTerm binds `Option+Enter` to fullscreen by default. To use `Option+Enter` for draht follow-up queueing, add this key override:
|
|
53
53
|
|
|
54
54
|
```lua
|
|
55
55
|
local wezterm = require 'wezterm'
|
|
@@ -66,11 +66,11 @@ return config
|
|
|
66
66
|
|
|
67
67
|
If you already have a `config.keys` table, add the entry to it.
|
|
68
68
|
|
|
69
|
-
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 `
|
|
69
|
+
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 `DRAHT_HARDWARE_CURSOR=1` before running draht or set `showHardwareCursor` to `true` in settings.
|
|
70
70
|
|
|
71
71
|
## Alacritty
|
|
72
72
|
|
|
73
|
-
Alacritty usually works out of the box for `Shift+Enter`. On macOS, `Option+Enter` may arrive as plain `Enter`. To use `Option+Enter` for
|
|
73
|
+
Alacritty usually works out of the box for `Shift+Enter`. On macOS, `Option+Enter` may arrive as plain `Enter`. To use `Option+Enter` for draht follow-up queueing, add to `~/.config/alacritty/alacritty.toml`:
|
|
74
74
|
|
|
75
75
|
```toml
|
|
76
76
|
[[keyboard.bindings]]
|
|
@@ -105,7 +105,7 @@ Add to `keybindings.json`:
|
|
|
105
105
|
|
|
106
106
|
## Windows Terminal
|
|
107
107
|
|
|
108
|
-
Add to `settings.json` (Ctrl+Shift+, or Settings → Open JSON file) to forward the modified Enter keys
|
|
108
|
+
Add to `settings.json` (Ctrl+Shift+, or Settings → Open JSON file) to forward the modified Enter keys draht uses:
|
|
109
109
|
|
|
110
110
|
```json
|
|
111
111
|
{
|
|
@@ -123,8 +123,8 @@ Add to `settings.json` (Ctrl+Shift+, or Settings → Open JSON file) to forward
|
|
|
123
123
|
```
|
|
124
124
|
|
|
125
125
|
- `Shift+Enter` inserts a new line.
|
|
126
|
-
- Windows Terminal binds `Alt+Enter` to fullscreen by default. That prevents
|
|
127
|
-
- Remapping `Alt+Enter` to `sendInput` forwards the real key chord to
|
|
126
|
+
- Windows Terminal binds `Alt+Enter` to fullscreen by default. That prevents draht from receiving `Alt+Enter` for follow-up queueing.
|
|
127
|
+
- Remapping `Alt+Enter` to `sendInput` forwards the real key chord to draht instead.
|
|
128
128
|
|
|
129
129
|
If you already have an `actions` array, add the objects to it. If the old fullscreen behavior persists, fully close and reopen Windows Terminal.
|
|
130
130
|
|
|
@@ -143,6 +143,6 @@ For the best experience, use a terminal that supports the Kitty keyboard protoco
|
|
|
143
143
|
|
|
144
144
|
The built-in terminal has limited escape sequence support. Shift+Enter cannot be distinguished from Enter in IntelliJ's terminal.
|
|
145
145
|
|
|
146
|
-
If you want the hardware cursor visible, set `
|
|
146
|
+
If you want the hardware cursor visible, set `DRAHT_HARDWARE_CURSOR=1` before running draht (disabled by default for compatibility).
|
|
147
147
|
|
|
148
148
|
Consider using a dedicated terminal emulator for the best experience.
|
package/docs/termux.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Termux (Android) Setup
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
draht runs on Android via [Termux](https://termux.dev/), a terminal emulator and Linux environment for Android.
|
|
4
4
|
|
|
5
5
|
## Prerequisites
|
|
6
6
|
|
|
@@ -16,14 +16,14 @@ pkg update && pkg upgrade
|
|
|
16
16
|
# Install dependencies
|
|
17
17
|
pkg install nodejs termux-api git
|
|
18
18
|
|
|
19
|
-
# Install
|
|
19
|
+
# Install draht
|
|
20
20
|
npm install -g --ignore-scripts @draht/coding-agent
|
|
21
21
|
|
|
22
22
|
# Create config directory
|
|
23
|
-
mkdir -p ~/.
|
|
23
|
+
mkdir -p ~/.draht/agent
|
|
24
24
|
|
|
25
|
-
# Run
|
|
26
|
-
|
|
25
|
+
# Run draht
|
|
26
|
+
draht
|
|
27
27
|
```
|
|
28
28
|
|
|
29
29
|
## Clipboard Support
|
|
@@ -34,7 +34,7 @@ Image clipboard is not supported on Termux (the `ctrl+v` image paste feature wil
|
|
|
34
34
|
|
|
35
35
|
## Example AGENTS.md for Termux
|
|
36
36
|
|
|
37
|
-
Create `~/.
|
|
37
|
+
Create `~/.draht/agent/AGENTS.md` to help the agent understand the Termux environment:
|
|
38
38
|
|
|
39
39
|
````markdown
|
|
40
40
|
# Agent Environment: Termux on Android
|