DSH Plugins Marketplace

DSH Plugins

Plugins

/

Sessions & Messages

/

dsh-prompt-optimize

d

dsh-prompt-optimize

Manifest valid
UI (client)hasBundlePatch

dsh-prompt-optimize

DeepSeek Harness web plugin: rewrite the current composer draft through an auxiliary LLM call. Click replaces the draft only; it never sends a message or starts a turn.

Install

dsh plugin --profile web add github:peterliucius/dsh-prompt-optimize

Git-hosted plugins build on install through prepare. pnpm ≥10 blocks that script until you allow it. The first add fails and prints the key; copy it into the profile's pnpm-workspace.yaml:

allowBuilds:
  dsh-prompt-optimize: true

Then re-run the same add. Only allow packages whose source you trust. Pin a commit (github:peterliucius/dsh-prompt-optimize#<sha>) if you do not want a later push to change what runs.

A local checkout that already has lib/ does not need allowBuilds:

dsh plugin --profile web add /path/to/dsh-prompt-optimize

Start the web profile:

dsh --profile web

The patch inserts one row named dsh-prompt-optimize (maxInputBytes: 32768, maxOutputTokens: 4096, timeoutMs: 60000). The same package's dsh.client declaration occupies conversation.input.right. Default web-app does not mount this plugin.

Behavior

The sparkle button is always visible. It disables when the draft is empty after trim, contains a composer reference chip (U+FFFC), the session is removed, or the input machine is not in the plain phase.

Click captures the current draft, calls ctx.promptOptimize.optimize over the promptOptimize Typert Remote, and overwrites the composer through inputActions.setDraft only when the live draft still equals that capture. Failures toast; a moved draft toasts and is not replaced.

The auxiliary request frames the draft as JSON, uses a fixed rewrite instruction, enforces the configured byte and token budgets, composes timeout with caller cancellation, and sets reasoningEffort: 'off'. It never enqueues a user message or appends a durable session event.

Route resolution uses plugin provider/model when both are set, else the session's latest request/header config, else ctx.get('agentDefaultModel')?.currentSelection().

Configuration

Every field is required except the paired route override; there are no library defaults. The bundle row supplies the values below.

KeyContract
maxInputBytesPositive UTF-8 byte ceiling for the final JSON-framed user prompt.
maxOutputTokensPositive auxiliary generation token cap.
timeoutMsPositive end-to-end deadline within the runtime timer limit.
provider, modelOptional explicit route; both or neither.

Override them in the profile's cordis.patch.yml by restating the whole row config.

Develop against a local harness

Tests resolve @deepseek-ai/dsh-* peers through a sibling deepseek-harness checkout at ../dsharness. Without that checkout, pnpm test skips.

pnpm install
pnpm test
pnpm build

Regenerate Typert host + remote-client artifacts after changing @Remote methods (requires the sibling checkout):

pnpm exec tsx scripts/generate-typert.ts

License

MIT

Comments

Loading…

From the same category

billion-context

by ranxianglei

基本稳定可用 100K tokens is enough. Universal context-compression proxy for ALL AI coding agents,10w上下文足矣

Sessions & MessagesManifest valid

★ 632

↓ 388.2k/wk

MIT

TypeScript

Oct 8, 2026

dsh plugin --profile web add billion-context

by Han-1413141

DeepSeek Harness session cost meter plugin: session/daily cost, budget, history, OpenCode Go quota, official & custom-provider balance, Codex-like token heatmap, peak/off-peak pricing with pre-switch

Sessions & MessagesManifest valid

★ 377

↓ 33.5k/wk

MIT

JavaScript

Oct 7, 2026

dsh plugin --profile web add dsh-cost-meter

by Nwflower

Import 14+ external agent chat histories (Claude Code, Codex, ChatGPT, Cursor, Gemini, Reasonix, opencode, ZCode, Grok Build, OpenClaw, Pi, Hermes, Kimi CLI, DSH) into DeepSeek Harness as resumable se

Sessions & MessagesManifest valid

★ 213

MIT

JavaScript

Oct 7, 2026

dsh plugin --profile web add dsh-chat-import

by Totoro-qaq

DeepSeek Harness plugin for previewable cross-preset session migration. Fixed-schema handoffs preserve state, source-model intent, and unresolved images; the original session stays untouched.

Sessions & MessagesManifest valid

★ 165

MIT

JavaScript

Oct 6, 2026

dsh plugin --profile web add dsh-plugin-bridge

by Anionex

deepseek harness对话和代码状态回退插件 | DSH — rewind conversation and workspace state, powered by a persistent Change Ledger

Sessions & MessagesManifest valid

★ 131

BSD-3-Clause

JavaScript

Oct 1, 2026

dsh plugin --profile web add @anionex/dsh-turn-rewind

by aa2246740

Read-only Agent work-path observer for DeepSeek Harness

Sessions & MessagesManifest valid

★ 115

MIT

JavaScript

Oct 7, 2026

dsh plugin --profile web add dsh-watcher