thachvd-kit 1.0.19 → 1.0.20
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/.agent/docs/architecture.md +3 -2
- package/.agent/docs/conventions.md +1 -1
- package/.agent/docs/tooling.md +5 -8
- package/.agent/skills/project-onboarding/SKILL.md +1 -1
- package/.agent/skills/using-git-worktrees/SKILL.md +2 -3
- package/.agent/skills/writing-skills/SKILL.md +170 -110
- package/.agent/workflows/review.md +125 -0
- package/.agent/workflows/spec.md +140 -0
- package/README.md +45 -44
- package/bin/cli.js +323 -311
- package/kit/README.md +2 -1
- package/package.json +1 -1
- package/skills/code-review-checklist/SKILL.md +142 -109
- package/skills/project-onboarding/SKILL.md +1 -1
- package/skills/tdd-workflow/SKILL.md +25 -1
- package/skills/using-git-worktrees/SKILL.md +2 -3
- package/skills/verification-before-completion/SKILL.md +24 -10
- package/skills/writing-skills/SKILL.md +170 -110
|
@@ -1,110 +1,170 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: writing-skills
|
|
3
|
-
description: Use when creating a new skill or improving an existing one — follows best practices for SKILL.md structure, Claude Search Optimization, token efficiency, and skill testing methodology
|
|
4
|
-
allowed-tools: Read, Write, Edit
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# Writing Skills
|
|
8
|
-
|
|
9
|
-
## What is a Skill?
|
|
10
|
-
|
|
11
|
-
A skill is a reusable instruction set that activates when
|
|
12
|
-
|
|
13
|
-
## Skill Types
|
|
14
|
-
|
|
15
|
-
| Type | Purpose | Example |
|
|
16
|
-
|
|
17
|
-
| **Technique** | How-to guide | `tdd-workflow` |
|
|
18
|
-
| **Pattern** | Mental model | `clean-code` |
|
|
19
|
-
| **Reference** | Documentation | `api-patterns` |
|
|
20
|
-
| **Discipline** | Rules/enforcement | `verification-before-completion` |
|
|
21
|
-
|
|
22
|
-
## Directory Structure
|
|
23
|
-
|
|
24
|
-
```
|
|
25
|
-
skill-name/
|
|
26
|
-
├── SKILL.md # Required: metadata + instructions
|
|
27
|
-
├── scripts/ # Optional: runnable scripts
|
|
28
|
-
└── references/ # Optional: templates, docs
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
## SKILL.md Structure
|
|
32
|
-
|
|
33
|
-
```markdown
|
|
34
|
-
---
|
|
35
|
-
name: skill-name
|
|
36
|
-
description: [Trigger description — when to use this skill]
|
|
37
|
-
allowed-tools: [Bash, Read, Edit, Write, ...]
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
# Skill Title
|
|
41
|
-
|
|
42
|
-
## Overview
|
|
43
|
-
Brief summary + core principle
|
|
44
|
-
|
|
45
|
-
##
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
1
|
+
---
|
|
2
|
+
name: writing-skills
|
|
3
|
+
description: Use when creating a new skill or improving an existing one — follows best practices for SKILL.md structure, Claude Search Optimization, token efficiency, anti-rationalization tables, and skill testing methodology
|
|
4
|
+
allowed-tools: Read, Write, Edit
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Writing Skills
|
|
8
|
+
|
|
9
|
+
## What is a Skill?
|
|
10
|
+
|
|
11
|
+
A skill is a reusable instruction set that activates when an AI detects a relevant context. It lives in a folder with a `SKILL.md` file and works across Codex, Antigravity, Claude, and Cursor.
|
|
12
|
+
|
|
13
|
+
## Skill Types
|
|
14
|
+
|
|
15
|
+
| Type | Purpose | Example | Anti-Rationalization Required? |
|
|
16
|
+
|------|---------|---------|----|
|
|
17
|
+
| **Technique** | How-to guide | `tdd-workflow` | Optional |
|
|
18
|
+
| **Pattern** | Mental model | `clean-code` | Optional |
|
|
19
|
+
| **Reference** | Documentation | `api-patterns` | No |
|
|
20
|
+
| **Discipline** | Rules/enforcement | `verification-before-completion` | **Mandatory** |
|
|
21
|
+
|
|
22
|
+
## Directory Structure
|
|
23
|
+
|
|
24
|
+
```
|
|
25
|
+
skill-name/
|
|
26
|
+
├── SKILL.md # Required: metadata + instructions
|
|
27
|
+
├── scripts/ # Optional: runnable scripts
|
|
28
|
+
└── references/ # Optional: templates, docs
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## SKILL.md Structure
|
|
32
|
+
|
|
33
|
+
```markdown
|
|
34
|
+
---
|
|
35
|
+
name: skill-name
|
|
36
|
+
description: [Trigger description — when to use this skill]
|
|
37
|
+
allowed-tools: [Bash, Read, Edit, Write, ...]
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
# Skill Title
|
|
41
|
+
|
|
42
|
+
## Overview
|
|
43
|
+
Brief summary + core principle
|
|
44
|
+
|
|
45
|
+
## When to Use
|
|
46
|
+
- Specific trigger scenarios
|
|
47
|
+
|
|
48
|
+
## [Main Content]
|
|
49
|
+
...
|
|
50
|
+
|
|
51
|
+
## Anti-Rationalization ← REQUIRED for Discipline/Technique skills
|
|
52
|
+
| Excuse | Correct Response |
|
|
53
|
+
|--------|-----------------|
|
|
54
|
+
| "Just this once" | No exceptions. Apply the rule. |
|
|
55
|
+
|
|
56
|
+
## Exit Criteria ← REQUIRED for Technique/Discipline skills
|
|
57
|
+
- [ ] Specific, verifiable condition 1
|
|
58
|
+
- [ ] Specific, verifiable condition 2
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Claude Search Optimization (CSO)
|
|
62
|
+
|
|
63
|
+
The `description` field is how the AI decides whether to load your skill. Make it trigger correctly:
|
|
64
|
+
|
|
65
|
+
### 1. Rich Description
|
|
66
|
+
|
|
67
|
+
```yaml
|
|
68
|
+
# ❌ Vague
|
|
69
|
+
description: For code review
|
|
70
|
+
|
|
71
|
+
# ✅ Specific with triggers
|
|
72
|
+
description: Use when completing tasks, implementing major features, or before merging — pre-review checklist, evidence-before-claims workflow
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
### 2. Keyword Coverage
|
|
76
|
+
|
|
77
|
+
Include synonyms, trigger phrases, and common user requests in description.
|
|
78
|
+
|
|
79
|
+
### 3. Token Efficiency (Critical)
|
|
80
|
+
|
|
81
|
+
- Use tables instead of prose for comparisons
|
|
82
|
+
- Use code blocks for commands
|
|
83
|
+
- Use flowcharts/diagrams for processes
|
|
84
|
+
- Avoid narrative explanations — use structured data
|
|
85
|
+
|
|
86
|
+
### 4. Cross-Referencing
|
|
87
|
+
|
|
88
|
+
Use `Pairs with:` and `Integration:` sections to link related skills.
|
|
89
|
+
|
|
90
|
+
## Anti-Rationalization Tables (Key Concept)
|
|
91
|
+
|
|
92
|
+
The most powerful feature of a discipline skill. A table that blocks the AI's most common excuses for skipping a rule.
|
|
93
|
+
|
|
94
|
+
### Why They Matter
|
|
95
|
+
|
|
96
|
+
AI agents (like humans) tend to rationalize shortcuts under pressure. An Anti-Rationalization table names each excuse explicitly and provides the correct response, making it impossible to skip without consciously overriding the rule.
|
|
97
|
+
|
|
98
|
+
### Format
|
|
99
|
+
|
|
100
|
+
```markdown
|
|
101
|
+
## Anti-Rationalization
|
|
102
|
+
|
|
103
|
+
| Excuse | Reality / Correct Response |
|
|
104
|
+
|--------|---------------------------|
|
|
105
|
+
| "It's a small change" | Size doesn't reduce the need. Apply the rule. |
|
|
106
|
+
| "I'm confident it works" | Confidence ≠ evidence. Run verification. |
|
|
107
|
+
| "Just this once" | No exceptions — "just this once" is how standards die. |
|
|
108
|
+
| "The last run passed" | Stale results. Run fresh verification now. |
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### What Makes a Good Entry
|
|
112
|
+
|
|
113
|
+
- **Excuse column**: Real phrases AI uses to justify skipping. Be specific.
|
|
114
|
+
- **Reality column**: The direct counter. Short, imperative, no hedging.
|
|
115
|
+
- Cover at least 4–6 common excuses for discipline skills.
|
|
116
|
+
|
|
117
|
+
## Exit Criteria
|
|
118
|
+
|
|
119
|
+
Every Technique or Discipline skill must end with a verifiable checklist the AI can check off before declaring the task done.
|
|
120
|
+
|
|
121
|
+
```markdown
|
|
122
|
+
## Exit Criteria
|
|
123
|
+
|
|
124
|
+
Before claiming this task is complete:
|
|
125
|
+
- [ ] [Verifiable condition 1]
|
|
126
|
+
- [ ] [Verifiable condition 2]
|
|
127
|
+
- [ ] [Verifiable condition 3]
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
**Rules for Exit Criteria:**
|
|
131
|
+
- Each item must be binary (done or not done) — no vague "looks good" items
|
|
132
|
+
- Must be something that can be checked programmatically or by inspection
|
|
133
|
+
- Failing any item = task is NOT complete
|
|
134
|
+
|
|
135
|
+
## Anti-Patterns to Avoid
|
|
136
|
+
|
|
137
|
+
| ❌ Anti-Pattern | ✅ Fix |
|
|
138
|
+
|----------------|-------|
|
|
139
|
+
| Narrative prose everywhere | Tables, bullet lists, code blocks |
|
|
140
|
+
| Discipline skill with no Anti-Rationalization | Add the table — it's mandatory |
|
|
141
|
+
| Technique skill with no Exit Criteria | Add verifiable checklist |
|
|
142
|
+
| Vague description | Specific triggers and use cases |
|
|
143
|
+
| Generic labels ("Step 1", "Step 2") | Descriptive labels ("Verify baseline", "Run tests") |
|
|
144
|
+
| Code examples in flowchart labels | Flowcharts for flow, code blocks for code |
|
|
145
|
+
|
|
146
|
+
## Skill Creation Checklist
|
|
147
|
+
|
|
148
|
+
- [ ] Description field triggers correctly (test: "would AI load this for X?")
|
|
149
|
+
- [ ] Core principle stated in Overview
|
|
150
|
+
- [ ] Content uses tables/code blocks, not prose paragraphs
|
|
151
|
+
- [ ] Token-efficient (no redundant explanations)
|
|
152
|
+
- [ ] **Anti-Rationalization section included** (Discipline/Technique skills — mandatory)
|
|
153
|
+
- [ ] **Exit Criteria section included** (Discipline/Technique skills — mandatory)
|
|
154
|
+
- [ ] Integration section lists related skills
|
|
155
|
+
- [ ] Tested: create a scenario where this skill should fire, verify it does
|
|
156
|
+
|
|
157
|
+
## Testing Skills
|
|
158
|
+
|
|
159
|
+
For **discipline skills** (rules): Create scenario where rule should fire, verify AI follows it AND rejects the rationalizations in the Anti-Rationalization table.
|
|
160
|
+
For **technique skills** (how-to): Apply skill to a real task, verify output quality and that Exit Criteria are met.
|
|
161
|
+
For **reference skills** (docs): Query for specific info, verify correct answer.
|
|
162
|
+
|
|
163
|
+
## The Bottom Line
|
|
164
|
+
|
|
165
|
+
A skill is good when:
|
|
166
|
+
1. It fires when it should (good description/CSO)
|
|
167
|
+
2. It improves output quality noticeably
|
|
168
|
+
3. It's token-efficient (doesn't waste context)
|
|
169
|
+
4. It has no ambiguous loopholes (Anti-Rationalization table closes them)
|
|
170
|
+
5. It's verifiable (Exit Criteria defines "done")
|