For the complete documentation index, see llms.txt. This page is also available as Markdown.

The Wiki

The Wiki is a continuously updated structured memory per tenant. Not a vector store with documents in it. A graph of entities, relationships, narratives, and rolling summaries, linked back to Ledger and Raw.

The Wiki is what makes Brain compound. The longer it runs for a tenant, the deeper the memory and the lower the marginal cost per query.

What Lives in the Wiki

Element
Examples

Entities

Counterparties, accounts, products, contracts, employees

Relationships

"Vendor X invoices Cost Center Y", "Account A funds Subsidiary B"

Narratives

"Q3 receivables held flat versus Q2 despite revenue growth, driven by..."

Rolling summaries

Week-over-week, month-over-month, quarter-over-quarter snapshots

Embeddings

pgvector embeddings indexed for semantic retrieval

What the Wiki Answers

The Wiki is built to answer the kinds of questions only memory can answer.

Example Question
Why Memory Is Required

"Who is this counterparty?"

Requires accumulated entity knowledge

"What is our normal monthly burn?"

Requires rolling baselines

"Have we paid this vendor before?"

Requires historical lookups

"What changed in receivables this quarter?"

Requires diff against prior periods

"Is this subscription one we still use?"

Requires usage and recurrence tracking

Citations on Every Answer

Every answer carries citations into the Ledger and Raw. Any claim is traceable back to source evidence.

How the Wiki Updates

The Wiki updates incrementally as new Ledger records arrive.

Trigger
Wiki Action

New transaction in Ledger

Update counterparty profile, refresh rolling balance, re-embed narrative

Counterparty merge

Resolve duplicate entities, rewrite relationship edges

Invoice paid

Close the matching obligation; update vendor history

Period boundary

Generate rolling summary; index for retrieval

Why Not Just a Vector Store

Vector stores retrieve documents. The Wiki retrieves a graph of verified entities with citations.

Vector store
Wiki

Returns chunks of documents

Returns entities and relationships

No native citations to source

Every node links to Ledger and Raw

Updates by re-embedding

Updates incrementally as Ledger changes

No notion of correction

Supersession propagates from Ledger

Reasoning hallucinated on retrieval

Reasoning bounded by structured facts

Compounding Effect

Brain's Wiki gets cheaper to query and richer to read the longer it runs.

Time Horizon
What Compounds

First weeks

Entity resolution stabilizes; counterparty profiles emerge

First months

Rolling baselines mature; anomaly detection becomes possible

First year

Year-over-year comparisons unlock; vendor history is deep

Multi-year

Cross-period narratives become durable; switching costs are high

What's Next

📥 Raw and Ledger

The verified substrate underneath the Wiki.

📋 Policy

How Wiki context informs policy decisions.

🛠️ Wiki SDK

Programmatic queries.

Last updated