Skip to main content
Everything Xynthis learns starts as a perception: a message you typed, a note, a document chunk, an event from a watcher. This page follows a perception from arrival to recall.

The write-time filter

Every perception passes through one filter before it can be stored. There is no side door: the CLI, the MCP server, background reflection, and file watchers all go through the same gate. The filter has three outcomes:
  1. Durable fact. The perception enters the fact store and the knowledge graph, and joins working memory. This is the only lane that survives a restart.
  2. Session-only. Useful right now but not a fact about you or the world: questions you asked (“what do you remember about X?”), task commands (“open Safari and search for Y”), the agent’s own narration of what it just did. These go to the working memory ring so the current session can use them, but they are never written to the fact store, so a question you asked today cannot come back tomorrow disguised as a fact.
  3. Rejected. Never stored anywhere: content matching the privacy blocklist, raw tool output and shell dumps, the agent’s injected prompt scaffolds, oversized dumps, and low-signal chatter.
Rules fire in priority order and the first match wins. Some concrete boundaries: user messages are never length-capped (you typed them on purpose), notes are capped at 800 characters, everything else at 500; longer content is almost always a shell dump, not a fact. A structural analyzer scores every candidate; anything it classifies as chatter, or scoring below a 0.30 quality floor, does not become a durable fact. The filter is deliberately conservative about narration. Only agent-emitted channels are scanned for process narration; content from human channels (messages, documents, calendar events) is never dropped for sounding like narration.

The fact store

Durable facts land in the Binary Memory Core (BMC), the storage engine the brain hosts in-process. A fact is stored as a fixed 64-byte binary record carrying a 256-bit signature derived from its embedding, alongside the verbatim text and its provenance. Search is two-stage: a locality-sensitive hash index proposes candidates by Hamming distance over the bit signatures, then a precise cosine pass over just those candidates re-scores them. Both stages run in-process and synchronously: recall does not cross a network, and typical queries complete in under a millisecond. Nothing in this path leaves your machine. Embeddings are computed locally, and the stores are plain files under ~/.xynthis/bmc/.

The knowledge graph

Alongside the fact store, the brain maintains a temporal knowledge graph of subject-predicate-object triples: (you, prefers, rust), (project, uses, postgres). Extraction is structural (a precedence-ordered pattern table, no LLM call), so it is fast and predictable:
  • Explicit verbs (“chose”, “built”, “prefers”) produce triples at 0.75-0.9 confidence; a bare “is” statement gets 0.45.
  • Hedged statements (“I think”, “maybe”) have their confidence multiplied by 0.6.
  • Negated clauses produce no triple at all.
  • “Ended” phrasing closes the triple’s validity window instead of deleting it.
Every triple carries a validity window and a confidence, so the graph answers as-of queries: what did Xynthis believe about this entity last month? Ended facts stay queryable in their window rather than vanishing.

Working memory

Working memory is a 256-slot ring of the most recent perceptions, held in RAM only. It gives the current session short-term context (including the session-only lane from the filter), and it is the raw material the consolidation cycle and reflection read from. It is never persisted: restart the brain and the ring starts empty. Durable facts are unaffected.

Recall

A recall query walks four layers, cheapest first:
  1. Identity: who you are, standing preferences.
  2. Working memory: the current session’s recent context.
  3. Knowledge graph: matching triples, filtered by validity window.
  4. Binary facts: the two-stage semantic search over the fact store.
Semantic score is not the only signal. A lexical overlap check runs as a floor under the semantic score, so a query that names a thing literally (“rust”, an exact filename) still ranks it first even when the embedding match is weak. This is on by default; set XYNTHIS_LEXICAL_FLOOR=0 to disable it. On top of the base score, a learned reranker nudges results by at most ±0.25, and small recency and frequency terms break ties: a learned signal can reorder close calls but never override a strong direct match.

Per-source trust

Not all memories are equal, and recall knows it. Each fact’s confidence is set at write time from how it was stated: a direct user statement enters near the top of the range, a hedged remark enters lower, and an inference the brain derived on its own enters lower still. That born-with confidence is the largest single component of the trust score attached to every recalled fact, so when a direct statement and a derived guess both match your query, the statement wins. See Truthful memory for the full trust model.

Supersession

Facts change. When a new perception contradicts an existing one (same subject and predicate, conflicting object), the older fact is marked stale, and the consolidation cycle sweeps these markers on every pass. Stale facts stop surfacing in recall: tell Xynthis you switched editors and the old preference retires instead of competing with the new one. The record itself is not destroyed; it is demoted out of the answer set.