A memory link between models.
An agent can write a handover. Drift explores another route: let its partner read translated working memory.
Drift connects frozen language models through their key-value caches. Model-specific taps capture memory, trained translators map it into a form the receiver can use, and the receiver attends to it alongside its own context. The backbone weights stay frozen.
The goal is a choice in your workflow: ordinary text communication, or a Drift memory link over MCDMA. Duo is the first agent integration; the exchange components and tap CLI live here so other workflows can use the same machinery.
Experimental. GLM and Qwen have completed three two-way MCDMA exchanges through a controlled OMP parent/subagent workflow, including a separate linked-cancellation check with both workers reaped. This is a bounded engineering qualification, not a general recall guarantee or a turnkey Duo integration. You can use the CLI, extend adapters and run the local reference today.
Documentation · Current status · CLI guide · Adapter contract
The designated activation channel carries KV tensors and bounded protocol metadata. It does not carry task text or token IDs. Each direction needs a compatible tap, translator and receiver; matching tensor shapes alone is not enough.
MCDMA moves the memory. Drift handles its representation, ownership, sequence and application. The agent runtime still owns tools, local generation and lifecycle.
See the MCDMA repository and its setup guide for the transport. Installing MCDMA alone does not enable Drift's native workflow; the local CLI reference below needs no RDMA hardware.
This is a channel-specific claim. Setup prompts, locally generated tokens and shared repository files still exist, and any text fallback must be declared. A transport acknowledgement is not proof that a model used the memory correctly.
Use Python 3.11–3.13 in a fresh environment. The dependency pins describe the reference build; use an approved PyTorch build for your host and requalify any variation, without upgrading a serving environment in place.
python3 -m venv .venv
. .venv/bin/activate
python -m pip install -e '.[test]'
drift --help
drift adapter list
python -m pytest -qThe reference suite does not need model downloads, a Studio, Sparks or a running MCDMA daemon. Optional runtime tests can skip when their environment is absent; those skips are blocked qualification gates, not passes.
For a small self-handoff check with the random toy model:
mkdir -p local/reference
python scripts/self_handoff.py --out local/reference/self_handoff.jsonThat checks cache mechanics, not language understanding or cross-family recall.
The tap commands inventory two local checkpoints, hash their inputs and check the evidence needed to connect them. These commands do not load the backbone models, train a translator or start remote services.
Replace these paths with your checkpoints and recorded runtime locks. This example uses the built-in Qwen and GLM Torch adapter IDs; their runtime requirements and qualification still apply.
drift tap create my-pair \
--source-checkpoint /models/qwen \
--source-adapter qwen4_exp/torch \
--source-host local \
--source-runtime-lock /locks/qwen.lock \
--target-checkpoint /models/glm \
--target-adapter glm5_next/torch \
--target-host local \
--target-runtime-lock /locks/glm.lock \
--output ./local/taps/my-pair
drift tap status ./local/taps/my-pairWithout qualification reports and translators, this creates a BLOCKED project and tells you which gates are missing. Status checks rehash the project artifacts and inputs rather than trusting a saved verdict. Existing output directories are never overwritten.
| Exit code | Meaning |
|---|---|
0 |
PASSED for the requested operation |
1 |
FAILED |
2 |
BLOCKED, with missing prerequisites reported |
3 |
INVALID request or evidence |
To emit a runnable local manifest, also supply --source-qualification, --target-qualification, --source-translator and --target-translator. Both adapters must qualify against the exact checkpoint and runtime, and both translators must bind to the same pool.v1 format. Different-host projects remain BLOCKED; entering two hostnames does not qualify a distributed run.
Want to add another family? Generate a separate adapter package:
drift adapter scaffold my_model/torch \
--model-type my_model \
--output ./local/drift-adapter-my-modelThe scaffold deliberately starts with a blocked loader. Implement the adapter contract, then qualify it on tiny configurations and real weights. A model name is not a compatibility guarantee, including MiniMax or Nemotron variants.
The full CLI guide covers qualification artifacts, translator inputs and plugin registration.
drift transcript imports an explicitly supplied text conversation, lets local GLM
read it, transfers stripped latent rows over MCDMA, and lets local Qwen answer
from translated memory. This is GLM's memory of the transcript, not the API
model's recovered cache or hidden reasoning.
Start with the completed text-only messages array from your API client, including assistant replies and tool results, in an owner-only directory outside the repo:
drift transcript import --input /private/memory/messages.json \
--provider example --model api-model --conversation-id session-1 \
--output /private/memory/transcript.json
drift transcript validate --input /private/memory/transcript.json
drift transcript --helpFor Python callers, the importer returns the same validated snapshot without intercepting requests or handling provider credentials:
from drift.transcript.importer import from_chat_messages
transcript = from_chat_messages(
[{"role": "user", "content": "Delivery arrives at 10:45."},
{"role": "assistant", "content": "Recorded."}],
provider="example", model="api-model", conversation_id="session-1",
)
receipt = transcript.receipt()The remaining commands are capture on the GLM host, receive over MCDMA on
the Qwen host, and answer using the pinned translator and received memory.
Follow the transcript-memory guide for their
required flags, private files and explicit time budgets; these commands do not
install runtimes, start daemons or recover an API provider's original cache.
The transcript path has passed a native GLM → MCDMA → Qwen smoke check: Qwen recovered all three queried facts from one synthetic conversation, as it did with the full transcript. Without memory it recovered none; with a second conversation's memory it returned that conversation's three different facts. This checks execution and memory dependence on a tiny fixture, not general recall, source attribution or a quality advantage over text.
drift is the shell CLI. /drift is an OMP command registered by the separate omp-drift plugin in this repository, not by Duo.
From this repository's root, link the plugin and restart OMP:
omp plugin link "$PWD/plugin/omp-drift"That adds the command without modifying Duo's source. Configure the local service and authentication described in the plugin guide before using /drift start --reference.
The default command controls the reference service. A separately configured /drift subagent enable now selects a pinned KV-only pair with restricted task admission and repeated exchange boundaries; see the subagent setup and qualification limits. Its installed-OMP fixture passes, but native qualification of this new command remains BLOCKED. It does not turn an existing Duo room into a KV-linked pair or provision MCDMA/inference servers. Earlier native three-epoch and cancellation results used a different control policy; see native exchange evidence.
The reusable exchange core takes a source, link and sink. It owns the cursors, capacity checks and poisoned-session state while runtime adapters own the model caches and transport calls.
Keep that coordinator alive across exchanges. Spawning a new CLI process at each tool boundary loses the state that makes sequencing safe. See the exchange contracts and integration limits before connecting a main agent, subagent or another host runtime.
| Code | Responsibility |
|---|---|
drift/taps/ and drift/cli.py |
Checkpoint inventory, qualification checks and tap projects |
drift/adapters/ and drift/translate/ |
Model-specific taps and memory translators |
drift/exchange/ |
Stateful exchange contracts, live adapters and coordinator |
drift/serving/ |
Native worker sessions, cache application and MCDMA integration |
plugin/omp-drift/ |
OMP commands, worker provider and lifecycle controls |
drift/eval/ and tests/ |
Evaluation machinery and engineering regressions |
Read AGENTS.md, the engineering contracts and current status before changing this repository.
- Read the latest progress and identify the first failing or unimplemented gate. Preserve the M−1 through M6 sequence.
- Inspect the actual runtime and integration source. Do not invent provider APIs, model support, hardware guarantees or measurements.
- Run the baseline tests before code changes, then focused tests and the full suite after a meaningful fix. Keep modules focused and code comments to one line.
- Keep backbone weights frozen and task text off the live activation channel. Stop on corrupted activations, unexplained native parity failures or poisoned sessions.
- Keep private activations, credentials and scorer evidence outside agent-readable project trees. Do not start remote jobs, restart services or change drivers without the required ownership and authorization.
- Record the exact commit, commands, test results, evidence hashes, measured costs and next blocker in
docs/agent-progress.md. UsePASSED,FAILED,BLOCKEDorINVALID, and never count a required skip as a pass.
A green local suite does not establish native recall, source ownership or successful agent collaboration. Do not remove a guard to make a demo run.
Public examples use .invalid hostnames, TEST-NET addresses and example paths. Replace them with verified private configuration and pin the deployed code, model and translator hashes.
Measure transport time, cache application and task success separately. Millisecond delivery does not establish millisecond incorporation, and the exploratory asynchronous loop does not qualify the reference's prior-epoch schedule.
Keep receipts, private activations and credentials out of commits and release archives. The original development history is private; publication uses a separately audited source snapshot.
