Coordinate multiple worker agents for project management. Handles task distribution, progress tracking, and result synthesis.
Requirements, wiring steps, and what this pattern adds to your project.
Pick how you want to pull this pattern in. Then wire env vars and routes the same way.
Download → Next.js app
Use Download → Next.js app in the preview toolbar. You get a zip scaffold (Pro downloads rewrite preview `/view/.../api/*` paths to `/api/*` automatically).
Extract the zip and install dependencies
Unzip the archive, then run `pnpm install` (or npm / yarn) in the project folder.
Fill .env.local
The download includes .env.local placeholders when needed. Add real values for: OPENAI_API_KEY.
Customize the agent and tool files
Adapt prompts, tools, and stop conditions in the generated project for your product.
Run the app and open the pattern route
Run `pnpm dev`, open the setup/checklist page if present, then navigate to the generated pattern route and verify responses.
OPENAI_API_KEYGet keyAI SDK APIs
AgenttoolstepCountIsExperimental_AgentgatewayProviders
app/page.tsxapp/layout.tsxapp/api/orchestrator-agent/route.tslib/orchestrator-agent.tslib/orchestrator-tool-types.tslib/ai-agent-orchestrator-tools/orchestrator.tslib/ai-agent-orchestrator-tools/worker.tslib/ai-agent-orchestrator-tools/coordinator.tslib/ai-agent-orchestrator-tools/schema.tscomponents/orchestrator-chat-demo.tsxcomponents/tool-views/orchestrator-view.tsxcomponents/tool-views/worker-view.tsxcomponents/tool-views/coordinator-view.tsxREADME.mdAGENT_FLOW.mdnpm packages
6
Registry components
orchestrator-agent/route.tsAPI route wiring the orchestrator agent: uses createAgentUIStreamResponse and validateUIMessages.
lib/orchestrator-agent.tsCore agent definition implementing the Orchestrator-Worker pattern. Defines 9 specialized worker types and a mandatory workflow. Registers 3 tools (orchestrator, worker, coordinator) with stepCountIs(15).
ai-agent-orchestrator-tools/orchestrator.tsOrchestrator planning tool: breaks down requests into structured implementation plans with 6 phases, each with category, priority, complexity, dependencies, and estimated duration.
ai-agent-orchestrator-tools/coordinator.tsCoordinator process management tool: implements 6 actions (start, check_progress, resolve_blocker, complete, pause, resume). Tracks progress and produces completion summaries.
ai-agent-orchestrator-tools/worker.tsWorker execution tool: handles 9 specialized worker types, each producing typed deliverables. Shows the pattern for domain-specific task delegation.
ai-agent-orchestrator-tools/schema.tsShared Zod schemas defining data contracts between orchestrator, workers, and coordinator.
Coordinate multiple worker agents for project management. Handles task distribution, progress tracking, and result synthesis.
Requirements, wiring steps, and what this pattern adds to your project.
Pick how you want to pull this pattern in. Then wire env vars and routes the same way.
Download → Next.js app
Use Download → Next.js app in the preview toolbar. You get a zip scaffold (Pro downloads rewrite preview `/view/.../api/*` paths to `/api/*` automatically).
Extract the zip and install dependencies
Unzip the archive, then run `pnpm install` (or npm / yarn) in the project folder.
Fill .env.local
The download includes .env.local placeholders when needed. Add real values for: OPENAI_API_KEY.
Customize the agent and tool files
Adapt prompts, tools, and stop conditions in the generated project for your product.
Run the app and open the pattern route
Run `pnpm dev`, open the setup/checklist page if present, then navigate to the generated pattern route and verify responses.
OPENAI_API_KEYGet keyAI SDK APIs
AgenttoolstepCountIsExperimental_AgentgatewayProviders
app/page.tsxapp/layout.tsxapp/api/orchestrator-agent/route.tslib/orchestrator-agent.tslib/orchestrator-tool-types.tslib/ai-agent-orchestrator-tools/orchestrator.tslib/ai-agent-orchestrator-tools/worker.tslib/ai-agent-orchestrator-tools/coordinator.tslib/ai-agent-orchestrator-tools/schema.tscomponents/orchestrator-chat-demo.tsxcomponents/tool-views/orchestrator-view.tsxcomponents/tool-views/worker-view.tsxcomponents/tool-views/coordinator-view.tsxREADME.mdAGENT_FLOW.mdnpm packages
6
Registry components
orchestrator-agent/route.tsAPI route wiring the orchestrator agent: uses createAgentUIStreamResponse and validateUIMessages.
lib/orchestrator-agent.tsCore agent definition implementing the Orchestrator-Worker pattern. Defines 9 specialized worker types and a mandatory workflow. Registers 3 tools (orchestrator, worker, coordinator) with stepCountIs(15).
ai-agent-orchestrator-tools/orchestrator.tsOrchestrator planning tool: breaks down requests into structured implementation plans with 6 phases, each with category, priority, complexity, dependencies, and estimated duration.
ai-agent-orchestrator-tools/coordinator.tsCoordinator process management tool: implements 6 actions (start, check_progress, resolve_blocker, complete, pause, resume). Tracks progress and produces completion summaries.
ai-agent-orchestrator-tools/worker.tsWorker execution tool: handles 9 specialized worker types, each producing typed deliverables. Shows the pattern for domain-specific task delegation.
ai-agent-orchestrator-tools/schema.tsShared Zod schemas defining data contracts between orchestrator, workers, and coordinator.

Unlock the live preview and source
Locked on free (high token spend). Pro runs the live demo and includes the source.
Early-bird pricing — limited time

Open on desktop for the interactive preview.
Coordinate multiple worker agents for project management. Handles task distribution, progress tracking, and result synthesis.
Unlock the live preview and source
Locked on free (high token spend). Pro runs the live demo and includes the source.

Unlock the live preview and source
Locked on free (high token spend). Pro runs the live demo and includes the source.
Early-bird pricing — limited time

Open on desktop for the interactive preview.
Coordinate multiple worker agents for project management. Handles task distribution, progress tracking, and result synthesis.
Unlock the live preview and source
Locked on free (high token spend). Pro runs the live demo and includes the source.