Lavett
Lavett turns a messy pile of notes, chats, and logs into a typed, evidence-anchored memory — then compiles the minimal proof path an answer needs, instead of dumping raw history into the prompt.
Against flat context.
A bigger context window does not create structured memory. It postpones the same problem at a higher token cost. Most AI memory still behaves like a pile — previous messages, summaries, or retrieved chunks.
A recurring mistake, a corrected belief, a changing goal, and a stable preference should not all live as equal pieces of text. They need structure, scope, evidence, and a lifecycle.
A support structure for reasoning.
A lavett is the carriage beneath the cannon: the structure that carries, stabilizes, and aims it. The barrel does the firing; the carriage decides where it points. The base model stays the engine of language — Lavett builds the support layer around it, so the same model reasons from better-aimed input.
An engine, and three surfaces on top of it.
A local-first, evidence-anchored memory engine — Python, Apache-2.0, offline by default. Every stored fact points back to an exact source_file:Lline, and a context compiler selects only the evidence a question needs and renders it, cited. Three surfaces sit on the engine.
Current
An offline, read-only view of project memory: current state, what changed, open questions, ruled-out / superseded — each cited to its line. Deliberately not a chatbot.
Structure Atoms
A grep-safe ID over an exact raw span that decodes to triples, lifecycle status, and an integrity hash — and back to the exact source. Raw text is never mutated.
Appeals
The first product vertical: a UK PIP benefit-refusal plus the claimant’s evidence, compiled into a cited, adviser-review packet — which descriptors the evidence supports, where the decision contradicts it, and the honest gaps. Decision-support, not legal advice; the bundled case is synthetic.
A deterministic verifier owns grounding and rejection. An opaque LLM is optional, gated, default-off, and its proposals are accepted only when the verifier can ratify them against a verbatim source quote. In the Appeals vertical the verifier rejected 393/393 systematic and 4,800/4,800 randomized-fuzz adversarial proposals with zero ungrounded acceptances; where the legible layer recovered nothing on everyday paraphrase (0.0), one capped model run (~$0.017) lifted it to 1.0 through that same verifier.
These are adversarial-set and synthetic-corpus results — attack coverage and integration recall, not a real-world accuracy claim. Promising, not proof yet.Decision-grade, and reproducible by one command.
A deterministic string scorer is the source of truth — no LLM grades itself. Headline 33-case suite, temperature-0, fully offline. Every figure below maps to a row in the repository’s evidence ledger with an exact reproduce command.
And on real, fixed models.
Live answer-recall on two model families, deterministic substring scorer, ~65 vs ~137 tokens. Lavett beats a fair BM25 retriever in every run; against full raw context it wins for one family and honestly loses for the other. Total live cost across both runs: ~$0.24.
NodeWeb: language as connected meaning.
Not a nearest-neighbour blob. Typed meaning events, correction trajectories, lifecycle state, scopes, and an evidence-anchored RoleGraph — routed through explicit memory paths. Each subsystem is independently ablated in the benchmark, so its weight is measured, not asserted.
Meaning Event Graph
Language is decomposed into structured events: subject, action, object, time, attributes, and evidence.
learner → omitted → article ("the")Concept Gravity
Recurring or important concepts gain weight over time, so retrieval surfaces what actually matters.
concept recurs → gravity ↑Truth Lifecycle
Facts can be current, uncertain, contradicted, corrected, or superseded — and the transition stays inspectable.
belief → corrected → supersededMulti-Route Retrieval
Routes search memory differently — entities, timelines, corrections, evidence — run in parallel and competed.
route(roles) ∥ route(evidence)Correction Trajectories
Tracks the arc of a mistake instead of a single snapshot: mistake → correction → recurrence → improvement.
mistake → corrected → recursContext Compiler
Compiles a task-specific briefing split into proof context, background, and what it dropped — not raw chunks.
chunks ✗ → proof path ✓Scope-Bound Memory
Memory is scoped by workspace, so a coding answer is never contaminated by unrelated tutoring notes.
answer ⊂ dominant workspaceExplainable Memory Paths
Every answer can show the memory route behind it — the roles, events, and evidence it actually used (lavett ask --explain).
answer ⟵ route ⟵ evidenceI publish the anti-results.
The headline 1.0 / 0.887 is in-sample and partly tuned to the query wording. Under blind paraphrase the structural synthesizer still generalizes — answer recall 0.833 on unseen wordings, isolation and compression intact — but a retrieval-side paraphrase tax remains (req-evidence ~0.88–0.91, precision ~0.47–0.55) and is not claimed. Every case where raw context or BM25 beats Lavett (7 and up to 5 cases respectively) is preserved in the evidence ledger. The full test suite runs 590 passed, 2 xfailed. That is what makes the rest trustworthy.
Legibility is not optional.
Nothing Lavett stores, routes, or emits is allowed to exist without a deterministic decoder back to faithful human-readable text. A representation without a registered decoder is rejected at write time.
The road from here.
typed memory, cited proof paths, offline benchmark suite
benefit-refusal → cited, adviser-review evidence packet
packets in front of 5–10 advisers / caseworkers
UK PIP vs Swedish Försäkringskassan — a corpus swap, not a rewrite
the moonshot — explicitly not being trained now
Early, with a real, growing edge.
NodeWeb runs today as a Python research prototype — a CLI-first engine with SQLite storage, heuristic extraction, multi-route retrieval, evidence-aware context compilation, ablation-backed evaluation, and 31 registered frontier diagnostics. Apache-2.0, offline by default.
lavett ingestlavett asklavett ask --explainlavett compile-contextlavett evalmake proofMemory should have shape.
Language models need more than longer context. They need memory with structure, evidence, and aim — and a representation a human can still read. NodeWeb is the first attempt to build it.