# Team Orchestration

> Multi-agent orchestration system modeled after a real dev team. Provides specialist agents (Tech Lead, Staff Engineer, Architect, Navigator, Strategist, Advisor, Scout) that coordinate complex coding tasks within a single premium request.

- Skill: `jim0thy/team-orchestration` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add jim0thy/team-orchestration`
- Raw SKILL.md: https://api.skillmd.com/api/skills/jim0thy/team-orchestration/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: jim0thy (https://skillmd.com/u/jim0thy)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/jim0thy/team-orchestration

---


# Team Orchestration

This skill provides a multi-agent orchestration system for complex coding tasks. It coordinates specialist agents — modeled after a well-run engineering team — to break down, plan, implement, and review work efficiently.

## Agents

| Agent | Role | Best For |
|-------|------|----------|
| **Tech Lead** | Orchestrator | Coordinating complex multi-step tasks |
| **Staff Engineer** | Deep worker | Large implementations spanning 5+ files |
| **Architect** | Systems analyst | Debugging, architecture review, root-cause analysis |
| **Navigator** | Codebase expert | Finding code, explaining patterns, documentation |
| **Scout** | Fast search | Quick read-only codebase searches |
| **Strategist** | Planner | Creating implementation plans with phases |
| **Advisor** | Plan critic | Validating plans before execution |

## How It Works

1. All agents are registered as `customAgents` in the Copilot SDK session.
2. The SDK's built-in `task` tool enables agent-to-agent delegation.
3. All orchestration happens within a **single premium request** — subagent invocations are free.
4. The Tech Lead coordinates specialists based on task complexity.

## Usage

### Via CLI (one-shot mode)
```bash
bun src/cli/index.ts "Refactor the authentication module to use JWT"
```

### Programmatic
```typescript
import { createAnvilSession } from "./src/cli/index.js";

const session = await createAnvilSession({
  model: "claude-sonnet-4.6",
});

const response = await session.send("Add dark mode support");
await session.destroy();
```

### Via TUI
The agents are automatically loaded when Anvil starts in TUI mode. Use:
- `Ctrl+A` or `/agents` to see available agents
- `/team` to enable orchestrated mode (Intake → Tech Lead → Specialists)
- `/direct` to go back to single-agent mode

## Single-Request Guarantee

The critical design constraint: **1 user message = 1 premium request**. This is achieved because:

- Agents are SDK `customAgents`, not separate API calls
- The `task` tool delegates to subagents within the same request context
- All tool calls, agent delegations, and follow-ups happen within a single `session.send()` call
- The request only completes when `session.idle` fires

This means even a complex flow like:
```
User → Tech Lead → Strategist (plan) → Advisor (validate) → Staff Engineer (implement) → Reviewer (check) → User
```
...consumes exactly **1 premium request**.

