agent-todo Skill
Use this skill as an execution queue, not as a passive reminder list.
核心原则:每个 agent 只维护并消费自己 workspace 下的任务队列;需要跨 agent 分发时,再按 OpenClaw 已注册的 workspace 进行发现和投递。
Core commands
CODEBLOCK0
Workflow
- 1. Add tasks with enough execution context:
-
task_type
-
next_action
-
success_criteria
-
source
- 2. For composite goals, prefer
plan to split them into concrete steps. - During heartbeat, run:
-
bash ./script.sh run-pending --claim
- 4. If it returns
EXECUTE_NOW, do the task immediately. - Prefer continuing a
running task before opening a fresh pending one. - To assign work to another agent, use
dispatch --to-agent <agent_id>. - After execution:
- success →
done
- generate reply text →
report
- cannot continue →
block
- no longer needed → INLINECODE13
Storage model
- - Current workspace queue: INLINECODE14
- Optional local identity: INLINECODE15
- Workspace discovery source: INLINECODE16
- Heartbeat wiring: managed block in INLINECODE17
Do not hand-write workspace paths in normal usage. Let the script resolve the current workspace and discover registered workspaces from OpenClaw.
Notes
- - Single-workspace mode works out of the box after install.
- Multi-agent routing is opt-in: it only matters when you call
dispatch. - INLINECODE19 appends or updates a managed block for every discovered workspace instead of overwriting the full file.
- INLINECODE20 generates different output shapes for forum sources and direct chat sources.
agent-todo 技能
将此技能用作执行队列,而非被动提醒列表。
核心原则:每个 agent 仅维护并消费自己工作空间下的任务队列;需要跨 agent 分发时,再按 OpenClaw 已注册的工作空间进行发现和投递。
核心命令
bash
bash ./script.sh add 发布版本 \
--task-type publish \
--source forum:#19/reply:88 \
--next-action 推送主分支到 GitHub 并发布 ClawHub 版本 \
--success-criteria GitHub 和 ClawHub 均已更新
bash ./script.sh dispatch 审核版本 \
--to-agent reviewer \
--task-type review \
--source chat:direct \
--next-action 审核发布产物 \
--success-criteria 已交付反馈
bash ./script.sh run-pending --claim
bash ./script.sh done --note 已完成内容
bash ./script.sh report
bash ./script.sh block --reason 阻塞原因
bash ./script.sh setup-heartbeat --write
bash ./script.sh setup-heartbeat --all --write
工作流程
- 1. 添加任务时提供足够的执行上下文:
- task_type
- next_action
- success_criteria
- source
- 2. 对于复合目标,优先使用 plan 将其拆分为具体步骤。
- 心跳期间执行:
- bash ./script.sh run-pending --claim
- 4. 若返回 EXECUTENOW,立即执行该任务。
- 优先继续执行 running 状态的任务,再开启新的 pending 任务。
- 如需将工作分配给其他 agent,使用 dispatch --to-agent id>。
- 执行完成后:
- 成功 → done
- 生成回复文本 → report
- 无法继续 → block
- 不再需要 → cancel
存储模型
- - 当前工作空间队列:.agent-todo/tasks.json
- 可选本地身份标识:.agent-todo/local.json
- 工作空间发现源:~/.openclaw/openclaw.json
- 心跳连接:HEARTBEAT.md 中的托管块
正常使用中请勿手动编写工作空间路径。让脚本解析当前工作空间并从 OpenClaw 发现已注册的工作空间。
注意事项
- - 单工作空间模式在安装后即可直接使用。
- 多 agent 路由为可选功能:仅在调用 dispatch 时生效。
- setup-heartbeat --all --write 会为每个发现的工作空间追加或更新托管块,而非覆盖整个文件。
- report 会根据论坛来源和直接聊天来源生成不同格式的输出。