AgentSkillsCN

orchestrate

协调多位代理,共同应对复杂任务;可用于多视角分析、全方位评审,或需要不同领域专业经验的各类任务。

SKILL.md
--- frontmatter
name: orchestrate
description: Coordinate multiple agents for complex tasks. Use for multi-perspective analysis, comprehensive reviews, or tasks requiring different domain expertise.

Multi-Agent Orchestration

You are now in ORCHESTRATION MODE. Your task: coordinate specialized agents to solve this complex problem.

Task to Orchestrate

$ARGUMENTS


🔴 CRITICAL: Minimum Agent Requirement

⚠️ ORCHESTRATION = MINIMUM 3 DIFFERENT AGENTS

If you use fewer than 3 agents, you are NOT orchestrating - you're just delegating.

Validation before completion:

  • Count invoked agents
  • If agent_count < 3 → STOP and invoke more agents
  • Single agent = FAILURE of orchestration

Agent Selection Matrix

Task TypeREQUIRED Agents (minimum)
Web Appfrontend-specialist, backend-specialist, test-engineer
APIbackend-specialist, security-auditor, test-engineer
UI/Designfrontend-specialist, seo-specialist, performance-optimizer
Databasedatabase-architect, backend-specialist, security-auditor
Full Stackproject-planner, frontend-specialist, backend-specialist, devops-engineer
Debugdebugger, explorer-agent, test-engineer
Securitysecurity-auditor, penetration-tester, devops-engineer

Pre-Flight: Mode Check

Current ModeTask TypeAction
planAny✅ Proceed with planning-first approach
editSimple execution✅ Proceed directly
editComplex/multi-file⚠️ Ask: "This task requires planning. Switch to plan mode?"
askAny⚠️ Ask: "Ready to orchestrate. Switch to edit or plan mode?"

🔴 STRICT 2-PHASE ORCHESTRATION

PHASE 1: PLANNING (Sequential - NO parallel agents)

StepAgentAction
1project-plannerCreate docs/PLAN.md
2(optional) explorer-agentCodebase discovery if needed

🔴 NO OTHER AGENTS during planning! Only project-planner and explorer-agent.

⏸️ CHECKPOINT: User Approval

code
After PLAN.md is complete, ASK:

"✅ Plan created: docs/PLAN.md

Do you approve? (Y/N)
- Y: Start implementation
- N: I'll revise the plan"

🔴 DO NOT proceed to Phase 2 without explicit user approval!

PHASE 2: IMPLEMENTATION (Parallel agents after approval)

Parallel GroupAgents
Foundationdatabase-architect, security-auditor
Corebackend-specialist, frontend-specialist
Polishtest-engineer, devops-engineer

✅ After user approval, invoke multiple agents in PARALLEL.

Available Agents (17 total)

AgentDomainUse When
project-plannerPlanningTask breakdown, PLAN.md
explorer-agentDiscoveryCodebase mapping
frontend-specialistUI/UXReact, Vue, CSS, HTML
backend-specialistServerAPI, Node.js, Python
database-architectDataSQL, NoSQL, Schema
security-auditorSecurityVulnerabilities, Auth
penetration-testerSecurityActive testing
test-engineerTestingUnit, E2E, Coverage
devops-engineerOpsCI/CD, Docker, Deploy
mobile-developerMobileReact Native, Flutter
performance-optimizerSpeedLighthouse, Profiling
seo-specialistSEOMeta, Schema, Rankings
documentation-writerDocsREADME, API docs
debuggerDebugError analysis
game-developerGamesUnity, Godot
orchestratorMetaCoordination

Orchestration Protocol

Step 1: Analyze Task Domains

Identify ALL domains this task touches:

code
□ Security     → security-auditor, penetration-tester
□ Backend/API  → backend-specialist
□ Frontend/UI  → frontend-specialist
□ Database     → database-architect
□ Testing      → test-engineer
□ DevOps       → devops-engineer
□ Mobile       → mobile-developer
□ Performance  → performance-optimizer
□ SEO          → seo-specialist
□ Planning     → project-planner

Step 2: Phase Detection

If Plan ExistsAction
NO docs/PLAN.md→ Go to PHASE 1 (planning only)
YES docs/PLAN.md + user approved→ Go to PHASE 2 (implementation)

Step 3: Execute Based on Phase

PHASE 1 (Planning):

code
Use the project-planner agent to create PLAN.md
→ STOP after plan is created
→ ASK user for approval

PHASE 2 (Implementation - after approval):

code
Invoke agents in PARALLEL:
Use the frontend-specialist agent to [task]
Use the backend-specialist agent to [task]
Use the test-engineer agent to [task]

🔴 CRITICAL: Context Passing (MANDATORY)

When invoking ANY subagent, you MUST include:

  1. Original User Request: Full text of what user asked
  2. Decisions Made: All user answers to Socratic questions
  3. Previous Agent Work: Summary of what previous agents did
  4. Current Plan State: If plan files exist in workspace, include them

Example with FULL context:

code
Use the project-planner agent to create PLAN.md:

**CONTEXT:**
- User Request: "A social platform for students, using mock data"
- Decisions: Tech=Vue 3, Layout=Grid Widgets, Auth=Mock, Design=Youthful & dynamic
- Previous Work: Orchestrator asked 6 questions, user chose all options
- Current Plan: playful-roaming-dream.md exists in workspace with initial structure

**TASK:** Create detailed PLAN.md based on ABOVE decisions. Do NOT infer from folder name.

⚠️ VIOLATION: Invoking subagent without full context = subagent will make wrong assumptions!

Step 4: Verification (MANDATORY)

The LAST agent must run appropriate verification scripts:

bash
python .agent/skills/vulnerability-scanner/scripts/security_scan.py .
python .agent/skills/lint-and-validate/scripts/lint_runner.py .

Step 5: Synthesize Results

Combine all agent outputs into unified report.


Output Format

markdown
## 🎼 Orchestration Report

### Task
[Original task summary]

### Mode
[Current Antigravity Agent mode: plan/edit/ask]

### Agents Invoked (MINIMUM 3)
| # | Agent | Focus Area | Status |
|---|-------|------------|--------|
| 1 | project-planner | Task breakdown | ✅ |
| 2 | frontend-specialist | UI implementation | ✅ |
| 3 | test-engineer | Verification scripts | ✅ |

### Verification Scripts Executed
- [x] security_scan.py → Pass/Fail
- [x] lint_runner.py → Pass/Fail

### Key Findings
1. **[Agent 1]**: Finding
2. **[Agent 2]**: Finding
3. **[Agent 3]**: Finding

### Deliverables
- [ ] PLAN.md created
- [ ] Code implemented
- [ ] Tests passing
- [ ] Scripts verified

### Summary
[One paragraph synthesis of all agent work]

🔴 EXIT GATE

Before completing orchestration, verify:

  1. Agent Count: invoked_agents >= 3
  2. Scripts Executed: At least security_scan.py ran
  3. Report Generated: Orchestration Report with all agents listed

If any check fails → DO NOT mark orchestration complete. Invoke more agents or run scripts.


Begin orchestration now. Select 3+ agents, execute sequentially, run verification scripts, synthesize results.


Built with ❤️ from Antigravity Kit & UXUI ProMax MIT © Vudovn