dsh-rtk
RTK (Rust Token Killer) native plugin for DSH: auto-rewrites model shell commands to RTK-filtered equivalents through the official tools/execute hook, compressing tool output before it reaches the LLM context.
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:dd2673/dsh-rtk说明文档
阅读完整 README ↗使用发布后的不可变 commit;首次安装会提示 pnpm 允许执行 prepare。
dsh plugin --profile demo add github:dd2673/dsh-rtk#
配置
| 键 | 类型 | 默认 | 说明 |
|---|---|---|---|
enabled | boolean | true | 插件总开关 |
announceToAgent | boolean | true | 是否向 Agent 宣告插件 |
rtkBin | string | rtk | RTK 二进制路径(可用绝对路径) |
askMode | 'rewrite' | 'passthrough' | rewrite | rtk rewrite 退出码 3(ask)时的处理 |
excludeCommands | string[] | [] | 前缀匹配、永不重写的命令 |
interceptedTools | string[] | ['pwsh'] | 被拦截改写的工具名 |
defaultTimeoutMs | number | 120000 | 模型未指定 timeoutMs 时的超时 |