Spots

I Stopped Writing Separate Instructions for Claude Code, Codex, and Cursor -…

AGENTS.md vs CLAUDE.md vs Cursor Rules vs Skills vs MCP: What Actually Belongs Where? AGENTS.md vs CLAUDE.md vs Cursor Rules vs Skills vs MCP: What Actually Belongs Where? I use multiple AI coding agents in my development workflow. Claude Code for some tasks. Codex for others. Cursor when I want to work directly inside the editor. At first, my approach was simple: Give each AI tool enough instructions to understand the project. That worked. Until it didn't. My repositories gradually started accumulating instructions everywhere: Many of these files contained overlapping information.

I was mixing project conventions, architecture decisions, feature

I was mixing project conventions, architecture decisions, feature requirements, and agent workflows into the same documents. Whenever I updated a rule, I had to remember where else I'd duplicated it. The problem wasn't necessarily that my agents needed more context. The problem was how I organized that context. So I started separating shared repository knowledge from tool-specific instructions and task-specific requirements.

This article explains the structure, why I use

This article explains the structure, why I use it, and how to avoid a subtle configuration problem when sharing instructions between Claude Code, Codex, and Cursor.

Important: This is my approach to organizing AI

Important: This is my approach to organizing AI development workflows, not a universal standard. Each coding agent has its own instruction discovery and configuration behavior. Always check your tool's current documentation.

Important: This is my approach to organizing AI

Important: This is my approach to organizing AI development workflows, not a universal standard. Each coding agent has its own instruction discovery and configuration behavior. Always check your tool's current documentation. 1. The Problem: Every AI Agent Needs Context Imagine you're developing a production application using: Authentication and permissions Established architectural conventions You ask your coding agent: That sounds straightforward. But the agent needs answers to several questions.

Does the application already have a reusable filter

Does the application already have a reusable filter component? Are filters stored in URL parameters? Does the backend already support filtering? Where should data fetching happen? More importantly, which existing patterns should the agent preserve?

Without sufficient context, an agent might introduce a

Without sufficient context, an agent might introduce a second filtering system instead of extending the existing implementation.

That's where AI-generated code becomes expensive: not necessarily

That's where AI-generated code becomes expensive: not necessarily because the generated code is incorrect, but because it doesn't fit the existing system. 2. My First Mistake: The Giant Instruction File Initially, I tried solving this by putting almost everything into one instruction file. Eventually, the file became difficult to maintain.

The problem was that permanent instructions, temporary requirements

The problem was that permanent instructions, temporary requirements, and reference documentation were all competing for the same space. A small UI change didn't need deployment documentation. A backend bug didn't need animation guidelines. And a feature requirement shouldn't permanently live alongside repository-wide coding conventions. More context is not automatically better context. I needed a way to organize information according to its purpose. 3. The Mental Model I Use Now Instead of treating context as one giant document, I separate it into distinct responsibilities. Each layer answers a different question.

For example, repository instructions explain how an agent

For example, repository instructions explain how an agent should work, while feature intent explains what a particular change should accomplish. This distinction makes it easier to maintain context without repeating everything in every prompt. A note about compatibility

News

I Stopped Writing Separate Instructions for Claude Code, Codex, and Cursor - Here's My 2026 Setup

AGENTS.md vs CLAUDE.md vs Cursor Rules vs Skills vs MCP: What Actually Belongs Where?

@spots #dev
Source: Dev.to
See more like this