When developing DeepSeek Harness (DSH) agents, the main agent often needs to delegate specific steps to subagents after planning a task. Existing generic subagent configurations make it difficult to dynamically specify the model or reasoning effort at invocation time, leaving task execution and review lacking fine-grained control.
What Is This¶
dsh-delegation-workflow is a collaborative delegation workflow plugin maintained by Wh1stle05. It provides DeepSeek Harness with a delegate_with_model tool that implements a “main plan → subagent execute → main review” workflow, allowing the main agent to delegate planned steps to subagents and explicitly specify the subagent’s running model and reasoning effort.
Core Features¶
- Added tool
delegate_with_model: The main agent can use this tool to initiate delegation. - Parameter support: Supports
description(delegation description),prompt(subagent task instructions, without sharing the parent agent context),provider(subagent LLM backend),model(model ID),reasoning_effort(reasoning effort, with dynamic validation of supported levels), andrun_in_background(whether to run in the background). - Web command: Adds the
/delegate-modelslash command for selecting a model and reasoning effort in the Web interface. The configuration is persisted to$DSH_HOME/settings.yaml. - General settings: Adds a “Subagent Default Model” entry in general settings, with selectors for model and reasoning effort.
- Distinct from the built-in subagent: The plugin writes the caller-specified
providerandmodelinto the subagent’sAgentOptionsand injectsreasoning_effortbefore the subagent sends its first request, providing finer-grained control.
Installation and Enablement¶
Installing the plugin first requires DeepSeek Harness (dsh command) to be installed. The dsh plugin command forwards to pnpm underneath.
# 安装最新版
dsh plugin --profile web add github:Wh1stle05/dsh-delegation-workflow
# 或固定到某个版本 tag
dsh plugin --profile web add github:Wh1stle05/dsh-delegation-workflow#v0.2.1
# 本地开发 (link 到工作副本,改完源码重启 dsh 即生效)
dsh plugin --profile web add link:/path/to/dsh-delegation-workflow
After the plugin is installed, the repository-bundled cordis.patch.yml takes effect automatically. There is no need to manually repeat the insert in the profile’s cordis.patch.yml (a duplicate insert will create two plugins with the same name in the same entry list). To modify the default configuration (such as provider, model, or effort), use id: delegation-workflow in the profile’s cordis.patch.yml to target the override:
- id: delegation-workflow
config:
subagentProvider: spawn
provider: commandcode-ubuntu1
model: deepseek/deepseek-v4-pro
reasoningEffort: high
toolName: delegate_with_model
Typical Usage¶
Typical usage follows the “main plan → subagent execute → main review” flow:
- The main agent uses
todo_writeto break down the plan. - The main agent uses
delegate_with_modelto delegate the first step to a subagent, with parameters including the model and reasoning effort. - The subagent executes and returns the result.
- The main agent reviews the result against the plan until acceptance passes.
For specific workflow rules, see the AGENTS.md file.
Notes¶
- Process restart: Changes to the plugin source code (
src/) require restarting the dsh process to take effect. - Configuration hot reload: Configuration changes in
cordis.patch.ymlsupport hot reloading. - Concept distinction:
subagentProvideris the subagent execution backend (transport, registered bydsh-subagent-{spawn,fork}-in-process), whileprovideris the LLM model backend (e.g.,opencode-go). The two concepts are different and must not be mixed; otherwise, the errorno subagent provider registered for ...will occur. - Dependency management: Starting with v0.2.1, dependencies are specified as
peerDependenciesand resolved by the profile, avoiding import failures caused by mixing with the host’s packages.
Summary¶
This plugin enhances task delegation in DSH by explicitly controlling subagent models and reasoning effort. For more details, see its GitHub repository.