DeepSeek Harness Plugin

Mutx163/dsh-model-memory

Downloads (30d) 1,875 Category Models & Providers Added 2026-09-05 npm dsh-model-memory

Reasoning-effort tier manager for custom API models plus cross-session preference memory: inline low/medium/high/max toggles inside Settings → Models, with atomic settings writes.

Install

# from npm (prebuilt)

dsh plugin --profile web add dsh-model-memory

# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)

dsh plugin --profile web add github:Mutx163/dsh-model-memory

Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).

README


dsh-model-memory is a plugin for DeepSeek Harness (DSH) that provides reasoning effort management, channel-level retry policy control, and cross-session preference memory for custom API models.


🌟 Key Features

1. 🧠 Custom Model Reasoning Effort Configuration

  • Seamless UI Integration: Automatically mounts inline reasoning effort controls directly under custom model items inside DSH Settings -> Models.
  • Effort Tiers Selection: Enables supportsReasoningEffort and allows selecting supported tiers (low / medium / high / max).
  • Instant Persistence: Saves atomically into ~/.dsh/settings.yaml with immediate effect.

2. ⚡ Cross-Session Preference Memory

  • Per-Channel Memory: Accurately remembers the last chosen model and reasoning effort (e.g. max) per custom provider channel.
  • Auto-Fill on Session Start: Automatically restores your preferred model and thinking tier when creating new sessions or switching channels.

3. 🔁 Channel-Level Request Retry Policy

  • Three Modes: Channel default (up to 5 retries after a failure), unlimited retries (keeps retrying until success or cancellation), or a custom count (0 disables retries).
  • Applies per Channel: DSH's retryPolicy is a channel-level setting shared by all models inside the channel; updates preserve the channel's existing backoff parameters and reuse the same write path as reasoning effort (host settings service first, atomic direct file write as fallback).

4. 🛡️ Lightweight & Upgrade-Immune

  • Zero UI Clutter: Clean integration within settings pages without adding stray buttons to the main view.
  • Upgrade-Safe: Retains your configuration and local plugin across global DSH CLI upgrades.

🚀 Installation

Option 1: Install from NPM (Recommended)

dsh plugin --profile web add dsh-model-memory

Option 2: Local Development with Link

# 1. Clone repository
git clone https://github.com/Mutx163/dsh-model-memory.git
cd dsh-model-memory

# 2. Install dependencies & verify
pnpm install
pnpm run verify

# 3. Mount to DSH Web Profile
dsh plugin --profile web add link:/path/to/dsh-model-memory

📂 Project Structure

dsh-model-memory/
├── src/
│   ├── index.ts        # Plugin lifecycle and Agent default model wrapper
│   ├── memory.ts       # Model & reasoning effort memory algorithm engine
│   ├── rpc.ts          # /model-memory bidirectional RPC channel
│   ├── settings.ts     # settings.yaml atomic configuration manager
│   ├── store.ts        # Disk persistence engine (~/.dsh/model-memory.json)
│   ├── types.ts        # TypeScript definitions
│   └── client/
│       └── index.ts    # Web UI client components
├── test/               # Vitest unit test suites
├── cordis.patch.yml    # Cordis patch layer
├── LICENSE             # MIT License
├── README.md           # Chinese Documentation (Default)
└── README_EN.md        # English Documentation

🧪 Development & Testing

# TypeScript typecheck
pnpm run typecheck

# Run unit tests
pnpm run test

# Full verification & build
pnpm run verify

📄 License

Licensed under the MIT License.

Content from the project README on GitHub ↗

Links

More in this category

View the whole category →

Community comments

Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.