OpenViking
volcengine
Self-evolving Context Database for AI Agents. Unify Agent Memory, Knowledge RAG and Skills.
february2015/dsh-taskswarm
TaskSwarm (蜂群) — DeepSeek Harness 上的多智能体任务编排插件:waves/lanes 并行执行、git worktree 隔离、任务包与跨模型评审、崩溃可恢复 | Multi-agent task orchestration for DeepSeek Harness: waves/lanes parallel execution, git worktree isolation, task packets, cross-model review, crash recovery
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:february2015/dsh-taskswarm
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
⚠️ Temporary install notice (Aug 17–18, 2026): the npm package
dsh-taskswarmwas fully unpublished to clean up old versions and is subject to a 24-hour cool-down (npm's anti-squatting protection). For Aug 17 and Aug 18, install from GitHub:dsh plugin add https://github.com/february2015/dsh-taskswarm.gitStarting Aug 19, the npm package is back:dsh plugin add dsh-taskswarm. This notice will be removed then.
Multi-agent task orchestration for DeepSeek Harness (DSH).
TaskSwarm arranges a batch of tasks into dependency-ordered waves, runs multiple AI workers in parallel lanes isolated by git worktrees, then automatically reviews and merges their output.
蜂群 (fēngqún) is a swarm of bees: the queen directs, the workers each buzz on their own task in parallel — exactly what this project does: the supervisor plans the waves, then every worker advances in its own lane.
taskswarm/orch integration branchPROMPT.md (mission / steps / constraints) + STATUS.md (progress), giving workers durable memory across context resetsReview Level; PASS merges, REVISE sends it back for revision.taskswarm/config.json across restartstaskswarm/orch integration HEAD, so it inherits all previously merged output instead of re-inventing shared code/tswarm-check + npm run check:tasks surface malformed packets (bad IDs, missing steps/criteria) with actionable causes instead of silently skipping themtaskswarm/orch conflicts, an independent merger agent resolves the conflict semantically inside the orch worktree; unresolvable conflicts land the lane in a conflict state and pause the batch for supervisor interventionDSH's native subagent / workflow / goal are conversational, one-shot scheduling — great for
ad-hoc delegation. TaskSwarm is a project-level orchestration layer on top of them:
| DSH native subagents | TaskSwarm | |
|---|---|---|
| Task shape | one sentence in chat | task packets (PROMPT.md / STATUS.md) — versioned, batchable, reusable |
| Parallelism | manual | wave planning: dependency-topological waves, parallel lanes per wave |
| Isolation | shared workspace (writes collide) | git worktree isolation: per-lane branch + checkpoints, merged into taskswarm/orch |
| Quality gate | none | independent Reviewer (PASS / REVISE) |
| Resumability | gone when the process ends | durable batch state (.taskswarm/batches/*.json): restart / resume / skip finished lanes |
| Observability | watch the chat | supervisor event reports + Web Dashboard, auto-started with the batch, link printed in chat |
# npm registry
dsh plugin --profile web add dsh-taskswarm
# GitHub
dsh plugin --profile web add https://github.com/february2015/dsh-taskswarm.git
# Local directory (development / offline)
git clone https://github.com/february2015/dsh-taskswarm.git && cd dsh-taskswarm
npm install && npm run build
dsh plugin --profile web add $(pwd)
Restart dsh web after installing — the plugin takes effect on boot.
Upgrading an existing install:
dsh plugin --profile web add dsh-taskswarmreports "Already up to date" and stays on the old version when the lockfile version already satisfies the declared range. Pin the new version explicitly:dsh plugin --profile web add dsh-taskswarm@<new-version>(or runpnpm update --latestin the profile directory), then restart dsh web.
/tswarm-init # creates two example task packets (EXAMPLE-001 / EXAMPLE-002)
/tswarm-plan all # shows tasks grouped into waves by dependency
/tswarm all # run all tasks in parallel; or target one: /tswarm EXAMPLE-002
/tswarm-status # watch progress anytime
Starting a batch (/tswarm) auto-starts the dashboard and prints its link in the
session, so you can watch progress while waves run. Manual control is still available:
# from a DSH session (supervisor command)
/tswarm-dashboard
# or standalone CLI — after installing the plugin, the bin is on PATH:
npx taskswarm-dashboard --root <repo>
# or without installing anything, fetched on the fly (after npm publish):
npx --package dsh-taskswarm taskswarm-dashboard --root <repo> [--port 8100] [--no-open]
One dashboard per workspace: if one is already running for the same repo (started manually or left over from an earlier session), it is detected and reused — a second instance is never spawned.
Four roles are orchestrated:
| Role | Responsibility |
|---|---|
| Supervisor | Plans waves, schedules lanes, handles events, talks to you (the session that ran /tswarm) |
| Worker | One DSH agent per task, advancing its task packet step by step in an isolated lane worktree |
| Reviewer | Independent agent reviewing worker output, emitting PASS / REVISE |
| Merger | Merges finished lane output into the taskswarm/orch integration branch |
Git model:
taskswarm/orch ← integration branch: all lane output lands here (persistent — don't delete)
taskswarm/<taskId> ← per-lane working branch (holds step checkpoints; removed after merge)
Durable state (<repo>/.taskswarm/):
.taskswarm/batches/<batchId>.json # single source of truth for a batch (phase + lanes)
.taskswarm/mailbox/<batchId>/ # agent-to-agent messages
.taskswarm/worktrees/_orch/ # integration worktree
.taskswarm/worktrees/<taskId>/ # per-lane isolated worktrees
| Command | Action |
|---|---|
/tswarm [scope] |
Start a batch (scope: all / task id / path) |
/tswarm-plan [scope] |
Preview wave plan and dependency graph (no execution) |
/tswarm-status |
Show current batch / lane progress |
/tswarm-pause / /tswarm-resume |
Pause after the current wave / resume. A failed lane also auto-pauses after the wave (pauseOnLaneFailure, on by default) — resume then skips the failed lane; rerun it with /tswarm <taskId> |
/tswarm-stop-lane <taskId> |
Stop one lane immediately (kill worker, mark failed, preserve worktree/checkpoints); sibling lanes continue, the batch pauses after the wave |
/tswarm-switch-model <taskId> <model> |
Switch one lane to a different model: stop it, record the override, auto-rerun from the next step (checkpoints preserved). Override > workerModel > parent-session default |
/tswarm-abort |
Abort after the current wave (kills running lanes) |
/tswarm-deps [scope] |
Show the dependency graph |
/tswarm-sessions |
List active lanes and their worktrees |
/tswarm-integrate |
Merge taskswarm/orch into the current working branch |
/tswarm-dashboard |
Start the Web Dashboard |
/tswarm-init [ID] |
Scaffold example task packets |
Compatible aliases:
/orch,/orch-statusand other/orch-*commands are equivalent.
cordis.patch.yml are hot-reloaded by DSH without a restart. Caveat: reloading the orchestrator plugin (e.g. editing its config row) aborts all running batches via its unload cleanup — do not touch orchestrator config while a batch is running.cordis-plugin-hmr is disabled by default); source changes require npm run build followed by a dsh web restart..taskswarm/ disk state + checkpoints + lane branches persist; check /orch-status afterwards and resume/rerun failed lanes through the supervisor without losing completed work.Supervisor notifications are designed to save tokens without losing information:
Complete, localized messages — every notification (periodic report, wave complete, lane failed, stalled, batch complete) is already written in full, human-readable language (Chinese or English per the session locale), e.g.:
[TaskSwarm] ⏱️ 定时汇报(每 5 分钟):
批次 b-msvinu6n — running(已完成 1/4)· 波次 1/2
lane 1 [已合并] JM-402 · 步骤 8/8,218 步
The supervisor agent never re-translates or restates them — the system prompt explicitly tells it: notifications are already complete and readable; do NOT translate or repeat them; judge only whether there is an anomaly or an action needed — if yes, handle/report briefly; if no, stay quiet or acknowledge in one short line. This is what actually saves tokens: the notification itself is written once in the cheapest place (the engine), and the model does not burn tokens re-explaining it back to the user.
The design principle: don't shrink the message, eliminate the re-explanation. A terse message forces the model to translate/expand it (expensive); a complete message lets the user read it directly and lets the model act only on anomalies.
TaskSwarm exposes a standard Cordis service for other DSH plugins:
const taskswarm = ctx.get('taskswarm')
const { batches } = taskswarm.getSnapshot()
Each batch includes ownerSessionId, so plugins like dsh-dingo can show a “waiting for background/subtasks/swarm” state on the main session card while the batch is still running.
This makes it possible to see “main conversation finished, but the swarm is still working” directly in the dsh-dingo card panel.
Clean card list — TaskSwarm's internal worker/reviewer/merger sessions never appear as user cards in dsh-dingo: no purple draft counts, no stray cards, no reminders from sub-agents. Only the main session that started the batch shows as a user card (with the "waiting for swarm" state).
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: git-worktree、multi-agent。