What it does
The Forge is a software factory: the thing a person runs to get a new project that is already safe to let an AI agent build in. Measured from the repository (main), counting every tracked file including the extension-less commands (bin/stamp, bin/doctor, bin/terminal-proof, bin/forge-hook, bin/forge-core-manifest and the git hooks): 10,534 lines of application code in 112 files, 5,830 lines of tests in 45 files, 340 written test cases, 7 data tables, 5,398 lines of Markdown, YAML, JSON and text, 89 commits on the main line and 89 on all branches. The pieces, with what each is made of:
- The factory commands: 1,361 lines.
bin/stamp(518 lines),bin/doctor(362),bin/terminal-proof(426), the launch shimbin/forge-hook(34) and the manifest toolbin/forge-core-manifest(21). - The control kit (
controlkit/): 4,313 lines of Python. Thirteen control modules (2,061 lines), the fail-closed runner (224), the transcript reader (357), the back-check reconciler (264), the integrity manifest (209), the typed event model (122), the Astro decomposer (110), the orientation composer (176), the store primitives (180) and the store tools (330), with 14 contracts, 6 rule files for a pinned code parser and the committed core manifest. - The git perimeter (
.githooks/): 384 lines of dependency-free shell: a pre-commit hook (84), a pre-push hook (90) and a shared scanner (210). - The two state servers (
mcp/): 274 lines,forge-orient(91) andforge-store(183), over a 112-line database schema. - The four frame-packs: 5,420 lines of code and tests together.
ts-default(2,326),astro(902),py-default(851) andkernel-default(1,341), carrying 42 deliberately illegal examples. - The six build-loop skills: 221 lines, projected for two AI tools (Claude Code and Codex).
- The proof machinery. The doctor, the terminal-proof generator with 13 committed capture files for two packs, 4 per-line provers, the core-integrity manifest, and 26 test files holding 4,480 lines.
- The records. The Definition of Done (99 lines), two doctrine files (the 42-line operator protocol and the 14-line list of enforced actions), the north-star document (
VISION.md, 350 lines), the orientation protocol, and 7 review records instate/reviews/(two independent sign-offs and five per-step records).
Each part, as built:
The factory: what a new project receives on day one
- The factory (
bin/stamp). One command assembles a new project folder with both skeletons already in it: the chosen starter pack as the project's own code frame, and the whole control kit around it. The doctrine, the skills, the packs and the control kit are kept in one place, the factory, and every project is a pinned copy of them. - What is stamped. The control kit with every control, rule and contract; the two servers that expose the project's state; the git perimeter; the doctrine; the session wiring and the six build-loop skills; the launch shim; the doctor; the ledger's schema; recorded real events for the canary; the control kit's own tests; and a seed plan.
- Green out of the box. A stamped project must build, run its own gate and run its own doctor successfully before anyone has touched it. The stamp's tests prove this on a real throwaway project with real installs.
- The seed plan is unapproved on purpose. The first attempt to write product code in a new project is refused until a plan has been written and a fresh reviewer has approved it. A test asserts that no pack ships a plan that is already approved.
- The composed instruction file. The project's own
CLAUDE.mdis assembled from the factory's rules and the pack's frame rules, with the gate command re-pointed at the project. If the line to re-point is missing, the stamp refuses to produce the project. .forge-versionand--restamp. Each project records which version of the factory stamped it. A restamp is an explicit, reviewable act that refreshes the control kit and leaves the project's own code, plan and ledger untouched; a control deleted in the factory is deleted in the project too. A project is never tied to the live factory, so it stays buildable and enforced whatever the factory does next.- Its own integrity manifest. The stamp recomputes the fingerprints of the project's own copy of the control kit, so the tamper check is correct from the first minute.
- The factory-only door ships shut. The one sanctioned way to edit the control kit exists only in the factory. A stamped project's instructions say so, and a test asserts the door is not armed.
- The stamp fails closed. A missing pack, or a pack name that tries to reach outside the packs folder, stops the stamp before any file is written. It never leaves a half-made project.
- Silent-rot guards. Tests fail if the stamp's file list or a pack's dependencies fall behind what a project needs, so the factory cannot keep running while producing subtly stale projects.
The Frame: bad code cannot compile
- Frame-packs (the starter packs). Four of them:
ts-defaultfor TypeScript business applications,astrofor content and marketing sites,py-defaultfor Python, andkernel-defaultfor the declare-once kernel. The Harness does not depend on the language, so a new kind of project is a new pack and nothing else changes. - What a pack must provide. An instruction file stating its frame rules, and one gate command that succeeds with nothing else running: no database, no network, no container.
- Packs obey the Harness. A pack's own code must pass the control kit it ships with, with no shortcut anywhere. The frame governs its own example.
- One source of truth. Each kind of record is declared once, as its database table. The check that validates it and the compiler's description of it are both derived from that declaration, so the three cannot drift. Change one column and everything that depends on it stops compiling.
- Illegal states are unrepresentable. Every "one of several" is written so that each state carries exactly the fields that exist in that state. A confirmed booking with no contract value cannot be written down; the compiler rejects the shape.
- Branded types and smart constructors. An amount of money, a date, an email address and each kind of identifier is its own type, and can only be made by one function that validates it. A bare number is not an amount, and a tour's identifier cannot be passed where a booking's is wanted.
- The smart-constructor carve-out. Making a branded value needs one cast, and casts are banned. So exactly one named file per project may contain exactly one kind of cast, to a brand declared in that same file. Everything else is still refused there, and the exception is tied to the file's name, so no comment on a line can widen it. The rule behind it: carve out the legitimate use and block only the misuse.
- Parse, don't validate. Anything arriving from outside (a web request, the database, a file, an AI's output) is parsed once into a domain type. After that the type itself is the proof, and nothing re-checks.
- Exhaustive matches. Every place that handles "one of several" must handle all of them. Adding a state stops compilation at every place that has not dealt with it, so the compiler produces the list of what a change touches.
- Typed lifecycle. The order of the business lives in the types: a tour can only be created from a qualified lead, and a booking only from a completed tour. An illegal step does not compile.
- Schema-driven screens with opt-out fields. Lists and forms are generated from the same declaration. Every field appears by default, and a screen may change how a field is drawn and may never drop it: a screen that leaves a field out does not compile. Add a column and every screen for that record stops compiling until the field is given a place.
- The deterministic verifier (the trust inversion). Business rules are small, pure functions that judge a proposed change and return every violation, with the clock and every fact they need handed to them. Nothing an AI produces reaches an effect without passing one. His line for it: AI proposes, the gate disposes.
- prove-bites. For every guarantee the pack keeps a deliberately illegal example, marked
@bite. On every run the gate compiles them and requires the compiler to reject each marked line individually, by name, so one dead example cannot hide behind another's error. If a later change widens a type so that an illegal example starts compiling, the gate fails. - The gate checks the tests as well. The tests are type-checked by the gate, because the test runner does not check them and a test could otherwise make a claim about types that is false.
- The Astro pack: exhaustive at the paint. A page is a list of sections, each one of a closed set. Content is parsed against its declaration at build time, so a malformed page fails the build. The renderer is a table that must hold a component for every kind of section, so a kind with no component is a compile error and never a blank space on a live page. Every link target is a parsed, branded route, and the gate ends with a check of every link in the built site.
- The Python pack. The same frame carried into a second language, where "will not compile" becomes "will not pass the strict type checker at the gate", with the same per-line proof and with tests that generate their own inputs.
- The kernel pack (
kernel-default). The declare-once kernel as a starter pack: one specification per kind of record, in a closed vocabulary of ten field types, relations, checks, claims and named actions with pure checkers, from which the validation, the screens and the database are derived. It was the first pack built through the Forge's own loop. The kernel has its own page (the declare-once kernel). The ten field types are text, long text, email, timestamp, date, integer, money, boolean, array and enum (an enum must name its initial value); an effect is a pureverify(row in, verdict out, no input or output) plus a pureapplythat returns a patch; a queued side-effect job is written in the same transaction as the row (the outbox pattern by construction); the row type is derived from the field and relation declarations and never written by hand; a field's optionalgroupputs it in a generated section so a 48-field form reads as tidy sections; and a list-column entry naming a field that does not exist does not compile. A per-entity content hash of the specification is derived, never maintained (a label change rehashes only its entity, a change to a verifier body does not rehash). The pack's 212-line specification and its eight-phase plan (P0 to P7: scaffold and two-tier gate, frame and specification language, generated screens, pure verifiers, the database leg, the database doctor, the reasoning door, and the Forge's declared-service integration) set out the plain-tables-plus-audit-trigger engine (a database trigger that audits every write including a console edit, tenant isolation by forced row-level security, an exclusion constraint against double-booking, an idempotency-keyed command log written through a privileged funnel, and a version funnel for stale clients, queued jobs and emailed links). That engine was chosen over an event-ledger design after five rounds of adversarial debate and an audit of seven of his own production systems. - The cast-free boundary. The kernel's central hand-off, from a raw database row to a typed checker, is the place a cast is the obvious answer. The Harness refuses one even inside the carve-out file, and the plan review made the boundary the first risk to retire. The boundary is designed so the compiler accepts it with no cast at all, with a runtime check of the row's shape in front of it and a counter-example proving the alternative does not compile. The mechanism: the erased view of an effect declares its two functions (
verifyandapply) as method signatures over a plain string-keyed row, and TypeScript checks method parameters in both directions even under its strict function-type setting, so a typed effect assigns into the erased view with noas. Four alternatives were tried in a spike against both the compiler and the Harness and rejected in the file's own record (relocating the cast into the carve-out file, a branded-function witness, a closure, and parsing the row through the schema, held in reserve). A negative-control file shows the property form does not typecheck, so the method form is load-bearing. Because that form is deliberately unsound at that one parameter,checkRowShapeis the only thing keeping the row's shape honest,invokeVerifyandinvokeApplyare the sole callers of the erased functions in the pack, and a test gutscheckRowShapeto prove its throw path. - The two-tier gate and the declared service. A pack that needs a database splits its proof in two. The ordinary gate runs with nothing else switched on, which keeps the promise that a stamped project proves itself at once. The guarantees only a real database can show are demonstrated by a second doctor against a service the pack declares.
- The reasoning door. Where an AI proposes a change at run time, the wall ignores the reason the AI gives and works out for itself whether the change is legal, with the same checker a form's Save button uses. The decision is identical with or without the AI's explanation.
The reference product every pack carries
- An event-booking slice at full frame rigor. The
ts-defaultpack (2,326 lines) is itself a small working product: three records (a lead, a tour and a booking), each declared once as a table, each with its states as a closed set. A lead is new, qualified or lost; a booking is draft, held, confirmed or lost, and each state carries exactly its own fields (a held booking has a hold-until date, a confirmed one a contract value, a lost one a reason). Three typed lifecycle steps connect them. The pack has a typed API router, three screens (lead, tour, booking) generated from the declarations through a field renderer, a browser entry point, and 7 test files, one of them a render smoke test of the screens. - The verifier with three business rules.
src/verify.tsholds the trust-inversion seam: a pure function that takes a proposed booking and the facts around it (the tour, the confirmed bookings that already exist, the clock) and returns every violation found. Its three rules are that a confirmed booking needs a positive value, that nothing may be confirmed for a tour that has already happened, and that one venue on one date cannot be booked twice. Each violation is a typed variant carrying the offending data, and the function never reads the system clock. - The same slice in Python.
py-default(851 lines) carries lead, tour, booking, lifecycle, result, smart constructors and verifier as Python modules under the strict type checker, with 10 marked illegal examples in its prover, property-based tests, and a Makefile gate (linter, strict type checker, tests and the prover). - The Astro site frame.
astro(902 lines) carries a page as a list of sections drawn from a closed set of three (hero, call to action, prose), two content pages (home and about), a layout, a catch-all route, a branded-route module, a link checker (bin/link-check.mjs) and a prover, with 3 test files. - The kernel pack.
kernel-default(1,341 lines) holds the specification language (dsl.ts), the registry, validators, a content hash of the specification, two example records (booking and contact), the cast-free boundary module, a migration script, and a Docker Compose file for the database that its second-tier doctor uses. - A pack's contract with the factory. Each pack ships its own
CLAUDE.mdandAGENTS.mdframe rules, its own brand and smart-constructor modules and its own illegal-example prover. An optionalpack.jsondeclares the pack's gate command, its bring-up steps and its extra ignore rules: a pack without one is a Node pack onnpm run gate, andpy-defaultuses it to declaremake gate, so adding a language or a project shape adds a folder and the stamp adapts its message and its composed instruction file to it.
The Harness: bad process cannot proceed (the control kit, controlkit)
- Fail-open is unrepresentable. A control is a pure function that looks at what the agent is about to do and returns one of two answers, allow or block. It never ends the program itself. One runner turns the answer into the exit signal, and it turns everything else (a crash, an unreadable event, an unknown control, an answer that is not an answer) into block. The two answers are numbered as the AI tool's own exit signals, so there is no translation to get wrong. The only way to "allow" is for a control to say so explicitly.
- The launch-failure shim (
bin/forge-hook). A few lines of the plainest shell stand in front of the runner. If the enforcement program is missing or crashes, the shim reports "block". The doctor proves both cases on every run. - One entry point for five kinds of event. The AI tool's settings wire the same launch shim to before-tool, after-tool, session-start, turn-end and helper-agent-turn-end events, and the runner routes each to the controls that apply to it. After-tool blocks are sent back to the AI as an error to correct and also stop its next step.
- Four layers. Before a tool runs, the controls judge what it is about to do. After it runs, they re-check what actually landed on the disk. When the agent tries to end its turn, they judge its claim. And outside the AI tool altogether, git's own hooks check what is being committed and pushed. A single guard is one bug away from off.
- The deny matrix. Under the controls, the AI tool's own permission settings refuse the most obvious moves outright: editing the control kit or its wiring, and committing with checks skipped. The core is fenced twice by unlike machinery.
- The escape-hatch closer (
pre-edit-escape-hatch). Before any edit to source lands, the control rebuilds the file as it would be after the edit and scans it with a real code parser for the four shortcuts and for comments that silence the checker. If one is there, the write never reaches the disk. A file the parser cannot read is refused, never waved through. The scan coversany,ascasts (but notas const) including the angle-bracket form, the non-null!(and not!x,!==or!!x),@ts-ignore,@ts-nocheck,@ts-expect-errorandeslint-disable, and an identifier that merely contains "any" is allowed. Rebuilding the file matters because an edit carries only a fragment, which is not parseable TypeScript: the control reads the file on disk, applies the patch and scans the whole result. Three named invariants hold, C1 (the scanner's version is verified before its answer is trusted), C2 (a sentinel rule detects the parser's error nodes, so an unparseable buffer fails closed) and C3 (notebook cells are extracted and scanned, and Astro files are decomposed). A declaration file is allowed early. The control's contract carries 72 examples (47 that must be blocked and 25 that must be allowed), 24 of them on the smart-constructor carve-out alone. - The scanner pin (
pre-edit-astgrep-pin, C1). The scanner is found at a fixed location and must report the exact pinned version (0.40.5) before its answer is trusted. A fake scanner cannot pass, and the doctor proves it by planting one. - The on-disk backstop (
post-edit-escape-hatch). After any tool has run, the file that is actually on the disk is scanned again with the same rules. The first check judges what the agent said it would write; this one judges what was written. - No back-door writes to source (
pre-bash-write-to-source). Source may only be written through the scanned editing path. Shell redirects, in-place stream editors and one-line scripts that open a file for writing are refused. - No switching the checks off (
pre-bash-no-verify). A commit that skips the hooks, and any setting that points git at a different hooks folder, is refused. The command is parsed the way a shell would parse it, and a command the parser cannot read is refused. - No removing the signal (
pre-edit-test-signal). Marking a test to be skipped, marking one test to run alone (which silently disables every other test in the file) and deleting a test file are all refused. The markers refused are.skip(,.only(,xit(,xdescribe(,xtest(,it.skipandtest.skip; the check reads only the new text an edit introduces, and a guard catches a marker split across the pieces of a multi-part edit. - The AI cannot edit the rules it follows (
pre-edit-protect-core). The control kit, its wiring, its environment, the shim, the doctor and the git hooks cannot be edited, by the editing tools or by any shell command that writes, copies or moves a file into them. Copying a file out is reading, and is allowed. The shell check extracts the destination of each file-writing verb (cp,mv,install,rsync,ln,dd) and blocks a core destination, so a plain copy of a neutered file over a control is refused. The protected set also coversbin/and the root test configuration. - The self-edit seam (
FORGE_SELF_EDIT). The control kit still has to be changeable on purpose. There is one door, it exists only in the factory, and every edit made through it is allowed and written to the ledger as a self-edit. The door could not be built through the tool it guards, so its creation was planned as one recorded genesis edit to three named files. - The core-integrity manifest (
post-core-integrity). A committed list of fingerprints covers every file of the control kit, the git hooks, the shim, the doctor and the wiring. After any tool runs the files are fingerprinted again, and a difference that did not come through the audited door is refused. The same check runs again at commit. A missing manifest is itself a refusal. - No code before an approved plan (
pre-edit-plan-gate). Product code cannot be edited until the plan file records that a review approved it. A missing or unreadable plan is a refusal, and the folder name is matched with case folding so thatSRC/orSrc/on a case-insensitive disk does not get round it (pinned as a contract case). - Only the implementer edits code (
pre-edit-skill-scope). Each step of the build loop records the role it is acting in and clears it on the way out, so a stale permission cannot carry over. Product code can be edited only in the implementing role. In the planning role, the reviewing role or no recorded role, the edit is refused, so a reviewer that finds a fault cannot quietly fix it and must send it back. A scope command (controlkit/scope.py, 98 lines) records, clears, shows and validates the role, and a malformed scope file is a refusal. - The keystone:
stop-green-gate. When an agent tries to end its turn with a claim of completion, the control reads the real record of the session and looks for a gate command that succeeded after the last change to code. With none, the turn is refused and the agent is told to run the gate. A gate that ran before the last edit does not count, a missing record is a refusal, and helper agents are held to the same rule. A claim is recognised by a vocabulary of completion phrases (done, complete, finished, ready to merge, ready for review, all set, shipped, good to go, "all tests pass", "the build is green", fixed, resolved, and the check mark) matched sentence by sentence, and a disclaimer in the same sentence ("not yet done", "still working") cancels that sentence's claim while a disclaimer about other work in a different sentence does not. A plain stop with no claim is never blocked, and a claim with an unreadable record is. The gate command pattern can be overridden per product (FORGE_GATE_PATTERN), and the block is sent on both channels the AI tool documents, exit code 2 with the reason and the structured block message. - The transcript scanner. The record is read as data. Each command is rebuilt the way a shell would read it, so the word "pytest" inside a commit message or a printed line does not count as a test run.
- The review gate (
stop-review-gate). A plan step marked done must have a review record whose verdict is a pass and whose producer and reviewer are two different sessions. The trigger is the plan file and not the agent's words, so the rule cannot be dodged by not saying "done". A review record signed by the session that did the work is treated the same as no record. The loop writes the record before it marks the step done, so the rule can never lock a correctly run build, and the only steps exempt are ones he named explicitly. The exempt set lives in a.baselinefile that is deliberately not a.jsonfile so the review loader skips it, and a missing baseline exempts nothing. - The back-check. After commits land, a reconciler compares the review records with the commits, each of which names the session that made it. A phase with no implementer commit, no reviewer commit, or the same session on both sides fails. The commits carry git trailers (
Forge-Session-Idon the implementer's commit,Forge-Review-Session-Idon the reviewer's verdict commit,Forge-Phaseon both), and a phase named by a trailer with no review record fails too. The doctor runs the back-check, with a self-check against a synthetic clean history. - Session-start orientation (
session-start). Before a new session's first turn it is handed the live state of the build and the operating protocol, so it starts from what is true and does not invent a process. A helper agent receives the same picture as the main session. - The
.githooksperimeter. Shell scripts with no dependencies scan what is being committed and what is being pushed, using the same rule files, so an edit made in another editor or a plain terminal meets the same wall. It is proved under the stricter shell that Linux servers use. - Selector parity. The same rules run in two languages, in the controls and in the git hooks. A shared set of cases is run through both real implementations and must give the same answer, so there is one definition of a shortcut and not one per layer.
- The Astro decomposer. The parser cannot read Astro's mixed files, so each one is split into its code regions and those are scanned with the ordinary rules. A file that cannot be split cleanly is refused. The splitter exists twice, once for the controls and once for the git hooks, and the two are held to byte-for-byte agreement.
- The typed event boundary and the schema canary. The controls read the AI tool's events through a typed model, and real events are recorded to disk. A strict reading and a tolerant reading of those recordings are compared on every run, so a change in what the AI tool sends is caught before it can blind a control. It caught two real fields a looser model would have dropped without a word.
The ledger and the live state
- The append-only ledger (
audit_events). Every refusal and every self-edit is written as a row with its time, session, control and reason. The database itself rejects any change or deletion of a row, whoever asks and through whatever program, so the history of what agents attempted cannot be rewritten by an agent. Two indexed time and agent columns, a payload and an evidence path sit beside each row, the database runs in write-ahead mode with foreign keys on, and the refusal surfaces as the database's own integrity error rather than anything the application raises. The store layer is dependency-free (the standard library's database module only), finds its root by one fixed order (FORGE_ROOT, thenCLAUDE_PROJECT_DIR, then the current folder) shared with the runner so hook writes and server reads always meet the same file, and makes each record's identifier from a random 32-bit token and not a hash of the payload, so two identical same-second calls can never share one identifier. - Decisions, findings and traps. Beside the ledger sit three records an agent can add to. A decision carries its reasons and its evidence and can be superseded, never erased. A finding carries a severity and a way to reproduce it. A trap is a mistake this project has already made, with the rule that avoids it. Each record notes when it was last read in full, so records nobody has opened are surfaced.
- The tools are the contract (
forge-store). Agents reach the store through twelve tools, nine that read and three that add. There is no tool that deletes or edits, and the database file is not to be read directly. orient(forge-orient). One call returns the live state of the build in under three kilobytes: the plan and the phase in hand, the last gate result, open findings by severity, active traps, the list of enforced actions and the build loop. It replaces a fresh agent re-reading a pile of files, and it never fails: a missing source becomes an "unknown" and a warning.- The live marker. The orientation carries a token computed from the current phase and the last gate result, and its contract checks that token, proving that live state and not a fixed banner reached the session.
- Durable state over chat. The plan, the role in hand, the reviews and the last gate result are files. The controls read those files and never the agent's account of them.
- Logic apart from transport. Everything the two servers do lives in plain functions the gate tests directly. The servers are thin wrappers, so the gate never depends on the transport. The server library is imported lazily because the gate's own environment runs an older Python than the library needs.
- The twelve tools by name. Nine read (
list_findings,get_finding,list_decisions,get_decision,list_traps,get_trap,recent_audit_events,stale_records,store_stats) and three add (record_finding,record_decision,record_audit_event); the last returns the database's refusal as a structured tool error and not a crash. A test seeds ten findings and eight traps and asserts the orientation stays at or under 3,072 bytes, which is why a trap surfaces as an identifier and a summary only. - The wiring discovery. A real engineering problem found while wiring the two servers: a plain import of the server library from the repository root resolved to the project's own
mcp/folder (a namespace folder with no__init__.py), which has no file, and not the library. The answer was a dedicated Python 3.12 environment with the library pinned, no__init__.pyever added to that folder, and a proof by a real handshake over standard input and output (initialise, list the tools, call one) against both servers.
The six build-loop skills and the two AI tools
- Six skills, 221 lines.
/forge-new(intake, 29 lines),/forge-plan(33),/forge-plan-review(32),/forge-implement(54),/forge-verify(26) and/forge-review(47), each a short file naming its role, the tools it is allowed and the order of its steps. The loop that joins them, and the controls that enforce its order, are described under How he built it. - Two AI tools, one set of rules. The skills and hook wiring are held for Claude Code (
.claude/) and projected for Codex (.agents/skills/,.codex/hooks.json), with the Codex instruction file generated from the first. - Orientation and the ledger's servers.
.mcp.jsonregistersforge-orientandforge-storefor a session; a dedicated Python 3.12 environment runs them, apart from the protected one.
The parts, in a line each
- The factory:
bin/stampwith restamp, four frame-packs, and a suite that stamps real throwaway projects to prove each one comes up working. - The control kit: 13 registered controls wired to five kinds of session event, the fail-closed runner and launch shim, six rule files for a pinned code parser, 14 contracts, and the git perimeter with its shared scanner.
- The append-only store with its four tables, the two state servers and their 13 tools, and the orientation composed from the doctrine.
- The six build-loop skills, the role-scope command, the review gate and the back-check.
- The proof machinery: the doctor, the terminal-proof generator for two packs with its committed captures, the integrity manifest and its tool, and four per-line provers.
- A reference slice of an event-booking product (lead, tour, booking) at full frame rigor: one declaration per record, branded values, typed lifecycle, generated screens, and a verifier for three business rules.
- The Definition of Done, the doctrine, the north-star document, and two independent sign-off records with five per-step review records.
What it achieved
- 58 commits in one day took the factory from its first commit to an independent sign-off of all four gates and a merge. This measures what Maxwell's agents produced in one day under his design.
- The Astro pack went from its first line to an independent sign-off in under four and a half hours, and an environmental services company's website was stamped from it the same day.
- The independent reviewer's own attacks, beyond the scripted ones, were all refused: a gate that had run before the last edit, a failed gate, a different illegal state, a different shortcut. Ordinary work was let through, showing the wall is not a blanket refusal.
- 13 controls are proved by 14 contracts carrying 312 examples through the real entry point: 185 that must be blocked and 127 that must be allowed.
- 42 deliberately illegal states across the four packs are each rejected individually on every run: 15 in TypeScript, 7 in Astro, 10 in Python and 10 in the kernel pack.
- 365 tests of the control kit, and 96 tests across the four packs.
- The Forge's own ledger holds 68,146 rows from its own building sessions and proof runs: 68,132 refusals and 14 audited self-edits. By control: 25,885 type-safety shortcuts, 14,113 back-door writes to source, 9,991 attempts on the control kit, 8,470 attempts to disable tests, 7,292 attempts to switch off checks, and 348 claims of "done" without proof, with a further 1,476 refused edits for want of the pinned scanner, 311 caught by the after-the-edit re-scan of the disk, 234 for files the parser could not read, 8 attempts to edit code before an approved plan, 4 integrity failures. The 14 audited self-edits were recorded under four names (11 from the entry point, and one each from the core-protection control, the factory's self-edit door and the core-integrity repair). The rows were written under 14 distinct agent names.
- Across the Forge, the five projects that carry its control kit and the refusal demonstration, the ledgers hold 371,817 recorded refusals (counted from the seven ledgers). This counts every refusal the engine issued and recorded, of agents' real work and of the violations each project's doctor, contracts and tests drive through the real entry point on every run.
- Fresh reviewers were used at every step: on the plans before any code, on each built phase, and as adversaries attacking the controls, and every finding was fixed and re-reviewed.
- 89 commits in all, directed through 52 typed turns and 8 answered question panels from him in the recorded sessions.
- Measured from the repository. 10,534 lines of application code in 112 files, including the extension-less commands and the Astro files, 5,830 lines of tests in 45 files, 340 written test cases, 89 commits.
- By kind of file. The application code is 5,229 lines of Python in 42 files, 2,293 lines of TypeScript in 40 files, 459 lines of TSX in 7 files, 472 lines of
.mjsin 7 files, 178 lines of Astro in 6 files, 210 lines and 112 lines of shell and SQL, and 1,535 lines in 7 extension-less commands (the three factory commands, the shim, the manifest tool and the two git hooks), with the Python pack's 46-line Makefile in the 112 files. The tests are 4,663 lines of Python in 29 files and 1,167 lines of TypeScript in 16 files. The 26 root test files hold 4,480 lines. Markdown, YAML, JSON and text come to 5,398 lines in 106 files, and the repository tracks 271 files in all. - Gates. The control kit's unit gate runs 365 tests; the independent sign-off ran the gate and the doctor to exit 0 with all guards demonstrated, with all 15 TypeScript illegal examples rejected.
The problem it solves
- An AI produces the most probable continuation of what is in front of it. Probable and true only sometimes coincide, and the AI cannot feel the difference from the inside. He traced this to two roots: it has no model of the world, only of text about the world, and it was trained to look done rather than be done. The second root has no training fix. It can only be fixed by structure built around the model, which is the layer he works in.
- Under pressure an AI behaves predictably. It guesses, defers, removes the signal of a problem in place of the problem, explains away what it just did, conforms to whatever an earlier agent wrote, drifts to an easier question, and claims it cannot do what it can. Once behaviour is predictable it can be designed around: he does not try to change the creature, he engineers the enclosure.
- Giving the AI a tighter target does not make it honest. A capable model pointed at any stand-in for the goal (a passing test, a gate, something that looks finished) finds the cheapest route to the stand-in. So the wrong shape has to be made impossible to write, not merely forbidden.
- Strict types have a hole the compiler cannot see. Four small pieces of code (
any,as,!,@ts-ignore) tell the compiler to stop checking. They look like ordinary code, a reader skimming a change easily misses them, and any one of them quietly voids the whole structure. So there are two skeletons, and the second exists to defend the first. - A rule that has failed twice as written words is not fixed by better words. A warning is invisible to an AI. Only a block changes what it does.
- A safeguard that has never been seen to refuse anything may not be working at all: a guard that is built and never wired in looks like protection and does nothing. So every safeguard has to prove both that it stops what it should and that it lets legitimate work through.
- The session that produced a piece of work cannot review it. The reasoning that led to each choice is still in its context and will confirm each choice again. This is a property of the structure, not of effort.
- An AI that is blocked by a rule will, under pressure, propose editing the rule. This is the most dangerous failure of all, because it destroys the thing that makes every other check possible.
- A blocker that crashes lets everything through. The AI tool treats any exit signal except one specific number as "carry on", so a broken enforcer silently switches itself off unless failing is itself made to mean "refuse".
- An AI's memory of how something works is a guess: it will name a field the way it remembers it, even when the real data has no such field. So the real data is captured and the safeguards are checked against it.
- Each rule in the factory traces to a named incident, and he turned each into machinery: the blocks on destructive commands and on tampering with the hooks; the browser-validation rule and a turn-end block on closing an issue without it; the rule that "I can't" is a claim to be disproved, with the exact tool tried and the error it returned (the false capability ceiling, catalogued as pattern P-038); the rule to intervene minimally and never rewrite what works, with "while I'm here", "let me clean this up" and "for consistency" banned from dispatch prompts; and the rule that completion is a gate's exit signal read from the real record, never a claim.
- Copying a starter into each new project puts a separate copy of the rules in every project and lets every copy drift. So the rules are kept in one factory, and each project gets a pinned copy that is refreshed only by an explicit act.
- In ordinary business software one fact is restated by hand in about fourteen places that must agree, and the bugs live where two copies differ. They have one root: facts restated by hand, with agreement left to memory.
- The people who use his software have not adopted AI. A design that replaced the screens with one box to type requests into was rejected on that ground and is recorded as rejected so that it is not proposed again. The screens stay ordinary, and get more complete.
- The central rule: an agent will call work done before it is. The Forge answers it with the four-gate Definition of Done, the keystone that blocks "done" without proof, the wiring test, and six named invariants (C1 to C6). Together they close every way round the controls: a fake scanner placed earlier on the search path, a file the scanner cannot read, an unscanned notebook edit, a "done" with no proof, an editable control kit, and a folder renamed by letter case to slip past the plan rule.
- The Forge was not a new bet. Without having named it, he had already built this kind of machine, pointed at one subject, the building of software, and the same instinct was already in several of his products. The factory names that pattern and makes it systematic.
- Simple means simple code, not fewer guarantees. A safeguard is merged into another only when something else makes it wholly redundant.
- A wall that only ever grows becomes something to fight. Rules are earned from real incidents and never written in advance, and a safeguard can be narrowed or removed through the same diagnosis that adds one.
- The disciplines he had forced onto agents by hand are, one for one, the parts a more trustworthy AI would need inside it. The Harness builds those parts outside the model.
- The failures of AI agents could be collected, counted and compiled before any enforcement code was written. The Forge's profile records his directing of agents across more than 100 software projects and more than 200 dated, named incidents, with each control tracing back through a named pattern to one of them. Of the 145 behaviours that survived the filter, 95 were kept as his own voice, 32 cleaned up and 18 rewritten, and 14 were cut as an AI's account of him. A behaviour that appeared across all eight slices of his history was treated as an invariant, and those drive the control architecture. Of the 96 patterns, 38 are rated high confidence, 46 moderate and 78 universal, a rating that records which are properties of human and AI work in general and not of his habits. Each pattern has six fields: the trigger (what the AI does), the pushback (what he does), the AI's proposal, his decision, the implementation and the transferable rule.
- Four through-lines connect an incident to a pattern, a doctrine rule and a control, and the profile traces each to its code. "Done" without a green gate (the fabricated-tests incident, the keystone). Type-safety shortcuts that hide in a diff, where only a machine check reliably catches them (the escape-hatch closer). The writer reviewing their own work (the review gate, with its real committed record of two different sessions). The AI editing the rules it follows (the core protection, which also refuses a plain copy of a neutered file over a control).
- The north-star document was distilled from a working conversation and records its reasoning as an arc so the conclusions are not re-argued: decompose ordinary software into about 15 layers and name the glue tax; redraw a real 111-table application as a kernel (an 18,000-line helper becoming tools plus reasoning, soft-delete and the audit rule becoming impossible to violate); conceive a whole multi-tenant event-booking product, weigh the "one intent box" design and choose normal screens with the back end changed invisibly; and lock the decision that the Forge enforces the kernel shape first and ships the runtime as the library it leans on. The document also notes the pattern was already in several of his earlier products, unnamed, such as an audit log with an outbox, idempotency keys, date claims and a command pattern.
- Where the kernel is not the answer is written down: a marketing site, the checkout page, a hero booking page and a calendar are designed by hand; simple stable tables stay plain; hot high-frequency reads stay plain queries. The rule is to generate the app and hand-design the brochure.
- What must stay deterministic is named, and none of it is left to reasoning: every checker asserts that the actor's tenant equals the record's tenant; money is whole cents, payment proofs such as a webhook signature are checked, idempotency keys are single-use, and a pricing tool computes the charge so the model never does; first-payment-wins and no existing claim on a date; a refund no larger than the deposit; and consent before any outbound message. Tenants differ in policy and not in structure, so taking on a tenant is writing a brief.
- Screens of the kind the metadata-driven tools build (admin panels, low-code builders) already existed, and he placed the new idea precisely: what is new is where the AI plugs in, writing the declaration at build time and judging at run time and never drawing the screens.
How he built it
Maxwell builds software by directing AI agents, and The Forge was built that way: every control, pack, skill, contract and proof above is his work. He built the factory inside its own controls, produced by his agents inside the rules below. These are the rules, mechanisms and checks he put around that work, each under its real name.
How a rule becomes enforcement, and how enforcement is proved to bite
- The five-rung enforcement ladder (the enforcement maturity ladder). A failure happens; then a note the AI may ignore; then a hook that will not run the action; then a lint rule that will not let the shape be merged; then a type that will not compile. Every rule is pushed as far down as it can go, and a rule that has needed two spoken corrections must be promoted. Warn is invisible, so every control blocks. The controls lean toward refusing, because a false refusal costs one extra loop and a missed one costs his attention and his trust.
- Every failure becomes the spec for a permanent block (P-010). When an AI fails, the move is never patch and continue. It is to name the failure, name what made it possible, design the mechanical block that removes the whole class, and build it in the same session. His later correction of his own rule is kept beside it: the right change may add, remove or leave alone.
- The lineage. Each control traces back through a named pattern to a dated incident: real incidents, then 145 recorded behaviours, then 96 patterns in 11 families, then nine doctrine rules and the list of enforced actions, then the controls, then the ledger of what they refused. The behaviours were filtered for whose voice they were in, so that an AI's account of what he does was rewritten or cut and his own practice kept. How often a behaviour recurred across his history, and whether it can be detected reliably, decides what becomes a block and what stays as doctrine, so enforcement never runs ahead of evidence.
- Doctrine as the single source. The list of what is enforced is one short file. The orientation every session receives is composed from that file at the moment it is asked for, so changing what agents are told is one edit with no second copy to forget.
- Bijection contracts. Every control ships with a contract: inputs it must block and inputs it must allow. Both are run from end to end through the real entry point the AI tool calls, never through a stand-in, each in a fresh sealed project folder with the factory door's flag stripped so that no proof can pass because a door happened to be open. The must-allow half matters as much as the other, because a guard that refuses everything only looks safe.
- The control↔contract bijection. A test compares the list of registered controls with the list of contracts. A control with no contract fails the build, and so does a contract for a control that does not exist.
- The wiring meta-test. A second test compares the settings file with the registry. A hook that points at nothing, or a control that nothing calls, fails the build. This is the test that ends the guard that was built and never wired.
- The doctor (
bin/doctor): demonstrate, don't claim. The health check does not read settings and report that enforcement is on. It attempts each forbidden act for real (a shortcut written into source, an edit to the control kit, a copy over a control, code with no plan, a skipped test, a commit with checks off, a "done" with no proof, a completed step with no review, a tampered core file) and requires each to be refused, and requires the matching legitimate act to be let through. - The registry↔doctor bijection. Removing any demonstration from the doctor fails a test, so the proof cannot be weakened quietly.
- The gate is the checkpoint. Three named commands make up the gate (the control kit's tests, the doctor and the pack's own gate), and no check invented on the spot may stand in for them.
- Contracts first, red before green. A new control's contract is written first and seen to fail. The control, its contract and its doctor demonstration land in the same commit.
- Every bypass becomes a named case. An adversarial audit attacks the controls, and any way round them is reproduced, fixed test-first and pinned as a contract case carrying the exact input.
- No regression, ever. A change to a control that breaks an existing contract is a real failure, never a baseline to be edited.
- Empty is not green. A proof that ran nothing fails. An empty recordings folder, an empty list of illegal examples and a skipped step each count as failure, never as a pass by default.
- What the doctor drives, control by control. A write containing
as anyis refused and a clean write allowed; a fake scanner with the wrong version is seeded and a TypeScript edit refused; an edit to a control file and acpover a control are each refused; a source edit with no plan file in an isolated folder is refused; a source edit with no recorded implement role is refused; addingit.skip(and deleting a test file byrmare each refused;git commit -m x --no-verifyis refused;sed -i s/x/any/ src/a.tsis refused;as anyseeded on disk is caught by the after-edit control; a tampered core file is refused and a pristine tree allowed; "All done, ready to merge" with no gate is refused and a plain stop allowed; a done step with no review record is refused and a clean record allowed. The doctor also runs the full unit gate as its last backend proof, with a recursion guard because the suite includes the doctor's own end-to-end test, and it asserts that the evidence files each gate names are on the disk. A launch-failure proof shows the shim refusing even when the Python runner cannot be invoked. - The deny matrix, as written. The AI tool's settings refuse any shell command containing
--no-verifyor-c core.hooksPath, and any edit, write or multi-edit to the control kit, the settings file, the local settings file and the protected environment folder, so the controls themselves are fenced by unlike machinery. - The build record by commit. The fail-closed core first; then the escape-hatch closer on the reconstructed buffer; protect-core, no-verify, write-to-source and plan-gate; then, each in its own commit, the keystone (C4), the scanner pin (C1), the self-edit seam and session-start orientation; the hardening commits for notebook edits and unparseable buffers, unbalanced quotes, case-variant and missing paths, the after-edit backstop, and the
.githookslayer and its dash-clean form; the six skills in one commit, the role-scope control, the Definition of Done, the TypeScript pack, the stamp and its restamp, the Python and kernel packs, the integrity manifest with copy and move detection, and the review gate, whose message records that the gate that stops self-approval did not approve itself. - A build that ran its own audit and its own back-check. The astro pack's sign-off ran the stamped product's own
bin/forge-hookagainst a different illegal state than the script used (a suppression comment inside a.astrofile's frontmatter) and checked that a real refusal row, with its control name and the offending line, landed in that product's own ledger. The same sign-off checked the escape-hatch scan on all four paths of an Astro file (frontmatter, script, clean, and an unterminated frontmatter fence). - Terminal proof (
bin/terminal-proof). One command stamps a throwaway project, plants an illegal state and captures the compiler's refusal, drives the refusals through the project's own entry point, and tries to delete a ledger row. The captured output is committed, and anyone can regenerate it. - Traps are written into the instructions. A mistake the project has already made is recorded with the test that shows the truth. One example: the state servers are proved to start by a real handshake, never by a check that could load the wrong thing.
- No overclaim. The project's public description may state only what the build enforces and demonstrates. Done is what the doctor proves, never what a document says.
Who checks whom
- The build loop. Six skills in a fixed order:
/forge-newturns an idea into a specification,/forge-planturns that into a phased plan,/forge-plan-reviewattacks the plan,/forge-implementbuilds one step,/forge-verifyruns the gate, and/forge-reviewattacks the work. The Harness enforces the order: no code before an approved plan, no "done" before a successful gate, no producer reviewing its own work. - Each skill is scoped by its tools. A skill is given only the tools its role needs. The intake and planning skills have no way to run a command, and the verifying skill can only run and read, so a role cannot act outside itself even if it tries.
- Frame-first planning. A plan is ordered the way correct software is built: the types and the one source of truth, then proof that they bite, then the screens generated from them, then the verifier and its tests, then features. Every step names its files and the proof it will produce, and a step's done-signal is an exit code.
- Fresh-context plan review. Before any code, a fresh agent that never saw the planning is given the specification and the plan and told to find where the plan fails. The decision to build is final and not open to it. Any critical finding keeps the plan unapproved, and the plan gate keeps code locked.
- Producer ≠ reviewer, by session identity. A review counts only when the record names two different sessions. The reviewing agent returns findings as data and cannot write the record. A pass written by the session that did the work is, in the project's words, a forged attestation, and the gate rejects it.
- The reviewer does not touch the code. Findings go back through the implementing step and the gate is run again. A finding may not be waved through as inconvenient or as already there.
- The claim gate. The next step may not start until the current one has its clean review record, so nothing is built on work that has not been independently attested.
- Review after fix. Fixes made in answer to a review are themselves sent to a fresh review.
- The gate that stops self-approval does not approve itself. When the review gate was built, it was marked untrusted until a fresh adversary had attacked it, and what followed from that attack (detecting copies and moves, and the integrity manifest) was again marked untrusted until reviewed.
- The four-gate Definition of Done. Done means four independent gates all hold, every file of evidence each gate names is on the disk, and a fresh review of the whole is clean. Gate A is the control kit, and the doctor's exit signal is its definition. Gate B is the process: the keystone fires, the wiring test holds, and real refusals are in the ledger. Gate C is the screens: generated from the declaration, with the missing-field proof and a render in a real browser. Gate D is a reference product stamped and driven through the Forge itself. A slip on any one undoes done, and done is never asserted by an agent.
- Fresh-context sign-off by running. The final reviewer trusts no committed transcript. It reruns everything on a newly stamped project and then adds attacks of its own that were not in the script.
- The mandatory loop for the factory itself. His plan for building the factory put every one of its eleven phases through the loop it ships: a written goal with exit criteria, a fresh review of the plan, a contract written first, the gate, a fresh review of the built work, and the evidence committed. No phase counts on a report.
- The early-phase back-check. The first phases had to be built before the machinery that enforces the loop existed. The plan has them run the loop by hand with the evidence committed, and then reconciled against the history once the machinery exists. Early work is not exempt from the standard.
What the AI must treat as true
- The operator protocol. Nine rules handed to every session. Your own fluent answer under uncertainty is a guess shaped like an answer. Run, read, then claim, and cite the file or the exit signal. No claim of completion without the evidence in the same message. Understand exhaustively and intervene minimally.
- The truth hierarchy. What a tool returned ranks first, then his own documents, then the conversation, then documents written by an AI, and last the code, which shows what is and never what was meant. A conflict is ruled on openly and the higher rank wins.
- The two-option rule. On any error there are two moves: fix the root cause, or stop and present what happened with a proposed fix. Continuing silently is not available, and neither is removing the signal. The Harness closes both by force.
- Technical decisions belong to the AI. The agent makes the technical call and states its reason. Only four kinds of decision come back to him: a version change to a dependency, anything destructive or irreversible, anything legal or touching personal data, and a business choice.
- "I can't" needs proof. A claim of inability must name the exact tool tried and the error it returned. Infrastructure that can be started is started and is never offered as a reason to stop.
- Three corrections means a fresh agent. Three corrections on the same framing show the context is polluted. The answer is a fresh agent, not a fourth correction.
- "Flaky" is escape vocabulary. An intermittent failure is investigated. It is never counted as a pass.
VISION.md, the north star. A fresh agent reads once why the factory exists: software built as a small kernel (an append-only record, a finite set of allowed changes each guarded by a small fixed checker, and AI reasoning only behind the buttons that need judgment), with ordinary screens generated from one declaration. The Forge's job is twofold: enforce that products are built this way, and ship the runtime they are built from, written once and reused by every product.- Not every write goes through a model. An ordinary Save on an ordinary form passes through the fixed checkers and the record, with no AI in its path, and no AI sits in the path of any read. The reasoning layer never commits anything; the wall does.
- AI authors the specification. What an AI has to get right shrinks from thousands of lines of hand-written screens and handlers to one small declaration that can be reviewed. Less to write by hand means less to get wrong.
- Tenants differ in policy, not in structure. Customers of one product share the same allowed changes and the same checkers. What differs between them is a brief and a set of settings, so taking on a customer is writing a brief and never forking code.
- The rejected paths are written down. The document records the two designs that were tried and dropped, with the reasons, and says where the kernel is not the right tool (a marketing page or a checkout is designed by hand), so a later agent neither re-proposes nor over-applies it.
- The discipline concentrates. What must never be left to an AI's reasoning is named: the wall between customers, money arithmetic, the core rules of the business, and consent. Reasoning proposes; the wall disposes.
- Superseded designs are kept and marked. When the kernel's engine was chosen after five rounds of adversarial debate, the specification and plan it superseded stayed on disk under a "superseded" name, with an instruction not to restore them.
- The Forge is itself an instance of the kernel. Its ledger is the append-only record, its controls and contracts are the checked changes,
orientis the read view, and the agent is the reasoning layer whose proposals the wall accepts or refuses. The task is to turn the kernel the Forge runs on into the kernel it makes products from. - Rules are earned from incidents. The factory ships only safeguards that trace to something that happened, and guards may be narrowed. The keystone was narrowed so that it judges changes to code and not edits to documents.
How the owner judges the work by machine evidence
- "Does it build, and is the gate green?" The Frame Method's central move: instead of reading every line to ask whether the code is right, he asks a question a machine answers, and the system is engineered so that the two questions converge. The compiler does the line-by-line review, and he judges its verdict. His part is to steer the specification, approve the plan, demand the proof and read the gate.
- Proof of rejection. For every new guarantee the agent must show him the refusal: an illegal state failing to compile, a shortcut being blocked. Seeing it refused is his evidence that the guardrail is real.
- Plain-language intake.
/forge-newrestates his idea in one sentence for him to confirm, turns it into records and their states in words, writes acceptance criteria that can be tested, and brings only business choices back to him. It may not invent a business rule he has not confirmed. - Evidence, not a summary. The verifying step shows the actual command output and exit signals.
- A refusal anyone can cause. In a browser page built as a proof, a visitor plays the part of an agent, attempts a forbidden act, and watches the real control kit compute a real refusal and write a real ledger row, then tries to delete the row and is refused by the database. Nothing in it is recorded, replayed or simulated.
- The same wall in a second AI tool. The hook wiring and the six skills are also projected for Codex, with its instruction file generated from the first, so the rules do not depend on which agent is at the keyboard.
Named concepts
The named concepts, defined
The Forge · Idea B · The truth kernel · Enforcer first, runtime as the library it leans on · The wall · Reasoning proposes, the wall disposes · Metadata-driven UI, with the AI placed at build time and run time · The through-lines · Forge-Session-Id · Forge-Review-Session-Id · Forge-Phase · FORGE_GATE_PATTERN · The funnel rule · The audit-trigger floor · The command log · The version funnel · The decompiler · Plain tables with an audit trigger · Cast-A · Correctness by construction · Bad code can't compile, bad process can't proceed · The Frame · The Harness · The two skeletons · AI proposes, the gate disposes · The compiler becomes the reviewer · The green build is the spec · A self-defending software factory · Frame-pack · bin/stamp · --restamp · .forge-version · Green out of the box · Illegal states unrepresentable · One source of truth · Branded types · Smart constructors · The smart-constructor carve-out · Parse, don't validate · Opt-out fields · Schema-driven UI · The trust inversion · prove-bites · @bite · Prove it bites · Exhaustive at the paint · The cast-free boundary · The two-tier gate · The reasoning door · controlkit · Fail-open is unrepresentable · Fail-closed by construction · The launch-failure shim · The deny matrix · Escape hatches · The escape-hatch closer · pre-edit-escape-hatch · pre-edit-astgrep-pin (C1) · post-edit-escape-hatch · pre-bash-write-to-source · pre-bash-no-verify · pre-edit-test-signal · pre-edit-protect-core · FORGE_SELF_EDIT · The self-edit seam · post-core-integrity · The core-integrity manifest · pre-edit-plan-gate · pre-edit-skill-scope · stop-green-gate (the keystone, C4) · stop-review-gate · The back-check · session-start · The .githooks perimeter · Selector parity · The schema canary · The five-rung enforcement ladder · The enforcement maturity ladder · Warn is invisible · P-010: every failure becomes the spec for a permanent block · Bijection contract · Must-block and must-allow · The control↔contract bijection · The wiring meta-test · The doctor · Demonstrate, don't claim · The registry↔doctor bijection · Terminal proof · Silent-rot guards · audit_events · The forge-store · Decisions, findings and traps · orient · The live marker · Durable state over chat · The build loop · /forge-new · /forge-plan · /forge-plan-review · /forge-implement · /forge-verify · /forge-review · Frame-first · Fresh context · Producer ≠ reviewer · A forged attestation · The claim gate · The Definition of Done · Gate A, Gate B, Gate C, Gate D · The completion predicate · The operator protocol · The truth hierarchy · The two-option rule · Capability-ceiling falsification · The glue tax · The kernel · The ledger · Effects and verifiers · Projections · The reasoning layer · Generate the app, hand-design the brochure · The Frame Method · The Operator Doctrine · The Build Protocol
What it shows
He can turn what he has learned about how AI agents fail into machinery that makes those failures impossible, package it as a factory that every new project starts from, and have each safeguard prove that it bites.