К основному содержанию
скилл CX Codex

subagent-driven-development · nousresearch — скилл для Claude Code: как установить

Скилл subagent-driven-development делит план на задачи и отдаёт каждую свежему субагенту через delegate_task. Результат проверяют два ревью: на соответствие спеку и на качество кода.

MIT 106 установок ★ 265 216 обновлён 2026-10-25

Установить в Claude Code · Через Skills CLI (Vercel) Все способы и платформы ↓
npx skills add NousResearch/hermes-agent --skill subagent-driven-development -a claude-code
Открыть на GitHub

Что делает subagent-driven-development

Скилл читает файл плана один раз, вытаскивает из него все задачи и заводит список дел через todo. Дальше каждую задачу выполняет отдельный субагент-исполнитель, запущенный через delegate_task. Полный текст задачи и контекст проекта кладут прямо в промпт, сам файл плана исполнитель не читает.

Когда исполнитель закончил, работу смотрят два ревьюера по очереди. Первый сверяет код со спецификацией задачи и отвечает PASS или списком пробелов. Второй оценивает качество и выносит вердикт APPROVED или REQUEST_CHANGES. Порядок жёсткий: ревью качества не начинают, пока спек не прошёл. К следующей задаче не переходят, пока по текущей есть открытые замечания.

После последней задачи финальный ревьюер проверяет, как части работают вместе, затем прогоняют весь набор тестов и делают коммит. Задачи нужны мелкие, по 2-5 минут работы. Если они правят одни и те же файлы, запускать на них нескольких исполнителей нельзя. Упавшую задачу чинит новый субагент, а не основная сессия.

Какие задачи решает

  • выполнить готовый план задача за задачей, не копя контекст в одной сессии
  • сверить код со спецификацией задачи до разговора о стиле
  • поймать лишнее, чего в задаче не просили
  • получить вердикт APPROVED или REQUEST_CHANGES по каждому куску работы
  • проверить перед мержем, что части плана сходятся друг с другом

Примеры запросов агенту

  • Выполни план из docs/plans/feature-plan.md через скилл subagent-driven-development
  • Раздай задачи плана свежим субагентам и после каждой проведи ревью на спек и на качество
  • Используй subagent-driven-development: по субагенту на задачу, в конце общее ревью

Как установить subagent-driven-development

1Через Skills CLI (Vercel)

npx skills add NousResearch/hermes-agent --skill subagent-driven-development -a claude-code

2Вручную: положить файлы

~/.claude/skills/subagent-driven-development/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/subagent-driven-development/

По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов

Вопросы о subagent-driven-development

Как установить subagent-driven-development в Claude Code?

Выполните npx skills add NousResearch/hermes-agent --skill subagent-driven-development -a claude-code. Файл скилла окажется в ~/.claude/skills/subagent-driven-development/SKILL.md.

Что делает subagent-driven-development?

Берёт готовый план и отдаёт каждую задачу свежему субагенту через delegate_task. После каждой задачи идут два ревью, в конце общая проверка всей реализации.

Что нужно иметь перед запуском скилла?

План реализации, составленный скиллом plan или по требованиям пользователя. Скилл рассчитан на задачи, которые в основном независимы друг от друга.

Исходный текст

SKILL.md · MIT
---
name: subagent-driven-development
description: "Execute plans via delegate_task subagents (2-stage review)."
version: 1.1.0
author: Hermes Agent (adapted from obra/superpowers)
license: MIT
platforms: [linux, macos, windows]
metadata:
  hermes:
    tags: [delegation, subagent, implementation, workflow, parallel]
    related_skills: [requesting-code-review, test-driven-development]
---

# Subagent-Driven Development

## Overview

Execute implementation plans by dispatching fresh subagents per task with systematic two-stage review.

**Core principle:** Fresh subagent per task + two-stage review (spec then quality) = high quality, fast iteration.

## When to Use

Use this skill when:
- You have an implementation plan (from the `plan` skill or user requirements)
- Tasks are mostly independent
- Quality and spec compliance are important
- You want automated review between tasks

**vs. manual execution:**
- Fresh context per task (no confusion from accumulated state)
- Automated review process catches issues early
- Consistent quality checks across all tasks
- Subagents can ask questions before starting work

## The Process

### 1. Read and Parse Plan

Read the plan file. Extract ALL tasks with their full text and context upfront. Create a todo list:

```python
# Read the plan
read_file("docs/plans/feature-plan.md")

# Create todo list with all tasks
todo([
    {"id": "task-1", "content": "Create User model with email field", "status": "pending"},
    {"id": "task-2", "content": "Add password hashing utility", "status": "pending"},
    {"id": "task-3", "content": "Create login endpoint", "status": "pending"},
])
```

**Key:** Read the plan ONCE. Extract everything. Don't make subagents read the plan file — provide the full task text directly in context.

### 2. Per-Task Workflow

For EACH task in the plan:

#### Step 1: Dispatch Implementer Subagent

Use `delegate_task` with complete context:

```python
delegate_task(
    goal="Implement Task 1: Create User model with email and password_hash fields",
    context="""
    TASK FROM PLAN:
    - Create: src/models/user.py
    - Add User class with email (str) and password_hash (str) fields
    - Use bcrypt for password hashing
    - Include __repr__ for debugging

    FOLLOW TDD:
    1. Write failing test in tests/models/test_user.py
    2. Run: pytest tests/models/test_user.py -v (verify FAIL)
    3. Write minimal implementation
    4. Run: pytest tests/models/test_user.py -v (verify PASS)
    5. Run: pytest tests/ -q (verify no regressions)
    6. Commit: git add -A && git commit -m "feat: add User model with password hashing"

    PROJECT CONTEXT:
    - Python 3.11, Flask app in src/app.py
    - Existing models in src/models/
    - Tests use pytest, run from project root
    - bcrypt already in requirements.txt
    """,
    toolsets=['terminal', 'file']
)
```

#### Step 2: Dispatch Spec Compliance Reviewer

After the implementer completes, verify against the original spec:

```python
delegate_task(
    goal="Review if implementation matches the spec from the plan",
    context="""
    ORIGINAL TASK SPEC:
    - Create src/models/user.py with User class
    - Fields: email (str), password_hash (str)
    - Use bcrypt for password hashing
    - Include __repr__

    CHECK:
    - [ ] All requirements from spec implemented?
    - [ ] File paths match spec?
    - [ ] Function signatures match spec?
    - [ ] Behavior matches expected?
    - [ ] Nothing extra added (no scope creep)?

    OUTPUT: PASS or list of specific spec gaps to fix.
    """,
    toolsets=['file']
)
```

**If spec issues found:** Fix gaps, then re-run spec review. Continue only when spec-compliant.

#### Step 3: Dispatch Code Quality Reviewer

After spec compliance passes:

```python
delegate_task(
    goal="Review code quality for Task 1 implementation",
    context="""
    FILES TO REVIEW:
    - src/models/user.py
    - tests/models/test_user.py

    CHECK:
    - [ ] Follows project conventions and style?
    - [ ] Proper error handling?
    - [ ] Clear variable/function names?
    - [ ] Adequate test coverage?
    - [ ] No obvious bugs or missed edge cases?
    - [ ] No security issues?

    OUTPUT FORMAT:
    - Critical Issues: [must fix before proceeding]
    - Important Issues: [should fix]
    - Minor Issues: [optional]
    - Verdict: APPROVED or REQUEST_CHANGES
    """,
    toolsets=['file']
)
```

**If quality issues found:** Fix issues, re-review. Continue only when approved.

#### Step 4: Mark Complete

```python
todo([{"id": "task-1", "content": "Create User model with email field", "status": "completed"}], merge=True)
```

### 3. Final Review

After ALL tasks are complete, dispatch a final integration reviewer:

```python
delegate_task(
    goal="Review the entire implementation for consistency and integration issues",
    context="""
    All tasks from the plan are complete. Review the full implementation:
    - Do all components work together?
    - Any inconsistencies between tasks?
    - All tests passing?
    - Ready for merge?
    """,
    toolsets=['terminal', 'file']
)
```

### 4. Verify and Commit

```bash
# Run full test suite
pytest tests/ -q

# Review all changes
git diff --stat

# Final commit if needed
git add -A && git commit -m "feat: complete [feature name] implementation"
```

## Task Granularity

**Each task = 2-5 minutes of focused work.**

**Too big:**
- "Implement user authentication system"

**Right size:**
- "Create User model with email and password fields"
- "Add password hashing function"
- "Create login endpoint"
- "Add JWT token generation"
- "Create registration endpoint"

## Red Flags — Never Do These

- Start implementation without a plan
- Skip reviews (spec compliance OR code quality)
- Proceed with unfixed critical/important issues
- Dispatch multiple implementation subagents for tasks that touch the same files
- Make subagent read the plan file (provide full text in context instead)
- Skip scene-setting context (subagent needs to understand where the task fits)
- Ignore subagent questions (answer before letting them proceed)
- Accept "close enough" on spec compliance
- Skip review loops (reviewer found issues → implementer fixes → review again)
- Let implementer self-review replace actual review (both are needed)
- **Start code quality review before spec compliance is PASS** (wrong order)
- Move to next task while either review has open issues

## Handling Issues

### If Subagent Asks Questions

- Answer clearly and completely
- Provide additional context if needed
- Don't rush them into implementation

### If Reviewer Finds Issues

- Implementer subagent (or a new one) fixes them
- Reviewer reviews again
- Repeat until approved
- Don't skip the re-review

### If Subagent Fails a Task

- Dispatch a new fix subagent with specific instructions about what went wrong
- Don't try to fix manually in the controller session (context pollution)

## Efficiency Notes

**Why fresh subagent per task:**
- Prevents context pollution from accumulated state
- Each subagent gets clean, focused context
- No confusion from prior tasks' code or reasoning

**Why two-stage review:**
- Spec review catches under/over-building early
- Quality review ensures the implementation is well-built
- Catches issues before they compound across tasks

**Cost trade-off:**
- More subagent invocations (implementer + 2 reviewers per task)
- But catches issues early (cheaper than debugging compounded problems later)

## Integration with Other Skills

### With plan

This skill EXECUTES plans created by the `plan` skill:
1. User requirements → plan → implementation plan
2. Implementation plan → subagent-driven-development → working code

### With test-driven-development

Implementer subagents should follow TDD:
1. Write failing test first
2. Implement minimal code
3. Verify test passes
4. Commit

Include TDD instructions in every implementer context.

### With requesting-code-review

The two-stage review process IS the code review. For final integration review, use the requesting-code-review skill's review dimensions.

### With systematic-debugging

If a subagent encounters bugs during implementation:
1. Follow systematic-debugging process
2. Find root cause before fixing
3. Write regression test
4. Resume implementation

## Example Workflow

```
[Read plan: docs/plans/auth-feature.md]
[Create todo list with 5 tasks]

--- Task 1: Create User model ---
[Dispatch implementer subagent]
  Implementer: "Should email be unique?"
  You: "Yes, email must be unique"
  Implementer: Implemented, 3/3 tests passing, committed.

[Dispatch spec reviewer]
  Spec reviewer: ✅ PASS — all requirements met

[Dispatch quality reviewer]
  Quality reviewer: ✅ APPROVED — clean code, good tests

[Mark Task 1 complete]

--- Task 2: Password hashing ---
[Dispatch implementer subagent]
  Implementer: No questions, implemented, 5/5 tests passing.

[Dispatch spec reviewer]
  Spec reviewer: ❌ Missing: password strength validation (spec says "min 8 chars")

[Implementer fixes]
  Implementer: Added validation, 7/7 tests passing.

[Dispatch spec reviewer again]
  Spec reviewer: ✅ PASS

[Dispatch quality reviewer]
  Quality reviewer: Important: Magic number 8, extract to constant
  Implementer: Extracted MIN_PASSWORD_LENGTH constant
  Quality reviewer: ✅ APPROVED

[Mark Task 2 complete]

... (continue for all tasks)

[After all tasks: dispatch final integration reviewer]
[Run full test suite: all passing]
[Done!]
```

## Remember

```
Fresh subagent per task
Two-stage review every time
Spec compliance FIRST
Code quality SECOND
Never skip reviews
Catch issues early
```

**Quality is not an accident. It's the result of systematic process.**

## Further reading (load when relevant)

When the orchestration involves significant context usage, long review loops, or complex validation checkpoints, load these references for the specific discipline:

- **`references/context-budget-discipline.md`** — Four-tier context degradation model (PEAK / GOOD / DEGRADING / POOR), read-depth rules that scale with context window size, and early warning signs of silent degradation. Load when a run will clearly consume significant context (multi-phase plans, many subagents, large artifacts).
- **`references/gates-taxonomy.md`** — The four canonical gate types (Pre-flight, Revision, Escalation, Abort) with behavior, recovery, and examples. Load when designing or reviewing any workflow that has validation checkpoints — use the vocabulary explicitly so each gate has defined entry, failure behavior, and resumption rules.

Both references adapted from gsd-build/get-shit-done (MIT © 2025 Lex Christopherson).

© Hermes Agent (adapted from obra/superpowers) · MIT · NousResearch/hermes-agent

Похожие скиллы

Все скиллы по теме «Настройка агента: память, контекст, субагенты» →

Сначала — subagent-driven-development от других авторов.

subagent-driven-development Jesse Vincent Скилл subagent-driven-development выполняет план через отдельных субагентов для каждой задачи и проверяет результат после каждого шага. Подходит для независимых задач в одной сессии. CX Codex +1 237 746установок subagent-driven-development NeoLabHQ Скилл subagent-driven-development раздаёт задачи плана свежим субагентам и вставляет код-ревью между ними, чтобы не тащить грязный контекст через всю сессию. CX Codex +1 1 300установок subagent-delegation chrisbanes Скилл subagent-delegation для Claude Code структурирует процесс делегирования задач субагентам. Активируется при прямом вызове пользователем или инструкции по распределению работы. CX Codex +1 123установок test-driven-development Jesse Vincent Скилл test-driven-development для Claude Code задаёт цикл TDD: тест, проверка падения, минимальный код и рефакторинг. Цикл охватывает новые функции, исправления и изменения поведения. CX Codex +1 259 292установок development-skills hashgraph-online Плагин development-skills внедряет инженерный рабочий процесс с тремя уровнями риска, сохранением решений на диск и независимым ревью. CX Codex ★ 1 596звёзд репо constraint-driven-development addyosmani Скилл constraint-driven-development превращает размытые представления о качестве в письменный контракт проекта. Опрашивает вас, какие метрики важны, и записывает всё в CONSTRAINTS.md с числами, которые можно проверять автоматически. CX Codex +1 49 100установок behavior-driven-development FradSer Скилл behavior-driven-development задаёт BDD-процесс для фич, исправлений и тестов: сначала сценарий и падающий тест, затем код. CX Codex +1 151установок doubt-driven-development addyosmani Скилл doubt-driven-development отправляет нетривиальные решения на проверку свежему ревьюеру, который ищет слабые места. Пригодится перед сложными изменениями, когда ошибку трудно исправить позже. CX Codex +1 72 600установок

Из того же набора61

Весь набор →
document-to-action-items Скилл document-to-action-items для Claude Code, Codex, Cursor и других агентов: достаёт из документов обязательства, дедлайны и задачи с привязкой к странице источника. Каждый пункт трассируется обратно до конкретного файла и раздела. CX Codex +1 173установок blocked-page-recovery Скилл blocked-page-recovery для Claude Code ищет копии страницы при ответе 403 или 429, paywall или блокировке бота. Используется для сбора материалов и проверки источников. CX Codex +1 167установок weekly-review-planning Скилл weekly-review-planning для Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI и OpenCode ведёт структурированный еженедельный сброс: обязательства, зависшие проекты, план на следующую неделю. CX Codex +1 163установок meeting-action-items Скилл meeting-action-items для Claude Code превращает заметки или транскрипт встречи в список решений, ответственных и задач. Запускается, когда нужно разобрать протокол и подготовить follow-up. CX Codex +1 162установок sdlc-review Скилл sdlc-review для Claude Code независимо проверяет задачу, переданную исполнителем в колонку review на Kanban-доске, и принимает её, возвращает на доработку или передаёт человеку. CX Codex +1 162установок product-price-monitor Скилл product-price-monitor отслеживает итоговые цены товаров, авиабилетов и номеров в отелях, отсекая дубликаты и скрытые сборы. Присылает уведомление при достижении целевой стоимости. CX Codex +1 160установок pixel-art Скилл pixel-art превращает изображения в пиксель-арт с палитрами NES, Game Boy и PICO-8, а затем создаёт короткую анимацию с эффектами. CX Codex +1 138установок box Скилл box для Claude Code управляет файлами в облаке Box, общими папками, поиском и метаданными. CX Codex +1 111установок

Спонсоры проекта

Компании, которые помогают держать аналитику открытой