跳过主要内容
N

dsh-translator

nicearrack/dsh-translator

Youdao-style word-selection translation for the DSH web GUI. Select text anywhere, click the floating button, get a translation from the harness's own LLM — no API keys, no third-party endpoints. 有道风格划词翻译:DSH Web GUI 里划选文本即现悬浮「译」按钮,点击由 harness 自带大模型翻译,无需

安装

dsh plugin --profile web add github:nicearrack/dsh-translator

README

dsh-translator

Youdao-style word-selection translation for DeepSeek Harness (DSH).

Select any text — a conversation message, the sidebar, an input field — and a floating 「译」 button appears at the selection's top-right corner. Click it to get a translation card. Translations are produced by the harness's own LLM: no API keys, no third-party endpoints, your selected text never leaves the model pipeline you already configured.

English中文 README

Usage

Select text → click the 「译」 button at the selection's top-right corner → the translation card appears. That's it.

Features

  • Word-selection trigger anywhere in the app; floating button follows the selection, theme-aware (light/dark)
  • Automatic direction detection (Chinese → English, everything else → Simplified Chinese)
  • Translation card with source, direction badge, result, and retry on failure; dismiss with Esc / click-outside / scroll
  • Uses your configured default model — zero extra configuration

Install

From npm:

dsh plugin --profile web add @nicearrack/dsh-translator@latest

From a local checkout:

dsh plugin --profile web add /path/to/dsh-translator

From git:

dsh plugin --profile web add github:nicearrack/dsh-translator

Git installs run the package's prepare build script. pnpm ≥ 10 requires one-time authorization: add allowBuilds: { "@nicearrack/dsh-translator": true } to the profile's pnpm-workspace.yaml if the first install is refused.

Uninstall

dsh plugin --profile web remove @nicearrack/dsh-translator

Restart the instance (dsh --profile web) for the removal to take effect.

License

MIT

相关插件