tracerkit 1.6.0 → 1.7.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tracerkit",
3
- "version": "1.6.0",
3
+ "version": "1.7.0",
4
4
  "description": "Spec-driven workflow for Claude Code: replace ad-hoc prompts with PRD → plan → verify.",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -41,13 +41,17 @@ Read `{{paths.plans}}/<slug>.md`. If it does not exist, list available plans and
41
41
 
42
42
  Read the source PRD referenced in the plan header (`> Source PRD: ...`).
43
43
 
44
- ### 3. Launch read-only review
44
+ ### 3. Fast-path: check if implementation exists
45
+
46
+ Before launching a subagent, check whether the primary module file(s) from Phase 1 exist. If none exist, skip the subagent entirely and report `0/N — not yet started`. List Phase 1's "Done when" items as next steps and jump to Step 5.
47
+
48
+ ### 3b. Launch read-only review
45
49
 
46
50
  Use a **read-only subagent** (no file writes, no edits) to:
47
51
 
48
52
  1. Read every section of the plan — architectural decisions, each phase, done-when checkboxes
49
53
  2. For each phase, check every `- [ ]` / `- [x]` item against the codebase
50
- 3. Run any test commands referenced in the plan or discoverable via project conventions
54
+ 3. Run the project's test suite (e.g., `npm test`, `npx vitest run`) and include pass/fail results in the report. If no test command is discoverable, note this.
51
55
  4. Compare user stories from the PRD against actual behavior
52
56
 
53
57
  For each checkbox, determine whether it should be verified (`[x]`) or not (`[ ]`) and report this — do not edit any files.
@@ -57,7 +61,7 @@ Collect findings into two categories:
57
61
  - **BLOCKERS** — checked items that don't hold up, failing tests, broken contracts. These prevent transitioning to `done`.
58
62
  - **SUGGESTIONS** — improvements, minor gaps, style issues. These do not prevent `done`.
59
63
 
60
- ### 3b. Update checkboxes
64
+ ### 3c. Update checkboxes
61
65
 
62
66
  Using the subagent's report, update each checkbox in `{{paths.plans}}/<slug>.md` to `[x]` or `[ ]`.
63
67
 
@@ -33,7 +33,7 @@ If the PRD has no frontmatter, skip this step silently.
33
33
 
34
34
  ### 2. Explore the codebase
35
35
 
36
- Understand current architecture, existing patterns, and integration points.
36
+ Understand current architecture, existing patterns, and integration points. If you already have codebase context from a prior step in this conversation (e.g., you just ran `/tk:prd`), skip the exploration and note which context you're reusing.
37
37
 
38
38
  **Research protocol**: codebase first, then project docs. If you cannot verify a technical claim from these sources, flag it as uncertain — never fabricate.
39
39
 
@@ -132,7 +132,7 @@ Carried forward from PRD verbatim.
132
132
  Gaps found in the PRD needing resolution. Blank if none.
133
133
  ```
134
134
 
135
- Print saved path and one line per phase: `Phase N — <title> (<condition summary>)`.
135
+ Print saved path and one line per phase: `Phase N — <title> (<condition summary>)`. Then ask: "Run `/tk:check <slug>` when ready?"
136
136
 
137
137
  ## Rules
138
138
 
@@ -140,7 +140,7 @@ Print saved path and one line per phase: `Phase N — <title> (<condition summar
140
140
  - Each phase must be demoable end-to-end on its own
141
141
  - "Done when" must be a checkbox list of testable conditions, not prose
142
142
  - **Safety valve**: if a phase has >5 "Done when" items, stop and split it into smaller phases before continuing
143
- - Never modify the source PRD
143
+ - Never modify the source PRD content — only update frontmatter status fields
144
144
  - Carry PRD's Out of Scope forward verbatim
145
145
 
146
146
  ## Error Handling
@@ -7,13 +7,17 @@ argument-hint: <idea>
7
7
 
8
8
  Skip steps already satisfied. If user provided a description via arguments, skip to Step 2.
9
9
 
10
+ ## Pre-loaded context
11
+
12
+ - Existing PRDs: !`ls {{paths.prds}}/ 2>/dev/null || echo "none"`
13
+
10
14
  ## Input
11
15
 
12
16
  The argument is: $ARGUMENTS
13
17
 
14
18
  If the argument is empty, go straight to Step 1 (gather problem description). After gathering the idea, derive the slug from the idea.
15
19
 
16
- If the argument is provided, convert it to a kebab-case slug (lowercase, spaces and underscores replaced with hyphens). This is `<slug>`. The output file is `{{paths.prds}}/<slug>.md`.
20
+ If the argument is provided, derive a slug: use only the text before `—` or `–` (if present), take at most 3–4 keywords, strip filler words (a, the, for, etc.), then convert to kebab-case (lowercase, hyphens). This is `<slug>`. The output file is `{{paths.prds}}/<slug>.md`.
17
21
 
18
22
  If `{{paths.prds}}/<slug>.md` already exists, tell the user and ask whether to overwrite or pick a new name.
19
23
 
@@ -33,7 +37,7 @@ Verify assertions and map current state: data models, services, API routes, fron
33
37
 
34
38
  Interview relentlessly, one question at a time. Lead with your recommended answer; let the user confirm or correct. If a question can be answered by exploring code, explore instead of asking. For terse answers, offer concrete options (A/B/C).
35
39
 
36
- Walk these branches (skip any already resolved):
40
+ Walk these branches (skip any already resolved or irrelevant to the project type — e.g., for CLI tools and libraries, skip UI-specific branches like Display, Access, Navigation unless the idea involves them):
37
41
 
38
42
  - **Scope & Surface** — Where does this live? New page/view or integrated? Which user roles?
39
43
  - **Data & Concepts** — Precise definitions for each new concept. What data exists, what's missing?
@@ -124,6 +128,8 @@ Long numbered list. Cover happy path, edge cases, error states.
124
128
 
125
129
  Do NOT include file paths or code snippets — they go stale.
126
130
 
131
+ Omit any section whose content would be "None required" — only include sections with actual content.
132
+
127
133
  ## Testing Decisions
128
134
 
129
135
  - What makes a good test (behavior, not implementation)
@@ -136,7 +142,7 @@ Do NOT include file paths or code snippets — they go stale.
136
142
  Explicit list. Be specific — vague exclusions invite scope creep.
137
143
  ```
138
144
 
139
- Tell the user: file created, one-line summary, next step is `/tk:plan <slug>`.
145
+ Tell the user: file created, one-line summary. Then ask: "Run `/tk:plan <slug>` next?"
140
146
 
141
147
  ## Error Handling
142
148