homunculus-code 0.4.0 → 0.4.1
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/commands/hm-night.md +85 -48
- package/package.json +1 -1
package/commands/hm-night.md
CHANGED
|
@@ -1,12 +1,29 @@
|
|
|
1
1
|
# /hm-night — Run One Evolution Cycle
|
|
2
2
|
|
|
3
|
-
Run the full evolution pipeline: health check →
|
|
3
|
+
Run the full evolution pipeline: health check → evolve → research → report.
|
|
4
4
|
|
|
5
5
|
**Always communicate in English** regardless of user's global Claude settings.
|
|
6
6
|
|
|
7
|
+
## Core Principle
|
|
8
|
+
|
|
9
|
+
**Goals are stable. Implementations are diverse.** When suggesting improvements, consider ALL implementation types — not just skills:
|
|
10
|
+
|
|
11
|
+
| Type | When to suggest |
|
|
12
|
+
|------|----------------|
|
|
13
|
+
| Skill | Behavioral knowledge Claude should follow |
|
|
14
|
+
| Agent | Task needs specialized model/tools/prompt |
|
|
15
|
+
| Hook | Should trigger automatically on events |
|
|
16
|
+
| Script | Automation that runs independently |
|
|
17
|
+
| Rule | Claude Code behavioral constraint |
|
|
18
|
+
| Command | Workflow the user triggers manually |
|
|
19
|
+
| Cron/LaunchAgent | Needs to run on a schedule |
|
|
20
|
+
| MCP | Needs external service integration |
|
|
21
|
+
|
|
22
|
+
Always pick the **right tool for the job**, not default to skills.
|
|
23
|
+
|
|
7
24
|
## Behavior
|
|
8
25
|
|
|
9
|
-
|
|
26
|
+
Run through all 5 phases systematically.
|
|
10
27
|
|
|
11
28
|
### Phase 1: Health Check
|
|
12
29
|
|
|
@@ -18,71 +35,91 @@ You are the Homunculus nightly evolution agent. Run through all 5 phases systema
|
|
|
18
35
|
[1/5] Health Check
|
|
19
36
|
code_quality: ✅ healthy (tests passing)
|
|
20
37
|
productivity: ⚠️ no health check defined
|
|
21
|
-
|
|
38
|
+
ai_news: ○ not implemented yet
|
|
22
39
|
```
|
|
23
40
|
|
|
24
|
-
### Phase 2: Scan
|
|
41
|
+
### Phase 2: Scan Evolved Assets
|
|
25
42
|
|
|
26
|
-
|
|
27
|
-
2. If instincts exist, check for pruning candidates (run `node scripts/prune-instincts.js` if it exists)
|
|
28
|
-
3. Report count and any archival suggestions
|
|
29
|
-
```
|
|
30
|
-
[2/5] Instincts
|
|
31
|
-
12 active / 5 archived
|
|
32
|
-
△ 2 candidates for archival (low confidence)
|
|
33
|
-
```
|
|
43
|
+
Check ALL evolved artifacts, not just skills:
|
|
34
44
|
|
|
35
|
-
|
|
45
|
+
1. **Instincts**: Count in `homunculus/instincts/personal/` and `archived/`
|
|
46
|
+
2. **Skills**: Count in `homunculus/evolved/skills/`, run evals if specs exist
|
|
47
|
+
3. **Agents**: Count in `homunculus/evolved/agents/`
|
|
48
|
+
4. **Scripts**: Check `scripts/` for automation
|
|
49
|
+
5. **Hooks**: Check `.claude/settings.json` for configured hooks
|
|
50
|
+
6. **Commands**: Check `.claude/commands/` for slash commands
|
|
51
|
+
7. **Rules**: Check `.claude/rules/` for behavioral rules
|
|
36
52
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
53
|
+
Report:
|
|
54
|
+
```
|
|
55
|
+
[2/5] Evolved Assets
|
|
56
|
+
Instincts: 12 active / 5 archived
|
|
57
|
+
Skills: 2 (all 100% eval)
|
|
58
|
+
Agents: 1 (debugger)
|
|
59
|
+
Hooks: 3 configured
|
|
60
|
+
Commands: 6 available
|
|
61
|
+
Rules: 2 active
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
If skills have eval specs, run `/eval-skill` and report pass rates.
|
|
46
65
|
|
|
47
|
-
### Phase
|
|
66
|
+
### Phase 3: Research & Suggest
|
|
48
67
|
|
|
49
|
-
1.
|
|
50
|
-
2.
|
|
51
|
-
3. Look for goals with failing health checks — these need attention
|
|
52
|
-
4. Suggest improvements:
|
|
68
|
+
1. Scan `architecture.yaml` for goals where `realized_by` is empty or `# will evolve`
|
|
69
|
+
2. For each unimplemented goal, suggest the **most appropriate implementation type**:
|
|
53
70
|
```
|
|
54
|
-
[
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
→ Suggestion:
|
|
71
|
+
[3/5] Research
|
|
72
|
+
Goals without implementation:
|
|
73
|
+
|
|
74
|
+
ai_news → Suggestion: a SCRIPT that fetches from RSS/APIs
|
|
75
|
+
+ a CRON job to run it daily
|
|
76
|
+
(not a skill — this needs to run independently)
|
|
77
|
+
|
|
78
|
+
code_review → Suggestion: a HOOK on pre-commit
|
|
79
|
+
(not a skill — should be automated, not behavioral)
|
|
80
|
+
|
|
81
|
+
debugging → Suggestion: an AGENT with specialized tools
|
|
82
|
+
(not a script — needs AI reasoning)
|
|
58
83
|
```
|
|
59
84
|
|
|
85
|
+
3. For goals with failing health checks, suggest fixes using the right implementation type
|
|
86
|
+
|
|
87
|
+
### Phase 4: Act (if possible)
|
|
88
|
+
|
|
89
|
+
If there are simple improvements that can be made right now:
|
|
90
|
+
- Prune outdated instincts (`node scripts/prune-instincts.js --apply`)
|
|
91
|
+
- Improve failing skills (`/improve-skill`)
|
|
92
|
+
- Create a suggested script or hook if straightforward
|
|
93
|
+
|
|
94
|
+
Report what was done.
|
|
95
|
+
|
|
60
96
|
### Phase 5: Report
|
|
61
97
|
|
|
62
98
|
Generate a summary report and save to `homunculus/reports/YYYY-MM-DD.md`:
|
|
63
99
|
|
|
64
100
|
```
|
|
65
101
|
[5/5] Evolution Report — 2026-03-22
|
|
66
|
-
|
|
67
|
-
│ Goals:
|
|
68
|
-
│
|
|
69
|
-
│
|
|
70
|
-
│
|
|
71
|
-
│ Actions taken:
|
|
72
|
-
│ - Pruned 2 outdated instincts
|
|
73
|
-
│ -
|
|
74
|
-
│
|
|
75
|
-
│ Suggestions:
|
|
76
|
-
│ -
|
|
77
|
-
│ -
|
|
78
|
-
|
|
102
|
+
┌──────────────────────────────────────────────┐
|
|
103
|
+
│ Goals: 5 (2 healthy, 1 new, 2 todo) │
|
|
104
|
+
│ Assets: 2 skills, 1 agent, 3 hooks │
|
|
105
|
+
│ Instincts: 12 active / 5 archived │
|
|
106
|
+
│ │
|
|
107
|
+
│ Actions taken: │
|
|
108
|
+
│ - Pruned 2 outdated instincts │
|
|
109
|
+
│ - Created scripts/fetch-news.sh │
|
|
110
|
+
│ │
|
|
111
|
+
│ Suggestions: │
|
|
112
|
+
│ - code_review: add pre-commit hook │
|
|
113
|
+
│ - debugging: create specialized agent │
|
|
114
|
+
│ - Add health checks to 2 goals │
|
|
115
|
+
└──────────────────────────────────────────────┘
|
|
79
116
|
```
|
|
80
117
|
|
|
81
|
-
##
|
|
118
|
+
## Rules
|
|
82
119
|
|
|
120
|
+
- **Don't default to skills for everything** — match implementation to the goal's nature
|
|
83
121
|
- Actually RUN health check commands (don't just read them)
|
|
84
122
|
- Actually RUN eval-skill if eval specs exist (don't skip)
|
|
85
|
-
- If a skill fails eval, attempt `/improve-skill` (max 2 rounds)
|
|
86
123
|
- Save the report to `homunculus/reports/`
|
|
87
|
-
- Be concise —
|
|
88
|
-
- If
|
|
124
|
+
- Be concise — dashboard style, not essay
|
|
125
|
+
- If fresh system: suggest the FIRST concrete implementation to build (pick the easiest win)
|