@sleighmaster/bmad 1.5.11 → 1.5.13
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.
|
@@ -54,11 +54,29 @@
|
|
|
54
54
|
3. **Code Quality**: Security, performance, maintainability
|
|
55
55
|
4. **Test Quality**: Real tests vs placeholder bullshit
|
|
56
56
|
</action>
|
|
57
|
+
|
|
58
|
+
<!-- Initialize review loop counter -->
|
|
59
|
+
<action>Set {{review_round}} = 0</action>
|
|
60
|
+
<action>Set {{cumulative_fixed}} = 0</action>
|
|
57
61
|
</step>
|
|
58
62
|
|
|
59
63
|
<step n="3" goal="Execute adversarial review">
|
|
60
64
|
<critical>VALIDATE EVERY CLAIM - Check git reality vs story claims</critical>
|
|
61
65
|
|
|
66
|
+
<!-- Review loop tracking -->
|
|
67
|
+
<action>Set {{review_round}} = {{review_round}} + 1</action>
|
|
68
|
+
<check if="{{review_round}} gt 1">
|
|
69
|
+
<critical>⚠️ THIS IS NOT A VERIFICATION PASS — THIS IS A FULL ADVERSARIAL RE-REVIEW FROM SCRATCH.
|
|
70
|
+
You MUST NOT assume your fixes are correct. You have confirmation bias — fight it.
|
|
71
|
+
Treat this round as if a DIFFERENT reviewer is seeing the code for the first time.
|
|
72
|
+
Execute ALL checks below (AC Validation, Task Audit, Code Quality) with the SAME rigor as Round 1.
|
|
73
|
+
"Re-read modified files" means read EVERY file in the comprehensive review list, not just the ones you touched.</critical>
|
|
74
|
+
<output>🔄 **Re-review Round {{review_round}}** — FULL adversarial re-review (not just fix verification)...</output>
|
|
75
|
+
<action>Re-read ALL files in the comprehensive review list (not just files modified in the previous round)</action>
|
|
76
|
+
<action>Re-run git status/diff to capture latest changes</action>
|
|
77
|
+
<action>Re-extract ALL Acceptance Criteria and Tasks from the story file (do NOT rely on memory from previous rounds)</action>
|
|
78
|
+
</check>
|
|
79
|
+
|
|
62
80
|
<!-- Git vs Story Discrepancies -->
|
|
63
81
|
<action>Review git vs story File List discrepancies:
|
|
64
82
|
1. **Files changed but not in story File List** → MEDIUM finding (incomplete documentation)
|
|
@@ -106,20 +124,47 @@
|
|
|
106
124
|
</action>
|
|
107
125
|
<action>Find at least 3 more specific, actionable issues</action>
|
|
108
126
|
</check>
|
|
127
|
+
|
|
128
|
+
<!-- Mandatory review evidence output — required EVERY round before proceeding to Step 4 -->
|
|
129
|
+
<critical>You MUST output the following structured evidence checklist BEFORE proceeding to Step 4.
|
|
130
|
+
If you cannot fill in specific evidence for each section, you have NOT completed the review.
|
|
131
|
+
Do NOT proceed to Step 4 until every section has concrete evidence.</critical>
|
|
132
|
+
<output>### 📋 Review Evidence (Round {{review_round}})
|
|
133
|
+
|
|
134
|
+
**Files Actually Read This Round:** [list every file path you read]
|
|
135
|
+
|
|
136
|
+
**AC Verification:**
|
|
137
|
+
{{for each AC}}
|
|
138
|
+
- AC#{{n}}: {{IMPLEMENTED|PARTIAL|MISSING}} — Evidence: {{file:line or specific code reference}}
|
|
139
|
+
{{/for}}
|
|
140
|
+
|
|
141
|
+
**Task Audit:**
|
|
142
|
+
{{for each [x] task}}
|
|
143
|
+
- Task {{n}}: {{VERIFIED|NOT DONE}} — Evidence: {{file:line or specific code reference}}
|
|
144
|
+
{{/for}}
|
|
145
|
+
|
|
146
|
+
**Security/Performance Spot-Check:**
|
|
147
|
+
- Checked: {{list specific checks performed with file references}}
|
|
148
|
+
|
|
149
|
+
**Issues Found This Round:** {{count}} ({{high}} HIGH, {{medium}} MEDIUM, {{low}} LOW)
|
|
150
|
+
</output>
|
|
109
151
|
</step>
|
|
110
152
|
|
|
111
|
-
<step n="4" goal="
|
|
153
|
+
<step n="4" goal="Record findings, auto-fix, and loop until clean">
|
|
154
|
+
<critical>This step automatically records findings → fixes code → loops back to Step 3 for re-review until no HIGH/MEDIUM issues remain</critical>
|
|
155
|
+
|
|
156
|
+
<!-- 4a. Categorize and present findings -->
|
|
112
157
|
<action>Categorize findings: HIGH (must fix), MEDIUM (should fix), LOW (nice to fix)</action>
|
|
113
158
|
<action>Set {{fixed_count}} = 0</action>
|
|
114
159
|
<action>Set {{action_count}} = 0</action>
|
|
115
160
|
|
|
116
|
-
<output>**🔥 CODE REVIEW FINDINGS, {user_name}!**
|
|
161
|
+
<output>**🔥 CODE REVIEW FINDINGS (Round {{review_round}}), {user_name}!**
|
|
117
162
|
|
|
118
163
|
**Story:** {{story_file}}
|
|
119
164
|
**Git vs Story Discrepancies:** {{git_discrepancy_count}} found
|
|
120
165
|
**Issues Found:** {{high_count}} High, {{medium_count}} Medium, {{low_count}} Low
|
|
121
166
|
|
|
122
|
-
## 🔴 CRITICAL ISSUES
|
|
167
|
+
## 🔴 CRITICAL/HIGH ISSUES
|
|
123
168
|
- Tasks marked [x] but not actually implemented
|
|
124
169
|
- Acceptance Criteria not implemented
|
|
125
170
|
- Story claims files changed but no git evidence
|
|
@@ -138,33 +183,34 @@
|
|
|
138
183
|
- Git commit message quality
|
|
139
184
|
</output>
|
|
140
185
|
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
186
|
+
<!-- 4b. Record findings in story file (document BEFORE fixing) -->
|
|
187
|
+
<action>Add or update "Review Follow-ups (AI) — Round {{review_round}}" subsection in Tasks/Subtasks</action>
|
|
188
|
+
<action>For each HIGH and MEDIUM issue: `- [ ] [AI-Review][Round {{review_round}}][{{Severity}}] {{Description}} [{{file}}:{{line}}]`</action>
|
|
189
|
+
<action>For each LOW issue: `- [ ] [AI-Review][Round {{review_round}}][LOW] {{Description}} [{{file}}:{{line}}]`</action>
|
|
190
|
+
<action>Set {{action_count}} = number of action items recorded</action>
|
|
191
|
+
|
|
192
|
+
<!-- 4c. Check if there are any issues to fix -->
|
|
193
|
+
<check if="{{high_count}} + {{medium_count}} + {{low_count}} == 0">
|
|
194
|
+
<!-- No issues at all — review is clean -->
|
|
195
|
+
<output>✅ **No issues found! Code is clean.**</output>
|
|
196
|
+
<!-- Proceed to Step 5 (completion) -->
|
|
197
|
+
</check>
|
|
148
198
|
|
|
149
|
-
<check if="
|
|
150
|
-
|
|
199
|
+
<check if="{{high_count}} + {{medium_count}} + {{low_count}} gt 0">
|
|
200
|
+
<!-- 4d. Auto-fix all issues (HIGH, MEDIUM, and LOW) -->
|
|
201
|
+
<output>🔧 **Auto-fixing {{high_count}} HIGH + {{medium_count}} MEDIUM + {{low_count}} LOW issues...**</output>
|
|
202
|
+
<action>Fix all HIGH, MEDIUM, and LOW issues in the code</action>
|
|
151
203
|
<action>Add/update tests as needed</action>
|
|
152
204
|
<action>Update File List in story if files changed</action>
|
|
153
205
|
<action>Update story Dev Agent Record with fixes applied</action>
|
|
154
|
-
<action>Set {{fixed_count}} = number of
|
|
155
|
-
<action>
|
|
156
|
-
|
|
206
|
+
<action>Set {{fixed_count}} = number of all issues fixed</action>
|
|
207
|
+
<action>Mark fixed items with [x] in "Review Follow-ups (AI)" section</action>
|
|
208
|
+
<action>Set {{cumulative_fixed}} = {{cumulative_fixed}} + {{fixed_count}}</action>
|
|
157
209
|
|
|
158
|
-
|
|
159
|
-
<action>Add "Review Follow-ups (AI)" subsection to Tasks/Subtasks</action>
|
|
160
|
-
<action>For each issue: `- [ ] [AI-Review][Severity] Description [file:line]`</action>
|
|
161
|
-
<action>Set {{action_count}} = number of action items created</action>
|
|
162
|
-
<action>Set {{fixed_count}} = 0</action>
|
|
163
|
-
</check>
|
|
210
|
+
<output>🔧 **Round {{review_round}} fixes applied:** {{fixed_count}} issues fixed. Looping back for re-review...</output>
|
|
164
211
|
|
|
165
|
-
|
|
166
|
-
<
|
|
167
|
-
<action>Return to fix decision</action>
|
|
212
|
+
<!-- Loop back to Step 3 for FULL re-review — not just verification of fixes -->
|
|
213
|
+
<goto step="3" scope="FULL" depth="adversarial">Full adversarial re-review — re-execute ALL checks from scratch, not just verify fixes</goto>
|
|
168
214
|
</check>
|
|
169
215
|
</step>
|
|
170
216
|
|
|
@@ -217,10 +263,10 @@
|
|
|
217
263
|
<output>**✅ Review Complete!**
|
|
218
264
|
|
|
219
265
|
**Story Status:** {{new_status}}
|
|
220
|
-
**
|
|
221
|
-
**
|
|
266
|
+
**Review Rounds:** {{review_round}}
|
|
267
|
+
**Total Issues Fixed:** {{cumulative_fixed}}
|
|
222
268
|
|
|
223
|
-
{{#if new_status == "done"}}Code review complete!{{else}}
|
|
269
|
+
{{#if new_status == "done"}}Code review complete — all issues resolved!{{else}}Some issues could not be resolved. Check story file for details.{{/if}}
|
|
224
270
|
</output>
|
|
225
271
|
</step>
|
|
226
272
|
|