gm-cc 2.0.673 → 2.0.675
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/.claude-plugin/marketplace.json +1 -1
- package/package.json +1 -1
- package/plugin.json +1 -1
- package/skills/gm-emit/SKILL.md +2 -0
- package/skills/gm-execute/SKILL.md +44 -52
- package/skills/planning/SKILL.md +39 -82
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"name": "AnEntrypoint"
|
|
5
5
|
},
|
|
6
6
|
"description": "State machine agent with hooks, skills, and automated git enforcement",
|
|
7
|
-
"version": "2.0.
|
|
7
|
+
"version": "2.0.675",
|
|
8
8
|
"metadata": {
|
|
9
9
|
"description": "State machine agent with hooks, skills, and automated git enforcement"
|
|
10
10
|
},
|
package/package.json
CHANGED
package/plugin.json
CHANGED
package/skills/gm-emit/SKILL.md
CHANGED
|
@@ -22,6 +22,7 @@ For every claim landing in a file:
|
|
|
22
22
|
2. **Repair legality** — local patch dressed as structural repair? Downgrade scope or snake to PLAN.
|
|
23
23
|
3. **Lawful downgrade** — can a weaker, true statement replace it? PREFER the downgrade.
|
|
24
24
|
4. **Alternative-route suppression** — live competing route being silenced? Preserve it.
|
|
25
|
+
5. **Strongest objection** — if a reviewer pushed back on this change, what would the sharpest argument be? Articulate it. Cannot articulate = have not understood the alternatives = regress to `gm-execute`.
|
|
25
26
|
|
|
26
27
|
Fail any → regress to `gm-execute` to witness what was missing, or `planning` if gap is structural.
|
|
27
28
|
|
|
@@ -56,6 +57,7 @@ console.log(await fn(realInput));
|
|
|
56
57
|
- Post-emit matches pre-emit exactly
|
|
57
58
|
- Hot reloadable; errors throw with context (no fallbacks, `|| default`, `catch { return null }`)
|
|
58
59
|
- No mocks/fakes/stubs/scattered test files (delete on discovery)
|
|
60
|
+
- Behavior change in this emit = a corresponding assertion in test.js (a change no test would catch is a change you cannot prove)
|
|
59
61
|
- Files ≤200 lines
|
|
60
62
|
- No duplicate concern (run exec:codesearch for primary concern after writing; any overlap → `planning`)
|
|
61
63
|
- No comments; no hardcoded values; no adjectives in identifiers; no unnecessary files
|
|
@@ -5,61 +5,66 @@ description: EXECUTE phase AND the foundational execution contract for every ski
|
|
|
5
5
|
|
|
6
6
|
# GM EXECUTE — Resolve Every Unknown
|
|
7
7
|
|
|
8
|
-
GRAPH: `PLAN → [EXECUTE] → EMIT → VERIFY → COMPLETE
|
|
9
|
-
Entry: .prd with named unknowns. From `planning` or re-entered from EMIT/VERIFY.
|
|
8
|
+
GRAPH: `PLAN → [EXECUTE] → EMIT → VERIFY → COMPLETE`. Entry: .prd with named unknowns.
|
|
10
9
|
|
|
11
|
-
This skill = execution contract for ALL phases.
|
|
10
|
+
This skill = execution contract for ALL phases. About to run anything → load this first.
|
|
12
11
|
|
|
13
12
|
## TRANSITIONS
|
|
14
13
|
|
|
15
|
-
**EXIT → EMIT**: all mutables KNOWN → invoke `gm-emit
|
|
16
|
-
**SELF-LOOP**: still UNKNOWN → re-run different angle (max 2 passes
|
|
17
|
-
**REGRESS → PLAN**: new unknown
|
|
14
|
+
- **EXIT → EMIT**: all mutables KNOWN → invoke `gm-emit`.
|
|
15
|
+
- **SELF-LOOP**: still UNKNOWN → re-run different angle (max 2 passes).
|
|
16
|
+
- **REGRESS → PLAN**: new unknown | unresolvable after 2 passes.
|
|
18
17
|
|
|
19
18
|
## MUTABLE DISCIPLINE
|
|
20
19
|
|
|
21
|
-
Each mutable: name | expected | current | resolution method.
|
|
20
|
+
Each mutable: name | expected | current | resolution method.
|
|
22
21
|
|
|
23
|
-
|
|
22
|
+
Resolves to KNOWN only when ALL four pass:
|
|
24
23
|
- **ΔS=0** — witnessed output equals expected
|
|
25
24
|
- **λ≥2** — two independent paths agree
|
|
26
|
-
- **ε intact** — adjacent invariants hold
|
|
27
|
-
- **Coverage≥0.70** — enough corpus inspected
|
|
25
|
+
- **ε intact** — adjacent invariants hold
|
|
26
|
+
- **Coverage≥0.70** — enough corpus inspected
|
|
27
|
+
|
|
28
|
+
Unresolved after 2 passes = regress to `planning`. Never narrate past an unresolved mutable.
|
|
28
29
|
|
|
29
30
|
## PRIORS DON'T AUTHORIZE
|
|
30
31
|
|
|
31
|
-
Route candidates from PLAN
|
|
32
|
-
|
|
33
|
-
"The plan says" / "we agreed" / "obviously X" = prior-statements, not witnessed facts.
|
|
32
|
+
Route candidates from PLAN = `weak_prior` only. Plausibility = right to TEST, not BELIEVE.
|
|
33
|
+
weak_prior → witnessed probe → witnessed → feed to EMIT. "The plan says" / "obviously X" = prior, not fact.
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
Claims in response prose stand or fall by their last witness. A claim with no witness in this session is a hypothesis, not a finding — say so when you state it, and say what would settle it. The next reader (you, next turn) needs to know which lines were earned and which were carried forward.
|
|
36
|
+
|
|
37
|
+
## VERIFICATION BUDGET
|
|
36
38
|
|
|
37
|
-
`
|
|
39
|
+
Spend on `.prd` items in descending order of consequence-if-wrong × distance-from-witnessed. Items whose failure would collapse the headline finding must reach witnessed status before EMIT; items with sub-argument-level consequence need at minimum a stated fallback path.
|
|
38
40
|
|
|
39
|
-
|
|
41
|
+
## CODE EXECUTION
|
|
42
|
+
|
|
43
|
+
`exec:<lang>` only via Bash: `exec:<lang>\n<code>`
|
|
40
44
|
|
|
41
|
-
|
|
45
|
+
Langs: `nodejs` (default) | `bash` | `python` | `typescript` | `go` | `rust` | `c` | `cpp` | `java` | `deno` | `cmd`
|
|
42
46
|
|
|
43
|
-
|
|
47
|
+
File I/O: exec:nodejs + require('fs'). Git directly in Bash. **Never** Bash(node/npm/npx/bun).
|
|
44
48
|
|
|
49
|
+
Pack runs: Promise.allSettled parallel, each idea own try/catch, under 12s per call.
|
|
45
50
|
Runner: `exec:runner\nstart|stop|status`
|
|
46
51
|
|
|
47
52
|
## CODEBASE SEARCH
|
|
48
53
|
|
|
49
|
-
`exec:codesearch` only. Grep/Glob/Find/Explore/
|
|
54
|
+
`exec:codesearch` only. Grep/Glob/Find/Explore/grep/rg/find = hook-blocked.
|
|
50
55
|
|
|
51
|
-
Known absolute path → `Read`. Known dir → exec:nodejs + fs.readdirSync.
|
|
56
|
+
Known absolute path → `Read`. Known dir → exec:nodejs + fs.readdirSync.
|
|
52
57
|
|
|
53
58
|
```
|
|
54
59
|
exec:codesearch
|
|
55
60
|
<two-word query>
|
|
56
61
|
```
|
|
57
62
|
|
|
58
|
-
Iterate: change
|
|
63
|
+
Iterate: change/add one word per pass. Min 4 attempts before concluding absent.
|
|
59
64
|
|
|
60
65
|
## IMPORT-BASED EXECUTION
|
|
61
66
|
|
|
62
|
-
Always import actual modules.
|
|
67
|
+
Always import actual modules. Reimplemented = UNKNOWN.
|
|
63
68
|
|
|
64
69
|
```
|
|
65
70
|
exec:nodejs
|
|
@@ -67,67 +72,54 @@ const { fn } = await import('/abs/path/to/module.js');
|
|
|
67
72
|
console.log(await fn(realInput));
|
|
68
73
|
```
|
|
69
74
|
|
|
70
|
-
Differential diagnosis:
|
|
75
|
+
Differential diagnosis: smallest reproduction → compare actual vs expected → name the delta = mutable.
|
|
71
76
|
|
|
72
77
|
## CI — AUTOMATED
|
|
73
78
|
|
|
74
|
-
git push → Stop hook auto-watches
|
|
75
|
-
-
|
|
76
|
-
- Failure →
|
|
79
|
+
`git push` → Stop hook auto-watches Actions for pushed HEAD. Same-repo only — downstream cascades not auto-watched.
|
|
80
|
+
- Green → Stop approves with summary
|
|
81
|
+
- Failure → run names+IDs → `gh run view <id> --log-failed`
|
|
77
82
|
- Deadline 180s (override `GM_CI_WATCH_SECS`)
|
|
78
|
-
- Downstream-repo cascades NOT auto-watched — same-repo only
|
|
79
83
|
|
|
80
84
|
## GROUND TRUTH
|
|
81
85
|
|
|
82
|
-
Real services, real data, real timing. Mocks/stubs/
|
|
83
|
-
|
|
84
|
-
**Scan before edit**: exec:codesearch for existing implementation before creating/modifying. Duplicate concern = regress to `planning`.
|
|
86
|
+
Real services, real data, real timing. Mocks/stubs/scattered tests/fallbacks = delete.
|
|
85
87
|
|
|
88
|
+
**Scan before edit**: exec:codesearch before creating/modifying. Duplicate concern = regress to `planning`.
|
|
86
89
|
**Hypothesize via execution**: hypothesis → run → witness → edit. Never edit on unwitnessed assumption.
|
|
87
|
-
|
|
88
|
-
**Code quality** (stop at first that resolves need): native → library → structure (map/pipeline) → write.
|
|
90
|
+
**Code quality**: native → library → structure (map/pipeline) → write.
|
|
89
91
|
|
|
90
92
|
## PARALLEL SUBAGENTS
|
|
91
93
|
|
|
92
|
-
≤3 `gm:gm` subagents for independent items
|
|
93
|
-
|
|
94
|
-
Browser escalation: exec:browser → browser skill → navigate/click → screenshot (last resort).
|
|
94
|
+
≤3 `gm:gm` subagents for independent items in ONE message. Browser escalation: exec:browser → browser skill → screenshot last resort.
|
|
95
95
|
|
|
96
96
|
## RECALL — HARD RULE
|
|
97
97
|
|
|
98
|
-
Before resolving any new unknown via fresh execution,
|
|
99
|
-
|
|
100
|
-
Triggers (any = run recall NOW, before exec/codesearch):
|
|
101
|
-
- About to investigate a "did we hit this before" question
|
|
102
|
-
- About to ask the user something likely already discussed
|
|
103
|
-
- About to design an approach where a prior decision exists
|
|
104
|
-
- Encountered an error/quirk that "feels familiar"
|
|
105
|
-
- Starting a new sub-task on a project worked on before
|
|
106
|
-
- About to write a comment explaining a non-obvious choice
|
|
98
|
+
Before resolving any new unknown via fresh execution, recall first.
|
|
107
99
|
|
|
108
100
|
```
|
|
109
101
|
exec:recall
|
|
110
102
|
<2-6 word query>
|
|
111
103
|
```
|
|
112
104
|
|
|
113
|
-
|
|
105
|
+
Triggers: "did we hit this" | feels familiar | new sub-task in known project | about to comment a non-obvious choice | about to ask user something likely discussed.
|
|
114
106
|
|
|
115
|
-
|
|
107
|
+
Hits = weak_prior; still witness. Empty = proceed. Capped 6s, ~5ms when serve running. ~200 tokens / 5 hits.
|
|
116
108
|
|
|
117
109
|
## MEMORIZE — HARD RULE
|
|
118
110
|
|
|
119
|
-
Unknown→known =
|
|
120
|
-
|
|
121
|
-
Triggers: exec: output answers prior unknown | CI log reveals root cause | code read confirms/refutes | env quirk observed | user states preference/constraint.
|
|
111
|
+
Unknown→known = same-turn memorize.
|
|
122
112
|
|
|
123
113
|
```
|
|
124
114
|
Agent(subagent_type='gm:memorize', model='haiku', run_in_background=true, prompt='## CONTEXT TO MEMORIZE\n<fact>')
|
|
125
115
|
```
|
|
126
116
|
|
|
117
|
+
Triggers: exec output answers prior unknown | CI log reveals root cause | code read confirms/refutes | env quirk | user states preference/constraint.
|
|
118
|
+
|
|
127
119
|
N facts → N parallel Agent calls in ONE message. End-of-turn self-check mandatory.
|
|
128
120
|
|
|
129
|
-
|
|
121
|
+
## CONSTRAINTS
|
|
130
122
|
|
|
131
|
-
**Never**: Bash(node/npm/npx/bun) | fake data | mocks | scattered tests | fallbacks | Grep/Glob/Find/Explore | sequential independent items | respond
|
|
123
|
+
**Never**: Bash(node/npm/npx/bun) | fake data | mocks | scattered tests | fallbacks | Grep/Glob/Find/Explore | sequential independent items | respond mid-phase | edit before witnessing | duplicate code | if/else where dispatch suffices | one-liners that obscure | reinvent native/library
|
|
132
124
|
|
|
133
|
-
**Always**: witness every hypothesis | import real modules | scan before edit | regress on new unknown | delete mocks/comments/scattered tests on discovery | test.js for
|
|
125
|
+
**Always**: witness every hypothesis | import real modules | scan before edit | regress on new unknown | delete mocks/comments/scattered tests on discovery | update test.js for behavior changes | invoke next skill immediately when done | weight verification by load
|
package/skills/planning/SKILL.md
CHANGED
|
@@ -6,112 +6,77 @@ allowed-tools: Write
|
|
|
6
6
|
|
|
7
7
|
# Planning — State Machine Orchestrator
|
|
8
8
|
|
|
9
|
-
Runs `PLAN → EXECUTE → EMIT → VERIFY → UPDATE-DOCS → COMPLETE`.
|
|
10
|
-
|
|
11
|
-
Entry: prompt-submit hook → `gm` → here. Re-enter on any new unknown in any phase.
|
|
12
|
-
|
|
13
|
-
## UNKNOWNS = PRODUCT
|
|
14
|
-
|
|
15
|
-
Output = every fault surface work could fail on. Unknown named+resolved = cheaper downstream. Unknown skipped = EMIT/VERIFY surprise = snake back at higher cost.
|
|
16
|
-
|
|
17
|
-
Later-phase unknown → return here. Not failure — machine working. Patch-around-in-place = compounding debt.
|
|
9
|
+
Runs `PLAN → EXECUTE → EMIT → VERIFY → UPDATE-DOCS → COMPLETE`. Re-enter on any new unknown in any phase.
|
|
18
10
|
|
|
19
11
|
## RECALL — HARD RULE
|
|
20
12
|
|
|
21
|
-
Before naming any unknown,
|
|
22
|
-
|
|
23
|
-
Triggers (any = run `plugkit recall` BEFORE adding the .prd item):
|
|
24
|
-
- Unknown matches a previously-discussed topic in this project
|
|
25
|
-
- About to investigate a "have we seen this" question
|
|
26
|
-
- About to design an approach where a prior decision likely exists
|
|
27
|
-
- Quirk/error feels familiar
|
|
28
|
-
- Sub-task in a project worked on before
|
|
13
|
+
Before naming any unknown, run recall.
|
|
29
14
|
|
|
30
15
|
```
|
|
31
16
|
exec:recall
|
|
32
17
|
<2-6 word query>
|
|
33
18
|
```
|
|
34
19
|
|
|
35
|
-
|
|
20
|
+
Triggers: matches prior topic | "have we seen this" | designing where prior decision likely exists | quirk feels familiar | sub-task in known project.
|
|
36
21
|
|
|
37
|
-
Skip recall only
|
|
22
|
+
Hits = weak_prior; witness via EXECUTE before adopting. Skip recall only on brand-new project / trivially-bounded edit / surgical user instruction.
|
|
38
23
|
|
|
39
24
|
## MEMORIZE — HARD RULE
|
|
40
25
|
|
|
41
|
-
Every unknown
|
|
42
|
-
|
|
43
|
-
Triggers: exec: output answers prior unknown | code read confirms/refutes | CI log reveals root cause | user states preference/constraint | fix worked non-obviously | env quirk observed.
|
|
26
|
+
Every unknown→known = same-turn memorize. Background, parallel, never batched.
|
|
44
27
|
|
|
45
28
|
```
|
|
46
29
|
Agent(subagent_type='gm:memorize', model='haiku', run_in_background=true, prompt='## CONTEXT TO MEMORIZE\n<fact>')
|
|
47
30
|
```
|
|
48
31
|
|
|
49
|
-
|
|
32
|
+
Triggers: exec output answers prior unknown | code read confirms/refutes | CI log reveals root cause | user states preference/constraint | fix worked non-obviously | env quirk observed.
|
|
50
33
|
|
|
51
|
-
|
|
34
|
+
N facts → N parallel Agent calls in ONE message.
|
|
52
35
|
|
|
53
36
|
## STATE MACHINE
|
|
54
37
|
|
|
55
38
|
**FORWARD**: PLAN → `gm-execute` | EXECUTE → `gm-emit` | EMIT → `gm-complete` | VERIFY .prd remains → `gm-execute` | VERIFY .prd empty+pushed → `update-docs`
|
|
56
39
|
|
|
57
|
-
**REGRESSIONS**: new unknown
|
|
40
|
+
**REGRESSIONS**: new unknown anywhere → `planning` | EXECUTE unresolvable 2 passes → `planning` | EMIT logic error → `gm-execute` | VERIFY broken output → `gm-emit` | VERIFY logic wrong → `gm-execute`
|
|
58
41
|
|
|
59
42
|
Runs until: .gm/prd.yml empty AND git clean AND all pushes confirmed AND CI green.
|
|
60
43
|
|
|
61
44
|
## AUTONOMY — HARD RULE
|
|
62
45
|
|
|
63
|
-
|
|
46
|
+
PRD written → execute to COMPLETE without asking the user. No "should I continue", no "want me to do X next", no offering to split work.
|
|
64
47
|
|
|
65
|
-
Asking
|
|
48
|
+
Asking permitted only as last resort: destructive-irreversible with no PRD coverage, OR user intent unrecoverable from PRD/memory/code. Channel: `exec:pause` (renames prd.yml → prd.paused.yml; question in header). In-conversation asking last-resort.
|
|
66
49
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
**Cannot stop while**: .gm/prd.yml has items | git has uncommitted changes | git has unpushed commits.
|
|
50
|
+
**Cannot stop while**: .gm/prd.yml has items | git uncommitted | git unpushed.
|
|
70
51
|
|
|
71
52
|
## SKIP PLANNING (DEFAULT for small work)
|
|
72
53
|
|
|
73
|
-
Skip if ANY
|
|
74
|
-
- Single-file, single-concern edit
|
|
75
|
-
- Task trivially bounded, under ~5 min
|
|
76
|
-
- User gave explicit surgical instructions
|
|
77
|
-
- Bug fix with identified root cause
|
|
78
|
-
- Zero unknowns
|
|
79
|
-
|
|
80
|
-
Heavy ceremony (PRD + parallel subagents) for multi-file architectural work or genuinely unknown fault surfaces. If new unknown surfaces mid-work, THAT is when to regress — not preemptively.
|
|
54
|
+
Skip if ANY: single-file single-concern edit | trivially bounded <5min | surgical user instructions | bug fix with identified root cause | zero unknowns. Heavy ceremony only for multi-file architectural work.
|
|
81
55
|
|
|
82
56
|
## PLAN PHASE — MUTABLE DISCOVERY
|
|
83
57
|
|
|
84
|
-
For every aspect
|
|
85
|
-
- What do I not know? → mutable (UNKNOWN)
|
|
86
|
-
- What could go wrong? → edge case item with failure mode
|
|
87
|
-
- What depends on what? → blocking/blockedBy mapped
|
|
88
|
-
- What assumptions am I making? → each = unwitnessed hypothesis = mutable
|
|
58
|
+
For every aspect: what do I not know (UNKNOWN) | what could go wrong (failure mode) | what depends on what (blocking/blockedBy) | what assumptions am I making (unwitnessed hypothesis = mutable).
|
|
89
59
|
|
|
90
|
-
Fault surfaces: file existence | API shape | data format |
|
|
60
|
+
Fault surfaces: file existence | API shape | data format | dep versions | runtime behavior | env differences | error conditions | concurrency | integration seams | backwards compat | rollback paths | CI correctness.
|
|
91
61
|
|
|
92
|
-
**Route family** (
|
|
62
|
+
**Route family** (governance): tag every item — grounding|reasoning|state|execution|observability|boundary|representation.
|
|
93
63
|
|
|
94
|
-
**Failure-mode mapping**: cross-reference 16-failure taxonomy.
|
|
64
|
+
**Failure-mode mapping**: cross-reference 16-failure taxonomy.
|
|
95
65
|
|
|
96
|
-
**
|
|
66
|
+
**MANDATORY CODEBASE SCAN**: `existingImpl=UNKNOWN` for every item. Resolve via exec:codesearch before adding. Existing concern → consolidation, not addition.
|
|
97
67
|
|
|
98
|
-
**
|
|
99
|
-
|
|
100
|
-
**EXIT PLAN**: zero new unknowns last pass AND all .prd items have acceptance criteria AND dependencies mapped → launch subagents or invoke `gm-execute`.
|
|
68
|
+
**EXIT PLAN**: zero new unknowns last pass AND every item has acceptance criteria AND deps mapped → launch subagents or invoke `gm-execute`.
|
|
101
69
|
|
|
102
70
|
## OBSERVABILITY — MANDATORY EVERY PASS
|
|
103
71
|
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
**Server**: every subsystem exposes `/debug/<subsystem>`. State readable/filterable without restart. Structured logs with subsystem+severity+timestamp.
|
|
72
|
+
Server: every subsystem exposes `/debug/<subsystem>`. Structured logs `{subsystem, severity, ts}`.
|
|
73
|
+
Client: `window.__debug` live registry; modules register on mount.
|
|
107
74
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
`console.log` = ad-hoc = not observability. `window.__debug.module.state` = permanent. Discovery of gap → add .prd item immediately. Observability = highest priority, never deferred.
|
|
75
|
+
`console.log` ≠ observability. Discovery of gap → add .prd item immediately, never deferred.
|
|
111
76
|
|
|
112
77
|
## .PRD FORMAT
|
|
113
78
|
|
|
114
|
-
Path: `./.gm/prd.yml`. Write via `exec:nodejs` + `fs.writeFileSync`. Delete when empty
|
|
79
|
+
Path: `./.gm/prd.yml`. Write via `exec:nodejs` + `fs.writeFileSync`. Delete when empty.
|
|
115
80
|
|
|
116
81
|
```yaml
|
|
117
82
|
- id: kebab-id
|
|
@@ -121,6 +86,7 @@ Path: `./.gm/prd.yml`. Write via `exec:nodejs` + `fs.writeFileSync`. Delete when
|
|
|
121
86
|
effort: small|medium|large
|
|
122
87
|
category: feature|bug|refactor|infra
|
|
123
88
|
route_family: grounding|reasoning|state|execution|observability|boundary|representation
|
|
89
|
+
load: 0.0-1.0
|
|
124
90
|
failure_modes: []
|
|
125
91
|
route_fit: unexamined|examined|dominant
|
|
126
92
|
authorization: none|weak_prior|witnessed
|
|
@@ -132,51 +98,42 @@ Path: `./.gm/prd.yml`. Write via `exec:nodejs` + `fs.writeFileSync`. Delete when
|
|
|
132
98
|
- failure mode
|
|
133
99
|
```
|
|
134
100
|
|
|
135
|
-
|
|
101
|
+
**load** axis (consequence — convergence 3.3.0): 0.9 = headline collapses if wrong. 0.7 = sub-argument rebuilt. 0.4 = local patch. 0.1 = nothing breaks. **Verification budget = load × (1 − tier_confidence)**. High-load + low-tier item = top priority. λ>0.75 must be witnessed before EMIT.
|
|
102
|
+
|
|
103
|
+
Status: pending → in_progress → completed (remove). Effort: small <15min | medium <45min | large >1h.
|
|
136
104
|
|
|
137
105
|
## PARALLEL SUBAGENT LAUNCH
|
|
138
106
|
|
|
139
|
-
After .prd written,
|
|
107
|
+
After .prd written, ≤3 parallel `gm:gm` subagents for independent items in ONE message. Browser tasks serialize.
|
|
140
108
|
|
|
141
109
|
`Agent(subagent_type="gm:gm", prompt="Work on .prd item: <id>. .prd path: <path>. Item: <full YAML>.")`
|
|
142
110
|
|
|
143
|
-
|
|
111
|
+
Not parallelizable → invoke `gm-execute` directly.
|
|
144
112
|
|
|
145
|
-
|
|
113
|
+
## EXECUTION RULES
|
|
146
114
|
|
|
147
|
-
|
|
115
|
+
`exec:<lang>` only via Bash. File I/O via exec:nodejs + fs. Git directly in Bash. Never Bash(node/npm/npx/bun).
|
|
148
116
|
|
|
149
|
-
`exec
|
|
117
|
+
`exec:codesearch` only — Glob/Grep/Find/Explore hook-blocked. Start 2 words → change/add one per pass → minimum 4 attempts before concluding absent.
|
|
150
118
|
|
|
151
|
-
Pack runs:
|
|
119
|
+
Pack runs: Promise.allSettled for parallel. Each idea own try/catch. Under 12s per call.
|
|
152
120
|
|
|
153
|
-
##
|
|
121
|
+
## DEV WORKFLOW
|
|
154
122
|
|
|
155
|
-
|
|
123
|
+
No comments. No scattered test files. 200-line limit per file. Fail loud. No duplication. Scan before edit. AGENTS.md via memorize agent only. CHANGELOG.md append per commit.
|
|
156
124
|
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
No comments. No scattered test files. 200-line limit. Fail loud. No duplication. Scan before edit. AGENTS.md via memorize only. CHANGELOG.md: append per commit.
|
|
160
|
-
|
|
161
|
-
**Minimal code process** (stop at first that resolves need):
|
|
162
|
-
1. Native — does language/runtime do this? Use it.
|
|
163
|
-
2. Library — existing dep solve this? Use its API.
|
|
164
|
-
3. Structure — encode as data (map/table/pipeline)? Make structure enforce correctness.
|
|
165
|
-
4. Write — only when 1-3 exhausted.
|
|
125
|
+
**Minimal code process** (stop at first that resolves): native → library → structure (map/pipeline) → write.
|
|
166
126
|
|
|
167
127
|
## SINGLE INTEGRATION TEST POLICY
|
|
168
128
|
|
|
169
|
-
One `test.js` at project root. 200-line max. No
|
|
170
|
-
|
|
171
|
-
`gm-complete` runs test.js before completion. Failure = regression to EXECUTE. Every behavior change updates test.js. Every bug fix adds regression case.
|
|
129
|
+
One `test.js` at project root. 200-line max. No `.test.js` / `.spec.js` / `__tests__/` / fixtures / mocks. Plain assertions, real data, real system. `gm-complete` runs it. Failure = regression to EXECUTE.
|
|
172
130
|
|
|
173
131
|
## RESPONSE POLICY
|
|
174
132
|
|
|
175
|
-
Terse. Drop filler. Fragments OK. Pattern: `[thing] [action] [reason]. [next step].`
|
|
176
|
-
Code/commits/PRs = normal prose.
|
|
133
|
+
Terse. Drop filler. Fragments OK. Pattern: `[thing] [action] [reason]. [next step].` Code/commits/PRs = normal prose.
|
|
177
134
|
|
|
178
135
|
## CONSTRAINTS
|
|
179
136
|
|
|
180
|
-
**Never**: Bash(node/npm/npx/bun) | skip planning | partial execution | stop while .prd has items | stop while git dirty | sequential independent items | screenshot before JS exhausted | fallback/demo modes | swallow errors | duplicate concern | leave comments | scattered
|
|
137
|
+
**Never**: Bash(node/npm/npx/bun) | skip planning | partial execution | stop while .prd has items | stop while git dirty | sequential independent items | screenshot before JS exhausted | fallback/demo modes | swallow errors | duplicate concern | leave comments | scattered tests | if/else where map suffices | one-liners that obscure | leave resolved unknown un-memorized | batch memorize | serialize memorize spawns
|
|
181
138
|
|
|
182
|
-
**Always**: invoke Skill at every transition | regress to planning on new unknown | witnessed execution only | scan before edits | enumerate observability gaps every pass | follow chain end-to-end | prefer dispatch tables
|
|
139
|
+
**Always**: invoke Skill at every transition | regress to planning on new unknown | witnessed execution only | scan before edits | enumerate observability gaps every pass | follow chain end-to-end | prefer dispatch tables and pipelines | make wrong states unrepresentable | spawn memorize same turn unknown resolves | end-of-turn self-check
|