关于 task-handoff
task-handoff 是帮助 Agent 在暂停任务时保存进度、并在之后接续工作的技能。它通过交接文档和状态文件记录当前状态、已完成事项及后续步骤。
主要功能
- 01交接前检查文件与测试状态
- 02生成带时间戳的交接文档
- 03更新任务状态与文件清单
- 04接手时先读取文档并运行测试
- 05完成后清理交接记录
适用场景
- 01暂停正在进行的编码任务
- 02在不同工作阶段间传递任务
- 03恢复中断的任务并避免重复工作
安装
复制下面的命令,在终端中运行。
$
npx skills add https:/ / github.com/ archieindian/ openclaw-superpowers --skill task-handoff安装后在 Claude Code 中输入/task-handoff确认已加载。
附带文件STATE_SCHEMA.yaml
详细介绍
任务交接
状态文件:~/.openclaw/skill-state/task-handoff/state.yaml
交接前检查清单
- 当前状态稳定(没有写到一半的文件,也没有失败的测试)
- 所有已修改的文件均已保存
- 已运行测试
- 已编写交接文档
- 已更新状态文件
- 已更新记忆
编写交接文档
保存到 tasks/handoff-[task-name]-[timestamp].md:
# Handoff: [task name]
Written: YYYY-MM-DD HH:MM
Reason: [why stopping]
## Current State
[1-3 sentences: exactly where things are]
## What's Done
- [step] done
## What's Next
- [next step] - specific instructions
## Important Context
- [anything non-obvious from the code]
- [decisions made and why]
## Files Modified
- path/to/file - [what changed]
## Tests
- Last run: YYYY-MM-DD HH:MM
- Status: PASSING / FAILING
## Blockers
- [anything blocking]
然后更新状态:active_handoff_path(文件的完整路径)、task_name、reason、status: written、written_at、files_modified。
接手交接任务
- 读取状态文件,获取
active_handoff_path - 在触碰任何代码之前,完整阅读交接文档
- 运行测试以确认当前状态
- 从“接下来要做什么”开始——不要重复已完成的步骤
- 完成后:删除交接文件,将状态更新为
status: picked_up,清空active_handoff_path
评论
支持 Markdown