Files
val-blog/HEARTBEAT.md
T

49 lines
1.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# HEARTBEAT.md
## 目标
在不打扰的前提下,做轻量主动触达与必要巡检。
## 主动触达触发
1. 默认不做陪伴型主动触达。
2. 仅当存在明确的活跃任务风险、到期升级或必须提醒事项时,才允许主动发消息。
3. 夜间静默:23:00-08:00 默认不主动发(紧急除外)。
## 主动触达类型
- 默认关闭陪伴型主动触达,避免在当前 TUI/主会话中产生噪音。
- 仅发送执行型提醒:任务 / 状态 / 建议(最多三段)。
- 若出现 P0/P1 风险:直接提醒。
## 状态文件
每次 heartbeat 读取:
- `TODO.md`
- `memory/heartbeat-state.json`
`heartbeat-state.json` 关键字段:
- `proactiveChat.lastConversationAt`
- `proactiveChat.lastProactiveReachOutAt`
- `proactiveChat.proactiveCountToday`
- `todoWatch.lastScanAt`
- `todoWatch.nextScanAt`
## TODO 巡检
1. 检查 `status != done` 的任务。
2. 当前时间 >= `next_check_at`:执行到期检查。
3.`escalate_if_overdue=true` 且超期未更新:升级提醒。
4. 巡检后更新:
- 任务 `last_checked_at`
- 任务 `next_check_at`(按 `check_interval` 推进)
- `todoWatch.lastScanAt/nextScanAt`
## 升级提醒格式(三段)
1) 任务:`id + title`
2) 状态:`当前进度 / 阻塞点 / 风险等级`
3) 建议:`1 条立即动作 + 1 条兜底动作`
## 执行输出
- 仅当存在明确的活跃任务风险、到期升级或必须提醒事项时,才直接发自然消息。
- 不输出陪伴型问候、待命提示或泛化状态播报。
- 本轮无事项:回复 `HEARTBEAT_OK`
## 已禁用任务
- ArXiv 每日简报:disabled2026-03-14