This is a public snapshot of the 1Context state-machine and typed-control-fabric experiments from the private-4 line of work.
The original private repository contains credentials history and local runtime material, so this repo is intentionally published as a clean split: no private repo history, no local account files, no runtime ledgers, and no personal wiki/talk archives.
- A Python state-machine DSL for durable agent workflows.
- Typed runtime models for queueing, transitions, retries, supervision, and evidence receipts.
- Mermaid and Markdown diagrams for the memory-system control loop.
- Tests covering queue persistence, transition selection, production verification, runtime execution, and restartable scope state.
- Typed Control Fabric design notes in
docs/.
Agent work is not made trustworthy by pretending cognition is deterministic. It becomes trustworthy when the institution around cognition is deterministic:
facts -> signals -> route plans -> guarded jobs -> evidence -> persisted state
The control fabric makes each step inspectable, resumable, and testable.
docs/typed-control-fabric-architecture.mdsrc/onectx/state_machines/memory/plugins/base-memory-v1/state_machines/memory/plugins/base-memory-v1/diagrams/state-machine-control-loop.mdtests/test_state_machine_runtime.pytests/test_state_machine_queue.pytests/test_state_machine_production.py
uv run pytest tests/test_state_machine_*.py tests/test_memory_replay.py