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.
npx agentmods add rules/tomasz-tomczyk/crit/gogit clone --depth 1 https://github.com/tomasz-tomczyk/critWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00389 |
| Opus 5 | $0.00000 | $0.00195 |
| Sonnet 5 | $0.00000 | $0.00078 |
| Haiku 4.5 | $0.00000 | $0.00039 |
Grade A, and why
go 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 2d ago.
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.
What it actually says
Go Code Rules (semantic — linters handle syntax/style)
Struct & State Integrity
- When building structs for serialization or cross-boundary transfer, verify ALL source fields are mapped. Missing fields cause silent data loss.
- For boolean config fields, always use presence tracking to distinguish "not set" from "set to false". Go's zero-value for bool is
false, which is ambiguous. - When clearing/resetting state from a struct, enumerate ALL fields. Review comments, file comments, and metadata must all be cleared.
- When storing error values in shared state (atomic.Value, channels), copy the value first:
e := err; store(&e).
Code Organization
- This is
package main. Do NOT export functions/types unless required by tests in_test.gofiles. - Never create wrapper functions that just call another function with the same signature.
- Route all review file writes through
saveCritJSON(). Never write directly. - Before implementing logic inline, search for existing helper functions that do the same thing.
- After replacing a function with a new implementation, delete the old function AND its tests in the same PR.
Git Operations
- When determining file status, always diff against baseRef consistently. Don't mix
git status --porcelain(working tree) withgit diff --name-status(branch diff).
Daemon/Server
- When checking if a service is alive, validate the response body, not just HTTP status.
- Error paths in CLI subcommands must exit with non-zero status (
os.Exit(1)).
Testing
- Use table-driven tests instead of separate test functions for parameter variations.
- When adding a new API endpoint, add tests for: happy path, error cases, not-found, method-not-allowed.
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.
- 2d ago First seen · 32 lines · 0 tokens per session scan A 3cce88882bdf
go is a cursor rule published in the GitHub repository tomasz-tomczyk/crit (979 stars, last pushed 3d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 389 tokens. 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-30.
Other cursor rules, from other repositories
cursorrules
Este repo usa Knowledge-Driven Development (KDD). Las reglas completas para cualquier agente de IA (incluido Cursor) estan en .agents/AGENTS.md — leelo antes de escribir codigo.
java-springboot-jpa-cursorrules-prompt-file
description: "Cursor rules for Java development with Springboot and JPA integration." globs: / alwaysApply: false.
002-verify-before-act
Requires Claude to read before writing, verify before installing, and confirm before destructive operations.
swift-development
Swift development: SwiftUI, Combine, async/await, iOS patterns, and Apple platform conventions.
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.
dev-standard
Apache Superset development standards and guidelines for Cursor IDE.