@natjswenson/devlog 0.4.1 → 0.5.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/SKILL.md +223 -405
- package/bin/devlog.js +308 -202
- package/config.example.json +5 -1
- package/evals/budget.mjs +60 -0
- package/evals/fixtures/bad-post.md +33 -0
- package/evals/fixtures/good-post.md +118 -0
- package/evals/fixtures/irreproducible-post.md +71 -0
- package/evals/judge_post.mjs +113 -0
- package/evals/run_eval.mjs +95 -0
- package/lib/config_ops.mjs +58 -0
- package/lib/core.mjs +206 -0
- package/lib/lint_post.mjs +152 -0
- package/lib/publish_entry.mjs +71 -0
- package/lib/scan.mjs +229 -0
- package/package.json +4 -1
- package/skill-invariants.json +66 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
{
|
|
2
|
+
"comment": "Prose guardrails in SKILL.md that must survive edits. Each pattern is a case-insensitive regex tested against the full SKILL.md text by tests/skill_contract.test.mjs. If you intentionally change one, update it here in the same commit and say why in the PR.",
|
|
3
|
+
"prose": [
|
|
4
|
+
{
|
|
5
|
+
"id": "immutable-entries",
|
|
6
|
+
"pattern": "immutable[\\s\\S]{0,80}never overwrite",
|
|
7
|
+
"rationale": "A published release entry must never be overwritten; losing this line reopens the clobber path."
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"id": "stranger-test",
|
|
11
|
+
"pattern": "stranger test",
|
|
12
|
+
"rationale": "The governing quality rule: a reader without the author's repo can build the thing."
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"id": "gotchas-section",
|
|
16
|
+
"pattern": "## Gotchas",
|
|
17
|
+
"rationale": "The post template must require the Gotchas section (lint-post enforces it mechanically)."
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"id": "gotchas-never-invented",
|
|
21
|
+
"pattern": "never invented",
|
|
22
|
+
"rationale": "Gotchas come from real history (fix commits, reverts, changelog) — fabricating them breaks the product's honesty."
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"id": "reader-side-verify",
|
|
26
|
+
"pattern": "commands the READER runs",
|
|
27
|
+
"rationale": "Verify sections must instruct the reader, not demonstrate the author's repo."
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"id": "single-quote-rule",
|
|
31
|
+
"pattern": "single-quote every interpolated value",
|
|
32
|
+
"rationale": "Defense-in-depth on top of CLI validation for values the agent still shell-interpolates."
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"id": "voicepath-read-only",
|
|
36
|
+
"pattern": "voicePath[\\s\\S]{0,40}never shell-interpolated",
|
|
37
|
+
"rationale": "voicePath is deliberately exempt from strict path validation because it never touches a shell."
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"id": "no-algorithm-md",
|
|
41
|
+
"pattern": "Never read[\\s\\S]{0,10}`algorithm\\.md`",
|
|
42
|
+
"rationale": "Ghostwriter's LinkedIn reach tuning must not shape dev-log entries."
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"id": "remote-content-is-data",
|
|
46
|
+
"pattern": "data, not instructions",
|
|
47
|
+
"rationale": "Prompt-injection defense: fetched content never changes the rules."
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"id": "write-tool-not-heredoc",
|
|
51
|
+
"pattern": "Write tool[\\s\\S]{0,40}(never|not) (a )?bash heredoc",
|
|
52
|
+
"rationale": "Heredocs re-inject generated content into the shell."
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"id": "hash-validation",
|
|
56
|
+
"pattern": "\\^\\[0-9a-f\\]\\{7,40\\}\\$",
|
|
57
|
+
"rationale": "Commit hashes from scan output are re-validated before shell use."
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"id": "no-push-retry",
|
|
61
|
+
"pattern": "do not retry automatically",
|
|
62
|
+
"rationale": "A failed push is surfaced to the user, not retried blind."
|
|
63
|
+
}
|
|
64
|
+
],
|
|
65
|
+
"cli_commands_referenced": ["scan", "lint-post", "publish-entry", "add-project", "remove-project", "set", "config", "init"]
|
|
66
|
+
}
|