Alex-yuanli/babeldoc-on-dsh ↗★ 0
babeldoc-on-dsh
BabelDoc-on-dsh: a DeepSeek Harness plugin bundle that translates PDFs through BabelDOC while keeping their original layout. 适合需要保留原始排版格式来翻译 PDF 文档的用户。
설치
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Alex-yuanli/babeldoc-on-dsh配置API key
第一次使用时直接在输入框里执行:
/babeldoc key sk-xxxxxxxxxxxxxxxx
- 密钥写入
%USERPROFILE%\.dsh\babeldoc\settings.json,不进入会话记录(该命令声明了recordInput: false)。 - 命令回显只显示
sk-x...xxxx这样的掩码。 - 发布插件时包里不含任何api key,每个使用者填自己的。
其它子命令:
| 命令 | 作用 |
|---|---|
/babeldoc 或 /babeldoc status | 查看运行时、接口地址、模型、密钥是否已配置 |
/babeldoc key | 保存 API Key |
/babeldoc model | 切换模型,如 deepseek-chat、deepseek-reasoner |
/babeldoc base | 切换 OpenAI 兼容接口地址 |
/babeldoc clear | 清除已保存的 Key |
也可以不用命令,把值写进 profile 的 cordis.patch.yml(适合统一部署):
- id: babeldoc-on-dsh
name: babeldoc-on-dsh
config:
babeldocPath: 'C:\Users\name\.dsh\babeldoc\venv\Scripts\babeldoc.exe'
baseUrl: 'https://api.deepseek.com/v1'
model: 'deepseek-chat'
apiKey: ''
langIn: 'en'
langOut: 'zh'
outputDir: ''
qps: 4
hfEndpoint: 'https://hf-mirror.com'
extraArgs: []
读取顺序:/babeldoc 存的设置 → 插件配置 → 环境变量 BABELDOC_API_KEY / DEEPSEEK_API_KEY / OPENAI_API_KEY。