macca-method 2.0.0 â 2.1.2
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/.agents/macca-lock.json +1 -1
- package/.agents/skills/_shared/references/brainstorm-session.md +5 -5
- package/.agents/skills/_shared/references/fix-mode.md +18 -3
- package/.agents/skills/_shared/references/human-loop.md +1 -1
- package/.agents/skills/_shared/references/invocation-policy.md +20 -20
- package/.agents/skills/_shared/references/language-config.md +7 -5
- package/.agents/skills/_shared/references/output-ownership.md +11 -11
- package/.agents/skills/_shared/references/scope-rules.md +1 -1
- package/.agents/skills/_shared/references/skill-catalog.md +20 -20
- package/.agents/skills/_shared/scripts/validate-skills.py +37 -15
- package/.agents/skills/add-feature/SKILL.md +11 -3
- package/.agents/skills/antislop-copywriting/SKILL.md +372 -0
- package/.agents/skills/brainstorm-api/SKILL.md +33 -19
- package/.agents/skills/brainstorm-api/assets/api.template.md +35 -15
- package/.agents/skills/brainstorm-architecture/SKILL.md +40 -18
- package/.agents/skills/brainstorm-architecture/assets/architecture.template.md +44 -25
- package/.agents/skills/brainstorm-prd/SKILL.md +52 -20
- package/.agents/skills/brainstorm-prd/assets/PRD.template.md +47 -23
- package/.agents/skills/brainstorm-rules/SKILL.md +39 -22
- package/.agents/skills/brainstorm-rules/assets/rules.template.md +32 -18
- package/.agents/skills/brainstorm-schema/SKILL.md +23 -11
- package/.agents/skills/brainstorm-schema/assets/schema.template.md +25 -10
- package/.agents/skills/brainstorm-styleguide/SKILL.md +40 -22
- package/.agents/skills/brainstorm-styleguide/assets/StyleGuide.template.md +78 -60
- package/.agents/skills/brainstorm-task/SKILL.md +29 -14
- package/.agents/skills/brainstorm-task/assets/Task.template.md +29 -18
- package/.agents/skills/bug-fix/SKILL.md +39 -8
- package/.agents/skills/code-review/SKILL.md +9 -7
- package/.agents/skills/code-review/references/review-checklist.md +21 -10
- package/.agents/skills/developer/SKILL.md +10 -0
- package/.agents/skills/developer/references/execute-task.md +13 -7
- package/.agents/skills/developer/references/onboarding.md +1 -1
- package/.agents/skills/help/SKILL.md +39 -23
- package/.agents/skills/meet/SKILL.md +11 -4
- package/.agents/skills/quick-dev/SKILL.md +29 -22
- package/.agents/skills/release-readiness/SKILL.md +19 -13
- package/.agents/skills/skill-creator/LICENSE.txt +202 -0
- package/.agents/skills/skill-creator/SKILL.md +485 -0
- package/.agents/skills/skill-creator/agents/analyzer.md +274 -0
- package/.agents/skills/skill-creator/agents/comparator.md +202 -0
- package/.agents/skills/skill-creator/agents/grader.md +223 -0
- package/.agents/skills/skill-creator/assets/eval_review.html +146 -0
- package/.agents/skills/skill-creator/eval-viewer/generate_review.py +471 -0
- package/.agents/skills/skill-creator/eval-viewer/viewer.html +1325 -0
- package/.agents/skills/skill-creator/references/schemas.md +441 -0
- package/.agents/skills/skill-creator/scripts/__init__.py +0 -0
- package/.agents/skills/skill-creator/scripts/aggregate_benchmark.py +401 -0
- package/.agents/skills/skill-creator/scripts/generate_report.py +326 -0
- package/.agents/skills/skill-creator/scripts/improve_description.py +247 -0
- package/.agents/skills/skill-creator/scripts/package_skill.py +136 -0
- package/.agents/skills/skill-creator/scripts/quick_validate.py +103 -0
- package/.agents/skills/skill-creator/scripts/run_eval.py +310 -0
- package/.agents/skills/skill-creator/scripts/run_loop.py +328 -0
- package/.agents/skills/skill-creator/scripts/utils.py +47 -0
- package/.agents/skills/spec-audit/SKILL.md +33 -4
- package/.agents/skills/spec-compliance/SKILL.md +36 -21
- package/.agents/skills/spec-init/SKILL.md +31 -17
- package/README.md +165 -129
- package/bin/macca-method.js +1378 -1077
- package/package.json +40 -40
- package/scripts/run-skill-validator.js +27 -9
- package/scripts/test-install.js +611 -337
- package/scripts/test-upgrade-legacy.js +131 -76
- package/scripts/validate-skill-behavior.js +175 -64
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: brainstorm-task
|
|
3
|
-
description: Generates
|
|
3
|
+
description: Generates or updates project-context/Task.md with phased, verifiable tasks derived directly from completed specs. Use after architecture.md and relevant domain specs exist, when planning sprint tasks, or when adding an approved phase from add-feature. Do NOT use to brainstorm new product scope from scratch.
|
|
4
4
|
compatibility: Requires the complete MACCA-METHOD collection with sibling _shared resources and workspace file access.
|
|
5
5
|
metadata:
|
|
6
6
|
persona: "Galbi"
|
|
@@ -11,6 +11,8 @@ metadata:
|
|
|
11
11
|
|
|
12
12
|
## Shared Runtime Setup
|
|
13
13
|
|
|
14
|
+
Paths written as `../...` below are relative to this SKILL.md's own folder, not the project's working directory - resolve them as a sibling of the folder that contains this file.
|
|
15
|
+
|
|
14
16
|
Before starting:
|
|
15
17
|
|
|
16
18
|
1. Read `../_shared/references/language-config.md`.
|
|
@@ -32,6 +34,7 @@ Run as `@Galbi` (Project Manager). Use the shared persona profile in `../_shared
|
|
|
32
34
|
You are an **Engineering Manager & Scrum Master** who breaks large work into small, structured, ordered, verifiable tasks.
|
|
33
35
|
|
|
34
36
|
**Expertise:**
|
|
37
|
+
|
|
35
38
|
- Sprint planning and task breakdown from spec documents
|
|
36
39
|
- Identifying task dependencies and logical execution order
|
|
37
40
|
- Writing concrete, testable acceptance criteria per task
|
|
@@ -54,10 +57,12 @@ This skill generates **Task.md**: a work plan derived from existing spec documen
|
|
|
54
57
|
|
|
55
58
|
**Detect mode before starting:**
|
|
56
59
|
Check whether `project-context/Task.md` already exists.
|
|
60
|
+
|
|
57
61
|
- **Does not exist yet** â follow the steps below (New Generate Mode).
|
|
58
62
|
- **Already exists** (usually called from `add-feature`) â enter **Add Phase Mode**: skip clarification topics 1 and 3, ask only topic 2, append the approved phases/tasks, and update header counts/date, Progress Overview, dependencies, and Traceability Matrix. Preserve unrelated existing phases and IDs.
|
|
59
63
|
|
|
60
64
|
**Scope rules:**
|
|
65
|
+
|
|
61
66
|
- `frontend` â generate frontend tasks only
|
|
62
67
|
- `backend` â generate backend tasks only
|
|
63
68
|
- `fullstack` â generate the full task set
|
|
@@ -65,6 +70,7 @@ Check whether `project-context/Task.md` already exists.
|
|
|
65
70
|
**Session setup (ask before clarification):**
|
|
66
71
|
|
|
67
72
|
Run the shared runtime setup first. Announce how many clarification topics apply in the current mode, then apply the stored pacing and recommendation preferences. If they are not stored yet, ask both before starting:
|
|
73
|
+
|
|
68
74
|
```
|
|
69
75
|
This session has [N] clarification topics.
|
|
70
76
|
1. Pacing: (A) one by one (B) three at once (C) all at once
|
|
@@ -88,54 +94,63 @@ This session has [N] clarification topics.
|
|
|
88
94
|
|
|
89
95
|
## Clarification Topics (4 Short)
|
|
90
96
|
|
|
91
|
-
|
|
97
|
+
_This is not a fresh brainstorm. It is only clarification before task generation._
|
|
92
98
|
|
|
93
99
|
### 1. Phase Priority Order
|
|
94
|
-
|
|
100
|
+
|
|
101
|
+
**Ask:** _"Based on the PRD, I will organize the work into phases. Is there a preferred order, or should I use the standard: Setup â Auth â Core Features â UI â Testing?"_
|
|
95
102
|
|
|
96
103
|
**Collect:**
|
|
104
|
+
|
|
97
105
|
- Which features must be finished first?
|
|
98
106
|
- Any deadline per phase?
|
|
99
107
|
|
|
100
108
|
### 2. Task Granularity
|
|
101
|
-
|
|
109
|
+
|
|
110
|
+
**Ask:** _"How small should the tasks be? Should one task equal one file, or one full feature?"_
|
|
102
111
|
|
|
103
112
|
**Collect:**
|
|
113
|
+
|
|
104
114
|
- Atomic (very small, one task = one file/function) â good for strict review
|
|
105
115
|
- Modular (medium, one task = one endpoint or component)
|
|
106
116
|
- Feature-based (large, one task = one full end-to-end feature)
|
|
107
117
|
|
|
108
118
|
### 3. Execution Rules
|
|
109
|
-
|
|
119
|
+
|
|
120
|
+
**Ask:** _"While working through tasks, should I stop for confirmation after each task, or continue automatically per phase?"_
|
|
110
121
|
|
|
111
122
|
**Collect:**
|
|
123
|
+
|
|
112
124
|
- Stop after each task for review? (safer, slower)
|
|
113
125
|
- Stop after each phase? (faster, milestone review)
|
|
114
126
|
- Commit after every task?
|
|
115
127
|
|
|
116
128
|
Update the **Execution Rules** section in Task.md from the answer:
|
|
129
|
+
|
|
117
130
|
- Choose **per-task**: `"After each task is complete, STOP and wait for user confirmation before continuing."`
|
|
118
131
|
- Choose **per-phase** (default if no preference): `"After each phase is complete, STOP and wait before starting the next phase."`
|
|
119
132
|
|
|
120
133
|
### 4. Verify Available Documents
|
|
134
|
+
|
|
121
135
|
**Do not ask the user**. Check `project-context/` yourself:
|
|
122
136
|
Files: `PRD.md`, `architecture.md`, `schema.md`, `api.md`, `rules.md`, `StyleGuide.md`
|
|
123
137
|
|
|
124
138
|
**architecture.md is required** â if it does not exist, **STOP** and ask the user to run `brainstorm-architecture` first.
|
|
125
139
|
|
|
126
140
|
If another document required by the declared scope is missing, inform the user and obtain one continuation decision:
|
|
127
|
-
|
|
141
|
+
|
|
142
|
+
> _"I checked: `project-context/[filename]` was not found. It is recommended to complete it first so tasks are more accurate. Continue with the available documents?"_
|
|
128
143
|
|
|
129
144
|
## Deep Analysis (Before Creating Tasks)
|
|
130
145
|
|
|
131
146
|
Before writing `Task.md`, analyze internally:
|
|
132
147
|
|
|
133
|
-
1. Read `PRD.md` â list all MVP features â this is the task scope
|
|
134
|
-
2. Read `StyleGuide.md` â CSS framework, base components â include styling setup and base component tasks
|
|
135
|
-
3. Read `architecture.md` â tech stack and folder structure â determines which files need to be created
|
|
136
|
-
4. Read `schema.md` â map each datastore-native entity/collection/aggregate/stream to the migrations, validation, model, projection, or infrastructure tasks its architecture actually requires
|
|
137
|
-
5. Read `api.md` â map each REST endpoint, GraphQL operation, RPC procedure, or event contract to protocol-native implementation and contract-test tasks
|
|
138
|
-
6. Read `rules.md` â coding standards â include tasks for ESLint, Prettier, tsconfig setup?
|
|
148
|
+
1. Read `project-context/PRD.md` â list all MVP features â this is the task scope
|
|
149
|
+
2. Read `project-context/StyleGuide.md` â CSS framework, base components â include styling setup and base component tasks
|
|
150
|
+
3. Read `project-context/architecture.md` â tech stack and folder structure â determines which files need to be created
|
|
151
|
+
4. Read `project-context/schema.md` â map each datastore-native entity/collection/aggregate/stream to the migrations, validation, model, projection, or infrastructure tasks its architecture actually requires
|
|
152
|
+
5. Read `project-context/api.md` â map each REST endpoint, GraphQL operation, RPC procedure, or event contract to protocol-native implementation and contract-test tasks
|
|
153
|
+
6. Read `project-context/rules.md` â coding standards â include tasks for ESLint, Prettier, tsconfig setup?
|
|
139
154
|
7. Identify task dependencies (database before model, model before service, service before controller)
|
|
140
155
|
8. **Testing workflow:** Follow the policy in `rules.md`. If it requires test-first/TDD, precede implementation with a test task. Otherwise pair each behavior change with the test/verification task required by the approved rules. Do not force TDD against project policy.
|
|
141
156
|
9. If the specs mention security controls, create explicit security tasks â do not leave them implicit. Examples: auth guards, ownership checks, input validation, secure cookie config, rate limiting, CSRF protection, audit logs, data masking.
|
|
@@ -144,7 +159,7 @@ Before writing `Task.md`, analyze internally:
|
|
|
144
159
|
|
|
145
160
|
After analysis, **show the scope summary to the user**:
|
|
146
161
|
|
|
147
|
-
|
|
162
|
+
```text
|
|
148
163
|
From the available specs, I identified this scope:
|
|
149
164
|
|
|
150
165
|
Features to implement:
|
|
@@ -160,7 +175,7 @@ Security controls to implement:
|
|
|
160
175
|
- [control 2]
|
|
161
176
|
|
|
162
177
|
Is this scope correct? Anything to add or remove?
|
|
163
|
-
|
|
178
|
+
```
|
|
164
179
|
|
|
165
180
|
Wait for user confirmation before creating Task.md.
|
|
166
181
|
|
|
@@ -3,21 +3,24 @@
|
|
|
3
3
|
> **Total Phases:** [X] | **Total Tasks:** [Y] | **Last Updated:** [date]
|
|
4
4
|
|
|
5
5
|
## Document Role
|
|
6
|
+
|
|
6
7
|
- **Source of Truth:** Execution plan derived from approved spec documents
|
|
7
8
|
- **Primary Owner:** `brainstorm-task`
|
|
8
9
|
- **Out of Scope:** New product scope, new schema/API decisions, and code quality review findings
|
|
9
10
|
|
|
10
11
|
## Upstream Dependencies
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
|
12
|
+
|
|
13
|
+
| Topic | Canonical Source |
|
|
14
|
+
| ------------------- | --------------------------------- |
|
|
15
|
+
| Product scope | `project-context/PRD.md` |
|
|
14
16
|
| Technical structure | `project-context/architecture.md` |
|
|
15
|
-
| Data contract
|
|
16
|
-
| API contract
|
|
17
|
-
| UI contract
|
|
18
|
-
| Coding rules
|
|
17
|
+
| Data contract | `project-context/schema.md` |
|
|
18
|
+
| API contract | `project-context/api.md` |
|
|
19
|
+
| UI contract | `project-context/StyleGuide.md` |
|
|
20
|
+
| Coding rules | `project-context/rules.md` |
|
|
19
21
|
|
|
20
22
|
## Execution Rules
|
|
23
|
+
|
|
21
24
|
- Work on tasks **one by one** in order within each phase.
|
|
22
25
|
- After each **phase** is complete, **STOP** and wait for user confirmation before the next phase.
|
|
23
26
|
- Update status `[ ]` to `[x]` when a task is complete.
|
|
@@ -26,13 +29,15 @@
|
|
|
26
29
|
---
|
|
27
30
|
|
|
28
31
|
## Progress Overview
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
|
32
|
-
|
|
|
33
|
-
|
|
|
32
|
+
|
|
33
|
+
| Phase | Name | Status | Progress |
|
|
34
|
+
| ----- | ----------------------- | ------ | -------- |
|
|
35
|
+
| 1 | [Setup & Configuration] | [ ] | 0/3 |
|
|
36
|
+
| 2 | [Database & Models] | [ ] | 0/4 |
|
|
37
|
+
| 3 | [Backend: Auth] | [ ] | 0/3 |
|
|
34
38
|
|
|
35
39
|
## AI Read Order
|
|
40
|
+
|
|
36
41
|
1. Read `Execution Rules`
|
|
37
42
|
2. Read `Progress Overview`
|
|
38
43
|
3. Read only the current phase
|
|
@@ -41,10 +46,12 @@
|
|
|
41
46
|
---
|
|
42
47
|
|
|
43
48
|
## Phase 1: [Phase Name]
|
|
49
|
+
|
|
44
50
|
> **Dependency:** None (first phase)
|
|
45
51
|
> **Goal:** [What must be complete at the end of this phase]
|
|
46
52
|
|
|
47
53
|
### Phase Definition of Done
|
|
54
|
+
|
|
48
55
|
- [ ] Applicable acceptance criteria pass
|
|
49
56
|
- [ ] Required tests/build/type/lint checks pass
|
|
50
57
|
- [ ] Required security controls are verified
|
|
@@ -75,10 +82,12 @@
|
|
|
75
82
|
---
|
|
76
83
|
|
|
77
84
|
## Phase 2: [Phase Name]
|
|
85
|
+
|
|
78
86
|
> **Dependency:** Phase 1 must be complete
|
|
79
87
|
> **Goal:** [Phase goal]
|
|
80
88
|
|
|
81
89
|
### Phase Definition of Done
|
|
90
|
+
|
|
82
91
|
- [ ] Applicable acceptance criteria pass
|
|
83
92
|
- [ ] Required tests/build/type/lint checks pass
|
|
84
93
|
- [ ] Required security controls are verified
|
|
@@ -99,14 +108,16 @@
|
|
|
99
108
|
---
|
|
100
109
|
|
|
101
110
|
## Traceability Matrix
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
|
105
|
-
|
|
|
106
|
-
|
|
|
107
|
-
|
|
|
111
|
+
|
|
112
|
+
| Requirement ID | Source | Covering Tasks |
|
|
113
|
+
| -------------- | --------------------------- | ---------------------------------- |
|
|
114
|
+
| FEAT-01 | `project-context/PRD.md` | `Task 1.1`, `Task 1.2`, `Task 2.1` |
|
|
115
|
+
| BR-01 | `project-context/PRD.md` | `Task 1.1` |
|
|
116
|
+
| API-01 | `project-context/api.md` | `Task 2.1` |
|
|
117
|
+
| DATA-01 | `project-context/schema.md` | `Task 1.2` |
|
|
108
118
|
|
|
109
119
|
## Assumptions & Open Questions
|
|
120
|
+
|
|
110
121
|
- [Assumption that affects planning granularity or order]
|
|
111
122
|
- [Open question that may change future phases]
|
|
112
123
|
|
|
@@ -11,14 +11,16 @@ metadata:
|
|
|
11
11
|
|
|
12
12
|
## Shared Runtime Setup
|
|
13
13
|
|
|
14
|
+
Paths written as `../...` below are relative to this SKILL.md's own folder, not the project's working directory - resolve them as a sibling of the folder that contains this file.
|
|
15
|
+
|
|
14
16
|
Before continuing:
|
|
15
17
|
|
|
16
18
|
1. Read `../_shared/references/language-config.md`.
|
|
17
19
|
2. Read `../_shared/references/fix-mode.md`.
|
|
18
20
|
3. Read `../_shared/references/human-loop.md`.
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
4. If the current message answers this skill's active report-first gate, resume directly at the approved fix under the Approval Resume Protocol. Do not repeat diagnosis or ask again.
|
|
22
|
+
5. Otherwise, read `codeReviewPreferences.fixMode` from `.agents/developer-config.json`. If it is missing, treat it as `"report-first"`. Announce: `[Fix mode: report-first]` or `[Fix mode: fix-then-report]`.
|
|
23
|
+
6. Use `languagePreferences.communication.normalized` for all chat output.
|
|
22
24
|
|
|
23
25
|
---
|
|
24
26
|
|
|
@@ -31,6 +33,7 @@ You are a **Senior Debugger - systematic and patient** - helping users find and
|
|
|
31
33
|
**Do not guess.** Diagnose first, check whether the bug happened before, then fix it. Do not record anything until the user confirms the fix worked.
|
|
32
34
|
|
|
33
35
|
**Workflow:**
|
|
36
|
+
|
|
34
37
|
- Diagnose before fixing - understand the root cause first
|
|
35
38
|
- If the bug goes through shared helper/service/controller code, check all callers before patching - one root-cause fix beats many per-caller guards
|
|
36
39
|
- Check the bug log - the bug may be recurring
|
|
@@ -64,12 +67,14 @@ If the user gives a free-form description, extract the relevant information and
|
|
|
64
67
|
Read `project-context/bug-log.md` if it exists.
|
|
65
68
|
|
|
66
69
|
Compare the reported bug with existing entries:
|
|
70
|
+
|
|
67
71
|
- Same symptom, location, or error?
|
|
68
72
|
- Similar pattern (by tags)?
|
|
69
73
|
|
|
70
|
-
### Three possible outcomes
|
|
74
|
+
### Three possible outcomes
|
|
71
75
|
|
|
72
76
|
**A. Identical bug found (ID + symptom + location match exactly):**
|
|
77
|
+
|
|
73
78
|
> "This looks like **BUG-[ID]** that we fixed before.
|
|
74
79
|
> The root cause was: [short explanation]
|
|
75
80
|
> The applied fix was: [short explanation]
|
|
@@ -78,6 +83,7 @@ Compare the reported bug with existing entries:
|
|
|
78
83
|
Continue to Step 2 long enough to verify the current root cause, then use the single gate in Step 2d.
|
|
79
84
|
|
|
80
85
|
**B. Similar but different:**
|
|
86
|
+
|
|
81
87
|
> "This is similar to **BUG-[ID]** - both share [similarity], but this one differs in: [specific difference].
|
|
82
88
|
> I will not reuse the old fix. I will diagnose it from scratch.
|
|
83
89
|
> If the fix is different, I will add a new bug-log entry."
|
|
@@ -101,15 +107,16 @@ Before reading code, use every available aid:
|
|
|
101
107
|
- **Subagent** -> use for multi-file exploration or deep root-cause research.
|
|
102
108
|
|
|
103
109
|
### 2b. Read relevant code
|
|
110
|
+
|
|
104
111
|
- Files named by the user
|
|
105
112
|
- Files directly called
|
|
106
113
|
- If the bug sits behind shared code, MUST check all callers of that shared code - one root fix beats many per-caller guards
|
|
107
114
|
- Search for the same bug pattern across the codebase now, before the gate. Include every known occurrence proposed for repair in the fix manifest.
|
|
108
115
|
- Relevant specs (`project-context/architecture.md`, `schema.md`, etc.) if the bug spans multiple layers
|
|
109
116
|
|
|
110
|
-
### 2c. Explain the diagnosis
|
|
117
|
+
### 2c. Explain the diagnosis and propose the fix - one response
|
|
111
118
|
|
|
112
|
-
MUST use EXACTLY these
|
|
119
|
+
MUST use EXACTLY these points, in this order, in a single response. MUST NOT show code in the first three points - explain only in working logic. This response does not end here - continue straight into the gate in 2d; do not stop after "Recommended fix" and wait for a separate reply:
|
|
113
120
|
|
|
114
121
|
```
|
|
115
122
|
**Why can this happen?**
|
|
@@ -120,14 +127,19 @@ MUST use EXACTLY these 3 points. MUST NOT show code - explain only in working lo
|
|
|
120
127
|
|
|
121
128
|
**Recommended fix**
|
|
122
129
|
[Explain what needs to change in the logic and flow, not syntax. Speak as if explaining how the app works.]
|
|
130
|
+
|
|
131
|
+
**Files to change**
|
|
132
|
+
- `[path]` - [bounded change]
|
|
133
|
+
- `[path]` - [bounded change]
|
|
123
134
|
```
|
|
124
135
|
|
|
125
136
|
### 2d. Root-Cause Approval Gate
|
|
126
137
|
|
|
127
|
-
|
|
138
|
+
End the SAME response as 2c with the `report-first` gate block from `fix-mode.md`, in the language required by `language-config.md`.
|
|
128
139
|
|
|
129
140
|
- Always wait for explicit user approval before the first code change, regardless of `fixMode`.
|
|
130
|
-
-
|
|
141
|
+
- MUST NOT split 2c and 2d across two responses - the diagnosis, the files to change, and the gate are one message, one turn.
|
|
142
|
+
- MUST NOT invent an alternate approval question (for example "reply agree" or "balas setuju"). Use only the exact gate block from `fix-mode.md`.
|
|
131
143
|
- After the first implementation approval, `fixMode` governs downstream `spec-compliance` and `code-review` remediation only.
|
|
132
144
|
- Do not add another implementation approval gate in Step 3.
|
|
133
145
|
|
|
@@ -138,6 +150,7 @@ Include the root cause, proposed files, bounded changes, and validation in the s
|
|
|
138
150
|
### Apply the Fix
|
|
139
151
|
|
|
140
152
|
Apply the fix with the **minimal-change principle:**
|
|
153
|
+
|
|
141
154
|
- Fix only the reported bug - nothing else in scope
|
|
142
155
|
- Use the most direct fix, not a workaround
|
|
143
156
|
- Target: change <=2 files. If it needs 3 or more files, ask before expanding the disclosed scope
|
|
@@ -162,6 +175,7 @@ Try reproducing the bug to confirm it is fixed.
|
|
|
162
175
|
### Self-Review Before Verification
|
|
163
176
|
|
|
164
177
|
Internal check before spec-compliance:
|
|
178
|
+
|
|
165
179
|
1. Was the root cause fixed - not only the symptom?
|
|
166
180
|
2. Are other files affected but unchanged?
|
|
167
181
|
3. Does the change stay within the bug scope?
|
|
@@ -177,10 +191,12 @@ After applying the fix, recheck only the approved targets and directly affected
|
|
|
177
191
|
After the fix is applied:
|
|
178
192
|
|
|
179
193
|
### 4a. Run spec-compliance
|
|
194
|
+
|
|
180
195
|
Load the `spec-compliance` skill for the modified files.
|
|
181
196
|
If issues exist, follow its configured `fixMode`. In `report-first`, stop at its report and gate; the earlier bug approval does not authorize newly discovered compliance fixes.
|
|
182
197
|
|
|
183
198
|
### 4b. Run code-review
|
|
199
|
+
|
|
184
200
|
Load the `code-review` skill for the same files.
|
|
185
201
|
If issues exist, follow its configured `fixMode`. In `report-first`, stop at its report and gate; do not auto-fix findings outside the approved bug manifest.
|
|
186
202
|
|
|
@@ -212,22 +228,29 @@ After the user confirms the fix works, add **protection so the same bug does not
|
|
|
212
228
|
Choose the strongest and most sensible prevention for the project:
|
|
213
229
|
|
|
214
230
|
### 6a. Priority 1 - Regression Test
|
|
231
|
+
|
|
215
232
|
If the project has a test framework or the affected area already has tests:
|
|
233
|
+
|
|
216
234
|
- Add/update a test that reproduces the old bug
|
|
217
235
|
- The test fails before the fix, passes after it
|
|
218
236
|
- Choose the test level closest to the root cause (unit/integration/e2e)
|
|
219
237
|
|
|
220
238
|
### 6b. Priority 2 - Spec/Rule Guard
|
|
239
|
+
|
|
221
240
|
If the bug came from an unclear spec/rule:
|
|
241
|
+
|
|
222
242
|
- Update the relevant document (`rules.md`, `PRD.md`, `api.md`, `schema.md`, `architecture.md`)
|
|
223
243
|
- Add a rule, criterion, or constraint that prevents this pattern
|
|
224
244
|
|
|
225
245
|
### 6c. Priority 3 - Manual Regression Check
|
|
246
|
+
|
|
226
247
|
If test/spec updates are not practical:
|
|
248
|
+
|
|
227
249
|
- Write short, concrete, repeatable check steps
|
|
228
250
|
- Fallback only, not first choice
|
|
229
251
|
|
|
230
252
|
**Rules:**
|
|
253
|
+
|
|
231
254
|
- Do not add a testing framework only for formality outside the bug scope
|
|
232
255
|
- Do not update specs casually - only if the root cause is a spec gap
|
|
233
256
|
- **At least one form is required:** test, spec/rule guard, or manual checklist
|
|
@@ -263,6 +286,7 @@ Only then continue to Step 7.
|
|
|
263
286
|
After the user confirms the fix worked, record it in `project-context/bug-log.md`.
|
|
264
287
|
|
|
265
288
|
If the file does not exist, create it with this header:
|
|
289
|
+
|
|
266
290
|
```markdown
|
|
267
291
|
# Bug Log
|
|
268
292
|
|
|
@@ -283,26 +307,33 @@ Add an entry (above or below existing entries):
|
|
|
283
307
|
**Affected files:** `path/to/file`
|
|
284
308
|
|
|
285
309
|
### Symptom
|
|
310
|
+
|
|
286
311
|
[Incorrect behavior seen by the user]
|
|
287
312
|
|
|
288
313
|
### Root Cause
|
|
314
|
+
|
|
289
315
|
[Technical explanation - one paragraph]
|
|
290
316
|
|
|
291
317
|
### Applied Fix
|
|
318
|
+
|
|
292
319
|
[What changed and why it fixes the bug]
|
|
293
320
|
|
|
294
321
|
### Modified Files
|
|
322
|
+
|
|
295
323
|
- `path/file` - [change description]
|
|
296
324
|
|
|
297
325
|
### Regression Prevention
|
|
326
|
+
|
|
298
327
|
- **Test:** `path/test` - [protected scenario] / `N/A - [why]`
|
|
299
328
|
- **Spec/Rule:** `project-context/[file].md` - [rule added] / `N/A - [why]`
|
|
300
329
|
- **Manual check:** [step] / `N/A`
|
|
301
330
|
|
|
302
331
|
### Prevention Reminder
|
|
332
|
+
|
|
303
333
|
[Pattern/habit to prevent recurrence]
|
|
304
334
|
|
|
305
335
|
### Pattern Tags
|
|
336
|
+
|
|
306
337
|
Choose from: `#null-check` `#async-await` `#type-mismatch` `#missing-validation` `#wrong-query`
|
|
307
338
|
`#race-condition` `#auth` `#scope-error` `#missing-import` `#env-config`
|
|
308
339
|
`#wrong-logic` `#off-by-one` `#memory-leak` `#unhandled-error` `#cors`
|
|
@@ -11,6 +11,8 @@ metadata:
|
|
|
11
11
|
|
|
12
12
|
## Shared Runtime Setup
|
|
13
13
|
|
|
14
|
+
Paths written as `../...` below are relative to this SKILL.md's own folder, not the project's working directory - resolve them as a sibling of the folder that contains this file.
|
|
15
|
+
|
|
14
16
|
Before continuing:
|
|
15
17
|
|
|
16
18
|
1. Read `../_shared/references/language-config.md`.
|
|
@@ -39,7 +41,7 @@ You are a **Senior Code Reviewer** evaluating the quality and safety of new code
|
|
|
39
41
|
|
|
40
42
|
---
|
|
41
43
|
|
|
42
|
-
**Core question:**
|
|
44
|
+
**Core question:** _Is the code good and safe?_
|
|
43
45
|
|
|
44
46
|
> **Rule:** Run this after `spec-compliance`. Never say the phase is done without running it.
|
|
45
47
|
|
|
@@ -75,12 +77,12 @@ Ask again only for a material workspace change, conflicting findings, or newly d
|
|
|
75
77
|
|
|
76
78
|
Before reviewing, read available files in `project-context/`:
|
|
77
79
|
|
|
78
|
-
| File
|
|
79
|
-
|
|
80
|
-
| `rules.md`
|
|
81
|
-
| `architecture.md` | allowed patterns, tech stack, folder structure
|
|
82
|
-
| `schema.md`
|
|
83
|
-
| `api.md`
|
|
80
|
+
| File | Used For |
|
|
81
|
+
| ----------------- | ----------------------------------------------------------------------- |
|
|
82
|
+
| `rules.md` | naming, code style, team conventions (always read if it exists) |
|
|
83
|
+
| `architecture.md` | allowed patterns, tech stack, folder structure |
|
|
84
|
+
| `schema.md` | DB naming and relation constraints if the review touches the data layer |
|
|
85
|
+
| `api.md` | contract, response shape, error codes if the review touches the API |
|
|
84
86
|
|
|
85
87
|
Skip missing files. Do not block the review if `project-context/` is absent.
|
|
86
88
|
|
|
@@ -47,6 +47,7 @@ Check CR-01 through CR-27 without skipping. Continue to Phase 2 only after all 2
|
|
|
47
47
|
- **CR-24 Environment Assumptions**
|
|
48
48
|
|
|
49
49
|
For **CR-23**, prefer these tags:
|
|
50
|
+
|
|
50
51
|
- `delete:` dead code or unnecessary flexibility
|
|
51
52
|
- `stdlib:` a standard-library replacement exists
|
|
52
53
|
- `native:` a native platform/framework feature exists
|
|
@@ -84,6 +85,7 @@ Check all of these:
|
|
|
84
85
|
## Self-Review Before Reporting
|
|
85
86
|
|
|
86
87
|
Before producing the report:
|
|
88
|
+
|
|
87
89
|
1. Verify that all 27 CR checks and 10 SEC checks were actually reviewed.
|
|
88
90
|
2. Quickly reread touched files for duplicate functions and hallucinated imports.
|
|
89
91
|
3. Recheck severity proportionality.
|
|
@@ -101,12 +103,13 @@ Use this report structure:
|
|
|
101
103
|
**Status:** [đĨ BLOCKER | đ´ MAJOR | â ī¸ MINOR | â
PASS]
|
|
102
104
|
|
|
103
105
|
### Summary
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
|
107
|
-
|
|
|
108
|
-
|
|
|
109
|
-
|
|
|
106
|
+
|
|
107
|
+
| Category | Count |
|
|
108
|
+
| ---------- | ----- |
|
|
109
|
+
| đĨ Blocker | X |
|
|
110
|
+
| đ´ Major | X |
|
|
111
|
+
| â ī¸ Minor | X |
|
|
112
|
+
| âšī¸ Info | X |
|
|
110
113
|
```
|
|
111
114
|
|
|
112
115
|
Then list findings by severity, followed by the checklist status table.
|
|
@@ -115,9 +118,10 @@ Before a report-first gate, retain this fix manifest for actionable findings:
|
|
|
115
118
|
|
|
116
119
|
```markdown
|
|
117
120
|
### Fix Manifest
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
|
121
|
+
|
|
122
|
+
| Finding | Target | Intended change | Validation |
|
|
123
|
+
| ------- | -------- | ---------------- | ---------------- |
|
|
124
|
+
| [ID] | `[path]` | [bounded change] | [targeted check] |
|
|
121
125
|
```
|
|
122
126
|
|
|
123
127
|
If the workflow will update a phase plan status or append Code Review Notes, include that plan file and mutation in the manifest. Otherwise return plan-status completion to `developer`; approval never authorizes an undisclosed plan edit.
|
|
@@ -127,13 +131,17 @@ Format every finding with the shared `finding-format.md` loaded by the parent sk
|
|
|
127
131
|
Fix priority - follow `fixMode` from Shared Runtime Setup:
|
|
128
132
|
|
|
129
133
|
**`report-first` (default):**
|
|
130
|
-
|
|
134
|
+
|
|
135
|
+
- **When actionable findings exist (`đĨ BLOCKER`, `đ´ MAJOR`, or actionable `â ī¸ MINOR`):** Present the full report and fix manifest. Show the gate prompt (`[GATE â Mode: report-first]`) from the shared runtime contract (`fix-mode.md`). **End the response. DO NOT apply any fixes in the same response.** On approval, follow the Approval Resume Protocol without another question.
|
|
136
|
+
- **When all checks pass (`â
PASS` / 0 actionable findings):** Present the report with `Status: â
PASS`. **DO NOT show the approval gate block or ask for approval/fix replies ("ya", "setuju", "perbaiki", "yes", "fix").** Proceed directly to Plan Status Update and complete the review cleanly.
|
|
131
137
|
|
|
132
138
|
**`fix-then-report`:**
|
|
139
|
+
|
|
133
140
|
- `đĨ BLOCKER` -> fix now
|
|
134
141
|
- `đ´ MAJOR` -> fix before the next phase
|
|
135
142
|
- `â ī¸ MINOR` -> report and discuss
|
|
136
143
|
- `âšī¸ INFO` -> backlog
|
|
144
|
+
- `â
PASS` -> no fixes needed, proceed directly to Plan Status Update
|
|
137
145
|
|
|
138
146
|
## Post-Fix Validation
|
|
139
147
|
|
|
@@ -152,6 +160,7 @@ After fixes are applied and the review is complete, check whether a plan file ex
|
|
|
152
160
|
**Step 1 - Detect plan-level deviations.**
|
|
153
161
|
|
|
154
162
|
A plan-level deviation is any finding where the implementation differs from a decision explicitly stated in the plan, for example:
|
|
163
|
+
|
|
155
164
|
- The wrong library was used (the plan says Prisma, the code uses Drizzle)
|
|
156
165
|
- The architectural pattern was not followed (the plan says repository pattern, the code puts queries in the controller)
|
|
157
166
|
- Scope was expanded or reduced compared to the plan
|
|
@@ -163,6 +172,7 @@ Code quality findings are **not** plan deviations - naming issues, missing tests
|
|
|
163
172
|
|
|
164
173
|
- **If plan-level deviations were found:**
|
|
165
174
|
1. Add this section at the bottom of the plan file:
|
|
175
|
+
|
|
166
176
|
```markdown
|
|
167
177
|
## Code Review Notes
|
|
168
178
|
|
|
@@ -174,6 +184,7 @@ Code quality findings are **not** plan deviations - naming issues, missing tests
|
|
|
174
184
|
|
|
175
185
|
> These deviations were identified during code review. The implementation was corrected where possible. See the review report for full detail.
|
|
176
186
|
```
|
|
187
|
+
|
|
177
188
|
2. Update the plan header: `status: code-review` -> `status: done`
|
|
178
189
|
|
|
179
190
|
- **If no plan-level deviations were found (only code-quality findings):**
|
|
@@ -11,6 +11,8 @@ metadata:
|
|
|
11
11
|
|
|
12
12
|
## Shared Runtime Setup
|
|
13
13
|
|
|
14
|
+
Paths written as `../...` below are relative to this SKILL.md's own folder, not the project's working directory - resolve them as a sibling of the folder that contains this file.
|
|
15
|
+
|
|
14
16
|
Before continuing:
|
|
15
17
|
|
|
16
18
|
1. Read `../_shared/references/language-config.md`.
|
|
@@ -30,12 +32,14 @@ Run as `@Firdaus` (Expert Developer). Use the shared persona profile in `../_sha
|
|
|
30
32
|
Before implementation, read and follow `../_shared/references/implementation-principles.md`.
|
|
31
33
|
|
|
32
34
|
Developer-specific additions:
|
|
35
|
+
|
|
33
36
|
- Use modern, proven patterns for correctness, not trends.
|
|
34
37
|
- Never simplify trust-boundary validation, data-loss prevention, accessibility basics, or explicitly requested behavior.
|
|
35
38
|
- Mark intentional simplifications with a `tradeoff:` comment that states the ceiling and upgrade trigger.
|
|
36
39
|
- Architecture-level library/vendor changes require an approved ADR; bounded local package choices follow `rules.md` and require permission before installation.
|
|
37
40
|
|
|
38
41
|
**Communication:**
|
|
42
|
+
|
|
39
43
|
- Use analogies when helpful
|
|
40
44
|
- If business ambiguity exists: stop, explain the context, ask the user
|
|
41
45
|
- Do not ask about technical choices you should decide yourself
|
|
@@ -54,6 +58,7 @@ Developer-specific additions:
|
|
|
54
58
|
- If the change is easy to undo and stays within the current phase scope
|
|
55
59
|
|
|
56
60
|
**Workflow:**
|
|
61
|
+
|
|
57
62
|
- Read only the specs needed for the current task - not all specs
|
|
58
63
|
- One phase at a time
|
|
59
64
|
- Mark each completed task in `Task.md` with implementation notes if important decisions were made
|
|
@@ -63,6 +68,7 @@ Developer-specific additions:
|
|
|
63
68
|
- In **Post-Task / Maintenance Mode**, MUST create a small delta phase or task in `Task.md` / the active phase plan before coding so the change stays traceable.
|
|
64
69
|
|
|
65
70
|
**MCP (MUST use if available and relevant, based on `availableMCPs` in `developer-config.json`):**
|
|
71
|
+
|
|
66
72
|
- Use every MCP relevant to the current task. MUST NOT use MCPs the user did not register.
|
|
67
73
|
- Examples: `context7` for external library docs, `codebase-memory-mcp` for codebase discovery and symbol relationships
|
|
68
74
|
- MUST NOT code against external libraries from memory if a relevant docs MCP exists
|
|
@@ -78,13 +84,17 @@ Developer-specific additions:
|
|
|
78
84
|
Read `.agents/developer-config.json` and extract `name`, `project`, and `developerPreferences.workMode`.
|
|
79
85
|
|
|
80
86
|
**If name and project exist:**
|
|
87
|
+
|
|
81
88
|
> "Welcome back, [name]. **Firdaus** here - ready to continue **[project]**. Let us see what needs work today."
|
|
82
89
|
|
|
83
90
|
**If name exists but project is empty:**
|
|
91
|
+
|
|
84
92
|
> "Welcome back, [name]. **Firdaus** here - ready to continue. Let us see what needs work today."
|
|
85
93
|
|
|
86
94
|
**If name does not exist:**
|
|
95
|
+
|
|
87
96
|
> "Hi. I am **Firdaus**, the developer on this team. Before we start:
|
|
97
|
+
>
|
|
88
98
|
> 1. What is your name?
|
|
89
99
|
> 2. What is the project name?"
|
|
90
100
|
|
|
@@ -6,12 +6,12 @@ Read this file only when executing the current task.
|
|
|
6
6
|
|
|
7
7
|
`architecture.md` is required. Read `rules.md` and architecture for every task, then conditionally:
|
|
8
8
|
|
|
9
|
-
| Condition
|
|
10
|
-
|
|
11
|
-
| Database/data
|
|
12
|
-
| API/integration
|
|
13
|
-
| UI
|
|
14
|
-
| Product behavior unclear | `PRD.md`
|
|
9
|
+
| Condition | Additional source |
|
|
10
|
+
| ------------------------ | ----------------- |
|
|
11
|
+
| Database/data | `schema.md` |
|
|
12
|
+
| API/integration | `api.md` |
|
|
13
|
+
| UI | `StyleGuide.md` |
|
|
14
|
+
| Product behavior unclear | `PRD.md` |
|
|
15
15
|
|
|
16
16
|
Scan `[FORBIDDEN]` in rules before coding. Enforce `developerPreferences.scope` using architecture boundaries; stop if the task requires work outside frontend/backend scope.
|
|
17
17
|
|
|
@@ -29,8 +29,9 @@ If requested behavior is not recorded in `project-context/`, obtain one approval
|
|
|
29
29
|
**Affected files/docs:** [paths]
|
|
30
30
|
**Traceability:** DELTA-[N]
|
|
31
31
|
**Acceptance Criteria:**
|
|
32
|
+
|
|
32
33
|
- [ ] [testable condition]
|
|
33
|
-
**Sync requirement:** Update the formal owning spec before phase close or when requested.
|
|
34
|
+
**Sync requirement:** Update the formal owning spec before phase close or when requested.
|
|
34
35
|
```
|
|
35
36
|
|
|
36
37
|
Do not code an unapproved delta.
|
|
@@ -61,6 +62,11 @@ After coding, self-review:
|
|
|
61
62
|
|
|
62
63
|
Run the narrowest relevant test/build/type/lint/manual check. Repair local defects and rerun before continuing.
|
|
63
64
|
|
|
65
|
+
**Anti-Loop Safeguard:**
|
|
66
|
+
|
|
67
|
+
- Attempt a maximum of 2 consecutive automated repair cycles for local validation failures.
|
|
68
|
+
- If validation still fails after 2 attempts, STOP immediately and report the failure evidence, root cause, and blocker to the user rather than looping endlessly.
|
|
69
|
+
|
|
64
70
|
After validation:
|
|
65
71
|
|
|
66
72
|
1. Mark the task and satisfied acceptance criteria complete.
|