aether-colony 3.1.1 → 3.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/commands/ant/build.md +57 -6
- package/.claude/commands/ant/continue.md +43 -1
- package/.opencode/commands/ant/build.md +107 -11
- package/.opencode/commands/ant/continue.md +43 -1
- package/.opencode/commands/ant/maturity.md +92 -0
- package/.opencode/commands/ant/verify-castes.md +85 -0
- package/CHANGELOG.md +9 -0
- package/package.json +2 -2
- package/runtime/aether-utils.sh +16 -0
- package/.opencode/commands/ant/ant:build.md +0 -982
- package/.opencode/commands/ant/ant:verify-castes.md +0 -157
|
@@ -277,14 +277,36 @@ CONSTRAINTS: (none)
|
|
|
277
277
|
The `archaeology_context` will be injected into builder prompts in Step 5.1 (see below).
|
|
278
278
|
If this step was skipped (no existing files modified), the archaeology section is omitted from builder prompts.
|
|
279
279
|
|
|
280
|
-
### Step 5:
|
|
280
|
+
### Step 5: Initialize Swarm Display and Analyze Tasks
|
|
281
281
|
|
|
282
282
|
**YOU (the Queen) will spawn workers directly. Do NOT delegate to a single Prime Worker.**
|
|
283
283
|
|
|
284
|
-
|
|
284
|
+
**Initialize visual swarm tracking:**
|
|
285
285
|
```bash
|
|
286
|
+
# Generate unique build ID
|
|
287
|
+
build_id="build-$(date +%s)"
|
|
288
|
+
|
|
289
|
+
# Initialize swarm display for this build
|
|
290
|
+
bash .aether/aether-utils.sh swarm-display-init "$build_id"
|
|
291
|
+
|
|
292
|
+
# Log phase start
|
|
286
293
|
bash .aether/aether-utils.sh activity-log "EXECUTING" "Queen" "Phase {id}: {name} - Queen dispatching workers"
|
|
294
|
+
|
|
295
|
+
# Display animated header
|
|
296
|
+
bash .aether/aether-utils.sh swarm-display-update "Queen" "prime" "excavating" "Phase {id}: {name}" "Colony" '{"read":0,"grep":0,"edit":0,"bash":0}' 10 "fungus_garden" 0
|
|
297
|
+
```
|
|
298
|
+
|
|
299
|
+
**Show real-time display header:**
|
|
287
300
|
```
|
|
301
|
+
🔨🐜 COLONY BUILD INITIATED 🐜🔨
|
|
302
|
+
═══════════════════════════════════════════════════
|
|
303
|
+
Phase {id}: {name}
|
|
304
|
+
Build ID: {build_id}
|
|
305
|
+
|
|
306
|
+
Launching swarm display... (visual tracking enabled)
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
Analyze the phase tasks:
|
|
288
310
|
|
|
289
311
|
Analyze the phase tasks:
|
|
290
312
|
|
|
@@ -330,9 +352,10 @@ Total: {N} Builders + 1 Watcher + 1 Chaos = {N+2} spawns
|
|
|
330
352
|
|
|
331
353
|
For each Wave 1 task, use Task tool with `subagent_type="general"` and `run_in_background: true`:
|
|
332
354
|
|
|
333
|
-
Log each spawn:
|
|
355
|
+
Log each spawn and update swarm display:
|
|
334
356
|
```bash
|
|
335
357
|
bash .aether/aether-utils.sh spawn-log "Queen" "builder" "{ant_name}" "{task_description}"
|
|
358
|
+
bash .aether/aether-utils.sh swarm-display-update "{ant_name}" "builder" "excavating" "{task_description}" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "fungus_garden" 10
|
|
336
359
|
```
|
|
337
360
|
|
|
338
361
|
**Builder Worker Prompt Template:**
|
|
@@ -440,11 +463,15 @@ For each spawned worker, call TaskOutput with `block: true` to wait for completi
|
|
|
440
463
|
|
|
441
464
|
Store all results for synthesis in Step 5.6.
|
|
442
465
|
|
|
443
|
-
For each completed worker, log:
|
|
466
|
+
For each completed worker, log and update swarm display:
|
|
444
467
|
```bash
|
|
445
468
|
bash .aether/aether-utils.sh spawn-complete "{ant_name}" "completed" "{summary}"
|
|
469
|
+
bash .aether/aether-utils.sh swarm-display-update "{ant_name}" "builder" "completed" "{task_description}" "Queen" '{"read":5,"grep":3,"edit":2,"bash":1}' 100 "fungus_garden" 100
|
|
446
470
|
```
|
|
447
471
|
|
|
472
|
+
**Update swarm display with accumulated tool usage:**
|
|
473
|
+
As workers complete, accumulate their actual tool usage (Read, Grep, Edit, Bash counts from their activity logs) and update the swarm display to show live progress.
|
|
474
|
+
|
|
448
475
|
**Only proceed to Step 5.3 after ALL Wave 1 TaskOutput calls have returned.**
|
|
449
476
|
|
|
450
477
|
### Step 5.3: Spawn Wave 2+ Workers (Sequential Waves)
|
|
@@ -457,6 +484,7 @@ Repeat Step 5.1-5.2 for each subsequent wave, waiting for previous wave to compl
|
|
|
457
484
|
|
|
458
485
|
```bash
|
|
459
486
|
bash .aether/aether-utils.sh spawn-log "Queen" "watcher" "{watcher_name}" "Independent verification"
|
|
487
|
+
bash .aether/aether-utils.sh swarm-display-update "{watcher_name}" "watcher" "observing" "Verification in progress" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "nursery" 50
|
|
460
488
|
```
|
|
461
489
|
|
|
462
490
|
**Watcher Worker Prompt:**
|
|
@@ -567,6 +595,11 @@ Call TaskOutput with `block: true` using the Watcher's task_id:
|
|
|
567
595
|
- Parse: verification_passed, issues_found, quality_score, recommendation
|
|
568
596
|
- Store results for synthesis in Step 5.6
|
|
569
597
|
|
|
598
|
+
**Update swarm display when Watcher completes:**
|
|
599
|
+
```bash
|
|
600
|
+
bash .aether/aether-utils.sh swarm-display-update "{watcher_name}" "watcher" "completed" "Verification complete" "Queen" '{"read":3,"grep":2,"edit":0,"bash":1}' 100 "nursery" 100
|
|
601
|
+
```
|
|
602
|
+
|
|
570
603
|
**Only proceed to Step 5.4.2 after Watcher TaskOutput has returned.**
|
|
571
604
|
|
|
572
605
|
### Step 5.4.2: Spawn Chaos Ant for Resilience Testing
|
|
@@ -577,6 +610,7 @@ Generate a chaos ant name and log the spawn:
|
|
|
577
610
|
```bash
|
|
578
611
|
bash .aether/aether-utils.sh generate-ant-name "chaos"
|
|
579
612
|
bash .aether/aether-utils.sh spawn-log "Queen" "chaos" "{chaos_name}" "Resilience testing of Phase {id} work"
|
|
613
|
+
bash .aether/aether-utils.sh swarm-display-update "{chaos_name}" "chaos" "probing" "Resilience testing" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "refuse_pile" 75
|
|
580
614
|
```
|
|
581
615
|
|
|
582
616
|
**Retrieve existing flags for this phase** (to avoid duplicate findings):
|
|
@@ -662,9 +696,10 @@ Log the flag:
|
|
|
662
696
|
bash .aether/aether-utils.sh activity-log "FLAG" "Chaos" "Created blocker: {finding.title}"
|
|
663
697
|
```
|
|
664
698
|
|
|
665
|
-
Log chaos ant completion:
|
|
699
|
+
Log chaos ant completion and update swarm display:
|
|
666
700
|
```bash
|
|
667
701
|
bash .aether/aether-utils.sh spawn-complete "{chaos_name}" "completed" "{summary}"
|
|
702
|
+
bash .aether/aether-utils.sh swarm-display-update "{chaos_name}" "chaos" "completed" "Resilience testing done" "Queen" '{"read":2,"grep":1,"edit":0,"bash":0}' 100 "refuse_pile" 100
|
|
668
703
|
```
|
|
669
704
|
|
|
670
705
|
**Only proceed to Step 5.5 after Chaos Ant TaskOutput has returned.**
|
|
@@ -830,7 +865,23 @@ Use AskUserQuestion to get approval. Record in events:
|
|
|
830
865
|
|
|
831
866
|
**This step runs ONLY after synthesis is complete. All values come from actual worker results.**
|
|
832
867
|
|
|
833
|
-
|
|
868
|
+
**First, render the final swarm display showing all completed workers:**
|
|
869
|
+
```bash
|
|
870
|
+
# Final swarm display update - mark Queen as completed
|
|
871
|
+
bash .aether/aether-utils.sh swarm-display-update "Queen" "prime" "completed" "Phase {id} complete" "Colony" '{"read":10,"grep":5,"edit":5,"bash":2}' 100 "fungus_garden" 100
|
|
872
|
+
|
|
873
|
+
# Render the final swarm display
|
|
874
|
+
bash .aether/aether-utils.sh swarm-display-render "$build_id"
|
|
875
|
+
```
|
|
876
|
+
|
|
877
|
+
The swarm display will show:
|
|
878
|
+
- 🐜 All workers with their caste emojis (🔨 Builder, 👁️ Watcher, 🎲 Chaos)
|
|
879
|
+
- 📖 Tool usage stats (Read, Grep, Edit, Bash counts)
|
|
880
|
+
- 🏠 Chamber activity map (Fungus Garden, Nursery, Refuse Pile)
|
|
881
|
+
- ✅ Progress bars at 100% for completed work
|
|
882
|
+
- 🌈 Color-coded by caste
|
|
883
|
+
|
|
884
|
+
**Then display build summary based on synthesis results AND `verbose_mode` from Step 1:**
|
|
834
885
|
|
|
835
886
|
**If verbose_mode = false (compact output, ~12 lines):**
|
|
836
887
|
|
|
@@ -736,6 +736,48 @@ Set `last_commit_suggestion_phase` to `{phase_id}` in COLONY_STATE.json (add the
|
|
|
736
736
|
|
|
737
737
|
**Error handling:** If any git command fails (not a repo, merge conflict, pre-commit hook rejection), display the error output and continue to the next step. The commit suggestion is advisory only -- it never blocks the flow.
|
|
738
738
|
|
|
739
|
+
Continue to Step 2.7 (Context Clear Suggestion), then to Step 2.5 (Project Completion) or Step 3 (Display Result).
|
|
740
|
+
|
|
741
|
+
### Step 2.7: Context Clear Suggestion (Optional)
|
|
742
|
+
|
|
743
|
+
**This step is non-blocking. Skipping does not affect phase advancement.**
|
|
744
|
+
|
|
745
|
+
After committing (or skipping commit), suggest clearing context to refresh before the next phase.
|
|
746
|
+
|
|
747
|
+
1. **Display the suggestion:**
|
|
748
|
+
```
|
|
749
|
+
──────────────────────────────────────────────────
|
|
750
|
+
Context Refresh
|
|
751
|
+
──────────────────────────────────────────────────
|
|
752
|
+
|
|
753
|
+
State is fully persisted and committed.
|
|
754
|
+
Phase {next_id} is ready to build.
|
|
755
|
+
|
|
756
|
+
──────────────────────────────────────────────────
|
|
757
|
+
```
|
|
758
|
+
|
|
759
|
+
2. **Use AskUserQuestion:**
|
|
760
|
+
```
|
|
761
|
+
Clear context now?
|
|
762
|
+
|
|
763
|
+
1. Yes, clear context then run /ant:build {next_id}
|
|
764
|
+
2. No, continue in current context
|
|
765
|
+
```
|
|
766
|
+
|
|
767
|
+
3. **If option 1 ("Yes, clear context"):**
|
|
768
|
+
|
|
769
|
+
**IMPORTANT:** Claude Code does not support programmatic /clear. Display instructions:
|
|
770
|
+
```
|
|
771
|
+
Please type: /clear
|
|
772
|
+
|
|
773
|
+
Then run: /ant:build {next_id}
|
|
774
|
+
```
|
|
775
|
+
|
|
776
|
+
Record the suggestion: Set `context_clear_suggested` to `true` in COLONY_STATE.json.
|
|
777
|
+
|
|
778
|
+
4. **If option 2 ("No, continue in current context"):**
|
|
779
|
+
Display: `Continuing in current context. State is saved.`
|
|
780
|
+
|
|
739
781
|
Continue to Step 2.5 (Project Completion) or Step 3 (Display Result).
|
|
740
782
|
|
|
741
783
|
### Step 2.5: Project Completion
|
|
@@ -798,7 +840,7 @@ Output:
|
|
|
798
840
|
/ant:phase {next_id} 📋 Review phase details first
|
|
799
841
|
/ant:focus "<area>" 🎯 Guide colony attention
|
|
800
842
|
|
|
801
|
-
💾 State persisted —
|
|
843
|
+
💾 State persisted — context clear suggested above
|
|
802
844
|
```
|
|
803
845
|
|
|
804
846
|
**IMPORTANT:** In the "Next Steps" section above, substitute the actual phase number for `{next_id}` (calculated in Step 2 as `current_phase + 1`). For example, if advancing to phase 4, output `/ant:build 4` not `/ant:build {next_id}`.
|
|
@@ -15,30 +15,74 @@ Run using the Bash tool: `bash .aether/aether-utils.sh version-check 2>/dev/null
|
|
|
15
15
|
|
|
16
16
|
If the command succeeds and the JSON result contains a non-empty string, display it as a one-line notice. Proceed regardless of outcome.
|
|
17
17
|
|
|
18
|
+
### Step 0.6: Verify LiteLLM Proxy
|
|
19
|
+
|
|
20
|
+
Check that the LiteLLM proxy is running for model routing:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
curl -s http://localhost:4000/health | grep -q "healthy" && echo "Proxy healthy" || echo "Proxy not running - workers will use default model"
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
If proxy is not healthy, log a warning but continue (workers will fall back to default routing).
|
|
27
|
+
|
|
28
|
+
### Step 0.5: Load Colony State
|
|
29
|
+
|
|
30
|
+
Run using Bash tool: `bash .aether/aether-utils.sh load-state`
|
|
31
|
+
|
|
32
|
+
If the command fails (non-zero exit or JSON has ok: false):
|
|
33
|
+
1. Parse error JSON
|
|
34
|
+
2. If error code is E_FILE_NOT_FOUND: "No colony initialized. Run /ant:init first." and stop
|
|
35
|
+
3. If validation error: Display error details with recovery suggestion and stop
|
|
36
|
+
4. For other errors: Display generic error and suggest /ant:status for diagnostics
|
|
37
|
+
|
|
38
|
+
If successful:
|
|
39
|
+
1. Parse the state JSON from result field
|
|
40
|
+
2. Check if goal is null - if so: "No colony initialized. Run /ant:init first." and stop
|
|
41
|
+
3. Extract current_phase and phase name from plan.phases[current_phase - 1].name
|
|
42
|
+
4. Display brief resumption context:
|
|
43
|
+
```
|
|
44
|
+
🔄 Resuming: Phase X - Name
|
|
45
|
+
```
|
|
46
|
+
(If HANDOFF.md exists, this provides orientation before the build proceeds)
|
|
47
|
+
|
|
48
|
+
After displaying context, run: `bash .aether/aether-utils.sh unload-state` to release the lock.
|
|
49
|
+
|
|
18
50
|
### Step 1: Validate + Read State
|
|
19
51
|
|
|
20
52
|
**Parse $ARGUMENTS:**
|
|
21
53
|
1. Extract the phase number (first argument)
|
|
22
54
|
2. Check remaining arguments for flags:
|
|
23
55
|
- If contains `--verbose` or `-v`: set `verbose_mode = true`
|
|
24
|
-
-
|
|
56
|
+
- If contains `--model <name>` or `-m <name>`: set `cli_model_override = <name>`
|
|
57
|
+
- Otherwise: set defaults
|
|
25
58
|
|
|
26
59
|
If the phase number is empty or not a number:
|
|
27
60
|
|
|
28
61
|
```
|
|
29
|
-
Usage: /ant:build <phase_number> [--verbose|-v]
|
|
62
|
+
Usage: /ant:build <phase_number> [--verbose|-v] [--model <model>|-m <model>]
|
|
30
63
|
|
|
31
64
|
Options:
|
|
32
|
-
--verbose, -v
|
|
65
|
+
--verbose, -v Show full completion details (spawn tree, TDD, patterns)
|
|
66
|
+
--model, -m <name> Override model for this build (one-time)
|
|
33
67
|
|
|
34
68
|
Examples:
|
|
35
69
|
/ant:build 1 Build Phase 1 (compact output)
|
|
36
70
|
/ant:build 1 --verbose Build Phase 1 (full details)
|
|
37
71
|
/ant:build 3 -v Build Phase 3 (full details)
|
|
72
|
+
/ant:build 1 --model glm-5 Build Phase 1 with glm-5 for all workers
|
|
38
73
|
```
|
|
39
74
|
|
|
40
75
|
Stop here.
|
|
41
76
|
|
|
77
|
+
**Validate CLI model override (if provided):**
|
|
78
|
+
If `cli_model_override` is set:
|
|
79
|
+
1. Validate the model: `bash .aether/aether-utils.sh model-profile validate "$cli_model_override"`
|
|
80
|
+
2. Parse JSON result - if `.result.valid` is false:
|
|
81
|
+
- Display: `Error: Invalid model "$cli_model_override"`
|
|
82
|
+
- Display: `Valid models: {list from .result.models}`
|
|
83
|
+
- Stop here
|
|
84
|
+
3. If valid: Display `Using override model: {model}`
|
|
85
|
+
|
|
42
86
|
Read `.aether/data/COLONY_STATE.json`.
|
|
43
87
|
|
|
44
88
|
**Auto-upgrade old state:**
|
|
@@ -235,13 +279,33 @@ CONSTRAINTS: (none)
|
|
|
235
279
|
The `archaeology_context` will be injected into builder prompts in Step 5.1 (see below).
|
|
236
280
|
If this step was skipped (no existing files modified), the archaeology section is omitted from builder prompts.
|
|
237
281
|
|
|
238
|
-
### Step 5:
|
|
282
|
+
### Step 5: Initialize Swarm Display and Analyze Tasks
|
|
239
283
|
|
|
240
284
|
**YOU (the Queen) will spawn workers directly. Do NOT delegate to a single Prime Worker.**
|
|
241
285
|
|
|
242
|
-
|
|
286
|
+
**Initialize visual swarm tracking:**
|
|
243
287
|
```bash
|
|
288
|
+
# Generate unique build ID
|
|
289
|
+
build_id="build-$(date +%s)"
|
|
290
|
+
|
|
291
|
+
# Initialize swarm display for this build
|
|
292
|
+
bash .aether/aether-utils.sh swarm-display-init "$build_id"
|
|
293
|
+
|
|
294
|
+
# Log phase start
|
|
244
295
|
bash .aether/aether-utils.sh activity-log "EXECUTING" "Queen" "Phase {id}: {name} - Queen dispatching workers"
|
|
296
|
+
|
|
297
|
+
# Display animated header
|
|
298
|
+
bash .aether/aether-utils.sh swarm-display-update "Queen" "prime" "excavating" "Phase {id}: {name}" "Colony" '{"read":0,"grep":0,"edit":0,"bash":0}' 10 "fungus_garden" 0
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
**Show real-time display header:**
|
|
302
|
+
```
|
|
303
|
+
🔨🐜 COLONY BUILD INITIATED 🐜🔨
|
|
304
|
+
═══════════════════════════════════════════════════
|
|
305
|
+
Phase {id}: {name}
|
|
306
|
+
Build ID: {build_id}
|
|
307
|
+
|
|
308
|
+
Launching swarm display... (visual tracking enabled)
|
|
245
309
|
```
|
|
246
310
|
|
|
247
311
|
Analyze the phase tasks:
|
|
@@ -288,9 +352,10 @@ Total: {N} Builders + 1 Watcher + 1 Chaos = {N+2} spawns
|
|
|
288
352
|
|
|
289
353
|
For each Wave 1 task, use Task tool with `subagent_type="general"` and `run_in_background: true`:
|
|
290
354
|
|
|
291
|
-
Log each spawn:
|
|
355
|
+
Log each spawn and update swarm display:
|
|
292
356
|
```bash
|
|
293
357
|
bash .aether/aether-utils.sh spawn-log "Queen" "builder" "{ant_name}" "{task_description}"
|
|
358
|
+
bash .aether/aether-utils.sh swarm-display-update "{ant_name}" "builder" "excavating" "{task_description}" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "fungus_garden" 10
|
|
294
359
|
```
|
|
295
360
|
|
|
296
361
|
**Builder Worker Prompt Template:**
|
|
@@ -392,11 +457,15 @@ For each spawned worker, call TaskOutput with `block: true` to wait for completi
|
|
|
392
457
|
|
|
393
458
|
Store all results for synthesis in Step 5.6.
|
|
394
459
|
|
|
395
|
-
For each completed worker, log:
|
|
460
|
+
For each completed worker, log and update swarm display:
|
|
396
461
|
```bash
|
|
397
462
|
bash .aether/aether-utils.sh spawn-complete "{ant_name}" "completed" "{summary}"
|
|
463
|
+
bash .aether/aether-utils.sh swarm-display-update "{ant_name}" "builder" "completed" "{task_description}" "Queen" '{"read":5,"grep":3,"edit":2,"bash":1}' 100 "fungus_garden" 100
|
|
398
464
|
```
|
|
399
465
|
|
|
466
|
+
**Update swarm display with accumulated tool usage:**
|
|
467
|
+
As workers complete, accumulate their actual tool usage (Read, Grep, Edit, Bash counts from their activity logs) and update the swarm display to show live progress.
|
|
468
|
+
|
|
400
469
|
**Only proceed to Step 5.3 after ALL Wave 1 TaskOutput calls have returned.**
|
|
401
470
|
|
|
402
471
|
### Step 5.3: Spawn Wave 2+ Workers (Sequential Waves)
|
|
@@ -409,6 +478,7 @@ Repeat Step 5.1-5.2 for each subsequent wave, waiting for previous wave to compl
|
|
|
409
478
|
|
|
410
479
|
```bash
|
|
411
480
|
bash .aether/aether-utils.sh spawn-log "Queen" "watcher" "{watcher_name}" "Independent verification"
|
|
481
|
+
bash .aether/aether-utils.sh swarm-display-update "{watcher_name}" "watcher" "observing" "Verification in progress" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "nursery" 50
|
|
412
482
|
```
|
|
413
483
|
|
|
414
484
|
**Watcher Worker Prompt:**
|
|
@@ -508,6 +578,11 @@ Call TaskOutput with `block: true` using the Watcher's task_id:
|
|
|
508
578
|
- Parse: verification_passed, issues_found, quality_score, recommendation
|
|
509
579
|
- Store results for synthesis in Step 5.6
|
|
510
580
|
|
|
581
|
+
**Update swarm display when Watcher completes:**
|
|
582
|
+
```bash
|
|
583
|
+
bash .aether/aether-utils.sh swarm-display-update "{watcher_name}" "watcher" "completed" "Verification complete" "Queen" '{"read":3,"grep":2,"edit":0,"bash":1}' 100 "nursery" 100
|
|
584
|
+
```
|
|
585
|
+
|
|
511
586
|
**Only proceed to Step 5.4.2 after Watcher TaskOutput has returned.**
|
|
512
587
|
|
|
513
588
|
### Step 5.4.2: Spawn Chaos Ant for Resilience Testing
|
|
@@ -518,6 +593,7 @@ Generate a chaos ant name and log the spawn:
|
|
|
518
593
|
```bash
|
|
519
594
|
bash .aether/aether-utils.sh generate-ant-name "chaos"
|
|
520
595
|
bash .aether/aether-utils.sh spawn-log "Queen" "chaos" "{chaos_name}" "Resilience testing of Phase {id} work"
|
|
596
|
+
bash .aether/aether-utils.sh swarm-display-update "{chaos_name}" "chaos" "probing" "Resilience testing" "Queen" '{"read":0,"grep":0,"edit":0,"bash":0}' 0 "refuse_pile" 75
|
|
521
597
|
```
|
|
522
598
|
|
|
523
599
|
**Retrieve existing flags for this phase** (to avoid duplicate findings):
|
|
@@ -592,12 +668,16 @@ Log the flag:
|
|
|
592
668
|
bash .aether/aether-utils.sh activity-log "FLAG" "Chaos" "Created blocker: {finding.title}"
|
|
593
669
|
```
|
|
594
670
|
|
|
595
|
-
Log
|
|
671
|
+
Log the flag:
|
|
596
672
|
```bash
|
|
597
|
-
bash .aether/aether-utils.sh
|
|
673
|
+
bash .aether/aether-utils.sh activity-log "FLAG" "Chaos" "Created blocker: {finding.title}"
|
|
598
674
|
```
|
|
599
675
|
|
|
600
|
-
|
|
676
|
+
Log chaos ant completion and update swarm display:
|
|
677
|
+
```bash
|
|
678
|
+
bash .aether/aether-utils.sh spawn-complete "{chaos_name}" "completed" "{summary}"
|
|
679
|
+
bash .aether/aether-utils.sh swarm-display-update "{chaos_name}" "chaos" "completed" "Resilience testing done" "Queen" '{"read":2,"grep":1,"edit":0,"bash":0}' 100 "refuse_pile" 100
|
|
680
|
+
```
|
|
601
681
|
|
|
602
682
|
### Step 5.5: Create Flags for Verification Failures
|
|
603
683
|
|
|
@@ -760,7 +840,23 @@ Use AskUserQuestion to get approval. Record in events:
|
|
|
760
840
|
|
|
761
841
|
**This step runs ONLY after synthesis is complete. All values come from actual worker results.**
|
|
762
842
|
|
|
763
|
-
|
|
843
|
+
**First, render the final swarm display showing all completed workers:**
|
|
844
|
+
```bash
|
|
845
|
+
# Final swarm display update - mark Queen as completed
|
|
846
|
+
bash .aether/aether-utils.sh swarm-display-update "Queen" "prime" "completed" "Phase {id} complete" "Colony" '{"read":10,"grep":5,"edit":5,"bash":2}' 100 "fungus_garden" 100
|
|
847
|
+
|
|
848
|
+
# Render the final swarm display
|
|
849
|
+
bash .aether/aether-utils.sh swarm-display-render "$build_id"
|
|
850
|
+
```
|
|
851
|
+
|
|
852
|
+
The swarm display will show:
|
|
853
|
+
- 🐜 All workers with their caste emojis (🔨 Builder, 👁️ Watcher, 🎲 Chaos)
|
|
854
|
+
- 📖 Tool usage stats (Read, Grep, Edit, Bash counts)
|
|
855
|
+
- 🏠 Chamber activity map (Fungus Garden, Nursery, Refuse Pile)
|
|
856
|
+
- ✅ Progress bars at 100% for completed work
|
|
857
|
+
- 🌈 Color-coded by caste
|
|
858
|
+
|
|
859
|
+
**Then display build summary based on synthesis results AND `verbose_mode` from Step 1:**
|
|
764
860
|
|
|
765
861
|
**If verbose_mode = false (compact output, ~12 lines):**
|
|
766
862
|
|
|
@@ -719,6 +719,48 @@ Set `last_commit_suggestion_phase` to `{phase_id}` in COLONY_STATE.json (add the
|
|
|
719
719
|
|
|
720
720
|
**Error handling:** If any git command fails (not a repo, merge conflict, pre-commit hook rejection), display the error output and continue to the next step. The commit suggestion is advisory only -- it never blocks the flow.
|
|
721
721
|
|
|
722
|
+
Continue to Step 2.7 (Context Clear Suggestion), then to Step 2.5 (Project Completion) or Step 3 (Display Result).
|
|
723
|
+
|
|
724
|
+
### Step 2.7: Context Clear Suggestion (Optional)
|
|
725
|
+
|
|
726
|
+
**This step is non-blocking. Skipping does not affect phase advancement.**
|
|
727
|
+
|
|
728
|
+
After committing (or skipping commit), suggest clearing context to refresh before the next phase.
|
|
729
|
+
|
|
730
|
+
1. **Display the suggestion:**
|
|
731
|
+
```
|
|
732
|
+
──────────────────────────────────────────────────
|
|
733
|
+
Context Refresh
|
|
734
|
+
──────────────────────────────────────────────────
|
|
735
|
+
|
|
736
|
+
State is fully persisted and committed.
|
|
737
|
+
Phase {next_id} is ready to build.
|
|
738
|
+
|
|
739
|
+
──────────────────────────────────────────────────
|
|
740
|
+
```
|
|
741
|
+
|
|
742
|
+
2. **Use AskUserQuestion:**
|
|
743
|
+
```
|
|
744
|
+
Clear context now?
|
|
745
|
+
|
|
746
|
+
1. Yes, clear context then run /ant:build {next_id}
|
|
747
|
+
2. No, continue in current context
|
|
748
|
+
```
|
|
749
|
+
|
|
750
|
+
3. **If option 1 ("Yes, clear context"):**
|
|
751
|
+
|
|
752
|
+
**IMPORTANT:** OpenCode does not support programmatic /clear. Display instructions:
|
|
753
|
+
```
|
|
754
|
+
Please type: /clear
|
|
755
|
+
|
|
756
|
+
Then run: /ant:build {next_id}
|
|
757
|
+
```
|
|
758
|
+
|
|
759
|
+
Record the suggestion: Set `context_clear_suggested` to `true` in COLONY_STATE.json.
|
|
760
|
+
|
|
761
|
+
4. **If option 2 ("No, continue in current context"):**
|
|
762
|
+
Display: `Continuing in current context. State is saved.`
|
|
763
|
+
|
|
722
764
|
Continue to Step 2.5 (Project Completion) or Step 3 (Display Result).
|
|
723
765
|
|
|
724
766
|
### Step 2.5: Project Completion
|
|
@@ -781,7 +823,7 @@ Output:
|
|
|
781
823
|
/ant:phase {next_id} 📋 Review phase details first
|
|
782
824
|
/ant:focus "<area>" 🎯 Guide colony attention
|
|
783
825
|
|
|
784
|
-
💾 State persisted —
|
|
826
|
+
💾 State persisted — context clear suggested above
|
|
785
827
|
```
|
|
786
828
|
|
|
787
829
|
**IMPORTANT:** In the "Next Steps" section above, substitute the actual phase number for `{next_id}` (calculated in Step 2 as `current_phase + 1`). For example, if advancing to phase 4, output `/ant:build 4` not `/ant:build {next_id}`.
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ant:maturity
|
|
3
|
+
description: "👑🐜🏛️🐜👑 View colony maturity journey with ASCII art anthill"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are the **Queen**. Display the colony's maturity journey.
|
|
7
|
+
|
|
8
|
+
## Instructions
|
|
9
|
+
|
|
10
|
+
### Step 1: Detect Current Milestone
|
|
11
|
+
|
|
12
|
+
Run: `bash .aether/aether-utils.sh milestone-detect`
|
|
13
|
+
|
|
14
|
+
Parse JSON result to get:
|
|
15
|
+
- `milestone`: Current milestone name (First Mound, Open Chambers, Brood Stable, Ventilated Nest, Sealed Chambers, Crowned Anthill)
|
|
16
|
+
- `version`: Computed version string
|
|
17
|
+
- `phases_completed`: Number of completed phases
|
|
18
|
+
- `total_phases`: Total phases in plan
|
|
19
|
+
|
|
20
|
+
### Step 2: Read Colony State
|
|
21
|
+
|
|
22
|
+
Read `.aether/data/COLONY_STATE.json` to get:
|
|
23
|
+
- `goal`: Colony goal
|
|
24
|
+
- `initialized_at`: When colony was started
|
|
25
|
+
|
|
26
|
+
Calculate colony age from initialized_at to now (in days).
|
|
27
|
+
|
|
28
|
+
### Step 3: Display Maturity Journey
|
|
29
|
+
|
|
30
|
+
Display header:
|
|
31
|
+
```
|
|
32
|
+
.-.
|
|
33
|
+
(o o) AETHER COLONY
|
|
34
|
+
| O | Maturity Journey
|
|
35
|
+
`-`
|
|
36
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
37
|
+
|
|
38
|
+
👑 Goal: {goal (truncated to 50 chars)}
|
|
39
|
+
🏆 Current: {milestone} ({version})
|
|
40
|
+
📍 Progress: {phases_completed} of {total_phases} phases
|
|
41
|
+
📅 Colony Age: {N} days
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Step 4: Show ASCII Art Anthill
|
|
45
|
+
|
|
46
|
+
Read the ASCII art file for the current milestone:
|
|
47
|
+
- First Mound → `.aether/visualizations/anthill-stages/first-mound.txt`
|
|
48
|
+
- Open Chambers → `.aether/visualizations/anthill-stages/open-chambers.txt`
|
|
49
|
+
- Brood Stable → `.aether/visualizations/anthill-stages/brood-stable.txt`
|
|
50
|
+
- Ventilated Nest → `.aether/visualizations/anthill-stages/ventilated-nest.txt`
|
|
51
|
+
- Sealed Chambers → `.aether/visualizations/anthill-stages/sealed-chambers.txt`
|
|
52
|
+
- Crowned Anthill → `.aether/visualizations/anthill-stages/crowned-anthill.txt`
|
|
53
|
+
|
|
54
|
+
Display the ASCII art with current milestone highlighted (bold/bright).
|
|
55
|
+
|
|
56
|
+
### Step 5: Show Journey Progress Bar
|
|
57
|
+
|
|
58
|
+
Display progress through all milestones:
|
|
59
|
+
|
|
60
|
+
```
|
|
61
|
+
Journey Progress:
|
|
62
|
+
|
|
63
|
+
[█░░░░░] First Mound (0 phases) - Complete
|
|
64
|
+
[██░░░░] Open Chambers (1-3 phases) - Complete
|
|
65
|
+
[███░░░] Brood Stable (4-6 phases) - Complete
|
|
66
|
+
[████░░] Ventilated Nest (7-10 phases) - Current
|
|
67
|
+
[█████░] Sealed Chambers (11-14 phases)
|
|
68
|
+
[██████] Crowned Anthill (15+ phases)
|
|
69
|
+
|
|
70
|
+
Next: Ventilated Nest → Sealed Chambers
|
|
71
|
+
Complete {N} more phases to advance
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Calculate which milestones are complete vs current vs upcoming based on phases_completed.
|
|
75
|
+
|
|
76
|
+
### Step 6: Show Colony Statistics
|
|
77
|
+
|
|
78
|
+
Display summary stats:
|
|
79
|
+
```
|
|
80
|
+
Colony Statistics:
|
|
81
|
+
🐜 Phases Completed: {phases_completed}
|
|
82
|
+
📋 Total Phases: {total_phases}
|
|
83
|
+
📅 Days Active: {colony_age_days}
|
|
84
|
+
🏆 Current Milestone: {milestone}
|
|
85
|
+
🎯 Completion: {percent}%
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
### Edge Cases
|
|
89
|
+
|
|
90
|
+
- If milestone file doesn't exist: Show error "Milestone visualization not found"
|
|
91
|
+
- If COLONY_STATE.json missing: "No colony initialized. Run /ant:init first."
|
|
92
|
+
- If phases_completed is 0: All milestones show as upcoming except First Mound
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ant:verify-castes
|
|
3
|
+
description: "Verify colony caste assignments and system status"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are the **Queen**. Display the caste assignments and system status.
|
|
7
|
+
|
|
8
|
+
## Step 1: Show Caste Assignments
|
|
9
|
+
|
|
10
|
+
Display the colony caste structure:
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
Aether Colony Caste System
|
|
14
|
+
═══════════════════════════════════════════
|
|
15
|
+
|
|
16
|
+
CASTE ASSIGNMENTS
|
|
17
|
+
─────────────────
|
|
18
|
+
👑 Prime - Colony coordination and strategic planning
|
|
19
|
+
🏺 Archaeologist - Git history analysis and pattern excavation
|
|
20
|
+
🏛️ Architect - System design and documentation
|
|
21
|
+
🔮 Oracle - Deep research and foresight
|
|
22
|
+
🗺️ Route Setter - Task decomposition and planning
|
|
23
|
+
🔨 Builder - Implementation and coding
|
|
24
|
+
👁️ Watcher - Verification and testing
|
|
25
|
+
🔍 Scout - Research and exploration
|
|
26
|
+
🎲 Chaos - Edge case testing and resilience probing
|
|
27
|
+
🧭 Colonizer - Environment setup and exploration
|
|
28
|
+
|
|
29
|
+
───────────────────────────────────────────
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Step 2: Check System Status
|
|
33
|
+
|
|
34
|
+
Run using Bash tool: `bash .aether/aether-utils.sh version-check 2>/dev/null || echo "Utils available"`
|
|
35
|
+
|
|
36
|
+
Check LiteLLM proxy status:
|
|
37
|
+
```bash
|
|
38
|
+
curl -s http://localhost:4000/health 2>/dev/null | grep -q "healthy" && echo "✓ Proxy healthy" || echo "⚠ Proxy not running"
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Step 3: Show Current Session Info
|
|
42
|
+
|
|
43
|
+
```
|
|
44
|
+
SESSION INFORMATION
|
|
45
|
+
───────────────────
|
|
46
|
+
All workers in this session use the same model configuration.
|
|
47
|
+
To change models, restart Claude Code with different settings:
|
|
48
|
+
|
|
49
|
+
export ANTHROPIC_BASE_URL=http://localhost:4000
|
|
50
|
+
export ANTHROPIC_AUTH_TOKEN=sk-litellm-local
|
|
51
|
+
export ANTHROPIC_MODEL=<model-name>
|
|
52
|
+
claude
|
|
53
|
+
|
|
54
|
+
Available models (via LiteLLM proxy):
|
|
55
|
+
• glm-5 - Complex reasoning, architecture, planning
|
|
56
|
+
• kimi-k2.5 - Fast coding, implementation
|
|
57
|
+
• minimax-2.5 - Validation, research, exploration
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Step 4: Summary
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
═══════════════════════════════════════════
|
|
64
|
+
System Status
|
|
65
|
+
═══════════════════════════════════════════
|
|
66
|
+
Utils: ✓ Operational
|
|
67
|
+
Proxy: {status from Step 2}
|
|
68
|
+
Castes: 10 defined
|
|
69
|
+
|
|
70
|
+
Note: Model-per-caste routing was attempted but is not
|
|
71
|
+
possible with Claude Code's Task tool (no env var support).
|
|
72
|
+
See archived config: .aether/archive/model-routing/
|
|
73
|
+
Tag: model-routing-v1-archived
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Historical Note
|
|
77
|
+
|
|
78
|
+
A model-per-caste system was designed and implemented but cannot
|
|
79
|
+
function due to Claude Code Task tool limitations. The complete
|
|
80
|
+
configuration is archived in `.aether/archive/model-routing/`.
|
|
81
|
+
|
|
82
|
+
To view the archived configuration:
|
|
83
|
+
```bash
|
|
84
|
+
git show model-routing-v1-archived
|
|
85
|
+
```
|
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,15 @@ All notable changes to the Aether Colony project will be documented in this file
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [3.1.2] - 2026-02-15
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- **Swarm Display Integration in Build Command** — The visualization system was fully implemented but never integrated into `/ant:build`. Added `swarm-display-init` at build start, `swarm-display-update` calls when spawning builders/watchers/chaos ants, progress updates when workers complete (updating to 100% completion), and final `swarm-display-render` at build completion. The build now shows real-time ant-themed visualization with caste emojis, colors, tool usage stats, and chamber activity maps. (`.claude/commands/ant/build.md`, `.opencode/commands/ant/build.md`)
|
|
12
|
+
- **Missing swarm-display-render Command** — Added new `swarm-display-render` command to `aether-utils.sh` that executes the visualization script to render the current swarm state to terminal. (`.aether/aether-utils.sh`)
|
|
13
|
+
|
|
14
|
+
### Changed
|
|
15
|
+
- **OpenCode Build Command Parity** — Synchronized OpenCode build.md with Claude version: added `--model` flag support, proxy health check (Step 0.6), colony state loading (Step 0.5), and full swarm display integration. (`.opencode/commands/ant/build.md`)
|
|
16
|
+
|
|
8
17
|
## [3.1.1] - 2026-02-15
|
|
9
18
|
|
|
10
19
|
### Fixed
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "aether-colony",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.2",
|
|
4
4
|
"description": "Multi-agent system using ant colony intelligence for Claude Code and OpenCode — workers self-organize via pheromone signals",
|
|
5
5
|
"bin": {
|
|
6
|
-
"aether": "
|
|
6
|
+
"aether": "bin/cli.js"
|
|
7
7
|
},
|
|
8
8
|
"files": [
|
|
9
9
|
"bin/",
|