{"repo":"xiaonancs/codex-source-analysis","free":true,"listed":false,"github":"https://github.com/xiaonancs/codex-source-analysis","clone":"git clone https://github.com/xiaonancs/codex-source-analysis.git","description":"OpenAI Codex 源码深度研究 (Rust + TS + Python)：2 总纲 + 25 章 + 3 附录, ~51 万字 + 149 张 Mermaid 架构图","language":"JavaScript","stars":42,"topics":["agent-harness","ai-agent","chinese-documentation","codex","coding-agent","llm-agent","mcp","openai","python","rust"],"license":null,"category":"ai-agents","readme_excerpt":"OpenAI Codex 源码深度研究 这份研究覆盖 OpenAI Codex CLI / Rust 主体 / TS+Python SDK 全貌： 2 篇总纲 + 25 章正文 + 3 个附录 ，约 51 万中文字 / 1.5 MB Markdown 与 149 张 Mermaid 架构图 。 系列研究 本研究是 AI Agent / Coding Harness 源码深度研究系列的一部分，姊妹篇： - Claude Code 源码解析 — Anthropic Claude Code v2.1.88 完整 Agent Harness 拆解（30 篇 / 23 个子系统 / 179 张架构图） - Hermes Agent 深度研究 — Hermes Agent + 4 个同源/对比项目（OpenClaw / EvoMap / OpenHarness / JiuwenClaw），含抄袭分析（38 篇 / 32 章 / 97 张架构图） - OpenClaw 源码深度研究 — 358k Stars OpenClaw v2026.4.15 源码 + 23k commits + 生态调研 引言 OpenAI Codex 在 2025–2026 年从一个早期 TS 原型重写为以 Rust 为主体的多入口 harness： - codex-cli （npm）— 跨平台启动器，把请求转交给原生二进制 - codex-rs （Rust workspace， 120 个 crate）— 真正的核心：CLI、TUI、Agent 循环、App-Server JSON-RPC、沙箱、Plugin 市场、MCP、Cloud Tasks - sdk/typescript 与 sdk/python — 通过 spawn CLI 或 App-Server JSON-RPC 暴露给外部应用 本研究分三部分对其进行系统性源码层面解析： Part I 使用方法与原理（8 章） Part II 源码解析（13 章） Part III 对比与延展（4 章） 生成流程采用三阶段写作： - 第一稿 ：GPT-5.3 Codex High（章节 01-15 + 总纲 + 全网调研）/ Claude Opus 4.7 Thinking High（章节 16-25） - review 与优化升级 ：Claude Opus 4.7 Thinking High 对 17 篇做源码引用核验 + 七维框架补全 + Mermaid 加固 - 最终质量检测 ：GPT-5.5 High 对全 27 篇做 Mermaid 合规、跨章一致性、措辞审慎度收束 研究结构 总纲 文档 内容 ------ ------ 总纲 — Codex 技术主线分析 核心机制、设计哲学、火爆原因、整体架构 全网调研 — 社区认知地图 中英文社区技术分析索引、观点争议、认知盲区 Part I 使用方法与原理（8 章） 序号 章节 关键源码 ------ ------ ---------- 01 项目全景与设计哲学 codex-rs/Cargo.toml 、 AGENTS.md 02 多入口与启动分发 codex-cli/bin/codex.js 、 codex-rs/cli/src/main.rs 、 arg0/ 03 配置系统与企业要求 core/src/config/mod.rs 、 cloud-requirements/ 04 初级使用方法 docs/getting-started.md 、 login/ 05 高级使用方法 cl","default_branch":null,"files":null,"tree":[],"storefront":"/r/xiaonancs","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/xiaonancs/codex-source-analysis/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}