Memory, recall, and grounded answers
When you compile a source, ThinkingRoot does not store raw chunks. It extracts
Claims: the unit of memory
When you compile a source, ThinkingRoot does not store raw chunks. It extracts claims — atomic, self-contained statements of fact. Each claim carries:
- the statement (the fact itself),
- provenance — exactly which source and which byte range it came from,
- a grounding score and admission tier (how well-supported it is),
- temporal validity (so stale facts can be superseded), and
- links to the entities and other claims it relates to.
Because facts are atomic and provenance-tracked, ThinkingRoot can deduplicate them, supersede outdated ones, cite them precisely, and delete them cleanly — none of which is possible with raw document chunks.
remember
Write a fact into memory. It is embedded and indexed so it becomes immediately recallable. Writes are idempotent where they carry a deterministic id, so the same fact written twice does not create duplicates.
root ask "what depends on the billing service?" # a grounded queryIn code (SDK) or inside a Root Function:
await brain.memory.store("The billing service depends on the identity service for auth.");
await ctx.memory.remember("Customer 42 upgraded to the Pro plan on 2026-06-01.");recall
Semantic retrieval over the compiled graph. A query is embedded, matched against the claim vectors and the entity graph, then reranked by a cross-encoder for precision. You get back the most relevant claims, each with its source citation.
const hits = await brain.memory.recall("how does authentication work?");
// → [{ statement, source_uri, grounding_score, ... }, ...]Retrieval is local and fast — it never calls a generative LLM, so it is reliable and cheap. The generative step (turning claims into prose) is separate and optional.
Grounded answers: verified or silent
ask retrieves the relevant claims and synthesizes a cited answer. The defining
rule is "verified or silent": if the retrieved claims do not support an answer,
ThinkingRoot says it does not have that in memory rather than inventing one. This is
why answers carry citations and why they refuse instead of hallucinating.
const { answer, citations, refused } = await brain.ask("what is a Root Function?");
// answer is grounded in real claims; citations point at the exact sources;
// refused === true when memory doesn't support an answer.The grounding is a property of the retrieval + compile layer, not of any particular model. So whether your own LLM consumes the recalled claims (via MCP or the SDK) or ours does, the answer is grounded the same way — and the compiled, deduplicated context means the model spends far fewer tokens.
Why this beats raw retrieval
Naive retrieval-augmented generation feeds an LLM raw document chunks: redundant, unverified, unlinked. ThinkingRoot feeds it compiled, deduplicated, cited claims. That is why answers are accurate, why they can abstain honestly, and why the same knowledge costs a fraction of the tokens to reason over.