Skip to content

Architecture

Bellok edited this page Mar 28, 2026 · 8 revisions

Architecture

Back to Home

This page describes the core design of the Neurodivergent Memory MCP Server: the district model, canonical tag schema, and retrieval/graph operations.


District Model

Memories are partitioned into five cognitive districts that provide intentional context boundaries while still permitting cross-district graph connections.

District Purpose
logical_analysis Analytical reasoning, deductions, structured thinking
emotional_processing Emotional context, tone, affective state
practical_execution Task tracking, action items, procedural steps
vigilant_monitoring Risk awareness, anomalies, watchpoints
creative_synthesis Ideation, patterns, generative associations

The district model is inspired by how neurodivergent cognition naturally partitions attention across parallel, non-linear contexts. Rather than flattening all memories into a single namespace, districts let agents — and humans — scope recall intentionally.

Cross-district connections are fully supported via the graph layer, allowing a memory in creative_synthesis to explicitly relate to one in logical_analysis.


Canonical Tag Schema

All memories use structured tags in four namespaces to improve consistency, discoverability, and retrieval quality.

Namespace Purpose Examples
topic:X Subject matter of the memory topic:release, topic:architecture
scope:X Breadth or boundary of the memory scope:project, scope:session
kind:X Type of cognitive entry kind:decision, kind:observation, kind:plan
layer:X Abstraction level layer:system, layer:agent, layer:user

This schema applies to both human-authored and agent-authored entries, ensuring retrieval quality is consistent regardless of authorship.


Retrieval

BM25 Ranked Lexical Retrieval

The system uses BM25 (Best Match 25) for ranked lexical search over memory content. BM25 weighs term frequency and inverse document frequency, making it well-suited for short, dense memory entries.

Graph Traversal

Memories can be connected via explicit typed relationships. Graph traversal allows the server to:

  • surface associatively linked memories during retrieval,
  • trace chains of related context across districts,
  • and support future goal-aware and orchestration-aware retrieval strategies.

Memory Statistics and Health

The server exposes state and health inspection through memory statistics tools, allowing agents to introspect the current memory store without performing a full retrieval.


Design Philosophy

The architecture is explicitly built for non-linear cognition. Rather than assuming a single flat thread of recall, it:

  1. Partitions context into districts with intentional boundaries.
  2. Applies structured metadata so any entry is independently navigable.
  3. Uses graph relationships to honor associative, non-sequential memory patterns.
  4. Ranks retrieval by relevance rather than insertion order.

This makes the system natural for neurodivergent users and well-suited for multi-agent workflows where different agents operate in different cognitive modes simultaneously.


See also: Release-Notes · Roadmap · White-Paper

Home


Setup

Reference

Reports


v0.3.0 · Research Preview

npm · Docker Hub · GHCR

Clone this wiki locally