How it works with Kodus
Kodus lets you define Kody Rules — custom instructions that are checked automatically during every code review. There are two types:- Review Rules run during code review and analyze file diffs or the entire PR against your standards
- Memories are persistent conventions that Kody applies across all interactions — code reviews, conversations, and suggestions
Example: Enforcing a naming convention
You can create a file-level rule like:- Rule name: “React components must use PascalCase file names”
- Path:
src/components/**/*.tsx - Severity: High
- Instructions: “Flag any component file that doesn’t follow PascalCase naming.”
Example: Enforcing architectural boundaries
A PR-level rule can validate cross-file concerns:- Rule name: “Domain layer must not import from infrastructure”
- Execution mode: Per PR
- Instructions: “Check
pr_files_difffor any import statement insrc/domain/that referencessrc/infrastructure/. This violates our hexagonal architecture.”
Other approaches
You can also enforce standards by:- Importing from the Rules Library — click Discovery on the Kody Rules page to browse pre-built rules for security, performance, and style
- Syncing IDE rules — automatically import rules from Cursor, Copilot, Claude, and other AI tools
- Repository rules — define rules in markdown files directly in your repo (
.kody/rules/) - Auto-generating rules — let Kody analyze 3 months of review history and suggest rules based on your team’s patterns
Getting started
- Pick Global (or a repository / directory) in the scope picker at the top of the Code review group in the sidebar, then open Kody Rules
- Click New rule and define your standard
- Set the path, severity, and detailed instructions
- Kody will enforce it on every future PR