@yogiadhik/skillcheck 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.
- package/README.md +6 -5
- package/dist/lint/rules.js +7 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -94,11 +94,12 @@ because the point is the pattern, and the pattern repeats:
|
|
|
94
94
|
official and community both. Quality is achievable; it's just not
|
|
95
95
|
the default.
|
|
96
96
|
|
|
97
|
-
Two honest footnotes. First:
|
|
98
|
-
turned out to be this linter's own false positives — links
|
|
99
|
-
example code blocks,
|
|
100
|
-
runtime
|
|
101
|
-
|
|
97
|
+
Two honest footnotes. First: three times now, the loudest "errors" in
|
|
98
|
+
an audit turned out to be this linter's own false positives — links
|
|
99
|
+
inside example code blocks, templated {baseDir} targets that resolve
|
|
100
|
+
at runtime, and placeholder links in quoted prose like
|
|
101
|
+
"[Team roster](its link)". All fixed (0.1.1, 0.1.3, 0.2.1), all caught
|
|
102
|
+
by checking findings against the accused code before believing them. Do the same with
|
|
102
103
|
anything this tool tells you. Second: these audits are how skillcheck
|
|
103
104
|
gets tested — every rule here has drawn blood on real files or been
|
|
104
105
|
fixed for crying wolf.
|
package/dist/lint/rules.js
CHANGED
|
@@ -18,8 +18,10 @@ export const descriptionQuality = (s) => {
|
|
|
18
18
|
const out = [];
|
|
19
19
|
if (d.length < 20)
|
|
20
20
|
out.push(finding(s, 'description-quality', 'warning', 'description under 20 chars; unlikely to trigger reliably'));
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
// claude code truncates description + when_to_use at 1536 chars combined
|
|
22
|
+
const whenToUse = typeof s.frontmatter.when_to_use === 'string' ? s.frontmatter.when_to_use : '';
|
|
23
|
+
if (d.length + whenToUse.length > 1536)
|
|
24
|
+
out.push(finding(s, 'description-quality', 'warning', 'description over 1536 chars (counting when_to_use); gets truncated in listings'));
|
|
23
25
|
if (!/\b(use|when|for|trigger)\b/i.test(d))
|
|
24
26
|
out.push(finding(s, 'description-quality', 'warning', 'description has no trigger language ("use when ...") — the agent decides from this text alone'));
|
|
25
27
|
return out;
|
|
@@ -53,6 +55,9 @@ export const relativeLinks = (s) => {
|
|
|
53
55
|
// templated targets like {baseDir}/x.md resolve at runtime; can't judge them
|
|
54
56
|
if (target.includes('{'))
|
|
55
57
|
continue;
|
|
58
|
+
// a destination with a raw space never parses as a markdown link; it's placeholder prose
|
|
59
|
+
if (/\s/.test(target))
|
|
60
|
+
continue;
|
|
56
61
|
if (!existsSync(resolve(s.dir, target.split('#')[0])))
|
|
57
62
|
out.push(finding(s, 'relative-links', 'error', `broken relative link: ${target}`));
|
|
58
63
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yogiadhik/skillcheck",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "lint and behavioral tests for agent skills",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Yogesh Adhikari",
|
|
@@ -29,6 +29,6 @@
|
|
|
29
29
|
"@types/cross-spawn": "^6.0.6",
|
|
30
30
|
"@types/node": "^26.1.1",
|
|
31
31
|
"typescript": "^7.0.2",
|
|
32
|
-
"vitest": "^
|
|
32
|
+
"vitest": "^5.0.2"
|
|
33
33
|
}
|
|
34
34
|
}
|