Resonance Lattice · Docs

Why rlat?

You already have an LLM, file tools, vector databases, and a context window you could paste documents into. This page is the measured case for using rlat instead — and the honest list of cases where you shouldn't. Every number below comes from a published benchmark with a committed test set; each one links to its section on the benchmarks page.

01 — The case in one paragraph

What you're choosing between

An AI assistant answering questions about your corpus has four options today: trust its training data, dig through files with grep-style tools, bolt on a vector database, or paste the documents into context. rlat is the fifth: build the corpus into a single .rlat file once, and the assistant gets grounded, cited answers in milliseconds for tenths of a cent — plus three things none of the alternatives have at all: standing knowledge of your world's rules and dead ends, a memory that survives sessions, and a self-improvement loop with published evidence.

02 — vs the LLM alone

Training data is where hallucinations live

On a Microsoft Fabric documentation corpus — a domain the LLM partially knows, the most dangerous kind — Sonnet alone answered 63 hand-written questions at 56.9% accuracy with 19.6% hallucination, and invented an answer for half the product names that don't exist. The same model with rlat in the loop:

LaneAccuracyHallucination$ / question
Sonnet alone56.9%19.6%$0.002
+ rlat search (one shot)76.5%3.9%$0.004
+ rlat deep-search --mode knowledge92.2%0.0%$0.009

One retrieval call adds ~20 points of accuracy at 5× lower hallucination; the multi-hop loop takes hallucination to zero on answerable questions. For compliance work, single-shot --mode constrain is the floor: 2.0% hallucination and a 91.7% refusal rate on made-up product names — it invents nothing 11 times out of 12. Full matrix: hallucination reduction.

03 — vs file tools

The grep loop is good. It's also 6.5× the price.

The strongest alternative is a real one: an agent with grep, glob, and read-file tools digging through the corpus. On the Fabric bench it scored 94.1% — two points above deep-search's 92.2% — at $0.060 per question against $0.009, slower wall-time, and it was fooled by half again as many fake product names (25.0% vs 16.7% distractor hallucination). Within noise of each other on accuracy; 6.5× apart on spend.

And here is the honest other half. On a second benchmark — a hand-written code corpus the LLM had zero prior knowledge of — the grep loop beat single-shot rlat on accuracy outright (85% vs 35%): questions needing cross-file synthesis reward a tool that can keep digging. rlat was still 3.7× cheaper per correct answer ($0.012 vs $0.044), but if your workload is deep code navigation and thoroughness beats cost, use the file tools — we publish the number that says so (token spend).

The split, in one rule: volume and repetition favour rlat; one-off forensic digs favour the agent loop. An assistant answering corpus questions all day at $0.060 each is a bill; at $0.009 it's a rounding error.

04 — vs a vector database

A database is a part. rlat is the whole.

Measured against Chroma's out-of-box defaults on the same 1,000-passage corpus, same CPU: rlat answers warm queries at 17 ms p50 against 145 ms — 8.5× faster — and the result on disk is 2.7 MB against 8.6 MB. Chroma does build faster (a lighter embedder), then pays it back 8× on every query; build happens once, queries happen millions of times (build & query speed).

But the speed row understates the difference, because a vector DB is infrastructure you assemble: you choose the embedder, write the chunker, run the service, and what you get back is passages. A .rlat is the assembled thing — encoder pinned and benchmarked (BEIR-5 floor published), chunking built in, zero services, one portable file you can commit, copy, or hand to a teammate. And it holds what a DB has no column for: cited claims, standing constraints, falsified findings, and drift tracking back to source files.

05 — vs pasting docs into context

The most expensive option is the default one

Dumping the whole corpus into the context window every question cost $0.796 per correct answer on the code-corpus bench — 264,331 tokens a question — and scored worse than the grep agent (70% vs 85%): models lose facts in the middle of a giant paste. rlat's retrieved slice cost $0.012 per correct answer — 67× cheaper (token spend). Pasting re-buys the same tokens every single question; a knowledge model pays for the corpus once, at build time.

06 — What has no alternative

The part you can't assemble from parts

Retrieval is the comparable half of rlat. The other half doesn't have a competitor row, because the alternatives don't attempt it:

07 — When NOT rlat

The honest list

08 — The cost of finding out

One pip install, no API key

pip install rlat, build a knowledge model from a folder, query it — all free and local. The LLM-driven loops (deep research, curation, capture) run as skills on the Claude subscription you already have; an API key is only for unattended automation (API keys). First build to first grounded answer is a 15-minute path: getting started.

Where to go next