Rich Sadowski

Notes

Dated notes on running AI agents, knowledge systems and governance in production. Newest first.

The model writes words. Code supplies the facts.

Most AI knowledge bases fail the same way: they sound right and nobody can prove they are.

For the last few months I have been building a "Second Brain" for security and compliance work. It started from Andrej Karpathy's "LLM Wiki" method: raw source documents stay read-only in one folder, and an AI agent writes and maintains a plain-Markdown wiki from them in another. Policies, rulings, product docs and past answers become one curated page per topic, so retrieval returns reconciled facts, not fragments. This week it moved from "my tool" to a pilot others can install.

How I build on it borrows heavily from Matt Pocock's Claude Code skills: grill the plan before you build it, and write the failing test before the fix.

What changed in the design:

  1. The model writes words. Code supplies the facts and checks them. Every answer goes through a harness: retrieve, compose, then verify. Each quote must appear in the page it cites, each link must come from a supplied source, and each cited page must be real. If verification fails, the answer is withheld and the sources come back instead.
  2. Partial is a valid answer. If the Brain covers two of three parts of a question, it answers two and leaves the third blank. No guessing, no "TBD".
  3. Rulings are first-class. When I decide how a question should be answered, that decision is written to the owning page the same day, with a date. The next answer uses it.
  4. Chunking cuts facts apart, so a typed knowledge graph joins them. Every link carries a quote that must appear word for word on the page.
  5. Every page has a trust tier and a "stale after" date. About 1,700 product help pages are re-checked against the live docs, and pages past their date say so.
  6. Numbers are computed, not typed. A count that matters is stored as a sealed query. Lint fails if someone types the value by hand or edits the query without resealing it.
  7. It ships like software. A daily build runs lint, regression probes and a scan for credentials and personal data, then publishes a checksummed package with rollback.

The result is a knowledge base I can audit. When someone asks "where did that answer come from?", there is a file and a line.

If you are building retrieval for a regulated function, start with the verifier, not the prompt. See the architecture.

← richsadowski.comThe 3D officeLinkedIn ↗