dshbase

插件目录 / AI Models / dsh-prompt-polish

dsh-prompt-polish

已验证 · 实测可装 JoukoPuro

✓ 持续维护 基于 3 个官方 DSH 包

查看 GitHub ↗ ← 返回插件目录

3Stars
0Forks
0未关闭 issue
JavaScript语言
2026-08-14最近推送
跨平台平台

功能简介

一个 DeepSeek Harness(DSH)插件: 在 Web 输入框的工具行中添加一个 ✨ 图标按钮。点击后选择打磨风格,已接入的大模型 会把你草稿中的提示词改写得更专业、更易被 AI 理解 。A DeepSeek Harness plugin: icon-only composer button that rewrites your prompt via the connected LLM (balanced/concise/detailed/code styles, i18n)

✅
我们的评价
可用 — 实测通过,早期项目

一个 DeepSeek Harness(DSH)插件: 在 Web 输入框的工具行中添加一个 ✨ 图标按钮。点击后选择打磨风格,已接入的大模型 会把你草稿中的提示词改写得更专业、更易被 AI 理解 。A DeepSeek Harness plugin: icon-only composer button that rewrites your prompt via the connected LLM (balanced/concise/detailed/code styles, i18n) 实测能干净安装、正常启动。早期项目,但功能可用。

「已验证」表示我们的自动化 CI 在干净 profile 里实际执行了 dsh plugin add 并启动成功——仅此而已。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。

README

dsh-prompt-polish

English | 中文

A DeepSeek Harness (DSH) plugin
that adds a ✨ sparkle button to the web composer's tool row. Click it, pick a
rewrite style, and the already-connected LLM rewrites your draft prompt to be
more professional and easier for an AI to understand — then replaces the draft
so you can review before sending.

  • Icon-only button — a sparkle glyph in the composer tool row; no text,
    tooltip gives the full description.
  • Four rewrite styles — balanced / concise / detailed / code-oriented.
  • Multi-language UI — menu copy follows your browser language (zh, en, ja,
    ko, fr, de, es, pt, ru, it, tr, vi; falls back to English).
  • Uses your connected model — resolves the current default agent model
    (agentDefaultModel), or an explicit provider/model from config.

Requirements

  • DeepSeek Harness (@deepseek-ai/dsh) web profile running, with a model
    adapter configured (e.g. the DeepSeek provider with an API key in Settings).

Install

# from a checkout of this repository (or the directory containing it)
dsh plugin --profile web add ./dsh-prompt-polish

Then restart dsh web so the profile picks up the new bundle:

dsh web

Open the web UI, type a draft, and click the sparkle button in the composer
tool row.

Configuration

The plugin accepts optional config in the profile's cordis.patch.yml
(user layer, applied after the bundle layer):

- id: prompt-polish
  config:
    provider: deepseek-official   # explicit route (optional)
    model: deepseek-v4-flash      # must be paired with provider
    style: balanced               # default rewrite style: balanced | concise | detailed | code
    maxTokens: 2048               # output cap for the rewrite call
    # system: '...'               # custom rewrite instruction (replaces the built-in per-style prompts)

Without provider/model, the plugin uses
agentDefaultModel.currentSelection() — the same default model the session
uses.

How it works

Half File Role
Host lib/index.js Registers POST /prompt-polish on the web server; streams one LLM rewrite via ctx.llm
Browser lib/client.js Registers the sparkle button into conversation.input.right; opens a style menu; posts the draft and replaces it with the polished text

The bundle's package.json declares both faces of the dual-face plugin:

  • dsh.bundle — the profile patch layer (cordis.patch.yml) that inserts the
    prompt-polish loader row.
  • dsh.client — the web boot row; client-modules serves lib/client.js at
    /plugins/dsh-prompt-polish/client.js.

Development

Edit lib/index.js (host) and lib/client.js (browser). The browser bundle is
a hand-built closure-factory artifact (window.__ModuleLoader__.load({ id, factory })) — keep externals limited to the platform modules
(react, @deepseek-ai/dsh-client-ui-primitives) and inline everything else,
matching the loader's module-table rules.

Verify on a scratch port before touching the live profile:

dsh web --port 3099
curl -s http://127.0.0.1:3099/plugins/dsh-prompt-polish/client.js | head
curl -s -X POST http://127.0.0.1:3099/prompt-polish \
  -H 'content-type: application/json' \
  -d '{"text":"read a.csv and sort by b","style":"code"}'

License

MIT

安装

🧩 让 Agent 自动装(推荐)

装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:

dsh plugin add dshbase-catalog

然后对 agent 说「帮我装 dsh-prompt-polish」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。

该插件是 GitHub 源码(未发 npm)——直接从仓库装:

Web profile:

dsh plugin --profile web add github:JoukoPuro/dsh-prompt-polish

Headless(CLI)profile:

dsh plugin --profile headless add github:JoukoPuro/dsh-prompt-polish

实测报告

验证通过:从 GitHub 源码完成 L1 安装 + L2 加载 + L3 运行(dsh 0.1.0-rc.6)。

使用场景

把一个新模型、provider 或路由策略接入循环,让 dsh 能为任务选对脑子。

适合谁

同时用多个模型或 provider、想让成本/质量/延迟自动平衡的人。

二次开发建议

provider 适配器和路由启发式是缝——加后端、调回退链,或加按任务的模型选择。

安全:尚未扫描——我们的每日静态扫描将很快覆盖它。

分享徽章

AI Models 里更多

浏览全部 7797 个插件 →