agentsclimarketplace

Delegate

Skill mifunedev/skills/skills/delegate

A portable, cross-agent skill library for Claude Code and compatible AI agents.

Install
npx -y skills add mifunedev/skills --skill delegate

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Parallel execution coordinator. Decomposes a plan into discrete tasks, identifies parallelism via dependency analysis, and spawns worker sub-agents in waves to maximize throughput without sacrificing quality. Collects results, validates completeness, and reports a structured summary. TRIGGER when: asked to delegate work, execute a plan, parallelize tasks, "run this plan", "delegate this", or after /prd or plan creation.

SKILL.md

8.6 KB, as published. Nobody here has run it

Delegate

Parallel execution coordinator. Read a plan or conversation context, decompose it into a dependency-ordered task graph, and spawn worker sub-agents in parallel waves. Each wave completes before the next begins. Results are collected, validated, and reported.

Core principle: maximize parallelism while respecting dependencies absolutely.

Decision Flow

flowchart TD
    A["Resolve input: $ARGUMENTS or conversation context"] --> B{Plan found?}
    B -->|No| FAIL["Report: no plan found"]
    FAIL --> MEM_FAIL[Memory Protocol]

    B -->|Yes| C["Step 2: Deep-think task decomposition"]
    C --> D["Step 3: Build dependency graph"]
    D --> E["Step 4: Create tasks + compute waves"]
    E --> F{--dry-run?}
    F -->|Yes| DRY["Report: task graph + wave plan"]
    DRY --> MEM_DRY[Memory Protocol]

    F -->|No| G["Step 5: Execute Wave N"]
    G --> G1["Worker A"]
    G --> G2["Worker B"]
    G --> G3["Worker C"]
    G1 & G2 & G3 --> H{All passed?}
    H -->|No| I["Mark dependents BLOCKED, continue independent"]
    I --> J{More waves?}
    H -->|Yes| J
    J -->|Yes| G
    J -->|No| K["Step 6: Validate"]
    K --> L["Step 7: Report"]
    L --> MEM_OP[Memory Protocol]

Instructions

1. Resolve input

Arguments received: $ARGUMENTS

  • If --plan <path> is provided, read that file
  • If no arguments, use the current conversation context (the plan should be visible from a prior /prd, plan discussion, or issue triage output)
  • If --dry-run is present, set DRY_RUN=true

If no plan is found in either source, report:

No plan found. Provide a plan file path with --plan <path> or discuss the plan first, then run /delegate.

Run Memory Protocol and stop.

2. Decompose into tasks (use extended thinking)

Analyze the plan deeply and produce a structured task list. For each task, determine:

FieldDescription
IDSequential: T1, T2, T3, ...
TitleShort imperative description
DescriptionWhat the worker agent needs to do (2-3 sentences, include file paths)
Depends OnTask IDs this requires first, or "none"
FilesKey files the worker will read or modify
Modelhaiku (config/docs) / sonnet (standard, default) / opus (only multi-file architecture synthesis)
AcceptanceHow to verify the task is done (objectively checkable)

Decomposition rules:

  • Each task must be completable by a single sub-agent in one session
  • Prefer more smaller tasks over fewer larger ones
  • Schema/infrastructure before backend, backend before frontend
  • Tasks that touch different files with no shared state CAN be parallel
  • Tasks that modify the same file or depend on another's output MUST be sequential
  • Every task must have at least one verifiable acceptance criterion
  • Each task must have a distinct, non-overlapping scope — do not spawn redundant workers for the same files
  • A task that is itself multi-step and parallelizable MAY recursively delegate via the Agent tool — but only if the worker's task description includes explicit Max depth: N and Step budget: N fields (see context/rules/recursive-delegation.md). Absent those fields, workers stay flat.

3. Build dependency graph and compute waves

Arrange tasks into parallel execution waves using topological ordering:

  1. Wave 1: All tasks with Depends On: none -- run first, in parallel
  2. Wave 2: All tasks whose dependencies are entirely within Wave 1
  3. Wave N: All tasks whose dependencies are entirely within Waves 1..N-1

Output the wave plan:

WaveTasksParallelismComplexity
1T1, T2, T33 agentsS + S + M
2T4, T52 agentsM + S
3T61 agentL

Validation:

  • No circular dependencies (if found, report error and stop)
  • Max 5 concurrent agents per wave (split larger waves into sub-waves)

4. Create tasks and track dependencies

Use TaskCreate for each task. Then use TaskUpdate with addBlockedBy to wire dependencies.

If --dry-run, output the full task graph and wave plan, then skip to Step 8.

5. Execute waves

For each wave, starting from Wave 1:

a) Spawn worker agents in ONE message (parallel)

Launch N Agent tool calls in a single message for parallel execution. Each worker receives:

  • Task ID, title, description, files, and acceptance criteria
  • Summaries of completed prior-wave results (not full output)
  • Instruction: report what was done, what files changed, whether acceptance criteria are met

Worker configuration:

  • Model: as specified in the task decomposition (haiku/sonnet/opus)
  • run_in_background: true (for waves with 2+ tasks)

a.1) Recursion-authorization gate

If any worker's task description authorizes recursive delegation (Max depth: N with N ≥ 2), confirm before spawning that all three fields are present in that worker's briefing:

  • Max depth: N
  • Max children per level: M (M ≤ 5)
  • Step budget: S

If any field is missing, either add it or downgrade the task to flat execution (Max depth: 1). Workers without all three fields MUST stay flat — they have no authority to spawn grandchildren regardless of how the task is described in prose. See context/rules/recursive-delegation.md for the full protocol.

b) Collect results

After all agents in the wave complete, update each task via TaskUpdate:

TaskStatusSummaryFiles Changed
T1completedCreated schema migrationprisma/schema.prisma
T2completedAdded API routesrc/app/api/...
T3FAILType error in ...--

c) Handle failures

If any task fails:

  • Log the failure with details
  • Check if tasks in subsequent waves depend on the failed task
  • Mark dependent tasks as BLOCKED (do not execute them)
  • Continue with non-dependent tasks in the next wave

d) Advance to next wave

Pass completed task summaries as context to the next wave's workers. Repeat until all waves complete or all remaining tasks are blocked.

6. Validate

After all waves complete:

  1. Review acceptance criteria for every completed task
  2. If the plan involved code changes, run verification:
cd ~/harness && pnpm -r run lint 2>&1 || true
cd ~/harness && pnpm -r run build 2>&1 || true
cd ~/harness && pnpm -r run test 2>&1 || true
  1. If validation fails, note which tasks likely caused the failure

7. Report

Output a structured summary:

## Delegation Report

### Task Summary
| Task | Wave | Status | Summary |
|------|------|--------|---------|
| T1   | 1    | DONE   | ...     |
| T2   | 1    | DONE   | ...     |
| T3   | 1    | FAIL   | ...     |
| T4   | 2    | BLOCKED| Depends on T3 |

### Execution Stats
- Total tasks: N
- Completed: N
- Failed: N
- Blocked: N
- Waves executed: N
- Max parallelism: N agents

### Validation
- Type check: PASS/FAIL
- Lint: PASS/FAIL
- Tests: PASS/FAIL

### Issues Requiring Attention
- [list any failures, blocked tasks, or validation errors]

8. Memory Improvement Protocol

Run at the end of every execution -- op, dry-run, or error.

a) Log -- append to memory/<today>/log.md where today = date -u +%Y-%m-%d:

## Delegate -- HH:MM UTC
- **Result**: OP | DRY-RUN | PARTIAL | FAIL
- **Plan**: "<plan title or source>"
- **Action**: [N tasks across M waves, P parallel max; X completed, Y failed, Z blocked]
- **Duration**: ~Xs
- **Observation**: [one sentence]

See context/rules/memory.md for the canonical Memory Improvement Protocol.

Reference

Wave Execution Rules

RuleValue
Max concurrent agents per wave5 (split larger waves)
Failure handlingMark dependent tasks BLOCKED, continue independent ones
Context passingPrior wave summaries, not full output
Model selectionhaiku: config/docs, sonnet: standard (default), opus: synthesis only

Key Resources

ResourcePath
Agent: Implementer.claude/agents/implementer.md
Agent: Critic.claude/agents/critic.md
Agent: PM.claude/agents/pm.md
Agent: Council.claude/agents/council.md
IdentityIDENTITY.md
MemoryMEMORY.md
Daily Logsmemory/YYYY-MM-DD/log.md

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.