Back to home

Classicoke

cleverer-dsh

DSH execution-discipline plugin suite: 11 plugins + 6 skills, zero dependencies, 426 tests. 让 DeepSeek Harness 变聪明的插件套件。

Stars
3
Language
JavaScript
Created
Aug 15, 2026
Updated
Aug 16, 2026

Introduction

cleverer-dsh

English | 中文

A plugin suite that makes DeepSeek Harness (DSH) actually smart — execution discipline, practical tools, and a skill library, installed in one shot.


✨ Feature Highlights

IconFeature
Faster & cheaper (measured): same task vs bare DSH — 49% faster, 44% fewer estimated tokens (small sample, not yet broadly tested)
🧠Execution discipline: automatic failure interception, forced reflection, task-planning reminders, memory dedup, experience auto-distilled into skills
🛠️Ready-made tools: instant multi-directory file lookup + 9-point environment health check — stop guessing
📦One-command install/uninstall via DSH's own plugin manager
🧪478 unit tests green, statement & line coverage 100%; pure code, zero dependencies, never touches DSH itself
📚6 built-in skills: 6-step error handling, error lookup table, fast file lookup, root-cause debugging, local-first, plan-before-execute

Measured results

We ran the same real task (analyzing a software packaging log) on DSH with this suite vs a bare DSH (nothing installed):

MetricWith suiteBare DSHDiff
Total time8.6 min12.8 min49% faster
LLM calls5161-20%
Tool calls5967-14%
Estimated total tokens~41,000~73,00044% fewer
Reasoning chunks4011,163-65%

What you notice in practice: with the suite, the agent stops retrying the same broken approach (it automatically switches), distills working commands into reusable scripts, and asks you before acting at key decision points. Bare DSH retried the same problem 13 times, never distilled anything, and never consulted you.

⚠️ Disclaimer: n=1 per group; tokens are character-estimated (±20%); not broadly tested yet — the direction is evidenced, exact numbers await more samples and real API billing data.


What it fixes

DSH is full-featured but not smart by default: empty system prompt, stubborn retries on failure, skills installed but never used, todo tool ignored. This suite fixes it:

LayerWhat it does
Discipline layer (8 plugins)failure interception, forced reflection, task planning, memory dedup
Hub (discipline-hub)shared failure log + reminder throttling — plugins don't collide, issues are traceable
Tools layer (2 plugins)instant file lookup, env health check
Skill layer (6 skills)on-demand auto-loading — know what to do on errors, find things fast

Architecture

Installed via Option 1 (plugin manager) — all plugins in one inline patch

cordis.patch.yml
├─ discipline-hub          hub (failure log / reminder throttle / turn stats)
├─ anti-stuck              stuck-loop guard: no repeat same-arg retries, force new approach
├─ dsh-env-triage          problem tracing: stop & report when several schemes fail
├─ dsh-plan-discipline     task planning: remind to create a plan for multi-step tasks
├─ dsh-memory              cross-session memory: auto-dedup, anti-bloat
├─ skill-evolver           experience distillation: failure → solution → saved skill
├─ dsh-discipline          11 execution rules injected every turn
├─ dsh-skill-loader        skill usage boost: on-demand catalog + keyword summoning
├─ dsh-skill-provider      runtime skill registry: the 6 bundled skills resolve in-package
├─ dsh-cordis-discipline   dynamic-plugin guardrail: no run before define, no undefine before stop
├─ dsh-fast-locate         file lookup: parallel multi-directory scan
└─ dsh-env-check-tool      env health check: 9 checks

Installed via Option 2 (script install) — grouped into boards

cordis.patch.yml (home patch)
├─ discipline-hub              hub, loaded first (failure log / reminder throttle / turn stats)
├─ cordis:include → discipline-board.cordis.yml   (8 discipline plugins)
│  ├─ anti-stuck               stuck-loop guard
│  ├─ dsh-env-triage           problem tracing
│  ├─ dsh-plan-discipline      task planning
│  ├─ dsh-memory               memory dedup
│  ├─ skill-evolver            experience distillation
│  ├─ dsh-discipline           11 execution rules
│  ├─ dsh-skill-loader         skill usage boost
│  └─ dsh-cordis-discipline    dynamic-plugin guardrail
└─ cordis:include → tools-board.cordis.yml        (2 tool plugins)
   ├─ dsh-fast-locate          file lookup
   └─ dsh-env-check-tool       env health check

The board layout makes plugin cooperation structural: the discipline group shares the hub's unified failure log and reminder pipeline, working as one suite instead of in isolation.


Installation

Prerequisites: DSH installed and initialized; pnpm available (DSH's plugin manager).

Choose before you install — the two options differ in how plugins are organized:

Option 1: plugin manager (official)Option 2: script install
Commanddsh plugin add ...paste one PowerShell line
Plugin organizationall plugins in one inline configgrouped into discipline-board (discipline) + tools-board (tools) boards
Plugin cooperationplugins work independentlystronger — discipline plugins share one failure log & reminder pipeline, working as one suite

💡 Why boards are the better architecture: the plugins are not meant to work in isolation — one traces the root cause, one distills the lesson, one reminds you to plan. Boards make this cooperation a structural guarantee (plugins belong to the same group and share the same facilities by construction) instead of leaving it to chance. Discipline and tools are physically separated with clear boundaries, so adding your own plugin later has an obvious home; groups start/stop as a whole, which makes upgrades and troubleshooting simpler.

Option 1: via DSH's plugin manager (official)

dsh plugin --profile web add github:Classicoke/cleverer-dsh
# headless instead:  dsh plugin --profile headless add github:Classicoke/cleverer-dsh

No build step — plugins and skills are ready as soon as the command finishes. Uninstall:

dsh plugin --profile web remove cleverer-dsh

Option 2: one-command script (PowerShell 7+)

Paste this into PowerShell (auto-downloads the release zip → extracts → installs → cleans up):

$u = 'https://github.com/Classicoke/cleverer-dsh/archive/refs/tags/v1.2.zip'
$z = "$env:TEMP\cleverer-dsh.zip"; $d = "$env:TEMP\cleverer-dsh-install"
Invoke-WebRequest $u -OutFile $z
Expand-Archive $z $d -Force
pwsh -File "$d\cleverer-dsh-1.2\install.ps1"
Remove-Item $z, $d -Recurse -Force

⚠️ Pick ONE install method. Installing both applies every plugin twice (duplicated behavior, premature denials). Uninstall one before switching to the other.

Uninstall (Option 2)

# 1. Restore the config backup install auto-created (if you had no
#    cordis.patch.yml before, the backup is an empty [] patch = pre-install state)
$dshHome = Join-Path $HOME '.dsh'
if (-not (Test-Path $dshHome)) { Write-Host "Not found: $dshHome — aborting"; exit 1 }
$bak = Get-ChildItem "$dshHome\cordis.patch.yml.bak-cleverer-*" |
       Sort-Object LastWriteTime -Descending | Select-Object -First 1
if ($bak) { Copy-Item $bak.FullName "$dshHome\cordis.patch.yml" -Force }

# 2. Remove ONLY the files cleverer-dsh installed (explicit list — your own
#    plugins/skills in the same folders are left untouched)
$plugins = @('_shared','anti-stuck','discipline-hub','dsh-cordis-discipline','dsh-discipline',
             'dsh-env-check-tool','dsh-env-triage','dsh-fast-locate','dsh-memory',
             'dsh-plan-discipline','dsh-skill-loader','dsh-skill-provider','skill-evolver')
foreach ($p in $plugins) { Remove-Item "$dshHome\plugins\$p.mjs" -ErrorAction SilentlyContinue }
$skills = @('debug-by-root-cause','dsh-error-protocol','dsh-error-triage','dsh-fast-lookup','local-first','plan-before-execute')
foreach ($s in $skills) { Remove-Item "$dshHome\skills\$s.md" -ErrorAction SilentlyContinue }
Remove-Item "$dshHome\discipline-board.cordis.yml", "$dshHome\tools-board.cordis.yml" -ErrorAction SilentlyContinue
Remove-Item "$dshHome\scripts\dsh-env-check.mjs" -ErrorAction SilentlyContinue

# 3. Restart DSH

All deletions are scoped to $HOME\.dsh (your own user directory, never a system path), and only the files listed above are touched.


Plugins

PluginProblem it solvesWhen it triggers
anti-stuckstubbornly retrying the same failing command≥2 same-arg fails → deny; ≥3 turn fails → remind; ≥5 → force reflection
dsh-env-triageparam-tweaking loops, going in circles≥2 schemes fail → trace card; ≥3 → stop & report
dsh-plan-disciplinetodo tool ignoredmulti-step task without plan → remind; ≥3 fails & stale plan → refresh
dsh-memorymemory bloat, force-write abusededup before write + 60s window dedup
skill-evolverjunk skills being savedgeneralization gate before persisting
dsh-disciplineempty system promptinjects 11 execution rules every turn
dsh-skill-loaderskills installed but never usedavailable-skills reminder at task start + keyword summoning
dsh-cordis-disciplinedynamic-plugin misuseprecondition checks (no run before define, no undefine before stop)
discipline-hubplugins each doing their own thing, reminder spamunified failure log + reminder throttle
dsh-fast-locateslow file lookupone call, parallel multi-directory scan
dsh-env-check-toolguessing at environment issuesone-shot 9-point env health check

Built-in skills

SkillPurpose
dsh-error-protocol6-step error handling (classify → diagnose → decide → verify → distill)
dsh-error-triageerror lookup table: which error maps to which command
dsh-fast-lookupfast file lookup methodology
debug-by-root-causefind the root cause first, don't blindly retry
local-firstverify locally before guessing online
plan-before-executeplan before acting, keep the plan updated

Known limitations

  • Verified on Windows + PowerShell only; Linux/macOS untested (plugins are cross-platform, install scripts are PowerShell)
  • Never modifies DSH source code; only config injection and skill injection
  • Headless mode: some features limited (no web server → some web-dependent features skipped)

License

MIT © 2026 cleverer-dsh contributors