agentleFS
fatih-developerfatih-developer/fth-skills/skills/task-decomposer/SKILL.md

task-decomposer

Skill7 starsChanged 43 days agoMITView on GitHub

Break down large, complex, or ambiguous tasks into independent subtasks with dependency maps, execution order, and success criteria. Plan first, then execute step by step. Triggers on 'how should I do this', 'where do I start', 'plan the project', 'break it down', 'implement' or whenever a task involves multiple phases.

9 other projects use a version of this.

Adopted by

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

13 rules. 0 are common, 9 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 9

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Before decomposing, answer these questions:

    line 26
  2. Distinctive:

    Is anything unclear?: If so, ask one clarifying question — never multiple.

    line 31
  3. Distinctive:

    Do not generate subtasks until the task is clearly understood.

    line 34
  4. Distinctive:

    Optional (?): Not core, nice to have

    line 72
  5. Distinctive:

    Use mermaid for complex dependency graphs:

    line 84
  6. Distinctive:

    After approval, complete each subtask:

    line 106
  7. Very specific:

    Before starting, print a header: ### [#N] Task Name

    line 108
  8. Distinctive:

    Ask the user: "Continue or fix this first?"

    line 116
  9. Distinctive:

    Escalation rule: If 2 consecutive subtasks fail, stop automatically and ask:

    line 118
  10. Very specific:

    When all subtasks are done, present a summary using templates/task-summary.md.tmpl.

    line 130
  11. Distinctive:

    Do not decompose — respond directly when:

    line 136
  12. Very specific:

    Use templates/task-plan.md.tmpl for presenting the plan to the user.

    line 153
  13. Very specific:

    Use templates/task-summary.md.tmpl for the completion report.

    line 154

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Task Decomposer Protocol

Break a complex task into independently executable, verifiable subtasks. Produce a structured plan first, get approval, then execute step by step with progress tracking.


Workflow

1. Analyze the task
2. Decompose into subtasks (with dependency map)
3. Present the plan and get approval
4. Execute sequentially — complete each step before moving to next
5. Produce summary report

Step 1: Analyze the Task

Before decomposing, answer these questions:

  • What is the goal? What does success look like?
  • What is the scope? What is included, what is excluded?
  • Are there constraints? Technology, time, dependencies?
  • Is anything unclear? If so, ask one clarifying question — never multiple.
  • Domain Awareness Check: If the request matches a domain in the Ecosystem Index below, follow that ecosystem's workflow map (@ecosystem-<domain>) and build your Dependency Map from its steps. If the ecosystem skill is not installed, use the index as the plan skeleton. Never invent skills that are not listed.

Do not generate subtasks until the task is clearly understood.


Ecosystem Index

<!-- BEGIN GENERATED: ecosystem-index (generated from the ecosystem workflow map by build_ecosystems.py — do not edit by hand) -->
EcosystemDomainUse forWorkflows
@ecosystem-orchestrationAgent OrchestrationPlan, execute, recover, remember, and review multi-step agent work; connect external agents safely.orch-complex-task, orch-code-change, orch-resilience, orch-agent-connectivity, orch-knowledge
@ecosystem-reasoningReasoning, Planning Gates & PromptingClarify intent, stress-test plans, compare perspectives, and craft prompts, without stacking redundant question gates.reason-clarify, reason-decision, reason-plan-review, reason-prompting
@ecosystem-apiAPI DomainDesign, secure, scale, and evolve REST, GraphQL, gRPC, and event-driven APIs with a contract-first workflow.api-design, api-security-scale, api-evolution, api-production-readiness
@ecosystem-databaseDatabase DomainModel, secure, optimize, migrate, and operate SQL databases (PostgreSQL, MySQL, SQLite) with data integrity first.db-new-schema, db-performance, db-evolution, db-compliance, db-scaling
@ecosystem-mobileMobile App DomainArchitect, audit, release, and monitor iOS, Android, React Native, and Flutter apps.mobile-pre-release-audit, mobile-release, mobile-feature-architecture, mobile-post-launch
@ecosystem-webWeb, Design & DeliveryDesign product-grade web interfaces, keep design systems consistent, make sites visible to search and AI answer engines, and deploy them.web-foundations, web-build-page, web-visibility, web-review, web-de-slop, web-deploy
@ecosystem-productProduct & GrowthTake a product from focus to market: B2B go-to-market, naming, creative content, and discoverability.product-launch, product-naming, product-content
@ecosystem-securitySecurityAudit skills before deployment, guard agent runtimes against injection and exfiltration, and learn from incidents.sec-skill-audit, sec-runtime-guard, sec-full-lifecycle

Pick the ecosystem whose domain matches the request and follow its workflow map. If the ecosystem skill is not installed, use the workflow ids above as the plan skeleton and run each member skill directly, or install it with npx skills add fatih-developer/fth-skills --skill <ecosystem> after the user agrees. Never invent skills that are not listed.

<!-- END GENERATED: ecosystem-index -->

Step 2: Decompose into Subtasks

Each subtask must meet these criteria:

  • Atomic: Does one thing, contains no internal decision branches
  • Verifiable: You can definitively say "done" when completed
  • Independent (when possible): Can run without waiting for other subtasks
  • Has a concrete output: A file, a function, a document, a decision

Dependency Map

Define relationships between subtasks:

  • Sequential (->): B cannot start until A completes
  • Parallel (||): Can run simultaneously — no shared dependencies
  • Optional (?): Not core, nice to have

How to handle parallel steps: Group || steps together. Complete all steps in the group, then move to the next sequential step.

Group A (parallel): #1 || #2 || #3  -> complete all, then continue
Group B (sequential): #4 -> #5 -> #6

Dependency Visualization

Use mermaid for complex dependency graphs:

graph LR
    T1["#1 Data Model"] --> T3["#3 CRUD Operations"]
    T2["#2 DB Connection"] --> T3
    T3 --> T4["#4 API Endpoints"]
    T4 --> T5["#5 Tests"]

Step 3: Present the Plan

Show the plan to the user using the format in templates/task-plan.md.tmpl and ask for approval.

Do not start execution without explicit user approval.


Step 4: Execute Step by Step

After approval, complete each subtask:

  1. Before starting, print a header: ### [#N] Task Name
  2. Execute the task — write code, create files, research, document
  3. On completion, print: Completed: [what was produced]
  4. Move to the next subtask

On failure:

  • Explain the error
  • Suggest an alternative path
  • Ask the user: "Continue or fix this first?"

Escalation rule: If 2 consecutive subtasks fail, stop automatically and ask:

"2 consecutive steps failed. Should we review the plan together before continuing?"

Cross-Skill Integration

  • checkpoint-guardian: During execution, critical actions (file deletion, DB writes, deploys) should trigger risk assessment checkpoints.
  • multi-brain: For complex subtasks where the approach is unclear, use 3-perspective evaluation before committing to an implementation.

Step 5: Summary Report

When all subtasks are done, present a summary using templates/task-summary.md.tmpl.


When to Skip

Do not decompose — respond directly when:

  • Single-step, clear task ("translate this file", "fix this bug")
  • User already knows the steps and only wants execution
  • Task can be completed in under 3 minutes

See references/SKIP_CONDITIONS.md for the full decision matrix.


References

  • See references/PLAN_TEMPLATE.md for the plan output structure.
  • See references/EXAMPLES.md for worked examples including a real code output.
  • See references/SKIP_CONDITIONS.md for when to skip decomposition.

Templates

  • Use templates/task-plan.md.tmpl for presenting the plan to the user.
  • Use templates/task-summary.md.tmpl for the completion report.

🔗 Next Steps & Handoffs

<!-- BEGIN GENERATED: handoffs (generated from the ecosystem workflow map by build_ecosystems.py — do not edit by hand) -->

Ecosystem: @ecosystem-orchestration — Agent Orchestration.

Workflows:

  • Complex Task Execution Flow (orch-complex-task, step 1 of 6): next → @parallel-planner (optional).
  • Plan Hardening Flow (reason-plan-review, step 2 of 2, via @ecosystem-reasoning): last step → once it passes, complete the workflow and report the outcome.

Handoff contract: pass results to the next skill through an inline Handoff block in your reply with the fields skill, workflow, created_at, inputs, summary, and next (the handoff contract of @ecosystem-orchestration). If a next skill is not installed, continue with its step from the ecosystem map, or install it with npx skills add fatih-developer/fth-skills --skill <name> after the user agrees.

<!-- END GENERATED: handoffs -->

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.