@antoneeo/kb-agentic-skill 1.0.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/CHANGELOG.md +332 -0
- package/README.md +85 -0
- package/gemini-extension.json +6 -0
- package/package.json +50 -0
- package/scripts/init.js +216 -0
- package/scripts/lib.js +152 -0
- package/scripts/postinstall.js +42 -0
- package/scripts/preuninstall.js +17 -0
- package/skills/kb-agentic-skill/ENFORCEMENT.md +123 -0
- package/skills/kb-agentic-skill/SKILL.md +134 -0
- package/skills/kb-agentic-skill/dispatch.md +87 -0
- package/skills/kb-agentic-skill/distillation.md +79 -0
- package/skills/kb-agentic-skill/elicitation.md +131 -0
- package/skills/kb-agentic-skill/guides.md +287 -0
- package/skills/kb-agentic-skill/reconciliation.md +79 -0
- package/skills/kb-agentic-skill/review.md +168 -0
- package/skills/kb-agentic-skill/routing.md +100 -0
- package/skills/kb-agentic-skill/scripts/sdlc_check.py +846 -0
- package/skills/kb-agentic-skill/scripts/sdlc_core.py +1996 -0
- package/skills/kb-agentic-skill/taxonomy.md +80 -0
- package/skills/kb-agentic-skill/templates.md +579 -0
- package/skills/kb-agentic-skill/vision.md +245 -0
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
# Writing a Vision that a cold reviewer can actually apply
|
|
2
|
+
|
|
3
|
+
Support file for `ai_docs/vision/project_vision.md`, `vision/features/VISION_*.md`
|
|
4
|
+
and (Hybrid) the devPNT M-VISION. Read it when writing or amending any of them.
|
|
5
|
+
The template lives in `templates.md`; this file is the *why it works*.
|
|
6
|
+
|
|
7
|
+
**The problem this solves.** A Vision's job is to be read cold — by a later
|
|
8
|
+
session, by a reviewer, by another agent — and to produce a ruling on a proposed
|
|
9
|
+
change. Most Visions cannot do that: they read as intent to whoever wrote them and
|
|
10
|
+
as ambiguity to everyone else, and the gap is invisible until something wrong gets
|
|
11
|
+
through. Writing one and then discovering the holes by adversarial rounds works,
|
|
12
|
+
but it costs several rewrites. The checklist below exists so a Vision is
|
|
13
|
+
verifiable on the **first** draft.
|
|
14
|
+
|
|
15
|
+
Everything here was derived empirically: six blind adversarial rounds against one
|
|
16
|
+
real Vision, reviewers with no repository access, ~25 attack proposals. Rules that
|
|
17
|
+
survived every attack and rules that fell were compared for structure. What
|
|
18
|
+
follows is that difference.
|
|
19
|
+
|
|
20
|
+
## What a Vision IS
|
|
21
|
+
|
|
22
|
+
A Vision states **what is to be obtained — the benefit — while leaving the most
|
|
23
|
+
degrees of freedom possible. It binds nothing that does not obstruct that
|
|
24
|
+
benefit.**
|
|
25
|
+
|
|
26
|
+
Four consequences, each operational:
|
|
27
|
+
|
|
28
|
+
- **State the benefit, not the mechanism.** What the actor *obtains*, never how —
|
|
29
|
+
and concrete enough that an obstacle to it is *recognizable*. This is the test a
|
|
30
|
+
North Star must pass: from "best-in-class" no constraint is derivable and none
|
|
31
|
+
is refutable, because nothing recognizably obstructs it. From "everything the
|
|
32
|
+
methodology produces stays usable in full without paying", a metering ban
|
|
33
|
+
follows and can be checked.
|
|
34
|
+
- **The deletion test — the generative rule for every constraint.** Remove the
|
|
35
|
+
rule: is the benefit still reachable? If **yes**, delete the rule — it was
|
|
36
|
+
spending a degree of freedom on nothing. If **no**, keep it, and its sentence
|
|
37
|
+
must name the obstacle it removes. This is also the stop rule: when nothing on
|
|
38
|
+
the table would obstruct the benefit, the Vision needs no new rule.
|
|
39
|
+
- **Constraints accumulate as the work reveals obstacles.** The first draft is the
|
|
40
|
+
benefit plus the few constraints already known — usually almost none, and that
|
|
41
|
+
is correct (`DRAFT` informs, `APPROVED` binds). Each constraint added later
|
|
42
|
+
*sharpens* the Vision without shrinking it more than the obstacle requires.
|
|
43
|
+
- **A constraint never obstructs the Vision.** A proposed rule that conflicts with
|
|
44
|
+
the benefit is not a constraint to negotiate in place — it is a Vision
|
|
45
|
+
**amendment**, and amending is the owner's decision, never a side effect of a
|
|
46
|
+
downstream edit.
|
|
47
|
+
|
|
48
|
+
Extracting the benefit from a discussion is real work: a discourse arrives with
|
|
49
|
+
solutions, preferences and constraints tangled together, and the Vision is the
|
|
50
|
+
distilled benefit only. The elicitation round (`elicitation.md`) asks for it first
|
|
51
|
+
— and a mechanism ("a dashboard") is not an acceptable answer to a benefit
|
|
52
|
+
question ("never lose the thread"); ask again until the answer names what the
|
|
53
|
+
actor obtains.
|
|
54
|
+
|
|
55
|
+
The deletion test decides **which** rules exist. Everything below decides **how**
|
|
56
|
+
to write a rule so it holds once you know it must exist.
|
|
57
|
+
|
|
58
|
+
## 0. The one-line test
|
|
59
|
+
|
|
60
|
+
> Could a reader who has never seen this project rule ACCEPT or REJECT on a
|
|
61
|
+
> proposed change, quoting one line of this document, without asking anyone
|
|
62
|
+
> anything?
|
|
63
|
+
|
|
64
|
+
If a section cannot contribute to that, it is background — keep it if it helps a
|
|
65
|
+
human, but know it carries no gate weight.
|
|
66
|
+
|
|
67
|
+
## 1. The nine properties of a rule that holds
|
|
68
|
+
|
|
69
|
+
Each is stated as a drafting action, with the attack it defeats.
|
|
70
|
+
|
|
71
|
+
1. **Key the rule to a property observable in the artifact — never to intent,
|
|
72
|
+
commitment, plan or purpose.** Test while drafting: *could I verify compliance
|
|
73
|
+
by reading the diff, without asking the author what they meant?*
|
|
74
|
+
→ Defeats: the proposer simply promises the opposite. A rule that forbids
|
|
75
|
+
"committing to track someone's format" is satisfied by saying "we commit to
|
|
76
|
+
nothing"; a rule that forbids "code in this repo that parses a format we do
|
|
77
|
+
not define" is not.
|
|
78
|
+
2. **Write it as one yes/no question with BOTH branches answered.**
|
|
79
|
+
→ Defeats: a gate that can only reject. A prohibition-only Vision rejects the
|
|
80
|
+
work it wants (new client support, packaging, bug fixes) and is abandoned.
|
|
81
|
+
3. **Phrase the question counterfactually about capability, not about the status
|
|
82
|
+
quo** — "could the user obtain this…", not "does the product currently do it".
|
|
83
|
+
→ Defeats: "we never shipped it, so nothing is being taken away."
|
|
84
|
+
4. **Enumerate the near-miss verbs, not just the headline one** — charge / count /
|
|
85
|
+
cap / condition / gate / degrade / delay / require-signup.
|
|
86
|
+
→ Defeats: the soft form. A generous cap, a free-but-registered tier, a
|
|
87
|
+
zero-cost counter — all are the same harm and none is the headline verb.
|
|
88
|
+
5. **Define every term the rule turns on by EFFECT, and close the list.** A
|
|
89
|
+
definition that enumerates mechanisms is a list of the ways you already thought
|
|
90
|
+
of; end it with "…and anything else the user must give, accept or obtain from
|
|
91
|
+
us."
|
|
92
|
+
→ Defeats: the third mechanism. "Charge = payment or account" is walked past by
|
|
93
|
+
"requires opting into telemetry".
|
|
94
|
+
6. **Enumerate the FORMS a violation can take, then state a closure rule** —
|
|
95
|
+
"anything not named here is out unless it is X".
|
|
96
|
+
→ Defeats: the unnamed variant. "A step, a required field, a check, or a cost
|
|
97
|
+
that varies but is never zero" kills "auto-filled, zero human input", because
|
|
98
|
+
the form is still a required field.
|
|
99
|
+
7. **State the subject predicate of any enumerated test in checkable terms.** If
|
|
100
|
+
the test applies to "a record of work", say what makes something one.
|
|
101
|
+
→ Defeats: denying the subject. The proposer agrees with every item on your
|
|
102
|
+
list and asserts the list does not apply.
|
|
103
|
+
8. **Give one IN and one OUT example on the same axis, differing in a single
|
|
104
|
+
variable.** The pair carries the discriminator; without it the reader invents
|
|
105
|
+
one.
|
|
106
|
+
→ Defeats: the borderline case, which is where every real argument happens.
|
|
107
|
+
9. **Name the re-descriptions you expect, inside the rule's own sentence** —
|
|
108
|
+
"in any presentation", "however the code got here", "not by a component that
|
|
109
|
+
does not exist yet", "storing it as Markdown changes nothing".
|
|
110
|
+
→ Defeats: relabeling. A board called a "view" is still a board.
|
|
111
|
+
|
|
112
|
+
## 2. The five clauses a Vision needs around its rules
|
|
113
|
+
|
|
114
|
+
Rules do not hold alone. These structural clauses were the difference between a
|
|
115
|
+
rule that survived and the same rule leaking.
|
|
116
|
+
|
|
117
|
+
- **Supremacy clause** — on any rule a second layer, product, tier or future
|
|
118
|
+
component could route around: *"these bind the product as a whole; shipping a
|
|
119
|
+
forbidden thing in the paid layer does not put it out of reach."*
|
|
120
|
+
- **Exceptions attached to the rule they limit, in the same bullet, phrased
|
|
121
|
+
affirmatively.** An exception in another section is a leak; an exception phrased
|
|
122
|
+
only as a negation produces CANNOT DECIDE. *"This rule does not reach X;
|
|
123
|
+
supporting one more X is squarely wanted."*
|
|
124
|
+
- **Anti-abuse clause on every exemption, naming the only permitted outcomes.**
|
|
125
|
+
A maintenance exemption without one lets any forbidden thing that already
|
|
126
|
+
shipped be maintained forever, and any new one be framed as a fix to it:
|
|
127
|
+
*"work framed as a fix to something that should never have shipped is not
|
|
128
|
+
exempt — it is the removal of that thing, or it is out."*
|
|
129
|
+
- **Stated defaults, per path including the exempt path** — "anything unreached is
|
|
130
|
+
out"; "an exempt fix that preserves a forbidden thing is out". A test that says
|
|
131
|
+
"admitted only if" gives new capability a default; exempt work has none unless
|
|
132
|
+
you write one.
|
|
133
|
+
- **Precedence, when two sentences can both apply.** Two adjacent statements
|
|
134
|
+
pointing opposite ways are decided by whichever the reader reaches first.
|
|
135
|
+
|
|
136
|
+
## 3. Only prohibitions can reject; only positives can admit
|
|
137
|
+
|
|
138
|
+
This is the most common structural failure and it is invisible from the inside.
|
|
139
|
+
|
|
140
|
+
- **A Goal cannot reject anything.** If the admission test says "advances a Goal
|
|
141
|
+
and violates no Non-Goal", then rejection power lives *only* in the Non-Goals.
|
|
142
|
+
A Goal that says "scale cost to risk in both directions" cannot stop cost
|
|
143
|
+
inflation — you need a prohibition for that.
|
|
144
|
+
- **A prohibition scoped to one rung of your own scale protects only that rung.**
|
|
145
|
+
Banning ceremony on trivial edits invites the same ceremony one level up.
|
|
146
|
+
- **A criterion phrased as an already-true state cannot be advanced.** "The check
|
|
147
|
+
is CLEAN at every closure" is a state, so "advances this signal" is meaningless
|
|
148
|
+
and any proposal citing it is undecidable. Give every positive criterion a
|
|
149
|
+
**baseline with headroom**: a current value and date, or an explicit list of
|
|
150
|
+
improvement categories that count.
|
|
151
|
+
- **Give recurring legitimate work an explicit authorization clause**, or it will
|
|
152
|
+
be rejected by your own test: packaging and installation, the product's own
|
|
153
|
+
tests, reducing what the agent must read, supporting one more client. Each needs
|
|
154
|
+
a home in the positive sources — otherwise "moves nothing this document commits
|
|
155
|
+
to" fires on exactly the maintenance the product needs.
|
|
156
|
+
|
|
157
|
+
## 4. Minimum operable sections
|
|
158
|
+
|
|
159
|
+
A Vision is a gate. These are the load-bearing parts; anything else is
|
|
160
|
+
orientation for humans and should be recognized as such.
|
|
161
|
+
|
|
162
|
+
| Section | Must contain | Enables |
|
|
163
|
+
|---|---|---|
|
|
164
|
+
| Authority & scope | what it binds (all layers, tiers, future components), that packaging is irrelevant, precedence among its own sections, the approval line | both |
|
|
165
|
+
| Defaults | the default ruling for anything unreached, stated per path | both |
|
|
166
|
+
| Admission test | one sentence naming *exactly which* sections are positive sources and *exactly which* are prohibitions | ACCEPT |
|
|
167
|
+
| Positive sources | Goals / Actor commitments / Success Signals — each with a baseline and headroom, checkable against a named artifact | ACCEPT |
|
|
168
|
+
| Prohibitions | property-based, closed enumerations, named re-descriptions, in/out pairs | REJECT |
|
|
169
|
+
| Invariants | the decision question with both branches answered, plus an anti-laundering clause | both |
|
|
170
|
+
| Exemptions | each with its anti-abuse clause | prevents laundering |
|
|
171
|
+
| Definitions & imported facts | terms defined by effect; **any fact from another document a ruling depends on, restated here** with the reason | standalone use |
|
|
172
|
+
| Pointers | what deliberately lives elsewhere, so an absence reads as intentional | prevents false CANNOT DECIDE |
|
|
173
|
+
|
|
174
|
+
**Imported facts matter more than they look.** If a ruling needs your triage
|
|
175
|
+
levels, your risk tiers or your lifecycle states, restate the boundaries in the
|
|
176
|
+
Vision — routing the reader to another file breaks the cold-read premise the
|
|
177
|
+
whole gate rests on. Keep the procedure elsewhere; bring the boundaries here.
|
|
178
|
+
|
|
179
|
+
**Keep competitive positioning OUT.** A Vision defined by comparison to another
|
|
180
|
+
product rots silently: the comparison target moves and no one edits your document.
|
|
181
|
+
Put it in a dated snapshot elsewhere and point to it.
|
|
182
|
+
|
|
183
|
+
## 5. What no wording can fix — use a mechanism instead
|
|
184
|
+
|
|
185
|
+
Five failure classes are structural. Prose cannot close them; do not try.
|
|
186
|
+
|
|
187
|
+
| Failure | Mechanism |
|
|
188
|
+
|---|---|
|
|
189
|
+
| "Advances a Goal" is a claim about the world, not the text | Measure it: run the ruling battery before and after, admit on measured improvement |
|
|
190
|
+
| **Cumulative ratchet** — each addition defensible, the sum is the ceremony the Vision forbids | A measured budget: steps per level, tokens the agent loads, artifacts per change; add-one-remove-one |
|
|
191
|
+
| Facts the proposal never states ("a quota of *what*?") | A proposal template that demands them, and a stated rule that omission resolves against the proposal |
|
|
192
|
+
| Structural compliance without truth — every rule satisfied, the artifact still wrong | Independent review; a Vision cannot detect this |
|
|
193
|
+
| An accepted change silently falsifying the Vision | Require the amendment in the same change; check cross-document facts mechanically |
|
|
194
|
+
|
|
195
|
+
And the sixth, which is why this file exists:
|
|
196
|
+
|
|
197
|
+
**Adversarial re-description is unbounded.** Every patch names the evasions seen so
|
|
198
|
+
far; a new one always exists. Patch-after-defeat is a treadmill. The only thing
|
|
199
|
+
that converts it into a ratchet is a **standing battery**: keep every attack
|
|
200
|
+
proposal that ever worked as a fixture and re-run the whole set against every
|
|
201
|
+
Vision edit. A Vision without a battery decays the moment someone motivated reads
|
|
202
|
+
it.
|
|
203
|
+
|
|
204
|
+
## 6. The blind check (procedure)
|
|
205
|
+
|
|
206
|
+
Run this **before promoting any Vision to APPROVED, and before any amendment of an
|
|
207
|
+
approved one**. Not for DRAFT edits — promotion is when authority is granted, and
|
|
208
|
+
it is rare, so the cost lands where it buys most.
|
|
209
|
+
|
|
210
|
+
1. **Give the reviewer the document text and nothing else.** Not a path — the
|
|
211
|
+
text, pasted. Forbid opening files, searching, and web access explicitly. A
|
|
212
|
+
term the reviewer cannot resolve is then a property of the document, not of
|
|
213
|
+
their tooling.
|
|
214
|
+
2. **Fresh context, and a different model from the author where the client allows
|
|
215
|
+
it.** Author self-review is structurally blind to its own omissions.
|
|
216
|
+
3. **Hand them a battery, not an open question.** Concrete proposals to rule on:
|
|
217
|
+
- the standing fixtures (every attack that ever worked — see §5);
|
|
218
|
+
- **reject-side** proposals aimed at each prohibition;
|
|
219
|
+
- **accept-side** proposals the document plainly wants (a bug fix, packaging
|
|
220
|
+
work, supporting one more client, a documentation improvement). *A gate that
|
|
221
|
+
can only reject is half a gate, and the accept side is where most Visions
|
|
222
|
+
fail without anyone noticing.*
|
|
223
|
+
4. **Ask for the mechanism, not just the verdict.** For each ruling: the exact
|
|
224
|
+
quoted line, or precisely what the document fails to say. Then: *which rules
|
|
225
|
+
could you not get around, and what structural property defeated you?* That
|
|
226
|
+
answer is worth more than the findings.
|
|
227
|
+
5. **Ask for rewords.** "Slip a bad proposal past this document, including one
|
|
228
|
+
dressed in its own approving vocabulary." A rule nobody can reword is done; a
|
|
229
|
+
rule that falls to the first attempt was never a rule.
|
|
230
|
+
6. **Every finding is answered — fixed, or refused with reasoning** (`review.md`
|
|
231
|
+
§Receiving). Add every successful reword to the standing battery, whether or
|
|
232
|
+
not you fix it this round.
|
|
233
|
+
|
|
234
|
+
Three lenses are worth running for a product-level Vision: **comprehension** (what
|
|
235
|
+
is this, what could you not resolve), **gate operability** (the battery above),
|
|
236
|
+
**durability** (what rots, what is unfalsifiable, what is a time bomb). For a
|
|
237
|
+
feature-level Vision or an M-VISION, the gate lens alone is usually enough.
|
|
238
|
+
|
|
239
|
+
## 7. Cost, honestly
|
|
240
|
+
|
|
241
|
+
A first draft written against §1–§4 will still have findings — the checklist
|
|
242
|
+
removes the structural classes, not judgement errors. Expect one blind round to
|
|
243
|
+
find real things and a second to confirm. What it should NOT take is five rounds
|
|
244
|
+
of discovering the same class of defect in a new disguise; that is the specific
|
|
245
|
+
waste this file exists to prevent.
|