Skip to main content

dsh-evolve-modes

39Stars1Forks1Issues1Watchers

Provides composable controls for self-evolving modes, including task states, thinking strategies, quality review, and human moderation for DeepSeek Harness Web.

Evidence5/5methodologySourceInstallMaintenanceDSH versionSecurity scan
Machine-auditedInstall commandRepo verifieddsh-plugin topicLicenseREADMEAI wiki
Language
TypeScript
License
MIT
Branch
main
acceptance-reviewagent-reviewai-agentsdeepseek-harnessdshdsh-pluginplan-modeprompt-engineering

Install

cmdweb profile
$ dsh plugin --profile web add @graysilver/dsh-evolve-modes

Run the command above in your terminal to install this plugin via the dsh CLI. You can switch Profile in the top-right corner. New to dsh? Read the beginner tutorial

Install via your agent

Install the DeepSeek Harness plugin GraySilver/dsh-task-modes for me: review the repository at https://github.com/GraySilver/dsh-evolve-modes first, then run the install command and verify the plugin loads successfully.

Paste this instruction to the DSH Web GUI assistant — it will install and verify for you.

One-Line Positioning

dsh-evolve-modes is a DeepSeek Harness web plugin that combines four dimensions—working state, thinking strategy, quality gates, and self-evolution—into a compact control next to the input area, allowing users to combine agent working modes by task rather than by persona, and supports global rule learning based on completed sessions with human oversight.

Core Capabilities

  • Display and switch working state (Execute / Plan), thinking strategy (Standard / First Principles), quality gates (Off / Adversarial Review / Acceptance Review), and self-evolution (Off / Proposal) as four independent dimensions next to the input area
  • When First Principles is enabled, inject explicit goal-fact-assumption-constraint-derivation-verification segments into the system prompt and leave traceable historical evidence in Trajectory
  • Launch an independent forked sub-agent for adversarial or acceptance review after the parent agent completes its response, and render the Markdown report below the corresponding response
  • In Plan mode, limit executable tools via a tool whitelist (read-type tools + platform shell + exit_plan_mode), rejecting all other tools directly
  • Learn in isolation from completed sessions at a default rhythm of once every 3 parent responses, generating evidence-backed pending review proposals that require manual Apply to become approved global rules
  • Provide a Self-evolution mode settings page to view pending proposals, add/edit/delete approved rules, restore from backup, view learning execution records and failure reasons

Technical Implementation

  • Language: TypeScript + React (server entry at src/index.ts, client UI at src/client/index.tsx)
  • Key Dependencies: @deepseek-ai/cordis (plugin injection and effects), @deepseek-ai/dsh-storage-domain (persistent storage domain), @deepseek-ai/dsh-subagent (forked sub-agents), @deepseek-ai/dsh-typert-protocol (remote service description)
  • Architecture Pattern: Plugin ID and default shellTool declared via cordis.patch.yml; Host side uses ctx.inject to subscribe to agentPresets/commands/llm/systemPrompt/subagents/storageDomain/tools at once, then separately registers systemPrompt sections, tools/pre-execute hooks, evolve-mode / evolve-mode-review commands, and agent/turn-stopping listeners; Client side injects conversation.input.left control, conversation.input.plan slot, conversation.chat.turnTail review report via slots, and exposes 5 settings interfaces through Typert Remote
  • Entry Files: src/index.ts:apply (Host entry), src/client/index.tsx:apply (Client entry), src/typert.ts / src/remote.ts (Typert definitions)

Applicable Scenarios

Users who need the agent's working mode to flexibly combine by task: use "normal + standard + off" for daily tasks to maintain speed, switch to "plan + first principles" for high-risk decisions, enable "adversarial or acceptance review" after delivery for independent sub-agent result checking; if long-term stable preferences and identity information should be accumulated, enable self-evolution, where the plugin learns in fixed batches and generates pending rules requiring approval.

Prerequisites and Compatibility

DependencyMinimum VersionDescription
DeepSeek Harness0.1.0-rc.6Requires web plugin loader, client UI slots, storage domain, direct llm service, forked subagent, official planMode service, and tools/pre-execute pipeline
Node.js^22.19.0 or >=24.0.0From package.json engines field
@deepseek-ai/cordis^4.0.1-rc.1peerDependencies
@deepseek-ai/dsh-*rc.1 / rc.511 peer dependencies, must be provided by host profile
React^18.2.0Client UI dependency
PlatformmacOS / Windows / LinuxDefault shellTool is pwsh on Windows, bash on other platforms, determined by process.platform in cordis.patch.yml
Native ModulesNoneUses only node:crypto at runtime, no node-pty / node:sqlite native dependencies

Installation

dsh plugin --profile web add @graysilver/dsh-evolve-modes

Configuration Options

ConfigurationTypeDescriptionDefault Value
shellTool'bash' | 'pwsh'Platform shell allowed in Plan mode tool whitelist, automatically selected by cordis.patch.yml (pwsh on Windows, bash elsewhere); only takes effect when target profile has registered corresponding shellCross-platform auto: Windows → pwsh, others → bash

The plugin's runtime behavior (learning batches, pending proposal limits, current state of each dimension) is managed through the Self-evolution mode settings page and /evolve-mode command, not via host yaml configuration.

FAQ

Q: After installation, where can I find this plugin's controls?

A: After restarting the web profile, the self-evolution mode control appears on the left side of the input area (conversation.input.left slot), and the self-evolution settings entry is in the top-level Settings page under the Self-evolution mode section.

Q: Will the plugin modify DeepSeek Harness core code?

A: No. cordis.patch.yml only inserts the plugin's own injection description, and plugin state is saved in its own storage domain, not modifying AGENTS.md or CLAUDE.md.

Q: How many additional model calls do adversarial review / acceptance review add?

A: Each time the parent agent completes a response, the quality gate triggers an extra forked sub-agent call to generate a Markdown review report; self-evolution analysis triggers an isolated LLM call each time a learning batch completes (default: once every 3 parent responses).

Q: Do self-evolution mode rules take effect automatically?

A: No. Learning results only generate pending review proposals that must be manually clicked Apply in the Self-evolution mode settings page to become approved rules, which are then injected into subsequent system prompts through a tagged <dsh-evolve-modes-learned-instructions> segment.

Q: What context from the parent session does the learning request read?

A: Learning requests are isolated: they use an independent persona and system prompt, don't inherit parent session history or parent agent working context, carry no tools, don't create learning sub-agents, and don't load the source working directory's AGENTS.md/CLAUDE.md.

Q: Where is data stored? How to uninstall?

A: Session-level state lives in graysilver_dsh_evolve_modes storage domain, while cross-session self-evolution rules/proposals/backups/learning records live in graysilver_dsh_evolve_modes_evolution domain; after uninstalling via dsh plugin remove, data remains in host storage.

Q: What's the relationship with DSH's built-in plan mode?

A: The plugin directly reuses the official @deepseek-ai/dsh-plan-mode service and exit_plan_mode approval flow, and limits available tools in plan mode through tools/pre-execute without implementing a duplicate plan system.

Q: Will old version session records migrate automatically?

A: Yes. 0.3.x copies data from graysilver_task_modes and graysilver_task_modes_evolution legacy domains, maps old single-mode aliases to new fields, and won't overwrite existing data in new domains.

Learning Curve

Entry-level — the control mounts directly to the input area with working defaults; only requires understanding the "four independent dimensions" mental model without configuring any host yaml.

Known Issues and Limitations

  • Platform shell is fully functional in plan mode, relying solely on prompt-based review agent suggestions not to modify files, not OS-level sandbox; configure restricted shell or external sandbox for process isolation (README.md:191-201 / README.en.md:109-111)
  • Each completed parent response with quality gate enabled adds one model call and corresponding delay, and reviews don't automatically run project test/lint/build (README.en.md:123)
  • Self-evolution analysis requires the session to have parsed provider and model, otherwise throws error and logs failure to learning runs (src/evolution/learning.ts:49-51)
  • Assistant messages only serve as context and cannot individually become rule evidence; when exceeding 2000 characters, only first and last 1000 are retained (src/evolution/messages.ts:4-16, README.md:91)
  • Approved rules are global and not bound to project directory; project-level scope no longer supported from 0.3.x (src/types.ts:21-23, README.en.md:103)
  • Each self-evolution analysis run uses the parent session's provider/model with no independent model routing configuration

Read the usage guide →

Install steps, key points, FAQ and compatibility for this plugin — auto-derived from indexed fields.

Listing badge

Listed on deepseek-plugin.org
[![Listed on deepseek-plugin.org](https://img.shields.io/badge/listed_on-deepseek--plugin.org-007EC6)](https://deepseek-plugin.org/plugins/GraySilver/dsh-task-modes)

Paste this markdown into your GitHub README to link back to this listing. The badge only states the listing — not a security endorsement.

← Back to plugin directory