😎

How to Use Claude Code and Codex

に公開

1. Introduction

  • I use Claude Code (Anthropic) and Codex (OpenAI)[1][2]
  • Both tools let AI write or fix code, but each works best at different steps, so I use them for different parts.
  • Here is how I use them now.Things change fast, so think of this as my current best method.

2. Overall steps

  1. Check requirements & give short instructions: Codex (high quality from short prompts).[2:1]
  2. Build features & edit many files: Claude Code (fast at making changes).[1:1][3]
  3. Review & focus: Codex /review (can review a PR and also uncommitted Git changes with a command).[4]
  • I use MCP/Serena to load related files into the context.

3. Basics

3.1 What is Claude Code?

  • An AI coding agent from Anthropic.[1:2]
  • Good practice is to edit several files together and work with your local tools.[3:1]
  • It can read and edit your repo and run it locally, so it helps speed up the build phase.

3.2 What is Codex?

  • A CLI agent from OpenAI that reads your local folder and can edit and run code.[2:2]
  • It uses GPT-5-Codex, so you can do reviews and refactoring with very short instructions[5]
  • In short, it is designed to work well with minimal prompts.

4. Why I use them this way

  • Requirements & checks → Codex: It reads local context and helps work out details from short instructions.[2:3]
  • Implementation → Claude Code: When changing many files, the structure is easier to see, and the speed feels high.[1:3][3:2]
  • Review → Codex /review: It matches your goal with the Git changes and shows the key issues first, so you read less AI-made code at the start.[4:1]

5. Tips for running /review locally

  • In a talk from the Codex team, they show running /review on local changes before a PR.[6]
  • Codex reads the changed files, runs and tests if needed, and reports the most important points first.[4:2]
  • This step helps clean up long AI-made changes before people read them.

6. My impressions (not official)

  • In my experience, Codex sometimes avoids creating too many new files compared to Claude Code during refactoring.
  • So I often choose Codex for refactoring.

7. References

脚注
  1. Anthropic, “Claude Code overview.” ↩︎ ↩︎ ↩︎ ↩︎

  2. OpenAI, “Codex CLI.” ↩︎ ↩︎ ↩︎ ↩︎

  3. Anthropic, “Best practices for agentic coding.” ↩︎ ↩︎ ↩︎

  4. OpenAI, “Code review with Codex.” ↩︎ ↩︎ ↩︎

  5. OpenAI, “Introducing upgrades to Codex (GPT-5-Codex).” ↩︎

  6. YouTube, “Shipping with Codex.” ↩︎

Discussion