Skip to main content

dsh_workflow

90Stars1Forks2Issues1Watchers

A named, persistent, background-running multi-agent workflow engine built on DSH, supporting save, pause, rerun, resume, generation, and audit.

Evidence5/5methodologySourceInstallMaintenanceDSH versionSecurity scan
Machine-auditedInstall commandRepo verifieddsh-plugin topicLicenseREADMEAI wiki
Language
TypeScript
License
MIT
Branch
main
agent-orchestrationdeepseek-harnessdshdsh-plugindshtopicmulti-agentworkflow

Install

cmdweb profile
$ dsh plugin --profile web add github:icetomoyo/dsh_workflow

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 icetomoyo/dsh_workflow for me: review the repository at https://github.com/icetomoyo/dsh_workflow 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

Layer a named, savable, pausable, rerunnable, auditable reusable Workflow engine on top of DeepSeek Harness (DSH)'s original workflow tool, transforming multi-Agent collaboration from one-off tricks into maintainable engineering assets.

Core Capabilities

  • Run named, saved multi-Agent workflows (project-level or personal-level catalogs), or invoke via /workflow <name> in conversation
  • Automatically orchestrate a reusable inline workflow from natural language requirements (scout-then-author)
  • Rerun from snapshot, resume from effect cache, pause/resume/stop runs, and retain immutable capsules for post-hoc traceability
  • Provide two built-in flows: parallel-investigation and scoped-review (including /workflow review command that automatically captures Git diff)
  • Expose three DSH tools: workflow_list (discovery), run_workflow (execution/generation/inline), workflow_manage (lifecycle management)
  • Run generative scripts in QuickJS WebAssembly isolated heap, only calling host via JSON capability bridge; statically reject import/process/files/network/timers

Technical Implementation

  • Language: TypeScript (built to ESM lib/*.js)
  • Key Dependencies: quickjs-emscripten (restricted script sandbox), @deepseek-ai/cordis (plugin injection), @deepseek-ai/schemastery (config schema)
  • Architecture Pattern: Cordis bundle patch — cordis.patch.yml declares dsh-external-workflow node; index.ts exports name + inject: ['subagents','tools'] + apply(ctx, config); runtime registers one /workflow command, three DSH tools, System Prompt paragraph, and mounts service/engine/catalog/runtime/store submodules via ctx.plugin(DynamicWorkflowService)
  • Entry File: src/index.ts (compiled to lib/index.js)

Use Cases

Suitable for teams that need to沉淀 multi-Agent collaboration flows for repeated use: save fixed processes like code reviews, parallel investigations, and competitor comparisons in the repository, avoiding repeatedly prompting "how to split tasks, how to parallelize, how to verify". Also suitable for developers who need to run workflows as long-running tasks or background jobs—the plugin returns { runId, status, jobId } by default,托管 by DSH background jobs, without occupying the current conversation.

Prerequisites & Compatibility

DependencyMinimum VersionDescription
DeepSeek Harness0.0.1-rc.2See commit pinned in compatibility.json; requires host to have all 12 peer packages: Cordis, subagent, agent, commands, jobs, llm, session, tools, workflow, user-approval, user-questions, system-prompt
Node.js22.19.0 (also supports >=24)From engines field in package.json; trusted-local .ts depends on Node 22's native erasable-syntax TypeScript
PlatformCross-platformNo os/cpu restrictions; pure JS code + WebAssembly sandbox
Native Modulequickjs-emscripten 0.32.0WASM form, target binary included in bundle, no local compilation needed

Installation

dsh plugin --profile web add github:icetomoyo/dsh_workflow

Configuration Options

ConfigTypeDescriptionDefault
approvalModeEnumApproval strategy: never / generated-and-local (default, only generated & local trusted flows go through one-time authorization) / alwaysgenerated-and-local
maxAgentsNatural numberMaximum Agents allowed within a single run (deployment cap)64
maxConcurrencyNatural numberGlobal concurrent sub-Agent cap8
maxRetainedRunsNatural numberAuto-retained recent terminal run count (active runs never cleaned)500
fastProvider / fastModelProvider / fastModel / fastMaxTokensString/Natural numberLightweight tier model routing (subagent transport + model provider + model + max tokens)spawn / empty / empty / 4096
balancedProvider / balancedModelProvider / balancedModel / balancedMaxTokensString/Natural numberBalanced tier model routingspawn / empty / empty / 8192
deepProvider / deepModelProvider / deepModel / deepMaxTokensString/Natural numberDeep tier model routingspawn / empty / empty / 16384
readOnlyAllowedToolsString arrayRead-only mode whitelist (intersection with parent Agent's real-time visible tools)read, read_image, glob, grep, lsp, skill, web_search
availableTools / availableMcp / availableSkillsString arrayDeployment capability manifest for capsule pre-check; requirements outside the manifest are rejected rather than silently degraded[]
projectDirectory / personalDirectory / runDirectoryPath stringProject-level catalog, personal-level catalog, persistent run output directory.dsh/workflows / workflows / .dsh/workflow-runs
listToolName / runToolName / manageToolNameStringNames of the three DSH toolsworkflow_list / run_workflow / workflow_manage
maxCapsuleBytesNatural numberMax size limit for single workflow file admission512000
maxCatalogEntriesNatural numberCatalog entry limit returned to callers200
maxResultCharsNatural numberResult summary character limit for rendering to user (full JSON still in run.json)50000
scriptSyncTimeoutMs / scriptWallTimeoutMsMillisecondsSync slice cap and wall-clock cap for sandboxed scripts10000 / 3600000
defaultProvider / synthesisProviderStringSub-Agent transport for default and synthesis phasesspawn / spawn
readOnlyDeniedToolsString arrayDeprecated difference set field; use readOnlyAllowedTools instead[]

Complete field definitions and "deployment adapter" registration (registerIsolationAdapter / registerVerificationAdapter / registerDispatchAdapter) see docs/CONFIGURATION.md.

FAQ

Q: Will this plugin take over DSH's built-in workflow tool?

A: No. The two coexist: DSH's built-in tool still handles "run several tasks in parallel this time," while this plugin handles "naming, persisting, reusing, and governing such processes." It injects as a Cordis bundle patch rather than replacing the core.

Q: Can it run out of the box after installation? Does it need extra configuration?

A: Yes. Out of the box—the config schema provides all defaults; common adjustments are approvalMode, maxAgents, maxConcurrency, the three-tier model routing (fast/balanced/deep), or appending additional read-only tools to readOnlyAllowedTools.

Q: How do I use the built-in code review flow?

A: Enter /workflow review in the session. The plugin will call git diff to capture current changes (defaults to comparing against main/master/develop, falls back to uncommitted content if all fail), then启动 the scoped-review flow. Parameters: --risk low|medium|high (risk routing), --requirement "..." (review constraints), --test-evidence "..." (existing test evidence), --wait (sync wait), -- followed by review focus.

Q: Is the generated script safe? Can it access my files?

A: By default, no. Generative scripts run in a QuickJS WebAssembly isolated heap, only calling the host via JSON capability bridge; static policy rejects import/require/process/files/Shell/network/timers/non-deterministic APIs. Sync duration, wall-clock, memory, and stack all have limits. However, trusted-local形态 inherits host Node permissions, and each execution requires explicit confirmation—do not mark untrusted third-party source as trusted-local.

Q: How do I pause, resume, or rerun a run?

A: Use /workflow command: pause|resume|stop controls the current active run; rerun reruns with the saved version, resume-run resumes from an immutable capsule snapshot (tasks hitting effect cache are skipped). Use corresponding action of workflow_manage tool on the model side.

Q: Where is persisted data stored? How do I clean it up?

A: Run outputs default to .dsh/workflow-runs/<run-id>/ in project root (contains run.json, events.jsonl, workflow.workflow.json, results/, artifacts/). Named workflows are in .dsh/workflows/ (project) or $DSH_HOME/workflows/ (personal). Use /workflow prune to preview/delete by count or time window; terminal runs are also auto-cleaned when exceeding maxRetainedRuns.

Q: Will uninstalling the plugin leave data behind?

A: Commands and tools stop registering, but already-written directories in the project remain. Reinstalling the plugin can continue accessing historical runs; to completely clear, delete .dsh/workflow-runs/ and .dsh/workflows/ directories.

Q: Can I write my own workflow for others to reuse?

A: Yes. Place .workflow.json (containing manifest + source + intent + requires + provenance) into project .dsh/workflows/ or personal directory; files not matching manifest.name, unknown fields, version incompatibility, symlink escape, and oversized files are all rejected at pre-check. Generative inline workflows can be auto-produced by the plugin via /workflow create <requirement>.

Difficulty Level

Intermediate — requires understanding DSH sub-agents, built-in tool naming, model routing, etc., but all configs have defaults; running /workflow list and /workflow parallel-investigation once per README.md shows the effect.

Known Issues & Limitations

  • trusted-local form .ts files depend on Node 22's native erasable-syntax TypeScript and Node module cache; DSH needs restart after modification; for transform-only syntax like enums/decorators or hot-reload, publish as .mjs/.js.
  • Nested workflows only support one layer; attempts at two layers are immediately rejected by WorkflowControlError.
  • /workflow create <request> and free-text requests do not accept --wait—their execution is taken over by the current Agent and must wait for current turn to end.
  • DSH's current sub-agent seam does not natively support existing-agent target, per-agent effort, or general worktree; related requests need deployment to register registerDispatchAdapter/registerIsolationAdapter, which explicitly fail when not registered.
  • Built-in verification covers "executed read tool evidence / Git workspace changes / pre/post fingerprints for each required path / final-text postconditions"; non-Git workspace or external authoritative evidence is supplemented by registerVerificationAdapter.
  • Only runs with generative capsules can save immutable script snapshots for rerun by run ID; runs with purely functional trusted-package/trusted-local cannot be saved from run ID.
  • dsh.workflow v1 capsules and KodaX capsules have no wire compatibility; external KodaX capsules will not be mistakenly executed.
  • DSH Web's left workspace collapses other sessions when "manual sort" is enabled and current workspace session exceeds 5 messages; new workflow sessions already belong to corresponding workspace, click "Expand remaining N sessions" or switch to "Recently Updated" sort.

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/icetomoyo/dsh_workflow)

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