| name | team-designer |
| description | Meta-skill for generating team skills following the v4 architecture pattern. Produces complete skill packages with SKILL.md router, coordinator, worker roles, specs, and templates. Triggers on "team-designer", "design team". |
| allowed-tools | Agent(*), AskUserQuestion(*), Read(*), Write(*), Edit(*), Bash(*), Glob(*), Grep(*), mcp__ccw-tools__team_msg(*) |
Team Skill Designer
Generate complete team skills following the team-lifecycle-v4 architecture: SKILL.md as universal router, coordinator with beat model, worker roles with optional commands/, shared specs, and templates.
Architecture Overview
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Team Skill Designer (SKILL.md) โ
โ โ Orchestrator: gather requirements, generate files, validate โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโผโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ โ โ โ
โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ
โ Phase 1 โ โ Phase 2 โ โ Phase 3 โ โ Phase 4 โ
โ Require โ โ Scaffoldโ โ Content โ โ Valid โ
โ Analysisโ โ Gen โ โ Gen โ โ & Reportโ
โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ
โ โ โ โ
teamConfig SKILL.md roles/ Validated
+ dirs specs/ skill pkg
templates/
Key Design Principles
- v4 Architecture Compliance: Generated skills follow team-lifecycle-v4 pattern โ SKILL.md = pure router, beat model = coordinator-only, unified structure (roles/ + specs/ + templates/)
- Golden Sample Reference: Uses
team-lifecycle-v4 as reference implementation at ~ or <project>/.claude/skills/team-lifecycle-v4/
- Intelligent Commands Distribution: Auto-determines which roles need
commands/ (2+ commands) vs inline logic (1 command)
- team-worker Compatibility: Role.md files include correct YAML frontmatter for team-worker agent parsing
Execution Flow
Input Parsing:
โโ Parse user requirements (skill name, roles, pipelines, domain)
Phase 1: Requirements Analysis
โโ Ref: phases/01-requirements-analysis.md
โโ Tasks: Detect input โ Gather roles โ Define pipelines โ Build teamConfig
โโ Output: teamConfig
Phase 2: Scaffold Generation
โโ Ref: phases/02-scaffold-generation.md
โโ Tasks: Create dirs โ Generate SKILL.md router โ Verify
โโ Output: SKILL.md + directory structure
Phase 3: Content Generation
โโ Ref: phases/03-content-generation.md
โโ Tasks: Coordinator โ Workers โ Specs โ Templates
โโ Output: roles/**/*.md, specs/*.md, templates/*.md
Phase 4: Validation
โโ Ref: phases/04-validation.md
โโ Output: Validation report (PASS/REVIEW/FAIL)
Return:
โโ Summary with skill location and usage instructions
Phase Reference Documents (read on-demand when phase executes):
Golden Sample
Generated skills follow the architecture of ~ or <project>/.claude/skills/team-lifecycle-v4/:
.claude/skills/<skill-name>/
โโโ SKILL.md # Universal router (all roles read)
โโโ roles/
โ โโโ coordinator/
โ โ โโโ role.md # Orchestrator + beat model + entry router
โ โ โโโ commands/
โ โ โโโ analyze.md # Task analysis
โ โ โโโ dispatch.md # Task chain creation
โ โ โโโ monitor.md # Beat control + callbacks
โ โโโ <inline-worker>/
โ โ โโโ role.md # Phase 2-4 embedded (simple role)
โ โโโ <command-worker>/
โ โโโ role.md # Phase 2-4 dispatcher
โ โโโ commands/
โ โโโ <cmd-1>.md
โ โโโ <cmd-2>.md
โโโ specs/
โ โโโ pipelines.md # Pipeline definitions + task registry
โ โโโ <domain-specs>.md # Domain-specific specifications
โโโ templates/ # Optional document templates
Data Flow
User Input (skill name, roles, pipelines)
โ
Phase 1: Requirements Analysis
โ Output: teamConfig
โ
Phase 2: Scaffold Generation
โ Input: teamConfig
โ Output: SKILL.md + skillDir
โ
Phase 3: Content Generation
โ Input: teamConfig + skillDir
โ Output: roles/, specs/, templates/
โ
Phase 4: Validation
โ Input: teamConfig + all files
โ Output: validation report
โ
Return summary to user
Core Rules
- Start Immediately: First action is Phase 1 execution
- Parse Every Output: Extract teamConfig from Phase 1 for subsequent phases
- Auto-Continue: After each phase, automatically execute next phase
- Progressive Phase Loading: Read phase docs ONLY when that phase is about to execute
- Golden Sample Fidelity: Generated files must match team-lifecycle-v4 patterns
- DO NOT STOP: Continuous workflow until all 4 phases complete
Input Processing
Convert user input to structured format:
SKILL_NAME: [kebab-case name, e.g., team-code-review]
DOMAIN: [what this team does, e.g., "multi-stage code review with security analysis"]
ROLES: [worker roles beyond coordinator, e.g., "analyst, reviewer, security-expert"]
PIPELINES: [pipeline types and flows, e.g., "review-only: SCAN-001 โ REVIEW-001 โ REPORT-001"]
SESSION_PREFIX: [3-4 char, e.g., TCR]
Error Handling
- Invalid role name: Must be lowercase alphanumeric with hyphens, max 20 chars
- Circular dependencies: Detect and report in pipeline validation
- Missing golden sample: Fall back to embedded templates in phase files
- Directory conflict: Warn if skill directory already exists, ask user to confirm overwrite