Commit Graph

981 Commits

Author SHA1 Message Date
Steve Yegge
b3d95191dd bd sync: 2025-12-23 21:19:04 2025-12-23 21:19:04 -08:00
Steve Yegge
eced6494f8 bd sync: 2025-12-23 20:30:06 2025-12-23 20:30:06 -08:00
Steve Yegge
e972d983c1 bd sync: 2025-12-23 20:25:57 2025-12-23 20:25:58 -08:00
Steve Yegge
17ae76fbd2 docs: remove remaining Breaking Bad references
Clean up Walter White quotes, 99.1% pure, secret formula references.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 20:15:41 -08:00
Steve Yegge
de3a3e0813 docs: remove explicit Breaking Bad/Mad Max metaphor section
The metaphors inspired the naming, but explicit mapping does not
belong in user-facing documentation.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 20:11:17 -08:00
Steve Yegge
a84eb179db docs: consolidate Rig/Cook/Run into molecular-chemistry.md (gt-8tmz.32)
- Add Work Lifecycle section (Rig → Cook → Run phases)
- Add Complete Artifact Graph showing full generation/bond relationships
- Add Two Composition Operators section (rig vs bond distinction)
- Add Formulas section covering source layer above protos
- Add symmetric Bond Table
- Update vocabulary appendix with new terms
- Redirect rig-cook-run.md to consolidated doc
- Update references in molecule-algebra.md and vision.md

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 20:11:17 -08:00
Steve Yegge
22c5fb6bdf bd sync: 2025-12-23 20:10:06 2025-12-23 20:10:06 -08:00
Steve Yegge
16f6b4ee67 bd sync: 2025-12-23 20:02:30 2025-12-23 20:02:30 -08:00
Steve Yegge
0835a7066e bd sync: 2025-12-23 19:53:48 2025-12-23 19:53:48 -08:00
Steve Yegge
a3cb8f33aa bd sync: 2025-12-23 19:28:20 2025-12-23 19:28:20 -08:00
Steve Yegge
3bc676ee2e bd sync: 2025-12-23 19:27:58 2025-12-23 19:27:58 -08:00
Steve Yegge
32048ceaaa bd sync: 2025-12-23 19:27:37 2025-12-23 19:27:37 -08:00
Steve Yegge
837cad67b8 feat: add Towers of Hanoi formula prototype (gt-8tmz)
Demonstrates that molecule algebra solves the "million step workflow"
problem that MAKER addressed with distributed voting.

Key insight: structure is mechanical, only leaf execution needs AI.
- The move sequence is 100% deterministic (2^n - 1 moves)
- Each step is trivial ("move disk 3 from A to C")
- No voting needed - formula generates perfect structure

New beads filed:
- gt-8tmz.26: Direct formula-to-wisp (skip proto for huge ephemeral work)
- gt-8tmz.27: Computed range expansion (for-each over expressions)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 19:27:21 -08:00
Steve Yegge
c13eb39908 bd sync: 2025-12-23 19:27:17 2025-12-23 19:27:17 -08:00
Steve Yegge
6fe32bb5a8 bd sync: 2025-12-23 19:26:56 2025-12-23 19:26:56 -08:00
Steve Yegge
ef6959e4dd bd sync: 2025-12-23 19:19:56 2025-12-23 19:20:09 -08:00
Steve Yegge
4716b2ee57 docs: discover Rig/Cook/Run lifecycle - the three phases of work (gt-8tmz)
Key insight: Rig and Bond operate at different abstraction levels:
- Rig = source-level composition (formula YAML with extends/compose)
- Bond = artifact-level composition (protos, mols, wisps)

This preserves the symmetric bond table while cleanly separating
authoring (rig) from runtime composition (bond).

New docs:
- rig-cook-run.md: Canonical spec for the three phases

Updated docs:
- molecule-algebra.md: Three Phases section, rig/bond distinction
- molecular-chemistry.md: Rig/bond clarification in bond section
- vision.md: Core Innovation 3 now covers Rig/Cook/Run

"This is a discovery, not an invention."

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 19:19:21 -08:00
Steve Yegge
733039a6d6 bd sync: 2025-12-23 19:19:11 2025-12-23 19:19:11 -08:00
Steve Yegge
d07f3be9ca bd sync: 2025-12-23 19:12:35 2025-12-23 19:12:35 -08:00
Steve Yegge
3228a93453 bd sync: 2025-12-23 18:48:25 2025-12-23 18:48:56 -08:00
Steve Yegge
04c6ba048a bd sync: 2025-12-23 18:20:23 2025-12-23 18:48:56 -08:00
Steve Yegge
b9705fc35b bd sync: 2025-12-23 18:04:57 2025-12-23 18:48:56 -08:00
Steve Yegge
0a7630c263 refactor: formulas use YAML instead of JSON (gt-8tmz)
- Convert .formula.json files to .formula.yaml
- Update molecule-algebra.md to specify YAML format
- Update molecular-chemistry.md proto examples
- Add Safety Constraints section: cycle detection, aspect
  self-matching prevention, max expansion depth, graceful degradation

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 18:48:43 -08:00
Steve Yegge
74430a1019 refactor: formulas use JSON instead of YAML (gt-8tmz)
JSON for consistency with beads (issues.jsonl, molecules.jsonl).
Agents create/manage formulas; humans use visualizers.

- Simpler parsing (Go built-in JSON)
- No YAML gotchas
- Agents generate JSON flawlessly
2025-12-23 18:23:36 -08:00
Steve Yegge
93d9726bbc docs: add Formula + Cook terminology and example formulas (gt-8tmz)
Updates to molecule-algebra.md:
- Added Formulas and Cooking section
- Four-tier model: Formula → cook → Proto → pour/wisp → Mol/Wisp
- Breaking Bad × Mad Max naming (Let's cook!)
- Updated vision diagram

New example formulas:
- shiny.formula.yaml (Engineer in a Box)
- rule-of-five.formula.yaml (Jeffrey's Rule expansion macro)
- security-audit.formula.yaml (AOP aspect)
- shiny-enterprise.formula.yaml (composed example)
2025-12-23 18:20:39 -08:00
Steve Yegge
e63ac65b86 docs: add molecule algebra specification (gt-8tmz)
Comprehensive design doc for work composition DSL:
- Phase transitions (pour/wisp/bond)
- Composition operators (sequence, parallel, branch)
- Advice operators (before/after/around - Lisp style)
- Expansion operators (macros like Rule of Five)
- Aspects (AOP cross-cutting concerns)
- Selection operators (glob, filter)
- Condition evaluation

From issues-in-git to work composition algebra in 10 weeks.
2025-12-23 18:05:19 -08:00
Steve Yegge
1931ec736a Polecat template cleanup (gt-t9u7)
- Rename "Dependency Trap" to "Gotchas when Filing Beads" in all 6 role templates
- Fix "git clone" to "git worktree" in polecat template
- Simplify completion section to just "gt done"
- Condense Work Protocol section (let molecule define steps)
- Simplify "Before Signaling Done" to trust gt done internals
- Clarify work status: use "gt mol status" as primary command

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 17:08:55 -08:00
Steve Yegge
f6b099eb14 bd sync: 2025-12-23 16:58:44 2025-12-23 16:58:44 -08:00
Steve Yegge
d11bbf527b bd sync: 2025-12-23 16:57:26 2025-12-23 16:57:34 -08:00
Steve Yegge
475dcb37fa gt sling: enable wisp spawning for patrol roles (gt-jsup)
Revert IsWisp: false → true for patrol spawning. bd mol run now
auto-discovers the main database for templates when --db contains
.beads-wisp, so patrol molecules can spawn correctly into ephemeral storage.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 16:39:46 -08:00
Steve Yegge
41bf7da3af bd sync: 2025-12-23 16:39:32 2025-12-23 16:39:32 -08:00
Steve Yegge
521f5d6272 bd sync: 2025-12-23 16:31:08 2025-12-23 16:31:08 -08:00
Steve Yegge
901d0a1528 bd sync: 2025-12-23 16:29:05 2025-12-23 16:29:20 -08:00
Steve Yegge
58c0fae614 gt sling: use mail queue for patrol roles (gt-afn0)
When slinging work to patrol agents (witness, refinery, deacon), queue via
mail instead of replacing the hook. This preserves patrol continuity.

New behavior:
- Default: Check if patrol is running, start default patrol if not, send
  work via mail. Patrol processes queued work during its cycle.
- --urgent: Marks mail as urgent (🚨 URGENT prefix)
- --replace: Legacy behavior, explicitly terminates patrol (break-glass)

New helper functions:
- isPatrolRole(kind): Returns true for witness/refinery/deacon
- getDefaultPatrolMolecule(role): Returns patrol template name
- resolvePatrolMoleculeID(path, title): Looks up beads issue ID by title
- isPatrolRunning(path, addr): Checks if patrol molecule is attached

Note: Patrol spawning currently uses main DB (not wisp storage) because
templates must be looked up from the main database. Wisp support for
patrol instances is a future enhancement.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 16:24:55 -08:00
Steve Yegge
7b619b75d6 bd sync: 2025-12-23 16:24:52 2025-12-23 16:24:52 -08:00
Steve Yegge
b2bdb85ac4 bd sync: 2025-12-23 16:23:48 2025-12-23 16:23:48 -08:00
Steve Yegge
6806a6146b bd sync: 2025-12-23 16:13:05 2025-12-23 16:13:05 -08:00
Steve Yegge
419015b59b bd sync: 2025-12-23 16:08:22 2025-12-23 16:08:31 -08:00
Steve Yegge
fd8a5d028d bd sync: 2025-12-23 16:07:48 2025-12-23 16:08:31 -08:00
Steve Yegge
7f37d41da3 gt sling --force: return displaced work to ready pool (gt-o40t)
When slinging with --force to an agent with occupied hook, the displaced
molecule is now returned to the ready pool rather than silently orphaned.

Changes:
- Modified checkHookCollision to take force param and return displaced ID
- Added releaseDisplacedWork helper to unpin and release displaced molecules
- Updated all 5 sling handlers (polecat, crew, witness, refinery, mayor)

Behavior:
- Without --force: still errors "hook already occupied by X"
- With --force: prints warning, releases old work, proceeds with new sling

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 16:07:42 -08:00
Steve Yegge
5e093dadff Fix witness session to start in witness directory
The witness session was starting in the rig root (e.g., /gt/gastown)
instead of the witness directory (e.g., /gt/gastown/witness/rig).
This caused gt prime to detect the Mayor role instead of Witness role.

Now ensureWitnessSession uses the same pattern as ensureRefinerySession:
1. Try <rig>/witness/rig/ first (for rigs with worktree setup)
2. Fall back to <rig>/witness/ (for simpler setups)
3. Last resort: use rig root (shouldn't happen normally)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 16:07:23 -08:00
Steve Yegge
d507bf6516 bd sync: 2025-12-23 16:07:14 2025-12-23 16:07:14 -08:00
Steve Yegge
f61570c079 bd sync: 2025-12-23 16:05:40 2025-12-23 16:05:40 -08:00
Steve Yegge
7185d01911 bd sync: 2025-12-23 16:00:29 2025-12-23 16:00:29 -08:00
Steve Yegge
7caf3ff28e bd sync: 2025-12-23 15:57:06 2025-12-23 15:57:06 -08:00
Steve Yegge
143959943b bd sync: 2025-12-23 15:56:29 2025-12-23 15:56:39 -08:00
Steve Yegge
76697c5105 bd sync: 2025-12-23 15:05:40 2025-12-23 15:56:39 -08:00
Steve Yegge
3e72146673 Clarify molecule vs epic distinction in beads-data-plane.md
The document conflated epics and molecules. This revision:
- Explains molecules as the general abstraction for executable work
- Introduces the concept of molecular shapes (Epic, Christmas Ornament, etc.)
- Clarifies that epics are just ONE shape (a simple TODO list pattern)
- Adds the key insight: All epics are molecules. Not all molecules are epics.
- Explains why the data plane stores all shapes the same way
- Updates Related Documents with better descriptions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 15:24:16 -08:00
Steve Yegge
c8bb8ac6b9 Add Dependency Trap warning to all gt prime role templates
Temporal language like "Phase 1 blocks Phase 2" triggers incorrect
dependency direction. Added a concise warning to all 6 role templates
(crew, polecat, mayor, witness, refinery, deacon) reminding agents:
- Think "X needs Y", not "X comes before Y"
- Verify with `bd blocked`

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 15:13:32 -08:00
Steve Yegge
683989dfd8 Add session-lifecycle.md: unified context cycling model
Documents foundational architecture for session lifecycle:
- Single-Bond Principle (one bead ≈ one session)
- Context Budget Model (what N-heuristics really proxy for)
- Unified cycling model across all roles
- Mid-step handoff mechanics
- Happy Path (decomposition) vs Sad Path (compaction)
- Oversized Bead Protocol

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 15:02:33 -08:00