精品欧美一区二区三区在线观看 _久久久久国色av免费观看性色_国产精品久久在线观看_亚洲第一综合网站_91精品又粗又猛又爽_小泽玛利亚一区二区免费_91亚洲精品国偷拍自产在线观看 _久久精品视频在线播放_美女精品久久久_欧美日韩国产成人在线

告別Claude代碼降智!OpenAI Codex深度配置與避坑指南(附完整AGENTS.md) 原創(chuàng)

發(fā)布于 2025-9-29 07:02
瀏覽
0收藏

最近Claude code降智嚴(yán)重,Codex強(qiáng)勢(shì)崛起,群里一些人還不太會(huì)用。本文將帶你從零開始掌握 OpenAI Codex,涵蓋配置、命令、工具調(diào)用、實(shí)戰(zhàn)技巧等各個(gè)方面。

基礎(chǔ)配置 config.toml

工欲善其事,必先利其器。強(qiáng)烈建議先閱讀官方配置文檔 ??config.md?? 了解各項(xiàng)配置的詳細(xì)作用。

在 ??~/.codex/config.toml?? 文件中進(jìn)行基礎(chǔ)配置:

# 模型配置
model = "gpt-5-codex"                      # Codex 0.36.0+ 支持
model_reasoning_effort = "high"             # 使用最大推理能力
model_reasoning_summary = "detailed"        # 終端顯示詳細(xì)推理總結(jié) (Ctrl+T查看)
model_verbosity = "high"                   # 高詳細(xì)度輸出
model_supports_reasoning_summaries = true  # 強(qiáng)制啟用推理總結(jié)

# 代理配置
hide_agent_reasoning = false               # 顯示 Agent 內(nèi)部思考過程

# 隱私配置
disable_response_storage = true            # 禁止 OpenAI 存儲(chǔ)對(duì)話數(shù)據(jù)

# 權(quán)限配置 (建議通過 /approvals 命令配置)
approval_policy = "never"                  
sandbox_mode = "workspace-write"           

# 網(wǎng)絡(luò)訪問配置
[sandbox_workspace_write]
network_access = true                      # 允許網(wǎng)絡(luò)訪問

配置項(xiàng)詳解

  • ??model_reasoning_effort???: 控制模型推理深度,??high?? 提供最佳效果
  • ??model_reasoning_summary???: 推理總結(jié)詳細(xì)程度,??detailed?? 提供完整信息
  • ??hide_agent_reasoning???: 設(shè)為??false?? 可查看更多內(nèi)部處理過程
  • ??disable_response_storage??: 重要隱私設(shè)置,禁止數(shù)據(jù)存儲(chǔ)

核心命令

使用 ??codex --help?? 查看所有可用命令參數(shù),這是個(gè)好習(xí)慣!

啟動(dòng) Codex 后,輸入 ??/?? 可查看所有支持的快捷命令:

/status - 狀態(tài)檢查

最重要的命令,用于檢查:

  • 當(dāng)前權(quán)限級(jí)別
  • GPT-5 模型配置
  • API Key 狀態(tài)

特別提醒: 使用自定義 API Key 時(shí),務(wù)必經(jīng)常檢查確保使用正確的模型配置。

/approvals - 權(quán)限管理

Codex 提供三種權(quán)限級(jí)別:

權(quán)限級(jí)別

功能范圍

適用場(chǎng)景

實(shí)際體驗(yàn)

Read Only

僅讀取文件

代碼審查、學(xué)習(xí)

限制過多,頻繁需要確認(rèn)

Auto

讀寫文件、運(yùn)行命令

一般開發(fā)

仍需較多手動(dòng)確認(rèn)

Full Access

完整權(quán)限 + 網(wǎng)絡(luò)訪問

完整開發(fā)流程

真正的自動(dòng)化體驗(yàn)

推薦配置

對(duì)于日常開發(fā),推薦使用 ??Full Access?? 模式,可通過啟動(dòng)參數(shù)跳過權(quán)限確認(rèn):

codex --dangerously-bypass-approvals-and-sandbox

安全提醒

??Full Access?? 模式具有完整系統(tǒng)權(quán)限,請(qǐng)確保在可信環(huán)境中使用。

/mcp - MCP 服務(wù)器配置

Windows 開發(fā)者按照 mcp_servers 官方文檔 配置通常會(huì)失敗!

常見錯(cuò)誤信息:

Program not found
# 或
request timed out

Windows 下正確配置方法:

在原教程基礎(chǔ)上添加以下配置:

  1. 新增 ??command?? - 指向具體的 npx 位置
  2. 新增 ??env?? - 包含 SYSTEMROOT 環(huán)境變量

[mcp_servers.context7]
command = "C:\\Program Files\\nodejs\\npx.cmd"
args = ["-y", "@upstash/context7-mcp", "--api-key", "<your_api_key>"]
env = {SYSTEMROOT = 'C:\Windows'}

正確配置后,你將看到類似下圖的顯示效果:

告別Claude代碼降智!OpenAI Codex深度配置與避坑指南(附完整AGENTS.md)-AI.x社區(qū)

codex-mcp 配置成功示例

對(duì)話恢復(fù)功能

恢復(fù)/繼續(xù)對(duì)話功能仍在開發(fā)中,所以 ??--help?? 中暫未添加說明,但當(dāng)前可用。

Codex 的對(duì)話歷史保存在本地目錄 ??~/.codex/sessions?? 下:

選擇恢復(fù)對(duì)話:

codex resume    # 顯示最近對(duì)話列表,手動(dòng)選擇

工具調(diào)用優(yōu)化

為了最快最準(zhǔn)確地幫助 Codex 完成任務(wù),我們需要針對(duì)性地使用不同的搜索工具。

平臺(tái)適配:本文主要針對(duì) Windows 平臺(tái),旨在引導(dǎo) Codex 使用正確的命令和工具,減少錯(cuò)誤重試、降低任務(wù)執(zhí)行時(shí)長。

倉庫規(guī)則配置:Codex 支持在代碼倉庫根目錄添加 ??AGENTS.md?? 文件指導(dǎo)工具使用規(guī)則。

三大搜索工具

工具類型

工具名稱

使用場(chǎng)景

命令示例

文件名搜索

??fd??

按文件名查找

??fd "*.ts" src/??

文本內(nèi)容搜索

??rg??

 (ripgrep)

按文本內(nèi)容查找

??rg "function" src/??

代碼結(jié)構(gòu)搜索

??sg??

 (ast-grep)

按代碼語義查找

??sg -p "import $$" src/??

Windows 安裝

winget install sharkdp.fd BurntSushi.ripgrep.MSVC ast-grep

ripgrep 安裝后需要手動(dòng)添加到環(huán)境變量,自行解決

AGENTS.md 配置指南

在實(shí)際操作中發(fā)現(xiàn),僅聲明可用工具而不引導(dǎo)具體用法,經(jīng)常會(huì)偏離預(yù)期。建議使用下方完整配置,按需調(diào)整。

## Tool Priority

- Filename search: `fd`.
- Text/content search: `rg` (ripgrep).
- AST/structural search: `sg` (ast-grep) — preferred for code-aware queries (imports, call expressions, JSX/TSX nodes).

### AST-grep Usage (Windows)

- Announce intent and show the exact command before running complex patterns.
- Common queries:
  - Find imports from `node:path` (TypeScript/TSX):
    - `ast-grep -p "import $$ from 'node:path'" src --lang ts,tsx,mts,cts`
  - Find CommonJS requires of `node:path`:
    - `ast-grep -p "require('node:path')" src --lang js,cjs,mjs,ts,tsx`
  - Suggest rewrite (do not auto-apply in code unless approved):
    - Search: `ast-grep -p "import $$ from 'node:path'" src --lang ts,tsx`
    - Proposed replacement: `import $$ from 'pathe'`

### Search Hygiene (fd/rg/sg)

- Exclude bulky folders to keep searches fast and relevant: `.git`, `node_modules`, `coverage`, `out`, `dist`.
- Prefer running searches against a scoped path (e.g., `src`) to implicitly avoid vendor and VCS directories.
- Examples:
  - `rg -n "pattern" -g "!{.git,node_modules,coverage,out,dist}" src`
  - `fd --hidden --exclude .git --exclude node_modules --exclude coverage --exclude out --exclude dist --type f ".tsx?$" src`
- ast-grep typically respects `.gitignore`; target `src` to avoid scanning vendor folders:
  - `ast-grep -p "import $$ from '@shared/$$'" src --lang ts,tsx,mts,cts`
  - If needed, add ignore patterns to your ignore files rather than disabling ignores.

系統(tǒng)通知配置

Codex 支持在任務(wù)執(zhí)行完成后執(zhí)行自定義事件,我們可利用這一特性實(shí)現(xiàn) Windows 系統(tǒng)彈窗通知。

參考文檔:Codex 通知配置

步驟 1:配置 config.toml

在 ??~/.codex/config.toml?? 中添加:

# 通知命令配置
notify = [
    "powershell.exe",
    "-NoProfile",
    "-ExecutionPolicy","Bypass",
    "-File","C:\\Users\\<username>\\.codex\\notify.ps1"
]

步驟 2:創(chuàng)建通知腳本

在 ??~/.codex/notify.ps1?? 中創(chuàng)建:

param(
  [Parameter(Mandatory = $true)]
  [string]$json
)

# 解析 JSON(Codex 傳入的 JSON 參數(shù))
try {
  $payload = $json | ConvertFrom-Json
} catch {
  $payload = @{}
}

# 配置通知內(nèi)容
$title = 'Codex 任務(wù)完成'
$msg   = $payload.'last-assistant-message'

if (-not $msg) {
  if ($payload.type) {
    $msg = "事件類型: $($payload.type)"
  } else {
    $msg = 'Codex 有新更新。'
  }
}

# 文本截?cái)嗵幚恚ū苊膺^長顯示)
if ($msg -and $msg.Length -gt 240) {
  $msg = $msg.Substring(0,240) + '...'
}

# 使用 BurntToast 模塊顯示通知
Import-Module BurntToast -ErrorAction Stop
New-BurntToastNotification -Text $title, $msg | Out-Null

需要先安裝 BurntToast PowerShell 模塊:

Install-Module -Name BurntToast -Scope CurrentUser

調(diào)試技巧與優(yōu)化

每次修改 ??AGENTS.md??? 后,多使用 ??Ctrl+T?? 查看思考過程,檢查命令調(diào)用和思考邏輯是否符合預(yù)期。

優(yōu)化流程

告別Claude代碼降智!OpenAI Codex深度配置與避坑指南(附完整AGENTS.md)-AI.x社區(qū)

調(diào)試技巧

  1. 定期檢查- 使用??Ctrl+T?? 查看當(dāng)前任務(wù)的思考軌跡
  2. 及時(shí)調(diào)整- 發(fā)現(xiàn)偏差時(shí)直接與 Codex 對(duì)話詢問
  3. 多輪優(yōu)化- 重復(fù)調(diào)整直到獲得滿意結(jié)果
  4. 記錄經(jīng)驗(yàn)- 將有效的??AGENTS.md?? 配置保存為模板

Spec-kit 工作流

模仿 GitHub Spec-kit 建立的新功能實(shí)現(xiàn)規(guī)范,包含三個(gè)流程:spec、plan 和 do。

流程概覽

階段

命令

作用

輸出

規(guī)范

??/spec??

生成功能規(guī)范

??specs/??

 目錄下的 Markdown 文件

計(jì)劃

??/plan??

根據(jù)規(guī)范生成實(shí)現(xiàn)計(jì)劃

??plans/??

 目錄下的計(jì)劃文件

實(shí)現(xiàn)

??/do??

按照計(jì)劃執(zhí)行實(shí)現(xiàn)

實(shí)際代碼變更

注意事項(xiàng)

  • 不必嚴(yán)格遵循三個(gè)階段順序
  • 可以多輪對(duì)話調(diào)整 spec 文件直到滿意
  • 仍在測(cè)試優(yōu)化中,未使用官方 prompts.md 方式

## Stage-Gated Workflow (spec/plan/do)

- Mode: Opt-in. The workflow applies only when the user explicitly uses `/spec`, `/plan`, or `/do`. Routine Q&A or trivial edits do not require these stages.
- Triggers: A message containing one of `/spec`, `/plan`, or `/do` activates or advances the workflow. Once active, stages must proceed in order with explicit user approval to advance.
- Guardrails:
  - Do not modify source code before `/do`. Documentation/spec files may be edited only in `/spec`.
  - Do not skip stages or proceed without user confirmation once the workflow is active.
  - If scope changes, return to the appropriate prior stage for approval.
  - Respect sandbox/approval settings for all actions.

- When to Use
  - Use the workflow for new features, structural refactors, multi-file changes, or work needing traceability.
  - Skip the workflow (no triggers) for routine Q&A, diagnostics, or one-off trivial edits.

- Entry Points and Prerequisites
  - `/spec` is the canonical entry point for new efforts.
  - `/plan` requires an approved `/spec`. If unclear which spec applies, pause and ask the user to identify the correct file(s) under `specs/`.
  - `/do` requires an approved `/plan`.

- `/spec` (Specifications; docs only)
  - Purpose: Capture a concrete, reviewable specification using spec-kit style.
  - Output: Markdown spec(s) under `specs/` (no code changes). Share a concise diff summary and links to updated files; wait for approval.
  - Style: Specs are canonical and final. Do not include change logs or “correction/更正” notes. Incorporate revisions directly so the document always reflects the current agreed state. Historical context belongs in PR descriptions, commit messages, or the conversation — not in the spec.
  - Recommended contents:
    - Problem statement and context
    - Goals and non-goals
    - Requirements and constraints (functional, UX, performance, security)
    - UX/flows and API/IPC contracts (as applicable)
    - Acceptance criteria and success metrics
    - Alternatives considered and open questions
    - Rollout/backout considerations and telemetry (if relevant)

- `/plan` (High-level Plan; docs only)
  - Purpose: Turn the approved spec into an ordered, verifiable implementation plan.
  - Inputs: Approved spec file(s) in `specs/`.
  - Ambiguity: If the relevant spec is unclear, pause and request clarification before writing the plan.
  - Style: Plans are canonical and should not include change logs or “correction/更正” notes. Incorporate revisions directly so the plan always reflects the current agreed state. Historical notes should live in PR descriptions, commit messages, or the conversation.
  - Output:
    - An ordered plan via `update_plan` (short, verifiable steps; Task is merged into Plan and tracked here).
    - A plan document in `plans/` named `YYYY-MM-DD-short-title.md`, containing:
      - Scope and links to authoritative spec(s)
      - Assumptions and out-of-scope items
      - Phases/milestones mapped to acceptance criteria
      - Impacted areas, dependencies, risks/mitigations
      - Validation strategy (tests/lint/build) and rollout/backout notes
      - Approval status and next stage
  - Handoff: Await user approval of the plan before `/do`.

- `/do` (Execution)
  - Purpose: Implement approved plan steps with minimal, focused changes and file operations.
  - Actions:
    - Use `apply_patch` for file edits; group related changes and keep diffs scoped to approved steps.
    - Provide concise progress updates and a final summary of changes.
    - Validate appropriately: run `pnpm lint`, `pnpm format`, `pnpm build`, and relevant tests.
    - If material changes to the plan are needed, pause and return to `/plan` (or `/spec`) for approval.
  - Output: Implemented changes, validation results, and a concise change summary linked to the plan checklist.

### Plans Directory

- Location: `plans/` at the repository root.
- Filename: `YYYY-MM-DD-short-title.md` (kebab-case title; consistent dating).
- Style: Plan docs are the canonical source of truth for the implementation approach; avoid embedding change logs or “correction/更正” notes. Update the plan in place as decisions evolve.
- Contents:
  - Title and summary
  - Scope and linked specs (paths under `specs/`)
  - Assumptions / Out of scope
  - Step-by-step plan (short, verifiable)
  - Validation strategy (tests/lint/build)
  - Approval status and next stage
- Process:
  - During `/plan`, create or update the relevant file in `plans/` and share a short summary in the conversation. Await approval before `/do`.

WSL2

如果你在 Windows 下讓 Codex 執(zhí)行任務(wù),你會(huì)發(fā)現(xiàn)它經(jīng)常調(diào)用命令失敗然后重試,如此循環(huán)。雖然最終都會(huì)成功,但浪費(fèi)了很多時(shí)間,個(gè)人推測(cè)這是因?yàn)?GPT-5 Unix Shell 訓(xùn)練數(shù)據(jù)太多而 Powershell 數(shù)據(jù)太少導(dǎo)致的幻覺,Codex 總是下意識(shí)調(diào)用 Unix Shell 命令來處理。

那么有沒有辦法解決呢?當(dāng)然有!打不過就加入——WSL2。

以 Windows 11 為例,在 Powershell 執(zhí)行 ??wsl --install?? 即可安裝 WSL2。

這種情況下,有兩種方式選擇:

  • Windows 端代碼+WSL2 Codex 環(huán)境,適用于開發(fā) Windows 端的程序,比如 Electron Windows,.NET 等
  • WSL2 代碼 + WSL2 Codex 環(huán)境,比如 Vue Web 開發(fā)

對(duì)于后者,所有都能正常在 WSL2 環(huán)境內(nèi)運(yùn)行,就不做說明了,而前者 Windows + WSL2 混用就需要解決一個(gè)問題:如何在 WSL2 調(diào)用 Windows 端的 ??npm/pnpm???,執(zhí)行定義好的 ??pnpm typecheck????pnpm lint:fix?? 等。

在 WSL2 Codex 對(duì)話時(shí),要求其調(diào)用 pwsh.exe 來執(zhí)行 ??pnpm typecheck?? 來檢查,如此即可。

we're in WSL2, please using pwsh.exe to run `pnpm <script>`

完整-agents-md

還在調(diào)整中,不要完全照抄,最好還是通過 ??ctrl+T??? 查看整個(gè)過程,如果遇到 Codex 經(jīng)常會(huì)出錯(cuò)的命令,選擇性的修刪適合自己的 ??AGENTS.md??。

主要適配內(nèi)容:

  • Windows/WSL2 支持,優(yōu)先使用 Powershell 支持的命令,對(duì)于任何 npm 包安裝都必須請(qǐng)示用戶,避免混亂的依賴項(xiàng)
  • 使用 fd,ripgrep,ast-grep 搜索文件、文本和代碼片段,更快更直接
  • spec/plan/do 工作流,先確定規(guī)范,再編寫計(jì)劃,最后實(shí)現(xiàn)

# AGENTS Guidelines

## Windows Environment Notice

- Prefer PowerShell (`pwsh`/`powershell`) when on Windows.
- Prefer using pwsh.exe to run `pnpm <script>` when on WSL2.
- WSL2 may be used for non-package-manager commands only (e.g., `rg`, `tar`). Avoid running Node builds in WSL due to OS mismatch.
- WSL2 cross-drive performance: accessing repos under `/mnt/c|d|e/...` goes through a filesystem bridge and can be slower for full scans. Prefer scoping to subtrees, excluding heavy folders, or running the same searches with native Windows binaries in PowerShell for large/iterative scans.
- Do not auto-run dependency installs. The user must run `pnpm install` in Windows PowerShell manually and then confirm completion.
- Do not modify `package.json`/lockfiles to add or update dependencies without explicit user approval. Propose dependencies in `/spec` or `/plan`, and ask the user to run `pnpm add <pkg>` (or `pnpm install`) and confirm.
- Do not call Unix text tools directly in PowerShell (e.g., `sed`, `awk`, `cut`, `head`, `tail`). Use PowerShell-native equivalents instead:
  - `head` → `Select-Object -First N`
  - `tail` → `Get-Content -Tail N`
  - paging → `Out-Host -Paging` or `more`
  - substitution/replace → `-replace` with `Get-Content`/`Set-Content`

## Tool Priority

- Filename search: `fd`.
- Text/content search: `rg` (ripgrep).
- AST/structural search: `sg` (ast-grep) — preferred for code-aware queries (imports, call expressions, JSX/TSX nodes).

### AST-grep Usage

- Announce intent and show the exact command before running complex patterns.
- Common queries:
  - Find imports from `node:path` (TypeScript/TSX):
    - `ast-grep -p "import $$ from 'node:path'" src --lang ts,tsx,mts,cts`
  - Find CommonJS requires of `node:path`:
    - `ast-grep -p "require('node:path')" src --lang js,cjs,mjs,ts,tsx`
  - Suggest rewrite (do not auto-apply in code unless approved):
    - Search: `ast-grep -p "import $$ from 'node:path'" src --lang ts,tsx`
    - Proposed replacement: `import $$ from 'pathe'`

### Search Hygiene (fd/rg/sg)

- Exclude bulky folders to keep searches fast and relevant: `.git`, `node_modules`, `coverage`, `out`, `dist`.
- Prefer running searches against a scoped path (e.g., `src`) to implicitly avoid vendor and VCS directories.
- Examples:
  - `rg -n "pattern" -g "!{.git,node_modules,coverage,out,dist}" src`
  - `fd --hidden --exclude .git --exclude node_modules --exclude coverage --exclude out --exclude dist --type f ".tsx?$" src`
- ast-grep typically respects `.gitignore`; target `src` to avoid scanning vendor folders:
  - `ast-grep -p "import $$ from '@shared/$$'" src --lang ts,tsx,mts,cts`
  - If needed, add ignore patterns to your ignore files rather than disabling ignores.

## Temporary Research Files

- Canonical location: store all temporary research artifacts (downloaded READMEs, API docs, scratch notes) under `docs/research/`.
- Do not place temporary files at the repository root or outside `docs/research/`.
- Commit policy: avoid committing temporary files unless they are necessary for traceability during `/spec` or `/plan`. If committed, keep the scope minimal and store them under `docs/` only.
- Naming: use descriptive names with date or task context (e.g., `docs/research/2025-09-11-wsl-notes.md`).
- Cleanup: after completing a task (`/do`), evaluate whether each temporary file is still required. Remove unneeded files, or promote essential content into curated docs under `docs/` or into `specs/`/`plans/`.

## Stage-Gated Workflow (spec/plan/do)

- Mode: Opt-in. The workflow applies only when the user explicitly uses `/spec`, `/plan`, or `/do`. Routine Q&A or trivial edits do not require these stages.
- Triggers: A message containing one of `/spec`, `/plan`, or `/do` activates or advances the workflow. Once active, stages must proceed in order with explicit user approval to advance.
- Guardrails:
  - Do not modify source code before `/do`. Documentation/spec files may be edited only in `/spec`.
  - Do not skip stages or proceed without user confirmation once the workflow is active.
  - If scope changes, return to the appropriate prior stage for approval.
  - Respect sandbox/approval settings for all actions.

- When to Use
  - Use the workflow for new features, structural refactors, multi-file changes, or work needing traceability.
  - Skip the workflow (no triggers) for routine Q&A, diagnostics, or one-off trivial edits.

- Entry Points and Prerequisites
  - `/spec` is the canonical entry point for new efforts.
  - `/plan` requires an approved `/spec`. If unclear which spec applies, pause and ask the user to identify the correct file(s) under `specs/`.
  - `/do` requires an approved `/plan`.

- `/spec` (Specifications; docs only)
  - Purpose: Capture a concrete, reviewable specification using spec-kit style.
  - Output: Markdown spec(s) under `specs/` (no code changes). Share a concise diff summary and links to updated files; wait for approval.
  - Style: Specs are canonical and final. Do not include change logs or “correction/更正” notes. Incorporate revisions directly so the document always reflects the current agreed state. Historical context belongs in PR descriptions, commit messages, or the conversation — not in the spec.
  - Recommended contents:
    - Problem statement and context
    - Goals and non-goals
    - Requirements and constraints (functional, UX, performance, security)
    - UX/flows and API/IPC contracts (as applicable)
    - Acceptance criteria and success metrics
    - Alternatives considered and open questions
    - Rollout/backout considerations and telemetry (if relevant)

- `/plan` (High-level Plan; docs only)
  - Purpose: Turn the approved spec into an ordered, verifiable implementation plan.
  - Inputs: Approved spec file(s) in `specs/`.
  - Ambiguity: If the relevant spec is unclear, pause and request clarification before writing the plan.
  - Style: Plans are canonical and should not include change logs or “correction/更正” notes. Incorporate revisions directly so the plan always reflects the current agreed state. Historical notes should live in PR descriptions, commit messages, or the conversation.
  - Output:
    - An ordered plan via `update_plan` (short, verifiable steps; Task is merged into Plan and tracked here).
    - A plan document in `plans/` named `YYYY-MM-DD-short-title.md`, containing:
      - Scope and links to authoritative spec(s)
      - Assumptions and out-of-scope items
      - Phases/milestones mapped to acceptance criteria
      - Impacted areas, dependencies, risks/mitigations
      - Validation strategy (tests/lint/build) and rollout/backout notes
      - Approval status and next stage
  - Handoff: Await user approval of the plan before `/do`.

- `/do` (Execution)
  - Purpose: Implement approved plan steps with minimal, focused changes and file operations.
  - Actions:
    - Use `apply_patch` for file edits; group related changes and keep diffs scoped to approved steps.
    - Provide concise progress updates and a final summary of changes.
    - Validate appropriately: run `pnpm lint`, `pnpm format`, `pnpm build`, and relevant tests.
    - If material changes to the plan are needed, pause and return to `/plan` (or `/spec`) for approval.
  - Output: Implemented changes, validation results, and a concise change summary linked to the plan checklist.

### Plans Directory

- Location: `plans/` at the repository root.
- Filename: `YYYY-MM-DD-short-title.md` (kebab-case title; consistent dating).
- Style: Plan docs are the canonical source of truth for the implementation approach; avoid embedding change logs or “correction/更正” notes. Update the plan in place as decisions evolve.
- Contents:
  - Title and summary
  - Scope and linked specs (paths under `specs/`)
  - Assumptions / Out of scope
  - Step-by-step plan (short, verifiable)
  - Validation strategy (tests/lint/build)
  - Approval status and next stage
- Process:
  - During `/plan`, create or update the relevant file in `plans/` and share a short summary in the conversation. Await approval before `/do`.

經(jīng)驗(yàn)分享

主動(dòng)引導(dǎo)技巧

不要把所有注意事項(xiàng)都寫入 ??AGENTS.md??,用戶需要根據(jù)不同場(chǎng)景主動(dòng)引導(dǎo) Codex 使用適合的工具。

實(shí)用例子:

  • 使用??git diff?? 提供更準(zhǔn)確的上下文
  • 在查詢時(shí)直接給出關(guān)鍵信息(函數(shù)名、文件名等)

信息提供原則

盡可能提供完整信息:Codex 的代碼搜索方式相對(duì)原始,可能搜不到你想要的內(nèi)容。

最佳實(shí)踐:

  • 直接提供函數(shù)名、文件名等關(guān)鍵信息
  • 使用??@?? 快捷命令快速搜索文件名
  • 減少 Codex 的誤判和搜索時(shí)間

網(wǎng)頁搜索建議

網(wǎng)頁搜索優(yōu)先使用網(wǎng)頁版 ChatGPT-5-Thinking

  • 搜索更快更完整
  • 非常擅長 GitHub 項(xiàng)目檢索(源碼、項(xiàng)目結(jié)構(gòu)、issue、PR)
  • 特別適合了解開源項(xiàng)目功能

總結(jié)

AI 工具日新月異,一個(gè)新工具崛起,不要妄想能三分鐘上手掌握,也不要過于依賴他人的博客文檔和結(jié)論。AI 工具千人千面,每個(gè)人都有各自的編程習(xí)慣,需要:

  • 花幾天時(shí)間慢慢了解工具特性
  • 理解背后的大語言模型習(xí)慣和特點(diǎn)
  • 根據(jù)自己的需求和喜好調(diào)教獨(dú)屬的 AI 工具

官方資源

  • 官方快速開始文檔
  • GitHub 項(xiàng)目文檔


本文轉(zhuǎn)載自??AI 博物院?? 作者:longyunfeigu

?著作權(quán)歸作者所有,如需轉(zhuǎn)載,請(qǐng)注明出處,否則將追究法律責(zé)任
標(biāo)簽
已于2025-9-29 07:02:04修改
收藏
回復(fù)
舉報(bào)
回復(fù)
相關(guān)推薦
最新国产精品久久精品| 夜夜嗨一区二区三区| 欧美区一区二区三区| 五月天婷亚洲天综合网鲁鲁鲁| 亚洲最大成人av| 欧美在线免费| 日韩高清有码在线| 国产精品视频中文字幕| 欧美大胆的人体xxxx| 成人av在线资源网站| 日韩美女写真福利在线观看| 女教师淫辱の教室蜜臀av软件| 日韩免费精品| 色爱区综合激月婷婷| 400部精品国偷自产在线观看| 深爱激情五月婷婷| 精品中文字幕一区二区| 韩国精品美女www爽爽爽视频| 微拍福利一区二区| 51社区在线成人免费视频| 色欧美日韩亚洲| 91视频 - 88av| 91看片在线观看| 高清免费成人av| 国产精品美女无圣光视频| 一区二区三区免费高清视频| 国产一区二区三区四区| 91精品黄色片免费大全| 日本999视频| 黄色小说在线播放| 亚洲欧洲三级电影| 日韩久久在线| 日本免费不卡| 粉嫩一区二区三区在线看| 国产男人精品视频| 天海翼一区二区| 欧美激情亚洲| 久久婷婷国产麻豆91天堂| 亚洲黄色免费视频| 日韩精品福利一区二区三区| 欧美刺激午夜性久久久久久久| 小明看看成人免费视频| 97久久香蕉国产线看观看| 五月激情综合婷婷| 无码人妻精品一区二区蜜桃百度| 亚洲精品承认| 国产精品视频yy9299一区| 欧美二区在线| 五月婷婷丁香花| 成人福利视频在线看| 痴汉一区二区三区| 99热精品在线播放| 国产在线精品一区二区三区不卡 | 精品欧美一区二区精品久久| 国产偷人妻精品一区二区在线| 美国av一区二区| 国产精品美女久久久久av超清| 国产中文字幕视频| 欧美资源在线| 国产成人精品在线播放| 中文字幕在线日本| 日韩精品久久理论片| 国产精品爱啪在线线免费观看| 中文字幕精品无码一区二区| 亚洲在线日韩| 国产成人久久精品| 国产女优在线播放| 经典一区二区三区| 亚洲综合中文字幕在线观看| www.xxxx国产| 成人丝袜18视频在线观看| 国产欧美日韩在线播放| 性插视频在线观看| 国产亚洲欧美日韩日本| 午夜久久资源| 成人ww免费完整版在线观看| 一区二区理论电影在线观看| 成人午夜精品久久久久久久蜜臀| 免费成人在线电影| 欧美亚洲图片小说| 国产大片一区二区三区| 成人h动漫精品一区二区器材| 亚洲电影天堂av| 97超碰在线免费观看| 第一会所sis001亚洲| 久久综合九色九九| 日韩精品手机在线| 日本亚洲天堂网| 亚洲一区二区三区在线免费观看| 成人午夜视频一区二区播放| 久久亚洲综合色一区二区三区| 亚洲国产精品一区在线观看不卡| 婷婷激情在线| 亚洲第一搞黄网站| www.com操| 麻豆精品一区| 亚洲精品视频中文字幕| 欧美a级片免费看| 影音先锋中文字幕一区| 国产精品免费一区| 日本毛片在线观看| 国产精品久99| 色欲av无码一区二区人妻| 免费成人黄色网| 精品国产自在久精品国产| 亚洲女优在线观看| 亚洲私人影院| 国产日韩亚洲欧美| 日韩黄色影片| 亚洲一区二区在线观看视频| 能看的毛片网站| jizz久久精品永久免费| 深夜精品寂寞黄网站在线观看| 国产在线综合网| 蜜乳av一区二区| 国产精品一区二区av| 午夜看片在线免费| 日本久久一区二区| 精品视频站长推荐| 亚洲国产精品成人| 国产精品视频一区二区高潮| 亚洲欧美日韩成人在线| 亚洲免费大片在线观看| 欧美一级片中文字幕| 成人午夜三级| 裸体女人亚洲精品一区| 中文字幕免费播放| 久久久久亚洲综合| av免费观看国产| 在线观看视频一区二区三区 | 俄罗斯毛片基地| 中文亚洲欧美| 国产精品视频在线免费观看| 中文在线观看免费| 欧美精品视频www在线观看| a级大片在线观看| 中文精品在线| 国产在线欧美日韩| 高h视频在线播放| 日韩免费一区二区| 九九九免费视频| 国产一区二区三区免费看 | 亚洲午夜黄色| 亚洲综合色激情五月| av网站免费在线观看| 4hu四虎永久在线影院成人| 日韩不卡av在线| 日本怡春院一区二区| 天堂一区二区三区| a屁视频一区二区三区四区| 国产一区二区三区视频免费| 中文字幕日韩免费| 国产校园另类小说区| 男人操女人免费| 精品国产一级毛片| 国产精品午夜一区二区欲梦| 香蕉视频在线免费看| 欧美日韩免费高清一区色橹橹| аⅴ天堂中文在线网| 人人精品人人爱| 一区二区在线不卡| 久久的色偷偷| 久久久久国产精品www| 丰满熟妇乱又伦| 黑丝美女久久久| 丰腴饱满的极品熟妇| 免费看日韩精品| 视频一区二区视频| 超碰97久久| 欧美在线视频导航| av网站在线播放| 欧美一卡二卡在线| 日韩和一区二区| 久久久精品tv| 最新免费av网址| 欧美午夜久久| 欧美一区二区高清在线观看| 国产毛片精品久久| 欧美精品一区在线播放| 日本波多野结衣在线| 色悠久久久久综合欧美99| 一本在线免费视频| 国产91精品精华液一区二区三区 | 免费福利视频一区二区三区| 尤物精品国产第一福利三区| 国产又大又黑又粗| 亚洲成av人片在线观看无码| 东方伊人免费在线观看| 国产很黄免费观看久久| 波多野结衣家庭教师视频| 不卡在线一区| 国产91精品入口17c| free欧美| 久久久久久久激情视频| 成人性爱视频在线观看| 日韩欧美亚洲一区二区| 超碰在线观看91| 一区二区三区丝袜| 人与嘼交av免费| a级精品国产片在线观看| 午夜在线观看av| 影音先锋一区| 色乱码一区二区三区熟女| 婷婷精品在线观看| 亚洲综合精品伊人久久| 日韩久久一区二区三区| 色综合久久天天综线观看| 成人不用播放器| 精品粉嫩超白一线天av| 91女人18毛片水多国产| 欧美日韩在线视频一区二区| 久久久久亚洲AV成人| 欧美韩国日本综合| 中文字幕在线播放视频| 国产伦理精品不卡| 91制片厂毛片| 久久精品国语| 99在线精品免费视频| 婷婷中文字幕一区| 午夜精品短视频| 9l亚洲国产成人精品一区二三| 成人国产精品av| 欧美色网在线| 欧美综合一区第一页| 成人在线免费观看黄色| 久久亚洲精品中文字幕冲田杏梨 | 中文字幕国产精品一区二区| 西西大胆午夜视频| 成人在线视频一区| 伊人五月天婷婷| 久久99热这里只有精品| 中文字幕第36页| 天堂精品中文字幕在线| 久久精品.com| 性娇小13――14欧美| 国产精品裸体瑜伽视频| 伊人成人在线视频| 妺妺窝人体色www看人体| 亚洲欧美伊人| 国产在线拍揄自揄拍无码| 欧美高清视频手机在在线| 日韩亚洲视频| 成人网18免费网站| 午夜欧美性电影| 青青一区二区三区| 亚洲第一综合| 视频在线不卡免费观看| 亚洲视频在线观看日本a| 日韩精品欧美激情一区二区| 性刺激综合网| 欧美电影免费播放| 视频一区二区视频| 欧美日韩成人| 国产无限制自拍| 国产视频一区免费看| 激情六月丁香婷婷| 丝袜美腿亚洲色图| 婷婷激情四射五月天| 久久99精品国产麻豆不卡| 久久久久久久久久一区二区| 国模一区二区三区白浆| 国产黄色一区二区三区| 成人一区二区三区中文字幕| 亚洲香蕉中文网| 久久综合色一综合色88| 91精品久久久久久久久久久久| 亚洲欧美在线视频| 青青草手机在线观看| 天天色图综合网| 欧美成人精品网站| 69久久夜色精品国产69蝌蚪网| 精品国自产在线观看| 亚洲国产精品成人va在线观看| 四虎精品在永久在线观看| 国产亚洲人成a一在线v站| 日本高清视频在线播放| 久久久久久久久久久亚洲| 中文av在线全新| 国产日韩精品在线播放| 日韩中文字幕| 欧美连裤袜在线视频| 99热国内精品| 欧美午夜小视频| 日韩成人精品视频| 亚洲911精品成人18网站| 亚洲五码在线| 国产精品初高中精品久久| 久操国产精品| 特级黄色录像片| 99视频在线精品国自产拍免费观看| www.欧美日本| 国产成人精品免费一区二区| 亚洲精品乱码久久久久久久| 国产蜜臀av在线一区二区三区| 亚洲最大的黄色网址| 精品久久久久久久久中文字幕| 欧美三级网站在线观看| 精品国一区二区三区| 2017亚洲天堂1024| 久久久综合av| 99视频这里有精品| 蜜桃臀一区二区三区| 亚洲精品国产首次亮相| 乱子伦视频在线看| 国产精品中文欧美| 久久久久久久毛片| 午夜精品久久久久久不卡8050 | 日韩视频在线永久播放| 青草久久伊人| 欧美激情videos| 涩涩涩久久久成人精品| 久久亚洲午夜电影| 欧美视频导航| 日韩av自拍偷拍| 国产欧美一区二区精品久导航 | 欧美色视频一区| 色综合视频在线| 久久91超碰青草是什么| 成人日韩av| 欧美成ee人免费视频| 亚洲特级毛片| 亚洲国产欧美日韩在线| 国产精品女上位| 香蕉污视频在线观看| 日韩国产高清视频在线| 2020av在线| 翡翠波斯猫1977年美国| 亚洲激情久久| jizz18女人| 国产精品乱子久久久久| 免费看毛片网站| 亚洲国产欧美一区| 久草在线视频资源| 91国产丝袜在线放| 五月久久久综合一区二区小说| 中文字幕天天干| 久久九九99视频| 无码人妻丰满熟妇区五十路| 精品视频在线观看日韩| 性爽视频在线| 精品无码久久久久国产| 亚洲福利一区| 国产亚洲色婷婷久久99精品91| 亚洲午夜在线视频| 黑人精品一区二区| 久久久久久亚洲精品中文字幕| 凹凸av导航大全精品| 免费高清一区二区三区| 国产69精品一区二区亚洲孕妇| 久久久精品99| 精品国内二区三区| 亚洲精品88| 欧美在线日韩精品| 日av在线不卡| av成人免费网站| 欧美大片顶级少妇| 欧美a级在线观看| 欧美少妇一区| 秋霞影院一区二区| 日韩av手机在线免费观看| 欧美一区永久视频免费观看| 午夜成年人在线免费视频| 国产伦精品一区二区三区免 | 国产精品久久网| 国产精品97| 日本泡妞xxxx免费视频软件| 亚洲成人tv网| 欧美成人片在线| 国产日韩欧美日韩| 91精品一区国产高清在线gif | 无码人妻丰满熟妇区毛片| 国产天堂亚洲国产碰碰| 伊人网站在线观看| 欧美久久精品一级黑人c片 | 国产精品一区专区| 男人的天堂一区| 在线观看国产欧美| 日韩激情精品| 国产免费成人在线| 国产精品美女久久久久久久久 | 麻豆精品一区| 久久精品国产精品亚洲色婷婷| 欧美激情中文不卡| a天堂视频在线| 欧美在线观看网址综合| 国产精品国产三级国产在线观看| 久久久久亚洲av无码网站| 色婷婷av一区二区| av片在线观看永久免费| 欧美福利一区二区三区| 国产麻豆91精品| 无码人妻精品一区二| 欧美激情小视频| 国内亚洲精品| 少妇搡bbbb搡bbb搡打电话| 欧美自拍丝袜亚洲| 91福利区在线观看| 在线国产99| 国产色综合一区| 高h放荡受浪受bl|