# Agent Task Decomposition Planner

Breaks a broad goal into a structured set of sub-tasks an AI agent can execute step by step, with clear success criteria and handoff points for human review.

## Prompt

You are an AI agent architect who designs reliable, well-scoped task plans for autonomous or semi-autonomous agents.

High-level goal for the agent: {{goal_description}}
Tools/capabilities the agent has access to: {{available_tools}}
Constraints (what it must NOT do without approval): {{constraints}}

Do the following:
1. Break the goal into a sequential list of discrete sub-tasks, each specific enough that the agent knows exactly what 'done' looks like for that step.
2. For each sub-task, specify: the exact tool(s) needed, the expected output/artifact, and a clear success condition the agent (or a human) can check against.
3. Identify which sub-tasks are safe for the agent to complete fully autonomously, and which ones require a human-in-the-loop checkpoint before proceeding (e.g., anything irreversible, costly, or touching sensitive data).
4. Note likely failure points in the plan (steps where the agent is most likely to get stuck, loop, or need a fallback) and suggest a fallback action for each.

## Best for

Developers and product builders designing agent workflows (using frameworks like Claude Agent SDK, LangChain, or custom orchestration) who need a clear, checkable task plan before writing the actual agent logic.

## Compatible tools

- Claude
- ChatGPT

## How to use

- Describe the agent's overall goal and exactly which tools or APIs it has access to.
- List any hard constraints on what the agent must not do without approval.
- Use the sub-task breakdown as the literal step sequence to implement in your agent's logic or prompt chain.
- Build human-in-the-loop checkpoints at exactly the points flagged before deploying the agent for real use.

## Customization tips

- If you're using a specific agent framework, mention it so tool references match that framework's terminology.
- For multi-agent systems, ask for the plan to specify which sub-tasks should be handled by which specialized sub-agent.
- Request a version with estimated execution time per sub-task if you need to budget for latency or API costs.

## Example input

Goal: Research 20 potential leads for a B2B SaaS product and produce a ranked shortlist with contact info. Tools: web search, a CRM API, a spreadsheet writer. Constraints: Must not send any outreach messages without human approval.

## Example output

A sequential plan including sub-tasks like 'search for companies matching the ICP criteria' (web search, output: list of 30+ candidate companies, success: each has a verifiable website), 'enrich with contact info' (CRM API, output: contact records), and 'rank and write to spreadsheet' (spreadsheet writer, output: ranked shortlist file), with a flag that any step touching the CRM's write access needs human approval, and a noted failure point around ambiguous ICP matches with a fallback to flag for manual review instead of guessing.
