aiblueprint-cli 1.4.88 → 1.4.89

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/agents-config/skills/agents-manager/SKILL.md +14 -3
  2. package/agents-config/skills/agents-manager/references/writing-agent-prompts.md +1 -1
  3. package/agents-config/skills/apex/SKILL.md +116 -55
  4. package/agents-config/skills/apex/scripts/setup-templates.sh +154 -0
  5. package/agents-config/skills/apex/scripts/update-progress.sh +80 -0
  6. package/agents-config/skills/apex/steps/step-00-init.md +278 -0
  7. package/agents-config/skills/apex/steps/step-00b-branch.md +126 -0
  8. package/agents-config/skills/apex/steps/step-00b-economy.md +247 -0
  9. package/agents-config/skills/apex/steps/step-00b-interactive.md +170 -0
  10. package/agents-config/skills/apex/steps/step-00b-save.md +125 -0
  11. package/agents-config/skills/apex/steps/step-01-analyze.md +388 -0
  12. package/agents-config/skills/apex/steps/step-02-plan.md +593 -0
  13. package/agents-config/skills/apex/steps/step-02b-tasks.md +301 -0
  14. package/agents-config/skills/apex/steps/step-03-execute-teams.md +296 -0
  15. package/agents-config/skills/apex/steps/step-03-execute.md +240 -0
  16. package/agents-config/skills/apex/steps/step-04-validate.md +272 -0
  17. package/agents-config/skills/apex/steps/step-05-examine.md +400 -0
  18. package/agents-config/skills/apex/steps/step-06-resolve.md +239 -0
  19. package/agents-config/skills/apex/steps/step-07-tests.md +250 -0
  20. package/agents-config/skills/apex/steps/step-08-run-tests.md +314 -0
  21. package/agents-config/skills/apex/steps/step-09-finish.md +223 -0
  22. package/agents-config/skills/apex/steps/step-10-verify.md +296 -0
  23. package/agents-config/skills/apex/templates/00-context.md +55 -0
  24. package/agents-config/skills/apex/templates/01-analyze.md +10 -0
  25. package/agents-config/skills/apex/templates/02-plan.md +10 -0
  26. package/agents-config/skills/apex/templates/03-execute.md +10 -0
  27. package/agents-config/skills/apex/templates/04-validate.md +10 -0
  28. package/agents-config/skills/apex/templates/05-examine.md +10 -0
  29. package/agents-config/skills/apex/templates/06-resolve.md +10 -0
  30. package/agents-config/skills/apex/templates/07-tests.md +10 -0
  31. package/agents-config/skills/apex/templates/08-run-tests.md +10 -0
  32. package/agents-config/skills/apex/templates/09-finish.md +10 -0
  33. package/agents-config/skills/apex/templates/10-verify.md +9 -0
  34. package/agents-config/skills/apex/templates/README.md +195 -0
  35. package/agents-config/skills/apex/templates/step-complete.md +7 -0
  36. package/agents-config/skills/appstore-connect/SKILL.md +3 -9
  37. package/agents-config/skills/environments-manager/SKILL.md +86 -94
  38. package/agents-config/skills/environments-manager/examples/{skills/dev/SKILL.md → claude/commands/dev.md} +1 -2
  39. package/agents-config/skills/environments-manager/examples/{skills/lint/SKILL.md → claude/commands/lint.md} +1 -2
  40. package/agents-config/skills/environments-manager/examples/{skills/test/SKILL.md → claude/commands/test.md} +1 -2
  41. package/agents-config/skills/environments-manager/examples/{skills/typecheck/SKILL.md → claude/commands/typecheck.md} +1 -2
  42. package/agents-config/skills/environments-manager/examples/scripts/worktree-down.sh +5 -12
  43. package/agents-config/skills/environments-manager/examples/scripts/worktree-up.sh +11 -21
  44. package/agents-config/skills/environments-manager/references/claude.md +9 -13
  45. package/agents-config/skills/environments-manager/references/convex.md +120 -0
  46. package/agents-config/skills/environments-manager/references/cursor.md +2 -2
  47. package/agents-config/skills/environments-manager/references/postgresql.md +89 -0
  48. package/agents-config/skills/oneshot/SKILL.md +21 -37
  49. package/agents-config/skills/rules-manager/SKILL.md +15 -2
  50. package/agents-config/skills/skill-manager/SKILL.md +30 -2
  51. package/agents-config/skills/ultrathink/SKILL.md +1 -1
  52. package/agents-config/skills/use-fable/SKILL.md +64 -0
  53. package/package.json +1 -1
  54. package/agents-config/skills/appstore-connect/references/setup.md +0 -156
  55. package/agents-config/skills/appstore-connect/references/testflight.md +0 -212
@@ -0,0 +1,240 @@
1
+ ---
2
+ name: step-03-execute
3
+ description: Todo-driven implementation - execute the plan file by file
4
+ prev_step: steps/step-02-plan.md
5
+ next_step: steps/step-04-validate.md
6
+ ---
7
+
8
+ # Step 3: Execute (Implementation)
9
+
10
+ ## MANDATORY EXECUTION RULES (READ FIRST):
11
+
12
+ - 🛑 NEVER deviate from the approved plan
13
+ - 🛑 NEVER add features not in the plan (scope creep)
14
+ - 🛑 NEVER modify files without reading them first
15
+ - ✅ ALWAYS follow the plan file-by-file
16
+ - ✅ ALWAYS mark todos complete immediately after each task
17
+ - ✅ ALWAYS read files BEFORE editing them
18
+ - 📋 YOU ARE AN IMPLEMENTER following a plan, not a designer
19
+ - 💬 FOCUS on executing the plan exactly as approved
20
+ - 🚫 FORBIDDEN to add "improvements" not in the plan
21
+
22
+ ## EXECUTION PROTOCOLS:
23
+
24
+ - 🎯 Create todos from plan before starting
25
+ - 💾 Mark todos complete immediately after each task
26
+ - 📖 Read each file BEFORE modifying it
27
+ - 🚫 FORBIDDEN to have multiple todos in_progress simultaneously
28
+
29
+ ## CONTEXT BOUNDARIES:
30
+
31
+ - Plan from step-02 is approved and must be followed
32
+ - Files to modify are known from the plan
33
+ - Patterns to follow are documented from step-01
34
+ - Don't add features - stick to the plan
35
+ - **If context was cleared ("Execute and clear context"):** The plan file contains all APEX state variables in the "APEX Workflow Context" section. Read the plan file first and restore all variables before proceeding.
36
+
37
+ ## YOUR TASK:
38
+
39
+ Execute the approved implementation plan file-by-file, tracking progress with todos.
40
+
41
+ ---
42
+
43
+ <available_state>
44
+ From previous steps:
45
+
46
+ | Variable | Description |
47
+ |----------|-------------|
48
+ | `{task_description}` | What to implement |
49
+ | `{task_id}` | Kebab-case identifier |
50
+ | `{auto_mode}` | Skip confirmations |
51
+ | `{save_mode}` | Save outputs to files |
52
+ | `{output_dir}` | Path to output (if save_mode) |
53
+ | Implementation plan | File-by-file changes from step-02 |
54
+ | Patterns | How to implement from step-01 |
55
+ </available_state>
56
+
57
+ ---
58
+
59
+ ## EXECUTION SEQUENCE:
60
+
61
+ ### 1. Initialize Save Output (if save_mode)
62
+
63
+ **If `{save_mode}` = true:**
64
+
65
+ ```bash
66
+ bash {skill_dir}/scripts/update-progress.sh "{task_id}" "03" "execute" "in_progress"
67
+ ```
68
+
69
+ Append logs to `{output_dir}/03-execute.md` as you work.
70
+
71
+ ### 2. Create Todos from Plan
72
+
73
+ Convert each file change from the plan into todos:
74
+
75
+ ```
76
+ Plan entry:
77
+ #### `src/auth/handler.ts`
78
+ - Add `validateToken` function
79
+ - Handle error case: expired token
80
+
81
+ Becomes:
82
+ - [ ] src/auth/handler.ts: Add validateToken function
83
+ - [ ] src/auth/handler.ts: Handle expired token error
84
+ ```
85
+
86
+ Use TodoWrite to create the full list.
87
+
88
+ ### 3. Execute File by File
89
+
90
+ For each todo:
91
+
92
+ **3.1 Mark In Progress**
93
+ - Only ONE todo in_progress at a time
94
+
95
+ **3.2 Read Before Edit**
96
+ ```
97
+ ALWAYS read the file before modifying:
98
+ - Understand current structure
99
+ - Find exact insertion points
100
+ - Verify patterns match expectations
101
+ ```
102
+
103
+ **3.3 Implement Changes**
104
+ ```
105
+ Make changes specified in the plan:
106
+ - Follow patterns from step-01 analysis
107
+ - Use exact names from plan
108
+ - Handle error cases as specified
109
+ - NO comments unless truly necessary
110
+ ```
111
+
112
+ **3.4 Mark Complete Immediately**
113
+ - Mark todo complete RIGHT AFTER finishing
114
+ - Don't batch completions
115
+
116
+ **3.5 Log Progress (if save_mode)**
117
+ ```markdown
118
+ ### ✓ src/auth/handler.ts
119
+ - Added `validateToken` function (lines 45-78)
120
+ - Added error handling for expired tokens
121
+ **Timestamp:** {ISO}
122
+ ```
123
+
124
+ ### 4. Handle Blockers
125
+
126
+ **If `{auto_mode}` = true:**
127
+ → Make reasonable decision and continue
128
+
129
+ **If `{auto_mode}` = false:**
130
+
131
+ ```yaml
132
+ questions:
133
+ - header: "Blocker"
134
+ question: "Encountered an issue. How should we proceed?"
135
+ options:
136
+ - label: "Use alternative approach (Recommended)"
137
+ description: "Description of alternative"
138
+ - label: "Skip this part"
139
+ description: "Continue without this change"
140
+ - label: "Stop for discussion"
141
+ description: "I want to discuss before continuing"
142
+ multiSelect: false
143
+ ```
144
+
145
+ ### 5. Verify Implementation
146
+
147
+ After completing all todos:
148
+
149
+ ```bash
150
+ pnpm run typecheck && pnpm run lint --fix
151
+ ```
152
+
153
+ Fix any errors immediately.
154
+
155
+ ### 6. Implementation Summary
156
+
157
+ ```
158
+ **Implementation Complete**
159
+
160
+ **Files Modified:**
161
+ - `src/auth/handler.ts` - Added validateToken, error handling
162
+ - `src/api/auth/route.ts` - Integrated token validation
163
+
164
+ **New Files:**
165
+ - `src/types/auth.ts` - Auth type definitions
166
+
167
+ **Todos:** {X}/{Y} complete
168
+ ```
169
+
170
+ **If `{auto_mode}` = true:**
171
+ → Proceed to validation
172
+
173
+ **If `{auto_mode}` = false:**
174
+
175
+ ```yaml
176
+ questions:
177
+ - header: "Execute"
178
+ question: "Implementation complete. Ready to validate?"
179
+ options:
180
+ - label: "Proceed to validation (Recommended)"
181
+ description: "Run typecheck, lint, and tests"
182
+ - label: "Review changes"
183
+ description: "I want to review what was changed"
184
+ - label: "Make adjustments"
185
+ description: "I want to modify something"
186
+ multiSelect: false
187
+ ```
188
+
189
+ ### 7. Complete Save Output (if save_mode)
190
+
191
+ **If `{save_mode}` = true:**
192
+
193
+ Append to `{output_dir}/03-execute.md`:
194
+ ```markdown
195
+ ---
196
+ ## Step Complete
197
+ **Status:** ✓ Complete
198
+ **Files modified:** {count}
199
+ **Todos completed:** {count}
200
+ **Next:** step-04-validate.md
201
+ **Timestamp:** {ISO timestamp}
202
+ ```
203
+
204
+ ---
205
+
206
+ ## SUCCESS METRICS:
207
+
208
+ ✅ All plan items implemented
209
+ ✅ All todos marked complete
210
+ ✅ No scope creep - only plan items
211
+ ✅ Files read before modification
212
+ ✅ Typecheck and lint pass
213
+ ✅ Progress logged (if save_mode)
214
+
215
+ ## FAILURE MODES:
216
+
217
+ ❌ Adding features not in the plan
218
+ ❌ Modifying files without reading first
219
+ ❌ Not updating todos as you work
220
+ ❌ Multiple todos in_progress simultaneously
221
+ ❌ Ignoring type or lint errors
222
+ ❌ **CRITICAL**: Not using AskUserQuestion for blockers
223
+
224
+ ## EXECUTION PROTOCOLS:
225
+
226
+ - Follow the plan EXACTLY
227
+ - Read before write
228
+ - One file at a time
229
+ - Update todos in real-time
230
+ - Fix errors immediately
231
+
232
+ ---
233
+
234
+ ## NEXT STEP:
235
+
236
+ After implementation complete, load `./step-04-validate.md`
237
+
238
+ <critical>
239
+ Remember: Execution is about following the plan - don't redesign or add features!
240
+ </critical>
@@ -0,0 +1,272 @@
1
+ ---
2
+ name: step-04-validate
3
+ description: Self-check - run tests, verify AC, audit implementation quality
4
+ prev_step: steps/step-03-execute.md
5
+ next_step: steps/step-05-examine.md
6
+ ---
7
+
8
+ # Step 4: Validate (Self-Check)
9
+
10
+ ## MANDATORY EXECUTION RULES (READ FIRST):
11
+
12
+ - 🛑 NEVER claim checks pass when they don't
13
+ - 🛑 NEVER skip any validation step
14
+ - ✅ ALWAYS run typecheck, lint, and tests
15
+ - ✅ ALWAYS verify each acceptance criterion
16
+ - ✅ ALWAYS fix failures before proceeding
17
+ - 📋 YOU ARE A VALIDATOR, not an implementer
18
+ - 💬 FOCUS on "Does it work correctly?"
19
+ - 🚫 FORBIDDEN to proceed with failing checks
20
+
21
+ ## EXECUTION PROTOCOLS:
22
+
23
+ - 🎯 Run all validation commands
24
+ - 💾 Log results to output (if save_mode)
25
+ - 📖 Check each AC against implementation
26
+ - 🚫 FORBIDDEN to mark complete with failures
27
+
28
+ ## CONTEXT BOUNDARIES:
29
+
30
+ - Implementation from step-03 (or step-03-execute-teams) is complete
31
+ - Tests may or may not pass yet
32
+ - Type errors may exist
33
+ - Focus is on verification, not new implementation
34
+ - **If `{teams_mode}` = true:** The agent team is still alive. Do NOT shutdown or dismiss teammates. Team shutdown happens in step-09-finish only.
35
+
36
+ ## YOUR TASK:
37
+
38
+ Validate the implementation by running checks, verifying acceptance criteria, and ensuring quality.
39
+
40
+ ---
41
+
42
+ <available_state>
43
+ From previous steps:
44
+
45
+ | Variable | Description |
46
+ |----------|-------------|
47
+ | `{task_description}` | What was implemented |
48
+ | `{task_id}` | Kebab-case identifier |
49
+ | `{acceptance_criteria}` | Success criteria |
50
+ | `{auto_mode}` | Skip confirmations |
51
+ | `{save_mode}` | Save outputs to files |
52
+ | `{test_mode}` | Include test steps |
53
+ | `{examine_mode}` | Auto-proceed to review |
54
+ | `{output_dir}` | Path to output (if save_mode) |
55
+ | Implementation | Completed in step-03 |
56
+ </available_state>
57
+
58
+ ---
59
+
60
+ ## EXECUTION SEQUENCE:
61
+
62
+ ### 1. Initialize Save Output (if save_mode)
63
+
64
+ **If `{save_mode}` = true:**
65
+
66
+ ```bash
67
+ bash {skill_dir}/scripts/update-progress.sh "{task_id}" "04" "validate" "in_progress"
68
+ ```
69
+
70
+ Append results to `{output_dir}/04-validate.md` as you work.
71
+
72
+ ### 2. Discover Available Commands
73
+
74
+ Check `package.json` for exact command names:
75
+ ```bash
76
+ cat package.json | grep -A 20 '"scripts"'
77
+ ```
78
+
79
+ Look for: `typecheck`, `lint`, `test`, `build`, `format`
80
+
81
+ ### 3. Run Validation Suite
82
+
83
+ **3.1 Typecheck**
84
+ ```bash
85
+ pnpm run typecheck # or npm run typecheck
86
+ ```
87
+
88
+ **MUST PASS.** If fails:
89
+ 1. Read error messages
90
+ 2. Fix type issues
91
+ 3. Re-run until passing
92
+
93
+ **3.2 Lint**
94
+ ```bash
95
+ pnpm run lint
96
+ ```
97
+
98
+ **MUST PASS.** If fails:
99
+ 1. Try auto-fix: `pnpm run lint --fix`
100
+ 2. Manually fix remaining
101
+ 3. Re-run until passing
102
+
103
+ **3.3 Tests**
104
+ ```bash
105
+ pnpm run test -- --filter={affected-area}
106
+ ```
107
+
108
+ **MUST PASS.** If fails:
109
+ 1. Identify failing test
110
+ 2. Determine if code bug or test bug
111
+ 3. Fix the root cause
112
+ 4. Re-run until passing
113
+
114
+ **If `{save_mode}` = true:** Log each result
115
+
116
+ ### 4. Self-Audit Checklist
117
+
118
+ Verify each item:
119
+
120
+ **Tasks Complete:**
121
+ - [ ] All todos from step-03 marked complete
122
+ - [ ] No tasks skipped without reason
123
+ - [ ] Any blocked tasks have explanation
124
+
125
+ **Tests Passing:**
126
+ - [ ] All existing tests pass
127
+ - [ ] New tests written for new functionality
128
+ - [ ] No skipped tests without reason
129
+
130
+ **Acceptance Criteria:**
131
+ - [ ] Each AC demonstrably met
132
+ - [ ] Can explain how implementation satisfies AC
133
+ - [ ] Edge cases considered
134
+
135
+ **Patterns Followed:**
136
+ - [ ] Code follows existing patterns
137
+ - [ ] Error handling consistent
138
+ - [ ] Naming conventions match
139
+
140
+ ### 5. Format Code
141
+
142
+ If format command available:
143
+ ```bash
144
+ pnpm run format
145
+ ```
146
+
147
+ ### 6. Final Verification
148
+
149
+ Re-run all checks:
150
+ ```bash
151
+ pnpm run typecheck && pnpm run lint
152
+ ```
153
+
154
+ Both MUST pass.
155
+
156
+ ### 7. Present Validation Results
157
+
158
+ ```
159
+ **Validation Complete**
160
+
161
+ **Typecheck:** ✓ Passed
162
+ **Lint:** ✓ Passed
163
+ **Tests:** ✓ {X}/{X} passing
164
+ **Format:** ✓ Applied
165
+
166
+ **Acceptance Criteria:**
167
+ - [✓] AC1: Verified by [how]
168
+ - [✓] AC2: Verified by [how]
169
+
170
+ **Files Modified:** {list}
171
+
172
+ **Summary:** All checks passing, ready for next step.
173
+ ```
174
+
175
+ ### 8. Determine Next Step
176
+
177
+ **Decision tree:**
178
+
179
+ ```
180
+ IF {test_mode} = true:
181
+ → Load step-07-tests.md (test analysis and creation)
182
+
183
+ ELSE IF {examine_mode} = true:
184
+ → Load step-05-examine.md (adversarial review)
185
+
186
+ ELSE IF {verify_mode} = true:
187
+ → Load step-10-verify.md (feature verification)
188
+
189
+ ELSE IF {auto_mode} = false:
190
+ → Ask user:
191
+ ```
192
+
193
+ ```yaml
194
+ questions:
195
+ - header: "Next"
196
+ question: "Validation complete. What would you like to do?"
197
+ options:
198
+ - label: "Run adversarial review"
199
+ description: "Deep review for security, logic, and quality"
200
+ - label: "Verify feature"
201
+ description: "Launch app and test feature works"
202
+ - label: "Complete workflow"
203
+ description: "Skip review and finalize"
204
+ - label: "Add tests"
205
+ description: "Create additional tests first"
206
+ multiSelect: false
207
+ ```
208
+
209
+ ```
210
+ ELSE:
211
+ → Complete workflow (show final summary)
212
+ ```
213
+
214
+ ### 9. Complete Save Output (if save_mode)
215
+
216
+ **If `{save_mode}` = true:**
217
+
218
+ Append to `{output_dir}/04-validate.md`:
219
+ ```markdown
220
+ ---
221
+ ## Step Complete
222
+ **Status:** ✓ Complete
223
+ **Typecheck:** ✓
224
+ **Lint:** ✓
225
+ **Tests:** ✓
226
+ **Next:** {next step based on flags}
227
+ **Timestamp:** {ISO timestamp}
228
+ ```
229
+
230
+ ---
231
+
232
+ ## SUCCESS METRICS:
233
+
234
+ ✅ Typecheck passes
235
+ ✅ Lint passes
236
+ ✅ All tests pass
237
+ ✅ All AC verified
238
+ ✅ Code formatted
239
+ ✅ User informed of status
240
+
241
+ ## FAILURE MODES:
242
+
243
+ ❌ Claiming checks pass when they don't
244
+ ❌ Not running all validation commands
245
+ ❌ Skipping tests for modified code
246
+ ❌ Missing AC verification
247
+ ❌ Proceeding with failures
248
+ ❌ **CRITICAL**: Not using AskUserQuestion for next step
249
+
250
+ ## VALIDATION PROTOCOLS:
251
+
252
+ - Run EVERY validation command
253
+ - Fix failures IMMEDIATELY
254
+ - Don't proceed until all green
255
+ - Verify EACH acceptance criterion
256
+ - Document all results
257
+
258
+ ---
259
+
260
+ ## NEXT STEP:
261
+
262
+ Based on flags (check in order):
263
+ - **If test_mode:** Load `./step-07-tests.md`
264
+ - **If examine_mode OR user requests:** Load `./step-05-examine.md`
265
+ - **If verify_mode:** Load `./step-10-verify.md` to verify feature
266
+ - **If pr_mode:** Load `./step-09-finish.md` to create pull request
267
+ - **Otherwise:** Workflow complete - show summary
268
+
269
+ <critical>
270
+ Remember: NEVER proceed with failing checks - fix everything first!
271
+ If teams_mode is active: NEVER shutdown teammates - they stay alive until step-09-finish!
272
+ </critical>