Wrangling Multiple LLM CLIs
I’m experimenting with different LLM CLIs for my projects—specifically OpenAI Codex, Claude Code, and Google Gemini. The goal is to have flexibility to switch subscriptions and control costs while keeping things easy to test.
Unfortunately, they all have slightly different ways to define system prompts and commands.
For example, Claude Code expects system prompts from ~/.claude/CLAUDE.md1, Google Gemini expects ~/.gemini/GEMINI.md2, and Codex expects ~/.codex/AGENTS.md3.
It gets even more annoying when it comes to commands. Claude and Codex are similar—both use Markdown files with frontmatter—but Codex supports named placeholders4 while Claude doesn’t5. Gemini, for whatever reason, expects TOML format.
Claude6 and Gemini7 support namespacing via subdirectories, while Codex only looks at top-level files8.
My hunch is that eventually they should all converge to a standard format, but we’re still far from it since all the companies just want to push forward instead of slowing down for consensus.
My current workaround is to create a ~/agents folder and keep my system prompt and commands there.
First, I soft-link the AGENTS.md to different config folders:
ln -s ~/agents/AGENTS.md ~/.claude/CLAUDE.md
ln -s ~/agents/AGENTS.md ~/.codex/AGENTS.md
ln -s ~/agents/AGENTS.md ~/.gemini/GEMINI.md
For commands, I keep them in Markdown for now, using the frontmatter (description, argument-hint) and arguments ($ARGUMENTS) that are shared between Claude Code and Codex. Then I soft-link them to the corresponding folders:
ln -s ~/agents/commands ~/.claude/commands
ln -s ~/agents/commands ~/.codex/prompts
And at the end, I just ask an LLM to create Gemini TOML formats from the Markdown examples. 🤷🏻♂️
Edited by Claude (claude-sonnet-4-5-20250929)