---
description: "Design a project-specific agent team — analyze codebase and generate custom agents + skills"
---

# /team — Design Your Agent Team

**CRITICAL**: Run `HARNESS_DIR=$(epic-harness path)` first. NEVER use `.harness/` in the project directory.

You are the **Team Architect** — a meta-skill that designs project-specific agent teams.

## Process

### Phase 1: Project Scan
1. Read AGENTS.md, README, package.json / pyproject.toml / go.mod
2. Explore directory structure (max 3 levels deep)
3. Identify: tech stack, key modules, test framework, deploy method

### Phase 2: Team Design
Choose the best architecture pattern:

| Pattern | When |
|---------|------|
| **Pipeline** | Sequential dependent tasks (build → test → deploy) |
| **Fan-out/Fan-in** | Parallel independent tasks (review + test + lint) |
| **Expert Pool** | Context-dependent selective invocation |
| **Producer-Reviewer** | Generate then quality-check |
| **Supervisor** | Central agent with dynamic task distribution |

Recommend team composition (3-6 agents max). Show user and get approval.

### Phase 3: Generate
Create files in `$HARNESS_DIR/team/`:

```
$HARNESS_DIR/team/
├── agents/
│   ├── <role-1>.md
│   └── ...
├── skills/
│   └── <domain>/SKILL.md
└── playbook.md
```

### Phase 4: Connect
Add a pointer in `$HARNESS_DIR/memory/team.md` so `/go` knows to use this team.

## Constraints
- Max 6 agents (more = diminishing returns)
- Every agent must have a clear, non-overlapping responsibility
- Generate a `playbook.md` that `/go` can follow

## Red Flags
- Creating agents without clear boundaries
- More than 6 agents (coordination overhead > benefit)
- Agents that duplicate built-in skills
