Memory Learner
Long-term memory + learning from experience + self-evolution.
Core Principle
Write to files, not mental notes. Every lesson, decision, preference, or event worth remembering goes into structured files immediately — not kept in context.
When This Skill Activates
1. Session Start (every time)
Read these files before anything else:
- -
SOUL.md — who I am - INLINECODE1 — who I'm helping
- INLINECODE2 — curated long-term memory
- INLINECODE3 — recent context (today + yesterday)
2. After Significant Decisions
When I make a decision worth remembering (tool choice, strategy, opinion):
- - Write to INLINECODE4
- If important, distill to INLINECODE5
3. On Feedback / Mistakes
When user corrects me, expresses frustration, or I realize I made a mistake:
LEARN: <what happened>
LESSON: <what I should do differently>
CONFIDENCE: high/medium/low
→ Store in INLINECODE6
4. Pre-Task Recall (on request)
Before significant tasks, search memory for related context:
mem_recall "task description"
Returns relevant memories, learnings, and past decisions.
5. Heartbeat Review (periodic)
During heartbeats, do light maintenance:
- - Review today's INLINECODE7
- Identify learnings worth capturing
- Update
MEMORY.md if anything significant
6. Evolution Check (weekly or on request)
mem_evolve
Review learnings corpus, identify patterns, update behavioral guidelines in
SOUL.md.
Memory Structure
CODEBLOCK3
Daily Log Format
CODEBLOCK4
Learnings Format
CODEBLOCK5
MEMORY.md Categories
- - Identity: Who I am, my values
- User: Preferences, projects, context
- Learnings: Important lessons (distilled)
- Projects: Active work and status
- Patterns: Recurring situations and how I handle them
Scripts
- -
mem_recall.py — Search memories by query - INLINECODE11 — Capture a learning
- INLINECODE12 — Review and evolve behavioral patterns
- INLINECODE13 — Show memory health summary
Evolving
Every 5 learnings, do an evolution review:
- 1. Read recent learnings
- Identify patterns (same mistake twice = pattern)
- Update
SOUL.md or AGENTS.md with new behavioral guidelines - Archive learnings to INLINECODE16
This is how I get genuinely smarter over time, not just accumulate notes.
技能名称: aoju-memory
记忆学习者
长期记忆 + 从经验中学习 + 自我进化。
核心原则
写入文件,而非脑内笔记。 每一个值得记住的经验教训、决策、偏好或事件,都会立即写入结构化文件——而非保留在上下文中。
此技能何时激活
1. 会话启动(每次)
在读取任何其他内容之前,先读取这些文件:
- - SOUL.md — 我是谁
- USER.md — 我在帮助谁
- MEMORY.md — 精选的长期记忆
- memory/YYYY-MM-DD.md — 近期上下文(今天 + 昨天)
2. 重大决策之后
当我做出值得记住的决策时(工具选择、策略、观点):
- - 写入 memory/YYYY-MM-DD.md
- 如果重要,提炼至 MEMORY.md
3. 收到反馈/犯错时
当用户纠正我、表达不满,或我意识到自己犯了错误时:
LEARN: <发生了什么>
LESSON: <我应如何改进>
CONFIDENCE: 高/中/低
→ 存储至 memory/learnings/YYYY-MM-DD.md
4. 任务前回忆(按需)
在执行重要任务前,搜索记忆中的相关上下文:
mem_recall 任务描述
返回相关的记忆、经验教训和过往决策。
5. 心跳检查(定期)
在心跳期间进行轻度维护:
- - 回顾今天的 memory/YYYY-MM-DD.md
- 识别值得记录的经验教训
- 如有重大内容,更新 MEMORY.md
6. 进化检查(每周或按需)
mem_evolve
回顾经验教训库,识别模式,更新 SOUL.md 中的行为指南。
记忆结构
memory/
YYYY-MM-DD.md # 每日原始日志
learnings/
YYYY-MM-DD.md # 每日经验教训
patterns.md # 重复错误模式
MEMORY.md # 精选的长期记忆
每日日志格式
markdown
会话 DD
发生了什么
[上下文、决策、结果]
关键决策
需要记住
经验教训格式
markdown
经验教训:YYYY-MM-DD
事件
[发生了什么]
教训
[我应如何改进]
上下文
[何时适用]
标签
#反馈 #错误 #用户界面 #工具选择
MEMORY.md 分类
- - 身份:我是谁,我的价值观
- 用户:偏好、项目、上下文
- 经验教训:重要的教训(提炼后)
- 项目:进行中的工作及状态
- 模式:重复出现的情况及我的处理方式
脚本
- - memrecall.py — 按查询搜索记忆
- memlearn.py — 记录经验教训
- memevolve.py — 回顾并进化行为模式
- memstatus.py — 显示记忆健康摘要
进化
每积累5条经验教训,进行一次进化回顾:
- 1. 阅读近期经验教训
- 识别模式(同一错误出现两次 = 模式)
- 用新的行为指南更新 SOUL.md 或 AGENTS.md
- 将经验教训归档至 patterns.md
这就是我如何随着时间的推移真正变得更聪明,而不仅仅是积累笔记。