OpenAI Codex(OpenAI 编程智能体) 评测 2026
OpenAI 出品的编程智能体:ChatGPT 网页端 Codex Cloud 云端并行任务(产出 diff/PR)、开源 Codex CLI 本地终端 agent、IDE 扩展三形态;默认模型 GPT-6 Astra(2026-09 起滚动上线);随 ChatGPT 订阅包含;核心开源 Apache-2.0,约 13 万 star。价格以官网为准。
OpenAI's coding agent: Codex Cloud parallel cloud tasks in ChatGPT web (reviewable diffs/PRs), the open-source Codex CLI terminal agent, and an IDE extension; default model GPT-6 Astra (rolling out since Sept 2026); bundled with ChatGPT plans; open-source core (Apache-2.0, ~130k stars). Prices per official site.
概述 Overview
OpenAI 出品的编程智能体:ChatGPT 网页端 Codex Cloud 云端并行任务(产出 diff/PR)、开源 Codex CLI 本地终端 agent、IDE 扩展三形态;默认模型 GPT-6 Astra(2026-09 起滚动上线);随 ChatGPT 订阅包含;核心开源 Apache-2.0,约 13 万 star。价格以官网为准。
OpenAI's coding agent: Codex Cloud parallel cloud tasks in ChatGPT web (reviewable diffs/PRs), the open-source Codex CLI terminal agent, and an IDE extension; default model GPT-6 Astra (rolling out since Sept 2026); bundled with ChatGPT plans; open-source core (Apache-2.0, ~130k stars). Prices per official site.
专家点评 Expert Take
Codex 是 OpenAI 的捆绑打法:产品故事既是能力也是定价——如果你已为 ChatGPT 付费,智能体没有第二笔账单。真正的差异化是异步模式:委派任务,回来收 PR,而不是在编辑器里看着它逐行输入(Cursor/Cline 的循环)。坦诚的提醒:用量与 ChatGPT 套餐限额共享,重度用户会落到 Pro $100/$200 档;云端专属功能(自动代码审查、Slack)在 API 密钥模式下没有;模型阵容变化快(GPT-6 Astra 自 2026 年 9 月滚动上线,GPT-5.5 于 2026 年 10 月 14 日退役)——不要把模型假设硬编码进长期自动化。
Codex is OpenAI's bundling play: the product story is as much pricing as capability — if you already pay for ChatGPT, there is no second bill for the agent. The real differentiator is the async model: delegate a task, come back to a PR, instead of watching it type line by line in your editor (the Cursor/Cline loop). The honest caveats: usage shares your ChatGPT plan's limits, so heavy users land on the Pro $100/$200 tiers; cloud-only features (automatic code review, Slack) don't exist in API-key mode; and the model lineup churns fast (GPT-6 Astra rollout Sept 2026, GPT-5.5 retired Oct 14, 2026) — don't hard-code model assumptions into long-lived automation.
优点 Pros
- ✓ ChatGPT 订阅用户零额外账单——智能体随附
- ✓ 真正异步:委派 → 并行云端运行 → 收 PR,无需守着编辑器
- ✓ 开源核心加标准扩展格式(AGENTS.md / MCP / SKILL.md)
- ✓ 深度 GitHub 集成:PR、自动代码审查、issue 工作流
- ✓ Zero extra bill for ChatGPT subscribers — the agent rides along
- ✓ Truly async: delegate → parallel cloud runs → collect PRs, no editor babysitting
- ✓ Open-source core plus standard extension formats (AGENTS.md / MCP / SKILL.md)
- ✓ Deep GitHub integration: PRs, automatic code review, issue workflows
缺点 Cons
- ✗ 用量与 ChatGPT 套餐共享——重度使用会推到 Pro $100/$200 档
- ✗ API 密钥模式缺少云端功能(自动代码审查、Slack 集成)
- ✗ 2026 年模型阵容变化快(GPT-5.x 退役、GPT-6 Astra 上线)——不要把模型假设硬编码进长期自动化
- ✗ Usage is shared with your ChatGPT plan — heavy use pushes you to the Pro $100/$200 tiers
- ✗ API-key mode lacks cloud features (automatic code review, Slack integration)
- ✗ Fast-moving model lineup in 2026 (GPT-5.x retired, GPT-6 Astra launched) — don't hard-code model assumptions into long-lived automation
核心功能 Key Features
- ☁️Codex Cloud:并行云端任务: 隔离的云端容器并行执行任务,产出可审查的 diff 与 pull request;Plus 及以上档位含自动代码审查与 Slack 集成。
- 🖥️Codex CLI:本地终端智能体: 在沙箱内读取、编辑并运行代码;开源核心(Apache-2.0),一条 npm 命令安装。
- 🧩IDE 扩展: 同一智能体进入编辑器——终端、云端与 IDE 体验一致。
- 📝AGENTS.md + MCP + Skills: 通过 AGENTS.md 设定项目指令,~/.codex/config.toml 中配置 MCP 服务器,开放 SKILL.md 格式的 Agent Skills,外加 subagents——可组合的生态。
- 🔑API 密钥模式: CLI/SDK 按 API token 费率计费——为 CI/CD 与产品集成打造;不含云端功能(GitHub 代码审查、Slack 等)。
- ☁️Codex Cloud: Parallel Cloud Tasks: Isolated cloud containers execute tasks in parallel, producing reviewable diffs and pull requests; automatic code review and Slack integration on Plus and above.
- 🖥️Codex CLI: Local Terminal Agent: Reads, edits, and runs code inside a sandbox; open-source core (Apache-2.0), one npm command to install.
- 🧩IDE Extension: The same agent inside your editor — consistent experience across terminal, cloud, and IDE.
- 📝AGENTS.md + MCP + Skills: Project instructions via AGENTS.md, MCP servers in ~/.codex/config.toml, Agent Skills in the open SKILL.md format, plus subagents — a composable ecosystem.
- 🔑API-Key Mode: CLI/SDK billed at API token rates — built for CI/CD and product integrations; excludes cloud features (GitHub code review, Slack, etc.).
应用场景 Use Cases
- 🚀异步功能开发: 把规格交给云端,让 Codex 并行实现,回来审查并合并 PR——适合规格明确的任务。
- 🔍自动化 PR 代码审查: 把 Codex 接入团队工作流,让每个 PR 都经过自动审查,合并前发现明显问题。
- 🛠️终端结对编程: 让 CLI 在仓库沙箱内编辑代码、运行测试并修复失败,AGENTS.md 让它遵循你的约定。
- 🤖CI/CD 与自动化: API 密钥模式按 token 计费——把重构、迁移与合规检查等重活变成可重复的自动化流水线。
- 🚀Async Feature Work: Hand a spec to the cloud, let Codex implement in parallel, come back to review and merge the PR — ideal for well-specified tasks.
- 🔍Automated PR Code Review: Wire Codex into the team workflow so every PR gets an automatic review pass, catching obvious issues before merge.
- 🛠️Terminal Pair Programming: Let the CLI edit code, run tests, and fix failures inside the repo sandbox, with AGENTS.md keeping it on your conventions.
- 🤖CI/CD & Automation: API-key mode bills by token — turn heavy-lift work like refactors, migrations, and compliance checks into repeatable automated pipelines.
快速开始 Getting Started
ChatGPT 订阅用户直接用:网页端/桌面端开 Codex Cloud 任务;本地终端运行 npm i -g @openai/codex 后用 ChatGPT 账号登录;仓库根目录放 AGENTS.md 写项目约定;API key 模式按 token 计费,用于 CI/CD。
结论 Verdict
OpenAI Codex(OpenAI 编程智能体)是同类 AI 工具中的顶级选择(130k+ GitHub stars)。凭借庞大的开发者社区与持续更新,2026 年值得推荐。
OpenAI Codex is a top-tier agent solution with 130k+ GitHub stars. Its large developer community and ongoing updates make it a recommended choice in 2026.
常见问题 Frequently Asked Questions
2026 年如何访问 Codex?
Codex 随 ChatGPT 套餐捆绑:在 ChatGPT 网页/桌面端启动 Codex Cloud 任务(Plus 及以上最完整;Free 额度非常有限);本地安装开源 Codex CLI(npm i -g @openai/codex)并用 ChatGPT 账号登录;或使用 API 密钥模式,CLI/SDK 用量按 token 计费,用于 CI/CD——不含云端功能。
Codex 的默认模型是什么?
GPT-6 Astra——自 2026 年 9 月 3 日起向 Plus、Pro、Business 与 Enterprise 用户滚动上线;Free 与 Go 档位以标准速度运行 GPT-6 Luna;GPT-5.5 已于 2026 年 10 月 14 日从所有套餐退役。请查看 OpenAI 官方文档了解当前阵容。
Codex 是开源的吗?
核心是开源的:openai/codex 仓库采用 Apache-2.0,约 13 万 GitHub stars(2026 年 10 月核实),包含 CLI 与 SDK,更新频繁;Codex Cloud 服务本身是 OpenAI 的闭源服务。
Codex、Claude Code 与 Cursor 该选哪个?
已有 ChatGPT 订阅且喜欢异步「委派 → 收 PR」模式时选 Codex;Claude Code 仍是重度终端多文件工作的专业开发者首选;可视化 IDE 工作流选 Cursor。也可以组合使用:云端任务用 Codex,编辑器里用别的。
How do I access Codex in 2026?
Codex is bundled with ChatGPT plans: start Codex Cloud tasks in ChatGPT web/desktop (fullest on Plus and above; Free has very limited quota); install the open-source Codex CLI locally (npm i -g @openai/codex) and sign in with your ChatGPT account; or use API-key mode, where CLI/SDK usage is billed by token for CI/CD — without the cloud features.
What is Codex's default model?
GPT-6 Astra — rolling out to Plus, Pro, Business, and Enterprise users since September 3, 2026; Free and Go tiers run GPT-6 Luna at standard speed; GPT-5.5 retired from all plans on October 14, 2026. Check OpenAI's official docs for the current lineup.
Is Codex open source?
The core is open source: the openai/codex repo is Apache-2.0 with ~130k GitHub stars (verified Oct 2026), includes the CLI and SDK, and is frequently updated; the Codex Cloud service itself is OpenAI's closed service.
Codex vs Claude Code vs Cursor?
Pick Codex if you have a ChatGPT subscription and like the async “delegate → receive PR” model; Claude Code remains the pro-developer favorite for heavy terminal-based multi-file work; pick Cursor for visual IDE workflows. You can also combine them: Codex for cloud tasks, something else in the editor.