cursorrules

A set of Cursor editor rules for applying the CLARE framework to coding work. Cursor is a code editor with an integrated AI agent.

In plain words
What is it for?
It helps Cursor check allowed file paths, stop for human-only areas, run CI verification after edits, and keep agent instructions aligned across tools.
Why use it?
It makes verification, autonomy limits, and synchronized instructions explicit across several coding-agent environments.

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/jketreno/clare/cursorrules
Clone the repo
git clone --depth 1 https://github.com/jketreno/clare

Made for: Cursor.

Per session 513 This file is loaded in full into every session.
When invoked 513 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found 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.00513 $0.00513
Opus 5 $0.00257 $0.00257
Sonnet 5 $0.00103 $0.00103
Haiku 4.5 $0.00051 $0.00051

Measured yesterday against content hash 2d13d8293ff2, 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.

.cursorrules · 45 lines

What it actually says

CLARE Framework Rules

This project uses the CLARE framework. Detailed rules are in .cursor/rules/.

Core Rule

After editing a file, run ./clare/verify-ci.sh before marking work complete. Run it only in a turn where you edited a file — not in plan-mode, research, or read-only turns. See .cursor/rules/clare-workflow.mdc for the full procedure.

Cross-Agent Sync Rule

When CLARE agent configuration changes, update all supported agent environments in the same change:

  • Copilot: .github/copilot-instructions.md and install/.github/copilot-instructions.md
  • Claude: CLAUDE.md and install/root/CLAUDE.md
  • Codex: AGENTS.md and install/root/AGENTS.md
  • Cursor: .cursorrules and install/root/.cursorrules
  • Roo/Zoo Code: .roo/rules/clare.md and install/.roo/rules/clare.md

Before Any File Change

Check clare/autonomy.yml for the file path:

  • full-autonomy → proceed
  • supervised → generate + add "⚠ Human review required"
  • humans-only → STOP, notify user, do not generate code

Five Principles

  • [C] Constrained: rules exist in tests/linters, not comments
  • [L] Limited: autonomy.yml defines where AI can work alone
  • [A] Assertive: tests enforce invariants, not implementations
  • [R] Reality-Aligned: one source of truth per domain concept
  • [E] Ephemeral: regenerate generated code, never patch it

CLARE₂ Commands

When the CLARE₂ pipeline container is running:

  • /project:clare2-capture start — begin session JSONL capture
  • /project:distill — trigger on-demand distillation pass

Full Rules

See .cursor/rules/ for detailed MDC rule files. See clare/principles.md for the principle reference card. See CLAUDE.md for the complete workflow specification.

CLARE₂ Temper Routing

Use clare_temper_route(project, task_kind, capabilities) for an opaque route ID and send X-CLARE-Route-ID to the policy proxy. Never select/load adapters, provide adapter paths, call raw vLLM management endpoints, or access Docker.

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 · 45 lines · 513 tokens per session scan A 2d13d8293ff2

Subscribe to this mod's changes

cursorrules is a cursor rule published in the GitHub repository jketreno/clare (5 stars, last pushed 1mo ago), licensed MIT. It adds 513 tokens to every session, about $0.0026 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.