Skip to content

Switch a story between Claude Code and Codex

Status: Partial

Nothing about a story belongs to the agent working on it:

  • the story file and its place in the plan
  • the worktree and branch
  • the team context written into that worktree

So switching LL-231 from Claude Code to Codex doesn’t mean starting over. You open the same workspace and run the other CLI.

1. Open the story’s workspace

Right-click LL-231 in the left nav and choose Open story workspace. If the worktree already exists, CodeSense reuses it, and your branch and uncommitted changes are just as the last agent left them.

2. Stop the first agent (or don’t)

Exit Claude Code in its tab, or leave it running. Both agents can share the worktree. If they do, keep them off the same files.

3. Start Codex

Open a New terminal in the workspace and run:

Terminal window
codex

Codex starts in the story’s worktree. It reads AGENTS.md if your team keeps one in its context. The Ledgerline billing team has both a CLAUDE.md and an AGENTS.md.

4. CodeSense tools in Codex

The story’s worktree already has the CodeSense bridge in .codex/config.toml (and in .mcp.json for Claude Code), kept out of git, so Codex started by hand there can use CodeSense’s tools, for example validate_story, or signal_done to record that it finished. A Codex launched from CodeSense gets the bridge for its session without reading that file.

What carries over, and what doesn’t

Claude CodeCodex
Worktree, branch, story fileyesyes
Team context files in the worktreeCLAUDE.md, .claude/ skillsAGENTS.md, plus whatever else your team keeps
CodeSense MCP toolsyesyes
Status dot on the tab (Beta)yesno

A story’s status doesn’t care which agent worked on it either: it’s a field in the story file, and whichever agent finishes writes it. See Statuses and phases.

How we know this is accurate 8 sources

Checked against the app at 1b3d5a69d73473db077dfb44f4390b42cded6bd4.

Feature inventory

  • AG-4
  • D-20

Code

  • src-tauri/src/agents/adapter/claude.rs
  • src-tauri/src/agents/adapter/codex.rs
  • src-tauri/src/commands/managed_worktree_config.rs
  • src-tauri/src/commands/mcp_scope.rs
  • src-tauri/src/commands/mcp_workspace.rs
  • src-tauri/src/commands/deps.rs