aether-colony 2.0.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.
Potentially problematic release.
This version of aether-colony might be problematic. Click here for more details.
- package/.claude/commands/ant/ant.md +89 -0
- package/.claude/commands/ant/build.md +504 -0
- package/.claude/commands/ant/colonize.md +94 -0
- package/.claude/commands/ant/continue.md +674 -0
- package/.claude/commands/ant/feedback.md +65 -0
- package/.claude/commands/ant/flag.md +108 -0
- package/.claude/commands/ant/flags.md +139 -0
- package/.claude/commands/ant/focus.md +42 -0
- package/.claude/commands/ant/init.md +129 -0
- package/.claude/commands/ant/migrate-state.md +140 -0
- package/.claude/commands/ant/organize.md +210 -0
- package/.claude/commands/ant/pause-colony.md +87 -0
- package/.claude/commands/ant/phase.md +86 -0
- package/.claude/commands/ant/plan.md +409 -0
- package/.claude/commands/ant/redirect.md +53 -0
- package/.claude/commands/ant/resume-colony.md +83 -0
- package/.claude/commands/ant/status.md +122 -0
- package/.claude/commands/ant/watch.md +220 -0
- package/LICENSE +21 -0
- package/README.md +258 -0
- package/bin/cli.js +196 -0
- package/package.json +35 -0
- package/runtime/DISCIPLINES.md +93 -0
- package/runtime/QUEEN_ANT_ARCHITECTURE.md +347 -0
- package/runtime/aether-utils.sh +760 -0
- package/runtime/coding-standards.md +197 -0
- package/runtime/debugging.md +207 -0
- package/runtime/docs/pheromones.md +213 -0
- package/runtime/learning.md +254 -0
- package/runtime/planning.md +159 -0
- package/runtime/tdd.md +257 -0
- package/runtime/utils/atomic-write.sh +213 -0
- package/runtime/utils/colorize-log.sh +132 -0
- package/runtime/utils/file-lock.sh +122 -0
- package/runtime/utils/watch-spawn-tree.sh +185 -0
- package/runtime/verification-loop.md +159 -0
- package/runtime/verification.md +116 -0
- package/runtime/workers.md +671 -0
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
# Verification Loop Discipline
|
|
2
|
+
|
|
3
|
+
## Purpose
|
|
4
|
+
|
|
5
|
+
A comprehensive 6-phase quality check that runs before phase advancement or PR creation. Complements the core Verification Discipline (evidence before claims) with systematic quality gates.
|
|
6
|
+
|
|
7
|
+
## When to Invoke
|
|
8
|
+
|
|
9
|
+
- After completing a phase (via `/ant:continue`)
|
|
10
|
+
- Before creating a PR
|
|
11
|
+
- After significant refactoring
|
|
12
|
+
- After major changes (every 15 minutes in long sessions)
|
|
13
|
+
|
|
14
|
+
## The 6 Phases
|
|
15
|
+
|
|
16
|
+
### Phase 1: Build Verification
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
# Detect and run build command
|
|
20
|
+
npm run build 2>&1 | tail -30
|
|
21
|
+
# OR: pnpm build, cargo build, go build ./..., python -m build
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
**Gate:** If build fails, STOP. Fix before continuing.
|
|
25
|
+
|
|
26
|
+
### Phase 2: Type Check
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
# TypeScript
|
|
30
|
+
npx tsc --noEmit 2>&1 | head -30
|
|
31
|
+
|
|
32
|
+
# Python
|
|
33
|
+
pyright . 2>&1 | head -30
|
|
34
|
+
|
|
35
|
+
# Go
|
|
36
|
+
go vet ./... 2>&1 | head -30
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
**Gate:** Report all type errors. Fix critical ones before continuing.
|
|
40
|
+
|
|
41
|
+
### Phase 3: Lint Check
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
# JavaScript/TypeScript
|
|
45
|
+
npm run lint 2>&1 | head -30
|
|
46
|
+
|
|
47
|
+
# Python
|
|
48
|
+
ruff check . 2>&1 | head -30
|
|
49
|
+
|
|
50
|
+
# Go
|
|
51
|
+
golangci-lint run 2>&1 | head -30
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
**Gate:** Report warnings. Fix errors before continuing.
|
|
55
|
+
|
|
56
|
+
### Phase 4: Test Suite
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
# Run tests with coverage
|
|
60
|
+
npm run test -- --coverage 2>&1 | tail -50
|
|
61
|
+
|
|
62
|
+
# Python
|
|
63
|
+
pytest --cov=. 2>&1 | tail -50
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Report:
|
|
67
|
+
- Total tests: X
|
|
68
|
+
- Passed: X
|
|
69
|
+
- Failed: X
|
|
70
|
+
- Coverage: X% (target: 80%+)
|
|
71
|
+
|
|
72
|
+
**Gate:** If tests fail, STOP. Fix before continuing.
|
|
73
|
+
|
|
74
|
+
### Phase 5: Security Scan
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
# Check for exposed secrets
|
|
78
|
+
grep -rn "sk-\|api_key\|password\s*=" --include="*.ts" --include="*.js" --include="*.py" src/ 2>/dev/null | head -10
|
|
79
|
+
|
|
80
|
+
# Check for debug artifacts
|
|
81
|
+
grep -rn "console\.log\|debugger\|TODO.*REMOVE" --include="*.ts" --include="*.tsx" --include="*.js" src/ 2>/dev/null | head -10
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Report:
|
|
85
|
+
- Potential secrets: X
|
|
86
|
+
- Debug artifacts: X
|
|
87
|
+
|
|
88
|
+
**Gate:** Fix exposed secrets immediately. Debug artifacts are warnings.
|
|
89
|
+
|
|
90
|
+
### Phase 6: Diff Review
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
# Show what changed
|
|
94
|
+
git diff --stat
|
|
95
|
+
git diff HEAD~1 --name-only
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Review each changed file for:
|
|
99
|
+
- Unintended changes (files touched that shouldn't be)
|
|
100
|
+
- Missing error handling
|
|
101
|
+
- Potential edge cases
|
|
102
|
+
- Leftover debugging code
|
|
103
|
+
|
|
104
|
+
**Gate:** Review before advancing. Flag concerns.
|
|
105
|
+
|
|
106
|
+
## Verification Report Format
|
|
107
|
+
|
|
108
|
+
After running all phases, produce a verification report:
|
|
109
|
+
|
|
110
|
+
```
|
|
111
|
+
VERIFICATION LOOP REPORT
|
|
112
|
+
========================
|
|
113
|
+
|
|
114
|
+
Phase 1: Build [PASS/FAIL]
|
|
115
|
+
Phase 2: Types [PASS/FAIL] (X errors)
|
|
116
|
+
Phase 3: Lint [PASS/FAIL] (X warnings)
|
|
117
|
+
Phase 4: Tests [PASS/FAIL] (X/Y passed, Z% coverage)
|
|
118
|
+
Phase 5: Security [PASS/FAIL] (X issues)
|
|
119
|
+
Phase 6: Diff [X files changed]
|
|
120
|
+
|
|
121
|
+
Overall: [READY/NOT READY] for advancement
|
|
122
|
+
|
|
123
|
+
Issues to Fix:
|
|
124
|
+
1. ...
|
|
125
|
+
2. ...
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
## Command Detection
|
|
129
|
+
|
|
130
|
+
Detect project type and commands automatically:
|
|
131
|
+
|
|
132
|
+
| File | Build | Test | Types | Lint |
|
|
133
|
+
|------|-------|------|-------|------|
|
|
134
|
+
| `package.json` | `npm run build` | `npm test` | `npx tsc --noEmit` | `npm run lint` |
|
|
135
|
+
| `Cargo.toml` | `cargo build` | `cargo test` | (built-in) | `cargo clippy` |
|
|
136
|
+
| `go.mod` | `go build ./...` | `go test ./...` | `go vet ./...` | `golangci-lint run` |
|
|
137
|
+
| `pyproject.toml` | `python -m build` | `pytest` | `pyright .` | `ruff check .` |
|
|
138
|
+
| `Makefile` | `make build` | `make test` | (check targets) | `make lint` |
|
|
139
|
+
|
|
140
|
+
## Skip Conditions
|
|
141
|
+
|
|
142
|
+
If command doesn't exist for project:
|
|
143
|
+
- Skip that phase
|
|
144
|
+
- Note "N/A" in report
|
|
145
|
+
- Don't fail the loop
|
|
146
|
+
|
|
147
|
+
## Integration with Hooks
|
|
148
|
+
|
|
149
|
+
This discipline provides comprehensive review. Hooks catch issues immediately during development. Use both:
|
|
150
|
+
- Hooks: Real-time feedback
|
|
151
|
+
- Verification Loop: Comprehensive gate before advancement
|
|
152
|
+
|
|
153
|
+
## Why This Matters
|
|
154
|
+
|
|
155
|
+
- Catches issues before they compound
|
|
156
|
+
- Ensures consistent quality gates
|
|
157
|
+
- Prevents shipping broken code
|
|
158
|
+
- Creates audit trail of verification
|
|
159
|
+
- Builds confidence in phase completion
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# Verification Discipline
|
|
2
|
+
|
|
3
|
+
## The Iron Law
|
|
4
|
+
|
|
5
|
+
```
|
|
6
|
+
NO COMPLETION CLAIMS WITHOUT FRESH VERIFICATION EVIDENCE
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
If you haven't run the verification command in this message, you cannot claim it passes.
|
|
10
|
+
|
|
11
|
+
## The Gate Function
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
BEFORE claiming any status or expressing satisfaction:
|
|
15
|
+
|
|
16
|
+
1. IDENTIFY: What command proves this claim?
|
|
17
|
+
2. RUN: Execute the FULL command (fresh, complete)
|
|
18
|
+
3. READ: Full output, check exit code, count failures
|
|
19
|
+
4. VERIFY: Does output confirm the claim?
|
|
20
|
+
- If NO: State actual status with evidence
|
|
21
|
+
- If YES: State claim WITH evidence
|
|
22
|
+
5. ONLY THEN: Make the claim
|
|
23
|
+
|
|
24
|
+
Skip any step = lying, not verifying
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Common Failures
|
|
28
|
+
|
|
29
|
+
| Claim | Requires | Not Sufficient |
|
|
30
|
+
|-------|----------|----------------|
|
|
31
|
+
| Tests pass | Test command output: 0 failures | Previous run, "should pass" |
|
|
32
|
+
| Build succeeds | Build command: exit 0 | Linter passing, logs look good |
|
|
33
|
+
| Bug fixed | Test original symptom: passes | Code changed, assumed fixed |
|
|
34
|
+
| Task complete | Success criteria verified | "I wrote the code" |
|
|
35
|
+
| Phase ready | All tasks verified | Prime Worker reports success |
|
|
36
|
+
|
|
37
|
+
## Red Flags - STOP
|
|
38
|
+
|
|
39
|
+
When you catch yourself:
|
|
40
|
+
- Using "should", "probably", "seems to"
|
|
41
|
+
- Expressing satisfaction before verification ("Great!", "Done!")
|
|
42
|
+
- About to report completion without running checks
|
|
43
|
+
- Trusting spawn reports without independent verification
|
|
44
|
+
- Relying on partial verification
|
|
45
|
+
- **ANY wording implying success without having run verification**
|
|
46
|
+
|
|
47
|
+
## Rationalization Prevention
|
|
48
|
+
|
|
49
|
+
| Excuse | Reality |
|
|
50
|
+
|--------|---------|
|
|
51
|
+
| "Should work now" | RUN the verification |
|
|
52
|
+
| "I'm confident" | Confidence ≠ evidence |
|
|
53
|
+
| "Just this once" | No exceptions |
|
|
54
|
+
| "Spawn said success" | Verify independently |
|
|
55
|
+
| "Partial check is enough" | Partial proves nothing |
|
|
56
|
+
|
|
57
|
+
## Verification Patterns
|
|
58
|
+
|
|
59
|
+
**Tests:**
|
|
60
|
+
```
|
|
61
|
+
✅ [Run test command] → [See: 34/34 pass] → "All tests pass"
|
|
62
|
+
❌ "Should pass now" / "Looks correct"
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
**Build:**
|
|
66
|
+
```
|
|
67
|
+
✅ [Run build] → [See: exit 0] → "Build succeeds"
|
|
68
|
+
❌ "Code compiles" (without running build)
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
**Task Completion:**
|
|
72
|
+
```
|
|
73
|
+
✅ Re-read success criteria → Verify each with evidence → Report with proof
|
|
74
|
+
❌ "Tasks done, phase complete"
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
**Spawn Verification:**
|
|
78
|
+
```
|
|
79
|
+
✅ Spawn reports success → Check files exist → Run tests → Report actual state
|
|
80
|
+
❌ Trust spawn report blindly
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Phase Advancement Gate
|
|
84
|
+
|
|
85
|
+
Before `/ant:continue` advances to next phase:
|
|
86
|
+
|
|
87
|
+
1. **Build Check**: Run project build command (if exists)
|
|
88
|
+
2. **Test Check**: Run test suite, capture pass/fail counts
|
|
89
|
+
3. **Success Criteria**: Line-by-line verification of phase criteria
|
|
90
|
+
4. **Evidence Required**: Each criterion needs specific proof
|
|
91
|
+
|
|
92
|
+
```
|
|
93
|
+
Phase {N} Verification
|
|
94
|
+
======================
|
|
95
|
+
|
|
96
|
+
Build: {command} → {exit code}
|
|
97
|
+
Tests: {command} → {pass}/{total} ({fail} failures)
|
|
98
|
+
|
|
99
|
+
Success Criteria:
|
|
100
|
+
✅ Criterion 1: {evidence}
|
|
101
|
+
✅ Criterion 2: {evidence}
|
|
102
|
+
❌ Criterion 3: {what's missing}
|
|
103
|
+
|
|
104
|
+
Verdict: PASS / FAIL
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
If ANY criterion fails verification, phase cannot advance.
|
|
108
|
+
|
|
109
|
+
## Why This Matters
|
|
110
|
+
|
|
111
|
+
- False completion claims break trust
|
|
112
|
+
- Unverified code ships bugs
|
|
113
|
+
- Time wasted on rework from premature advancement
|
|
114
|
+
- Colony integrity depends on honest reporting
|
|
115
|
+
|
|
116
|
+
**Evidence before claims, always.**
|