opencode-agile-agent 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/README.md +71 -0
  2. package/bin/cli.js +434 -0
  3. package/bin/validate-templates.js +58 -0
  4. package/package.json +52 -0
  5. package/templates/.opencode/ARCHITECTURE.md +368 -0
  6. package/templates/.opencode/README.md +391 -0
  7. package/templates/.opencode/agents/api-designer.md +312 -0
  8. package/templates/.opencode/agents/backend-specialist.md +214 -0
  9. package/templates/.opencode/agents/code-archaeologist.md +260 -0
  10. package/templates/.opencode/agents/database-architect.md +212 -0
  11. package/templates/.opencode/agents/debugger.md +302 -0
  12. package/templates/.opencode/agents/developer.md +523 -0
  13. package/templates/.opencode/agents/devops-engineer.md +253 -0
  14. package/templates/.opencode/agents/documentation-writer.md +247 -0
  15. package/templates/.opencode/agents/explorer-agent.md +239 -0
  16. package/templates/.opencode/agents/feature-lead.md +302 -0
  17. package/templates/.opencode/agents/frontend-specialist.md +186 -0
  18. package/templates/.opencode/agents/game-developer.md +391 -0
  19. package/templates/.opencode/agents/mobile-developer.md +264 -0
  20. package/templates/.opencode/agents/orchestrator.md +463 -0
  21. package/templates/.opencode/agents/penetration-tester.md +256 -0
  22. package/templates/.opencode/agents/performance-optimizer.md +292 -0
  23. package/templates/.opencode/agents/pr-reviewer.md +468 -0
  24. package/templates/.opencode/agents/product-manager.md +225 -0
  25. package/templates/.opencode/agents/product-owner.md +264 -0
  26. package/templates/.opencode/agents/project-planner.md +248 -0
  27. package/templates/.opencode/agents/qa-automation-engineer.md +276 -0
  28. package/templates/.opencode/agents/security-auditor.md +260 -0
  29. package/templates/.opencode/agents/seo-specialist.md +266 -0
  30. package/templates/.opencode/agents/system-analyst.md +428 -0
  31. package/templates/.opencode/agents/test-engineer.md +229 -0
  32. package/templates/.opencode/config.template.json +129 -0
  33. package/templates/.opencode/rules/coding-standards.md +250 -0
  34. package/templates/.opencode/rules/git-conventions.md +149 -0
  35. package/templates/.opencode/skills/api-patterns/SKILL.md +162 -0
  36. package/templates/.opencode/skills/brainstorming/SKILL.md +255 -0
  37. package/templates/.opencode/skills/clean-code/SKILL.md +351 -0
  38. package/templates/.opencode/skills/code-philosophy/SKILL.md +512 -0
  39. package/templates/.opencode/skills/frontend-design/SKILL.md +237 -0
  40. package/templates/.opencode/skills/intelligent-routing/SKILL.md +195 -0
  41. package/templates/.opencode/skills/parallel-agents/SKILL.md +274 -0
  42. package/templates/.opencode/skills/plan-writing/SKILL.md +251 -0
  43. package/templates/.opencode/skills/systematic-debugging/SKILL.md +210 -0
  44. package/templates/.opencode/skills/testing-patterns/SKILL.md +252 -0
  45. package/templates/.opencode/workflows/brainstorm.md +110 -0
  46. package/templates/.opencode/workflows/create.md +108 -0
  47. package/templates/.opencode/workflows/debug.md +128 -0
  48. package/templates/.opencode/workflows/deploy.md +160 -0
  49. package/templates/.opencode/workflows/enhance.md +253 -0
  50. package/templates/.opencode/workflows/orchestrate.md +130 -0
  51. package/templates/.opencode/workflows/plan.md +163 -0
  52. package/templates/.opencode/workflows/review.md +135 -0
  53. package/templates/.opencode/workflows/status.md +102 -0
  54. package/templates/.opencode/workflows/test.md +146 -0
  55. package/templates/AGENTS.template.md +426 -0
@@ -0,0 +1,237 @@
1
+ ---
2
+ name: frontend-design
3
+ description: UI/UX patterns, component design, and frontend architecture best practices.
4
+ version: 1.0.0
5
+ ---
6
+
7
+ # Frontend Design
8
+
9
+ Patterns and best practices for building maintainable frontend applications.
10
+
11
+ ## Component Design Principles
12
+
13
+ ### Single Responsibility
14
+
15
+ ```typescript
16
+ // ❌ Does too much
17
+ function UserDashboard() {
18
+ // Fetches data
19
+ // Renders charts
20
+ // Handles settings
21
+ // Manages notifications
22
+ }
23
+
24
+ // ✅ Focused components
25
+ function UserDashboard() {
26
+ return (
27
+ <DashboardLayout>
28
+ <UserProfile />
29
+ <ActivityChart />
30
+ <SettingsPanel />
31
+ <NotificationList />
32
+ </DashboardLayout>
33
+ );
34
+ }
35
+ ```
36
+
37
+ ### Component Composition
38
+
39
+ ```typescript
40
+ // ❌ Prop drilling
41
+ <Parent user={user} onUserChange={setUser} />
42
+
43
+ // ✅ Composition
44
+ <Card>
45
+ <CardHeader title="Profile" />
46
+ <CardSection>
47
+ <UserProfile />
48
+ </CardSection>
49
+ <CardFooter>
50
+ <EditButton />
51
+ </CardFooter>
52
+ </Card>
53
+ ```
54
+
55
+ ### Controlled vs Uncontrolled
56
+
57
+ ```typescript
58
+ // Controlled (parent manages state)
59
+ function ControlledInput({ value, onChange }) {
60
+ return <input value={value} onChange={onChange} />;
61
+ }
62
+
63
+ // Uncontrolled (component manages state)
64
+ function UncontrolledInput({ defaultValue, onChange }) {
65
+ const [value, setValue] = useState(defaultValue);
66
+ return <input value={value} onChange={e => setValue(e.target.value)} />;
67
+ }
68
+ ```
69
+
70
+ ## State Management
71
+
72
+ ### Local State (Default)
73
+
74
+ ```typescript
75
+ // Component-level state
76
+ const [isOpen, setIsOpen] = useState(false);
77
+ const [formData, setFormData] = useState({});
78
+ ```
79
+
80
+ ### Lift State Up
81
+
82
+ ```typescript
83
+ // When multiple components need the same state
84
+ function Parent() {
85
+ const [selected, setSelected] = useState(null);
86
+ return (
87
+ <>
88
+ <List items={items} selected={selected} onSelect={setSelected} />
89
+ <Details item={selected} />
90
+ </>
91
+ );
92
+ }
93
+ ```
94
+
95
+ ### Global State (Zustand)
96
+
97
+ ```typescript
98
+ const useStore = create((set) => ({
99
+ user: null,
100
+ setUser: (user) => set({ user }),
101
+ logout: () => set({ user: null }),
102
+ }));
103
+ ```
104
+
105
+ ### Server State (React Query)
106
+
107
+ ```typescript
108
+ const { data, isLoading, error } = useQuery({
109
+ queryKey: ['user', userId],
110
+ queryFn: () => fetchUser(userId),
111
+ staleTime: 5 * 60 * 1000,
112
+ });
113
+ ```
114
+
115
+ ## Styling Patterns
116
+
117
+ ### Tailwind Best Practices
118
+
119
+ ```typescript
120
+ // ❌ Inline everything
121
+ <div className="flex flex-col items-center justify-center p-4 m-2 bg-white rounded-lg shadow-md hover:shadow-lg transition-shadow duration-200">
122
+
123
+ // ✅ Extract variants with cva
124
+ const cardVariants = cva("rounded-lg p-4", {
125
+ variants: {
126
+ variant: {
127
+ default: "bg-white shadow",
128
+ outlined: "border border-gray-200",
129
+ elevated: "bg-white shadow-lg"
130
+ }
131
+ }
132
+ });
133
+
134
+ <div className={cardVariants({ variant })}>
135
+ ```
136
+
137
+ ### Responsive Design
138
+
139
+ ```typescript
140
+ // Mobile-first approach
141
+ <div className="
142
+ p-4 // Mobile: padding
143
+ md:p-6 // Tablet: more padding
144
+ lg:p-8 // Desktop: even more
145
+ grid
146
+ grid-cols-1 // Mobile: 1 column
147
+ md:grid-cols-2 // Tablet: 2 columns
148
+ lg:grid-cols-3 // Desktop: 3 columns
149
+ ">
150
+ ```
151
+
152
+ ## Performance Patterns
153
+
154
+ ### Code Splitting
155
+
156
+ ```typescript
157
+ // Route-based splitting
158
+ const Dashboard = lazy(() => import('./Dashboard'));
159
+ const Settings = lazy(() => import('./Settings'));
160
+
161
+ // Component-based splitting
162
+ const HeavyChart = lazy(() => import('./HeavyChart'));
163
+ ```
164
+
165
+ ### Memoization
166
+
167
+ ```typescript
168
+ // Only when needed (measure first!)
169
+ const MemoizedList = memo(function List({ items }) {
170
+ return items.map(item => <Item key={item.id} {...item} />);
171
+ });
172
+
173
+ // Memoize callbacks
174
+ const handleSubmit = useCallback((data) => {
175
+ submit(data);
176
+ }, [submit]);
177
+
178
+ // Memoize computations
179
+ const sortedItems = useMemo(() => {
180
+ return [...items].sort(compareFn);
181
+ }, [items]);
182
+ ```
183
+
184
+ ### Virtualization
185
+
186
+ ```typescript
187
+ // For long lists
188
+ import { FixedSizeList } from 'react-window';
189
+
190
+ function VirtualList({ items }) {
191
+ return (
192
+ <FixedSizeList height={600} itemCount={items.length} itemSize={50}>
193
+ {({ index, style }) => (
194
+ <div style={style}>{items[index].name}</div>
195
+ )}
196
+ </FixedSizeList>
197
+ );
198
+ }
199
+ ```
200
+
201
+ ## Accessibility
202
+
203
+ ### Semantic HTML
204
+
205
+ ```typescript
206
+ // ❌ Divs everywhere
207
+ <div onClick={handleClick}>Click me</div>
208
+
209
+ // ✅ Semantic elements
210
+ <button onClick={handleClick}>Click me</button>
211
+ ```
212
+
213
+ ### ARIA Labels
214
+
215
+ ```typescript
216
+ <button aria-label="Close dialog" onClick={onClose}>
217
+ <XIcon />
218
+ </button>
219
+
220
+ <div role="alert" aria-live="polite">
221
+ {errorMessage}
222
+ </div>
223
+ ```
224
+
225
+ ### Focus Management
226
+
227
+ ```typescript
228
+ // Trap focus in modal
229
+ const modalRef = useRef();
230
+ useEffect(() => {
231
+ modalRef.current?.focus();
232
+ }, []);
233
+ ```
234
+
235
+ ---
236
+
237
+ **Good frontend design balances UX, DX, and performance.**
@@ -0,0 +1,195 @@
1
+ ---
2
+ name: intelligent-routing
3
+ description: Automatic agent detection and routing based on task keywords and context.
4
+ version: 1.0.0
5
+ ---
6
+
7
+ # Intelligent Routing
8
+
9
+ Automatically detect which agent(s) should handle a task based on keywords and context.
10
+
11
+ ## How It Works
12
+
13
+ 1. **Analyze** the user request for keywords and patterns
14
+ 2. **Detect** relevant domains (frontend, backend, security, etc.)
15
+ 3. **Select** appropriate specialist agent(s)
16
+ 4. **Announce** which agent is being used
17
+ 5. **Execute** with specialist expertise
18
+
19
+ ## Keyword Detection Matrix
20
+
21
+ ### Frontend
22
+
23
+ | Keywords | Agent |
24
+ |----------|-------|
25
+ | component, react, vue, angular, svelte | `frontend-specialist` |
26
+ | css, style, tailwind, scss, styled | `frontend-specialist` |
27
+ | ui, ux, design, layout, responsive | `frontend-specialist` |
28
+ | page, route, navigation, menu | `frontend-specialist` |
29
+ | form, input, button, modal | `frontend-specialist` |
30
+ | state, redux, zustand, context | `frontend-specialist` |
31
+
32
+ ### Backend
33
+
34
+ | Keywords | Agent |
35
+ |----------|-------|
36
+ | api, endpoint, route, rest, graphql | `backend-specialist` |
37
+ | server, express, fastify, nestjs | `backend-specialist` |
38
+ | authentication, auth, login, jwt | `backend-specialist` + `security-auditor` |
39
+ | database, sql, prisma, sequelize | `database-architect` |
40
+ | migration, schema, table, index | `database-architect` |
41
+
42
+ ### Security
43
+
44
+ | Keywords | Agent |
45
+ |----------|-------|
46
+ | security, vulnerability, cve, owasp | `security-auditor` |
47
+ | encrypt, decrypt, hash, password | `security-auditor` |
48
+ | xss, sql injection, csrf | `security-auditor` |
49
+ | penetration, pentest, exploit | `penetration-tester` |
50
+ | audit, compliance, gdpr | `security-auditor` |
51
+
52
+ ### Testing
53
+
54
+ | Keywords | Agent |
55
+ |----------|-------|
56
+ | test, jest, vitest, mocha | `test-engineer` |
57
+ | e2e, playwright, cypress | `test-engineer` |
58
+ | coverage, tdd, unit test | `test-engineer` |
59
+ | qa, automation, pipeline | `qa-automation-engineer` |
60
+
61
+ ### DevOps
62
+
63
+ | Keywords | Agent |
64
+ |----------|-------|
65
+ | deploy, deployment, release | `devops-engineer` |
66
+ | docker, container, kubernetes | `devops-engineer` |
67
+ | ci/cd, pipeline, github actions | `devops-engineer` |
68
+ | infrastructure, terraform, aws | `devops-engineer` |
69
+
70
+ ### Performance
71
+
72
+ | Keywords | Agent |
73
+ |----------|-------|
74
+ | performance, slow, optimize, fast | `performance-optimizer` |
75
+ | bundle, size, lazy load | `performance-optimizer` |
76
+ | lighthouse, core web vitals | `performance-optimizer` |
77
+
78
+ ### Debugging
79
+
80
+ | Keywords | Agent |
81
+ |----------|-------|
82
+ | bug, error, fix, broken | `debugger` |
83
+ | debug, crash, exception | `debugger` |
84
+ | issue, problem, not working | `debugger` |
85
+
86
+ ### Planning
87
+
88
+ | Keywords | Agent |
89
+ |----------|-------|
90
+ | plan, roadmap, milestone | `project-planner` |
91
+ | feature, requirement, spec | `project-planner` |
92
+ | architecture, design, decision | `project-planner` |
93
+ | brainstorm, idea, explore | `project-planner` |
94
+
95
+ ### Mobile
96
+
97
+ | Keywords | Agent |
98
+ |----------|-------|
99
+ | mobile, ios, android, app | `mobile-developer` |
100
+ | react native, flutter, expo | `mobile-developer` |
101
+ | app store, play store | `mobile-developer` |
102
+
103
+ ### SEO
104
+
105
+ | Keywords | Agent |
106
+ |----------|-------|
107
+ | seo, search, ranking, google | `seo-specialist` |
108
+ | meta, sitemap, robots | `seo-specialist` |
109
+ | structured data, schema | `seo-specialist` |
110
+
111
+ ### Documentation
112
+
113
+ | Keywords | Agent |
114
+ |----------|-------|
115
+ | documentation, docs, readme | `documentation-writer` |
116
+ | api docs, reference, guide | `documentation-writer` |
117
+
118
+ ### Games
119
+
120
+ | Keywords | Agent |
121
+ |----------|-------|
122
+ | game, unity, godot, unreal | `game-developer` |
123
+ | gameplay, mechanics, level | `game-developer` |
124
+
125
+ ## Multi-Agent Detection
126
+
127
+ When multiple domains are detected, combine agents:
128
+
129
+ ### Common Combinations
130
+
131
+ | Request Pattern | Agents |
132
+ |-----------------|--------|
133
+ | "Build a secure API" | `backend-specialist` + `security-auditor` |
134
+ | "Create a dashboard with database" | `frontend-specialist` + `database-architect` |
135
+ | "Fix slow page with tests" | `performance-optimizer` + `test-engineer` |
136
+ | "Deploy with monitoring" | `devops-engineer` + `performance-optimizer` |
137
+ | "Mobile app with auth" | `mobile-developer` + `security-auditor` |
138
+
139
+ ## Detection Algorithm
140
+
141
+ ```typescript
142
+ function detectAgents(request: string): Agent[] {
143
+ const agents: Agent[] = [];
144
+ const keywords = extractKeywords(request);
145
+
146
+ // Check each domain
147
+ if (matchesAny(keywords, FRONTEND_KEYWORDS)) {
148
+ agents.push('frontend-specialist');
149
+ }
150
+
151
+ if (matchesAny(keywords, BACKEND_KEYWORDS)) {
152
+ agents.push('backend-specialist');
153
+ }
154
+
155
+ if (matchesAny(keywords, SECURITY_KEYWORDS)) {
156
+ agents.push('security-auditor');
157
+ }
158
+
159
+ // ... more domains
160
+
161
+ // Default to orchestrator if no specific match
162
+ if (agents.length === 0) {
163
+ agents.push('orchestrator');
164
+ }
165
+
166
+ return agents;
167
+ }
168
+ ```
169
+
170
+ ## Announcement Pattern
171
+
172
+ When routing to an agent, announce the selection:
173
+
174
+ ```
175
+ 🤖 Applying @frontend-specialist + @backend-specialist...
176
+ ```
177
+
178
+ ## Context Passing
179
+
180
+ When invoking agents, pass full context:
181
+
182
+ ```typescript
183
+ invokeAgent('backend-specialist', {
184
+ task: 'Create authentication API',
185
+ context: {
186
+ userRequest: originalRequest,
187
+ previousFindings: explorerResults,
188
+ constraints: userPreferences
189
+ }
190
+ });
191
+ ```
192
+
193
+ ---
194
+
195
+ **Intelligent routing ensures users get specialist help without needing to know the agent system.**
@@ -0,0 +1,274 @@
1
+ ---
2
+ name: parallel-agents
3
+ description: Multi-agent coordination patterns and best practices for parallel execution.
4
+ version: 1.0.0
5
+ ---
6
+
7
+ # Parallel Agents
8
+
9
+ Patterns and best practices for coordinating multiple agents in parallel.
10
+
11
+ ## When to Use Parallel Agents
12
+
13
+ ### Good Candidates
14
+
15
+ - Independent tasks (frontend + backend)
16
+ - Multiple file types (code + tests + docs)
17
+ - Multiple perspectives (security + performance)
18
+ - Large codebase analysis
19
+ - Comprehensive reviews
20
+
21
+ ### Poor Candidates
22
+
23
+ - Sequential dependencies (API → Frontend)
24
+ - Shared mutable state
25
+ - Conflicting file modifications
26
+ - Tasks requiring full context from previous step
27
+
28
+ ## Parallel Execution Patterns
29
+
30
+ ### Pattern 1: Domain Split
31
+
32
+ ```
33
+ Task: "Build user management feature"
34
+
35
+ ┌─────────────────────────────────────┐
36
+ │ Orchestrator │
37
+ └──────────────┬──────────────────────┘
38
+
39
+ ┌───────┴───────┐
40
+ │ │
41
+ ▼ ▼
42
+ ┌─────────────┐ ┌─────────────┐
43
+ │ Frontend │ │ Backend │
44
+ │ Specialist │ │ Specialist │
45
+ │ │ │ │
46
+ │ Components │ │ APIs │
47
+ │ Pages │ │ Services │
48
+ │ State │ │ Database │
49
+ └─────────────┘ └─────────────┘
50
+ ```
51
+
52
+ ### Pattern 2: Multi-Perspective Review
53
+
54
+ ```
55
+ Task: "Review authentication system"
56
+
57
+ ┌─────────────────────────────────────┐
58
+ │ Orchestrator │
59
+ └──────────────┬──────────────────────┘
60
+
61
+ ┌───────────┼───────────┐
62
+ │ │ │
63
+ ▼ ▼ ▼
64
+ ┌───────┐ ┌───────┐ ┌───────┐
65
+ │Security│ │Backend│ │ Test │
66
+ │Auditor │ │Special│ │Engine │
67
+ └───────┘ └───────┘ └───────┘
68
+ │ │ │
69
+ └───────────┼───────────┘
70
+
71
+ Synthesis Report
72
+ ```
73
+
74
+ ### Pattern 3: File Type Distribution
75
+
76
+ ```
77
+ Task: "Implement feature with tests"
78
+
79
+ ┌─────────────────────────────────────┐
80
+ │ Orchestrator │
81
+ └──────────────┬──────────────────────┘
82
+
83
+ ┌───────┴───────┐
84
+ │ │
85
+ ▼ ▼
86
+ ┌─────────────┐ ┌─────────────┐
87
+ │ Developer │ │ Test │
88
+ │ (Code) │ │ Engineer │
89
+ │ │ │ (Tests) │
90
+ └─────────────┘ └─────────────┘
91
+ ```
92
+
93
+ ## Agent Groups
94
+
95
+ ### Foundation Group
96
+
97
+ For establishing core infrastructure:
98
+
99
+ | Agent | Responsibility |
100
+ |-------|----------------|
101
+ | `database-architect` | Schema, migrations |
102
+ | `security-auditor` | Security baseline |
103
+ | `devops-engineer` | CI/CD setup |
104
+
105
+ ### Core Development Group
106
+
107
+ For building features:
108
+
109
+ | Agent | Responsibility |
110
+ |-------|----------------|
111
+ | `frontend-specialist` | UI components |
112
+ | `backend-specialist` | APIs, services |
113
+ | `database-architect` | Data layer |
114
+
115
+ ### Quality Group
116
+
117
+ For ensuring quality:
118
+
119
+ | Agent | Responsibility |
120
+ |-------|----------------|
121
+ | `test-engineer` | Test coverage |
122
+ | `security-auditor` | Security check |
123
+ | `performance-optimizer` | Performance audit |
124
+
125
+ ### Documentation Group
126
+
127
+ For documentation:
128
+
129
+ | Agent | Responsibility |
130
+ |-------|----------------|
131
+ | `documentation-writer` | Docs |
132
+ | `api-designer` | API docs |
133
+ | `seo-specialist` | Meta, sitemap |
134
+
135
+ ## Coordination Protocol
136
+
137
+ ### Step 1: Task Decomposition
138
+
139
+ ```markdown
140
+ Original: "Build user dashboard"
141
+
142
+ Decomposed:
143
+ 1. [Frontend] Dashboard UI components
144
+ 2. [Backend] Dashboard API endpoints
145
+ 3. [Database] Dashboard data queries
146
+ 4. [Test] Dashboard E2E tests
147
+ ```
148
+
149
+ ### Step 2: Agent Assignment
150
+
151
+ ```markdown
152
+ Assignments:
153
+ - frontend-specialist → Dashboard components
154
+ - backend-specialist → API endpoints
155
+ - database-architect → Queries
156
+ - test-engineer → E2E tests
157
+ ```
158
+
159
+ ### Step 3: Dependency Analysis
160
+
161
+ ```markdown
162
+ Dependencies:
163
+ - Backend API depends on Database queries
164
+ - Frontend depends on Backend API
165
+ - Tests depend on Frontend + Backend
166
+
167
+ Execution Order:
168
+ 1. Database (independent)
169
+ 2. Backend (depends on 1)
170
+ 3. Frontend (depends on 2)
171
+ 4. Tests (depends on 3)
172
+ ```
173
+
174
+ ### Step 4: Parallel Execution
175
+
176
+ ```markdown
177
+ Wave 1: database-architect (parallel with nothing)
178
+ Wave 2: backend-specialist (after Wave 1)
179
+ Wave 3: frontend-specialist (parallel with Wave 2)
180
+ Wave 4: test-engineer (after Waves 2, 3)
181
+ ```
182
+
183
+ ## Context Sharing
184
+
185
+ ### Shared Context Object
186
+
187
+ ```typescript
188
+ interface SharedContext {
189
+ // Original request
190
+ userRequest: string;
191
+
192
+ // Decisions made
193
+ decisions: Decision[];
194
+
195
+ // Work completed
196
+ completedWork: WorkItem[];
197
+
198
+ // Files created/modified
199
+ files: FileInfo[];
200
+
201
+ // Open questions
202
+ openQuestions: Question[];
203
+ }
204
+ ```
205
+
206
+ ### Context Passing
207
+
208
+ ```typescript
209
+ // Pass context to each agent
210
+ invokeAgent('frontend-specialist', {
211
+ task: 'Build dashboard UI',
212
+ context: sharedContext
213
+ });
214
+
215
+ invokeAgent('backend-specialist', {
216
+ task: 'Build dashboard API',
217
+ context: sharedContext
218
+ });
219
+ ```
220
+
221
+ ## Conflict Resolution
222
+
223
+ ### File Conflicts
224
+
225
+ ```
226
+ If multiple agents modify the same file:
227
+ 1. Detect conflict
228
+ 2. Merge changes if possible
229
+ 3. Flag for human review if conflict
230
+ ```
231
+
232
+ ### API Contract Conflicts
233
+
234
+ ```
235
+ If frontend and backend disagree on API:
236
+ 1. Use API designer as mediator
237
+ 2. Document contract
238
+ 3. Both agents follow contract
239
+ ```
240
+
241
+ ## Synthesis Report
242
+
243
+ After parallel execution, synthesize results:
244
+
245
+ ```markdown
246
+ ## Orchestration Report
247
+
248
+ ### Agents Invoked
249
+ | Agent | Status | Files Modified |
250
+ |-------|--------|----------------|
251
+ | frontend-specialist | ✅ Complete | 5 files |
252
+ | backend-specialist | ✅ Complete | 3 files |
253
+ | test-engineer | ✅ Complete | 2 files |
254
+
255
+ ### Combined Findings
256
+ - [Finding from Agent 1]
257
+ - [Finding from Agent 2]
258
+ - [Finding from Agent 3]
259
+
260
+ ### Integration Notes
261
+ - [How agents' work integrates]
262
+
263
+ ### Recommendations
264
+ 1. [Combined recommendation]
265
+ 2. [Combined recommendation]
266
+
267
+ ### Next Steps
268
+ - [ ] [Action item]
269
+ - [ ] [Action item]
270
+ ```
271
+
272
+ ---
273
+
274
+ **Parallel agents multiply productivity when tasks are independent.**