- Home
- Plugins
- UI Enhancements
- dsh-star-prompt-enhance
dsh-star-prompt-enhance
zhouzhou5210/dsh-star-prompt-enhance
A star button beside the composer that rewrites the current draft into a clearer, more complete prompt with the session default model; it reads up to five recent user prompts from the same session as read-only context, writes the result back into the composer, and never sends the message.
Install
dsh plugin --profile web add github:zhouzhou5210/dsh-star-prompt-enhanceREADME
dsh-star-prompt-enhance
A DeepSeek Harness (dsh) plugin that adds a star button beside the message composer. One click rewrites the current draft into a clearer, more complete prompt — using the last few prompts of the same conversation as read-only context — then writes the result back into the draft so you can review it before sending.
What it does
- Adds a small star (sparkle) button to the composer's right-side control row, next to the send button.
- On click, the Host half reads up to the last five user prompts of the current session from the local session log, then asks the currently selected default model (
agentDefaultModel.currentSelection()) to rewrite the draft: it keeps your intent, facts, URLs, paths and constraints, resolves references like "the second one" against the recent conversation, adds goal/scope/steps/acceptance criteria where they are missing, and never invents requirements. - The rewritten text replaces the draft in place via the composer's
setDraft, so you can edit it, undo with the editor's own undo, or send it. - The button shows busy / done / error states, is disabled while the composer is submitting, and never sends the message for you.
Install
Requires dsh 0.2.1 or newer.
dsh plugin add dsh-star-prompt-enhance
Or from this repository directly:
dsh plugin add github:zhouzhou5210/dsh-star-prompt-enhance
Conversation context
- The Host reads the session's own
user/messageevents through the optionalsessionQueryservice: the last 5 prompts, each clipped to 1200 characters and 6000 characters in total. - The prompts are untrusted data used only to understand the draft; the model is told not to follow instructions inside them and not to add requirements the draft does not imply.
- If
sessionQueryis unavailable or the session cannot be read, the rewrite degrades to the draft alone instead of failing. - Only this session's user prompts are used — never other sessions, workspace files or attachments.
Privacy and behaviour
- The rewrite call happens in the Host process through the public
llmservice; no API key ever reaches the browser. - The current draft plus up to five recent user prompts of this session are sent to the model with a short system prompt. Nothing else is sent, and nothing is written to disk by the plugin.
- The button does nothing when the draft is empty or when the composer is mid-submit.
- The HTTP endpoint is same-origin only and goes through the host's connection fence (Host/Origin check plus login cookie).
Layout
| File | Purpose |
|---|---|
index.js | Host half: registers POST /dsh-star-prompt-enhance/enhance on the host web server and calls llm.prepareCall / llm.stream. |
client.js | Browser half: registers the star button in the conversation.input.right slot and the zh/en strings. |
cordis.patch.yml | Inserts the plugin row into the profile. |
locale/*.json | Plugin metadata and display strings. |
License
MIT
Related plugins
dsh-web (dsh-task-board)
zhu1090093659/dsh-web
dsh-web (dsh-web-all)
zhu1090093659/dsh-web
dsh-TUI
ccch1mneyyy/dsh-tui
dsh-web-ui (dsh-task-board)
zhu1090093659/dsh-web-ui