troykelly/claude-skills/worker-dispatch
Claude Code and agent skill by troykelly/claude-skills
- community
Checking that the SKILL.md file is still in the repository.
Use to spawn isolated worker processes for autonomous issue work. Uses Task tool with run_in_background for parallel execution and TaskOutput for monitoring. Pre-extracts context to minimize worker token usage.
Install
npx vskill@latest install troykelly/claude-skills/worker-dispatchSKILL.md
The same SKILL.md was published earlier as troykelly/claude-skills/worker-dispatch.
Worker Dispatch
Overview
Spawns and manages worker Claude agents using the Task tool with `run_in_background: true`. Workers run as parallel background agents monitored via TaskOutput.
Core principle: Workers are isolated, scoped, and expendable. State lives in GitHub, not in workers.
Key optimization: Pre-extract issue context BEFORE spawning. Workers receive focused context, not raw issues.
Worktree Isolation (MANDATORY)
CRITICAL: Every worker MUST have its own git worktree. Workers NEVER operate in the main repository.
Orchestrator responsibility: Create worktree BEFORE spawning worker. Worker responsibility: Verify isolation BEFORE any work (see worker-protocol).
This prevents file clobbering between parallel workers.
Worker Types
| Type | Subagent | Purpose | When to Use | |
|---|---|---|---|---|
| Implementation | general-purpose | Full feature work | Standard issue work | |
| Research | Explore | Read-only investigation | Pre-implementation analysis, debugging | |
| PR Resolution | general-purpose | Fix CI, merge PRs | Existing PR cleanup |
Pre-Extraction (CRITICAL)
Extract issue context BEFORE spawning. Workers should not spend tokens re-reading issues.
Spawning Implementation Workers
Step 1: Extract Context & Create Worktree
Step 2: Register in GitHub
Step 3: Construct Focused Prompt
~50 lines with pre-extracted context:
Step 4: Spawn Worker
Returns: task_id for monitoring.
Spawning Research Workers
Use Explore subagent for read-only investigation before implementation:
Use cases:
- Pre-implementation: "What patterns exist for similar features?"
- Debugging: "Where is this error originating?"
- Impact analysis: "What will this change affect?"
Parallel Dispatch
Spawn multiple workers in ONE message for concurrent execution:
Monitoring Workers
| Result | Meaning | Action | |
|---|---|---|---|
| "Task is still running..." | Worker active | Continue monitoring | |
| JSON with status | Worker complete | Parse result, update GitHub | |
| Error | Worker failed | Check GitHub for context |
Parse completion:
PR Workers
Resolve existing PRs (CI failures, missing reviews, merge):
Worker Cleanup
On completion (detected via TaskOutput):
Replacement Workers
When worker returns HANDOVER:
- Handover context is in issue comments (already posted by worker)
- Extract via:
extract_issue_context(includes HANDOVER variable) - Spawn replacement with attempt+1
- New worker receives full context automatically
Checklist
Before spawning:
- [ ] Issue context pre-extracted
- [ ] Worktree created on feature branch
- [ ] Worker registered in GitHub
- [ ] Project board status: In Progress
Prompt includes:
- [ ] Pre-extracted title and acceptance criteria
- [ ] JSON output format requirement
- [ ] Previous handover (if any)
- [ ] Recent progress comments
On completion:
- [ ] JSON result parsed
- [ ] GitHub state updated
- [ ] Project board status updated
- [ ] Task_id removed from active list
Integration
Used by: autonomous-orchestration, claude-autonomous --pr
Uses: worker-protocol (behavior contract), worker-handover (context format), ci-monitoring (PR workers)
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/worker-dispatch/SKILL.md
Popularity
- Repository stars
- 6
- 7-day trend score
- 10
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 8 Apr 2026, 7 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/troykelly/claude-skills/worker-dispatch)