Commit Graph

883 Commits

Author SHA1 Message Date
Steve Yegge
e27e3b7221 bd sync: 2025-12-28 16:19:51 2025-12-28 16:19:51 -08:00
Steve Yegge
11d86423ba witness patrol: nuke command already correct for MERGED handling
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 16:16:25 -08:00
Steve Yegge
a3e3f956b1 beads sync: Day 4.3, 4.4 and related closures
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 16:16:25 -08:00
Steve Yegge
2f38e73058 bd sync: 2025-12-28 16:12:53 2025-12-28 16:16:24 -08:00
Steve Yegge
0c4fd5ffa0 feat: Witness uses gt polecat nuke after MERGED, session mgmt note (gt-ztpe8)
- Updated MERGED handling to use gt polecat nuke for full cleanup
  (session + worktree + branch + agent bead)
- Added note that session management is polecat-controlled
- Witness only uses recycle for stuck recovery, not routine step transitions

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 16:16:24 -08:00
Steve Yegge
cb9c6385d0 bd sync: 2025-12-28 16:00:47 2025-12-28 16:16:24 -08:00
Steve Yegge
36dbea9618 bd sync: 2025-12-28 15:51:37 2025-12-28 15:51:37 -08:00
Steve Yegge
31a392eec2 bd sync: 2025-12-28 15:43:30 2025-12-28 15:43:30 -08:00
Steve Yegge
e54d0eec0a bd sync: 2025-12-28 15:33:00 2025-12-28 15:33:00 -08:00
Steve Yegge
2ad828f503 bd sync: 2025-12-28 15:32:52 2025-12-28 15:32:52 -08:00
Steve Yegge
85bf95a221 bd sync: 2025-12-28 15:32:31 2025-12-28 15:32:31 -08:00
Steve Yegge
4a321b9690 bd sync: 2025-12-28 15:31:31 2025-12-28 15:32:04 -08:00
Steve Yegge
73e829724f bd sync: 2025-12-28 14:07:42 2025-12-28 14:07:51 -08:00
Steve Yegge
c107665f17 bd sync: 2025-12-28 13:00:08 2025-12-28 13:00:20 -08:00
Steve Yegge
65b16117f7 bd sync: 2025-12-28 12:57:06 2025-12-28 12:57:07 -08:00
Steve Yegge
ecfd862dac Add preflight-tests step to mol-polecat-work
Checks tests on main BEFORE starting work. Scotty Principle:
- Quick fix (<15 min): Fix it, commit, continue
- Big fix: File bead, notify Witness, proceed

Closes gt-3zkjw
2025-12-28 12:49:48 -08:00
Steve Yegge
43ef530e95 bd sync: 2025-12-28 12:46:53 2025-12-28 12:46:53 -08:00
Steve Yegge
c564bfd736 Comprehensive polecat work lifecycle (mol-polecat-work v2)
Complete redesign of polecat work formula with 8 concrete steps:
1. load-context - Prime, read issue, verify can proceed
2. branch-setup - Clean feature branch, rebased on main
3. implement - Do work, commit regularly, file discovered work
4. self-review - Review diff, fix issues before testing
5. run-tests - ALL tests must pass, verify coverage
6. cleanup-workspace - No uncommitted, no stash, no cruft
7. close-issue - bd close with summary
8. signal-complete - POLECAT_DONE mail, WAIT for termination

Also updated mol-polecat-lease.formula.toml (v2):
- 5 steps: boot → working → verifying → merge_requested → done
- Aligns with witness patrol and mail protocol
- Clear verification criteria before MERGE_READY

Added templates/polecat-CLAUDE.md:
- Polecat role context for spawned workers
- Propulsion principle, key commands, completion protocol
- Clear "do NOT" section (don't exit, don't push to main)

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 11:13:00 -08:00
Steve Yegge
1366a032de bd sync: 2025-12-28 11:02:50 2025-12-28 11:02:50 -08:00
Steve Yegge
12a9e7982d bd sync: 2025-12-28 10:52:57 2025-12-28 10:53:08 -08:00
Steve Yegge
977927244a bd sync: 2025-12-28 10:27:57 2025-12-28 10:53:08 -08:00
Steve Yegge
7ee51b8460 bd sync: 2025-12-28 10:24:08 2025-12-28 10:25:30 -08:00
Steve Yegge
4c0ca6be4d Revert "chore: Track .beads/redirect for crew shared beads"
This reverts commit e00528e4ef.
2025-12-28 10:25:01 -08:00
Steve Yegge
e00528e4ef chore: Track .beads/redirect for crew shared beads
The redirect file points crew workers to the shared beads database
at mayor/rig/.beads. Tracking it keeps git status clean.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 10:22:55 -08:00
Steve Yegge
1877ed9e13 bd sync: 2025-12-28 10:18:51 2025-12-28 10:18:51 -08:00
Steve Yegge
5ec5616c9f bd sync: 2025-12-28 10:17:44 2025-12-28 10:17:44 -08:00
Steve Yegge
a001e78c71 bd sync: 2025-12-28 10:17:22 2025-12-28 10:17:22 -08:00
Steve Yegge
aadd58a06a bd sync: 2025-12-28 10:14:08 2025-12-28 10:14:08 -08:00
Steve Yegge
a5b8e9a6f0 bd sync: 2025-12-28 10:07:07 2025-12-28 10:07:14 -08:00
Steve Yegge
2655a85124 chore: remove issue ID references from comments
Strip (gt-xxx), (bd-xxx) suffixes from code comments. The descriptions
remain meaningful without the ephemeral issue IDs.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 10:05:16 -08:00
Steve Yegge
5838d4cd1b Witness pings Deacon for second-order monitoring (gt-5v8ls)
Added WITNESS_PING protocol for monitoring Deacon health:

Witness patrol (mol-witness-patrol):
- Added ping-deacon step after survey-workers
- Sends WITNESS_PING mail to Deacon each patrol cycle
- Checks Deacon agent bead last_activity timestamp
- Escalates to Mayor if Deacon appears unresponsive

Deacon patrol (mol-deacon-patrol):
- Added WITNESS_PING handling in inbox-check
- Added second-order monitoring section to description
- Bumped formula version to 2

This prevents the "who watches the watchers" problem - if Deacon dies,
the collective Witness fleet detects it and escalates.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 10:02:55 -08:00
Steve Yegge
60940bfd99 bd sync: 2025-12-28 09:59:49 2025-12-28 09:59:49 -08:00
Steve Yegge
ae8539d7e0 Refinery processes MERGE_READY and sends MERGED (gt-7uhts)
Updated mol-refinery-patrol formula with:
- MERGE_READY handling in inbox-check (parse branch/issue/polecat)
- Mail-based queue instead of git branch scanning
- MERGED mail sent to Witness after successful merge
- Flow diagram showing Witness→Refinery→Witness mail protocol
- Bumped formula version to 2

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 09:58:51 -08:00
Steve Yegge
600c468a9b bd sync: 2025-12-28 09:57:07 2025-12-28 09:58:51 -08:00
Steve Yegge
34ccd121e8 feat: Complete agent bead lifecycle for ZFC compliance
Changes:
1. prime.go: Create agent beads on first prime for all roles including crew
2. done.go: Update agent state to done/stuck/idle when work completes
3. sling.go: Populate hook_bead when work is assigned to agents
4. mol-witness-patrol.formula.toml: Document dead and spawning states

Closes: gt-hymm0, gt-0lop3, gt-59k2x, gt-c4j4j

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 09:56:59 -08:00
Steve Yegge
76b969fb2e Witness sends MERGE_READY to refinery on polecat completion (gt-u6siy)
Updated mol-witness-patrol formula with:
- MERGE_READY mail sent after polecat verification (process-cleanups)
- MERGED mail handling in inbox-check (completes cleanup)
- Cleanup wisp state machine: pending → merge-requested → closed
- Fallback discovery in survey-workers creates cleanup if done polecat
  found without existing wisp

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 09:53:51 -08:00
Steve Yegge
aab15fdf67 bd sync: 2025-12-28 09:49:17 2025-12-28 09:49:17 -08:00
Steve Yegge
6cfb31419e bd sync: 2025-12-28 09:43:06 2025-12-28 09:43:06 -08:00
Steve Yegge
ec0f314a2d bd sync: 2025-12-28 09:42:29 2025-12-28 09:42:53 -08:00
Steve Yegge
f3a6ef6ca5 feat: Witness reads polecat state from agent beads (gt-gizsv)
Changes:
1. Fix reportAgentState in prime.go to use beads API directly instead of
   non-existent `bd agent state` command. Agents now properly self-report
   their state to their agent beads on startup.

2. Update witness patrol survey-workers step to use agent beads:
   - List polecats via `bd list --type=agent --json`
   - Filter by role_type: polecat in description
   - Check agent_state field (running/idle/stuck/done)
   - Trust agent-reported state (ZFC principle)

No more PID/tmux inference for polecat state - agents self-report.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 09:42:07 -08:00
Steve Yegge
5b0b852eb5 bd sync: 2025-12-28 09:41:53 2025-12-28 09:41:53 -08:00
Steve Yegge
914d81151e bd sync: 2025-12-28 09:35:07 2025-12-28 09:35:17 -08:00
Steve Yegge
b9bb6577f8 bd sync: 2025-12-28 09:34:57 2025-12-28 09:35:17 -08:00
Steve Yegge
ec870b92d8 bd sync: 2025-12-28 09:33:08 2025-12-28 09:33:08 -08:00
Steve Yegge
e54435bc2c bd sync: 2025-12-28 09:23:07 2025-12-28 09:23:07 -08:00
Steve Yegge
0d75fd2675 bd sync: 2025-12-28 09:20:06 2025-12-28 09:20:06 -08:00
Steve Yegge
34f5ef0e93 feat: Wire witness patrol formula to daemon cron (gt-qpoxz)
Adds witness patrol to daemon heartbeat cycle:
- ensureWitnessesRunning(): Start witness for each rig if not running
- pokeWitnesses(): Send heartbeat messages to all witnesses
- getKnownRigs(): Read rig list from mayor/rigs.json

The daemon now ensures both Deacon and Witnesses are running
and sends periodic heartbeats to trigger their patrol molecules.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 02:44:37 -08:00
Steve Yegge
2ae7bd24a3 feat: gt doctor checks agent beads exist (gt-bq4wo)
Adds agent-beads-exist check to gt doctor:
- Verifies witness/refinery beads exist for each rig
- Verifies deacon/mayor beads exist in first rig
- Supports --fix to create missing agent beads
- Skips non-gt prefixes (beads library limitation)

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 02:40:00 -08:00
Steve Yegge
315206e593 bd sync: 2025-12-28 02:26:23 2025-12-28 02:26:42 -08:00
Steve Yegge
703234cf80 bd sync: 2025-12-28 02:25:50 2025-12-28 02:25:50 -08:00