From 774bed3fba50adbab222729afd4e49b2413951ab Mon Sep 17 00:00:00 2001 From: Steve Yegge Date: Tue, 23 Dec 2025 14:35:03 -0800 Subject: [PATCH] Fix beads architecture: two tiers with persistent+ephemeral each MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Corrected from 'three-tier' to 'two-tier' model: - Town level: persistent (.beads/) + ephemeral (.beads-wisp/) - Rig level: persistent (.beads/) + ephemeral (.beads-wisp/) Each tier has both durable and wisp storage, not three separate tiers. πŸ€– Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- docs/beads-data-plane.md | 86 +++++++++++++++++++--------------------- 1 file changed, 40 insertions(+), 46 deletions(-) diff --git a/docs/beads-data-plane.md b/docs/beads-data-plane.md index 7423f25e..4689e988 100644 --- a/docs/beads-data-plane.md +++ b/docs/beads-data-plane.md @@ -112,58 +112,52 @@ How does the system know if an issue is mail or work? The `from:` label is the canonical discriminator. Regular issues don't have senders. -## Three-Tier Beads Architecture +## Two-Tier Beads Architecture -Gas Town uses beads at three tiers - two persistent, one ephemeral: +Gas Town uses beads at two levels, each with persistent and ephemeral components: ``` -β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” -β”‚ TOWN LEVEL: ~/gt/.beads/ β”‚ -β”‚ ───────────────────────────────────────────────────────── β”‚ -β”‚ Prefix: hq-* β”‚ -β”‚ Git tracked: Yes β”‚ -β”‚ Contains: β”‚ -β”‚ - All mail (cross-agent communication) β”‚ -β”‚ - Mayor coordination issues β”‚ -β”‚ - Deacon patrol wisps (town-level ephemeral work) β”‚ -β”‚ - Cross-rig work items β”‚ -β”‚ Sync: Direct commit to main (single location) β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - β”‚ - β”‚ gt mail commands auto-route here - β–Ό -β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” -β”‚ RIG LEVEL: ~/gt//crew//.beads/ β”‚ -β”‚ ───────────────────────────────────────────────────────── β”‚ -β”‚ Prefix: gt-* (or rig-specific) β”‚ -β”‚ Git tracked: Yes (via beads-sync branch) β”‚ -β”‚ Contains: β”‚ -β”‚ - Project issues (bugs, features, tasks) β”‚ -β”‚ - Molecules (work patterns) β”‚ -β”‚ - Agent hook states (pinned molecules) β”‚ -β”‚ Sync: Via beads-sync branch (multiple clones) β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - β”‚ - β”‚ Ephemeral patrol state (not synced) - β–Ό -β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” -β”‚ RIG WISPS: ~/gt//.beads-wisp/ β”‚ -β”‚ ───────────────────────────────────────────────────────── β”‚ -β”‚ Git tracked: NO (gitignored) β”‚ -β”‚ Contains: β”‚ -β”‚ - Witness patrol cycles β”‚ -β”‚ - Refinery patrol cycles β”‚ -β”‚ - Any rig-level ephemeral molecule execution β”‚ -β”‚ Lifecycle: Created β†’ Executed β†’ Squashed to digest β†’ Deletedβ”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ +══════════════════════════════════════════════════════════════════════════ + TOWN LEVEL +══════════════════════════════════════════════════════════════════════════ + +β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” +β”‚ PERSISTENT: ~/gt/.beads/ β”‚ β”‚ EPHEMERAL: ~/gt/.beads-wisp/ β”‚ +β”‚ ───────────────────────────── β”‚ β”‚ ───────────────────────────── β”‚ +β”‚ Prefix: hq-* β”‚ β”‚ Git tracked: NO β”‚ +β”‚ Git tracked: Yes β”‚ β”‚ Contains: β”‚ +β”‚ Contains: β”‚ β”‚ - Deacon patrol cycles β”‚ +β”‚ - All mail β”‚ β”‚ - Town-level ephemeral work β”‚ +β”‚ - Mayor coordination β”‚ β”‚ Lifecycle: β”‚ +β”‚ - Cross-rig work items β”‚ β”‚ Created β†’ Executed β†’ β”‚ +β”‚ Sync: Direct commit to main β”‚ β”‚ Squashed to digest β†’ Deleted β”‚ +β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ + +══════════════════════════════════════════════════════════════════════════ + RIG LEVEL +══════════════════════════════════════════════════════════════════════════ + +β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” +β”‚ PERSISTENT: /.beads/ β”‚ β”‚ EPHEMERAL: /.beads-wisp/ β”‚ +β”‚ ───────────────────────────── β”‚ β”‚ ───────────────────────────── β”‚ +β”‚ Prefix: gt-* (rig-specific) β”‚ β”‚ Git tracked: NO β”‚ +β”‚ Git tracked: Yes β”‚ β”‚ Contains: β”‚ +β”‚ Contains: β”‚ β”‚ - Witness patrol cycles β”‚ +β”‚ - Project issues β”‚ β”‚ - Refinery patrol cycles β”‚ +β”‚ - Molecules (work patterns) β”‚ β”‚ - Rig-level ephemeral work β”‚ +β”‚ - Agent hook states β”‚ β”‚ Lifecycle: β”‚ +β”‚ Sync: Via beads-sync branch β”‚ β”‚ Created β†’ Executed β†’ β”‚ +β”‚ β”‚ β”‚ Squashed to digest β†’ Deleted β”‚ +β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` Key points: -- **Mail uses town beads** (`~/gt/.beads/`) - `gt mail` routes automatically -- **Deacon uses town beads** - town-level role, no rig dependency -- **Project work uses rig beads** (in your clone) - `bd` commands use local `.beads/` -- **Patrol wisps use rig wisp storage** - ephemeral, never synced, squashed after cycles -- **Different sync strategies**: Town is single-writer, rig uses branch-based sync, wisps don't sync +- **Each level has persistent + ephemeral storage** +- **Town persistent** (`~/gt/.beads/`) - mail, mayor work, cross-rig coordination +- **Town ephemeral** (`~/gt/.beads-wisp/`) - deacon patrols +- **Rig persistent** (`/.beads/`) - project issues, molecules, hooks +- **Rig ephemeral** (`/.beads-wisp/`) - witness/refinery patrols +- **Sync strategies**: Persistent beads sync via git; ephemeral wisps never sync ## The Query Model