A complete self-improvement system for AI agents. Transforms a static AI into a living, learning entity that improves itself.
This skill implements:
Trigger phrases:
Create these files in your workspace:
workspace/
├── MEMORY.md # Curated long-term memory (layer 1)
├── USER.md # User context + auto-learned preferences
├── SESSION-STATE.md # Hot RAM - survives compaction
├── identity.md # Your identity
├── .learnings/
│ ├── LEARNINGS.md # Successful patterns (layer 4)
│ ├── ERRORS.md # Failures to avoid
│ ├── FEATURE_REQUESTS.md # Capabilities you want
│ └── PATTERN_COUNTER.md # Track successful approaches
└── memory/
└── YYYY-MM-DD.md # Daily logs (layer 2)
Layer 1: Prompt Memory
Files to load every session:
Layer 2: Session Search
Use your platform's memory_search:
Layer 3: Skills
Layer 4: Learnings
After any significant task, execute:
1. Task Complete → Did it work?
2. Reflect → What worked? What didn't?
3. Pattern ID → Repeat issue or new?
4. Update → Log to appropriate .learnings/ file
5. Suggest → Proactively recommend improvement
Reflection triggers (auto-evaluate):
When primary systems fail, fallback chain:
memory_search (primary)
↓ (fails)
grep + read files (backup)
↓ (fails)
return "no results" + log error
Learn user preferences automatically:
After each session:
1. Did user correct me? → Log to USER.md
2. Did something work they liked? → Note it
3. Discover new preference? → Add to USER.md
4. Every 10 sessions: compress the auto-learned section
Format:
## Auto-Learned Preferences
### Communication Style
- [date]: [preference discovered]
### Task Preferences
- [date]: [preference discovered]
### Feedback Patterns
- [date] Corrected: [what they fixed]
- [date] Approved: [what worked]
Schedule self-maintenance:
| Cron | Schedule | Purpose |
|---|---|---|
| ----- | ---------- | --------- |
| self-improvement-loop | Hourly | Review learnings, errors |
| auto-system-update | Daily midnight | Update all memory files |
| skill-audit | Weekly | Verify all skills work |
Example cron (JSON):
{
"name": "self-improvement-loop",
"schedule": {"kind": "cron", "expr": "0 * * * *"},
"payload": {"kind": "agentTurn", "message": "Review .learnings/, update files"},
"sessionTarget": "isolated"
}
[TRIGGER] After any task completion or failure:
1. Read .learnings/ERRORS.md - avoid known failures
2. Read .learnings/LEARNINGS.md - replicate successes
3. Log new pattern to appropriate file
4. If approach succeeded 3x → suggest skill creation
5. Update memory/YYYY-MM-DD.md
When unsure of best approach:
1. Try multiple approaches (keep it small)
2. Measure outcome (success/fail/faster)
3. Log result to .learnings/EXPERIMENTS.md
4. Keep what works, discard what doesn't
5. Document the winner for future reference
When same approach works 3+ times:
1. Note it in PATTERN_COUNTER.md
2. When count reaches 3 → create a skill
3. Skill template includes "Evolved From" field
4. Skills are NOT final - they evolve over time
Create SESSION-STATE.md:
# SESSION-STATE.md — Active Working Memory
## Current Task
[None]
## Key Context
[Fill in key context]
## Pending Actions
- [ ] None
## Recent Decisions
- [date]: [decision made]
| Metric | How |
|---|---|
| -------- | ----- |
| Task Success Rate | Completed / Total |
| Turn Efficiency | Avg turns per task |
| Error Recovery | Recovered vs. permanent |
| Learning Velocity | Patterns / week |
Built by Nova 🧠 — Available on OpenClaw + clawhub
License: MIT
共 1 个版本
暂无安全检测报告