sdtk-code-kit 0.2.0 → 0.3.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/README.md +3 -3
- package/assets/manifest/toolkit-bundle.manifest.json +57 -57
- package/assets/manifest/toolkit-bundle.sha256.txt +28 -28
- package/assets/toolkit/toolkit/AGENTS.md +219 -219
- package/assets/toolkit/toolkit/install.ps1 +156 -156
- package/assets/toolkit/toolkit/scripts/install-claude-skills.ps1 +78 -78
- package/assets/toolkit/toolkit/scripts/install-codex-skills.ps1 +150 -150
- package/assets/toolkit/toolkit/scripts/uninstall-claude-skills.ps1 +62 -62
- package/assets/toolkit/toolkit/scripts/uninstall-codex-skills.ps1 +82 -82
- package/assets/toolkit/toolkit/sdtk-spec.config.json +6 -6
- package/assets/toolkit/toolkit/sdtk-spec.config.profiles.example.json +12 -12
- package/assets/toolkit/toolkit/skills/code-brainstorm/SKILL.md +55 -55
- package/assets/toolkit/toolkit/skills/code-debug/SKILL.md +296 -296
- package/assets/toolkit/toolkit/skills/code-debug/references/root-cause-tracing.md +68 -68
- package/assets/toolkit/toolkit/skills/code-discover/SKILL.md +54 -54
- package/assets/toolkit/toolkit/skills/code-execute/SKILL.md +74 -74
- package/assets/toolkit/toolkit/skills/code-finish/SKILL.md +205 -205
- package/assets/toolkit/toolkit/skills/code-parallel/SKILL.md +64 -64
- package/assets/toolkit/toolkit/skills/code-parallel/references/code-quality-reviewer-prompt.md +26 -26
- package/assets/toolkit/toolkit/skills/code-parallel/references/implementer-prompt.md +113 -113
- package/assets/toolkit/toolkit/skills/code-parallel/references/spec-reviewer-prompt.md +61 -61
- package/assets/toolkit/toolkit/skills/code-plan/SKILL.md +85 -85
- package/assets/toolkit/toolkit/skills/code-review/SKILL.md +79 -79
- package/assets/toolkit/toolkit/skills/code-review/references/checklist.md +125 -125
- package/assets/toolkit/toolkit/skills/code-review/references/code-reviewer.md +146 -146
- package/assets/toolkit/toolkit/skills/code-ship/SKILL.md +52 -52
- package/assets/toolkit/toolkit/skills/code-tdd/SKILL.md +378 -378
- package/assets/toolkit/toolkit/skills/code-tdd/references/testing-anti-patterns.md +299 -299
- package/assets/toolkit/toolkit/skills/code-verify/SKILL.md +144 -144
- package/assets/toolkit/toolkit/skills/code-worktree/SKILL.md +228 -228
- package/assets/toolkit/toolkit/templates/CODE_WORKFLOW_TEMPLATE.md +140 -140
- package/package.json +2 -2
- package/src/commands/agent-team.js +174 -0
- package/src/commands/guardrails.js +94 -2
- package/src/commands/help.js +13 -0
- package/src/commands/sleep.js +132 -0
- package/src/index.js +8 -0
- package/src/lib/agent-team-export.js +409 -0
- package/src/lib/agent-team-plan.js +514 -0
- package/src/lib/sleep-plan.js +175 -0
- package/src/lib/sleep-report.js +229 -0
- package/src/lib/trust-events.js +20 -1
|
@@ -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.
|