Codex CLI 0.128.0 新增 /goal 功能
摘要
OpenAI 的 Codex CLI v0.128.0 引入了 /goal 命令,使编程代理能够朝着既定目标迭代工作,直至任务完成或 Token 耗尽。
暂无内容
查看缓存全文
缓存时间: 2026/05/08 06:55
# Codex CLI 0.128.0 新增 /goal 功能
来源:https://simonwillison.net/2026/Apr/30/codex-goals/
2026年4月30日 \- 链接博客
**Codex CLI 0.128.0 新增 /goal (https://github.com/openai/codex/releases/tag/rust-v0.128.0)**(来自 (https://twitter.com/fcoury/status/2049917871799636201))OpenAI 的 Codex CLI 编程智能体最新版本加入了他们自己的 Ralph 循环 (https://ghuntley.com/ralph/) 实现:你现在可以设置一个 `/goal`,Codex 将不断循环执行,直到它评估目标已完成……或者配置的 token 预算耗尽。
该功能似乎主要通过 `goals/continuation.md` (https://github.com/openai/codex/blob/6014b6679ffbd92eeddffa3ad7b4402be6a7fefe/codex-rs/core/templates/goals/continuation.md) 和 `goals/budget_limit.md` (https://github.com/openai/codex/blob/6014b6679ffbd92eeddffa3ad7b4402be6a7fefe/codex-rs/core/templates/goals/budget_limit.md) 提示词实现,这些提示词会在每个轮次结束时自动注入。
发布于 2026年4月30日 (https://simonwillison.net/2026/Apr/30/) 23:23
## 最新文章
- 关于 xAI/Anthropic 数据中心交易的笔记 (https://simonwillison.net/2026/May/7/xai-anthropic/) \- 2026年5月7日
- 直播博客:与 Claude 一起编码 2026 (https://simonwillison.net/2026/May/6/code-w-claude-2026/) \- 2026年5月6日
- Vibe 编码和代理式工程正变得比我预期的更近 (https://simonwillison.net/2026/May/6/vibe-coding-and-agentic-engineering/) \- 2026年5月6日
这是由 Simon Willison 撰写的一篇**链接帖子**,发布于 2026年4月30日 (https://simonwillison.net/2026/Apr/30/)。
ai2008 (https://simonwillison.net/tags/ai/)openai417 (https://simonwillison.net/tags/openai/)prompt\-engineering189 (https://simonwillison.net/tags/prompt-engineering/)generative\-ai1779 (https://simonwillison.net/tags/generative-ai/)llms1745 (https://simonwillison.net/tags/llms/)coding\-agents198 (https://simonwillison.net/tags/coding-agents/)system\-prompts54 (https://simonwillison.net/tags/system-prompts/)codex\-cli34 (https://simonwillison.net/tags/codex-cli/)agentic\-engineering48 (https://simonwillison.net/tags/agentic-engineering/)
### 月度简报
赞助我 **$10/月**,获取本月最重要的 LLM 发展精选邮件摘要。
付钱让我少发点!
赞助与订阅 (https://github.com/sponsors/simonw/)
相似文章
@reach_vb: Codex 中的 /goal 命令太棒了!给 Codex 一个任务。告诉它“完成”是什么样子。让它一直执行直到达成终点…
Codex 引入了 /goal 命令,让 AI 能够自主地朝着定义好的最终状态工作,从而简化重构、迁移和重试循环等长时间运行的任务。
@gdb: 如何在Codex中使用/goal — 让Codex持续工作直到解决一个持久目标:
Greg Brockman的一条推文突出了一篇关于在Codex中使用Goals让AI持续工作于一个持久目标的文章,涵盖了何时使用、验证标准以及架构设计。
在 Claude Code 中使用 /goal
一个社区贡献的解决方案,使 Claude Code 中的 /goal 命令能够管理会话特定的目标和并发工作流,类似于 OpenAI Codex。
@dkundel: https://x.com/dkundel/status/2062650378089594955
关于使用Codex的目标模式(/goal)在长时间内完成复杂编码任务的详细指南,包含定义明确标准、提供指导和衡量进度的小贴士。
@ryancarson:如何使用 Codex 中的 /goal 命令交付大型功能
Ryan Carson 分享了一个使用 Codex 中的 /goal 命令高效交付大型功能的技巧。