LogoSkills

product:team-dev

Executes the Team Development workflow as the Team Lead.

ํ•ญ๋ชฉ๋‚ด์šฉ
Invoke/team-dev

/team-dev โ€” ์—ฌ๋Ÿฌ ์ž‘์—…์„ ๋™์‹œ์— ์ง„ํ–‰ํ•˜๋Š” "ํŒ€์žฅ"#

ํ•œ๋งˆ๋””๋กœ#

์„œ๋กœ ์˜ํ–ฅ์„ ์ฃผ์ง€ ์•Š๋Š” ์—ฌ๋Ÿฌ ์—…๋ฌด(์Šคํ† ๋ฆฌ)๋ฅผ ์—ฌ๋Ÿฌ ๋ช…์—๊ฒŒ ๋™์‹œ์— ๋‚˜๋ˆ  ๋งก๊ฒจ ํ•œ๊บผ๋ฒˆ์— ์ฒ˜๋ฆฌํ•˜๋Š” ๋ช…๋ น์ž…๋‹ˆ๋‹ค. ํ•œ ๋ช…์ด ์ผ์„ ์ˆœ์„œ๋Œ€๋กœ ์ฒ˜๋ฆฌํ•˜๋Š” ๋Œ€์‹ , ํŒ€์žฅ์ด ์ผ์„ ๊ฒน์น˜์ง€ ์•Š๊ฒŒ ๋‚˜๋ˆ  ์ฃผ๊ณ  ์—ฌ๋Ÿฌ ์ง์›์ด ๋™์‹œ์— ์ผํ•˜๋Š” ๊ฒƒ๊ณผ ๊ฐ™์•„์š”.

๋ˆ„๊ฐ€ยท์–ธ์ œ ์“ฐ๋‚˜์š”#

  • ํ•œ ์Šคํ”„๋ฆฐํŠธ ์•ˆ์— ์„œ๋กœ ๋…๋ฆฝ์ ์ธ(์„œ๋กœ ์˜์กดํ•˜์ง€ ์•Š๋Š”) ์ž‘์—…์ด 2๊ฐœ ์ด์ƒ ์ค€๋น„๋˜์–ด ์žˆ์„ ๋•Œ
  • ํ•œ ๊ฑด์”ฉ ์ˆœ์„œ๋Œ€๋กœ ์ฒ˜๋ฆฌํ•˜๊ธฐ์—” ์‹œ๊ฐ„์ด ์•„๊นŒ์›Œ, ๋™์‹œ์— ๋น ๋ฅด๊ฒŒ ๋๋‚ด๊ณ  ์‹ถ์„ ๋•Œ

๐Ÿ‘‰ ์ด ๋ช…๋ น ๋Œ€์‹  ๋‹ค๋ฅธ ๊ฑธ ์จ์•ผ ํ•˜๋Š” ๊ฒฝ์šฐ: ๋™์‹œ์— ๋Œ๋ฆด ๋งŒํผ ๋…๋ฆฝ์ ์ธ ์ž‘์—… ๋ฌถ์Œ์ด 1๊ฐœ๋ฟ์ด๋ฉด ๊ตณ์ด ํŒ€์„ ๊พธ๋ฆฌ๋Š” ๋น„์šฉ์ด ์•„๊น์Šต๋‹ˆ๋‹ค. ์ด ๊ฒฝ์šฐ ๋ช…๋ น์ด ํ•œ ๊ฑด์”ฉ ์ฒ˜๋ฆฌํ•˜๋Š” /dev-story๋ฅผ ๊ถŒํ•ฉ๋‹ˆ๋‹ค.

๐Ÿ‘‰ ์‚ฌ์ „ ์ค€๋น„: "Agent Teams"๋ผ๋Š” ์‹คํ—˜์  ๊ธฐ๋Šฅ์ด ์ผœ์ ธ ์žˆ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค(CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1). ๊บผ์ ธ ์žˆ์œผ๋ฉด ๋ช…๋ น์ด ๋ฉˆ์ถ”๊ณ  /dev-story๋ฅผ ์•ˆ๋‚ดํ•ฉ๋‹ˆ๋‹ค.

๋ฌด์—‡์„ ํ•ด์ฃผ๋‚˜์š”#

์—ฌ๋Ÿฌ ์Šคํ† ๋ฆฌ์— ๋Œ€ํ•œ ์‹ค์ œ ๋™์ž‘ํ•˜๋Š” ์ฝ”๋“œ๊ฐ€ ๋งŒ๋“ค์–ด์ง€๊ณ , ๊ฐ ์ž‘์—…๋งˆ๋‹ค PR(์ฝ”๋“œ ๊ฒ€ํ†  ์š”์ฒญ) ์ด ์—ด๋ฆฌ๋ฉฐ, ์Šคํ”„๋ฆฐํŠธ ํ˜„ํ™ฉ์ด ์ž๋™์œผ๋กœ ๊ฐฑ์‹ ๋ฉ๋‹ˆ๋‹ค.

  • ์ž‘์—…๋“ค์ด ๊ฒน์น˜์ง€ ์•Š๋„๋ก ๋‹ด๋‹น๊ณผ ํŒŒ์ผ ์˜์—ญ์„ ๋‚˜๋ˆˆ ๋ฐฐ์ •ํ‘œ
  • ์ž‘์—…๋ณ„ ๋ธŒ๋žœ์น˜ ๊ตฌ์กฐ(์—ํ”ฝ ๋ธŒ๋žœ์น˜ ์•„๋ž˜ ์Šคํ† ๋ฆฌ ๋ธŒ๋žœ์น˜)
  • ์™„๋ฃŒ๋œ ์ž‘์—…๋งˆ๋‹ค ํ’ˆ์งˆ ๊ฒ€์‚ฌ(lint, ํƒ€์ž… ์ฒดํฌ, ํ…Œ์ŠคํŠธ) ํ†ต๊ณผ ์—ฌ๋ถ€
  • ZenHub ๋ณด๋“œ์˜ ์ƒํƒœ ์ด๋™(์ง„ํ–‰ ์ค‘ โ†’ ๊ฒ€ํ† /QA)
  • ์˜์กด์„ฑ ๋•Œ๋ฌธ์— ๋™์‹œ์— ๋ชป ๋Œ๋ฆฐ ์ž‘์—…์€ "์ˆœ์ฐจ ๋Œ€๊ธฐ์—ด" ๋กœ ๋”ฐ๋กœ ์•ˆ๋‚ด

์–ด๋–ป๊ฒŒ ์“ฐ๋‚˜์š”#

# ๋™์‹œ ๊ฐœ๋ฐœ ์‹œ์ž‘ (ํŒ€์žฅ ์—ญํ• ๋กœ ์‹คํ–‰)
/team-dev

# ๋™์‹œ์— ๋ชป ๋Œ๋ฆฌ๋Š”, ์„œ๋กœ ์˜์กดํ•˜๋Š” ์ž‘์—…์€ ํ•œ ๊ฑด์”ฉ ์ฒ˜๋ฆฌ
/dev-story STORY-003

/team-dev๋Š” ๋ณ„๋„ ์˜ต์…˜ ์—†์ด ์‹คํ–‰ํ•˜๋ฉฐ, ๋™์‹œ์— ๋ช‡ ๋ช…๊นŒ์ง€ ์ผํ• ์ง€๋Š” ์„ค์ •๊ฐ’ agent_teams.max_teammates(๊ธฐ๋ณธ 3๋ช…)๋กœ ์ •ํ•ด์ง‘๋‹ˆ๋‹ค. ๋ฐฐ์ • ๊ณ„ํš์„ ๋งค๋ฒˆ ํ™•์ธ ์—†์ด ์ž๋™ ์Šน์ธํ•˜๋ ค๋ฉด ์„ค์ •๊ฐ’ agent_teams.auto_approve_plans๋ฅผ ์ผœ๋ฉด ๋ฉ๋‹ˆ๋‹ค.

์•ˆ์—์„œ ๋ฌด์Šจ ์ผ์ด ๋ฒŒ์–ด์ง€๋‚˜์š”#

  1. ์ค€๋น„ ์ ๊ฒ€ โ€” ์„ค์ •๊ณผ ์Šคํ”„๋ฆฐํŠธ ํ˜„ํ™ฉ์„ ๋ถˆ๋Ÿฌ์˜ค๊ณ , ๋™์‹œ ์ž‘์—… ๊ธฐ๋Šฅ(Agent Teams)์ด ์ผœ์ ธ ์žˆ๋Š”์ง€ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค. ๊บผ์ ธ ์žˆ์œผ๋ฉด ๋ฉˆ์ถ”๊ณ  ํ•œ ๊ฑด์”ฉ ์ฒ˜๋ฆฌํ•˜๋Š” ๋ฐฉ๋ฒ•์„ ์•ˆ๋‚ดํ•ฉ๋‹ˆ๋‹ค. ์‹œ์ž‘ํ•  ์ˆ˜ ์žˆ๋Š” ํ›„๋ณด ์ž‘์—…๋“ค์„ ์ถ”๋ฆฝ๋‹ˆ๋‹ค.
  2. ๋™์‹œ ์ฒ˜๋ฆฌ ๋ถ„์„ โ€” ์ž‘์—…์„ ์—ํ”ฝ๋ณ„๋กœ ๋ฌถ๊ณ , ์„œ๋กœ ์˜์กดํ•˜๊ฑฐ๋‚˜ ๊ฐ™์€ ํŒŒ์ผ์„ ๊ฑด๋“œ๋ฆฌ๋Š” ์ž‘์—…์„ ๊ณจ๋ผ๋ƒ…๋‹ˆ๋‹ค. ๊ฒน์น˜์ง€ ์•Š๋Š” ๋…๋ฆฝ ๋ฌถ์Œ๋งŒ ๋™์‹œ์— ๋Œ๋ฆฌ๊ณ , ๋‚˜๋จธ์ง€๋Š” ์ˆœ์ฐจ ๋Œ€๊ธฐ์—ด๋กœ ๋ณด๋ƒ…๋‹ˆ๋‹ค.
  3. ๋ฐฐ์ • ๊ณ„ํš ์ œ์‹œ โ€” ๋ˆ„๊ฐ€ ์–ด๋–ค ์ž‘์—…๊ณผ ํŒŒ์ผ์„ ๋งก์„์ง€ ํ‘œ๋กœ ๋ณด์—ฌ ์ฃผ๊ณ  ์‚ฌ์šฉ์ž์—๊ฒŒ ์ง„ํ–‰ ์—ฌ๋ถ€๋ฅผ ํ™•์ธ๋ฐ›์Šต๋‹ˆ๋‹ค(์ž๋™ ์Šน์ธ ์„ค์ • ์‹œ ์ƒ๋žต).
  4. ๋ธŒ๋žœ์น˜ ์ƒ์„ฑ โ€” ์—ํ”ฝ ๋ธŒ๋žœ์น˜์™€ ๊ทธ ์•„๋ž˜ ์Šคํ† ๋ฆฌ ๋ธŒ๋žœ์น˜๋“ค์„ ๋งŒ๋“ค์–ด ์ž‘์—… ๊ณต๊ฐ„์„ ๋ถ„๋ฆฌํ•ฉ๋‹ˆ๋‹ค.
  5. ์ž‘์—… ๋ถ„๋ฐฐยท์‹คํ–‰ โ€” ๊ณต์œ  ์ž‘์—… ๋ชฉ๋ก์„ ๋งŒ๋“ค๊ณ  ๋‹ด๋‹น์ž(teammate)๋“ค์„ ๋„์›Œ ๋™์‹œ์— ๊ฐœ๋ฐœ์„ ์‹œ์ž‘ํ•˜๋ฉฐ, ZenHub ๋ณด๋“œ๋ฅผ "์ง„ํ–‰ ์ค‘"์œผ๋กœ ์˜ฎ๊น๋‹ˆ๋‹ค.
  6. ์ง„ํ–‰ ๋ชจ๋‹ˆํ„ฐ๋ง โ€” ๊ฐ ๋‹ด๋‹น์ž์˜ ์ง„ํ–‰ ์ƒํ™ฉ์„ ํ™•์ธํ•˜๊ณ , ์™„๋ฃŒ๋  ๋•Œ๋งˆ๋‹ค ํ’ˆ์งˆ ๊ฒ€์‚ฌ๋ฅผ ๋Œ๋ ค ํ†ต๊ณผํ•œ ์ž‘์—…๋งŒ ๋ฐ›์•„๋“ค์ด๊ณ  ํ˜„ํ™ฉ์„ ๊ฐฑ์‹ ํ•ฉ๋‹ˆ๋‹ค.
  7. ๊ฒฐ๊ณผ ์ •๋ฆฌ โ€” ๋ชจ๋“  ์ž‘์—…์ด ๋๋‚˜๋ฉด ์Šคํ† ๋ฆฌ๋ณ„๋กœ PR์„ ์—ด๊ณ , ์™„๋ฃŒ ์š”์•ฝ๊ณผ ์ˆœ์ฐจ ๋Œ€๊ธฐ์—ด์— ๋‚จ์€ ์ž‘์—…์„ ์ •๋ฆฌํ•ด ๋ณด์—ฌ ์ค๋‹ˆ๋‹ค.

โš™๏ธ ์ƒ์„ธ ์˜ต์…˜ยท์‹คํ–‰ ๋ช…์„ธ (๊ฐœ๋ฐœ์ž / AI ์—์ด์ „ํŠธ์šฉ)

Workflow Overview#

Goal: Develop multiple stories in parallel using Agent Teams

Phase: 4 - Implementation (Parallel Execution)

Agent: Team Lead

Inputs: Sprint plan with stories, architecture document

Output: Working code for multiple stories, PRs created, sprint status updated

Duration: Varies by story count and complexity

Required for: Projects with 2+ independent stories ready for development

Prerequisite: Agent Teams must be enabled (CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1)


Pre-Flight#

  1. Load context per helpers.md#Combined-Config-Load
  2. Load sprint status per helpers.md#Load-Sprint-Status
  3. Check Agent Teams per helpers.md#Check-Agent-Teams-Available
  4. If teams_available = false:
    • Output:
            โš  Agent Teams not available.
      
      Agent Teams is an experimental feature that requires:
        CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1
      
      Sequential alternative:
        Use /dev-story STORY-{ID} to develop stories one at a time.
      
    • Stop workflow (do not proceed)
  5. Load architecture (if Level 2+): Read .bmad/architecture-*.md
  6. Load ZenHub context per helpers.md#Load-ZenHub-Context
  7. Identify candidate stories:
    • Find all stories with status "not_started" or "defined" in sprint status
    • If no stories available: inform user and stop
  8. Load max_teammates from config agent_teams.max_teammates (default: 3)
  9. Load sub-tasks (if zh_sub_tasks_enabled):
    • For each candidate story, check for sub_tasks[] in sprint status
    • Sub-tasks will be included in teammate context as implementation checklist

Part 1: Parallelization Analysis#

Analyze stories for parallel execution:

  1. Group stories by epic:

        Epic 1: [STORY-001, STORY-002, STORY-003]
    Epic 2: [STORY-004, STORY-005]
    
  2. Check dependencies:

    • Read each story's dependencies from sprint status or story documents
    • Build dependency graph
    • Identify independent groups (no cross-dependencies)
  3. Calculate file ownership boundaries:

    • From architecture document, map epics to source directories
    • Ensure no overlap between teammate file sets
    • If overlap detected: move overlapping stories to sequential queue
  4. Determine optimal teammate count:

    • Count independent story groups
    • Cap at max_teammates
    • If only 1 group: suggest /dev-story instead and ask user
  5. Display analysis:

        Parallelization Analysis:
    
    Independent Groups: {count}
    Total Stories: {count}
    Sequential Queue: {count} (due to dependencies or file overlap)
    
    Group 1: Epic  " {name} " 
       Stories: STORY-001, STORY-002
      Files: src/auth/*, src/middleware/auth/*
      Points: {total}
    
    Group 2: Epic  " {name} " 
       Stories: STORY-004, STORY-005
      Files: src/catalog/*, src/api/products/*
      Points: {total}
    
    Teammates needed: {count}
    

Part 2: Assignment Plan#

Present assignment plan to user:

Proposed Teammate Assignments:

Teammate 1 (Developer):
  Stories: STORY-001, STORY-002
  Epic: {epic_name}
  File Ownership: src/auth/*, tests/auth/*
  Branch: story/STORY-001-{slug}, story/STORY-002-{slug}
  Epic Branch: epic/EPIC-{num}-{slug}
  Sub-tasks: {count} (as implementation checklist)  โ† if sub-tasks exist

Teammate 2 (Developer):
  Stories: STORY-004, STORY-005
  Epic: {epic_name}
  File Ownership: src/catalog/*, tests/catalog/*
  Branch: story/STORY-004-{slug}, story/STORY-005-{slug}
  Epic Branch: epic/EPIC-{num}-{slug}
  Sub-tasks: {count} (as implementation checklist)  โ† if sub-tasks exist

Sequential Queue (after parallel phase):
  STORY-003 (depends on STORY-001)

Proceed with this plan? (y/n)

Wait for user confirmation before proceeding.

If config.agent_teams.auto_approve_plans = true, skip confirmation.


Part 3: Branch Creation#

Create branch hierarchy for all stories:

For each epic in the plan:

  1. Resolve branch names per helpers.md#Resolve-Branch-Names
  2. Create branch hierarchy per helpers.md#Create-Branch-Hierarchy
    • Create epic branch from main (if not exists)
    • Create story branches from epic branch

Display branch structure:

Branch Hierarchy:
main
โ”œโ”€โ”€ epic/EPIC-001-user-auth
โ”‚   โ”œโ”€โ”€ story/STORY-001-registration โ† Teammate 1
โ”‚   โ””โ”€โ”€ story/STORY-002-login โ† Teammate 1
โ””โ”€โ”€ epic/EPIC-002-product-catalog
    โ”œโ”€โ”€ story/STORY-004-listing โ† Teammate 2
    โ””โ”€โ”€ story/STORY-005-detail โ† Teammate 2

Part 4: Task List & Teammate Spawn#

Step 1: Create shared task list per helpers.md#Create-Team-Task-List:

For each teammate assignment:

TaskCreate:
  subject:  " Developer: Implement {story_ids} ({epic_name}) " 
   description: Full context including stories, file ownership, branches
  activeForm:  " Implementing {story_ids} "

Set up dependencies if any stories are sequential.

Step 2: Spawn teammates per helpers.md#Spawn-BMAD-Teammate:

For each teammate:

  • role: "developer"
  • context: Story documents, architecture summary, file ownership, branch info

Step 3: Move stories to In Progress on ZenHub:

If zh_available:
  For each story being developed:
    Call helpers.md#Move-Pipeline-with-Context(zh_story_id,  " In Progress " )
  For each epic with first story starting:
    Call helpers.md#Move-Pipeline-with-Context(zh_epic_id,  " In Progress " )

Note on Sub-tasks: When spawning teammates, include sub-task information in the context:

  • Sub-task list serves as implementation checklist for the teammate
  • Teammate should move sub-task pipelines as they complete each one
  • Include sub-task zh_issue_ids so teammates can call Move-Pipeline-with-Context
  • After teammate completes: Lead batch-updates sub_task statuses in sprint-status.yaml

Part 5: Plan Approval#

Review teammate implementation plans:

Each teammate produces an implementation plan before coding.

If config.agent_teams.auto_approve_plans = false (default):

  1. Collect plans from teammates
  2. Present each plan to user for review
  3. User approves or requests changes
  4. On approval: teammates proceed with implementation
  5. On rejection: teammate revises plan

If config.agent_teams.auto_approve_plans = true:

  • Teammates proceed directly after planning

Part 6: Progress Monitoring#

Poll teammate progress:

  1. Check task status:

        Call TaskList
    Display: {completed}/{total} teammates done
    
  2. On teammate completion: a. Run quality gate per helpers.md#Team-Quality-Gate:

           Call Team-Quality-Gate(story_branch)
       If passed: Accept work
       If failed: Report failures to user for decision
       

    b. Update sprint status per helpers.md#Update-Sprint-Status:

    • Update story status to "dev-complete"
    • Update branch, epic_branch fields
    • Increment completed_points
    • Update sub_task statuses if sub-tasks exist (batch update)
    • Increment sub_tasks_completed in metrics

    c. Move ZenHub pipeline:

           If zh_available:
         Call helpers.md#Move-Pipeline-with-Context(zh_story_id,  " Review/QA " )
       
  3. On teammate failure:

    • Log the issue
    • Continue monitoring remaining teammates
    • Report failed stories to user
  4. Display progress:

        Team Progress:
    
    Teammate 1: โœ“ Complete (STORY-001, STORY-002)
      Quality Gate: โœ“ Passed (lint โœ“, typecheck โœ“, tests โœ“)
    
    Teammate 2: ๐Ÿ”„ In Progress (STORY-004, STORY-005)
      Current: Implementing STORY-004...
    
    Overall: 2/4 stories complete
    

Part 7: Results Summary#

After all teammates complete:

  1. Collect results per helpers.md#Collect-Team-Results

  2. Handle sequential queue (if any):

    • Inform user about remaining dependent stories
    • Suggest /dev-story STORY-{ID} for each
  3. Create story โ†’ epic PRs per helpers.md#Create-PR-and-Merge:

        For each completed story:
      Call Create-PR-and-Merge(
        source: story_branch,
        target: epic_branch,
        title:  " feat: STORY-{ID} {title} " ,
        merge_strategy:  " merge " 
       )
    
  4. Display summary:

        โœ“ Team Development Complete!
    
    Stories Completed: {count}/{total}
    Total Points: {points}
    
    Results:
      STORY-001: โœ“ Dev Complete, PR open
        Quality: lint โœ“, typecheck โœ“, tests โœ“ ({count} tests)
        PR: {pr_url}
    
      STORY-002: โœ“ Dev Complete, PR open
        Quality: lint โœ“, typecheck โœ“, tests โœ“ ({count} tests)
        PR: {pr_url}
    
    ZenHub Pipeline:
      STORY-001 โ†’ Review/QA
      STORY-002 โ†’ Review/QA
    
    Sequential Queue:
      STORY-003 (depends on STORY-001) โ†’ Run /dev-story STORY-003
    
    Sprint Progress: {completed}/{total} points
    

Helper References#

  • Load config: helpers.md#Combined-Config-Load
  • Load sprint status: helpers.md#Load-Sprint-Status
  • Update sprint status: helpers.md#Update-Sprint-Status
  • Check Agent Teams: helpers.md#Check-Agent-Teams-Available
  • Spawn teammate: helpers.md#Spawn-BMAD-Teammate
  • Create team tasks: helpers.md#Create-Team-Task-List
  • Collect results: helpers.md#Collect-Team-Results
  • Quality gate: helpers.md#Team-Quality-Gate
  • Resolve branches: helpers.md#Resolve-Branch-Names
  • Create branch hierarchy: helpers.md#Create-Branch-Hierarchy
  • Create PR: helpers.md#Create-PR-and-Merge
  • ZenHub context: helpers.md#Load-ZenHub-Context
  • Move pipeline: helpers.md#Move-Pipeline-with-Context

Notes for LLMs#

  • ALWAYS check Agent Teams availability first (Pre-Flight step 3-4)
  • If teams not available, suggest /dev-story and STOP โ€” do not attempt workarounds
  • Present parallelization plan to user and wait for confirmation
  • Sprint-status.yaml is Lead-only: batch all updates after teammates complete
  • File ownership boundaries must be explicit and non-overlapping
  • Quality gates run automatically on each teammate's completed work
  • ZenHub pipeline moves are best-effort (warn and continue on failure)
  • Each teammate works on its own branch โ€” no shared branches between teammates
  • Sequential queue handles stories with dependencies (run after parallel phase)
  • If gh CLI unavailable, output manual PR instructions (do not block)

Remember: The value of /team-dev is parallelization. If there's only 1 independent story group, recommend /dev-story instead. The overhead of team coordination should be justified by parallel execution gains.