Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

docs(memory): update README to reflect current driver architecture

Steven Enamakel7673c7975638
diff --git a/crates/openhuman-core/src/memory/driver/README.md b/crates/openhuman-core/src/memory/driver/README.md
index 20d90d1833..997774c831 100644
--- a/crates/openhuman-core/src/memory/driver/README.md
+++ b/crates/openhuman-core/src/memory/driver/README.md
@@ -1,57 +1,40 @@
# memory/driver
-A one-file namespace that documents where the memory driver seam lives, and
-why there is no engine code in this directory.
-
-## Why this folder is nearly empty
-
-`mod.rs` is a module-level doc comment and nothing else. Memory execution runs
-as a compiled TinyMemory TinyBus module, so there is no in-process engine
-driver to put here. The host-side half of the driver contract is split across
-two files that already existed before this folder did:
-
-- [`memory/api.rs`](../api.rs): the tinybus module contract, a re-export of
- `tinymemory_api` naming only what actually crosses the bus between this host
- and the TinyMemory module.
-- [`memory/binding.rs`](../binding.rs): `admit()`, which reads
- `MemorySubsystemConfig` and decides which driver actually binds for a
- workspace.
-
-## The pluggable-engine story, as implemented today
-
-This is where OpenHuman's "pluggable memory engines" pillar lives, and the
-honest version is narrower than the config surface suggests. `tinymemory-api`
-(vendored at `vendor/tinymemory/`) defines a driver-neutral `MemoryProvider`
-trait and ships adapter crates for six remote engines under
-`vendor/tinymemory/crates/tinymemory-remote/`: Supermemory, Mem0, Cognee,
-CortexDB, AgentMemory, and LivingBrain.
-
-`binding::admit` does not wire any of those in yet. It only accepts the
-compiled TinyMemory module (registry id `tinymemory`, with `tinycortex` kept
-as a legacy config alias) or the `null` fallback provider
-(`tinymemory_api::null::NullMemoryProvider`). A driver id configured under
-`[subsystems.memory.drivers.<id>]` other than those is refused with "external
-driver transport is not implemented yet." In practice, TinyCortex (the
-compiled TinyMemory module) is the memory engine every OpenHuman install runs.
-
-The `[subsystems.memory]` config block already parses and persists ahead of
-that wiring:
-
-```toml
-[subsystems.memory]
-driver = "tinycortex"
-```
-
-`OPENHUMAN_MEMORY_DRIVER` overrides `driver` at the environment level (see
-`config/schema/load/env_overlay/subsystems_update.rs`). Both exist today so
-the shape is stable once a non-default driver actually switches engines;
-neither one does that yet.
+The memory-driver namespace. It exists to hold a place in the module tree, not
+to hold code: `mod.rs` is five lines, and none of them define a driver.
+
+## Why it is nearly empty
+
+Memory execution is provided by the compiled TinyMemory TinyBus module, the
+same native `cdylib` that backs [`crate::modules::memory`](../../modules/memory/README.md).
+There is intentionally no in-process engine driver here. Earlier revisions of
+this core linked `tinymemory-core` directly and picked between embedded
+engines in process; that class of driver is gone, and this directory is what
+is left of the namespace it used to occupy.
+
+The host-side contract and binding live one level up, in
+[`memory::api`](../api.rs) (the bus vocabulary, re-exported from
+`tinymemory_api`) and [`memory::binding`](../binding.rs) (the
+workspace-keyed `for_config` lookup that resolves which driver backs a given
+workspace, reached through `CoreContext::memory_binding`). Both are described
+in the top-level [`memory/README.md`](../README.md#wiring).
+
+## Pluggable engines
+
+Memory is one of this project's pluggable-engine subsystems: the driver a
+workspace binds to is chosen by config (`[subsystems.memory] driver`, or
+`OPENHUMAN_MEMORY_DRIVER`), not compiled in. TinyCortex is the engine embedded
+by default; remote engines such as Supermemory, Mem0, Cognee, CortexDB,
+AgentMemory, and LivingBrain are reached the same way, through the
+`tinymemory-api` contract rather than a driver-specific code path. See
+[engines.md](../../../../../gitbooks/developing/engines.md) for how engine
+selection works across subsystems.
## Where next
-- `gitbooks/developing/engines.md` for the cross-cutting pluggable-engines
- page (LLM providers, embeddings, memory, web search) and the current state
- of this seam in one place.
-- [`memory/binding_admission_tests.rs`](../binding_admission_tests.rs) for the
- admission behavior this README describes.
-- [`memory/README.md`](../README.md) for the memory domain as a whole.
+- [`memory/README.md`](../README.md) for the full split between this host and
+ the extracted `tinymemory-core` engine crate.
+- [`memory/binding.rs`](../binding.rs) for the workspace-to-driver cache and
+ its fail-closed rules (`docs/specs/kernel.md` §3.1, §3.4, §3.7).
+- [`modules/memory`](../../modules/memory/README.md) for the module-loading
+ side: how the TinyMemory `cdylib` is admitted and reached over the bus.