Standardized Rules for AI-assisted Software Development and Coding Agents

Software development is changing rapidly, and AI coding agents (Codex, Claude Code, GitHub Copilot, Cursor, Windsurf, Sourcegraph, Augment Code, etc.) are at the forefront of this transformation. Each of these tools has its own approach to defining and managing rules that guide AI behavior. These rules are critical to the success of future software development because of the need to ensure that the AI is behaving in a way that is consistent with the developer's intent and in a secure way. This initiative explores the fragmented landscape of AI coding agent rules and proposes a unified standard to enable interoperability, quality, and security in AI-assisted software engineering.

The AI Coding Agent Rule Fragmentation Problem

The power of AI coding agents is undeniable, but their growth has led to a fractured ecosystem. Each major tool (e.g. Cursor, Codex, Claude Code, Augment Code, Sourcegraph, Windsurf, GitHub Copilot, etc.) uses its own proprietary system for defining the rules that guide AI behavior. This section provides an overview of each tool's approach, highlighting the challenges this fragmentation creates for developers and organizations aiming for consistent, high-quality, and secure code.

We need a vendor-agnostic standard designed to unify the definition, scoping, and application of rules for AI coding agent behavior. The proposed specification synthesizes existing best practices observed in leading tools and introduces a resilient framework to support the future evolution of AI-assisted development.

Examples of Current Rule System Implementations

Each major AI coding agent has developed its own approach to rule definition and management. The chart below provides a high-level visual comparison of key features across a few platforms (not a complete list), while the table offers a detailed breakdown of their current implementations. They are all great in most of the categories; however, this analysis reveals the fragmentation that motivates the need for a unified standard.

Feature Cursor Windsurf GitHub Copilot Augment Code
File Location .cursor/rules + User Rules global_rules.md + .windsurf/rules .github/copilot-instructions.md .augment/rules
Rule Types Always, Auto, Agent, Manual Always On, Model Decision, Glob, Manual Repository-wide with applyTo scoping Always, Auto, Manual
Scoping Mechanism Nested dirs + glob patterns Global vs Workspace + globs applyTo frontmatter Directory auto-import
File Format MDC with metadata Markdown (12K limit) Markdown .md or .mdx
Manual Activation @ruleName @mention Not supported @tag
AI-Driven Selection Yes (Agent Requested) Yes (Model Decision) No Yes (Auto)

Foundational Principles for a Standard

Based on the analysis of existing systems and software engineering best practices, a successful standard must be built on a set of core principles. These tenets ensure the standard is robust, future-proof, and serves the needs of the entire development community.

Declarative & Human-Readable

Define *what* to do using natural language for model-agnostic readability.

Modular & Composable

Build complex behaviors from small, reusable rule components.

Hierarchical & Overridable

Support layers of rules (user, project, org) with clear precedence.

Version-Controlled & Discoverable

Treat rules as code, storing them alongside the project in Git. This is the best distribution mechanism for rules.

Testable & Validatable

Ensure rules can be verified to prevent "AI drift" and errors.

Extensible & Tool-Agnostic

Accommodate future AI capabilities and prevent vendor lock-in. This is the best way to ensure that the rules are not tied to a specific tool.

The AI Coding Agent Rule Spec Proposal

The Open AI Coding Agent Rule standard is a unified framework for defining AI coding agent rules. It combines the precision of a structured format (YAML) with the expressiveness of natural language (Markdown). Explore the core components of the proposed specification below.

Rule Definition Language (RDL)

The spec proposes a hybrid format: YAML for machine-readable structure and metadata, with embedded Markdown for human-readable, natural language guidance. This balances precision for tools with the flexibility needed to convey nuanced intent to an LLM.

id: "unique-rule-id"
name: "Human-Readable Name"
description: "What this rule does."
guidance: |
  # Markdown instructions for the AI
  - Follow these steps...
  - Use this specific library...
Join this Initiative!

Help shape the future of AI coding agent rules.