In this article
A useful rule has a clear scope and activation path; diagnose discovery and attachment before assuming the model rejected an instruction it never received.
Cursor rules supply reusable instructions, but a rule must be discovered and applied before it can influence a task. Project rules, user preferences, team rules, and AGENTS.md have different scopes. Understanding attachment conditions explains why a carefully written instruction can appear to be ignored when the relevant file pattern, description, or task context never activated it.
Persistent guidance is still supplied as context
A rule is not a permanent modification of the underlying model’s weights. It is reusable guidance supplied when the rule applies. This explains why storage location and activation matter. A file sitting somewhere in a repository does not automatically become an instruction for every request. Keep stable project conventions in the supported rule mechanism and provide task-specific evidence separately so the instruction body does not become a constantly changing project transcript.
Primary reference: Cursor Docs: Agent Overview.
Project-rule metadata controls discovery
Current project rules use the supported rule-file format and metadata for descriptions, file patterns, and application behavior. A plain Markdown file in the structured rule directory is not automatically equivalent to a valid rule. Check the documented extension and fields when troubleshooting. For a rule targeting backend validation, verify that the referenced files actually match its scope. A perfectly worded instruction cannot help if the discovery mechanism never considers it applicable.
Primary reference: Cursor Docs: Search.
Nested instructions narrow project guidance
AGENTS.md offers plain Markdown guidance, including supported nested placement. More specific directory guidance can refine the parent instructions for files in that area. This helps a repository with different conventions across frontend and backend code. Keep the hierarchy understandable and avoid duplicating contradictory paragraphs at every level. A maintainer should be able to determine the intended rule set for a file without reading every historical agent conversation.
Primary reference: Cursor Docs: Rules.
Referenced evidence may be fetched later
A path mentioned in a rule can tell the agent where supporting material lives without inlining that material into every prompt. If a requirement must always be present, place the essential instruction in the rule itself. Keep lengthy examples in referenced files when appropriate. Distinguish the instruction to consult a source from proof that the source has already been read. This prevents a missing reference from masquerading as a model reasoning failure.
Test a rule against a concrete task
Use a small representative edit and inspect whether the expected guidance applied. Check scope, discovery conditions, and any conflicting higher-priority task instruction. Evaluate the resulting behavior, such as using the repository’s existing validation command, rather than asking whether the agent remembers the rule. Keep the rule concise enough to review. The useful outcome is a reproducible instruction path that helps actual work, not a growing collection of increasingly emphatic prose.
Related reading: Continue vs Cline vs Aider for local coding; Reproducible inference stacks: preserving a GPU pilot’s result.
Earn rental income from GPUs
Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.