sdtk-code-kit 0.2.0 → 0.2.1

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.
Files changed (75) hide show
  1. package/README.md +201 -201
  2. package/assets/manifest/toolkit-bundle.manifest.json +147 -147
  3. package/assets/manifest/toolkit-bundle.sha256.txt +28 -28
  4. package/assets/toolkit/toolkit/AGENTS.md +219 -219
  5. package/assets/toolkit/toolkit/install.ps1 +156 -156
  6. package/assets/toolkit/toolkit/scripts/install-claude-skills.ps1 +78 -78
  7. package/assets/toolkit/toolkit/scripts/install-codex-skills.ps1 +150 -150
  8. package/assets/toolkit/toolkit/scripts/uninstall-claude-skills.ps1 +62 -62
  9. package/assets/toolkit/toolkit/scripts/uninstall-codex-skills.ps1 +82 -82
  10. package/assets/toolkit/toolkit/sdtk-spec.config.json +6 -6
  11. package/assets/toolkit/toolkit/sdtk-spec.config.profiles.example.json +12 -12
  12. package/assets/toolkit/toolkit/skills/code-brainstorm/SKILL.md +55 -55
  13. package/assets/toolkit/toolkit/skills/code-debug/SKILL.md +296 -296
  14. package/assets/toolkit/toolkit/skills/code-debug/references/root-cause-tracing.md +68 -68
  15. package/assets/toolkit/toolkit/skills/code-discover/SKILL.md +54 -54
  16. package/assets/toolkit/toolkit/skills/code-execute/SKILL.md +74 -74
  17. package/assets/toolkit/toolkit/skills/code-finish/SKILL.md +205 -205
  18. package/assets/toolkit/toolkit/skills/code-parallel/SKILL.md +64 -64
  19. package/assets/toolkit/toolkit/skills/code-parallel/references/code-quality-reviewer-prompt.md +26 -26
  20. package/assets/toolkit/toolkit/skills/code-parallel/references/implementer-prompt.md +113 -113
  21. package/assets/toolkit/toolkit/skills/code-parallel/references/spec-reviewer-prompt.md +61 -61
  22. package/assets/toolkit/toolkit/skills/code-plan/SKILL.md +85 -85
  23. package/assets/toolkit/toolkit/skills/code-review/SKILL.md +79 -79
  24. package/assets/toolkit/toolkit/skills/code-review/references/checklist.md +125 -125
  25. package/assets/toolkit/toolkit/skills/code-review/references/code-reviewer.md +146 -146
  26. package/assets/toolkit/toolkit/skills/code-ship/SKILL.md +52 -52
  27. package/assets/toolkit/toolkit/skills/code-tdd/SKILL.md +378 -378
  28. package/assets/toolkit/toolkit/skills/code-tdd/references/testing-anti-patterns.md +299 -299
  29. package/assets/toolkit/toolkit/skills/code-verify/SKILL.md +144 -144
  30. package/assets/toolkit/toolkit/skills/code-worktree/SKILL.md +228 -228
  31. package/assets/toolkit/toolkit/templates/CODE_WORKFLOW_TEMPLATE.md +140 -140
  32. package/bin/sdtk-code.js +14 -14
  33. package/package.json +44 -44
  34. package/src/commands/build.js +53 -53
  35. package/src/commands/doctor.js +51 -51
  36. package/src/commands/generate.js +11 -11
  37. package/src/commands/guardrails.js +215 -123
  38. package/src/commands/help.js +244 -244
  39. package/src/commands/init.js +98 -98
  40. package/src/commands/plan.js +53 -53
  41. package/src/commands/readiness.js +77 -77
  42. package/src/commands/resume.js +61 -61
  43. package/src/commands/runtime.js +224 -224
  44. package/src/commands/ship.js +59 -59
  45. package/src/commands/sleep.js +132 -0
  46. package/src/commands/start.js +89 -89
  47. package/src/commands/status.js +77 -77
  48. package/src/commands/update.js +11 -11
  49. package/src/commands/verify.js +71 -71
  50. package/src/index.js +108 -104
  51. package/src/lib/args.js +107 -107
  52. package/src/lib/errors.js +41 -41
  53. package/src/lib/powershell.js +65 -65
  54. package/src/lib/project-target-guard.js +53 -53
  55. package/src/lib/scope.js +72 -72
  56. package/src/lib/ship-readiness.js +281 -281
  57. package/src/lib/sleep-plan.js +175 -0
  58. package/src/lib/sleep-report.js +229 -0
  59. package/src/lib/toolkit-payload.js +72 -72
  60. package/src/lib/trust-events.js +166 -166
  61. package/src/lib/trust-file-scope.js +154 -154
  62. package/src/lib/trust-policy.js +212 -212
  63. package/src/lib/trust-redact.js +35 -35
  64. package/src/lib/trust-trace.js +179 -179
  65. package/src/lib/update.js +344 -344
  66. package/src/lib/workflow-artifact.js +503 -503
  67. package/src/lib/workflow-build.js +127 -127
  68. package/src/lib/workflow-doctor.js +83 -83
  69. package/src/lib/workflow-handoff.js +1029 -1029
  70. package/src/lib/workflow-intake.js +101 -101
  71. package/src/lib/workflow-plan.js +193 -193
  72. package/src/lib/workflow-review-packet.js +650 -650
  73. package/src/lib/workflow-ship.js +213 -213
  74. package/src/lib/workflow-state.js +438 -438
  75. package/src/lib/workflow-verify.js +393 -393
@@ -1,146 +1,146 @@
1
- # Code Review Agent
2
-
3
- You are reviewing code changes for production readiness.
4
-
5
- **Your task:**
6
- 1. Review {WHAT_WAS_IMPLEMENTED}
7
- 2. Compare against {PLAN_OR_REQUIREMENTS}
8
- 3. Check code quality, architecture, testing
9
- 4. Categorize issues by severity
10
- 5. Assess production readiness
11
-
12
- ## What Was Implemented
13
-
14
- {DESCRIPTION}
15
-
16
- ## Requirements/Plan
17
-
18
- {PLAN_REFERENCE}
19
-
20
- ## Git Range to Review
21
-
22
- **Base:** {BASE_SHA}
23
- **Head:** {HEAD_SHA}
24
-
25
- ```bash
26
- git diff --stat {BASE_SHA}..{HEAD_SHA}
27
- git diff {BASE_SHA}..{HEAD_SHA}
28
- ```
29
-
30
- ## Review Checklist
31
-
32
- **Code Quality:**
33
- - Clean separation of concerns?
34
- - Proper error handling?
35
- - Type safety (if applicable)?
36
- - DRY principle followed?
37
- - Edge cases handled?
38
-
39
- **Architecture:**
40
- - Sound design decisions?
41
- - Scalability considerations?
42
- - Performance implications?
43
- - Security concerns?
44
-
45
- **Testing:**
46
- - Tests actually test logic (not mocks)?
47
- - Edge cases covered?
48
- - Integration tests where needed?
49
- - All tests passing?
50
-
51
- **Requirements:**
52
- - All plan requirements met?
53
- - Implementation matches spec?
54
- - No scope creep?
55
- - Breaking changes documented?
56
-
57
- **Production Readiness:**
58
- - Migration strategy (if schema changes)?
59
- - Backward compatibility considered?
60
- - Documentation complete?
61
- - No obvious bugs?
62
-
63
- ## Output Format
64
-
65
- ### Strengths
66
- [What's well done? Be specific.]
67
-
68
- ### Issues
69
-
70
- #### Critical (Must Fix)
71
- [Bugs, security issues, data loss risks, broken functionality]
72
-
73
- #### Important (Should Fix)
74
- [Architecture problems, missing features, poor error handling, test gaps]
75
-
76
- #### Minor (Nice to Have)
77
- [Code style, optimization opportunities, documentation improvements]
78
-
79
- **For each issue:**
80
- - File:line reference
81
- - What's wrong
82
- - Why it matters
83
- - How to fix (if not obvious)
84
-
85
- ### Recommendations
86
- [Improvements for code quality, architecture, or process]
87
-
88
- ### Assessment
89
-
90
- **Ready to merge?** [Yes/No/With fixes]
91
-
92
- **Reasoning:** [Technical assessment in 1-2 sentences]
93
-
94
- ## Critical Rules
95
-
96
- **DO:**
97
- - Categorize by actual severity (not everything is Critical)
98
- - Be specific (file:line, not vague)
99
- - Explain WHY issues matter
100
- - Acknowledge strengths
101
- - Give clear verdict
102
-
103
- **DON'T:**
104
- - Say "looks good" without checking
105
- - Mark nitpicks as Critical
106
- - Give feedback on code you didn't review
107
- - Be vague ("improve error handling")
108
- - Avoid giving a clear verdict
109
-
110
- ## Example Output
111
-
112
- ```
113
- ### Strengths
114
- - Clean database schema with proper migrations (db.ts:15-42)
115
- - Comprehensive test coverage (18 tests, all edge cases)
116
- - Good error handling with fallbacks (summarizer.ts:85-92)
117
-
118
- ### Issues
119
-
120
- #### Important
121
- 1. **Missing help text in CLI wrapper**
122
- - File: index-conversations:1-31
123
- - Issue: No --help flag, users won't discover --concurrency
124
- - Fix: Add --help case with usage examples
125
-
126
- 2. **Date validation missing**
127
- - File: search.ts:25-27
128
- - Issue: Invalid dates silently return no results
129
- - Fix: Validate ISO format, throw error with example
130
-
131
- #### Minor
132
- 1. **Progress indicators**
133
- - File: indexer.ts:130
134
- - Issue: No "X of Y" counter for long operations
135
- - Impact: Users don't know how long to wait
136
-
137
- ### Recommendations
138
- - Add progress reporting for user experience
139
- - Consider config file for excluded projects (portability)
140
-
141
- ### Assessment
142
-
143
- **Ready to merge: With fixes**
144
-
145
- **Reasoning:** Core implementation is solid with good architecture and tests. Important issues (help text, date validation) are easily fixed and don't affect core functionality.
146
- ```
1
+ # Code Review Agent
2
+
3
+ You are reviewing code changes for production readiness.
4
+
5
+ **Your task:**
6
+ 1. Review {WHAT_WAS_IMPLEMENTED}
7
+ 2. Compare against {PLAN_OR_REQUIREMENTS}
8
+ 3. Check code quality, architecture, testing
9
+ 4. Categorize issues by severity
10
+ 5. Assess production readiness
11
+
12
+ ## What Was Implemented
13
+
14
+ {DESCRIPTION}
15
+
16
+ ## Requirements/Plan
17
+
18
+ {PLAN_REFERENCE}
19
+
20
+ ## Git Range to Review
21
+
22
+ **Base:** {BASE_SHA}
23
+ **Head:** {HEAD_SHA}
24
+
25
+ ```bash
26
+ git diff --stat {BASE_SHA}..{HEAD_SHA}
27
+ git diff {BASE_SHA}..{HEAD_SHA}
28
+ ```
29
+
30
+ ## Review Checklist
31
+
32
+ **Code Quality:**
33
+ - Clean separation of concerns?
34
+ - Proper error handling?
35
+ - Type safety (if applicable)?
36
+ - DRY principle followed?
37
+ - Edge cases handled?
38
+
39
+ **Architecture:**
40
+ - Sound design decisions?
41
+ - Scalability considerations?
42
+ - Performance implications?
43
+ - Security concerns?
44
+
45
+ **Testing:**
46
+ - Tests actually test logic (not mocks)?
47
+ - Edge cases covered?
48
+ - Integration tests where needed?
49
+ - All tests passing?
50
+
51
+ **Requirements:**
52
+ - All plan requirements met?
53
+ - Implementation matches spec?
54
+ - No scope creep?
55
+ - Breaking changes documented?
56
+
57
+ **Production Readiness:**
58
+ - Migration strategy (if schema changes)?
59
+ - Backward compatibility considered?
60
+ - Documentation complete?
61
+ - No obvious bugs?
62
+
63
+ ## Output Format
64
+
65
+ ### Strengths
66
+ [What's well done? Be specific.]
67
+
68
+ ### Issues
69
+
70
+ #### Critical (Must Fix)
71
+ [Bugs, security issues, data loss risks, broken functionality]
72
+
73
+ #### Important (Should Fix)
74
+ [Architecture problems, missing features, poor error handling, test gaps]
75
+
76
+ #### Minor (Nice to Have)
77
+ [Code style, optimization opportunities, documentation improvements]
78
+
79
+ **For each issue:**
80
+ - File:line reference
81
+ - What's wrong
82
+ - Why it matters
83
+ - How to fix (if not obvious)
84
+
85
+ ### Recommendations
86
+ [Improvements for code quality, architecture, or process]
87
+
88
+ ### Assessment
89
+
90
+ **Ready to merge?** [Yes/No/With fixes]
91
+
92
+ **Reasoning:** [Technical assessment in 1-2 sentences]
93
+
94
+ ## Critical Rules
95
+
96
+ **DO:**
97
+ - Categorize by actual severity (not everything is Critical)
98
+ - Be specific (file:line, not vague)
99
+ - Explain WHY issues matter
100
+ - Acknowledge strengths
101
+ - Give clear verdict
102
+
103
+ **DON'T:**
104
+ - Say "looks good" without checking
105
+ - Mark nitpicks as Critical
106
+ - Give feedback on code you didn't review
107
+ - Be vague ("improve error handling")
108
+ - Avoid giving a clear verdict
109
+
110
+ ## Example Output
111
+
112
+ ```
113
+ ### Strengths
114
+ - Clean database schema with proper migrations (db.ts:15-42)
115
+ - Comprehensive test coverage (18 tests, all edge cases)
116
+ - Good error handling with fallbacks (summarizer.ts:85-92)
117
+
118
+ ### Issues
119
+
120
+ #### Important
121
+ 1. **Missing help text in CLI wrapper**
122
+ - File: index-conversations:1-31
123
+ - Issue: No --help flag, users won't discover --concurrency
124
+ - Fix: Add --help case with usage examples
125
+
126
+ 2. **Date validation missing**
127
+ - File: search.ts:25-27
128
+ - Issue: Invalid dates silently return no results
129
+ - Fix: Validate ISO format, throw error with example
130
+
131
+ #### Minor
132
+ 1. **Progress indicators**
133
+ - File: indexer.ts:130
134
+ - Issue: No "X of Y" counter for long operations
135
+ - Impact: Users don't know how long to wait
136
+
137
+ ### Recommendations
138
+ - Add progress reporting for user experience
139
+ - Consider config file for excluded projects (portability)
140
+
141
+ ### Assessment
142
+
143
+ **Ready to merge: With fixes**
144
+
145
+ **Reasoning:** Core implementation is solid with good architecture and tests. Important issues (help text, date validation) are easily fixed and don't affect core functionality.
146
+ ```
@@ -1,52 +1,52 @@
1
- ---
2
- name: code-ship
3
- description: Ship and release. Use when implementation is complete, tests pass, and you need to prepare for merge or release -- pre-flight checks, version bump, CHANGELOG, bisectable commits.
4
- ---
5
-
6
- # Code Ship
7
-
8
- ## Critical Constraints
9
- - I do not start ship preparation until `code-verify` evidence and `code-review` outcomes are current.
10
- - I do not hide failing tests, unresolved review findings, or release risks behind a version bump.
11
-
12
- ## Overview
13
- Prepare completed implementation work for merge or release with a disciplined pre-flight process.
14
-
15
- ## Process
16
- 1. Confirm the branch is not `main` or another protected integration branch.
17
- 2. Review branch scope:
18
- - current diff summary
19
- - commits on the branch
20
- - uncommitted changes that must be included or split off
21
- 3. Merge or rebase from the mainline according to project policy.
22
- 4. Run the full verification set that proves ship readiness.
23
- 5. Run `code-review` if pre-landing review is stale.
24
- 6. Decide version bump level using the project release policy.
25
- 7. Update `VERSION` and `CHANGELOG.md` coherently.
26
- 8. Split changes into bisectable commits when the diff contains more than one logical unit.
27
- 9. Push the branch and open a PR when the project workflow requires one.
28
- 10. Report:
29
- - what is being shipped
30
- - verification results
31
- - version change
32
- - remaining operator notes
33
-
34
- ## Pre-Flight Checklist
35
- - Latest mainline merged or confirmed unnecessary
36
- - Verification evidence is fresh
37
- - Required review gate completed
38
- - Release notes drafted
39
- - Version bump consistent with scope
40
- - Commits are bisectable
41
- - No hidden migration, config, or rollout risk
42
-
43
- ## Red Flags
44
- - Shipping from a dirty or stale branch without understanding the diff.
45
- - Updating the version or changelog before tests and review pass.
46
- - Bundling unrelated work into one release commit.
47
- - Treating a push as proof that the code is ready.
48
-
49
- ## Integration
50
- - Run `code-verify` before this skill.
51
- - Run `code-review` before this skill when the code changed after the last review.
52
- - Finish with `code-finish` if the workflow requires a final branch integration decision.
1
+ ---
2
+ name: code-ship
3
+ description: Ship and release. Use when implementation is complete, tests pass, and you need to prepare for merge or release -- pre-flight checks, version bump, CHANGELOG, bisectable commits.
4
+ ---
5
+
6
+ # Code Ship
7
+
8
+ ## Critical Constraints
9
+ - I do not start ship preparation until `code-verify` evidence and `code-review` outcomes are current.
10
+ - I do not hide failing tests, unresolved review findings, or release risks behind a version bump.
11
+
12
+ ## Overview
13
+ Prepare completed implementation work for merge or release with a disciplined pre-flight process.
14
+
15
+ ## Process
16
+ 1. Confirm the branch is not `main` or another protected integration branch.
17
+ 2. Review branch scope:
18
+ - current diff summary
19
+ - commits on the branch
20
+ - uncommitted changes that must be included or split off
21
+ 3. Merge or rebase from the mainline according to project policy.
22
+ 4. Run the full verification set that proves ship readiness.
23
+ 5. Run `code-review` if pre-landing review is stale.
24
+ 6. Decide version bump level using the project release policy.
25
+ 7. Update `VERSION` and `CHANGELOG.md` coherently.
26
+ 8. Split changes into bisectable commits when the diff contains more than one logical unit.
27
+ 9. Push the branch and open a PR when the project workflow requires one.
28
+ 10. Report:
29
+ - what is being shipped
30
+ - verification results
31
+ - version change
32
+ - remaining operator notes
33
+
34
+ ## Pre-Flight Checklist
35
+ - Latest mainline merged or confirmed unnecessary
36
+ - Verification evidence is fresh
37
+ - Required review gate completed
38
+ - Release notes drafted
39
+ - Version bump consistent with scope
40
+ - Commits are bisectable
41
+ - No hidden migration, config, or rollout risk
42
+
43
+ ## Red Flags
44
+ - Shipping from a dirty or stale branch without understanding the diff.
45
+ - Updating the version or changelog before tests and review pass.
46
+ - Bundling unrelated work into one release commit.
47
+ - Treating a push as proof that the code is ready.
48
+
49
+ ## Integration
50
+ - Run `code-verify` before this skill.
51
+ - Run `code-review` before this skill when the code changed after the last review.
52
+ - Finish with `code-finish` if the workflow requires a final branch integration decision.