Fix beads architecture: two tiers with persistent+ephemeral each

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 <noreply@anthropic.com>
This commit is contained in:
Steve Yegge
2025-12-23 14:35:03 -08:00
parent 804dc75722
commit 774bed3fba

View File

@@ -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. 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/ TOWN LEVEL
│ ───────────────────────────────────────────────────────── │ ══════════════════════════════════════════════════════════════════════════
│ Prefix: hq-* │
│ Git tracked: Yes │ ┌─────────────────────────────────┐ ┌─────────────────────────────────┐
Contains: PERSISTENT: ~/gt/.beads/ EPHEMERAL: ~/gt/.beads-wisp/
- All mail (cross-agent communication) ───────────────────────────── │ │ ─────────────────────────────
- Mayor coordination issues Prefix: hq-* Git tracked: NO
- Deacon patrol wisps (town-level ephemeral work) Git tracked: Yes │ │ Contains:
- Cross-rig work items Contains: - Deacon patrol cycles
Sync: Direct commit to main (single location) - All mail - Town-level ephemeral work
└─────────────────────────────────────────────────────────────┘ │ - Mayor coordination │ │ Lifecycle: │
│ - Cross-rig work items │ │ Created → Executed →
│ gt mail commands auto-route here Sync: Direct commit to main │ │ Squashed to digest → Deleted │
└─────────────────────────────────┘ └─────────────────────────────────┘
┌─────────────────────────────────────────────────────────────┐
│ RIG LEVEL: ~/gt/<rig>/crew/<name>/.beads/ │ ══════════════════════════════════════════════════════════════════════════
│ ───────────────────────────────────────────────────────── │ RIG LEVEL
│ Prefix: gt-* (or rig-specific) │ ══════════════════════════════════════════════════════════════════════════
│ Git tracked: Yes (via beads-sync branch) │
│ Contains: │ ┌─────────────────────────────────┐ ┌─────────────────────────────────┐
- Project issues (bugs, features, tasks) PERSISTENT: <clone>/.beads/ EPHEMERAL: <rig>/.beads-wisp/
- Molecules (work patterns) ───────────────────────────── │ │ ─────────────────────────────
- Agent hook states (pinned molecules) Prefix: gt-* (rig-specific) │ │ Git tracked: NO
Sync: Via beads-sync branch (multiple clones) Git tracked: Yes │ │ Contains:
└─────────────────────────────────────────────────────────────┘ │ Contains: │ │ - Witness patrol cycles │
- Project issues │ │ - Refinery patrol cycles
│ Ephemeral patrol state (not synced) - Molecules (work patterns) │ │ - Rig-level ephemeral work │
- Agent hook states │ │ Lifecycle: │
┌─────────────────────────────────────────────────────────────┐ │ Sync: Via beads-sync branch │ │ Created → Executed → │
RIG WISPS: ~/gt/<rig>/.beads-wisp/ Squashed to digest → Deleted
───────────────────────────────────────────────────────── │ └─────────────────────────────────┘ ─────────────────────────────────
│ Git tracked: NO (gitignored) │
│ Contains: │
│ - Witness patrol cycles │
│ - Refinery patrol cycles │
│ - Any rig-level ephemeral molecule execution │
│ Lifecycle: Created → Executed → Squashed to digest → Deleted│
└─────────────────────────────────────────────────────────────┘
``` ```
Key points: Key points:
- **Mail uses town beads** (`~/gt/.beads/`) - `gt mail` routes automatically - **Each level has persistent + ephemeral storage**
- **Deacon uses town beads** - town-level role, no rig dependency - **Town persistent** (`~/gt/.beads/`) - mail, mayor work, cross-rig coordination
- **Project work uses rig beads** (in your clone) - `bd` commands use local `.beads/` - **Town ephemeral** (`~/gt/.beads-wisp/`) - deacon patrols
- **Patrol wisps use rig wisp storage** - ephemeral, never synced, squashed after cycles - **Rig persistent** (`<clone>/.beads/`) - project issues, molecules, hooks
- **Different sync strategies**: Town is single-writer, rig uses branch-based sync, wisps don't sync - **Rig ephemeral** (`<rig>/.beads-wisp/`) - witness/refinery patrols
- **Sync strategies**: Persistent beads sync via git; ephemeral wisps never sync
## The Query Model ## The Query Model