# What Is Subagent-Driven-Development and How It Differs from Inline Plan Execution

> Explore subagent-driven-development, a runtime skill using isolated sub-agents and reviews, and contrast it with inline plan execution's sequential task running. Learn the key differences.

- Repository: [OpenAI/plugins](https://github.com/openai/plugins)
- Tags: deep-dive
- Published: 2026-06-11

---

**Subagent-driven-development is a runtime execution skill that dispatches isolated sub-agents to implement plan tasks with mandatory two-stage review, while inline execution runs tasks sequentially within the same session without sub-agent isolation.**

The **subagent-driven-development** skill in the OpenAI plugins repository transforms static implementation plans into autonomous, high-reliability workflows. Unlike traditional inline execution, this approach leverages isolated sub-agents and dual verification gates to ensure both spec compliance and code quality. According to the source code in `openai/plugins`, the skill serves as the recommended execution engine for the `writing-plans` skill, offering a robust alternative to the lightweight `executing-plans` inline method.

## Understanding the Subagent-Driven-Development Skill

### Core Architecture and Isolation

At runtime, the skill operates by dispatching a **fresh sub-agent for every task** defined in an implementation plan. Each sub-agent executes within its own isolated context, preventing context leakage and maintaining focus on a single objective. The controller coordinates these agents from the main session, managing status transitions including `DONE`, `DONE_WITH_CONCERNS`, `NEEDS_CONTEXT`, and `BLOCKED`. This architecture is defined in [`plugins/superpowers/skills/subagent-driven-development/SKILL.md`](https://github.com/openai/plugins/blob/main/plugins/superpowers/skills/subagent-driven-development/SKILL.md).

### Two-Stage Review Process

Every task undergoes mandatory dual verification before completion. First, a **spec-compliance review** sub-agent validates that the implementation matches the original specification. Second, a **code-quality review** sub-agent evaluates style, test coverage, and overall engineering standards. The controller only marks a task complete when both reviews return ✅, automatically triggering remediation cycles if either check fails.

### Model Selection and Integration

The skill implements intelligent model selection, recommending the cheapest capable model tier (**mechanical → standard → high-capability**) based on task complexity. It integrates with several other super-powers including `using-git-worktrees`, `writing-plans`, `requesting-code-review`, and `finishing-a-development-branch` to create a complete development pipeline that runs continuously without human intervention except for genuine blockers.

## Comparing Subagent-Driven-Development vs Inline Execution in Writing-Plans

The `writing-plans` skill generates detailed implementation plans and offers two distinct execution paths. The subagent-driven path uses the skill described above, while inline execution relies on the `executing-plans` skill.

**Subagent-Driven Execution** isolates each task in a dedicated sub-agent context with two-stage quality gates. This approach catches bugs early through rigorous verification but incurs higher sub-agent invocation costs.

**Inline Execution** (via `executing-plans`) runs all tasks sequentially within the same session without spawning sub-agents. Reviews are performed by the controller itself or through single-pass batch checkpoints, making it faster but more susceptible to context pollution and missed specification failures.

## Implementation Flow and Code Examples

The following pseudocode illustrates the controller logic for dispatching sub-agents as implemented in the skill:

```python
def dispatch_task(task):
    impl = spawn_agent("implementer-prompt.md", context=task.full_text)
    while True:
        status = impl.wait()  # DONE, NEEDS_CONTEXT, BLOCKED, etc.

        if status == "NEEDS_CONTEXT":
            impl.send(context_needed)
        elif status == "BLOCKED":
            handle_blocker(impl)
        elif status == "DONE":
            break
    
    # Spec compliance review

    spec_rev = spawn_agent("spec-reviewer-prompt.md", code=impl.output)
    while not spec_rev.approved():
        impl.send(spec_rev.feedback)
        spec_rev = spawn_agent("spec-reviewer-prompt.md", code=impl.output)
    
    # Code quality review

    quality_rev = spawn_agent("code-quality-reviewer-prompt.md", code=impl.output)
    while not quality_rev.approved():
        impl.send(quality_rev.feedback)
        quality_rev = spawn_agent("code-quality-reviewer-prompt.md", code=impl.output)
    
    mark_task_complete(task)

```

In contrast, inline execution via `executing-plans` follows a direct sequential pattern:

```markdown

# Executing a plan inline

1. Load `docs/superpowers/plans/2024-03-15-feature-x.md`
2. Review for questions → ask human if any
3. For each task:
   - Mark `in_progress`
   - Run each step exactly as written (e.g., `pytest tests/...`)
   - Mark `complete`
4. When all tasks done → invoke `finishing-a-development-branch`

```

## Summary

- **Subagent-driven-development** dispatches isolated sub-agents for each plan task with mandatory spec-compliance and code-quality reviews.
- **Inline execution** runs tasks sequentially within the current session using the `executing-plans` skill, sacrificing isolation for speed.
- The controller manages sub-agent statuses (`DONE`, `NEEDS_CONTEXT`, `BLOCKED`) and automates remediation cycles.
- Source specifications reside in [`plugins/superpowers/skills/subagent-driven-development/SKILL.md`](https://github.com/openai/plugins/blob/main/plugins/superpowers/skills/subagent-driven-development/SKILL.md) and [`plugins/superpowers/skills/executing-plans/SKILL.md`](https://github.com/openai/plugins/blob/main/plugins/superpowers/skills/executing-plans/SKILL.md).

## Frequently Asked Questions

### When should I choose subagent-driven-development over inline execution?

Choose subagent-driven-development when code quality and spec compliance are critical, as the two-stage review catches errors early despite higher computational costs. Use inline execution only for simple, low-risk changes where speed outweighs the need for rigorous verification.

### How does the controller handle sub-agents that report NEEDS_CONTEXT or BLOCKED?

When a sub-agent returns `NEEDS_CONTEXT`, the controller supplies missing information and resumes the task. If the status is `BLOCKED`, the escalation logic either retries with a higher-capability model or pauses execution for human intervention, ensuring the pipeline halts only for genuine obstacles.

### What files define the review prompts used by subagent-driven-development?

The review prompts are defined in [`implementer-prompt.md`](https://github.com/openai/plugins/blob/main/implementer-prompt.md), [`spec-reviewer-prompt.md`](https://github.com/openai/plugins/blob/main/spec-reviewer-prompt.md), and [`code-quality-reviewer-prompt.md`](https://github.com/openai/plugins/blob/main/code-quality-reviewer-prompt.md), located alongside the [`SKILL.md`](https://github.com/openai/plugins/blob/main/SKILL.md) in the `plugins/superpowers/skills/subagent-driven-development/` directory.

### Can subagent-driven-development integrate with existing Git workflows?

Yes, the skill is designed to integrate with `using-git-worktrees` and `finishing-a-development-branch`, automatically managing branch isolation and final code review before merging completed tasks.