braid docs

Rules

Rules are always-on coding standards. When installed, they’re loaded into every conversation your AI agent has — no manual invocation needed.

When to use rules

Use rules for standards that should always apply:

  • Code style and formatting conventions
  • Architecture patterns (“use MSW for mock data fetching”)
  • Safety constraints (“never modify .env files”)
  • Commit message formats
  • Testing requirements

How rules work

  1. You write a rule in braid with a title and content
  2. braid install writes it as a native file for each agent
  3. The agent reads the rule automatically at conversation start

Where rules are installed

Each agent stores rules differently. braid handles the format conversion:

AgentLocation
Claude Code.claude/rules/
Cursor.cursor/rules/
GitHub Copilot.github/copilot-instructions.md
Windsurf.windsurf/rules/
Cline.cline/rules/

Example

A rule titled “Conventional Commits” with this content:

Use conventional commits with a scope.

Format: type(scope): description

Types: feat, fix, refactor, chore, docs, test, perf, ci

Always include a Linear issue reference in the body.

Gets written to .cursor/rules/conventional-commits.mdc, .claude/rules/conventional-commits.md, etc.

Rules vs skills

RulesSkills
When activeAlwaysOn demand
Loaded byAgent automaticallyAgent when relevant
Best forStandards, constraintsHow-to guides, workflows