Structure that remembers why.
Ontology + Reflection + Daemon + MCP — encode what your codebase IS (invariants, tensions, constraints) and what it DOES (operational modes, actor flows, config seals) in machine-queryable directed acyclic graphs. First-class web UI (10 pages), MCP server (19 tools), and live session sharing for AI agents. One protocol for developers, agents, and CI.
Protocol + Runtime. Zero enforcement.
.ontology/ as DAG: nodes, edges, invariants, tensions, gatespre_commit, drift, ontology_drift signals block until acknowledgedThe protocol lives in coexistence.
.ontology/ · adrs/ · reflection/schemas/adr · register · config · backlog · forms · describeontoref · actor detection · advisory locking · ONTOREF_IMPORT_PATHnickel export. ontoref-daemon · ontoref-ontology · ontoref-reflection · search engine · notification barrier · SurrealDB (optional).ontoref/config.ncl · scripts/ontoref · adopt_ontoref mode .ontology/ data. Ontoref provides the schemas, modules, and migration scripts. Zero lock-in. .ontology/ NCL files as typed Rust structsstratum-graph + stratum-state required; platform-nats feature-gatedstore.nu — SurrealDB-backed cache with NCL exportsync.nu — ontology code synchronizationdescribe.nu — actor-aware project self-knowledgecoder.nu — structured session recordspre_commit · drift · ontology_drift — pre-commit hook polls & blocks on ack./ontoref dispatched server-side, shared across actorsnotify): passive drift observer, no polling--db): actor sessions, seeded ontology tables, search index, notification history — fail-opennickel export on unchanged filesdb + nats feature flags — builds standalone with --no-default-features The adopt_ontoref mode wires up any existing project in one command.
ontoref-daemon is an optional persistent process. It caches NCL exports, serves 10 UI pages, exposes 19 MCP tools, maintains an actor registry, stores notifications, indexes everything for search, and optionally persists to SurrealDB. It never changes the protocol — it accelerates and shares access to it.
| Tool | Description |
|---|---|
| ontoref_help | List available tools and usage |
| ontoref_list_projects | Enumerate all registered projects |
| ontoref_set_project | Set session default project context |
| ontoref_project_status | Full project dashboard — health, drift, actors |
| ontoref_describe | Architecture overview and self-description |
| ontoref_search | Free-text search across nodes, ADRs, modes |
| ontoref_get | Fetch ontology node by id |
| ontoref_get_node | Full ontology node with edges and constraints |
| ontoref_list_adrs | List ADRs filtered by status |
| ontoref_get_adr | Full ADR content with constraints |
| ontoref_list_modes | List all reflection modes |
| ontoref_get_mode | Mode DAG contract — steps, preconditions, postconditions |
| ontoref_get_backlog | Backlog items filtered by status |
| ontoref_backlog | Add or update_status on a backlog item |
| ontoref_constraints | All hard + soft architectural constraints |
| ontoref_qa_list | List Q&A knowledge store with optional filter |
| ontoref_qa_add | Persist new Q&A entry to reflection/qa.ncl |
| ontoref_action_list | Quick actions catalog from .ontoref/config.ncl |
| ontoref_action_add | Create reflection mode + register as quick action |
--db feature flag and --db-url ws://...--db: DashMap-backed in-memory, process-lifetime only--db-namespace; credentials via --db-username/--db-passwordGET /notifications/pending?token=X&project=Y; blocks git commit until all ackedPOST /notifications/ack; custom notifications via POST /{slug}/notifications/emitForce-directed D3 graph of the live ontology. Nodes are typed (Axiom · Tension · Practice) and polarized (Yang · Yin · Spiral). Click any node to open its detail panel — artifacts, connections, NCL source.

Start with adopt_ontoref. Your project gains machine-queryable invariants, living ADRs, actor-aware operational modes, and a daemon that shares context across every actor in real time.