Voice Polish: Refining Voice Input Drafts into Coherent Text

Introduction

When using DeepSeek Harness (DSH), the dictation drafts recognized by voice input are often riddled with repetitions, colloquial expressions, and missing punctuation. Manually rewriting them is both time-consuming and prone to interrupting your train of thought. This plugin leverages a large language model to polish such drafts into logically coherent written text, and supports one-click enhancement into clearer prompts.

Plugin Overview

  • Name: liuyong0426/dsh-voice-polish
  • Maintainer: liuyong0426
  • Category: Workflow
  • Purpose: Adds “Polish” and “Enhance” functions to the DSH chat input box, enabling automatic or manual rewriting of voice-input drafts, with an optional step to expand the content into a structured prompt.

Core Features

Polish

  • Remove filler words and repeated phrases
  • Add missing punctuation
  • Correct typos
  • Restore misheard proper nouns (e.g., deep seek harness → DeepSeek Harness)
  • Preserve the original meaning

Enhance

  • When enabled, “Polish” simultaneously expands the text into a clearer prompt
  • Retains all original requirements
  • Clarifies vague expressions
  • Organizes content by key points

Auto-Polish

  • Auto-polish is enabled by default
  • After a long passage of dictated text is inserted at once, the plugin will automatically polish it after a brief pause
  • You can manually click “Polish” at any time to trigger it
  • Auto-polish only targets insertions that “look like dictation”: pasted URLs, file paths, and code snippets will not be rewritten (manually clicking “Polish” still works)

Settings

Configurable under DSH’s “Settings → Voice Polish”:

  • Model Provider / Model: Leave blank to follow the current default model
  • Auto-polish voice drafts: Enabled by default
  • Default “Enhance” on: Determines the initial state of the input box toggle
  • Minimum character count for auto-polish: Default is 12; insertions shorter than this will not be auto-polished
  • Extra polishing instructions: e.g., “Keep all English terms,” “Do not modify code snippets”

Settings are saved in $DSH_HOME/voice-polish/settings.json and will not modify the current profile’s cordis.patch.yml.

Output Drift Prevention

Polish mode uses three safeguards to prevent the model’s output from going off-track:

  1. The system prompt explicitly states that “the polisher is not an assistant,” emphasizing that the user’s dictated text is material to be polished, not an instruction to the model—even if the content resembles a question or a task assignment, it should not be executed.
  2. Post-response drift check: the output is flagged as drifted if it contains Markdown headings/tables/lists/numbered items, follow-up questions, task breakdowns, or if the length exceeds the original by more than 50%.
  3. If drift is detected, the request is retried once with stronger prohibition clauses; if it still drifts, it falls back to local polishing (bypassing the model) that only removes extra filler words and repetitions and adds punctuation, without altering single-character interjections (otherwise “干嘛” would be trimmed to “干”).

“Enhance” mode is not subject to this restriction, as it inherently requires restructuring the text.

Typical Usage

  1. In the DSH chat input box, insert a dictated passage via voice input.
  2. After a brief pause, the plugin automatically polishes the passage into written text.
  3. If you need a clearer prompt, click the “Enhance” toggle on the right side of the input box, then click “Polish” again to expand it into a structured prompt.
  4. To adjust the model or behavior, go to “Settings → Voice Polish” and modify the relevant options.

Use Cases & Notes

  • Ideal for developers who frequently use voice input and want to quickly convert dictated drafts into usable prompts or written text.
  • The plugin runs with the current DSH process privileges; review the source code and license before installing.

Summary

Voice Polish adds “Polish” and “Enhance” capabilities to the chat input box. By automatically or manually rewriting voice drafts, it transforms colloquial content into logically coherent written text and supports one-click enhancement into clear prompts.

  • Plugin directory: https://www.skillhub.cn/plugins/liuyong0426/dsh-voice-polish
  • GitHub: https://github.com/liuyong0426/dsh-voice-polish
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye