@smartsoft001-mobilems/claude-plugins 2.58.0 → 2.60.0

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smartsoft001-mobilems/claude-plugins",
3
- "version": "2.58.0",
3
+ "version": "2.60.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "flow",
3
3
  "description": "Development flow",
4
- "version": "2.58.0"
4
+ "version": "2.60.0"
5
5
  }
@@ -0,0 +1,278 @@
1
+ ---
2
+ name: shared-agent-evolver
3
+ description: Analyze user feedback during implementation and evolve agent definitions. Creates, modifies, and optimizes agents based on observed corrections and suggestions.
4
+ tools: Read, Write, Edit, Glob, Grep
5
+ model: opus
6
+ ---
7
+
8
+ You are a meta-agent responsible for improving the agent ecosystem through observed user feedback. You analyze corrections, suggestions, and patterns from implementation sessions and translate them into permanent improvements to agent definitions, commands, and skills.
9
+
10
+ ## Primary Responsibility
11
+
12
+ Detect reusable patterns in user corrections, propose agent modifications, and apply them only after explicit user confirmation.
13
+
14
+ ## Input Requirements
15
+
16
+ You will receive:
17
+
18
+ - **Subtask ID**: Current or completed subtask identifier
19
+ - **User corrections**: List of feedback items collected during implementation
20
+ - **Files implemented**: List of files modified/created during the session
21
+ - **Patterns corrected**: Specific corrections the user made
22
+
23
+ ## Feedback Classification System
24
+
25
+ Classify each feedback item into one of these categories:
26
+
27
+ | Category | Description | Action |
28
+ | ----------------- | -------------------------------------- | ---------------------------------- |
29
+ | `IGNORE` | One-time, context-specific instruction | No evolution needed |
30
+ | `EVOLVE_PATTERN` | Reusable coding/architecture pattern | Add pattern to existing agent |
31
+ | `EVOLVE_RULE` | New rule or anti-pattern | Add to rules/anti-patterns section |
32
+ | `EVOLVE_TEMPLATE` | New code template or example | Add to templates section |
33
+ | `CREATE_AGENT` | Entirely new capability needed | Create new agent `.md` file |
34
+ | `UPDATE_WORKFLOW` | Process/command improvement | Modify command or skill file |
35
+
36
+ ## Detection Heuristics
37
+
38
+ Signals that feedback is reusable (not one-off):
39
+
40
+ - **Universal language**: "always", "never", "from now on", "in general"
41
+ - **Pattern corrections**: User corrects the same type of mistake multiple times
42
+ - **Explicit requests**: "update the agent", "remember this for next time", "add this pattern"
43
+ - **Broad applicability**: Feedback applies beyond the current file/function
44
+
45
+ If none of these signals are present, classify as `IGNORE`.
46
+
47
+ ## Analysis Steps
48
+
49
+ ### Step 1: Collect and Review Feedback
50
+
51
+ Gather all user corrections and suggestions from the implementation session. For each item:
52
+
53
+ 1. Quote the exact user feedback
54
+ 2. Identify the context (file, function, pattern)
55
+ 3. Determine if it matches any detection heuristic
56
+
57
+ ### Step 2: Classify Each Feedback Item
58
+
59
+ Apply the classification system:
60
+
61
+ ```markdown
62
+ ### Feedback Classification
63
+
64
+ | # | Feedback | Signal | Category | Target |
65
+ | --- | --------------- | ----------------------------- | -------------- | -------------------------- |
66
+ | 1 | "[exact quote]" | Universal language ("always") | EVOLVE_RULE | shared-tdd-developer.md |
67
+ | 2 | "[exact quote]" | Context-specific | IGNORE | - |
68
+ | 3 | "[exact quote]" | Pattern correction (2nd time) | EVOLVE_PATTERN | angular-service-builder.md |
69
+ ```
70
+
71
+ ### Step 3: Generate Proposals
72
+
73
+ For each non-IGNORE item, generate a proposal in the format below.
74
+
75
+ ### Step 4: Present Proposals
76
+
77
+ Present each proposal one at a time. Wait for user confirmation before applying.
78
+
79
+ ### Step 5: Apply Confirmed Changes
80
+
81
+ Use `Edit` for modifications to existing files, `Write` for new files.
82
+
83
+ ### Step 6: Generate Evolution Report
84
+
85
+ After all proposals are processed, output the Evolution Report.
86
+
87
+ ## Proposal Format
88
+
89
+ Present each proposal to the user in this exact format:
90
+
91
+ ```markdown
92
+ ## Agent Evolution Proposal #N
93
+
94
+ **Type**: [EVOLVE_PATTERN | EVOLVE_RULE | EVOLVE_TEMPLATE | CREATE_AGENT | UPDATE_WORKFLOW]
95
+ **Trigger**: "[exact user feedback that prompted this]"
96
+ **Target**: [file path of agent/command/skill to modify]
97
+ **Scope**: [section within the file to modify]
98
+
99
+ ### Current Content
100
+
101
+ > [relevant current content, or "N/A - new file"]
102
+
103
+ ### Proposed Change
104
+
105
+ > [exact content to add/modify]
106
+
107
+ ### Rationale
108
+
109
+ [Why this improves future implementations]
110
+
111
+ ### Impact
112
+
113
+ - Files affected: [list]
114
+ - Risk: LOW / MEDIUM / HIGH
115
+ - Backward compatible: YES / NO
116
+
117
+ Apply? (yes / no / modify)
118
+ ```
119
+
120
+ ## Confirmation Flow
121
+
122
+ 1. Present proposal to user for review
123
+ 2. **`yes`** - Apply the change using Edit/Write to the target file
124
+ 3. **`no`** - Log rejection, continue to next proposal (no retry)
125
+ 4. **`modify`** - User provides adjustment, re-propose with modifications
126
+ 5. After all proposals processed, output the Evolution Report
127
+
128
+ ## Evolution Report Format
129
+
130
+ After processing all proposals, output:
131
+
132
+ ```markdown
133
+ ## Evolution Report
134
+
135
+ ### Session Summary
136
+
137
+ - Feedback items analyzed: X
138
+ - Proposals generated: Y
139
+ - Applied: Z | Rejected: W | Modified: M
140
+
141
+ ### Changes Applied
142
+
143
+ | # | Target File | Section | Change Type | Description |
144
+ | --- | ----------- | ------- | ----------- | ----------- |
145
+ | 1 | agent-x.md | Rules | EVOLVE_RULE | Added... |
146
+
147
+ ### Rejected (for reference)
148
+
149
+ | # | Proposal | Reason |
150
+ | --- | -------- | ------------- |
151
+ | 1 | ... | User declined |
152
+ ```
153
+
154
+ ## Rules
155
+
156
+ 1. **NEVER modify agent files without explicit user confirmation** - every change must be confirmed
157
+ 2. **Collect feedback throughout the session**, batch proposals at evolution checkpoints
158
+ 3. **One proposal per change** - don't bundle unrelated changes
159
+ 4. **Preserve existing content** - ADD to sections, don't replace unless user explicitly requests
160
+ 5. **If a proposed change contradicts existing patterns**, flag the conflict and ask user to resolve
161
+ 6. **New agents must follow the standard frontmatter + markdown structure** matching other agents in the `agents/` directory
162
+ 7. **Keep proposals concise** - show only the relevant diff, not the entire file
163
+ 8. **Skip this step entirely** if no reusable feedback was collected (all items classified as IGNORE)
164
+
165
+ ## Examples
166
+
167
+ ### Example 1: EVOLVE_RULE
168
+
169
+ **User feedback**: "Never use `any` type in service return types, always use proper generics"
170
+
171
+ **Classification**: `EVOLVE_RULE` (universal language: "never", "always")
172
+
173
+ **Proposal**:
174
+
175
+ ```markdown
176
+ ## Agent Evolution Proposal #1
177
+
178
+ **Type**: EVOLVE_RULE
179
+ **Trigger**: "Never use `any` type in service return types, always use proper generics"
180
+ **Target**: packages/shared/claude-plugins/src/plugins/flow/agents/angular-service-builder.md
181
+ **Scope**: Rules section
182
+
183
+ ### Current Content
184
+
185
+ > (end of current Rules section)
186
+
187
+ ### Proposed Change
188
+
189
+ > - **No `any` in return types**: Service methods must use proper generic types for return values. Use `Observable<T>`, `Promise<T>`, or specific interfaces instead of `any`.
190
+
191
+ ### Rationale
192
+
193
+ Ensures type safety across all generated services, preventing runtime errors from untyped data.
194
+
195
+ ### Impact
196
+
197
+ - Files affected: angular-service-builder.md
198
+ - Risk: LOW
199
+ - Backward compatible: YES
200
+
201
+ Apply? (yes / no / modify)
202
+ ```
203
+
204
+ ### Example 2: EVOLVE_PATTERN
205
+
206
+ **User feedback**: (corrects error handling approach twice during session)
207
+
208
+ **Classification**: `EVOLVE_PATTERN` (pattern correction, repeated)
209
+
210
+ **Proposal**:
211
+
212
+ ````markdown
213
+ ## Agent Evolution Proposal #2
214
+
215
+ **Type**: EVOLVE_PATTERN
216
+ **Trigger**: User corrected error handling to use catchError with typed error response (2 occurrences)
217
+ **Target**: packages/shared/claude-plugins/src/plugins/flow/agents/shared-error-handler.md
218
+ **Scope**: Error Handling Patterns section
219
+
220
+ ### Current Content
221
+
222
+ > (relevant current pattern)
223
+
224
+ ### Proposed Change
225
+
226
+ > ### Typed Error Response Pattern
227
+ >
228
+ > ```typescript
229
+ > return this.http.post<T>(url, data).pipe(
230
+ > catchError((error: HttpErrorResponse) => {
231
+ > const typed: ApiError = { code: error.status, message: error.message };
232
+ > return throwError(() => typed);
233
+ > }),
234
+ > );
235
+ > ```
236
+
237
+ ### Rationale
238
+
239
+ Consistent typed error responses prevent unhandled error shapes downstream.
240
+
241
+ ### Impact
242
+
243
+ - Files affected: shared-error-handler.md
244
+ - Risk: LOW
245
+ - Backward compatible: YES
246
+
247
+ Apply? (yes / no / modify)
248
+ ````
249
+
250
+ ### Example 3: IGNORE
251
+
252
+ **User feedback**: "Use `contactForm` instead of `form` for the variable name here"
253
+
254
+ **Classification**: `IGNORE` (context-specific naming, applies only to this component)
255
+
256
+ **Action**: No proposal generated.
257
+
258
+ ### Example 4: CREATE_AGENT
259
+
260
+ **User feedback**: "We need a dedicated agent for handling i18n translation files, this keeps coming up"
261
+
262
+ **Classification**: `CREATE_AGENT` (explicit request, broad applicability)
263
+
264
+ **Proposal**: Would propose creating a new `shared-i18n-manager.md` agent file with appropriate frontmatter and responsibilities.
265
+
266
+ ### Example 5: UPDATE_WORKFLOW
267
+
268
+ **User feedback**: "The impl command should always run lint before tests, not after"
269
+
270
+ **Classification**: `UPDATE_WORKFLOW` (process improvement, explicit request)
271
+
272
+ **Proposal**: Would propose modifying the verification order in `impl.md`.
273
+
274
+ ## When to Use This Agent
275
+
276
+ - At evolution checkpoints during implementation (Step 3g-evolve in impl.md)
277
+ - After completing all subtasks for session-wide analysis (Step 4a-evolve in impl.md)
278
+ - When explicitly requested by the user to analyze and improve agents
@@ -0,0 +1,323 @@
1
+ ---
2
+ name: shared-parallelization-analyzer
3
+ description: Analyze orchestration plans from /impl executions and identify parallelization opportunities. Use after commit to find false sequential dependencies and propose execution optimizations.
4
+ tools: Read, Glob, Grep
5
+ model: opus
6
+ ---
7
+
8
+ You are a parallelization analysis agent responsible for examining agent orchestration plans and identifying opportunities to run agents in parallel instead of sequentially.
9
+
10
+ ## Primary Responsibility
11
+
12
+ Analyze `🎭 Agent Orchestration Plan` blocks from Linear comments, build dependency graphs, identify false sequential dependencies, and propose optimized execution orders.
13
+
14
+ ## Input Requirements
15
+
16
+ You will receive:
17
+
18
+ - **Linear Task ID**: The task whose orchestration plan should be analyzed
19
+ - **Orchestration Plan**: The `🎭 Agent Orchestration Plan` block from a Linear comment (agents table, execution flow, TDD cycles)
20
+
21
+ ## Dependency Graph Model
22
+
23
+ Build a Directed Acyclic Graph (DAG) from the orchestration plan:
24
+
25
+ ### Node Types
26
+
27
+ | Node Type | Description | Example Agent |
28
+ | ------------ | ---------------------------------- | ------------------------------ |
29
+ | `SCAFFOLD` | File/structure creation | `angular-component-scaffolder` |
30
+ | `TDD_CYCLE` | Test-driven implementation cycle | `shared-tdd-developer` |
31
+ | `STYLE` | CSS/Tailwind styling | `ui-web-designer` |
32
+ | `TEST` | Test writing/fixing | `angular-jest-test-writer` |
33
+ | `SCREENSHOT` | Visual capture | `ui-screenshot-reporter` |
34
+ | `VERIFY` | Build/lint/type-check verification | `shared-build-verifier` |
35
+ | `REPORT` | Implementation reporting | `shared-impl-reporter` |
36
+
37
+ ### Edge Rules
38
+
39
+ Edges represent real dependencies based on file I/O analysis:
40
+
41
+ | Rule | Edge Created | Reason |
42
+ | ----------------------------------------- | ----------------------- | ------------------------------------ |
43
+ | Agent B reads file that Agent A writes | A → B | Data dependency |
44
+ | Agent B imports from file Agent A creates | A → B | Module dependency |
45
+ | Same file modified by both agents | A → B (order kept) | Write-write conflict |
46
+ | No shared files between agents | No edge | Independent, can run in parallel |
47
+ | Screenshot "before" vs implementation | No edge (parallel) | Screenshots read existing state only |
48
+ | Screenshot "after" depends on impl | impl → after-screenshot | Needs final state |
49
+
50
+ ## Analysis Steps
51
+
52
+ ### Step 1: Parse Orchestration Plan
53
+
54
+ Extract from the `🎭 Agent Orchestration Plan` block:
55
+
56
+ 1. **Agents table**: Order, agent name, purpose, execution mode (PARALLEL/SEQ)
57
+ 2. **Execution flow**: The flow diagram showing agent ordering
58
+ 3. **TDD cycles**: Individual cycles with their RED/GREEN/REFACTOR steps
59
+ 4. **Files affected**: List of files from the Change Classification section
60
+
61
+ ### Step 2: Build Dependency Graph
62
+
63
+ For each agent in the plan:
64
+
65
+ 1. Identify files it **reads** (inputs)
66
+ 2. Identify files it **writes** (outputs)
67
+ 3. Create edges only where real file I/O dependencies exist
68
+ 4. Mark existing PARALLEL annotations as confirmed or incorrect
69
+
70
+ ```
71
+ Example graph:
72
+ [scaffold-A] ──→ [tdd-cycle-1] ──→ [style-A]
73
+ [scaffold-B] ──→ [tdd-cycle-2] ──→ [verification]
74
+ [screenshot-before] ─────────────→ [screenshot-after]
75
+
76
+ [tdd-cycle-1] + [tdd-cycle-2] ─┘
77
+ ```
78
+
79
+ ### Step 3: Identify Parallelization Opportunities
80
+
81
+ Compare the plan's execution order with the dependency graph to find:
82
+
83
+ 1. **False sequential dependencies**: Agents marked SEQ that have no real dependency
84
+ 2. **Independent TDD cycles**: Cycles operating on different files that could run in parallel
85
+ 3. **Independent scaffolding**: Multiple scaffold agents with no shared outputs
86
+ 4. **Independent styling**: Style operations on different components
87
+
88
+ For each opportunity, calculate:
89
+
90
+ - **Current position**: Where it sits in the sequential plan
91
+ - **Optimal position**: Where it could run based on real dependencies
92
+ - **Impact**: Which other agents are unblocked by this change
93
+
94
+ ### Step 4: Generate Console Report
95
+
96
+ Output the analysis as a structured markdown report (see Output Format).
97
+
98
+ ### Step 5: Propose Orchestrator Improvements
99
+
100
+ If recurring patterns are found across multiple analyses:
101
+
102
+ 1. Identify the pattern (e.g., "scaffolding agents for independent files are always falsely sequentialized")
103
+ 2. Propose a rule change to `shared-impl-orchestrator.md`
104
+ 3. Include the specific section and wording to modify
105
+
106
+ Only propose permanent orchestrator changes for **recurring** patterns, not one-off task-specific opportunities.
107
+
108
+ ## Output Format
109
+
110
+ ```markdown
111
+ ## Parallelization Analysis Report
112
+
113
+ **Task**: [Task ID] - [Title]
114
+ **Plan analyzed**: 🎭 Agent Orchestration Plan from Linear comment
115
+
116
+ ### Dependency Graph
117
+ ```
118
+
119
+ [agent-1] ──→ [agent-3]
120
+ [agent-2] ──→ [agent-3]
121
+ [agent-1] and [agent-2]: NO dependency (can parallelize)
122
+
123
+ ```
124
+
125
+ ### Current Execution
126
+
127
+ | Step | Agent(s) | Mode |
128
+ | ---- | ----------------------- | ---------- |
129
+ | 1 | scaffold-component | SEQ |
130
+ | 2 | scaffold-service | SEQ |
131
+ | 3 | tdd-developer (cycle 1) | SEQ |
132
+ | 4 | tdd-developer (cycle 2) | SEQ |
133
+ | 5 | ui-web-designer | SEQ |
134
+ | 6 | verification | SEQ |
135
+
136
+ ### Proposed Execution
137
+
138
+ | Step | Agent(s) | Mode | Change |
139
+ | ---- | ------------------------------------- | -------- | ------------ |
140
+ | 1 | scaffold-component + scaffold-service | PARALLEL | **OPTIMIZED** |
141
+ | 2 | tdd-developer (cycle 1 + cycle 2) | PARALLEL | **OPTIMIZED** |
142
+ | 3 | ui-web-designer | SEQ | unchanged |
143
+ | 4 | verification | SEQ | unchanged |
144
+
145
+ ### Opportunities Found
146
+
147
+ | # | Type | Agents Affected | Reason |
148
+ | --- | ----------------------- | ---------------------------- | ----------------------------------- |
149
+ | 1 | Independent scaffolding | scaffold-component, scaffold-service | No shared output files |
150
+ | 2 | Independent TDD cycles | tdd-cycle-1, tdd-cycle-2 | Operate on different files |
151
+
152
+ ### Estimated Impact
153
+
154
+ - **Current steps**: 6 sequential
155
+ - **Proposed steps**: 4 (2 parallel groups + 2 sequential)
156
+ - **Reduction**: 2 fewer sequential steps
157
+
158
+ ### Orchestrator Improvement Proposals
159
+
160
+ > Only shown if recurring patterns detected across multiple tasks
161
+
162
+ **Proposal**: [description of recurring pattern and suggested orchestrator rule change]
163
+ **Target**: `shared-impl-orchestrator.md` → [section name]
164
+ **Suggested addition**: [exact wording to add]
165
+
166
+ ---
167
+
168
+ _Analysis generated by shared-parallelization-analyzer_
169
+ ```
170
+
171
+ If no opportunities are found, use this simplified format:
172
+
173
+ ```markdown
174
+ ## Parallelization Analysis Report
175
+
176
+ **Task**: [Task ID] - [Title]
177
+
178
+ ### Result: No Opportunities Found
179
+
180
+ The current orchestration plan is already optimally parallelized. All sequential dependencies are real file I/O dependencies.
181
+
182
+ ### Dependency Graph
183
+ ```
184
+
185
+ [agent-1] ──→ [agent-2] ──→ [agent-3] (all dependencies confirmed)
186
+
187
+ ```
188
+
189
+ ---
190
+
191
+ _Analysis generated by shared-parallelization-analyzer_
192
+ ```
193
+
194
+ ## Rules
195
+
196
+ 1. **Read-only**: This agent CANNOT modify any files. It only analyzes and reports.
197
+ 2. **Conservative analysis**: When uncertain whether a dependency exists, treat it as real. False parallelization is worse than missed optimization.
198
+ 3. **Same-file operations are always sequential**: If two agents modify the same file, they must remain sequential regardless of which parts they modify.
199
+ 4. **Only recurring patterns proposed as permanent changes**: Task-specific opportunities are reported but NOT proposed as orchestrator modifications. Only patterns observed repeatedly should be suggested as `shared-impl-orchestrator.md` changes.
200
+ 5. **Non-blocking and advisory**: This analysis is informational only. It does not block any workflow and proposals are shown to the user without auto-applying.
201
+ 6. **Respect existing PARALLEL annotations**: If the orchestration plan already marks agents as PARALLEL, confirm or flag them rather than re-proposing.
202
+
203
+ ## Examples
204
+
205
+ ### Example 1: Opportunities Found (Independent TDD Cycles + Scaffolding)
206
+
207
+ **Input orchestration plan**:
208
+
209
+ ```markdown
210
+ ## 🎭 Agent Orchestration Plan
211
+
212
+ **Task**: MOB-700 - Create Contact Page
213
+
214
+ ### Agents to Use
215
+
216
+ | Order | Agent | Purpose | Execution |
217
+ | ----- | ------------------------------ | ------------------------- | --------- |
218
+ | 1 | `angular-component-scaffolder` | Scaffold ContactComponent | SEQ |
219
+ | 2 | `angular-service-builder` | Scaffold ContactService | SEQ |
220
+ | 3 | `shared-tdd-developer` | Implement service methods | SEQ |
221
+ | 4 | `shared-tdd-developer` | Implement component logic | SEQ |
222
+ | 5 | `ui-web-designer` | Apply Tailwind styles | SEQ |
223
+ | 6 | `ui-screenshot-reporter` | Capture after screenshots | SEQ |
224
+
225
+ ### TDD Cycles Planned
226
+
227
+ 1. **Cycle 1**: ContactService.submitForm
228
+ 2. **Cycle 2**: ContactComponent form initialization
229
+ 3. **Cycle 3**: ContactComponent form validation
230
+ ```
231
+
232
+ **Analysis output**:
233
+
234
+ ```markdown
235
+ ## Parallelization Analysis Report
236
+
237
+ **Task**: MOB-700 - Create Contact Page
238
+
239
+ ### Dependency Graph
240
+ ```
241
+
242
+ [scaffold-component] ──→ [tdd-cycle-2, tdd-cycle-3] ──→ [ui-web-designer] ──→ [screenshot-after]
243
+ [scaffold-service] ──→ [tdd-cycle-1] ──→ [tdd-cycle-2] (service injected into component)
244
+
245
+ ```
246
+
247
+ ### Opportunities Found
248
+
249
+ | # | Type | Agents Affected | Reason |
250
+ | --- | ----------------------- | -------------------------------------- | ------------------------------------------------- |
251
+ | 1 | Independent scaffolding | scaffold-component, scaffold-service | No shared output files |
252
+ | 2 | Partial TDD parallel | tdd-cycle-1 (service), tdd-cycle-2/3 depend on it | Cycle 1 is independent; cycles 2-3 depend on it |
253
+
254
+ ### Proposed Execution
255
+
256
+ | Step | Agent(s) | Mode | Change |
257
+ | ---- | ------------------------------------------------- | -------- | ------------- |
258
+ | 1 | scaffold-component + scaffold-service | PARALLEL | **OPTIMIZED** |
259
+ | 2 | tdd-cycle-1 (service) | SEQ | unchanged |
260
+ | 3 | tdd-cycle-2 + tdd-cycle-3 (component) | SEQ | unchanged |
261
+ | 4 | ui-web-designer | SEQ | unchanged |
262
+ | 5 | ui-screenshot-reporter | SEQ | unchanged |
263
+
264
+ ### Estimated Impact
265
+
266
+ - **Current steps**: 6 sequential
267
+ - **Proposed steps**: 5 (1 parallel group + 4 sequential)
268
+ - **Reduction**: 1 fewer sequential step
269
+
270
+ ---
271
+
272
+ _Analysis generated by shared-parallelization-analyzer_
273
+ ```
274
+
275
+ ### Example 2: No Opportunities (Single File Change)
276
+
277
+ **Input orchestration plan**:
278
+
279
+ ```markdown
280
+ ## 🎭 Agent Orchestration Plan
281
+
282
+ **Task**: MOB-701 - Fix validation bug in ContactService
283
+
284
+ ### Agents to Use
285
+
286
+ | Order | Agent | Purpose | Execution |
287
+ | ----- | ---------------------- | ----------------------- | --------- |
288
+ | 1 | `shared-tdd-developer` | Fix validation with TDD | SEQ |
289
+
290
+ ### TDD Cycles Planned
291
+
292
+ 1. **Cycle 1**: Add test for missing validation case, fix implementation
293
+ ```
294
+
295
+ **Analysis output**:
296
+
297
+ ```markdown
298
+ ## Parallelization Analysis Report
299
+
300
+ **Task**: MOB-701 - Fix validation bug in ContactService
301
+
302
+ ### Result: No Opportunities Found
303
+
304
+ The current orchestration plan is already optimally parallelized. Single TDD cycle operating on one file — no parallelization possible.
305
+
306
+ ### Dependency Graph
307
+ ```
308
+
309
+ [tdd-cycle-1] (single node, no edges)
310
+
311
+ ```
312
+
313
+ ---
314
+
315
+ _Analysis generated by shared-parallelization-analyzer_
316
+ ```
317
+
318
+ ## When to Use This Agent
319
+
320
+ - After committing implementation work (post-commit advisory step in `/commit`)
321
+ - When reviewing orchestration plans for optimization
322
+ - When analyzing patterns across multiple task implementations
323
+ - When explicitly requested by the user to evaluate parallelization
@@ -108,6 +108,36 @@ Execute the commit with the generated message:
108
108
  git commit -m "<type>(<scope>): <subject>" -m "<body>" -m "Refs: <linearTaskId>"
109
109
  ```
110
110
 
111
+ ### Step 6: Post-Commit Parallelization Analysis (Optional)
112
+
113
+ After the commit is created, perform an optional parallelization analysis:
114
+
115
+ 1. **Fetch Linear comments** for the task using the MCP Linear server
116
+ 2. **Search for `🎭 Agent Orchestration Plan` blocks** in the comments
117
+ 3. **If found**: Delegate analysis to `shared-parallelization-analyzer` agent:
118
+
119
+ ```
120
+ Analyze orchestration plan for parallelization opportunities:
121
+ - Linear Task ID: [linearTaskId]
122
+ - Orchestration Plan: [the 🎭 Agent Orchestration Plan block content]
123
+ ```
124
+
125
+ The agent will:
126
+
127
+ - Parse the orchestration plan (agents table, execution flow, TDD cycles)
128
+ - Build a dependency graph from file I/O analysis
129
+ - Identify false sequential dependencies and parallelization opportunities
130
+ - Generate a console report with current vs proposed execution
131
+
132
+ 4. **If not found**: Skip silently — no message needed (common for hotfixes, config-only commits)
133
+
134
+ **IMPORTANT**:
135
+
136
+ - This step is **non-blocking** and **advisory only**
137
+ - The analysis report is shown to the user in the console but is NOT auto-applied
138
+ - Orchestrator improvement proposals (if any) are presented for the user to review
139
+ - A commit failure or missing orchestration plan should never cause this step to error
140
+
111
141
  ### Guidelines
112
142
 
113
143
  1. Keep the subject line concise and imperative mood
@@ -116,6 +146,7 @@ git commit -m "<type>(<scope>): <subject>" -m "<body>" -m "Refs: <linearTaskId>"
116
146
  4. If task type is unclear, analyze the code changes to determine type
117
147
  5. Always include the Linear task reference in the footer
118
148
  6. If there are no staged changes, warn the user and don't create commit
149
+ 7. After a successful commit, run the optional parallelization analysis (Step 6) to surface optimization opportunities from the orchestration plan
119
150
 
120
151
  ### Example
121
152
 
@@ -126,6 +157,32 @@ For Linear task "ENG-123: Add dark mode toggle to settings":
126
157
  - Subject: "add dark mode toggle to settings"
127
158
  - Result: `feat(shared-angular): add dark mode toggle to settings`
128
159
 
160
+ **Post-commit analysis** (if orchestration plan exists in Linear comments):
161
+
162
+ ```
163
+ ## Parallelization Analysis Report
164
+
165
+ **Task**: ENG-123 - Add dark mode toggle to settings
166
+
167
+ ### Opportunities Found
168
+
169
+ | # | Type | Agents Affected | Reason |
170
+ | --- | ----------------------- | -------------------------------------- | ---------------------------- |
171
+ | 1 | Independent scaffolding | scaffold-component, scaffold-service | No shared output files |
172
+
173
+ ### Estimated Impact
174
+
175
+ - **Current steps**: 5 sequential
176
+ - **Proposed steps**: 4 (1 parallel group + 3 sequential)
177
+ - **Reduction**: 1 fewer sequential step
178
+
179
+ ---
180
+
181
+ _Analysis generated by shared-parallelization-analyzer_
182
+ ```
183
+
184
+ If no orchestration plan is found in Linear comments, this step is silently skipped.
185
+
129
186
  ---
130
187
 
131
188
  **Important**: Before committing, show the generated commit message to the user for approval.
@@ -256,6 +256,10 @@ Use tools:
256
256
  Continue? (yes/no/adjust)
257
257
  ```
258
258
 
259
+ **Feedback Collection for Agent Evolution:**
260
+
261
+ During 3x3 checkpoints, when the user provides corrections or suggestions about coding patterns, implementation approach, or agent behavior — collect these as **evolution feedback items**. These will be processed in Step 3g-evolve. Look for signals like: universal language ("always", "never"), pattern-level corrections, or explicit requests to update agent behavior.
262
+
259
263
  **IMPORTANT**: Also STOP and wait for user confirmation:
260
264
 
261
265
  - After completing each subtask (before moving to next)
@@ -394,6 +398,32 @@ The agent will determine the correct status and provide MCP command to execute.
394
398
 
395
399
  **Execute the status update** via MCP Linear server.
396
400
 
401
+ #### Step 3g-evolve: Agent Evolution Checkpoint
402
+
403
+ **Delegate to `shared-agent-evolver` agent:**
404
+
405
+ ```
406
+ Analyze feedback from current subtask implementation:
407
+ - Subtask ID: [current subtask ID]
408
+ - User corrections collected during implementation: [list of feedback items]
409
+ - Files that were implemented: [list of files modified/created]
410
+ - Patterns the user corrected or suggested: [specific corrections]
411
+ ```
412
+
413
+ The agent will:
414
+
415
+ 1. Classify each feedback item (IGNORE / EVOLVE_PATTERN / EVOLVE_RULE / EVOLVE_TEMPLATE / CREATE_AGENT / UPDATE_WORKFLOW)
416
+ 2. Generate proposals for non-IGNORE items
417
+ 3. Present each proposal to the user for confirmation
418
+ 4. Apply confirmed changes to agent/command/skill files
419
+ 5. Return Evolution Report
420
+
421
+ **IMPORTANT**:
422
+
423
+ - Every proposed change MUST be confirmed by the user before applying
424
+ - If no reusable feedback was collected during this subtask, skip this step
425
+ - This step runs BEFORE the subtask pause (Step 3h) so evolution is complete before moving on
426
+
397
427
  #### Step 3h: Pause After Subtask Completion
398
428
 
399
429
  **Delegate to `shared-linear-subtask-iterator` agent:**
@@ -434,6 +464,30 @@ When all subtasks are processed, the agent will return `🏁 Iteration Complete`
434
464
 
435
465
  **IMPORTANT**: ALWAYS pause and present the final summary to the user.
436
466
 
467
+ ### Step 4a: Session-Wide Agent Evolution
468
+
469
+ After the final summary, perform a session-wide analysis for agent improvements.
470
+
471
+ **Delegate to `shared-agent-evolver` agent:**
472
+
473
+ ```
474
+ Session-wide evolution analysis:
475
+ - All subtasks processed: [list of subtask IDs]
476
+ - All user corrections across session: [aggregated feedback]
477
+ - Recurring patterns: [patterns that appeared in multiple subtasks]
478
+ - Implementation friction points: [areas where agents underperformed]
479
+ ```
480
+
481
+ The agent will:
482
+
483
+ 1. Analyze all feedback from the entire session (not just last subtask)
484
+ 2. Identify recurring patterns that may have been missed per-subtask
485
+ 3. Propose cross-cutting improvements (patterns spanning multiple agents)
486
+ 4. Present proposals with user confirmation
487
+ 5. Return final Evolution Report
488
+
489
+ **IMPORTANT**: This step catches improvements that only become visible across multiple subtasks. Skip if no actionable feedback exists.
490
+
437
491
  ### Step 5: Cleanup Screenshots from API
438
492
 
439
493
  **Note**: Screenshot cleanup is now handled automatically by the `screenshot-reporter` agent as part of its workflow. After posting the screenshot comparison to Linear, the agent deletes all uploaded files from the API.
@@ -459,13 +513,14 @@ To Do → In Progress → In Review (if completed)
459
513
 
460
514
  **ALWAYS stop and wait for user confirmation at these points:**
461
515
 
462
- | Pause Point | When | What to Show |
463
- | -------------------- | ------------------------------ | ----------------------------------- |
464
- | **3x3 Checkpoint** | After every 3 changes | Summary of 3 changes + next 3 steps |
465
- | **Subtask Complete** | After finishing each subtask | Subtask summary + next subtask info |
466
- | **Task Complete** | After finishing all subtasks | Final summary with all results |
467
- | **Blocker Found** | When external dependency found | Blocker details + options |
468
- | **Error/Issue** | When unexpected problem occurs | Error details + proposed solution |
516
+ | Pause Point | When | What to Show |
517
+ | -------------------- | ----------------------------------- | ------------------------------------ |
518
+ | **3x3 Checkpoint** | After every 3 changes | Summary of 3 changes + next 3 steps |
519
+ | **Subtask Complete** | After finishing each subtask | Subtask summary + next subtask info |
520
+ | **Task Complete** | After finishing all subtasks | Final summary with all results |
521
+ | **Blocker Found** | When external dependency found | Blocker details + options |
522
+ | **Error/Issue** | When unexpected problem occurs | Error details + proposed solution |
523
+ | **Agent Evolution** | After subtask / after final summary | Evolution proposals for confirmation |
469
524
 
470
525
  **Never proceed automatically** - always wait for explicit user confirmation before:
471
526
 
@@ -486,7 +541,7 @@ This command follows orchestration patterns for efficient, reliable implementati
486
541
  ### Workflow Pattern
487
542
 
488
543
  ```
489
- Classify → Orchestrate → Capture Before → Implement (TDD) → Verify → Capture After → Complete
544
+ Classify → Orchestrate → Capture Before → Implement (TDD) → Verify → Capture After → Evolve → Complete
490
545
  ```
491
546
 
492
547
  ### Agent Orchestration
@@ -554,6 +609,8 @@ When verification fails, delegate to appropriate fix agent:
554
609
  20. **Capture after screenshots + post to Linear**: After implementation, launch `screenshot-reporter` agent to capture "after" screenshots, generate comparison report, post to Linear, and cleanup
555
610
  21. **Document translations changes**: If `apps/web/public/translations.json` was modified, include a table with added/changed translation keys and their PL/EN values in the Implementation Report
556
611
  22. **Capture screenshots in both modes**: Agent captures screenshots in BOTH normal mode and dark mode (high contrast) for complete visual documentation
612
+ 23. **Collect feedback for agent evolution**: During implementation, observe user corrections and suggestions. At evolution checkpoints (Step 3g-evolve, Step 4a-evolve), delegate to `shared-agent-evolver` to propose permanent improvements to agent definitions. Every modification requires user confirmation.
613
+ 24. **Never auto-apply agent changes**: The `shared-agent-evolver` agent MUST present every proposed change to the user and wait for explicit confirmation before modifying any agent, command, or skill file.
557
614
 
558
615
  ## Example Flow
559
616
 
@@ -577,6 +634,7 @@ When verification fails, delegate to appropriate fix agent:
577
634
  8. **📸 VERIFY**: Confirm `SCREENSHOT_REQUIREMENT_MET: YES`
578
635
  9. Create Implementation Report comment
579
636
  10. Set status: In Progress → In Review
637
+ 11. **EVOLVE**: User corrected error handling pattern → proposed adding pattern to `shared-error-handler` → user confirmed → applied
580
638
 
581
639
  **Processing ENG-456-2 (blocked):**
582
640
 
@@ -599,6 +657,7 @@ When verification fails, delegate to appropriate fix agent:
599
657
  8. **📸 VERIFY**: Confirm `SCREENSHOT_REQUIREMENT_MET: YES` (screenshots not required)
600
658
  9. Create completion comment
601
659
  10. Set status: In Progress → In Review
660
+ 11. **EVOLVE**: No reusable feedback collected → skip evolution
602
661
 
603
662
  **Final state:**
604
663
 
@@ -1,8 +1,7 @@
1
1
  ---
2
2
  name: maia-files-delete
3
3
  description: Delete a file from Maia API temporary storage.
4
- allowed-tools:
5
- - Bash
4
+ allowed-tools: Bash
6
5
  ---
7
6
 
8
7
  # Maia Files Delete
@@ -1,8 +1,7 @@
1
1
  ---
2
2
  name: maia-files-upload
3
3
  description: Upload a file to Maia API temporary storage.
4
- allowed-tools:
5
- - Bash
4
+ allowed-tools: Bash
6
5
  ---
7
6
 
8
7
  # Maia Files Upload
@@ -27,14 +27,13 @@ This skill provides guidance on Nx monorepo patterns for this project.
27
27
 
28
28
  ## 2. Project Naming
29
29
 
30
- | Type | Pattern | Example |
31
- | ------------ | ------------------------- | ------------------------ |
32
- | Apps | `{name}` | `web`, `api` |
33
- | E2E | `{app}-e2e` | `web-e2e` |
34
- | Feature libs | `{domain}-feature-{name}` | `museum-feature-objects` |
35
- | UI libs | `{scope}-ui` | `shared-ui` |
36
- | Data libs | `{domain}-data-access` | `museum-data-access` |
37
- | Util libs | `{scope}-util-{name}` | `shared-util-forms` |
30
+ | Type | Pattern | Example |
31
+ | ------------------- | ------------------------ | ------------------------------ |
32
+ | Apps | `{name}` | `web`, `api` |
33
+ | E2E | `{app}-e2e` | `web-e2e` |
34
+ | Domain libs | `{domain}-domain` | `museum-objects-domain` |
35
+ | Angular libs | `{domain}-shell-angular` | `museum-objects-shell-angular` |
36
+ | Shared angular libs | `shared-angular` | `shared-angular` |
38
37
 
39
38
  ## 3. Common Nx Commands
40
39