nuwa-skill
alchaincyf
你想蒸馏的下一个员工,何必是同事。蒸馏任何人的思维方式——心智模型、决策启发式、表达DNA。Distill how anyone thinks.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:CTX666666/dsh-prompt-polish
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
A Work Buddy–style "polish prompt" button for the DeepSeek Harness composer.
Left-click rewrites your draft into a clearer prompt using the model the conversation is already on. Right-click picks a style.
The button sits in the composer's trailing control seat — immediately before the model selector, exactly where Work Buddy puts it — and does one thing: it rewrites the draft you are looking at into a more effective prompt.
modelSelection projection
first, then the selection the Client reports from its model seat, then the
profile default. Whichever it lands on is the model you were already using.llm service you already configured.| State | What you see |
|---|---|
| Draft empty, nothing rewritten | Button hidden (same as Work Buddy) |
| Draft has text | Spark icon; hover shows the tooltip and current style |
| Rewrite running | Spinner; a second click cancels and restores the draft |
| Rewrite succeeded | Revert arrow; click restores the original |
| Rewrite failed | Draft untouched; the reason appears in the tooltip |
adjudicating / submitting phase |
Button disabled |
The style menu also opens with Shift+F10 or the context-menu key, and closes on outside press, Esc, or window blur.
Install straight from GitHub — one command, nothing to clone:
dsh plugin add github:CTX666666/dsh-prompt-polish
Or clone the entire repository, including all subdirectories, and install that directory:
git clone https://github.com/CTX666666/dsh-prompt-polish.git
dsh plugin --profile <your-profile> add /path/to/dsh-prompt-polish
Quote Windows paths containing spaces. GitHub's complete ZIP also works after extraction; downloading only the root files does not produce a usable plugin.
Either way the bundle declares its own dsh.bundle.patch, so installing it
inserts the Host row and the Client bundle in one step; no separate registration.
After installing, the button appears the next time the composer renders. No rebuild and no extra dependency are needed — see below.
conversation.input.right
and the llm + webServer services.@deepseek-ai/dsh-client-ui-conversation and
@deepseek-ai/dsh-client-locale, so the locale and conversation packages must
be present (they ship with the standard Web/Desktop profile).Both halves are shipped as plain JavaScript, and that is deliberate:
src/index.js, an ES module that exports inject and
apply. It imports nothing from the Harness packages — a workspace-installed
bundle resolves its own bare imports against the workspace rather than the
running installation, so the small request vocabulary it needs is built from
the plain shapes the llm service documents.src/client.js, a classic script that registers itself
with window.__ModuleLoader__.load({ id, factory }) and resolves react
through the loader's module table.There is no bundler, no transpiler, and nothing to run before installing. What
you read in src/ is exactly what loads.
Zero runtime dependencies. The Client half requires react, which the Harness
loader already provides; the Host half requires nothing at all.
dsh-prompt-polish/
├── src/
│ ├── index.js # Host half: HTTP route + polish pipeline
│ └── client.js # Client half: the composer button
├── docs/
│ └── IMPLEMENTATION.md # replication spec: contract, verbatim prompts, edges
├── locale/
│ ├── en.json # plugin card metadata (anchor locale)
│ └── zh.json # Chinese metadata
├── assets/
│ └── icon.svg # plugin icon
├── scripts/
│ └── check.mjs # dependency-free sanity check
├── .github/
│ ├── workflows/ci.yml
│ └── ISSUE_TEMPLATE/
├── cordis.patch.yml # bundle patch: one Host row
├── package.json
├── README.md # this file
├── README.zh.md
├── CHANGELOG.md
├── CONTRIBUTING.md
├── LICENSE
├── .gitattributes
└── .gitignore
docs/IMPLEMENTATION.md is the build-it-again document: the
behaviour contract, the verbatim system and user prompts, the four style
directives, the context block format, the fidelity-guard regexes, the model
fallback chain, fifteen edge cases, and a fourteen-item self-test. It is written
so another engineer — or another model — can reproduce this plugin on a different
host without reading src/ first.
If you only want the prompt text to reuse in a single-turn tool, jump to §11 of that document.
npm run check
Checks syntax and manifest wiring, then runs 27 HTTP and component-state
regression tests. No npm install required. Running node scripts/check.mjs
alone only checks syntax and package files. Tests use controlled model outputs;
they do not establish end-to-end acceptance in a live Harness/model service.
POST /dsh-prompt-polish/polish with { text, style, sessionId?, provider?, model?, reasoningEffort? }.ctx.llm.stream() call at temperature: 1. Only text-delta chunks are
accumulated; a finish with kind: 'error' | 'aborted' is surfaced as a
failure.{ ok: true, text, provider, model, style, fidelity, contextUsed },
or { ok: false, code, error } with code one of empty_input, no_model,
llm_error, aborted, empty_result, fidelity_failed, invalid_request,
not_found, method_not_allowed, internal. A failed corrective retry
preserves the original draft and never returns rejected replacement text.Editing the draft, navigating to another session or submitting invalidates an in-flight result. Cancelling disconnects the Host request and aborts upstream generation; the initial call and corrective retry share a 60-second deadline.
Only text-delta and finish are read, so a provider that streams reasoning
blocks costs nothing extra.
llm
provider you configured — that is the model call.localStorage under dsh-prompt-polish.style.The Client half targets the slot contract declared by
@deepseek-ai/dsh-client-ui-conversation. If a future Harness moves that slot,
the button stops appearing rather than breaking the composer — the registration
is wrapped in ctx.effect, so it is disposed cleanly on unload.
See CONTRIBUTING.md. npm run check must
pass, and behaviour changes need a sentence in CHANGELOG.md.
git clone https://github.com/CTX666666/dsh-prompt-polish.git
The manifest already points at this repository. Installation requires cloning and installing the directory; users do not need to initialize or push a repository.
package.json keeps "private": true on purpose: this plugin is distributed as a
directory (or a git URL) that a DSH profile installs, not as a package on the npm
registry. That flag prevents an accidental npm publish; it does not restrict
cloning, forking, or installing.
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: prompt、prompt-engineering。