Skills · Content & docs

Grounded Vault

Unverified31/40

Use when maintaining a durable Markdown knowledge store that agents compile from sources, when every number or quote in a wiki page must trace back to an immutable source, or when compiled pages need cheap drift detection against the code they describe. Teaches the raw/wiki/archive layout, per-claim provenance links, and git fingerprints for zero-token staleness checks.

Originally by wshobson · MIT

Claude CodePartialHas SKILL.md but declares no allowed-tools — Claude Code will ask for permission each time
Cursor·UnknownWe have not crawled the repo tree, so we will not guess
Codex·UnknownWe have not crawled the repo tree, so we will not guess
Gemini CLI·UnknownThe spec defines no detection rule for Gemini
Copilot·UnknownWe have not crawled the repo tree, so we will not guess
npx agentalley add grounded-vault

This command does not work yet — the CLI is still being built. Until then, use Raw in the reader below to take the file.

Who is stuck, and on what

Use when maintaining a durable Markdown knowledge store that agents compile from sources, when every number or quote in a wiki page must trace back to an immutable source, or when compiled pages need cheap drift detection against the code they describe. Teaches the raw/wiki/archive layout, per-claim provenance links, and git fingerprints for zero-token staleness checks.

The whole source

No sign-in, no blur, nothing truncated
grounded-vault/SKILL.md105 lines5.3 KBRawView on GitHub
Frontmatter — 2 properties
namegrounded-vault
descriptionUse when maintaining a durable Markdown knowledge store that agents compile from sources, when every number or quote in a wiki page must trace back to an immutable source, or when compiled pages need cheap drift detection against the code they describe. Teaches the raw/wiki/archive layout, per-claim provenance links, and git fingerprints for zero-token staleness checks.
1---
2name: grounded-vault
3description: Use when maintaining a durable Markdown knowledge store that agents compile from sources, when every number or quote in a wiki page must trace back to an immutable source, or when compiled pages need cheap drift detection against the code they describe. Teaches the raw/wiki/archive layout, per-claim provenance links, and git fingerprints for zero-token staleness checks.
4---A5No allowed-tools declared — no way to tell what this skill may touch
5 
6# Grounded Vault
7 
8A grounded vault is a three-layer Markdown store in which every compiled claim can be traced
9back to an immutable source and every page can be checked for staleness with one `git diff`.
10It needs a git repository and nothing else. The convention comes from the `llm-wiki-loop`
11project, which is a reference implementation rather than a dependency; this skill teaches the
12pattern so it works with plain files and whatever agent is in the session.
13 
14## When to Use
15 
16- An agent compiles notes, papers, transcripts, logs, or code into wiki pages that later sessions rely on.
17- A page cites numbers, dates, or quotes, and a reader must be able to verify each one against its source.
18- Pages describe code, and rereading the codebase every session to check whether they still hold is too expensive.
19- Knowledge must be corrected without losing history: superseded pages are archived, never deleted.
20 
21Session state, task queues, and conversation continuity are a different problem; use the
22context-management or conductor plugins for those. This skill is about provenance and drift on a
23durable knowledge store.
24 
25## The three layers
26 
27| Layer | Contents | Who writes it | Rule |
28|---|---|---|---|
29| `raw/` | source material: notes, papers, transcripts, logs, exported data | people and ingestion only | immutable once added; agents never edit a raw file |
30| `wiki/` | compiled pages built from `raw/` and from code | agents and people | every number, date, and quote links to its source |
31| `archive/` | pages that drifted or were superseded | agents, during garbage collection | moved, never deleted; the header says why |
32 
33Two files sit at the vault root. `index.md` is the map of every current page. `log.md` is an
34append-only record of what changed and why. Both change in the same commit as the page they
35describe.
36 
37## Page header contract
38 
39Every `wiki/` page opens with a header block:
40 
41```markdown
42# Authentication architecture
43 
44> Raw: [raw/notes/auth-v1.md](../raw/notes/auth-v1.md), [raw/adr/0007-jwt.md](../raw/adr/0007-jwt.md)
45> Fingerprint: git:5b237fa
46> Monitored: src/auth/jwt.ts, src/auth/session.ts, package.json
47> Status: Current
48```
49 
50- `Raw:` lists every source the page was compiled from. Inline claims link to their specific source as well: `Tokens expire after 15 minutes ([raw/adr/0007-jwt.md](../raw/adr/0007-jwt.md)).`
51- `Fingerprint:` is the short commit hash the page was compiled against.
52- `Monitored:` lists the code paths the page describes. A change to any of them after the fingerprint means the page may be stale.
53- `Status:` is `Current`, `Outdated` (monitored code moved on), or `Disputed` (a newer source contradicts the page).
54 
55## Grounding rule
56 
57A compiled page states only what a source supports, and every number, date, or quotation
58appears verbatim in the linked source. A synthesis says it is one and links its inputs. A gap
59in the sources is written into the page as a gap rather than filled by guessing.
60 
61Check it mechanically: for each linked claim, search the linked raw file for the exact figure
62or quoted phrase. A miss is a grounding error and blocks the commit. The script in
63`references/details.md` does this for a whole vault.
64 
65## Drift detection
66 
67Compare the fingerprint with the current tree instead of rereading monitored code:
68 
69```bash
70git diff --stat 5b237fa..HEAD -- src/auth/jwt.ts src/auth/session.ts package.json
71```
72 
73Empty output means the page still describes the code it was compiled against. Any output means
74recompile: reread only the changed files, update the page, and stamp the new fingerprint. The
75check runs in milliseconds and spends no model tokens.
76 
77## Workflow
78 
791. **Ingest.** Put new material in `raw/` under a dated or sourced filename. Never rewrite an existing raw file; add a new one beside it.
802. **Compile.** Write or update the `wiki/` page with the header block, a source link on every claim, and the fingerprint of the commit the code was read at.
813. **Check.** Run the grounding check and the drift check before committing. Fix misses at the source; do not weaken a claim to make the check pass.
824. **Garbage collect.** When drift or a contradicting source appears and the page is not recompiled now, change its status, move it to `archive/`, and record the reason:
83 
84 ```markdown
85 > Status: Outdated
86 > Reason: src/auth/session.ts changed after git:5b237fa; see log.md 2026-09-01
87 ```
88 
895. **Update the map.** Every add, move, or archive updates `index.md` and appends one line to `log.md` in the same commit.
90 
91## Commit gate
92 
93Run both checks from a pre-commit hook or a CI step so a page cannot land with an unverifiable
94number or a stale fingerprint:
95 
96```bash
97python3 scripts/check_vault.py --strict # exits 1 on any grounding miss or drifted page
98```
99 
100## Going deeper
101 
102`references/details.md` covers: the vault check script, batching the drift check across pages,
103templates for `index.md` and `log.md`, renamed or deleted monitored files, sources that are
104binary or live at external URLs, and the reference implementation.
105 

Reviews

Installed this one?Write the first review and take the Trailblazer badge.

Reviews only open after a real install, so this is empty — and we leave it empty rather than invent one.

Alternatives

Also in Content & docs