Skip to content

Harmony

Don't reinvent the wheel. Decorate it.

Harmony provides an elegant way to modify the behavior of other plugins written for DeepSeek Harness. It runs as an external framework, applies Patches to target plugins at runtime, and starts DeepSeek Harness with the transformed plugin set.

Source Patches use TSQuery to precisely match target nodes in a TypeScript AST, then use MagicString to rewrite the corresponding ranges of the current in-memory source. Patches run in their configured order, and each Patch receives the output of the previous one, giving multiple changes to the same target a chance to coexist. Installed plugin files are never modified.

The goal is to extend the expressive power of DeepSeek Harness through creativity, composition, and modification.

Respect

Inspired by Harmony, the project of the same name created by Andreas Pardeike and other contributors for C#.

Install

Requires Node.js ^22.22.3 or >=24.11.1 and @deepseek-ai/dsh@0.1.0-rc.6.

sh
npm install -g @deepseek-ai/dsh@0.1.0-rc.6
npm install -g dsh-harmony
dsh web

After startup, open Settings → Harmony or run dsh harmony in another terminal. See Installation for profiles, Desktop integration, updates, and removal.

Documentation

TaskGuide
Understand where Harmony runsRuntime architecture
Install and configure a profileInstallation
Reorder, inspect, disable, and reloadOperations
Write a source or semantic PatchPatch authoring
Patch compiled React treesReact integration
Expose editable Studio variablesStudio integration
Look up commands and state filesCLI reference
Diagnose a failed PatchTroubleshooting

Runtime model

text
installed plugin source (unchanged)
  → collect enabled Patch providers
  → resolve provider order and conflicts
  → preflight every source transformation
  → execute the new runtime generation
StageOwned byGuarantee
Original sourceInstalled plugin packageNever written by Harmony
Patch pipelineHarmony providersDeterministic order and exact match checks
Runtime generationHarness LoaderReplaced only after successful preflight

Browser targets use Harness HMR. Node targets reload through the Loader Tree. Both use the same provider order, Patch state, and inspection trail.

dsh-harmony-react provides typed factories for changing compiled jsx and jsxs calls. Its optional Studio entry integrates those declarations with dsh-webui-studio.

Reference

Released under the MIT License.