get-shit-done-cc 1.41.2 → 1.42.0-rc2
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/README.md +1 -11
- package/agents/gsd-executor.md +37 -7
- package/agents/gsd-intel-updater.md +3 -3
- package/agents/gsd-phase-researcher.md +94 -7
- package/agents/gsd-planner.md +12 -20
- package/agents/gsd-verifier.md +14 -0
- package/commands/gsd/ns-review.md +1 -1
- package/get-shit-done/bin/gsd-tools.cjs +65 -64
- package/get-shit-done/bin/lib/active-workstream-store.cjs +85 -0
- package/get-shit-done/bin/lib/cjs-command-router-adapter.cjs +39 -0
- package/get-shit-done/bin/lib/command-aliases.generated.cjs +782 -69
- package/get-shit-done/bin/lib/commands.cjs +5 -1
- package/get-shit-done/bin/lib/config-schema.cjs +1 -0
- package/get-shit-done/bin/lib/config.cjs +7 -0
- package/get-shit-done/bin/lib/core.cjs +61 -75
- package/get-shit-done/bin/lib/init.cjs +52 -34
- package/get-shit-done/bin/lib/model-catalog.cjs +1 -1
- package/get-shit-done/bin/lib/phase-command-router.cjs +67 -42
- package/get-shit-done/bin/lib/phases-command-router.cjs +20 -17
- package/get-shit-done/bin/lib/plan-scan.cjs +138 -0
- package/get-shit-done/bin/lib/planning-workspace.cjs +3 -2
- package/get-shit-done/bin/lib/profile-output.cjs +13 -1
- package/get-shit-done/bin/lib/roadmap.cjs +23 -28
- package/get-shit-done/bin/lib/state-command-router.cjs +83 -74
- package/get-shit-done/bin/lib/state-document.cjs +122 -0
- package/get-shit-done/bin/lib/state.cjs +43 -111
- package/get-shit-done/bin/lib/verify.cjs +27 -26
- package/get-shit-done/bin/lib/workstream-inventory.cjs +159 -0
- package/get-shit-done/bin/lib/workstream-name-policy.cjs +33 -0
- package/get-shit-done/bin/lib/workstream.cjs +65 -189
- package/get-shit-done/bin/lib/worktree-safety.cjs +338 -0
- package/get-shit-done/references/checkpoints.md +6 -0
- package/get-shit-done/references/planner-human-verify-mode.md +57 -0
- package/get-shit-done/references/planning-config.md +2 -2
- package/get-shit-done/workflows/add-backlog.md +9 -4
- package/get-shit-done/workflows/discuss-phase.md +4 -2
- package/get-shit-done/workflows/help.md +1 -1
- package/get-shit-done/workflows/import.md +9 -4
- package/get-shit-done/workflows/plan-milestone-gaps.md +8 -1
- package/get-shit-done/workflows/plan-phase.md +4 -2
- package/get-shit-done/workflows/settings-advanced.md +1 -0
- package/get-shit-done/workflows/settings.md +3 -3
- package/package.json +1 -1
- package/sdk/dist/config.d.ts +12 -0
- package/sdk/dist/config.d.ts.map +1 -1
- package/sdk/dist/config.js +1 -0
- package/sdk/dist/config.js.map +1 -1
- package/sdk/dist/init-runner.d.ts.map +1 -1
- package/sdk/dist/init-runner.js +2 -2
- package/sdk/dist/init-runner.js.map +1 -1
- package/sdk/dist/phase-prompt.d.ts.map +1 -1
- package/sdk/dist/phase-prompt.js +3 -3
- package/sdk/dist/phase-prompt.js.map +1 -1
- package/sdk/dist/query/active-workstream-store.d.ts +7 -0
- package/sdk/dist/query/active-workstream-store.d.ts.map +1 -0
- package/sdk/dist/query/active-workstream-store.js +56 -0
- package/sdk/dist/query/active-workstream-store.js.map +1 -0
- package/sdk/dist/query/command-aliases.generated.d.ts +8 -2
- package/sdk/dist/query/command-aliases.generated.d.ts.map +1 -1
- package/sdk/dist/query/command-aliases.generated.js +44 -2
- package/sdk/dist/query/command-aliases.generated.js.map +1 -1
- package/sdk/dist/query/command-manifest.non-family.d.ts.map +1 -1
- package/sdk/dist/query/command-manifest.non-family.js +10 -0
- package/sdk/dist/query/command-manifest.non-family.js.map +1 -1
- package/sdk/dist/query/config-schema.d.ts.map +1 -1
- package/sdk/dist/query/config-schema.js +1 -0
- package/sdk/dist/query/config-schema.js.map +1 -1
- package/sdk/dist/query/helpers.d.ts +26 -20
- package/sdk/dist/query/helpers.d.ts.map +1 -1
- package/sdk/dist/query/helpers.js +70 -25
- package/sdk/dist/query/helpers.js.map +1 -1
- package/sdk/dist/query/init.d.ts.map +1 -1
- package/sdk/dist/query/init.js +73 -25
- package/sdk/dist/query/init.js.map +1 -1
- package/sdk/dist/query/phase-filesystem-adapter.d.ts +4 -0
- package/sdk/dist/query/phase-filesystem-adapter.d.ts.map +1 -0
- package/sdk/dist/query/phase-filesystem-adapter.js +33 -0
- package/sdk/dist/query/phase-filesystem-adapter.js.map +1 -0
- package/sdk/dist/query/phase-lifecycle-policy.d.ts +34 -0
- package/sdk/dist/query/phase-lifecycle-policy.d.ts.map +1 -0
- package/sdk/dist/query/phase-lifecycle-policy.js +138 -0
- package/sdk/dist/query/phase-lifecycle-policy.js.map +1 -0
- package/sdk/dist/query/phase-lifecycle.d.ts +2 -31
- package/sdk/dist/query/phase-lifecycle.d.ts.map +1 -1
- package/sdk/dist/query/phase-lifecycle.js +59 -327
- package/sdk/dist/query/phase-lifecycle.js.map +1 -1
- package/sdk/dist/query/phase-roadmap-mutation.d.ts +13 -0
- package/sdk/dist/query/phase-roadmap-mutation.d.ts.map +1 -0
- package/sdk/dist/query/phase-roadmap-mutation.js +65 -0
- package/sdk/dist/query/phase-roadmap-mutation.js.map +1 -0
- package/sdk/dist/query/plan-scan.d.ts +14 -0
- package/sdk/dist/query/plan-scan.d.ts.map +1 -0
- package/sdk/dist/query/plan-scan.js +70 -0
- package/sdk/dist/query/plan-scan.js.map +1 -0
- package/sdk/dist/query/profile-output.d.ts.map +1 -1
- package/sdk/dist/query/profile-output.js +16 -4
- package/sdk/dist/query/profile-output.js.map +1 -1
- package/sdk/dist/query/query-runtime-context.d.ts.map +1 -1
- package/sdk/dist/query/query-runtime-context.js +2 -25
- package/sdk/dist/query/query-runtime-context.js.map +1 -1
- package/sdk/dist/query/roadmap-update-plan-progress.d.ts.map +1 -1
- package/sdk/dist/query/roadmap-update-plan-progress.js +15 -5
- package/sdk/dist/query/roadmap-update-plan-progress.js.map +1 -1
- package/sdk/dist/query/roadmap.d.ts.map +1 -1
- package/sdk/dist/query/roadmap.js +2 -2
- package/sdk/dist/query/roadmap.js.map +1 -1
- package/sdk/dist/query/skill-manifest.d.ts.map +1 -1
- package/sdk/dist/query/skill-manifest.js +5 -3
- package/sdk/dist/query/skill-manifest.js.map +1 -1
- package/sdk/dist/query/skills.d.ts +3 -1
- package/sdk/dist/query/skills.d.ts.map +1 -1
- package/sdk/dist/query/skills.js +19 -7
- package/sdk/dist/query/skills.js.map +1 -1
- package/sdk/dist/query/state-document.d.ts +14 -0
- package/sdk/dist/query/state-document.d.ts.map +1 -0
- package/sdk/dist/query/state-document.js +110 -0
- package/sdk/dist/query/state-document.js.map +1 -0
- package/sdk/dist/query/state-mutation.d.ts +2 -12
- package/sdk/dist/query/state-mutation.d.ts.map +1 -1
- package/sdk/dist/query/state-mutation.js +29 -50
- package/sdk/dist/query/state-mutation.js.map +1 -1
- package/sdk/dist/query/state-project-load.d.ts.map +1 -1
- package/sdk/dist/query/state-project-load.js +2 -23
- package/sdk/dist/query/state-project-load.js.map +1 -1
- package/sdk/dist/query/state.d.ts +3 -1
- package/sdk/dist/query/state.d.ts.map +1 -1
- package/sdk/dist/query/state.js +14 -32
- package/sdk/dist/query/state.js.map +1 -1
- package/sdk/dist/query/validate.d.ts.map +1 -1
- package/sdk/dist/query/validate.js +3 -4
- package/sdk/dist/query/validate.js.map +1 -1
- package/sdk/dist/query/verify.d.ts.map +1 -1
- package/sdk/dist/query/verify.js +2 -8
- package/sdk/dist/query/verify.js.map +1 -1
- package/sdk/dist/query/workspace.d.ts +10 -2
- package/sdk/dist/query/workspace.d.ts.map +1 -1
- package/sdk/dist/query/workspace.js +7 -3
- package/sdk/dist/query/workspace.js.map +1 -1
- package/sdk/dist/query/workstream-inventory.d.ts +52 -0
- package/sdk/dist/query/workstream-inventory.d.ts.map +1 -0
- package/sdk/dist/query/workstream-inventory.js +141 -0
- package/sdk/dist/query/workstream-inventory.js.map +1 -0
- package/sdk/dist/query/workstream.d.ts.map +1 -1
- package/sdk/dist/query/workstream.js +66 -190
- package/sdk/dist/query/workstream.js.map +1 -1
- package/sdk/dist/query-gsd-tools-path.d.ts +1 -7
- package/sdk/dist/query-gsd-tools-path.d.ts.map +1 -1
- package/sdk/dist/query-gsd-tools-path.js +1 -18
- package/sdk/dist/query-gsd-tools-path.js.map +1 -1
- package/sdk/dist/sdk-package-compatibility.d.ts +37 -0
- package/sdk/dist/sdk-package-compatibility.d.ts.map +1 -0
- package/sdk/dist/sdk-package-compatibility.js +87 -0
- package/sdk/dist/sdk-package-compatibility.js.map +1 -0
- package/sdk/dist/session-runner.d.ts.map +1 -1
- package/sdk/dist/session-runner.js +2 -0
- package/sdk/dist/session-runner.js.map +1 -1
- package/sdk/dist/types.d.ts +1 -1
- package/sdk/dist/workstream-name-policy.d.ts +13 -0
- package/sdk/dist/workstream-name-policy.d.ts.map +1 -0
- package/sdk/dist/workstream-name-policy.js +24 -0
- package/sdk/dist/workstream-name-policy.js.map +1 -0
- package/sdk/dist/workstream-utils.d.ts +1 -6
- package/sdk/dist/workstream-utils.d.ts.map +1 -1
- package/sdk/dist/workstream-utils.js +1 -14
- package/sdk/dist/workstream-utils.js.map +1 -1
- package/sdk/package-lock.json +2 -2
- package/sdk/package.json +1 -1
- package/sdk/src/config.ts +13 -0
- package/sdk/src/init-runner.ts +2 -2
- package/sdk/src/phase-prompt.ts +3 -3
- package/sdk/src/query/QUERY-HANDLERS.md +4 -4
- package/sdk/src/query/active-workstream-store.ts +50 -0
- package/sdk/src/query/command-aliases.generated.ts +51 -3
- package/sdk/src/query/command-manifest.non-family.ts +17 -0
- package/sdk/src/query/config-query.test.ts +3 -1
- package/sdk/src/query/config-schema.ts +1 -0
- package/sdk/src/query/helpers.test.ts +72 -0
- package/sdk/src/query/helpers.ts +71 -35
- package/sdk/src/query/init.ts +77 -24
- package/sdk/src/query/phase-filesystem-adapter.ts +35 -0
- package/sdk/src/query/phase-lifecycle-policy.ts +171 -0
- package/sdk/src/query/phase-lifecycle.test.ts +119 -0
- package/sdk/src/query/phase-lifecycle.ts +89 -351
- package/sdk/src/query/phase-roadmap-mutation.ts +77 -0
- package/sdk/src/query/plan-scan.test.ts +35 -0
- package/sdk/src/query/plan-scan.ts +82 -0
- package/sdk/src/query/profile-output.ts +18 -4
- package/sdk/src/query/profile.test.ts +63 -1
- package/sdk/src/query/query-runtime-context.ts +2 -23
- package/sdk/src/query/roadmap-update-plan-progress.test.ts +41 -0
- package/sdk/src/query/roadmap-update-plan-progress.ts +16 -5
- package/sdk/src/query/roadmap.ts +2 -5
- package/sdk/src/query/skill-manifest.test.ts +62 -0
- package/sdk/src/query/skill-manifest.ts +5 -3
- package/sdk/src/query/skills.test.ts +36 -0
- package/sdk/src/query/skills.ts +19 -7
- package/sdk/src/query/state-document.ts +129 -0
- package/sdk/src/query/state-mutation.test.ts +164 -0
- package/sdk/src/query/state-mutation.ts +35 -51
- package/sdk/src/query/state-project-load.ts +2 -31
- package/sdk/src/query/state.test.ts +32 -4
- package/sdk/src/query/state.ts +25 -25
- package/sdk/src/query/validate.ts +2 -3
- package/sdk/src/query/verify.ts +2 -8
- package/sdk/src/query/workspace.test.ts +4 -3
- package/sdk/src/query/workspace.ts +18 -4
- package/sdk/src/query/workstream-inventory.ts +195 -0
- package/sdk/src/query/workstream.test.ts +29 -1
- package/sdk/src/query/workstream.ts +69 -199
- package/sdk/src/query-gsd-tools-path.ts +1 -24
- package/sdk/src/sdk-package-compatibility.test.ts +95 -0
- package/sdk/src/sdk-package-compatibility.ts +137 -0
- package/sdk/src/session-runner.ts +1 -0
- package/sdk/src/types.ts +1 -1
- package/sdk/src/workstream-name-policy.ts +24 -0
- package/sdk/src/workstream-utils.ts +1 -13
- package/sdk-bundle/gsd-sdk.tgz +0 -0
package/README.md
CHANGED
|
@@ -162,17 +162,7 @@ The main loop:
|
|
|
162
162
|
| `/gsd-complete-milestone` | Archive milestone and tag release |
|
|
163
163
|
| `/gsd-new-milestone` | Start next version |
|
|
164
164
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
| Command | What it does |
|
|
168
|
-
|---------|--------------|
|
|
169
|
-
| `/gsd-quick` | Ad-hoc tasks with GSD guarantees — skips planning overhead |
|
|
170
|
-
| `/gsd-map-codebase` | Analyze an existing codebase before starting a new project |
|
|
171
|
-
| `/gsd-autonomous` | Drive all remaining phases without stopping |
|
|
172
|
-
| `/gsd-forensics` | Post-mortem a failed or stuck run |
|
|
173
|
-
| `/gsd-help` | Full command reference inside your runtime |
|
|
174
|
-
|
|
175
|
-
For the complete command reference — workstreams, workspaces, phase management, code quality, backlog, session tools — see **[docs/COMMANDS.md](docs/COMMANDS.md)**.
|
|
165
|
+
For ad-hoc tasks, autonomous mode, codebase analysis, forensics, and the full command surface — see **[docs/COMMANDS.md](docs/COMMANDS.md)**.
|
|
176
166
|
|
|
177
167
|
---
|
|
178
168
|
|
package/agents/gsd-executor.md
CHANGED
|
@@ -33,19 +33,26 @@ When you need library or framework documentation, check in this order:
|
|
|
33
33
|
|
|
34
34
|
Step 1 — Resolve library ID:
|
|
35
35
|
```bash
|
|
36
|
-
|
|
36
|
+
if command -v ctx7 &>/dev/null; then
|
|
37
|
+
ctx7 library <name> "<query>"
|
|
38
|
+
else
|
|
39
|
+
echo "ctx7 not found — install with: npm install -g ctx7 (verify at npmjs.com/package/ctx7 first)"
|
|
40
|
+
fi
|
|
37
41
|
```
|
|
38
|
-
Example: `npx --yes ctx7@latest library react "useEffect hook"`
|
|
39
42
|
|
|
40
43
|
Step 2 — Fetch documentation:
|
|
41
44
|
```bash
|
|
42
|
-
|
|
45
|
+
if command -v ctx7 &>/dev/null; then
|
|
46
|
+
ctx7 docs <libraryId> "<query>"
|
|
47
|
+
else
|
|
48
|
+
echo "ctx7 not found — install with: npm install -g ctx7 (verify at npmjs.com/package/ctx7 first)"
|
|
49
|
+
fi
|
|
43
50
|
```
|
|
44
|
-
Example: `npx --yes ctx7@latest docs /facebook/react "useEffect hook"`
|
|
45
51
|
|
|
46
52
|
Do not skip documentation lookups because MCP tools are unavailable — the CLI fallback
|
|
47
53
|
works via Bash and produces equivalent output. Do not rely on training knowledge alone
|
|
48
|
-
for library APIs where version-specific behavior matters.
|
|
54
|
+
for library APIs where version-specific behavior matters. Do NOT use `npx --yes` to
|
|
55
|
+
auto-download ctx7 — this silently executes unverified packages from the registry.
|
|
49
56
|
</documentation_lookup>
|
|
50
57
|
|
|
51
58
|
<project_context>
|
|
@@ -168,7 +175,30 @@ No user permission needed for Rules 1-3.
|
|
|
168
175
|
|
|
169
176
|
**Trigger:** Something prevents completing current task
|
|
170
177
|
|
|
171
|
-
**Examples:**
|
|
178
|
+
**Examples:** Wrong types, broken imports, missing env var, DB connection error, build config error, missing referenced file, circular dependency
|
|
179
|
+
|
|
180
|
+
**EXCLUDED from RULE 3 — package manager installs:**
|
|
181
|
+
Running `npm install <pkg>`, `pip install <pkg>`, `cargo add <pkg>`, or any equivalent package-manager install command is **NOT** auto-fixable. If a referenced package fails to install or cannot be found:
|
|
182
|
+
1. Do NOT attempt to install a similarly-named alternative.
|
|
183
|
+
2. Do NOT retry with a different package name.
|
|
184
|
+
3. Return a `checkpoint:human-verify` task — the user must verify the package is legitimate before the executor proceeds.
|
|
185
|
+
|
|
186
|
+
This exclusion exists because a failed install may indicate a slopsquatted or hallucinated package name. Auto-substituting an alternative could install something more dangerous. If a package install fails, emit:
|
|
187
|
+
|
|
188
|
+
```xml
|
|
189
|
+
<task type="checkpoint:human-verify" gate="blocking-human">
|
|
190
|
+
<what-built>Package install failed — human verification required</what-built>
|
|
191
|
+
<how-to-verify>
|
|
192
|
+
`[package-name]` could not be installed. Before proceeding:
|
|
193
|
+
1. Verify the package exists and is legitimate: https://npmjs.com/package/[package-name]
|
|
194
|
+
2. Confirm the package name is spelled correctly in PLAN.md
|
|
195
|
+
3. If the package does not exist, return to /gsd-research-phase to find the correct package
|
|
196
|
+
</how-to-verify>
|
|
197
|
+
<resume-signal>Type "verified" with the correct package name, or "abort" to stop the phase</resume-signal>
|
|
198
|
+
</task>
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
Use `gate="blocking-human"` for package-legitimacy checkpoints so they are unambiguously excluded from auto-approval behavior.
|
|
172
202
|
|
|
173
203
|
---
|
|
174
204
|
|
|
@@ -265,7 +295,7 @@ For full automation-first patterns, server lifecycle, CLI handling:
|
|
|
265
295
|
|
|
266
296
|
**Auto-mode checkpoint behavior** (when `AUTO_CFG` is `"true"`):
|
|
267
297
|
|
|
268
|
-
- **checkpoint:human-verify** → Auto-approve
|
|
298
|
+
- **checkpoint:human-verify** → Auto-approve **except package-legitimacy checkpoints**. If checkpoint has `gate="blocking-human"` OR its purpose indicates package legitimacy verification (`what-built` mentions `Package verification required before install` or `Package install failed — human verification required`), do **not** auto-approve. STOP and return checkpoint_return_format for explicit human confirmation.
|
|
269
299
|
- **checkpoint:decision** → Auto-select first option (planners front-load the recommended choice). Log `⚡ Auto-selected: [option name]`. Continue to next task.
|
|
270
300
|
- **checkpoint:human-action** → STOP normally. Auth gates cannot be automated — return structured checkpoint message using checkpoint_return_format.
|
|
271
301
|
|
|
@@ -44,15 +44,15 @@ Write machine-parseable, evidence-based intelligence. Every claim references act
|
|
|
44
44
|
<upstream_input>
|
|
45
45
|
## Upstream Input
|
|
46
46
|
|
|
47
|
-
### From `/gsd-
|
|
47
|
+
### From `/gsd-map-codebase --query` Command
|
|
48
48
|
|
|
49
|
-
- **Spawned by:** `/gsd-
|
|
49
|
+
- **Spawned by:** `/gsd-map-codebase --query` command
|
|
50
50
|
- **Receives:** Focus directive -- either `full` (all 5 files) or `partial --files <paths>` (update specific file entries only)
|
|
51
51
|
- **Input format:** Spawn prompt with `focus: full|partial` directive and project root path
|
|
52
52
|
|
|
53
53
|
### Config Gate
|
|
54
54
|
|
|
55
|
-
The /gsd-
|
|
55
|
+
The /gsd-map-codebase --query command has already confirmed that intel.enabled is true before spawning this agent. Proceed directly to Step 1.
|
|
56
56
|
</upstream_input>
|
|
57
57
|
|
|
58
58
|
## Project Scope
|
|
@@ -26,10 +26,12 @@ Spawned by `/gsd-plan-phase` (integrated) or `/gsd-research-phase` (standalone).
|
|
|
26
26
|
- Return structured result to orchestrator
|
|
27
27
|
|
|
28
28
|
**Claim provenance:** Every factual claim in RESEARCH.md must be tagged with its source:
|
|
29
|
-
- `[VERIFIED: npm registry]` — confirmed via tool (npm view, web search, codebase grep)
|
|
29
|
+
- `[VERIFIED: npm registry]` — confirmed via tool (npm view, web search, codebase grep) AND discovered from an authoritative source (official docs, Context7)
|
|
30
30
|
- `[CITED: docs.example.com/page]` — referenced from official documentation
|
|
31
31
|
- `[ASSUMED]` — based on training knowledge, not verified in this session
|
|
32
32
|
|
|
33
|
+
**Package name provenance rule:** A package name discovered via WebSearch, training data, or any non-authoritative source must be tagged `[ASSUMED]` regardless of whether `npm view` confirms it exists on the registry. Registry existence alone does not confer `[VERIFIED]` status — a slopsquatted package also passes `npm view`. Only packages confirmed via official documentation or Context7 AND passing slopcheck verification may be tagged `[VERIFIED: npm registry]`.
|
|
34
|
+
|
|
33
35
|
Claims tagged `[ASSUMED]` signal to the planner and discuss-phase that the information needs user confirmation before becoming a locked decision. Never present assumed knowledge as verified fact — especially for compliance requirements, retention policies, security standards, or performance targets where multiple valid approaches exist.
|
|
34
36
|
</role>
|
|
35
37
|
|
|
@@ -45,15 +47,24 @@ When you need library or framework documentation, check in this order:
|
|
|
45
47
|
|
|
46
48
|
Step 1 — Resolve library ID:
|
|
47
49
|
```bash
|
|
48
|
-
|
|
50
|
+
if command -v ctx7 &>/dev/null; then
|
|
51
|
+
ctx7 library <name> "<query>"
|
|
52
|
+
else
|
|
53
|
+
echo "ctx7 not found — install with: npm install -g ctx7 (verify at npmjs.com/package/ctx7 first)"
|
|
54
|
+
fi
|
|
49
55
|
```
|
|
50
56
|
Step 2 — Fetch documentation:
|
|
51
57
|
```bash
|
|
52
|
-
|
|
58
|
+
if command -v ctx7 &>/dev/null; then
|
|
59
|
+
ctx7 docs <libraryId> "<query>"
|
|
60
|
+
else
|
|
61
|
+
echo "ctx7 not found — install with: npm install -g ctx7 (verify at npmjs.com/package/ctx7 first)"
|
|
62
|
+
fi
|
|
53
63
|
```
|
|
54
64
|
|
|
55
65
|
Do not skip documentation lookups because MCP tools are unavailable — the CLI fallback
|
|
56
|
-
works via Bash and produces equivalent output.
|
|
66
|
+
works via Bash and produces equivalent output. Do NOT use `npx --yes` to auto-download
|
|
67
|
+
ctx7 — this silently executes unverified packages from the registry.
|
|
57
68
|
</documentation_lookup>
|
|
58
69
|
|
|
59
70
|
<project_context>
|
|
@@ -251,6 +262,65 @@ Priority: Context7 > Exa (verified) > Firecrawl (official docs) > Official GitHu
|
|
|
251
262
|
|
|
252
263
|
</verification_protocol>
|
|
253
264
|
|
|
265
|
+
<package_legitimacy_protocol>
|
|
266
|
+
|
|
267
|
+
## Package Legitimacy Gate
|
|
268
|
+
|
|
269
|
+
Every phase that installs external packages **must** run the following verification before
|
|
270
|
+
emitting the `## Package Legitimacy Audit` section in RESEARCH.md.
|
|
271
|
+
|
|
272
|
+
### Step 1 — Install slopcheck (best-effort)
|
|
273
|
+
|
|
274
|
+
```bash
|
|
275
|
+
pip install slopcheck --break-system-packages 2>/dev/null || pip install slopcheck 2>/dev/null || true
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
### Step 2 — Run legitimacy check
|
|
279
|
+
|
|
280
|
+
```bash
|
|
281
|
+
if command -v slopcheck &>/dev/null; then
|
|
282
|
+
slopcheck install <pkg1> <pkg2> ... --json
|
|
283
|
+
else
|
|
284
|
+
echo "slopcheck not available — marking all packages [ASSUMED]"
|
|
285
|
+
fi
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
**Interpreting results:**
|
|
289
|
+
- `[SLOP]` — hallucinated or dangerously new package. **Remove entirely** from all RESEARCH.md recommendations. List in audit table under `Disposition: REMOVED`.
|
|
290
|
+
- `[SUS]` — suspicious (new, low-downloads, or no source repo). **Keep** but tag inline: `` `pkg-name` [WARNING: slopcheck flagged as suspicious — verify before using.] ``
|
|
291
|
+
- `[OK]` — clean. Proceed normally.
|
|
292
|
+
|
|
293
|
+
**Graceful degradation:** If slopcheck cannot be installed or cannot run, mark **every** recommended package `[ASSUMED]` (not `[VERIFIED]`). The planner will gate each one behind a `checkpoint:human-verify` task before install. This is strictly safer than the current baseline — never a hard failure.
|
|
294
|
+
|
|
295
|
+
### Step 3 — Ecosystem-specific registry verification
|
|
296
|
+
|
|
297
|
+
Run the appropriate command for the phase's primary language:
|
|
298
|
+
|
|
299
|
+
```bash
|
|
300
|
+
# Node.js / JavaScript phases
|
|
301
|
+
npm view <pkg> version
|
|
302
|
+
|
|
303
|
+
# Python phases
|
|
304
|
+
pip index versions <pkg>
|
|
305
|
+
|
|
306
|
+
# Rust phases
|
|
307
|
+
cargo search <pkg>
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
Cross-ecosystem confusion (a Python package name that exists on npm but not PyPI) is a
|
|
311
|
+
documented hallucination vector (~9% rate). Always verify on the correct ecosystem registry.
|
|
312
|
+
|
|
313
|
+
### Step 4 — Check for suspicious postinstall scripts (Node.js phases)
|
|
314
|
+
|
|
315
|
+
```bash
|
|
316
|
+
npm view <pkg> scripts.postinstall 2>/dev/null
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
A `postinstall` script that references network calls or filesystem paths outside the project
|
|
320
|
+
directory is a high-risk signal. Flag such packages `[SUS]` even if slopcheck rates them `[OK]`.
|
|
321
|
+
|
|
322
|
+
</package_legitimacy_protocol>
|
|
323
|
+
|
|
254
324
|
<output_format>
|
|
255
325
|
|
|
256
326
|
## RESEARCH.md Structure
|
|
@@ -298,11 +368,28 @@ Priority: Context7 > Exa (verified) > Firecrawl (official docs) > Official GitHu
|
|
|
298
368
|
npm install [packages]
|
|
299
369
|
\`\`\`
|
|
300
370
|
|
|
301
|
-
**Version verification:** Before writing the Standard Stack table, verify each recommended package
|
|
371
|
+
**Version verification:** Before writing the Standard Stack table, verify each recommended package exists and is current using the ecosystem-appropriate command:
|
|
302
372
|
\`\`\`bash
|
|
303
|
-
npm view [package] version
|
|
373
|
+
npm view [package] version # Node.js phases
|
|
374
|
+
pip index versions [package] # Python phases
|
|
375
|
+
cargo search [package] # Rust phases
|
|
304
376
|
\`\`\`
|
|
305
|
-
Document the verified version and publish date. Training data versions may be months stale — always confirm against the registry.
|
|
377
|
+
Document the verified version and publish date. Training data versions may be months stale — always confirm against the correct ecosystem registry.
|
|
378
|
+
|
|
379
|
+
## Package Legitimacy Audit
|
|
380
|
+
|
|
381
|
+
> **Required** whenever this phase installs external packages. Run the Package Legitimacy Gate protocol before completing this section.
|
|
382
|
+
|
|
383
|
+
| Package | Registry | Age | Downloads | Source Repo | slopcheck | Disposition |
|
|
384
|
+
|---------|----------|-----|-----------|-------------|-----------|-------------|
|
|
385
|
+
| [name] | npm/PyPI/crates | [e.g., 8 yrs] | [e.g., 50M/wk] | [github.com/org/repo or "none"] | [OK] | Approved |
|
|
386
|
+
| [name] | npm | [e.g., 3 days] | [e.g., 0] | none | [SLOP] | REMOVED |
|
|
387
|
+
| [name] | npm | [e.g., 2 mo] | [e.g., 800/wk] | [github.com/…] | [SUS] | Flagged — planner must add checkpoint |
|
|
388
|
+
|
|
389
|
+
**Packages removed due to slopcheck [SLOP] verdict:** [list, or "none"]
|
|
390
|
+
**Packages flagged as suspicious [SUS]:** [list — planner inserts checkpoint:human-verify before each install]
|
|
391
|
+
|
|
392
|
+
*If slopcheck was unavailable at research time, all packages above are tagged `[ASSUMED]` and the planner must gate each install behind a `checkpoint:human-verify` task.*
|
|
306
393
|
|
|
307
394
|
## Architecture Patterns
|
|
308
395
|
|
package/agents/gsd-planner.md
CHANGED
|
@@ -35,7 +35,7 @@ Your job: Produce PLAN.md files that Claude executors can implement without inte
|
|
|
35
35
|
</role>
|
|
36
36
|
|
|
37
37
|
<documentation_lookup>
|
|
38
|
-
For library docs:
|
|
38
|
+
For library docs: prefer Context7 MCP. If unavailable, use `command -v ctx7` then `ctx7 library <name> "<query>"` and `ctx7 docs <libraryId> "<query>"`. Never use `npx --yes ctx7@latest`.
|
|
39
39
|
</documentation_lookup>
|
|
40
40
|
|
|
41
41
|
<project_context>
|
|
@@ -304,6 +304,8 @@ This prevents the "scavenger hunt" anti-pattern where executors explore the code
|
|
|
304
304
|
|
|
305
305
|
Exceptions where `tdd="true"` is not needed: `type="checkpoint:*"` tasks, configuration-only files, documentation, migration scripts, glue code wiring existing tested components, styling-only changes.
|
|
306
306
|
|
|
307
|
+
`workflow.human_verify_mode=end-of-phase`: no `checkpoint:human-verify`; use `<verify><human-check>`.
|
|
308
|
+
|
|
307
309
|
## MVP Mode Detection
|
|
308
310
|
|
|
309
311
|
**When `MVP_MODE` is enabled (passed by the plan-phase orchestrator):** Decompose tasks as **vertical feature slices**, not horizontal layers. Required reading: `@~/.claude/get-shit-done/references/planner-mvp-mode.md` (loaded conditionally by the orchestrator).
|
|
@@ -482,6 +484,7 @@ Output: [Artifacts created]
|
|
|
482
484
|
|-----------|----------|-----------|-------------|-----------------|
|
|
483
485
|
| T-{phase}-01 | {S/T/R/I/D/E} | {function/endpoint/file} | mitigate | {specific: e.g., "validate input with zod at route entry"} |
|
|
484
486
|
| T-{phase}-02 | {category} | {component} | accept | {rationale: e.g., "no PII, low-value target"} |
|
|
487
|
+
| T-{phase}-SC | Tampering | npm/pip/cargo installs | mitigate | slopcheck + blocking human checkpoint for [ASSUMED]/[SUS] |
|
|
485
488
|
</threat_model>
|
|
486
489
|
|
|
487
490
|
<verification>
|
|
@@ -617,6 +620,14 @@ Read ROADMAP.md `**Requirements:**` line for this phase. Strip brackets if prese
|
|
|
617
620
|
|
|
618
621
|
**Security (when `security_enforcement` enabled — absent = enabled):** Identify trust boundaries in this phase's scope. Map STRIDE categories to applicable tech stack from RESEARCH.md security domain. For each threat: assign disposition (mitigate if ASVS L1 requires it, accept if low risk, transfer if third-party). Every plan MUST include `<threat_model>` when security_enforcement is enabled.
|
|
619
622
|
|
|
623
|
+
**Package legitimacy gate (npm/pip/cargo only):**
|
|
624
|
+
- Require RESEARCH.md `## Package Legitimacy Audit` before package-manager install tasks.
|
|
625
|
+
- If install tasks exist and the table is missing/malformed, stop planning:
|
|
626
|
+
`Package installs detected but audit table not found — researcher must run Package Legitimacy Gate protocol`
|
|
627
|
+
Fallback policy: treat all packages as `[ASSUMED]`.
|
|
628
|
+
- For each `[ASSUMED]`/`[SUS]` package, insert `<task type="checkpoint:human-verify" gate="blocking-human">` before install and verify via `npmjs.com/package`, `pypi.org/project`, or `crates.io/crates`.
|
|
629
|
+
- `[SLOP]` packages are forbidden; legitimacy checkpoints are never auto-approvable (`workflow.auto_advance` ignored). Keep `T-{phase}-SC` in `<threat_model>`.
|
|
630
|
+
|
|
620
631
|
**Step 1: State the Goal**
|
|
621
632
|
Take phase goal from ROADMAP.md. Must be outcome-shaped, not task-shaped.
|
|
622
633
|
- Good: "Working chat interface" (outcome)
|
|
@@ -657,11 +668,6 @@ Message list component wiring:
|
|
|
657
668
|
**Step 5: Identify Key Links**
|
|
658
669
|
"Where is this most likely to break?" Key links = critical connections where breakage causes cascading failures.
|
|
659
670
|
|
|
660
|
-
For chat interface:
|
|
661
|
-
- Input onSubmit -> API call (if broken: typing works but sending doesn't)
|
|
662
|
-
- API save -> database (if broken: appears to send but doesn't persist)
|
|
663
|
-
- Component -> real data (if broken: shows placeholder, not messages)
|
|
664
|
-
|
|
665
671
|
## Must-Haves Output Format
|
|
666
672
|
|
|
667
673
|
```yaml
|
|
@@ -691,20 +697,6 @@ must_haves:
|
|
|
691
697
|
pattern: "prisma\\.message\\.(find|create)"
|
|
692
698
|
```
|
|
693
699
|
|
|
694
|
-
## Common Failures
|
|
695
|
-
|
|
696
|
-
**Truths too vague:**
|
|
697
|
-
- Bad: "User can use chat"
|
|
698
|
-
- Good: "User can see messages", "User can send message", "Messages persist"
|
|
699
|
-
|
|
700
|
-
**Artifacts too abstract:**
|
|
701
|
-
- Bad: "Chat system", "Auth module"
|
|
702
|
-
- Good: "src/components/Chat.tsx", "src/app/api/auth/login/route.ts"
|
|
703
|
-
|
|
704
|
-
**Missing wiring:**
|
|
705
|
-
- Bad: Listing components without how they connect
|
|
706
|
-
- Good: "Chat.tsx fetches from /api/chat via useEffect on mount"
|
|
707
|
-
|
|
708
700
|
</goal_backward>
|
|
709
701
|
|
|
710
702
|
<checkpoints>
|
package/agents/gsd-verifier.md
CHANGED
|
@@ -532,6 +532,20 @@ done
|
|
|
532
532
|
|
|
533
533
|
**Needs human if uncertain:** Complex wiring grep can't trace, dynamic state behavior, edge cases.
|
|
534
534
|
|
|
535
|
+
**Harvest deferred items from PLAN.md (#3309 / `workflow.human_verify_mode = end-of-phase`):** Scan every PLAN file in the phase for `<verify><human-check>` blocks on `auto` tasks. These are verification items the planner deliberately deferred from `checkpoint:human-verify` to end-of-phase to avoid the executor cold-start cost. Each block has the same shape used by the planner:
|
|
536
|
+
|
|
537
|
+
```xml
|
|
538
|
+
<verify>
|
|
539
|
+
<human-check>
|
|
540
|
+
<test>What to do</test>
|
|
541
|
+
<expected>What should happen</expected>
|
|
542
|
+
<why_human>Why grep can't verify</why_human>
|
|
543
|
+
</human-check>
|
|
544
|
+
</verify>
|
|
545
|
+
```
|
|
546
|
+
|
|
547
|
+
Merge those harvested items into the same human verification list as your own analysis. Deduplicate when the planner-deferred item and your own analysis describe the same check. The downstream `human_needed` → HUMAN-UAT.md path in `workflows/execute-phase.md` is the single sink — no separate file is created.
|
|
548
|
+
|
|
535
549
|
**Format:**
|
|
536
550
|
|
|
537
551
|
```markdown
|