Context from Tape
A unified fact model for long-running, multi-team work.
It also extends to observability, eval, and training.
Practiced in bub.build, view source
The Minimal Model
Four core primitives
History is append-only, never overwritten
Derivatives never replace original facts
Context is constructed, not inherited wholesale
Append
The sole operation that mutates facts — writing to the tape’s tail
Order is trackable via monotonic IDs
Old facts cannot be modified in-place
Corrections are made by appending, not deleting
Anchor
A reconstruction marker, not a deletion point
Full history preserved before the anchor
Rebuild from anchor, skip full scans
Anchors can carry structured state payloads
Handoff
A constrained phase transition
Write a new anchor
Attach minimum inherited state
Shift execution origin past the new anchor
{ phase: "implement",
summary: "Discovery complete.",
next_steps: ["Run migration", "Integration tests"],
source_ids: [128, 130, 131],
owner: "agent" }Session Modeling
Defining the boundaries of context selection
Single Session
Entries share one timeline
Multi-turn
Assembled from latest anchor
Multi-session
Independent timelines; cross-session is opt-in
Topic Threading
Each topic binds an anchor; repeats trigger recall
Context Strategies
Three mechanism combos for compact, summary, and fork-merge
Compact
problemContext exceeds the window limit
key:compact ≠ delete history; shrink default read set
Summary
problemNeed a high-level overview for the next phase
key:Summaries cite sources; hints only
Fork / Merge
problemNeed parallel exploration with controlled convergence
key:Merge appends deltas only; no mainline rewrites
Memory
Complex memory assembled from anchor graphs
Anchors can form non-linear graphs, not a single timeline
Memory views assemble from multiple nodes, guided by policy
Graph structure requires explicit lineage and provenance
Teams
Teams coordinate via shared tapes and cross-tape views.
Shared Tape
Multiple agents append the same tape; entries keep their origin
Append-only; ownership remains traceable
Cross-Tape View
Teams read each other's tapes via views to coordinate
Views are assembled; tapes remain isolated
Appendix
Three extensions: observability, eval, and training.
Observability
Tape can retain sessions, tool calls, and events for a replayable web timeline.
The UI is a derived view; raw facts remain in the append-only tape.
refbubEval
Slice by anchor, replay history, inspect decisions, then write scores and labels back as derived facts.
Show the path and decisions to people first, then append derived annotations.
refPhoenixTraining / RL
Tape works with frameworks such as AReaL: slice by anchor, attach rewards, and export trajectories.
The training layer should consume tape exports, not replace tape as the raw record.
refopenclaw exampleConclusion
Placing context problems back into this model yields a stable research framework