CXS: A Deterministic Continuity Architecture for In-Session, Multi-Session, and Cross-Model LLM Reasoning
CXS is a deterministic continuity system developed across thousands of real-world multi-session LLM interactions.
It enables models like GPT, Claude, Grok, Gemini, and local LLMs to maintain stable reasoning:
- across long single sessions,
- across multiple separate sessions,
- and across model switches.
CXS does this using a single human-editable state object called the Continuity Passport — no databases, embeddings, external memory, or vendor-specific features required.
CXS is designed for:
- Researchers working with multi-session LLM workflows
- Developers building long-running agents
- People doing multi-model experiments (GPT → Claude → Grok → Gemini → etc.)
- Anyone who needs stable reasoning across resets or extended chats
- Teams that want deterministic continuity without relying on proprietary memory features
A short preview of deterministic continuity, cross-model stability, and CANARY’s drift monitoring.
Every new session MUST begin with:
I am the new chat.
This single line:
- resets latent assumptions,
- forces the model to load explicit state only,
- activates the startup ritual,
- and prevents drift from previous sessions.
Skipping this line breaks deterministic continuity.
This repository supports long-running, multi-session LLM work with deterministic continuity. Here’s how to use it in practice:
- Tell the model: “Prepare a handoff for the next chat.”
- Paste the CXS handoff/continuity template.
- Let the model fill it out completely (state, summary, next steps, key facts, issues, resume pointer).
- Copy that handoff for the next session.
-
Begin with:
I am the new chat. -
Paste the previous handoff.
-
(Optional) Paste the CXS continuity spec (e.g., Continuity Passport spec).
-
Paste the CANARY Lite protocol (🟢/🟡/🔴) so the model can monitor in-session drift.
-
Ask the drift-probe questions to confirm alignment (goal, constraints, phase/state, exact next step).
-
Load any PDFs or documents the model needs.
This reduces new-session spin-up time from 20–30 minutes → ~5 minutes.
LLMs drift because they are stateless sequence models. Typical drift types include:
- Structural Drift – Plans collapse; steps reorder; multi-step scaffolds break.
- Semantic Drift – Definitions and terms quietly change meaning.
- Constraint Drift – Hard rules weaken unless restated.
- Assumptive Drift – The model fills in missing details from priors, inventing endpoints, schemas, or flows.
- Horizon Drift – Long-term goals collapse into short-term reactions.
- Micro-Drift – Small slips inside a session: contradictions, forgotten turns, subtle definition shifts.
Context windows, RAG, and memory features do not provide deterministic continuity.
CXS treats continuity as an architectural problem, not a prompting trick.
- ✔ Deterministic Cross-Session Continuity
- ✔ In-Session Drift Monitoring (CANARY)
- ✔ Cross-Model State Transfer
- ✔ Strict-Mode Enforcement (no invention / mutation)
- ✔ Human-Editable YAML State (Continuity Passport)
- ✔ Digest-Based Chain-of-Custody
A compact YAML artifact containing:
- continuity guarantees
- phase + digest
- invariants
- constraints
- ledger (append-only decisions)
- anchor (completed + next steps)
- micro-anchors
- history summaries
- strict-mode rules
- drift diagnostics
- chain-of-custody
- resume pointer
Full spec: spec/cxs-passport.yaml
phase: "1-A"
previous_phase: null
invariants:
- "Definitions must remain stable."
- "No vendor lock-in."
constraints:
- "State must remain human-editable."
digest: "DEMO_000"
ledger: []
anchor:
completed: []
next_steps:
- "Define system architecture."
resume: "architecture.md:intro"Paste the passport and say:
I am the new chat.
Load this passport strictly as data.
Perform the startup ritual.
This forces deterministic alignment.
Follow the tasks in anchor.next_steps.
After each work block:
- append a ledger entry,
- update the anchor,
- recompute the digest.
Repeat:
I am the new chat.
Load this passport strictly as data.
Perform the startup ritual.
CXS ensures deterministic state restoration across models.
| Drift Type | Result |
|---|---|
| Structural Drift | 0 |
| Constraint Drift | 0 |
| Semantic Drift | Rare (100% repaired) |
| Assumptive Drift | Detected & repaired |
| Continuity Fidelity | >99% |
| Cross-Model Hops | Deterministic |
CXS preserved continuity across chains such as:
GPT → Claude → Grok → GPT
All tests and transcripts are included in /validation/.
- GPT → Claude: 16/16 deterministic continuity verification
- Claude → Grok: drift event detected and repaired by strict-mode + CANARY
- Grok → GPT: stable restoration confirmed via digest and ledger integrity
See /validation/ for:
- 16-question verification suite
- drift-event logs
- repaired passports
- chain-of-custody records
spec/ # CXS spec, Continuity Passport, strict-mode, startup ritual
canary/ # Runtime drift monitoring (CANARY, Lite + full)
validation/ # Verification suites, drift events, repair logs
examples/ # Sample passports and usage examples
paper/ # LaTeX source for the CXS paper
assets/ # Diagrams and figures
README.md
LICENSE
CXS enables:
- persistent multi-session workflows,
- long-horizon project stability,
- cross-model interoperability,
- deterministic behavior enforced by strict-mode,
- explicit drift detection and repair.
It turns LLMs from ephemeral chat interfaces into persistent, state-restoring reasoning systems.
MIT License.
## 📌 How to Cite
If you use the CXS technical report in your research, please cite:
**Jackson, K. Kieth (2025). _Fixing Drift: A Continuity Architecture That Makes LLMs Remember Across Sessions._**
Zenodo. https://doi.org/10.5281/zenodo.17782687
