Comparison
Pathrule vs CLAUDE.md, AGENTS.md and .cursorrules
Claude Code, Codex, Cursor and Copilot all carry knowledge forward in different ways. The useful comparison is where knowledge is shared, how it is selected for a task, and whether a requirement can be checked or blocked.
What these agents already do
Claude Code has path-scoped rules and local auto memory. It also supports AGENTS.md directly from version 2.1.277, but its default loader uses AGENTS.md only when no CLAUDE.md or CLAUDE.local.md is found in the current directory or an ancestor. Codex combines nested AGENTS.md instructions with opt-in local memories generated from eligible chats.
Cursor has scoped rules, user memories and Projects that share context across Cursor agents. GitHub Copilot has path-specific instructions and a memory preview: repository facts can be shared with users who have access, while user preferences stay private. These are meaningful capabilities, so Pathrule's difference cannot be that other agents do not remember.
The remaining questions are whether the same knowledge reaches different vendors' agents, whether the task receives the relevant slice, and what happens when a rule must hold or a result must be measured.
Where Pathrule adds value
A shared source across agent vendors. Codex local memories, Claude Code auto memory and Cursor user memories are useful within their own products. Cursor Projects and Copilot repository memories also share context within their ecosystems. Pathrule holds workspace knowledge once and delivers it to the agents Studio runs and supported MCP clients, so a teammate changing agents does not need a second copy.
Task selection with explicit requirements. Pathrule attaches knowledge to workspace paths, selects the slice relevant to the request, and compiles typed structure so a requirement keeps its rank above advice. Path-scoped files and rules in other products solve part of this problem; the difference is one shared selection and priority model across supported agents.
Enforcement and measured outcomes. Claude Code, Codex and Cursor expose blocking hooks. Pathrule connects strict rules and required checks to runtime guardrails on supported surfaces, while context-only integrations remain advisory. Its published compliance grid reports functional success, convention compliance and violations separately, including neutral cases.
A measured example, with its boundary
The published compliance grid includes tasks where an environment value must pass through a gateway, an empty request body must be guarded before parsing, and a database is a read-only replica. Those decisions were deliberately absent from the source files, so the agent could make a working change while violating a workspace convention.
Across 12 tasks and 24 runs with one pinned Claude Code model, both conditions finished all 12 tasks functionally. Compliance was 3/12 without Pathrule and 12/12 with it; convention violations were eight versus zero. Three tasks were neutral because the needed fact was already recoverable from the repository. This measures Pathrule's delivery in that setup. It does not compare Codex memories, Cursor Projects or Copilot Memory.
Side by side
| Pathrule | Claude Code | Codex | Cursor | Copilot | |
|---|---|---|---|---|---|
| Path scoping | Knowledge attached to paths, selected per task | `.claude/rules/` with `paths:` globs | Nested AGENTS.md, root down to your directory | Rules with globs | Path-specific instructions with applyTo globs |
| Learns without you writing | Workspace and user, with the evidence behind each | Auto memory, on by default | Opt-in local memories from eligible chats | Memories, learned from your behaviour | Copilot Memory preview |
| Who that learning belongs to | The workspace, and you across workspaces | This repository, on this machine | Local to the Codex installation | You, and your teammates never see it | Repository facts shared; user preferences private |
| Shared with the team | Workspace sync, no commit needed | CLAUDE.md by commit; auto memory not at all | AGENTS.md by commit; local memories stay local | Rules by commit or team setting; Projects share context inside Cursor | Instructions by commit; repository memories shared with access |
| What the agent receives | Compiled typed knowledge, requirements ranked above advice | Markdown text | Markdown text | Markdown text | Instruction text and cited memories |
| Enforcement | Constraints and checks held by the runtime, from the same knowledge | Hooks, written separately by you | Hooks can block supported actions | Hooks, written separately by you | Hooks depend on Copilot surface |
| Documented size limits | Selected per task rather than loaded whole | Auto memory index first 200 lines or 25KB; under 200 lines advised per CLAUDE.md | Stops adding files at 32 KiB combined | Guidance to keep a rule file under 500 lines | No single cross-surface limit documented here |
| Reaches other agents | One source, every engine Studio runs plus MCP clients | AGENTS.md under documented loader conditions | AGENTS.md-aware tools | Cursor ecosystem, including Projects | Copilot ecosystem |
Pathrule can coexist with these files. AGENTS.md vs Pathrule explains when each fits. Sources and review scope appear below.
When each one makes sense
The files alone. Genuinely the right answer for one developer on one agent. They are zero setup, they are free, they are committed and reviewable, and with globs and auto memory they now cover much more than they used to. Start here.
The files, plus discipline. A second vendor is where duplication can appear. Claude Code, Codex and Cursor each have ways to retain context, and some share it within their own product. Check whether your actual combination reads the same file and applies the same precedence before maintaining several copies.
Pathrule. Useful when a workspace spans agent vendors, when task-specific selection matters, or when requirements need enforcement and measured outcomes. One source, compiled per task. See the architecture and how we measure.
Other agents checked
Windsurf Cascade documents local workspace memories plus shareable rules and AGENTS.md. Its current Devin Desktop documentation distinguishes the legacy Cascade agent from the default Devin Local agent, which does not persist those memories. OpenCode V2 and Kimi Code document AGENTS.md instructions. Google Antigravity documents AGENTS.md and rules with activation modes, plus a /learn command that can turn feedback into persistent rules or skills. None should be described simply as having no memory or no scoped instructions.
These are documentation findings, not a cross-product runtime test. Installed CLI versions inspected here were OpenCode 1.18.34, Kimi 2.1.1 and Antigravity CLI 1.2.14; Windsurf, Cursor and Copilot were not locally tested. The sources below show each product's published behavior.
Sources and verification
Official documentation checked 1 October 2026. Installed versions inspected: Claude Code 2.1.287, Codex CLI 0.145.0, OpenCode 1.18.34, Kimi 2.1.1 and Antigravity CLI 1.2.14. Codex memories were disabled locally; memory generation and cross-agent behavior were not runtime-tested. Cursor, Copilot and Windsurf were documentation-reviewed only. Pathrule source reviewed at Studio 0.23.1 plus unreleased working-tree changes.
- Claude Code: how Claude remembers your project
Official source for CLAUDE.md loading and scope, for path-scoped rules in .claude/rules/ with paths: globs, and for auto memory: its four note types, the 200 line or 25KB index limit, and that it is per repository and machine local.
- Codex: custom instructions with AGENTS.md
Official discovery order and precedence: global scope, then project root down to the working directory, one file per directory, concatenated, stopping at 32 KiB combined.
- Codex: local memories
Official opt-in local memory behavior, storage, generation and controls.
- Cursor: rules
Official rule locations, application modes, globs and team rules.
- Cursor: memories
Official behaviour for memories Cursor extracts from your work, and how they differ from rules.
- Cursor: Projects
Official shared project context across Cursor agents and machines.
- GitHub Copilot: repository custom instructions
Official behaviour for copilot-instructions.md and for path-specific *.instructions.md files with an applyTo glob.
- GitHub Copilot: memory
Official repository and user memory behavior, sharing and availability.
- Windsurf Cascade: memories and rules
Official local Cascade memories, shareable rules and AGENTS.md behavior, with the Devin Local distinction.
- OpenCode V2: instructions
Official AGENTS.md discovery and V2 instruction behavior.
- Kimi Code: AGENTS.md
Official global and project agent instruction behavior.
- Google Antigravity: rules
Official rules, AGENTS.md support and activation modes.
- Google Antigravity: slash commands
Official /learn workflow for persistent rules and skills.
Frequently asked questions
Claude Code has auto memory now. Does that replace Pathrule?
Claude Code auto memory is useful within Claude Code. Pathrule is useful when the same workspace decision must reach Codex or another agent, be selected for a task, or be enforced through a supported hook. Claude Code also supports AGENTS.md under documented loading conditions.
Is Pathrule a replacement for CLAUDE.md?
No. Keep a short CLAUDE.md or AGENTS.md for repository-wide constants. Pathrule carries workspace knowledge that must reach teammates and supported agents from one source, with task selection and rule enforcement where available.
Do these files still have a scoping problem?
Less of one than they used to, and this page does not claim otherwise. Claude Code takes paths: globs on rules, Codex nests AGENTS.md per directory, and Cursor scopes rules by glob. What remains is that each documented limit is a size cap (a 32 KiB concatenation in Codex, a 200 line or 25KB memory index in Claude Code) rather than a relevance decision.
How does Pathrule compare to AGENTS.md?
Codex reads global and nested AGENTS.md instructions up to a documented 32 KiB combined limit. Other agents also support AGENTS.md, with different loading rules. Pathrule stores shared workspace knowledge, compiles it into typed structure, and selects the relevant part for each supported agent and task.
Do I have to migrate off my existing files?
No. Pathrule layers on top. Many teams keep a short CLAUDE.md or AGENTS.md and move the path-specific, team-shared rules into Pathrule so each session only loads what applies.
Does the comparison mean files are bad?
No, and they are better than they were. A file is the right starting point for one developer on one agent. The trade-off appears at team scale, across several agents, and anywhere a rule needs to hold rather than be read.
Does Pathrule store my source code?
No. Pathrule never reads or uploads source files. It stores only the knowledge your team writes and the evidence from real work. See the Security page.