In 1 in 6 repos with both files, Claude Code never loads the AGENTS.md
Harbor analyzed 3,905 GitHub repositories, finding 16 percent of paired rule files fail to link AGENTS.md to Claude Code, causing silent context omissions.
By Dillip Chowdary • Nov 14, 2026 • Source: gethrbr.com
In this post
Harbor released an analysis of 3,905 rule files collected from public GitHub repositories on October 18, 2026, revealing widespread context delivery failures between AI coding agents. According to gethrbr.com's report, 16 percent of repositories that maintain both CLAUDE.md and AGENTS.md at their project root never link the two files, causing Claude Code to omit the AGENTS.md document entirely during execution.
This report evaluates how developer instructions reach command-line agents, focusing on configuration drift, file-size ceilings, and syntax handling across thousands of active software projects. Engineering teams using multi-agent workflows with Claude Code and Codex will find specific data on rule-loading behaviors, parser mechanics, and context-window ingestion thresholds.
01Root file linkage across paired repositories
GitHub code search tracked 839,680 CLAUDE.md files and 1,142,784 AGENTS.md files in public repositories excluding forks. Harbor evaluated 745 root pairs where both configurations coexisted, discovering that 36 percent of all root AGENTS.md files sat alongside a companion CLAUDE.md. Anthropic memory architecture specifies that when any CLAUDE.md exists in current or parent directories, Claude Code loads those files exclusively.
Among paired repositories, only 25 percent successfully import AGENTS.md using an explicit include syntax, while 23 percent connect the files via symbolic links. A separate 7 percent copy lines directly between files, and another 7 percent exhibit configuration drift where initial copies parted ways over time. The remaining 16 percent omit any reference, leaving Claude Code running without the broader repository guidelines.
Informal instructional prompts also routinely fail to pull instructions into context. About 15 percent of paired configurations rely on prose sentences asking the model to review the companion document before starting work. Because Claude Code treats these lines as plain text rather than programmatic imports, the agent inspects the file only if it independently chooses to execute a file-read tool call.
02Context delivery limits and configuration drift
Rule files frequently diverge or exceed the ingestion ceilings defined by agent runtimes. The median CLAUDE.md spans 81 lines, but 19 percent exceed Anthropic's 200-line guideline and 4 percent exceed 500 lines, degrading model adherence. Across GitHub, 30,080 AGENTS.md files exceed 32 KiB, passing the default cutoff where Codex quietly truncates document context.
| Metric | Previous or baseline pattern | Observed Harbor study outcome |
|---|---|---|
| Root pair linkage | Expected shared rules across tools | 16% unlinked, 15% conditional text prompts |
| Configuration drift | Identical duplicated instructions | 7% drifted by five or more missing lines |
| CLAUDE.md length | Anthropic 200-line target (81 median) | 19% exceed 200 lines, 4% exceed 500 lines |
| Codex file size | 32 KiB default project_doc_max_bytes | 2.6% over 32 KiB (30,080 files truncated) |
| Runtime speedup | Standard unguided agent execution | 28.64% lower runtime with AGENTS.md (Lulla et al.) |
Academic benchmarks underline the performance stakes of reliable rule ingestion. Prior evaluations across 124 pull requests documented that providing valid AGENTS.md context lowered median agent runtime by 28.64 percent and decreased generation volume by 16.58 percent. When files drift or drop out of context, agents lose these execution advantages and run on conflicting rules.
03Rule ingestion hygiene for multi-agent repositories

Consolidating project rules into a single source eliminates silent tool-specific behavior splits. When a single directive updates inside an unlinked or drifted pair, developers end up running Codex and Claude Code against divergent operational constraints. Standardizing the primary instructions inside AGENTS.md ensures all downstream tools inherit the exact same baseline parameters.
Pruning unnecessary structural context preserves valuable token space for model reasoning. The study found directory trees inside 17 percent of CLAUDE.md and 11 percent of AGENTS.md files, despite research showing repository file maps provide no measurable retrieval benefit. Furthermore, 6 percent of CLAUDE.md files contain HTML block comments, which Claude Code strips before delivery, discarding any instructions nested inside them.
Avoiding silent truncation guarantees that all compliance, testing, and deployment rules remain active. Codex reads AGENTS.md files sequentially from the root downward and abruptly stops ingesting content once hitting the 32 KiB limit without outputting terminal alerts. Keeping combined instruction files under 24 KiB prevents nested project files from pushing total documentation past runtime ingestion boundaries.
Advertisement
Tech Pulse Daily
Get tomorrow's pulse first
Join engineers who read Tech Pulse before stand-up. Free, weekday mornings.
04Implementing active imports and runtime controls
Connecting CLAUDE.md directly to AGENTS.md requires adding an import directive on the first line of the file. Developers should place the single import statement at the beginning of CLAUDE.md and position Claude-specific adjustments below it.
@AGENTS.mdMaintaining the CLI client guarantees support for current context ingestion flags and configuration standards. Update the CLI tooling directly using the package manager.
npm install -g @anthropic-ai/claude-codeSwitch active models inside the interactive interface or adjust launch parameters from the terminal prompt. Select specific model tiers dynamically during an ongoing session.
/model claude-fable-5-1Launch the CLI directly with a pinned model configuration to bypass session selection menus.
claude --model fableCodex users managing extensive instruction suites must adjust configuration files when documentation cannot remain below default thresholds. Expand the project context ceiling directly within the configuration file to prevent silent truncation.
# ~/.codex/config.toml
project_doc_max_bytes = 6553605Monitoring context ceilings and symbolic link parsing
Teams deploying cross-platform environments must monitor how version control handles file references. While symbolic links resolve successfully across POSIX systems, Windows checkouts without core.symlinks enabled convert symlinks into single-line plain text strings. This checkout failure drops the referenced instructions and leaves the agent running without primary rules.
Developers must track file growth against the 200-line adherence threshold and the 24 KiB nested boundary. Because GitHub indexes 51,840 AGENTS.md files larger than 24 KiB, minor additions from subdirectories risk pushing total repository instructions beyond runtime limits. Auditing context size ensures instructions reach the model complete and untruncated.
Instruction parsers continue to evolve across CLI tools, requiring engineering teams to separate human maintainer notes from machine prompts. Omitting block-level HTML comments prevents silent rule omission, while replacing prose file requests with formal import statements guarantees immediate context loading. Systematic rule-file auditing ensures agents receive identical instructions across every session.
In 1 in 6 repos with both files FAQ
Does Claude Code read AGENTS.md automatically when both files exist?
No, Anthropic documentation specifies that Claude Code only loads CLAUDE.md files when present in the current or parent directory. To load AGENTS.md, developers must add an explicit @AGENTS.md import line or configure a symbolic link.
Why do instructions in HTML comments fail to work in CLAUDE.md?
Claude Code automatically strips block-level HTML comments before passing the document content into the model context window. Any developer instructions placed inside HTML comment tags are silently discarded before the agent can read them.
What happens when an AGENTS.md file exceeds 32 KiB in Codex?
Codex enforces a default project_doc_max_bytes limit of 32 KiB, halting file ingestion once reaching that size threshold without printing terminal warnings. Any instructions positioned beyond the first 32 KiB are completely omitted from the model.
How can engineering teams prevent configuration drift between Claude Code and Codex?
Teams should maintain project rules inside a single AGENTS.md file and include @AGENTS.md at the top of CLAUDE.md, avoiding separate duplicated files or prose instructions asking agents to read other documents.
Sources
Author
Dillip Chowdary
Writes Tech Bytes coverage of AI, engineering, and the tools that actually ship. Editor of Tech Pulse Daily.
Related on Tech Bytes
Advertisement