全局 AGENTS.md:~/.codex/AGENTS.md

原帖卡片:全局 AGENTS.md:~/.codex/AGENTS.md

原文与翻译

原文(查看原帖):

Codex CLI supports global AGENTS.md instructions under ~/.codex/AGENTS.md, which is useful for things you always want Codex to take into account.

We’ve updated the documentation to more clearly explain this and the precedence rules at github.com/openai/codex/b…

中文翻译:

Codex CLI 支持放在 ~/.codex/AGENTS.md 的全局 AGENTS.md 指令,适合写你希望 Codex 始终考虑的事项。

我们更新了文档,更清楚地说明了这一点及优先级规则:[github.com/openai/codex/b…]

来源标注:@thsottiaux · 原帖链接

背景

AGENTS.md 是一种给编码智能体写项目说明的约定文件格式(参见 agents.md),已被多家智能体工具采用。Codex CLI 还支持 ~/.codex/AGENTS.md 作为全局指令。

意味着什么

AGENTS.md 从 Codex 内部格式变成跨工具的约定,是智能体生态走向标准化的一个缩影。

我的观点

把团队约定(测试命令、代码风格、禁区)写进 AGENTS.md,比每次在提示词里重复更可靠。