dsh-prompt-better
其他 活跃维护

dsh-prompt-better

GeniusHu-tgty/dsh-prompt-better

在编辑器内一键将草稿重写为更清晰、具体的提示词,支持撤销与取消。轻量插件,集成在composer界面,即时生效,无需切换工具。

1
Stars 标星
0
Forks 分支
1
Watchers 关注
0
Open Issues
TypeScript
主要语言
Apache-2.0
开源协议
189 KB
仓库大小
1 个月前
最后推送
一键安装扩展 / 插件指令
dsh plugin --profile web add github:GeniusHu-tgty/dsh-prompt-better
git clone https://github.com/GeniusHu-tgty/dsh-prompt-better.git
git clone git@github.com:GeniusHu-tgty/dsh-prompt-better.git
README.md main
# DSH Prompt Better ### ✨ One click. A clearer prompt. Turn a rough idea into a focused prompt—right where you write. Enhance, cancel, or restore without leaving your conversation. [![Apache-2.0](https://img.shields.io/badge/license-Apache--2.0-4f7cff?style=flat-square)](https://raw.githubusercontent.com/GeniusHu-tgty/dsh-prompt-better/main/LICENSE) ![For DSH](https://img.shields.io/badge/made%20for-DSH-111827?style=flat-square) **English** · [简体中文](https://github.com/GeniusHu-tgty/dsh-prompt-better/blob/main/README.zh-CN.md)

From rough idea to ready-to-send

Ask a quick question, then enhance it into a clear request with useful context.

BEFORE AFTER
A short question about a GitHub project A detailed request for project analysis and usage instructions

A simple three-state button

✨ Enhance Animated loading spinner Enhancing · click to cancel ↺ Restore
Rewrite your draft in place. The animated spinner shows the request is running. Bring back the original draft at any time after enhancement.

The rewrite keeps your draft's language. Your text stays safe, too: if a request fails or you keep typing while it runs, the plugin won't replace it. File-reference chips are preserved.

Uses your current DSH model

Enhancement follows the model selected for the conversation when you click ✨, using your existing DSH provider and API setup. No separate API key or model setup is needed. If the conversation has no model selection, the DSH host's default model is used.

Get started

You need a working DSH installation and profile.

  1. Build the package:

    pnpm install
    pnpm build
  2. Add it to your profile's package.json and bundle list:

    {
     "dependencies": {
       "dsh-prompt-better": "link:<absolute path to this package>"
     },
     "dsh": {
       "profile": {
         "bundles": ["...", "dsh-prompt-better"]
       }
     }
    }
  3. Restart DSH, type a draft, and click ✨ beside the chat input.

Optional: set a timeout or pin a model Add this to your profile's `cordis.patch.yml`. Usually, no extra configuration is needed. ```yaml - id: enhance-prompt name: dsh-prompt-better config: timeoutMs: 120000 # Optional: use a fixed model instead of the conversation's selection. # provider: deepseek-account # model: deepseek-flash ```
Development ```bash pnpm install pnpm build pnpm typecheck ```

[Apache-2.0 License](https://github.com/GeniusHu-tgty/dsh-prompt-better/blob/main/LICENSE) · [简体中文](https://github.com/GeniusHu-tgty/dsh-prompt-better/blob/main/README.zh-CN.md)