Documentation

Read the source code of your memory.

Docs / mcp-tools / memory-tools

memory.* tools

5 tools for knowledge storage, search, context building, and entity lookup.

The memory.* namespace is the simplest way to use Orion. No agent identity required — connect and start storing knowledge immediately.

Progression model: Start with memory.* alone (Orion as a persistent store). Add Galaxy structure for typed, searchable knowledge. Graduate to brain.* for expertise accumulation and model continuity.

memory.write

Store a knowledge record. Auto-extracts entities, checks for contradictions, and indexes for semantic search. If planet is omitted, Orion routes the record to the best-matching Planet automatically.

content     string, required   The knowledge to store
planet      string, optional   Target planet (auto-routed if omitted)
biome       string, optional   Target biome (created if new)
region      string, optional   Cognitive region (default: "contextual")
confidence  float, optional    0.0–1.0 (default: 0.5)
tags        string[], optional Context tags for filtering
gravity     string, optional   BIOME | PLANET | GALAXY (default: BIOME)

Response:

{
  "stardust_id": "sd-abc123",
  "biome_name": "Database Migration",
  "entities_extracted": ["PostgreSQL", "MySQL"],
  "contradictions_detected": 0,
  "orion_confirmation": "✦ Stored in Database Migration (analytical) — 47 records today"
}

memory.search

Semantic search using RRF fusion across keyword cache, vector similarity, and graph traversal.

query   string, required   Natural language search query
planet  string, optional   Restrict to a planet
biome   string, optional   Restrict to a biome
region  string, optional   Restrict to a cognitive region
limit   int, optional      Max results (default: 5, max: 50)

Response:

{
  "records": [
    {
      "id": "sd-abc123",
      "content": "We chose PostgreSQL over MySQL for better JSON support...",
      "region": "analytical",
      "confidence": 0.85,
      "biome_name": "Database Migration"
    }
  ],
  "retrieval_metadata": {
    "sources_checked": ["redis_cache", "chroma_analytical", "chroma_procedural"],
    "cache_hits": 1,
    "total_records_considered": 42,
    "retrieval_latency_ms": 127
  }
}

memory.context

Build a structured context bundle sized to a token budget. Returns Sun context, planet knowledge, biome stardust, and recent entities — prioritized by confidence and recency. Use this to populate an agent's context window efficiently.

planet      string, optional   Focus planet
biome       string, optional   Focus biome
max_tokens  int, optional      Token budget (default: 4000)

When to use memory.context vs memory.search: memory.context builds a comprehensive context bundle (Sun + planet + biome + entities) within a token budget. memory.search finds specific records matching a query. Use context at session start to load broad context; use search during work to find specific knowledge.

memory.status

Galaxy health overview. No parameters.

Response:

{
  "galaxy_name": "Software Engineer's Galaxy",
  "strength_score": 73.4,
  "total_stardust": 3247,
  "total_entities": 189,
  "contradiction_count_unresolved": 3,
  "planets": [
    {"name": "Engineering", "stardust_count": 2891, "health_status": "healthy"}
  ]
}

memory.entity_get

Look up an entity's profile — type, tier, relationships, and timeline.

entity_name  string, required

Response:

{
  "name": "PostgreSQL",
  "type": "technology",
  "tier": 3,
  "mention_count": 47,
  "relationships": [
    {"target": "Redis", "type": "WORKS_WITH", "confidence": 0.8},
    {"target": "MySQL", "type": "REPLACES", "confidence": 0.9}
  ]
}