Open navigation
Back to Articles

October 2026 · 7 min read

One AGENTS.md Across Claude Code, Codex, and ZCode

How to operate multiple AI coding agents on one codebase using a single AGENTS.md instruction file, practical Windows fallback pointers, and explicit runtime guardrails.

Editorial cover for one agents md across claude code codex zcode

The single instruction file that drives OpenVibeEval

You do not need a fragmented collection of tool-specific instruction files to coordinate multiple AI coding agents across the same codebase. A single root AGENTS.md file is the primary operational contract for Claude Code, Codex, ZCode, and other harnesses, provided it documents concrete runtime ground truths instead of generic persona prompts.[1]

In the OpenVibeEval repository, I keep a single AGENTS.md file at the root. The file is roughly 19.9 KB. It does not contain conversational fluff about being a helpful assistant. Instead, it functions as a strict operational manual for both human contributors and automated coding tools that touch the repository tree.

I structured the file to document exact CLI commands for installation, local development, production builds, testing, linting, type-checking, benchmark result ingestion, automated scoring, and newsletter generation. It also details the repository layout, data schemas, and non-negotiable environment constraints that prevent models from corrupting data.

According to the official AGENTS.md documentation stewarded by the Agentic AI Foundation under the Linux Foundation, the open standard is adopted across more than 60,000 open-source repositories. It provides predictable guidance for runtimes like Codex, Jules, Gemini CLI, Aider, OpenCode, and Cursor.[1]

When agents arrive at a repository without this context, they waste tokens guessing package managers, assuming build commands, or running invalid test suites. Anchoring every agent to one root document stops that cycle immediately.[1]

Why CLAUDE.md is a 465-byte pointer instead of a symlink

Claude Code natively expects its repository instructions inside CLAUDE.md, whereas tools like Codex look for AGENTS.md by default. The standard Unix advice for this discrepancy is creating a filesystem symbolic link between the two filenames.[3][4]

That advice breaks immediately on Windows. In our local development environment on Windows, creating filesystem symlinks requires enabling Windows Developer Mode or running an elevated shell. Requiring administrative privileges just to check out a git repository and run an agent is unacceptable.

Instead of a symlink, OpenVibeEval uses a dedicated 465-byte CLAUDE.md file that is an explicit pointer. It contains instructions directing Claude Code to import and follow the root AGENTS.md document.

markdown
# Project Instructions

@AGENTS.md

# Operational Note

Keep this pointer file synchronized with AGENTS.md. Windows environments without Developer Mode cannot rely on filesystem symlinks.

Community analyses document that while recent Claude Code updates introduce fallback modes or import syntax, retaining this tiny file ensures backward compatibility. The pointer explicitly notes that if symlinks are unavailable, contributors must keep this reference stable rather than duplicating instructions.[3][4][6]

Maintaining duplicate copies of instruction files always leads to drift. An engineer updates the build flags in AGENTS.md during an outage, forgets CLAUDE.md, and suddenly Claude Code tests against stale commands. A 465-byte pointer eliminates drift while preserving cross-platform safety.[5]

Structuring operational commands and repo invariants

An effective AGENTS.md file must prioritize concrete execution instructions over high-level design philosophies. If an agent does not know the exact command to type-check changed files, it will either invent a broken command or skip verification entirely.[1][5]

In OpenVibeEval, the operational commands section provides direct copy-paste strings for every mandatory check. Agents are instructed on the exact package manager to use and the exact validation commands required before finalizing any pull request.

markdown
## Operational Commands

- Install dependencies: `npm install`
- Start dev server: `npm run dev`
- Build site: `npm run build`
- Run unit tests: `npm test`
- Lint code: `npm run lint`
- Type check: `npm run check`
- Ingest a run: `npm run ingest -- --file <path> --prompt <slug> --model <model> --harness <harness> --date YYYY-MM-DD`
- Score accessibility: `npm run a11y:score`
- Score performance: `npm run perf:score`
- Audit result data: `npm run audit:data`

Beyond commands, the file encodes structural invariants that protect data integrity. In OpenVibeEval, models and harnesses are strictly derived from the results data hierarchy. They must never be hardcoded into static configuration lists or enumeration types.

Similarly, the instructions prohibit autonomous agents from manually generating JSON files directly inside the results directory tree. All new benchmark runs must pass through the ingestion CLI script so DOM metrics, screenshot generation, and validation checks run deterministically.

Establishing boundaries on how data enters the repository prevents subtle regressions. Agents excel at writing code that appears correct in isolation, but they frequently bypass internal CLI tooling unless an instruction file explicitly forbids direct filesystem writes.[5]

Codifying runtime quirks that trip up autonomous agents

Coding agents do not operate in a standard interactive terminal. They execute inside synthetic harness environments with aggressive timeouts, background task limits, and idiosyncrasies that cause silent failures unless explicitly documented.[2]

Batched command execution causes immediate race conditions. Certain agent runtimes attempt to optimize execution speed by issuing multiple shell commands simultaneously. If those batched commands share dependencies, files are read before they are written.

To prevent this failure pattern, the instructions explicitly demand that dependent shell operations be combined into a single sequenced command string using standard operators.

bash
# Execute dependent tasks sequentially in a single invocation
npm run build && npm test

# Do not issue parallel batched tool calls for dependent steps

Foreground shells across multiple agent harnesses are hard-capped at approximately 30 seconds. When an agent kicks off a full ingestion or test suite in the foreground, the harness kills the process mid-stream.

The AGENTS.md file warns the model of this exact limit. Long-running tasks must be dispatched to background jobs and monitored with periodic polling loops rather than blocking the primary turn.

Windows PowerShell interacts poorly with Vitest stderr output. Vitest writes dynamic progress bars and informational messages directly to the standard error stream. PowerShell intercepts that stderr output and flags it as a NativeCommandError.

Without an explicit warning in AGENTS.md, an agent inspecting the shell return will flag an entirely passing test suite as a catastrophic build failure. Documenting that stderr output from Vitest is normal prevents agents from entering endless refactoring loops to solve imaginary bugs.

Three cards describing the runtime quirks encoded in AGENTS.md: parallel batched commands, the 30-second foreground shell cap, and Vitest stderr in PowerShell
The three runtime quirks the AGENTS.md file encodes — each one from a real incident.

Observed behavior across Claude Code, Codex, and ZCode

I have executed benchmark runs and maintenance operations on OpenVibeEval across Claude Code, Codex, Cline, OpenCode, ZCode, and other wrappers. My conclusions stem from practical operational observation of how these tools behave on real repository tasks, not token-level audits of internal context parsers.

In Codex, AGENTS.md at the root is parsed immediately before file modification tasks begin. OpenAI Codex CLI documentation highlights that the runtime is designed to seek out AGENTS.md to discover build targets and sandboxing rules.[2][4]

Claude Code relies on the CLAUDE.md pointer to ingest the same instructions. Once imported, it respects our constraints against writing directly into the raw results tree and adheres to the mandatory CLI ingestion path.

When using ZCode and OpenCode, the agents pick up the project conventions and test commands without requiring secondary prompt files. They execute verification suites using the prescribed package manager flags without hallucinating alternative scripts.

Other harnesses listed in community standards, such as Jules, Gemini CLI, Aider, and Windsurf, claim native support for AGENTS.md under the Agentic AI Foundation umbrella. I have not personally verified the complete parsing cascade in every listed tool, so maintainers should treat untested harnesses as targets for verification rather than assuming uniform execution.[1]

Drawing the line between AGENTS.md, skills, and MCP

A common mistake when standardizing agent workflows is attempting to force every operational concern into a single markdown document. AGENTS.md is an instruction file, not an execution engine or an external API gateway.[5]

AGENTS.md belongs to the repository. It stores repository invariants, file layout descriptions, build commands, test instructions, and runtime quirks that any agent must know before touching the code. It is static, declarative text.[1][5]

Skills are procedural tool definitions. In frameworks that support them, a skill provides dynamic scripts or reusable execution routines that an agent can call to perform parameterized actions. A skill executes logic; AGENTS.md merely tells the agent that the skill exists.[4]

Model Context Protocol servers operate at a different architectural layer altogether. An MCP server provides structured RPC interfaces to external systems like databases, issue trackers, or browser automation clusters. MCP supplies the protocol connection, whereas AGENTS.md specifies the repository rules for interacting with that connection.

I do not claim that AGENTS.md replaces these native configurations. If you blur these boundaries by pasting complex executable scripts directly into AGENTS.md, you bloat the context window while depriving your agents of real programmatic tool execution.

A practical checklist for unifying repository agent instructions

To establish a predictable multi-harness setup in your own repositories, follow this concrete implementation sequence:

Create an AGENTS.md file in the repository root. Document the exact commands for install, dev, build, test, lint, and type-check, specifying the intended package manager so agents avoid guessing.[1]

Add explicit environment quirks based on your harness tooling. Specify maximum foreground shell execution limits, sequence dependent commands into single strings, and clarify stderr behaviors that might be misinterpreted as test failures.

Define repository invariants and forbidden paths directly in the text. Explicitly forbid direct writes to generated data trees, mandate ingestion CLI usage, and forbid hardcoding dynamic entity lists into source files.

Create a lightweight CLAUDE.md pointer file at the root referencing AGENTS.md. Avoid relying on filesystem symlinks if contributors or CI agents run on Windows without Developer Mode enabled.[4]

Separate concerns cleanly across your tooling stack. Keep repository instructions in AGENTS.md, procedural actions in agent skills, and external data interfaces in Model Context Protocol servers.

coding-agentsagents-mdclaude-codecodexdeveloper-toolsopenvibeeval

Sources

  1. https://agents.md/
  2. https://github.com/openai/codex
  3. Does Claude Code read AGENTS.md? No — it reads CLAUDE.md. The official @AGENTS.md import and symlink methods that actually work (the 'reads it as a fallback' claim is wrong), plus five operator-side patterns for keeping the two files in sync. For the #6235 cluster (5,200+ reactions). · GitHub
  4. claude-code-commands-skills-agents/docs/claude-code-with-codex.md at main · shakacode/claude-code-commands-skills-agents · GitHub
  5. AGENTS.md vs CLAUDE.md: How to Give AI Coding Agents Better Instructions — Agrade Prestasi Insights | Agrade Prestasi
  6. Claude Code now supports AGENTS.md Natively - Here's how it actually works - DEV Community

Related articles

Press ? for keyboard shortcuts