Borrowing it
Nothing to install: this file belongs to TheArchitectit/agent-guardrails-template. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/TheArchitectit/agent-guardrails-template/main/.windsurfrulesgit clone --depth 1 https://github.com/TheArchitectit/agent-guardrails-templateWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/thearchitectit/agent-guardrails-template/windsurfrules)<a href="https://agentmods.dev/rules/thearchitectit/agent-guardrails-template/windsurfrules"><img src="https://agentmods.dev/badge/rules/thearchitectit/agent-guardrails-template/windsurfrules/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/thearchitectit/agent-guardrails-template/windsurfrules"><img src="https://agentmods.dev/badge/rules/thearchitectit/agent-guardrails-template/windsurfrules.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00935 | $0.00935 |
| Opus 5.5 | $0.00374 | $0.00374 |
| Sonnet 5.5 | $0.00187 | $0.00187 |
| Haiku 4.5 | $0.00093 | $0.00093 |
Grade A, and why
windsurfrules 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.
WINDSURF GUARDRAILS
These rules apply to ALL code generation, edits, and suggestions in this project.
The Four Laws of Agent Safety
- Read Before Editing - Never modify code without reading it first. Always use the Read tool before any edit.
- Stay in Scope - Only touch files explicitly authorized. No "while I'm here" fixes.
- Verify Before Committing - Test and check all changes. Run relevant tests.
- Halt When Uncertain - Ask for clarification instead of guessing.
Pre-Operation Checklist (MANDATORY)
Before ANY file modification:
- Read target file(s) completely
- Verify operation is within authorized scope
- Identify the rollback procedure
- Check for test/production separation requirements
Forbidden Actions (NEVER DO)
- Modifying code without reading it first
- Mixing test and production environments
- Force pushing to main/master
- Committing secrets, credentials, or .env files
- Running untested code in production
- Modifying unread code
- Working outside authorized scope
Halt Conditions (STOP and Ask User)
- Attempting to modify code you haven't read
- No rollback procedure exists or is unclear
- Production impact is uncertain
- User authorization is ambiguous
- Test and production environments may mix
- Uncertain about ANY aspect of the task
- Operation has failed 3 times
Three Strikes Rule
- Strike 1: Retry with adjusted approach
- Strike 2: Try alternative approach
- Strike 3: HALT and escalate to user
Never continue beyond 3 failures. Continuing wastes tokens, contaminates context, and rarely succeeds.
Production-First Rule
Production code MUST be created before test code or infrastructure code.
Order:
- Production implementation
- Production validation (lint, type check, compile)
- Tests for the production code
- Infrastructure/deployment config
Scope Rules
Only touch files within the authorized scope:
- Explicit file list from user (highest authority)
- Files identified in the task description
- Direct dependencies of target files (with approval)
- When uncertain: HALT and ask user
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.
- 1mo ago First seen · 127 lines · 935 tokens per session scan A c0c7842073cc
windsurfrules is a cursor rule published in the GitHub repository TheArchitectit/agent-guardrails-template (1 stars, last pushed 2d ago), licensed BSD-3-Clause. It adds 935 tokens to every session, about $0.0037 per session on Opus 5.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-09-08.
Other cursor rules, from other repositories
50-pr-and-git
Use when committing, opening or updating a pull request, writing a PR description, or preparing a release.
00-core-principles
Core working principles for Jeff Otterson's portfolio repos — receipts, honest benchmarks, fail-closed, no employer data.
git_workflow
Git Workflow and Configuration for AGB SDK.
git-workflow
Apply when user is creating Git commits, writing commit messages, managing branches (feature/fix/refactor), creating merge requests, or asking about Git workflow and branching strategy.
ai-coding
A set of rules for AI-assisted coding, including Chinese-language communication and comments, commit-message formatting, small changes, and human review of sensitive code.
roslyn-mcp-version-bump
Auto-bump Version after successful MCP self-build and reload.