aether-colony 5.3.2 → 5.4.0
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/.aether/aether-utils.sh +181 -5
- package/.aether/commands/archaeology.yaml +3 -3
- package/.aether/commands/build.yaml +80 -45
- package/.aether/commands/chaos.yaml +7 -7
- package/.aether/commands/colonize.yaml +17 -17
- package/.aether/commands/continue.yaml +40 -40
- package/.aether/commands/council.yaml +6 -6
- package/.aether/commands/data-clean.yaml +3 -3
- package/.aether/commands/dream.yaml +2 -2
- package/.aether/commands/entomb.yaml +12 -12
- package/.aether/commands/export-signals.yaml +2 -2
- package/.aether/commands/feedback.yaml +6 -6
- package/.aether/commands/flag.yaml +2 -2
- package/.aether/commands/flags.yaml +4 -4
- package/.aether/commands/focus.yaml +6 -6
- package/.aether/commands/help.yaml +1 -1
- package/.aether/commands/history.yaml +1 -1
- package/.aether/commands/import-signals.yaml +2 -2
- package/.aether/commands/init.yaml +44 -27
- package/.aether/commands/insert-phase.yaml +1 -1
- package/.aether/commands/interpret.yaml +2 -2
- package/.aether/commands/lay-eggs.yaml +3 -3
- package/.aether/commands/maturity.yaml +2 -2
- package/.aether/commands/memory-details.yaml +1 -1
- package/.aether/commands/migrate-state.yaml +1 -1
- package/.aether/commands/oracle.yaml +147 -82
- package/.aether/commands/organize.yaml +5 -5
- package/.aether/commands/patrol.yaml +8 -8
- package/.aether/commands/pause-colony.yaml +7 -7
- package/.aether/commands/phase.yaml +1 -1
- package/.aether/commands/pheromones.yaml +1 -1
- package/.aether/commands/plan.yaml +14 -14
- package/.aether/commands/quick.yaml +4 -4
- package/.aether/commands/redirect.yaml +6 -6
- package/.aether/commands/resume-colony.yaml +9 -9
- package/.aether/commands/resume.yaml +5 -38
- package/.aether/commands/run.yaml +10 -10
- package/.aether/commands/seal.yaml +33 -33
- package/.aether/commands/skill-create.yaml +4 -4
- package/.aether/commands/status.yaml +14 -14
- package/.aether/commands/swarm.yaml +14 -14
- package/.aether/commands/tunnels.yaml +7 -7
- package/.aether/commands/update.yaml +1 -1
- package/.aether/commands/verify-castes.yaml +3 -3
- package/.aether/commands/watch.yaml +15 -15
- package/.aether/docs/command-playbooks/build-complete.md +48 -15
- package/.aether/docs/command-playbooks/build-context.md +11 -11
- package/.aether/docs/command-playbooks/build-full.md +76 -76
- package/.aether/docs/command-playbooks/build-prep.md +10 -10
- package/.aether/docs/command-playbooks/build-verify.md +27 -27
- package/.aether/docs/command-playbooks/build-wave.md +38 -38
- package/.aether/docs/command-playbooks/continue-advance.md +60 -27
- package/.aether/docs/command-playbooks/continue-finalize.md +25 -11
- package/.aether/docs/command-playbooks/continue-full.md +60 -46
- package/.aether/docs/command-playbooks/continue-gates.md +18 -18
- package/.aether/docs/command-playbooks/continue-verify.md +10 -10
- package/.aether/docs/source-of-truth-map.md +10 -10
- package/.aether/docs/structural-learning-stack.md +283 -0
- package/.aether/templates/colony-state-template.json +1 -0
- package/.aether/utils/consolidation-seal.sh +196 -0
- package/.aether/utils/consolidation.sh +127 -0
- package/.aether/utils/curation-ants/archivist.sh +97 -0
- package/.aether/utils/curation-ants/critic.sh +214 -0
- package/.aether/utils/curation-ants/herald.sh +102 -0
- package/.aether/utils/curation-ants/janitor.sh +121 -0
- package/.aether/utils/curation-ants/librarian.sh +99 -0
- package/.aether/utils/curation-ants/nurse.sh +153 -0
- package/.aether/utils/curation-ants/orchestrator.sh +181 -0
- package/.aether/utils/curation-ants/scribe.sh +164 -0
- package/.aether/utils/curation-ants/sentinel.sh +119 -0
- package/.aether/utils/event-bus.sh +301 -0
- package/.aether/utils/graph.sh +559 -0
- package/.aether/utils/instinct-store.sh +401 -0
- package/.aether/utils/learning.sh +79 -7
- package/.aether/utils/oracle/oracle-stop-hook.sh +896 -0
- package/.aether/utils/session.sh +13 -0
- package/.aether/utils/state-api.sh +1 -1
- package/.aether/utils/trust-scoring.sh +347 -0
- package/.aether/utils/worktree.sh +97 -0
- package/.claude/commands/ant/archaeology.md +2 -2
- package/.claude/commands/ant/chaos.md +4 -4
- package/.claude/commands/ant/colonize.md +9 -9
- package/.claude/commands/ant/council.md +6 -6
- package/.claude/commands/ant/data-clean.md +3 -3
- package/.claude/commands/ant/dream.md +2 -2
- package/.claude/commands/ant/entomb.md +9 -9
- package/.claude/commands/ant/export-signals.md +2 -2
- package/.claude/commands/ant/feedback.md +4 -4
- package/.claude/commands/ant/flag.md +2 -2
- package/.claude/commands/ant/flags.md +4 -4
- package/.claude/commands/ant/focus.md +4 -4
- package/.claude/commands/ant/help.md +1 -1
- package/.claude/commands/ant/history.md +1 -1
- package/.claude/commands/ant/import-signals.md +2 -2
- package/.claude/commands/ant/init.md +44 -27
- package/.claude/commands/ant/insert-phase.md +1 -1
- package/.claude/commands/ant/interpret.md +2 -2
- package/.claude/commands/ant/lay-eggs.md +2 -2
- package/.claude/commands/ant/maturity.md +2 -2
- package/.claude/commands/ant/memory-details.md +1 -1
- package/.claude/commands/ant/migrate-state.md +1 -1
- package/.claude/commands/ant/oracle.md +78 -42
- package/.claude/commands/ant/organize.md +3 -3
- package/.claude/commands/ant/patrol.md +8 -8
- package/.claude/commands/ant/pause-colony.md +5 -5
- package/.claude/commands/ant/phase.md +1 -1
- package/.claude/commands/ant/pheromones.md +1 -1
- package/.claude/commands/ant/plan.md +8 -8
- package/.claude/commands/ant/quick.md +4 -4
- package/.claude/commands/ant/redirect.md +4 -4
- package/.claude/commands/ant/resume-colony.md +5 -5
- package/.claude/commands/ant/resume.md +17 -29
- package/.claude/commands/ant/run.md +10 -10
- package/.claude/commands/ant/seal.md +25 -25
- package/.claude/commands/ant/skill-create.md +2 -2
- package/.claude/commands/ant/status.md +14 -14
- package/.claude/commands/ant/swarm.md +14 -14
- package/.claude/commands/ant/tunnels.md +4 -4
- package/.claude/commands/ant/update.md +1 -1
- package/.claude/commands/ant/verify-castes.md +2 -2
- package/.claude/commands/ant/watch.md +8 -8
- package/.opencode/commands/ant/archaeology.md +1 -1
- package/.opencode/commands/ant/build.md +80 -45
- package/.opencode/commands/ant/chaos.md +3 -3
- package/.opencode/commands/ant/colonize.md +8 -8
- package/.opencode/commands/ant/continue.md +40 -40
- package/.opencode/commands/ant/council.md +5 -5
- package/.opencode/commands/ant/data-clean.md +2 -2
- package/.opencode/commands/ant/dream.md +1 -1
- package/.opencode/commands/ant/entomb.md +3 -3
- package/.opencode/commands/ant/export-signals.md +1 -1
- package/.opencode/commands/ant/feedback.md +2 -2
- package/.opencode/commands/ant/flag.md +1 -1
- package/.opencode/commands/ant/flags.md +3 -3
- package/.opencode/commands/ant/focus.md +2 -2
- package/.opencode/commands/ant/import-signals.md +1 -1
- package/.opencode/commands/ant/init.md +44 -27
- package/.opencode/commands/ant/insert-phase.md +1 -1
- package/.opencode/commands/ant/interpret.md +1 -1
- package/.opencode/commands/ant/lay-eggs.md +2 -2
- package/.opencode/commands/ant/maturity.md +1 -1
- package/.opencode/commands/ant/memory-details.md +1 -1
- package/.opencode/commands/ant/oracle.md +69 -40
- package/.opencode/commands/ant/organize.md +2 -2
- package/.opencode/commands/ant/patrol.md +8 -8
- package/.opencode/commands/ant/pause-colony.md +2 -2
- package/.opencode/commands/ant/pheromones.md +1 -1
- package/.opencode/commands/ant/plan.md +6 -6
- package/.opencode/commands/ant/quick.md +4 -4
- package/.opencode/commands/ant/redirect.md +2 -2
- package/.opencode/commands/ant/resume-colony.md +4 -4
- package/.opencode/commands/ant/resume.md +5 -17
- package/.opencode/commands/ant/run.md +10 -10
- package/.opencode/commands/ant/seal.md +8 -8
- package/.opencode/commands/ant/skill-create.md +2 -2
- package/.opencode/commands/ant/status.md +10 -10
- package/.opencode/commands/ant/tunnels.md +3 -3
- package/.opencode/commands/ant/verify-castes.md +1 -1
- package/.opencode/commands/ant/watch.md +7 -7
- package/CHANGELOG.md +83 -0
- package/README.md +22 -9
- package/bin/cli.js +118 -3
- package/bin/lib/binary-downloader.js +267 -0
- package/bin/lib/update-transaction.js +27 -3
- package/bin/lib/version-gate.js +179 -0
- package/bin/npx-entry.js +0 -0
- package/package.json +1 -1
- package/.aether/agents/aether-ambassador.md +0 -140
- package/.aether/agents/aether-archaeologist.md +0 -108
- package/.aether/agents/aether-architect.md +0 -133
- package/.aether/agents/aether-auditor.md +0 -144
- package/.aether/agents/aether-builder.md +0 -184
- package/.aether/agents/aether-chaos.md +0 -115
- package/.aether/agents/aether-chronicler.md +0 -122
- package/.aether/agents/aether-gatekeeper.md +0 -116
- package/.aether/agents/aether-includer.md +0 -117
- package/.aether/agents/aether-keeper.md +0 -177
- package/.aether/agents/aether-measurer.md +0 -128
- package/.aether/agents/aether-oracle.md +0 -137
- package/.aether/agents/aether-probe.md +0 -133
- package/.aether/agents/aether-queen.md +0 -286
- package/.aether/agents/aether-route-setter.md +0 -130
- package/.aether/agents/aether-sage.md +0 -106
- package/.aether/agents/aether-scout.md +0 -101
- package/.aether/agents/aether-surveyor-disciplines.md +0 -391
- package/.aether/agents/aether-surveyor-nest.md +0 -329
- package/.aether/agents/aether-surveyor-pathogens.md +0 -264
- package/.aether/agents/aether-surveyor-provisions.md +0 -334
- package/.aether/agents/aether-tracker.md +0 -137
- package/.aether/agents/aether-watcher.md +0 -174
- package/.aether/agents/aether-weaver.md +0 -130
- package/.aether/commands/claude/archaeology.md +0 -334
- package/.aether/commands/claude/build.md +0 -65
- package/.aether/commands/claude/chaos.md +0 -336
- package/.aether/commands/claude/colonize.md +0 -259
- package/.aether/commands/claude/continue.md +0 -60
- package/.aether/commands/claude/council.md +0 -507
- package/.aether/commands/claude/data-clean.md +0 -81
- package/.aether/commands/claude/dream.md +0 -268
- package/.aether/commands/claude/entomb.md +0 -498
- package/.aether/commands/claude/export-signals.md +0 -57
- package/.aether/commands/claude/feedback.md +0 -96
- package/.aether/commands/claude/flag.md +0 -151
- package/.aether/commands/claude/flags.md +0 -169
- package/.aether/commands/claude/focus.md +0 -76
- package/.aether/commands/claude/help.md +0 -154
- package/.aether/commands/claude/history.md +0 -140
- package/.aether/commands/claude/import-signals.md +0 -71
- package/.aether/commands/claude/init.md +0 -505
- package/.aether/commands/claude/insert-phase.md +0 -105
- package/.aether/commands/claude/interpret.md +0 -278
- package/.aether/commands/claude/lay-eggs.md +0 -210
- package/.aether/commands/claude/maturity.md +0 -113
- package/.aether/commands/claude/memory-details.md +0 -77
- package/.aether/commands/claude/migrate-state.md +0 -171
- package/.aether/commands/claude/oracle.md +0 -642
- package/.aether/commands/claude/organize.md +0 -232
- package/.aether/commands/claude/patrol.md +0 -620
- package/.aether/commands/claude/pause-colony.md +0 -233
- package/.aether/commands/claude/phase.md +0 -115
- package/.aether/commands/claude/pheromones.md +0 -156
- package/.aether/commands/claude/plan.md +0 -693
- package/.aether/commands/claude/preferences.md +0 -65
- package/.aether/commands/claude/quick.md +0 -100
- package/.aether/commands/claude/redirect.md +0 -76
- package/.aether/commands/claude/resume-colony.md +0 -197
- package/.aether/commands/claude/resume.md +0 -388
- package/.aether/commands/claude/run.md +0 -231
- package/.aether/commands/claude/seal.md +0 -774
- package/.aether/commands/claude/skill-create.md +0 -286
- package/.aether/commands/claude/status.md +0 -410
- package/.aether/commands/claude/swarm.md +0 -349
- package/.aether/commands/claude/tunnels.md +0 -426
- package/.aether/commands/claude/update.md +0 -132
- package/.aether/commands/claude/verify-castes.md +0 -143
- package/.aether/commands/claude/watch.md +0 -239
- package/.aether/commands/opencode/archaeology.md +0 -331
- package/.aether/commands/opencode/build.md +0 -1168
- package/.aether/commands/opencode/chaos.md +0 -329
- package/.aether/commands/opencode/colonize.md +0 -195
- package/.aether/commands/opencode/continue.md +0 -1436
- package/.aether/commands/opencode/council.md +0 -437
- package/.aether/commands/opencode/data-clean.md +0 -77
- package/.aether/commands/opencode/dream.md +0 -260
- package/.aether/commands/opencode/entomb.md +0 -377
- package/.aether/commands/opencode/export-signals.md +0 -54
- package/.aether/commands/opencode/feedback.md +0 -99
- package/.aether/commands/opencode/flag.md +0 -149
- package/.aether/commands/opencode/flags.md +0 -167
- package/.aether/commands/opencode/focus.md +0 -73
- package/.aether/commands/opencode/help.md +0 -157
- package/.aether/commands/opencode/history.md +0 -136
- package/.aether/commands/opencode/import-signals.md +0 -68
- package/.aether/commands/opencode/init.md +0 -518
- package/.aether/commands/opencode/insert-phase.md +0 -111
- package/.aether/commands/opencode/interpret.md +0 -272
- package/.aether/commands/opencode/lay-eggs.md +0 -213
- package/.aether/commands/opencode/maturity.md +0 -108
- package/.aether/commands/opencode/memory-details.md +0 -83
- package/.aether/commands/opencode/migrate-state.md +0 -165
- package/.aether/commands/opencode/oracle.md +0 -593
- package/.aether/commands/opencode/organize.md +0 -226
- package/.aether/commands/opencode/patrol.md +0 -626
- package/.aether/commands/opencode/pause-colony.md +0 -203
- package/.aether/commands/opencode/phase.md +0 -113
- package/.aether/commands/opencode/pheromones.md +0 -162
- package/.aether/commands/opencode/plan.md +0 -684
- package/.aether/commands/opencode/preferences.md +0 -71
- package/.aether/commands/opencode/quick.md +0 -91
- package/.aether/commands/opencode/redirect.md +0 -84
- package/.aether/commands/opencode/resume-colony.md +0 -190
- package/.aether/commands/opencode/resume.md +0 -394
- package/.aether/commands/opencode/run.md +0 -237
- package/.aether/commands/opencode/seal.md +0 -452
- package/.aether/commands/opencode/skill-create.md +0 -63
- package/.aether/commands/opencode/status.md +0 -307
- package/.aether/commands/opencode/swarm.md +0 -15
- package/.aether/commands/opencode/tunnels.md +0 -400
- package/.aether/commands/opencode/update.md +0 -127
- package/.aether/commands/opencode/verify-castes.md +0 -139
- package/.aether/commands/opencode/watch.md +0 -227
package/.aether/aether-utils.sh
CHANGED
|
@@ -48,6 +48,21 @@ CURRENT_LOCK=${CURRENT_LOCK:-""}
|
|
|
48
48
|
[[ -f "$SCRIPT_DIR/utils/council.sh" ]] && source "$SCRIPT_DIR/utils/council.sh"
|
|
49
49
|
[[ -f "$SCRIPT_DIR/utils/clash-detect.sh" ]] && source "$SCRIPT_DIR/utils/clash-detect.sh"
|
|
50
50
|
[[ -f "$SCRIPT_DIR/utils/worktree.sh" ]] && source "$SCRIPT_DIR/utils/worktree.sh"
|
|
51
|
+
[[ -f "$SCRIPT_DIR/utils/event-bus.sh" ]] && source "$SCRIPT_DIR/utils/event-bus.sh"
|
|
52
|
+
[[ -f "$SCRIPT_DIR/utils/trust-scoring.sh" ]] && source "$SCRIPT_DIR/utils/trust-scoring.sh"
|
|
53
|
+
[[ -f "$SCRIPT_DIR/utils/instinct-store.sh" ]] && source "$SCRIPT_DIR/utils/instinct-store.sh"
|
|
54
|
+
[[ -f "$SCRIPT_DIR/utils/graph.sh" ]] && source "$SCRIPT_DIR/utils/graph.sh"
|
|
55
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/sentinel.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/sentinel.sh"
|
|
56
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/janitor.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/janitor.sh"
|
|
57
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/archivist.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/archivist.sh"
|
|
58
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/scribe.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/scribe.sh"
|
|
59
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/nurse.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/nurse.sh"
|
|
60
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/herald.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/herald.sh"
|
|
61
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/librarian.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/librarian.sh"
|
|
62
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/critic.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/critic.sh"
|
|
63
|
+
[[ -f "$SCRIPT_DIR/utils/curation-ants/orchestrator.sh" ]] && source "$SCRIPT_DIR/utils/curation-ants/orchestrator.sh"
|
|
64
|
+
[[ -f "$SCRIPT_DIR/utils/consolidation-seal.sh" ]] && source "$SCRIPT_DIR/utils/consolidation-seal.sh"
|
|
65
|
+
[[ -f "$SCRIPT_DIR/utils/consolidation.sh" ]] && source "$SCRIPT_DIR/utils/consolidation.sh"
|
|
51
66
|
|
|
52
67
|
# Fallback error constants if error-handler.sh wasn't sourced
|
|
53
68
|
# This prevents "unbound variable" errors in older installations
|
|
@@ -1260,13 +1275,16 @@ case "$cmd" in
|
|
|
1260
1275
|
{"name": "pheromone-export", "description": "Export pheromone data to JSON"},
|
|
1261
1276
|
{"name": "pheromone-export-xml", "description": "Export pheromone data to XML"},
|
|
1262
1277
|
{"name": "pheromone-import-xml", "description": "Import pheromone data from XML"},
|
|
1263
|
-
{"name": "pheromone-validate-xml", "description": "Validate pheromone XML against schema"}
|
|
1278
|
+
{"name": "pheromone-validate-xml", "description": "Validate pheromone XML against schema"},
|
|
1279
|
+
{"name": "pheromone-snapshot-inject", "description": "Copy active pheromone signals into a new worktree branch"},
|
|
1280
|
+
{"name": "pheromone-export-branch", "description": "Export branch-specific pheromone signals for merge"},
|
|
1281
|
+
{"name": "pheromone-merge-back", "description": "Merge eligible branch pheromone signals back to main"}
|
|
1264
1282
|
],
|
|
1265
1283
|
"Utilities": [
|
|
1266
1284
|
{"name": "generate-ant-name", "description": "Generate a unique ant name with caste prefix"},
|
|
1267
1285
|
{"name": "activity-log", "description": "Append an entry to the activity log"},
|
|
1268
1286
|
{"name": "activity-log-init", "description": "Initialize the activity log file"},
|
|
1269
|
-
{"name": "activity-log-read", "description": "Read recent activity log entries"},
|
|
1287
|
+
{"name": "activity-log-read", "description": "Read recent activity log entries; --no-errors excludes ERROR/WARN lines"},
|
|
1270
1288
|
{"name": "generate-commit-message", "description": "Generate a commit message (types: milestone, pause, fix, contextual, seal)"},
|
|
1271
1289
|
{"name": "version-check", "description": "Check if Aether version meets requirement"},
|
|
1272
1290
|
{"name": "registry-add", "description": "Register a repo with Aether (supports --tags, --goal, --active)"},
|
|
@@ -1295,7 +1313,9 @@ case "$cmd" in
|
|
|
1295
1313
|
{"name": "suggest-quick-dismiss", "description": "Dismiss all suggestions without approving"}
|
|
1296
1314
|
],
|
|
1297
1315
|
"Maintenance": [
|
|
1298
|
-
{"name": "data-clean", "description": "Scan and remove test/synthetic artifacts from colony data files"}
|
|
1316
|
+
{"name": "data-clean", "description": "Scan and remove test/synthetic artifacts from colony data files"},
|
|
1317
|
+
{"name": "backup-prune-global", "description": "Prune .aether/data/backups/ to 50-file global cap (newest kept)"},
|
|
1318
|
+
{"name": "temp-clean", "description": "Remove files from .aether/temp/ older than 7 days"}
|
|
1299
1319
|
],
|
|
1300
1320
|
"Autopilot": [
|
|
1301
1321
|
{"name": "autopilot-init", "description": "Initialize autopilot run state (run-state.json)"},
|
|
@@ -1793,6 +1813,12 @@ HELP_EOF
|
|
|
1793
1813
|
json_ok "{\"archived\":$archived_flag}"
|
|
1794
1814
|
;;
|
|
1795
1815
|
activity-log-read)
|
|
1816
|
+
# Parse optional --no-errors flag before positional caste_filter
|
|
1817
|
+
_alr_no_errors=false
|
|
1818
|
+
if [[ "${1:-}" == "--no-errors" ]]; then
|
|
1819
|
+
_alr_no_errors=true
|
|
1820
|
+
shift
|
|
1821
|
+
fi
|
|
1796
1822
|
caste_filter="${1:-}"
|
|
1797
1823
|
|
|
1798
1824
|
# Graceful degradation: check if activity logging is enabled
|
|
@@ -1808,6 +1834,12 @@ HELP_EOF
|
|
|
1808
1834
|
else
|
|
1809
1835
|
content=$(cat "$log_file")
|
|
1810
1836
|
fi
|
|
1837
|
+
|
|
1838
|
+
# Filter out ERROR/WARN lines if --no-errors flag was set
|
|
1839
|
+
if [[ "$_alr_no_errors" == "true" ]]; then
|
|
1840
|
+
content=$(echo "$content" | grep -vE 'ERROR|WARN' || true)
|
|
1841
|
+
fi
|
|
1842
|
+
|
|
1811
1843
|
json_ok "$(echo "$content" | jq -Rs '.')"
|
|
1812
1844
|
;;
|
|
1813
1845
|
learning-promote) _learning_promote "$@" ;;
|
|
@@ -3567,12 +3599,14 @@ Files: ${files_changed} files changed"
|
|
|
3567
3599
|
|
|
3568
3600
|
memory-capture)
|
|
3569
3601
|
# Capture learning/failure events with deterministic memory actions.
|
|
3570
|
-
# Usage: memory-capture <event_type> <content> [wisdom_type] [source]
|
|
3602
|
+
# Usage: memory-capture <event_type> <content> [wisdom_type] [source] [source_type] [evidence_type]
|
|
3571
3603
|
# event_type: learning|failure|redirect|feedback|success|resolution
|
|
3572
3604
|
mc_event="${1:-}"
|
|
3573
3605
|
mc_content="${2:-}"
|
|
3574
3606
|
mc_wisdom_type="${3:-}"
|
|
3575
3607
|
mc_source="${4:-system:memory-capture}"
|
|
3608
|
+
mc_source_type="${5:-observation}"
|
|
3609
|
+
mc_evidence_type="${6:-anecdotal}"
|
|
3576
3610
|
|
|
3577
3611
|
[[ -z "$mc_event" ]] && json_err "$E_VALIDATION_FAILED" "Usage: memory-capture <event_type> <content> [wisdom_type] [source]" '{"missing":"event_type"}'
|
|
3578
3612
|
[[ -z "$mc_content" ]] && json_err "$E_VALIDATION_FAILED" "Usage: memory-capture <event_type> <content> [wisdom_type] [source]" '{"missing":"content"}'
|
|
@@ -3595,7 +3629,7 @@ Files: ${files_changed} files changed"
|
|
|
3595
3629
|
[[ -z "$colony_name" ]] && colony_name="unknown"
|
|
3596
3630
|
|
|
3597
3631
|
# SUPPRESS:OK -- read-default: returns fallback on failure
|
|
3598
|
-
observe_result=$(bash "$0" learning-observe "$mc_content" "$mc_wisdom_type" "$colony_name" 2>/dev/null || echo '{}')
|
|
3632
|
+
observe_result=$(bash "$0" learning-observe "$mc_content" "$mc_wisdom_type" "$colony_name" "$mc_source_type" "$mc_evidence_type" 2>/dev/null || echo '{}')
|
|
3599
3633
|
if ! echo "$observe_result" | jq -e '.ok == true' >/dev/null 2>&1; then # SUPPRESS:OK -- validation: testing JSON field
|
|
3600
3634
|
# SUPPRESS:OK -- read-default: query may return empty
|
|
3601
3635
|
obs_msg=$(echo "$observe_result" | jq -r '.error.message // "learning_observe_failed"' 2>/dev/null || echo "learning_observe_failed")
|
|
@@ -3907,6 +3941,9 @@ Files: ${files_changed} files changed"
|
|
|
3907
3941
|
pheromone-count) _pheromone_count "$@" ;;
|
|
3908
3942
|
pheromone-display) _pheromone_display "$@" ;;
|
|
3909
3943
|
pheromone-read) _pheromone_read "$@" ;;
|
|
3944
|
+
pheromone-snapshot-inject) _pheromone_snapshot_inject "$@" ;;
|
|
3945
|
+
pheromone-export-branch) _pheromone_export_branch "$@" ;;
|
|
3946
|
+
pheromone-merge-back) _pheromone_merge_back "$@" ;;
|
|
3910
3947
|
|
|
3911
3948
|
instinct-read) _instinct_read "$@" ;;
|
|
3912
3949
|
instinct-create) _instinct_create "$@" ;;
|
|
@@ -5174,6 +5211,50 @@ DRYRUN_EOF
|
|
|
5174
5211
|
'{ok:true, removed:{pheromones:$phero, queen:$queen, observations:$obs, midden:$midden, spawn_tree:$spawn, constraints:$constraints}, total:$total}')"
|
|
5175
5212
|
;;
|
|
5176
5213
|
|
|
5214
|
+
# --- Housekeeping Subcommands ---
|
|
5215
|
+
|
|
5216
|
+
backup-prune-global)
|
|
5217
|
+
# Prune .aether/data/backups/ to a global cap of 50 files (newest kept).
|
|
5218
|
+
# Per-filename rotation (MAX_BACKUPS=3) already runs in atomic-write.sh.
|
|
5219
|
+
# This is the global sweep for unique-filename growth.
|
|
5220
|
+
_bpg_cap=50
|
|
5221
|
+
_bpg_dir="${BACKUP_DIR:-$DATA_DIR/backups}"
|
|
5222
|
+
|
|
5223
|
+
if [[ ! -d "$_bpg_dir" ]]; then
|
|
5224
|
+
json_ok '{"pruned":0,"kept":0,"dir_exists":false}'; exit 0
|
|
5225
|
+
fi
|
|
5226
|
+
|
|
5227
|
+
_bpg_total=$(find "$_bpg_dir" -maxdepth 1 -type f 2>/dev/null | wc -l | tr -d ' ')
|
|
5228
|
+
|
|
5229
|
+
if [[ "$_bpg_total" -le "$_bpg_cap" ]]; then
|
|
5230
|
+
json_ok "$(jq -n --argjson pruned 0 --argjson kept "$_bpg_total" '{pruned:$pruned,kept:$kept}')"; exit 0
|
|
5231
|
+
fi
|
|
5232
|
+
|
|
5233
|
+
_bpg_pruned=0
|
|
5234
|
+
while IFS= read -r _bpg_file; do
|
|
5235
|
+
rm -f "$_bpg_file" 2>/dev/null && _bpg_pruned=$((_bpg_pruned + 1))
|
|
5236
|
+
done < <(find "$_bpg_dir" -maxdepth 1 -type f -print0 2>/dev/null | xargs -0 ls -t 2>/dev/null | tail -n +$((_bpg_cap + 1)))
|
|
5237
|
+
|
|
5238
|
+
_bpg_kept=$((_bpg_total - _bpg_pruned))
|
|
5239
|
+
json_ok "$(jq -n --argjson pruned "$_bpg_pruned" --argjson kept "$_bpg_kept" '{pruned:$pruned,kept:$kept}')"
|
|
5240
|
+
;;
|
|
5241
|
+
|
|
5242
|
+
temp-clean)
|
|
5243
|
+
# Remove files from .aether/temp/ older than 7 days.
|
|
5244
|
+
_tc_dir="$AETHER_ROOT/.aether/temp"
|
|
5245
|
+
_tc_cleaned=0
|
|
5246
|
+
|
|
5247
|
+
if [[ ! -d "$_tc_dir" ]]; then
|
|
5248
|
+
json_ok '{"cleaned":0,"dir_exists":false}'; exit 0
|
|
5249
|
+
fi
|
|
5250
|
+
|
|
5251
|
+
while IFS= read -r _tc_file; do
|
|
5252
|
+
rm -f "$_tc_file" 2>/dev/null && _tc_cleaned=$((_tc_cleaned + 1))
|
|
5253
|
+
done < <(find "$_tc_dir" -maxdepth 1 -type f -mtime +7 2>/dev/null)
|
|
5254
|
+
|
|
5255
|
+
json_ok "$(jq -n --argjson cleaned "$_tc_cleaned" '{cleaned:$cleaned}')"
|
|
5256
|
+
;;
|
|
5257
|
+
|
|
5177
5258
|
# --- Autopilot State Tracking ---
|
|
5178
5259
|
# Tracks /ant:run autopilot sessions in run-state.json (separate from COLONY_STATE.json)
|
|
5179
5260
|
# Optional — colonies without /ant:run are unaffected
|
|
@@ -5462,6 +5543,101 @@ DRYRUN_EOF
|
|
|
5462
5543
|
worktree-cleanup)
|
|
5463
5544
|
_worktree_cleanup "$@"
|
|
5464
5545
|
;;
|
|
5546
|
+
worktree-merge)
|
|
5547
|
+
_worktree_merge "$@"
|
|
5548
|
+
;;
|
|
5549
|
+
|
|
5550
|
+
# ── Event Bus ───────────────────────────────────────────────────────────────
|
|
5551
|
+
event-publish)
|
|
5552
|
+
_event_publish "$@"
|
|
5553
|
+
;;
|
|
5554
|
+
event-subscribe)
|
|
5555
|
+
_event_subscribe "$@"
|
|
5556
|
+
;;
|
|
5557
|
+
event-cleanup)
|
|
5558
|
+
_event_cleanup "$@"
|
|
5559
|
+
;;
|
|
5560
|
+
event-replay)
|
|
5561
|
+
_event_replay "$@"
|
|
5562
|
+
;;
|
|
5563
|
+
|
|
5564
|
+
# ── Trust Scoring ──────────────────────────────────────────────────────────
|
|
5565
|
+
trust-calculate)
|
|
5566
|
+
_trust_calculate "$@"
|
|
5567
|
+
;;
|
|
5568
|
+
trust-decay)
|
|
5569
|
+
_trust_decay "$@"
|
|
5570
|
+
;;
|
|
5571
|
+
trust-tier)
|
|
5572
|
+
_trust_tier "$@"
|
|
5573
|
+
;;
|
|
5574
|
+
|
|
5575
|
+
# ── Instinct Store ─────────────────────────────────────────────────────────
|
|
5576
|
+
instinct-store)
|
|
5577
|
+
_instinct_store "$@"
|
|
5578
|
+
;;
|
|
5579
|
+
instinct-read-trusted)
|
|
5580
|
+
_instinct_read_trusted "$@"
|
|
5581
|
+
;;
|
|
5582
|
+
instinct-decay-all)
|
|
5583
|
+
_instinct_decay_all "$@"
|
|
5584
|
+
;;
|
|
5585
|
+
instinct-archive)
|
|
5586
|
+
_instinct_archive "$@"
|
|
5587
|
+
;;
|
|
5588
|
+
|
|
5589
|
+
# ── Graph Traversal ────────────────────────────────────────────────────────
|
|
5590
|
+
graph-link)
|
|
5591
|
+
_graph_link "$@"
|
|
5592
|
+
;;
|
|
5593
|
+
graph-neighbors)
|
|
5594
|
+
_graph_neighbors "$@"
|
|
5595
|
+
;;
|
|
5596
|
+
graph-reach)
|
|
5597
|
+
_graph_reach "$@"
|
|
5598
|
+
;;
|
|
5599
|
+
graph-cluster)
|
|
5600
|
+
_graph_cluster "$@"
|
|
5601
|
+
;;
|
|
5602
|
+
|
|
5603
|
+
# ── Curation Ants ──────────────────────────────────────────────────────────
|
|
5604
|
+
curation-sentinel)
|
|
5605
|
+
_curation_sentinel "$@"
|
|
5606
|
+
;;
|
|
5607
|
+
curation-janitor)
|
|
5608
|
+
_curation_janitor "$@"
|
|
5609
|
+
;;
|
|
5610
|
+
curation-archivist)
|
|
5611
|
+
_curation_archivist "$@"
|
|
5612
|
+
;;
|
|
5613
|
+
curation-scribe)
|
|
5614
|
+
_curation_scribe "$@"
|
|
5615
|
+
;;
|
|
5616
|
+
curation-nurse)
|
|
5617
|
+
_curation_nurse "$@"
|
|
5618
|
+
;;
|
|
5619
|
+
curation-herald)
|
|
5620
|
+
_curation_herald "$@"
|
|
5621
|
+
;;
|
|
5622
|
+
curation-librarian)
|
|
5623
|
+
_curation_librarian "$@"
|
|
5624
|
+
;;
|
|
5625
|
+
curation-critic)
|
|
5626
|
+
_curation_critic "$@"
|
|
5627
|
+
;;
|
|
5628
|
+
curation-run)
|
|
5629
|
+
_curation_run "$@"
|
|
5630
|
+
;;
|
|
5631
|
+
|
|
5632
|
+
# ── Consolidation Seal ─────────────────────────────────────────────────────
|
|
5633
|
+
consolidation-seal)
|
|
5634
|
+
_consolidation_seal "$@"
|
|
5635
|
+
;;
|
|
5636
|
+
|
|
5637
|
+
# ── Consolidation Phase End ───────────────────────────────────────────────
|
|
5638
|
+
consolidation-phase-end)
|
|
5639
|
+
_consolidation_phase_end "$@"
|
|
5640
|
+
;;
|
|
5465
5641
|
|
|
5466
5642
|
*)
|
|
5467
5643
|
json_err "$E_VALIDATION_FAILED" "Unknown command: $cmd"
|
|
@@ -306,7 +306,7 @@ body_claude: |
|
|
|
306
306
|
|
|
307
307
|
Run using the Bash tool with description "Logging excavation activity...":
|
|
308
308
|
```bash
|
|
309
|
-
|
|
309
|
+
aether activity-log "ARCHAEOLOGY" "Archaeologist" "Excavated {target}: {total_commits} commits, {author_count} authors, {findings_count} findings, {tech_debt_count} debt markers"
|
|
310
310
|
```
|
|
311
311
|
|
|
312
312
|
Generate the state-based Next Up block by running using the Bash tool with description "Generating Next Up suggestions...":
|
|
@@ -314,7 +314,7 @@ body_claude: |
|
|
|
314
314
|
state=$(jq -r '.state // "IDLE"' .aether/data/COLONY_STATE.json)
|
|
315
315
|
current_phase=$(jq -r '.current_phase // 0' .aether/data/COLONY_STATE.json)
|
|
316
316
|
total_phases=$(jq -r '.plan.phases | length' .aether/data/COLONY_STATE.json)
|
|
317
|
-
|
|
317
|
+
aether print-next-up
|
|
318
318
|
```
|
|
319
319
|
|
|
320
320
|
## Investigation Guidelines
|
|
@@ -635,7 +635,7 @@ body_opencode: |
|
|
|
635
635
|
### Step 8: Log Activity
|
|
636
636
|
|
|
637
637
|
```bash
|
|
638
|
-
|
|
638
|
+
aether activity-log "ARCHAEOLOGY" "Archaeologist" "Excavated {target}: {total_commits} commits, {author_count} authors, {findings_count} findings, {tech_debt_count} debt markers"
|
|
639
639
|
```
|
|
640
640
|
|
|
641
641
|
## Investigation Guidelines
|
|
@@ -70,7 +70,7 @@ body_opencode: |
|
|
|
70
70
|
|
|
71
71
|
### Step 0.5: Load Colony State
|
|
72
72
|
|
|
73
|
-
Run using Bash tool: `
|
|
73
|
+
Run using Bash tool: `aether load-state`
|
|
74
74
|
|
|
75
75
|
If the command fails (non-zero exit or JSON has ok: false):
|
|
76
76
|
1. Parse error JSON
|
|
@@ -88,7 +88,7 @@ body_opencode: |
|
|
|
88
88
|
```
|
|
89
89
|
(If HANDOFF.md exists, this provides orientation before the build proceeds)
|
|
90
90
|
|
|
91
|
-
After displaying context, run: `
|
|
91
|
+
After displaying context, run: `aether unload-state` to release the lock.
|
|
92
92
|
|
|
93
93
|
### Step 1: Validate + Read State
|
|
94
94
|
|
|
@@ -121,7 +121,7 @@ body_opencode: |
|
|
|
121
121
|
|
|
122
122
|
**Set colony depth (if --depth flag provided):**
|
|
123
123
|
If `cli_depth_override` is set:
|
|
124
|
-
1. Run using Bash tool: `
|
|
124
|
+
1. Run using Bash tool: `aether colony-depth set "$cli_depth_override"`
|
|
125
125
|
2. Parse JSON result - if `.ok` is false:
|
|
126
126
|
- Display: `Error: Invalid depth "$cli_depth_override". Use: light, standard, deep, full`
|
|
127
127
|
- Stop here
|
|
@@ -150,7 +150,7 @@ body_opencode: |
|
|
|
150
150
|
Check for unresolved blocker flags on the requested phase:
|
|
151
151
|
|
|
152
152
|
```bash
|
|
153
|
-
|
|
153
|
+
aether flag-check-blockers {phase_number}
|
|
154
154
|
```
|
|
155
155
|
|
|
156
156
|
Parse the JSON result (`.result.blockers`):
|
|
@@ -158,7 +158,7 @@ body_opencode: |
|
|
|
158
158
|
- **If blockers == 0:** Display nothing (or optionally a brief `No active blockers for Phase {id}.` line). Proceed to Step 2.
|
|
159
159
|
- **If blockers > 0:** Retrieve blocker details:
|
|
160
160
|
```bash
|
|
161
|
-
|
|
161
|
+
aether flag-list --type blocker --json --phase {phase_number}
|
|
162
162
|
```
|
|
163
163
|
Parse `.result.flags` and display an advisory warning:
|
|
164
164
|
```
|
|
@@ -219,7 +219,7 @@ body_opencode: |
|
|
|
219
219
|
|
|
220
220
|
Run using the Bash tool with description "Showing phase progress...":
|
|
221
221
|
```bash
|
|
222
|
-
progress_bar=$(
|
|
222
|
+
progress_bar=$(aether generate-progress-bar "$current_phase" "$total_phases" 20 2>/dev/null || echo "")
|
|
223
223
|
if [[ -n "$progress_bar" ]]; then
|
|
224
224
|
echo "[Phase ${current_phase}/${total_phases}] ${progress_bar}"
|
|
225
225
|
fi
|
|
@@ -246,7 +246,7 @@ body_opencode: |
|
|
|
246
246
|
Check if territory survey exists and load relevant documents:
|
|
247
247
|
|
|
248
248
|
```bash
|
|
249
|
-
|
|
249
|
+
aether survey-load "{phase_name}" 2>/dev/null
|
|
250
250
|
```
|
|
251
251
|
|
|
252
252
|
**Parse the JSON response:**
|
|
@@ -292,7 +292,7 @@ body_opencode: |
|
|
|
292
292
|
Call `queen-read` to extract eternal wisdom for worker priming:
|
|
293
293
|
|
|
294
294
|
```bash
|
|
295
|
-
|
|
295
|
+
aether queen-read 2>/dev/null
|
|
296
296
|
```
|
|
297
297
|
|
|
298
298
|
**Parse the JSON response:**
|
|
@@ -327,7 +327,7 @@ body_opencode: |
|
|
|
327
327
|
Call `pheromone-read` to extract active colony signals for worker priming:
|
|
328
328
|
|
|
329
329
|
```bash
|
|
330
|
-
|
|
330
|
+
aether pheromone-read 2>/dev/null
|
|
331
331
|
```
|
|
332
332
|
|
|
333
333
|
**Parse the JSON response:**
|
|
@@ -381,8 +381,8 @@ body_opencode: |
|
|
|
381
381
|
|
|
382
382
|
Generate archaeologist name and log:
|
|
383
383
|
```bash
|
|
384
|
-
|
|
385
|
-
|
|
384
|
+
aether generate-ant-name --caste "archaeologist"
|
|
385
|
+
aether spawn-log --name "Queen" --caste "scout" --id "{archaeologist_name}" --description "Pre-build archaeology scan"
|
|
386
386
|
```
|
|
387
387
|
|
|
388
388
|
Display:
|
|
@@ -407,7 +407,7 @@ body_opencode: |
|
|
|
407
407
|
4. Run: git blame "{file_path}" | head -40 for authorship
|
|
408
408
|
5. Note TODO/FIXME/HACK markers
|
|
409
409
|
|
|
410
|
-
Log activity:
|
|
410
|
+
Log activity: aether activity-log "READ" "{Ant-Name}" "description"
|
|
411
411
|
|
|
412
412
|
Report (plain text):
|
|
413
413
|
- WHY key code sections exist (from commits)
|
|
@@ -421,7 +421,7 @@ body_opencode: |
|
|
|
421
421
|
|
|
422
422
|
Log completion:
|
|
423
423
|
```bash
|
|
424
|
-
|
|
424
|
+
aether spawn-complete --id "{archaeologist_name}" --status "completed" --summary "Pre-build archaeology scan"
|
|
425
425
|
```
|
|
426
426
|
|
|
427
427
|
3. **Store and display findings:**
|
|
@@ -472,9 +472,9 @@ body_opencode: |
|
|
|
472
472
|
|
|
473
473
|
3. **Generate ant names for each worker:**
|
|
474
474
|
```bash
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
475
|
+
aether generate-ant-name --caste "builder"
|
|
476
|
+
aether generate-ant-name --caste "watcher"
|
|
477
|
+
aether generate-ant-name --caste "chaos"
|
|
478
478
|
```
|
|
479
479
|
|
|
480
480
|
Display spawn plan with caste emojis:
|
|
@@ -553,12 +553,12 @@ body_opencode: |
|
|
|
553
553
|
|
|
554
554
|
**First, mark build start in context:**
|
|
555
555
|
```bash
|
|
556
|
-
|
|
556
|
+
aether context-update build-start {phase_id} {wave_1_worker_count} {wave_1_task_count}
|
|
557
557
|
```
|
|
558
558
|
|
|
559
559
|
Before dispatching each worker, refresh colony context so new pheromones/memory are visible:
|
|
560
560
|
```bash
|
|
561
|
-
prime_result=$(
|
|
561
|
+
prime_result=$(aether colony-prime --compact 2>/dev/null)
|
|
562
562
|
```
|
|
563
563
|
Update `prompt_section` from `prime_result.result.prompt_section`.
|
|
564
564
|
|
|
@@ -566,8 +566,8 @@ body_opencode: |
|
|
|
566
566
|
|
|
567
567
|
Log each spawn and update swarm display:
|
|
568
568
|
```bash
|
|
569
|
-
|
|
570
|
-
|
|
569
|
+
aether spawn-log --name "Queen" --caste "builder" --id "{ant_name}" --description "{task_description}"
|
|
570
|
+
aether context-update worker-spawn "{ant_name}" "builder" "{task_description}"
|
|
571
571
|
```
|
|
572
572
|
|
|
573
573
|
**Builder Worker Prompt (CLEAN OUTPUT):**
|
|
@@ -587,13 +587,13 @@ body_opencode: |
|
|
|
587
587
|
Work:
|
|
588
588
|
1. Read .aether/workers.md for Builder discipline
|
|
589
589
|
2. Implement task, write tests
|
|
590
|
-
3. Log activity:
|
|
590
|
+
3. Log activity: aether activity-log "ACTION" "{Ant-Name}" "description"
|
|
591
591
|
|
|
592
592
|
Spawn sub-workers ONLY if 3x complexity:
|
|
593
|
-
- Check:
|
|
594
|
-
- Generate name:
|
|
593
|
+
- Check: aether spawn-can-spawn {depth} --enforce
|
|
594
|
+
- Generate name: aether generate-ant-name --caste "builder"
|
|
595
595
|
- Announce: "🐜 Spawning {child_name} for {reason}"
|
|
596
|
-
- Log:
|
|
596
|
+
- Log: aether spawn-log --name "{Ant-Name}" --caste "builder" --id "{child_name}" --description "{task}"
|
|
597
597
|
|
|
598
598
|
Count your total tool calls (Read + Grep + Edit + Bash + Write) and report as tool_count.
|
|
599
599
|
|
|
@@ -676,7 +676,7 @@ body_opencode: |
|
|
|
676
676
|
|
|
677
677
|
Before using any worker payload, validate schema:
|
|
678
678
|
```bash
|
|
679
|
-
|
|
679
|
+
aether validate-worker-response builder '{worker_json}'
|
|
680
680
|
```
|
|
681
681
|
If validation fails, treat the worker as failed with blocker `invalid_worker_response`.
|
|
682
682
|
|
|
@@ -696,8 +696,8 @@ body_opencode: |
|
|
|
696
696
|
|
|
697
697
|
Log and update swarm display:
|
|
698
698
|
```bash
|
|
699
|
-
|
|
700
|
-
|
|
699
|
+
aether spawn-complete --id "{ant_name}" --status "completed" --summary "{summary}"
|
|
700
|
+
aether context-update worker-complete "{ant_name}" "completed"
|
|
701
701
|
```
|
|
702
702
|
|
|
703
703
|
**Check for total wave failure:**
|
|
@@ -754,7 +754,7 @@ body_opencode: |
|
|
|
754
754
|
|
|
755
755
|
Log escalation as flag:
|
|
756
756
|
```bash
|
|
757
|
-
|
|
757
|
+
aether flag-add --severity "blocker" --title "{task title}" --description "{failure summary}" --source "escalation" --phase {phase_number}
|
|
758
758
|
```
|
|
759
759
|
|
|
760
760
|
If at least one worker succeeded, continue normally to the next wave.
|
|
@@ -784,7 +784,7 @@ body_opencode: |
|
|
|
784
784
|
Spawn the Watcher using Task tool with `subagent_type="aether-watcher"`, include `description: "👁️ Watcher {Watcher-Name}: Independent verification"` (DO NOT use run_in_background - task blocks until complete):
|
|
785
785
|
|
|
786
786
|
```bash
|
|
787
|
-
|
|
787
|
+
aether spawn-log --name "Queen" --caste "watcher" --id "{watcher_name}" --description "Independent verification"
|
|
788
788
|
```
|
|
789
789
|
|
|
790
790
|
**Watcher Worker Prompt (CLEAN OUTPUT):**
|
|
@@ -804,7 +804,7 @@ body_opencode: |
|
|
|
804
804
|
4. Check success criteria: {list}
|
|
805
805
|
|
|
806
806
|
Spawn sub-workers if needed:
|
|
807
|
-
- Log:
|
|
807
|
+
- Log: aether spawn-log --name "{Watcher-Name}" --caste "watcher" --id "{child}" --description "{task}"
|
|
808
808
|
- Announce: "🐜 Spawning {child} to investigate {issue}"
|
|
809
809
|
|
|
810
810
|
Count your total tool calls (Read + Grep + Edit + Bash + Write) and report as tool_count.
|
|
@@ -819,7 +819,7 @@ body_opencode: |
|
|
|
819
819
|
|
|
820
820
|
Validate watcher payload first:
|
|
821
821
|
```bash
|
|
822
|
-
|
|
822
|
+
aether validate-worker-response watcher '{watcher_json}'
|
|
823
823
|
```
|
|
824
824
|
|
|
825
825
|
**Parse the Watcher's validated JSON response:** verification_passed, issues_found, quality_score, recommendation
|
|
@@ -844,13 +844,13 @@ body_opencode: |
|
|
|
844
844
|
|
|
845
845
|
Generate a chaos ant name and log the spawn:
|
|
846
846
|
```bash
|
|
847
|
-
|
|
848
|
-
|
|
847
|
+
aether generate-ant-name --caste "chaos"
|
|
848
|
+
aether spawn-log --name "Queen" --caste "chaos" --id "{chaos_name}" --description "Resilience testing of Phase {id} work"
|
|
849
849
|
```
|
|
850
850
|
|
|
851
851
|
**Retrieve existing flags for this phase** (to avoid duplicate findings):
|
|
852
852
|
```bash
|
|
853
|
-
|
|
853
|
+
aether flag-list --phase {phase_number}
|
|
854
854
|
```
|
|
855
855
|
Parse the result and extract unresolved flag titles into a list: `{existing_flag_titles}` (comma-separated titles from `.result.flags[].title`). If no flags exist, set `{existing_flag_titles}` to "None".
|
|
856
856
|
|
|
@@ -901,17 +901,17 @@ body_opencode: |
|
|
|
901
901
|
If any findings have severity `"critical"` or `"high"`:
|
|
902
902
|
```bash
|
|
903
903
|
# Create a blocker flag for each critical/high chaos finding
|
|
904
|
-
|
|
904
|
+
aether flag-add --severity "blocker" --title "{finding.title}" --description "{finding.description}" --source "chaos-testing" --phase {phase_number}
|
|
905
905
|
```
|
|
906
906
|
|
|
907
907
|
Log the flag:
|
|
908
908
|
```bash
|
|
909
|
-
|
|
909
|
+
aether activity-log "FLAG" "Chaos" "Created blocker: {finding.title}"
|
|
910
910
|
```
|
|
911
911
|
|
|
912
912
|
Log chaos ant completion and update swarm display:
|
|
913
913
|
```bash
|
|
914
|
-
|
|
914
|
+
aether spawn-complete --id "{chaos_name}" --status "completed" --summary "{summary}"
|
|
915
915
|
```
|
|
916
916
|
|
|
917
917
|
### Step 5.8: Create Flags for Verification Failures
|
|
@@ -921,16 +921,51 @@ body_opencode: |
|
|
|
921
921
|
For each issue in `issues_found`:
|
|
922
922
|
```bash
|
|
923
923
|
# Create a blocker flag for each verification failure
|
|
924
|
-
|
|
924
|
+
aether flag-add --severity "blocker" --title "{issue_title}" --description "{issue_description}" --source "verification" --phase {phase_number}
|
|
925
925
|
```
|
|
926
926
|
|
|
927
927
|
Log the flag creation:
|
|
928
928
|
```bash
|
|
929
|
-
|
|
929
|
+
aether activity-log "FLAG" "Watcher" "Created blocker: {issue_title}"
|
|
930
930
|
```
|
|
931
931
|
|
|
932
932
|
This ensures verification failures are persisted as blockers that survive context resets. Chaos Ant findings are flagged in Step 5.7.
|
|
933
933
|
|
|
934
|
+
### Stage Audit Gate (Pre-Synthesis Check)
|
|
935
|
+
|
|
936
|
+
**This gate runs before Step 5.9. All build stages must have completed before synthesizing results.**
|
|
937
|
+
|
|
938
|
+
Verify that each of the following stages has a recorded completion status:
|
|
939
|
+
|
|
940
|
+
| Stage | Steps | Required |
|
|
941
|
+
|-------|-------|----------|
|
|
942
|
+
| Builder waves | Steps 5.1–5.3 | At least 1 worker completed (status "completed") |
|
|
943
|
+
| Watcher | Steps 5.4–5.5 | Watcher returned a result (any status) |
|
|
944
|
+
| Chaos | Steps 5.6–5.7 | Chaos ant returned a result (any status) |
|
|
945
|
+
|
|
946
|
+
Check by reviewing the in-memory worker results accumulated during Steps 5.1–5.7:
|
|
947
|
+
- `builder_results` — results from all builder wave tasks
|
|
948
|
+
- `watcher_result` — result from Step 5.5
|
|
949
|
+
- `chaos_result` — result from Step 5.7
|
|
950
|
+
|
|
951
|
+
**If any stage result is absent (stage did not run or returned no result):**
|
|
952
|
+
- HALT — do not proceed to Step 5.9
|
|
953
|
+
- Display:
|
|
954
|
+
```
|
|
955
|
+
Stage Audit FAILED — cannot synthesize results.
|
|
956
|
+
|
|
957
|
+
Missing or incomplete stages:
|
|
958
|
+
{list each missing stage: "Builders — no results recorded" / "Watcher — did not complete" / "Chaos — did not complete"}
|
|
959
|
+
|
|
960
|
+
Recovery options:
|
|
961
|
+
1. Re-run /ant:build to restart this phase
|
|
962
|
+
2. Run /ant:flags to review blockers
|
|
963
|
+
3. Run /ant:swarm to auto-repair failed tasks
|
|
964
|
+
```
|
|
965
|
+
- Return `{"status": "failed", "summary": "Stage audit failed — stages did not complete"}` and stop.
|
|
966
|
+
|
|
967
|
+
**If all stages have results (even if some workers failed):** proceed to Step 5.9.
|
|
968
|
+
|
|
934
969
|
### Step 5.9: Synthesize Results
|
|
935
970
|
|
|
936
971
|
**This step runs after all worker tasks have completed (Builders, Watcher, Chaos).**
|
|
@@ -970,11 +1005,11 @@ body_opencode: |
|
|
|
970
1005
|
For each worker that returned `status: "failed"`:
|
|
971
1006
|
For each file in that worker's `files_modified` or `files_created`:
|
|
972
1007
|
```bash
|
|
973
|
-
|
|
1008
|
+
aether grave-add "{file}" "{ant_name}" "{task_id}" {phase} "{first blocker or summary}"
|
|
974
1009
|
```
|
|
975
1010
|
Log the grave marker:
|
|
976
1011
|
```bash
|
|
977
|
-
|
|
1012
|
+
aether activity-log "GRAVE" "Queen" "Grave marker placed at {file} — {ant_name} failed: {summary}"
|
|
978
1013
|
```
|
|
979
1014
|
|
|
980
1015
|
**Error Handoff Update:**
|
|
@@ -1149,12 +1184,12 @@ body_opencode: |
|
|
|
1149
1184
|
Log this build activity to `.aether/CONTEXT.md`:
|
|
1150
1185
|
|
|
1151
1186
|
```bash
|
|
1152
|
-
|
|
1187
|
+
aether context-update activity "build {phase_id}" "{synthesis.status}" "{files_created_count + files_modified_count}"
|
|
1153
1188
|
```
|
|
1154
1189
|
|
|
1155
1190
|
Mark build as complete in context:
|
|
1156
1191
|
```bash
|
|
1157
|
-
|
|
1192
|
+
aether context-update build-complete "{synthesis.status}" "{synthesis.status == 'completed' ? 'success' : 'failed'}"
|
|
1158
1193
|
```
|
|
1159
1194
|
|
|
1160
1195
|
Also update safe-to-clear status:
|
|
@@ -1201,7 +1236,7 @@ body_opencode: |
|
|
|
1201
1236
|
state=$(jq -r '.state // "IDLE"' .aether/data/COLONY_STATE.json 2>/dev/null || echo "IDLE")
|
|
1202
1237
|
current_phase=$(jq -r '.current_phase // 0' .aether/data/COLONY_STATE.json 2>/dev/null || echo "0")
|
|
1203
1238
|
total_phases=$(jq -r '.plan.phases | length' .aether/data/COLONY_STATE.json 2>/dev/null || echo "0")
|
|
1204
|
-
|
|
1239
|
+
aether print-next-up
|
|
1205
1240
|
```
|
|
1206
1241
|
|
|
1207
1242
|
**Routing Note:** The state-based Next Up block above routes based on colony state. If verification failed or blockers exist, review `/ant:flags` before continuing.
|
|
@@ -1216,6 +1251,6 @@ body_opencode: |
|
|
|
1216
1251
|
Update the session tracking file to enable `/ant:resume` after context clear:
|
|
1217
1252
|
|
|
1218
1253
|
```bash
|
|
1219
|
-
|
|
1254
|
+
aether session-update --command "/ant:build {phase_id}" --worker "/ant:continue" --summary "Phase {phase_id} build completed: {synthesis.status}"
|
|
1220
1255
|
```
|
|
1221
1256
|
|