KeinsteinNUS/dsh-speech-polish ↗★ 0
dsh-speech-polish
Terminology-aware correction layer for DeepSeek Harness's built-in local speech-to-text: fixes homophone and near-homophone mistakes before the transcript reaches the composer.
Install
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add https://github.com/KeinsteinNUS/dsh-speech-polish/releases/download/v0.1.0/dsh-speech-polish-0.1.0.tgzREADME
Read the full README ↗配置
写在 bundle patch 的 speech-polish 行的 config 里:
| 键 | 默认 | 说明 |
|---|---|---|
baseProviderId | sensevoice-local | 底层识别器 id |
providerId | sensevoice-polish | 本插件注册的 id |
label | SenseVoice + glossary fix | 设置里显示的名字 |
model | deepseek-chat | 纠错模型 |
baseURL | https://api.deepseek.com | OpenAI 兼容端点(可换任何厂商/自建网关) |
apiKey | 空 | 显式密钥,优先于环境变量与凭据库 |
timeoutMs | 8000 | 单次纠错超时 |
minChars | 4 | 短于此长度的文本不纠错(“嗯”“好的”) |
maxGrowthRatio | 0.6 | 输出相对原文允许的最大膨胀,超出即丢弃该次纠错 |
glossary | 内置通用技术词表 | 你的领域术语,数组;替换内置表 |
instruction | 空 | 追加给模型的额外要求(口吻、单位习惯等) |
enabled | true | 关掉后只做透传 |
traceFile | 关闭 | 打开后把每步写入 JSONL,便于排查 |
领域术语表
内置表只有通用技术词。材料的、医疗的、法务的术语请自己加:
- id: speech-polish
config:
glossary: [液晶盒, 取向层, 旋涂, 退火, 相位延迟, 氧化铟锡, 偏振响应, 双折射]
术语表只用于“同音错写时该改成什么”,不会让模型无中生有——输出长度偏离原文 40%~160% 之外会被判定不可信并丢弃。