agent-heartbeat
БесплатноБез исполняемых скриптовНе проверенAgent 心跳配置技能 — 配置 OpenClaw Agent 的定期心跳机制,保持在线状态,自动检查任务和更新。适用于需要长期运行的 Agent 任务。
от modbender★ 21 звезда на GitHubОб этом скилле
Agent Heartbeat 配置技能
触发词: heartbeat, 心跳, 定期任务, 在线状态, cron, schedule
问题
Agent 需要定期检查任务、保持在线状态、执行定时操作,但缺乏配置心跳的指导。
解决方案
通过配置 HEARTBEAT.md 文件,设置 Agent 定期执行的任务。
HEARTBEAT.md 配置
# Heartbeat Tasks
## 每30分钟检查一次
- 检查未完成的任务
- 发送在线状态更新
- 检查新消息
## 每小时执行一次
- 清理临时文件
- 备份重要数据
- 同步远程状态
OpenClaw CLI 配置
# 查看当前心跳配置
openclaw --profile <profile> status
# 心跳间隔默认为 30 分钟
# 可以通过配置文件修改
最佳实践
- 保持心跳任务轻量 - 避免在心跳中执行耗时操作
- 幂等性 - 心跳任务应该可以安全地重复执行
- 错误处理 - 心跳失败不应影响 Agent 正常运行
- 日志记录 - 记录心跳执行情况便于调试
示例:监控心跳
// 在心跳中检查服务状态
async function heartbeat() {
const status = await checkServices();
if (status.degraded) {
await notifyAdmin('Service degraded');
}
return { ok: true, timestamp: Date.now() };
}
相关技能
error-handling- 错误处理模式http-retry- HTTP 重试机制
Установить agent-heartbeat в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл agent-heartbeat?
Agent 心跳配置技能 — 配置 OpenClaw Agent 的定期心跳机制,保持在线状态,自动检查任务和更新。适用于需要长期运行的 Agent 任务。
Как установить скилл agent-heartbeat?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл agent-heartbeat запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic