From e068ac574f6cdd1b7660f4b9dff53bdc5fe1ca14 Mon Sep 17 00:00:00 2001 From: Steve Yegge Date: Thu, 25 Dec 2025 01:49:57 -0800 Subject: [PATCH] refactor: Simplify wisp architecture - badges not separate storage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Wisps are now just issues with Wisp=true flag in the main database, not exported to JSONL. Removes all references to .beads-wisp/ directory. - Update docs: CLAUDE.md, CLI_REFERENCE.md, MOLECULES.md, DELETIONS.md - Update code comments: wisp.go - Update changelog and info.go version notes đŸ¤– Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- CHANGELOG.md | 6 +++--- CLAUDE.md | 4 ++-- cmd/bd/info.go | 2 +- cmd/bd/wisp.go | 8 ++++---- docs/CLI_REFERENCE.md | 2 +- docs/DELETIONS.md | 5 ++--- docs/MOLECULES.md | 2 +- 7 files changed, 14 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bfe2c81b..0edf2d2f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -275,13 +275,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - `bd wisp create ` - Instantiate proto as ephemeral wisp (solid→vapor) - `bd wisp list` - List all wisps with stale detection - `bd wisp gc` - Garbage collect orphaned wisps - - Wisps live in `.beads-wisp/` (gitignored), never sync to remote + - Wisps have Wisp=true flag and are not exported to JSONL (never sync) - **Chemistry UX commands** - Phase-aware molecule operations - `bd pour ` - Instantiate proto as persistent mol (solid→liquid) - `bd mol bond --wisp` - Force spawn as vapor when attaching to mol - `bd mol bond --pour` - Force spawn as liquid when attaching to wisp - - Cross-store squash: condense wisp to digest in main storage + - Squash clears Wisp flag, promoting to persistent (exported to JSONL) - **Cross-project dependencies** (bd-66w1, bd-om4a) - Reference issues across repos - `external::` dependency syntax @@ -302,7 +302,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed -- **Wisp storage initialization** - NewWispStorage now copies issue_prefix from main db +- **Wisp flag handling** - Wisps now use Wisp=true flag in main database (not exported to JSONL) - **Prefix validation in multi-repo mode** (GH#686) - Skip validation for external repos - **Empty config values** (GH#680, GH#684) - Handle gracefully in getRepoConfig() - **Doctor UX improvements** (GH#687) - Better diagnostics and daemon integration diff --git a/CLAUDE.md b/CLAUDE.md index fbe7caaa..43580c8e 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -317,7 +317,7 @@ bd uses a molecular chemistry metaphor for template instantiation: |-------|---------|--------|----------| | **Proto** (solid) | Built-in | N/A | Reusable templates | | **Mol** (liquid) | `.beads/` | Yes | Persistent work | -| **Wisp** (vapor) | `.beads-wisp/` | No | Ephemeral operations | +| **Wisp** (vapor) | `.beads/` (Wisp=true) | No | Ephemeral operations | **Instantiation commands:** @@ -326,7 +326,7 @@ bd uses a molecular chemistry metaphor for template instantiation: bd pour --var key=value # Create in .beads/ # Wisp: proto → ephemeral wisp (vapor phase) -bd wisp create --var key=value # Create in .beads-wisp/ +bd wisp create --var key=value # Wisp=true, not exported to JSONL # List available templates bd mol list --json diff --git a/cmd/bd/info.go b/cmd/bd/info.go index c3a47146..0ae368b0 100644 --- a/cmd/bd/info.go +++ b/cmd/bd/info.go @@ -341,7 +341,7 @@ var versionChanges = []VersionChange{ "NEW: Chemistry UX - bd pour, bd mol bond --wisp/--pour for phase control", "NEW: Cross-project deps - external:: syntax, bd ship command", "BREAKING: bd repo add/remove now writes to .beads/config.yaml (not DB)", - "FIX: Wisp storage auto-copies issue_prefix from main database", + "FIX: Wisps use Wisp=true flag in main database (not exported to JSONL)", }, }, { diff --git a/cmd/bd/wisp.go b/cmd/bd/wisp.go index 41de529d..f03c9692 100644 --- a/cmd/bd/wisp.go +++ b/cmd/bd/wisp.go @@ -75,9 +75,9 @@ var wispCreateCmd = &cobra.Command{ Long: `Create a wisp from a proto - sublimation from solid to vapor. This is the chemistry-inspired command for creating ephemeral work from templates. -The resulting wisp lives in .beads-wisp/ (ephemeral storage) and is NOT synced. +The resulting wisp is stored in the main database with Wisp=true and NOT exported to JSONL. -Phase transition: Proto (solid) -> wisp -> Wisp (vapor) +Phase transition: Proto (solid) -> Wisp (vapor) Use wisp create for: - Patrol cycles (deacon, witness) @@ -86,8 +86,8 @@ Use wisp create for: - Routine operations with no audit value The wisp will: - - Be stored in .beads-wisp/ (gitignored) - - NOT sync to remote + - Be stored in main database with Wisp=true flag + - NOT be exported to JSONL (and thus not synced via git) - Either evaporate (burn) or condense to digest (squash) Examples: diff --git a/docs/CLI_REFERENCE.md b/docs/CLI_REFERENCE.md index 2d37f452..960cd74a 100644 --- a/docs/CLI_REFERENCE.md +++ b/docs/CLI_REFERENCE.md @@ -351,7 +351,7 @@ Beads uses a chemistry metaphor for template-based workflows. See [MOLECULES.md] |-------|-------|---------|---------| | Solid | Proto | `.beads/` | `bd mol catalog` | | Liquid | Mol | `.beads/` | `bd pour` | -| Vapor | Wisp | `.beads-wisp/` | `bd wisp create` | +| Vapor | Wisp | `.beads/` (Wisp=true, not exported) | `bd wisp create` | ### Proto/Template Commands diff --git a/docs/DELETIONS.md b/docs/DELETIONS.md index 1b9ac8a3..2d067e93 100644 --- a/docs/DELETIONS.md +++ b/docs/DELETIONS.md @@ -230,11 +230,10 @@ This is intentional, not a bug. See [ARCHITECTURE.md](ARCHITECTURE.md#wisps-and- ### If You Need Wisp History -Wisps exist in local git history (SQLite database commits) until garbage collected. Future enhancements may include: +Wisps are stored in the main database with `Wisp=true` flag and are not exported to JSONL. They exist in local SQLite until garbage collected or squashed. Future enhancements may include: -- Separate ephemeral repository for wisp storage -- Explicit migration step to promote wisps to permanent storage - Configurable wisp retention policies +- Automatic staleness detection based on dependency graph pressure ## Related diff --git a/docs/MOLECULES.md b/docs/MOLECULES.md index 8f519dce..4dba4cec 100644 --- a/docs/MOLECULES.md +++ b/docs/MOLECULES.md @@ -123,7 +123,7 @@ For reusable workflows, beads uses a chemistry metaphor: |-------|------|---------|--------|---------| | **Solid** | Proto | `.beads/` | Yes | Frozen template | | **Liquid** | Mol | `.beads/` | Yes | Active persistent work | -| **Vapor** | Wisp | `.beads-wisp/` | No | Ephemeral operations | +| **Vapor** | Wisp | `.beads/` (Wisp=true) | No | Ephemeral operations | ### Phase Commands