cursorrules

A set of rules for building software with AI agents, where people decide the requirements and design before the agent writes code.

In plain words
What is it for?
Use it to structure work from requirements and design through implementation and later improvement, including projects that use language models.
Why use it?
It prevents agents from rushing into implementation without enough direction or human feedback.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/altaidevorg/rules-for-ai/cursorrules
Clone the repo
git clone --depth 1 https://github.com/altaidevorg/rules-for-ai

Made for: Cursor.

Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 13,624 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.13624
Opus 5 $0.00000 $0.06812
Sonnet 5 $0.00000 $0.02725
Haiku 4.5 $0.00000 $0.01362

Measured yesterday against content hash f2b18dceffa3, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cursorrules scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

100% identical to cursorrules — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.cursorrules · 1,664 lines

How it starts

The opening of the file, as written. The whole thing — 1,664 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agentic Coding: Humans Design, Agents code!

If you are an AI agents involved in building LLM Systems, read this guide VERY, VERY carefully! This is the most important chapter in the entire document. Throughout development, you should always (1) start with a small and simple solution, (2) design at a high level (docs/design.md) before implementation, and (3) frequently ask humans for feedback and clarification. {: .warning }

Agentic Coding Steps

Agentic Coding should be a collaboration between Human System Design and Agent Implementation:

Steps Human AI Comment
1. Requirements ★★★ High ★☆☆ Low Humans understand the requirements and context.
2. Flow ★★☆ Medium ★★☆ Medium Humans specify the high-level design, and the AI fills in the details.
3. Utilities ★★☆ Medium ★★☆ Medium Humans provide available external APIs and integrations, and the AI helps with implementation.
4. Node ★☆☆ Low ★★★ High The AI helps design the node types and data handling based on the flow.
5. Implementation ★☆☆ Low ★★★ High The AI implements the flow based on the design.
6. Optimization ★★☆ Medium ★★☆ Medium Humans evaluate the results, and the AI helps optimize.
7. Reliability ★☆☆ Low ★★★ High The AI writes test cases and addresses corner cases.
  1. Requirements: Clarify the requirements for your project, and evaluate whether an AI system is a good fit.
    • Understand AI systems' strengths and limitations:
      • Good for: Routine tasks requiring common sense (filling forms, replying to emails)
      • Good for: Creative tasks with well-defined inputs (building slides, writing SQL)
      • Not good for: Ambiguous problems requiring complex decision-making (business strategy, startup planning)
    • Keep It User-Centric: Explain the "problem" from the user's perspective rather than just listing features.
    • Balance complexity vs. impact: Aim to deliver the highest value features with minimal complexity early.

Read the full file on GitHub · 1,664 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 1,664 lines · 0 tokens per session scan A f2b18dceffa3

Subscribe to this mod's changes

cursorrules is a cursor rule published in the GitHub repository altaidevorg/rules-for-ai (2 stars, last pushed 1y ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 13,624 tokens. A static security scan graded it A with 0 findings. It is 100% identical to cursorrules, differing in 0 lines, and is treated as a copy.