MemoryLayer
  • How it works
  • Arena
  • Benchmarks
  • Registry
  • Pricing
  • Docs
Log inGet started free
  • 01Arena
  • 02Benchmarks
  • 03Registry
  • 04Pricing
  • 05Docs
Log inGet started free

Docs

Docs home

Getting started

  • Quickstart
  • Claude Code
  • Cursor

Learn

  • How memory works
  • Search & recall
  • Shared across agents
  • Grounded facts
    1. Three verdicts
    2. What to ground
    3. Ground a fact
    4. Ground your docs
    5. Check claims
    6. Manage domains

Reference

  • MCP tools
  • Agent rules
  • Bookmarks
  • Registry & CLI

Help

  • FAQ
← Shared across agentsMCP tools →
Docs home

Getting started

  • Quickstart
  • Claude Code
  • Cursor

Learn

  • How memory works
  • Search & recall
  • Shared across agents
  • Grounded facts
    1. Three verdicts
    2. What to ground
    3. Ground a fact
    4. Ground your docs
    5. Check claims
    6. Manage domains

Reference

  • MCP tools
  • Agent rules
  • Bookmarks
  • Registry & CLI

Help

  • FAQ

Docs/Learn

Learn

Grounded facts

Add a domainto a memory and MemoryLayer can tell your agent when a claim contradicts it — not just that it couldn't find it.

Three verdicts

verify({ text }) → one verdict per claim

grounded

A stored fact confirms it

“Pro costs $19 a month”

refuted

A stored fact contradicts it

“Pro gets 10,000 calls a month”

unsupported

Nothing stored says either way

“Pro includes SSO”

Refuted is the one plain recall can’t give you: not “I couldn’t find it”, but “this contradicts what I know”.

A plain memory can only back a claim up. A grounded one is also turned into subject → relation → object facts that a Z3 solver can reason over, which is what makes refuted possible: a wrong number becomes a visible failure instead of a quiet guess.

What to ground

ground it

Facts that must stay true

  • Architecture invariants
  • Pricing and plan rules
  • Security boundaries and API contracts
  • Deliberate decisions — "SQLite, not Postgres"

leave it plain

Anything loose or hedged

  • Marketing copy and long prose
  • Text that contradicts itself
  • Guesses, "usually", "probably"

Solver facts are strict — fuzzy input makes every later check noisy.

Ground a fact

remember with a domain
remember({content: "The HNSW index is always reconstructable from the embeddings table.",domain: "architecture",tags: ["arch", "constraint"],priority: 10,namespace: "my-project"})

It's stored as a normal memory and promoted to solver facts straight away. For facts you're less sure of, pass promote_immediately: false and let them earn their place through repeat confirmation.

Ground your docs

Pass a domain when you index a folder of Markdown — ADRs, design principles, architecture notes. Only prose is grounded; code bodies never are.

code(ingest) with a domain
code({action: "ingest",path: "./docs",domain: "architecture",ground_immediately: true,namespace: "my-project"})

Check claims

verify splits text into claims and judges each one. Agents are reminded to run it before stating facts; you can call it any time.

verify
verify({text: "The HNSW index persists across restarts. It is rebuilt from the embeddings table.",domain: "architecture"})// claim 1 → refuted// claim 2 → grounded

For one precise relation — "is A a B?", "does A call B?" — prove returns proved, refuted or unknown with a certificate of the facts it used.

prove
prove({ claim: "HNSW index is durable state", domain: "architecture" })// → { verdict: "refuted", certificate: { axioms_used, proof_steps } }

Manage domains

domain
domain({ action: "load", source: "./domains/architecture.domain" })domain({ action: "status", name: "architecture" })   // fact count, modedomain({ action: "export", name: "architecture" })   // back to a file, for git
← PreviousShared across agentsNext →MCP tools

Something missing or wrong? Email support@memorylayer.in or open an issue.