Introduction

DeepSeek Harness (DSH) has a core philosophy: “everything is a plugin.” When handling complex tasks, processing them directly inside the main Agent can become chaotic, while blindly using sub-agents may lead to resource waste. We need a mechanism to answer three questions: when to delegate, how to delegate, and how to validate the returned results.

The dsh-subagent-delegation plugin is designed to solve these problems. It includes a set of skills that guide the main Agent on when to delegate work to sub-agents, how to distribute work in parallel, and how to validate the returned results.

Core Positioning

This is a DSH plugin that bundles a set of skills. It guides the main Agent on when to delegate work to sub-agents, how to distribute work in parallel, and how to validate the returned results. The plugin is maintained by gezi-wen.

Core Features

When to Delegate

The plugin has built-in decision logic to determine whether a task should be delegated. The main criteria are the three decision questions:

  1. It requires examining 5+ files
  2. It requires multiple rounds of search or research
  3. There are 2+ mutually independent sub-items

In addition, there is a “red card warning”: when encountering a “simple task” involving 5 files, delegation should also be triggered to prevent the main Agent from becoming overloaded.

Delegation Modes

DSH sub-agents do not have built-in Explore or general-purpose types. The shape of a sub-agent is entirely carried by the prompt. Developers need to write prompts for different modes according to task requirements, such as read-only exploration, general analysis, solution design, and independent review.

Parallelism and Background

Sending multiple subagent calls in the same message turn allows them to run in parallel. By default, subagent processes run in the background. If a task needs to see the context of the current conversation, use subagent_fork.

Validation Flow

Do not blindly trust the sub-agent’s summary. The core of validation is to check the “actual file changes” against the “evidence chain” provided by the sub-agent, ensuring that the results match expectations.

Installation and Enablement

Use the official command to install the plugin:

dsh plugin --profile web add dsh-subagent-delegation

During installation, the skills/ directory in the package is registered as a skills root and is placed into the Agent’s skills directory with the plugin.

Mechanism Description

The plugin is integrated through the cordis.patch.yml mechanism. Its mechanism is consistent with how DSH’s built-in agent preset loads skills.

In cordis.patch.yml, the baseUrl in !!js resolves to this package, so the path follows the installation location. Developers need to ensure that customSkillDirs points to the skills/ directory.

Notes

  1. DSH sub-agents do not have built-in types such as Explore / general-purpose; their shapes can only be carried by the prompt.
  2. Do not blindly trust the sub-agent’s summary; you must verify the actual file changes and the evidence chain it provides.

Conclusion

dsh-subagent-delegation provides a clear delegation and validation workflow, helping developers build more efficient and controllable DSH workflows.

GitHub Repository