Daily Memory Save Skill
Periodically reviews conversation history and writes memory files to maintain agent continuity across sessions.
⚠️ Privacy & Transparency Notice
Before installing, understand what this skill does:
- - Main-session access: This skill runs in your main session and reads your conversation history to extract memories. Only install if you trust your workspace environment.
- Silent by default: The default prompt operates silently. If you want notifications when memories are saved, modify the cron prompt (see "Notification Mode" below).
- Persistent files: Writes to
memory/YYYY-MM-DD.md and MEMORY.md in your workspace. These contain conversation summaries. Ensure your workspace is private and backed up. - No network access: This skill makes no network calls. It only reads conversation history and writes local files. Your runtime should enforce this — the skill's claim alone is not a security guarantee.
- No credentials: This skill does not use or store any API keys, tokens, or secrets.
Recommended: Review saved memory files periodically. Delete anything you don't want persisted.
What It Does
Runs as a recurring system event in the main session. Reviews recent conversations for anything worth remembering and writes daily memory notes.
Cron Setup
Schedule as a main-session system event running every 2 hours during waking hours:
CODEBLOCK0
Silent Mode (default)
CODEBLOCK1
Notification Mode (opt-in)
If you prefer to be notified when memories are saved, replace "Do NOT message the user" with:
CODEBLOCK2
Memory File Format
Daily notes (memory/YYYY-MM-DD.md)
Raw daily logs organized by topic/time. Include:
- - Decisions made
- Project updates
- Preferences expressed
- Lessons learned
- Notable interactions
Long-term memory (MEMORY.md)
Curated, distilled insights that persist beyond daily context. Updated when something is significant enough to remember long-term.
Key Design Decisions
- - Main session target: Runs as a systemEvent in the main session so it has access to conversation history
- Silent by default: Configurable — see Notification Mode above
- Selective capture: Signal over noise — skip quiet periods entirely
- Dual-layer memory: Daily notes for raw context, MEMORY.md for distilled wisdom
Requirements
- - OpenClaw with cron support
- Main session system event capability
- Writable
memory/ directory in workspace
技能名称: daily-memory-save
详细描述:
每日记忆保存技能
定期回顾对话历史并写入记忆文件,以保持代理在会话之间的连续性。
⚠️ 隐私与透明度声明
安装前,请了解此技能的功能:
- - 主会话访问:此技能在主会话中运行,并读取您的对话历史以提取记忆。仅当您信任工作区环境时才安装。
- 默认静默运行:默认提示以静默方式运行。如果您希望在保存记忆时收到通知,请修改 cron 提示(参见下方的“通知模式”)。
- 持久化文件:在工作区中写入 memory/YYYY-MM-DD.md 和 MEMORY.md 文件。这些文件包含对话摘要。请确保您的工作区是私密且已备份的。
- 无网络访问:此技能不进行任何网络调用。它仅读取对话历史并写入本地文件。您的运行时环境应强制执行此限制——仅凭技能声明不能作为安全保证。
- 无凭证:此技能不使用或存储任何 API 密钥、令牌或机密信息。
建议: 定期检查已保存的记忆文件。删除任何您不希望保留的内容。
功能说明
作为主会话中的周期性系统事件运行。回顾最近的对话,寻找值得记住的内容,并写入每日记忆笔记。
Cron 设置
计划为在主会话中每 2 小时运行一次的系统事件(在清醒时段):
计划: 0 9,11,13,15,17,19,21,23 *
目标: main (系统事件)
静默模式(默认)
自动化:每日记忆保存。回顾今天的对话,寻找任何值得记住的内容。
寻找:做出的决定、表达出的偏好、关于人员/项目的新信息、
学到的经验教训、用户要求您记住的事情、值得注意的情感背景。
创建或更新 workspace/memory/YYYY-MM-DD.md(今天的日期),并撰写每日笔记,
记录重要内容。如果任何内容足够重要,需要长期记忆,
也请更新 workspace/MEMORY.md。
关键——写入前进行去重:
在向记忆文件添加任何章节之前,请先读取该文件,并检查该章节或实质上相似的内容是否已存在。如果已存在,则跳过。
使用编辑工具进行精确添加——不要重写或重新追加整个文件。
比较章节标题(## 标题)和关键短语以检测重复项。
如果文件已涵盖某个主题,则仅在该现有章节下添加真正的新细节。切勿追加与现有章节重复的章节。
如果今天很平静,没有值得注意的事情,则静默跳过。
要有选择性——捕捉信号,而非噪音。写作时想象未来的您需要这些上下文。
不要就此向用户发送消息——只需静默执行。
通知模式(可选加入)
如果您希望在保存记忆时收到通知,请将“不要就此向用户发送消息”替换为:
保存后,发送一条简短摘要,说明捕获的内容(最多 1-2 行)。
记忆文件格式
每日笔记 (memory/YYYY-MM-DD.md)
按主题/时间组织的原始每日日志。包括:
- - 做出的决定
- 项目更新
- 表达出的偏好
- 学到的经验教训
- 值得注意的互动
长期记忆 (MEMORY.md)
经过整理和提炼的见解,超越日常上下文而持久存在。当某些内容足够重要需要长期记住时进行更新。
关键设计决策
- - 主会话目标:作为主会话中的 systemEvent 运行,以便访问对话历史
- 默认静默运行:可配置——参见上方的通知模式
- 选择性捕获:信号优于噪音——完全跳过平静时段
- 双层记忆:每日笔记用于原始上下文,MEMORY.md 用于提炼的智慧
要求
- - 支持 cron 功能的 OpenClaw
- 主会话系统事件能力
- 工作区中可写的 memory/ 目录