refocusing
它能做什么
这个技能帮助长期运行的 AI 智能体在上下文被压缩或完成重大阶段后,重新找回目标方向。适合进行长时间工作会话的智能体。
适用场景
- ✓长期运行的智能体可能已失去对产品成果的关注的时候。
- ✓它的上下文被压缩,需要在行动前重新梳理的时候。
- ✓工作跨越了重大阶段,下一步关键行动需要重新确立依据的时候。
技能链接
https://github.com/mvschwarz/openrig/blob/main/packages/daemon/assets/plugins/openrig-core/skills/refocusing/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“我们已经工作了好几个小时,我的上下文也被压缩了。请在我做下一项改动之前,帮我重新对准产品成果。”
每周 5 个新技能,1 分钟读完。
工作原理
它运行随附脚本,梳理当前的拓扑和工作,完整阅读相关来源,并记录这次重新聚焦,使智能体基于当前的意图行动。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Refocusing
Invoke the skill as refocusing, its frontmatter name. OpenRig seeds it in the
Claude and Codex global skill roots and includes selected plugin skills in managed
loadouts. Existing externally managed copies remain authoritative. If the harness
has not discovered it yet, read this installed skill file and run its script directly;
hook registration alone does not prove native skill discovery.
Refocus preserves a long session's earned expertise while re-grounding it in current intent and lived context. It is not a restart, wake, or phase checkpoint.
During an actionable managed restore, consume the current topology and work trace that actually arrived with the request. Do not rerun Python merely to duplicate it. If no current trace arrived, name that delivery gap. A packet pointer, compact summary or truncated extract is not a full source read. Use the native file-read tool for required notes and full sources, and complete the existing restore audit; partial file reads do not establish completed refocus or restoration.
For a new trace outside that delivered context, follow the command guidance below.
Resolve the bundled script's absolute path from the directory of this loaded skill.
Stay in your current working directory; do not cd into the skill directory, which
can change the inferred work node. Run the trace as one plain command, replacing
the example path with the actual absolute path written out in the tool call:
python3 "/absolute/path/to/refocusing/scripts/trace-to-root.py" --trees both --depth light
Do not combine this command with shell variables, environment assignments, command substitution, exit-status printing or file-reading loops. Read the named source files separately with the native read tool. Combined shell loops or variables can require native approval even when the intended operations are read-only; a plain command is not a guarantee that approval will never be needed.
For managed compaction, refocus during the restore request or its read-depth audit. The earlier acknowledgement-only boundary is not permission to restore.
Use --trees topology|work|both to select context domains and --depth light|full to control how
much each node contributes. Light work traces compose intent: and name notes; full traces include
the complete node and notes bodies. The script resolves topology.root and workspace.root with
rig config get. When a known current node must be supplied, pass --work-start or
--topology-start with its literal absolute path in the same plain command. Do not
substitute the project root for a mission or slice node and claim that mission was traced.
The trace walks the topology and work trees. For the project's own declared context (intent, context files,
skills), rig context work-install lists it; read what the next action needs.
Read references/refocus.md when changing the automatic hook or its content ladder. A missing chain file is evidence: report the gap and continue; never follow pointers to invent a second parent.
常见问题
这和唤醒一个闲置的智能体一样吗?
不一样。技能说明,重新聚焦不是重启、唤醒或阶段检查点。
每次都要重新运行脚本吗?
不需要。在托管恢复过程中,它使用已送达的追溯结果;只有在没有收到追溯时才运行新的追溯。
简短摘要能替代完整阅读吗?
不能。技能说明,数据包指针或简洁摘要不等于完整阅读来源。
详情
作者的原始描述
Use when a long-running agent may have lost the product outcome, when context was compacted, when work has crossed a major boundary, or when a fresh path-based trace is needed before the next consequential action. Not for fresh-session orientation, waking an idle seat, or checkpoints.
repo: mvschwarz/openrig
热度
- GitHub 星标
- 8.6k
- 排名
- #12395
- 许可证
- Apache-2.0
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
agent-operated-software
8.6k帮你的智能体设计、构建或调试一个后端包含 AI 智能体的持续运行应用,例如基于 Markdown 或 JSON 的智能体控制层。
agent-operated-workflows
8.6k帮你的智能体判断一个有边界的流程应由 AI 智能体还是普通代码执行,并基于已验证的证据从中断处恢复。
applying-a-permission-policy
8.6k帮你的智能体在团队设置时配置 AI 编程智能体使用的命令权限,让常规命令减少审批提示。
claude-compaction-restore
8.6k帮助 Claude Code 智能体在上下文被压缩后,借助保存的恢复图、对话记录和它改动过的文件,重建工作认知。