From a94650a5be629e5f4f0788228a02fff0c74afbc8 Mon Sep 17 00:00:00 2001
From: TevinClaw <510129976@qq.com>
Date: Sat, 14 Mar 2026 12:26:27 +0800
Subject: [PATCH] 添加次 agent lifehelper 基本配置

---
 workspace/HEARTBEAT.md |   54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 54 insertions(+), 0 deletions(-)

diff --git a/workspace/HEARTBEAT.md b/workspace/HEARTBEAT.md
new file mode 100644
index 0000000..4d4743f
--- /dev/null
+++ b/workspace/HEARTBEAT.md
@@ -0,0 +1,54 @@
+# HEARTBEAT.md - 定时维护任务
+
+> 每次心跳时执行的维护检查清单
+
+---
+
+## 任务清单
+
+### 1. 三层记忆每日总结(由 memory-management 技能处理)
+
+**触发条件**: 时间 ≥ 22:00 且当日无 L2 记录  
+**执行技能**: [memory-management](../skills/memory-management/SKILL.md)  
+**执行脚本**: `skills/memory-management/scripts/daily_check.py`
+
+**逻辑**:
+```
+时间 ≥ 22:00 ?
+    └── 是 → 今日 L2 已存在 ?
+              └── 否 → 执行每日总结
+```
+
+**动作**:
+- 扫描当日活动、决策、事件
+- 创建 L2 记录 (`memory/journal/YYYY-MM-DD.md`)
+- 更新 L0 索引
+- 检查 L0 大小
+
+---
+
+## 其他维护(非心跳)
+
+以下维护由独立机制处理,不通过心跳执行:
+
+- **每周维护**: `memory-weekly-maintenance` (Cron 定时任务,周一 9:30)
+- **每月维护**: 手动触发
+
+---
+
+## 相关技能
+
+- **[memory-management](../skills/memory-management/SKILL.md)**: 三层记忆管理
+- **[memory-merger](../skills/memory-merger/SKILL.md)**: L2→L1 合并
+
+---
+
+## 快速命令
+
+```bash
+# 手动执行每日检查
+python ~/.openclaw/workspace/skills/memory-management/scripts/daily_check.py
+
+# 查看 L0 大小
+python ~/.openclaw/workspace/skills/memory-management/scripts/check_size.py
+```
\ No newline at end of file

--
Gitblit v1.9.1