Composer input toolkit: arrow-key session history (first/last-line gated, IME and command-menu safe), an instructions viewer/editor for global and project AGENTS.md/CLAUDE.md, and a prompt library of 780 Chinese prompts (Cherry Studio agents-zh corpus, AGPL-3.0) inserted into the composer in one click. Ships on npm as `dsh-composer-tools`.
Install
# from npm (prebuilt)
dsh plugin --profile web add dsh-composer-tools
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:wsxwj123/dsh-plugins#path:/packages/dsh-composer-tools
Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).
README
This plugin publishes its README in Chinese only.
DSH web 输入体验增强插件:方向键输入历史 + 指令查看/编辑面板 + 提示词库。
给 DSH(DeepSeek Harness)的输入框加三个实用功能,全部本地运行、不联网、不需要密钥。
功能
1. 方向键输入历史
在输入框按 ↑ / ↓ 翻看本会话发过的输入,像 shell 历史一样:
- ↑ 翻更旧的输入,↓ 翻回更新的(到底恢复你正在编辑的草稿)
- 单行输入:直接触发(无论光标在哪)
- 多行输入:光标在第一行按 ↑ 才翻历史、光标在最后一行按 ↓ 才翻——光标在中间行时按键正常移动光标,不会误翻
- ← → 永不触发;中文输入法选字时不误触;命令菜单打开时方向键归菜单
- 历史按会话隔离、刷新后仍在(localStorage),每会话最多 100 条
2. 指令查看 / 编辑面板
输入框工具区的 🧩 按钮打开面板,查看当前会话实际生效的指令:
- 全局:
~/.dsh/AGENTS.md - 项目:项目根(
.git标记)到当前目录每层的AGENTS.md/CLAUDE.md/AGENTS.local.md/CLAUDE.local.md - 跨文件全文搜索(文件+行号+片段,点击跳转)
- 编辑保存:全局和项目级指令文件都可改(保存前有确认,mtime 冲突会提示重载/覆盖,超 1MB 的文件提示用外部编辑器防静默丢尾)
3. 提示词库(同一面板的第二个 tab)
内置 780 条中文提示词(源自 Cherry Studio agents-zh.json,AGPL-3.0 许可,面板内常驻标注来源):
- 按分类折叠浏览 + 搜索(标题/描述/正文)
- 发送到输入框:点一下追加到输入框末尾(已有内容自动空一行,不覆盖不自动发送)
- 复制到剪贴板
安装
从 dsh-market / GitHub 安装
包内已声明 prepare 构建脚本;pnpm 从 Git 安装时会自动执行 node build.mjs 生成 lib/。pnpm 10+ 默认拦截依赖的构建脚本,按 dsh-market 的提示把 pnpm 打印的 key 加入 profile 的 pnpm-workspace.yaml 的 allowBuilds 后重试即可。
# dsh-market 目标与此等价:
dsh plugin --profile web add "github:wsxwj123/dsh-plugins#path:/packages/dsh-composer-tools"
从本地源码 link 安装
lib/ 不入库,本地 link: 安装不会触发依赖构建,需要先构建:
# 1. 构建
cd packages/dsh-composer-tools
pnpm install
pnpm build
# 2. 装进你的 profile
cd ~/.dsh/profiles/web
pnpm add "link:/绝对路径/packages/dsh-composer-tools"
# 3. 装完检查 @deepseek-ai 物理复制坑(见下方"已知问题"),然后重启 dsh web
或直接 dsh plugin --profile web add "link:$PWD/packages/dsh-composer-tools"。
兼容版本:@deepseek-ai/dsh@0.1.0-rc.6。
工作原理(给维护者)
- host 半(node):挂
/ct前缀 RPC(loopback 信任围栏 + POST-only)——指令发现(.git找项目根 + 祖先链,lstat拒符号链接)、读写(basename 白名单 × 精确发现成员资格双闸门防逃逸 + mtime 乐观锁 + 截断保护)、提示词库按需下发 - client 半(React):注册
conversation.input.rightslot 注入入口按钮;方向键用 document capture keydown 拦截(先于 React),官方inputActions.setDraft回填;发送采集走 phase 状态机(发送失败自动剔除误录)
边界与已知限制
- 输入历史按会话隔离、明文存 localStorage(README 提示)
- 指令面板只读列出 + 编辑已发现的文件,不创建新文件
- 提示词库数据为 AGPL-3.0(Cherry Studio),随 MIT 插件分发,来源与许可证已在面板和本文件标注
- 真实浏览器交互(方向键门槛、IME、菜单让路)由 playwright e2e 在独立 profile 自动化验证
测试
pnpm test:acceptance # 131 条契约验收(真实实现)
node --test tests/unit/*.test.mjs # 112 条白盒单测
npx playwright test tests/e2e/ # 7 条真实 dsh web e2e(需先起 composer-e2e profile)
已知问题(本机 dsh 环境)
装插件后若所有工具调用报 Cannot read properties of undefined (reading 'prepare')——是 pnpm install 把 @deepseek-ai/* 物理复制成第二份导致 Symbol 分裂。检查 ~/.dsh/profiles/<name>/node_modules/@deepseek-ai/,若是真目录则 mv 掉它(回退共享 symlink),重启 dsh。详见 deepseek-harness discussion #783。
License
MIT(插件代码)。提示词数据源自 Cherry Studio(AGPL-3.0)。
Links
More in this category
zhu1090093659/dsh-web#packages/dsh-task-board★ 8121
Task board for the dsh web GUI: a sidebar multi-column kanban whose cards run in real DSH agent sessions and can also be scheduled with cron expressions, executed host-side even with the browser closed.
zhu1090093659/dsh-web#packages/dsh-web-all★ 8121
Plugin and skin collection for the DSH Web UI: task board, Git graph, right-side panel, remote mobile UI, pet, live token stats, and a skin center.
omdsh-dev/DSH-better-sidebar★ 3868
Full sidebar workbench with file rendering and editing, terminal, Git, and subagents; third-party plugins can register new tabs.
ccch1mneyyy/dsh-TUI★ 3734
Claude Code-style full-screen terminal UI: pixel-whale header, live status line, and streaming thought expansion.
MeteorNOX/DeepSeek-Balance-Whale-Widget★ 3369
A fixed-corner whale widget for the DSH web GUI — balance, today's usage and per-turn cost with peak/off-peak pricing, editable balance-alert and daily-budget bubbles, a module-based custom bubble queue with A/B weighted choices and random lines or images, 30+ vendor templates (OpenAI, OpenRouter, Kimi, SiliconFlow, Ark, Zhipu, MiniMax and more) with per-model balance and subscription quota, plus task-end sound, imported audio, custom roles and a resource manager. Local-only, no telemetry.
Devin-AXIS/deepseek-design#deepseek-idesign★ 1665
Visual design studio for websites, app prototypes, posters, cards, reports, and magazines, with templates, direct element editing, selection-aware AI draft handoff, and export.
Community comments
Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.