|
| 1 | +# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json |
| 2 | + |
| 3 | +# ============================================================================= |
| 4 | +# General |
| 5 | +# ============================================================================= |
| 6 | +language: en-US # default |
| 7 | +tone_instructions: >- |
| 8 | + Prefer concise responses (high information density, low fluff). |
| 9 | + This is a Kubernetes-native AI automation platform built with Go, NextJS, and Python. |
| 10 | +early_access: false # default |
| 11 | +enable_free_tier: false |
| 12 | + |
| 13 | +# ============================================================================= |
| 14 | +# Reviews |
| 15 | +# ============================================================================= |
| 16 | +reviews: |
| 17 | + profile: chill # default |
| 18 | + request_changes_workflow: false # default |
| 19 | + high_level_summary: true # default |
| 20 | + high_level_summary_instructions: "" # default |
| 21 | + high_level_summary_placeholder: "@coderabbitai summary" # default |
| 22 | + high_level_summary_in_walkthrough: false # default |
| 23 | + auto_title_placeholder: "@coderabbitai" # default |
| 24 | + auto_title_instructions: "" # default |
| 25 | + review_status: true # default |
| 26 | + review_details: false # default |
| 27 | + commit_status: false |
| 28 | + fail_commit_status: false # default |
| 29 | + collapse_walkthrough: true # default |
| 30 | + changed_files_summary: true # default |
| 31 | + sequence_diagrams: true # default |
| 32 | + estimate_code_review_effort: false |
| 33 | + assess_linked_issues: true # default |
| 34 | + related_issues: true # default |
| 35 | + related_prs: true # default |
| 36 | + suggested_labels: true # default |
| 37 | + labeling_instructions: [] # default |
| 38 | + auto_apply_labels: false # default |
| 39 | + suggested_reviewers: false |
| 40 | + auto_assign_reviewers: false # default |
| 41 | + in_progress_fortune: false |
| 42 | + poem: false |
| 43 | + enable_prompt_for_ai_agents: true # default |
| 44 | + abort_on_close: true # default |
| 45 | + disable_cache: false # default |
| 46 | + |
| 47 | + slop_detection: |
| 48 | + enabled: true # default |
| 49 | + |
| 50 | + # --------------------------------------------------------------------------- |
| 51 | + # Path filters |
| 52 | + # --------------------------------------------------------------------------- |
| 53 | + path_filters: |
| 54 | + - "!**/vendor/**" |
| 55 | + - "!**/zz_generated*" |
| 56 | + - "!**/pkg/api/openapi/**" |
| 57 | + - "!**/*.pb.go" |
| 58 | + - "!**/node_modules/**" |
| 59 | + - "!**/.next/**" |
| 60 | + - "!**/go.sum" |
| 61 | + - "!**/package-lock.json" |
| 62 | + |
| 63 | + # --------------------------------------------------------------------------- |
| 64 | + # Path instructions |
| 65 | + # --------------------------------------------------------------------------- |
| 66 | + path_instructions: |
| 67 | + - path: "**/*" |
| 68 | + instructions: | |
| 69 | + - Flag only errors, security risks, or functionality-breaking problems. |
| 70 | + - Limit to 3-5 comments max; group similar issues; mention repeated patterns once. |
| 71 | + - No style, formatting, or refactoring suggestions. If nothing is broken, approve briefly. |
| 72 | +
|
| 73 | + - path: "components/{backend,operator}/**/*.go" |
| 74 | + instructions: | |
| 75 | + - User-facing API ops MUST use GetK8sClientsForRequest(c), never the backend service account. |
| 76 | + - No panic() -- return fmt.Errorf with context. |
| 77 | + - Reconcile loops (operator) must be idempotent. |
| 78 | +
|
| 79 | + - path: "components/frontend/src/**/*.{ts,tsx}" |
| 80 | + instructions: | |
| 81 | + - No 'any' types -- use proper types, 'unknown', or generic constraints. |
| 82 | + - Verify loading/error states and error handling in React Query hooks. |
| 83 | +
|
| 84 | + - path: "components/runners/ambient-runner/**/*.py" |
| 85 | + instructions: | |
| 86 | + - Check subprocess handling, timeout management, and that secrets are not logged. |
| 87 | +
|
| 88 | + - path: "components/manifests/**/*.yaml" |
| 89 | + instructions: | |
| 90 | + - RBAC must follow least-privilege. Resource limits/requests required on containers. |
| 91 | +
|
| 92 | + - path: ".github/workflows/**/*.{yml,yaml}" |
| 93 | + instructions: | |
| 94 | + - Pin action versions to SHA. Verify secrets are not exposed and permissions are scoped. |
| 95 | +
|
| 96 | + # --------------------------------------------------------------------------- |
| 97 | + # Auto review |
| 98 | + # --------------------------------------------------------------------------- |
| 99 | + auto_review: |
| 100 | + enabled: true # default |
| 101 | + description_keyword: "" # default |
| 102 | + auto_incremental_review: true # default |
| 103 | + auto_pause_after_reviewed_commits: 5 # default |
| 104 | + drafts: false # default |
| 105 | + labels: [] # default |
| 106 | + ignore_title_keywords: |
| 107 | + - "WIP" |
| 108 | + - "DO NOT MERGE" |
| 109 | + ignore_usernames: |
| 110 | + - "dependabot[bot]" |
| 111 | + - "renovate[bot]" |
| 112 | + base_branches: |
| 113 | + - ".*" |
| 114 | + |
| 115 | + # --------------------------------------------------------------------------- |
| 116 | + # Finishing touches |
| 117 | + # --------------------------------------------------------------------------- |
| 118 | + finishing_touches: |
| 119 | + docstrings: |
| 120 | + enabled: true # default |
| 121 | + unit_tests: |
| 122 | + enabled: true # default |
| 123 | + simplify: |
| 124 | + enabled: true |
| 125 | + |
| 126 | + # --------------------------------------------------------------------------- |
| 127 | + # Pre-merge checks |
| 128 | + # --------------------------------------------------------------------------- |
| 129 | + pre_merge_checks: |
| 130 | + override_requested_reviewers_only: false # default |
| 131 | + |
| 132 | + docstrings: |
| 133 | + mode: warning # default |
| 134 | + threshold: 80 # default |
| 135 | + |
| 136 | + title: |
| 137 | + mode: warning |
| 138 | + requirements: >- |
| 139 | + Conventional Commits format: type(scope): description. |
| 140 | + Types: feat, fix, chore, docs, refactor, test, ci, perf. |
| 141 | +
|
| 142 | + description: |
| 143 | + mode: warning # default |
| 144 | + |
| 145 | + issue_assessment: |
| 146 | + mode: warning # default |
| 147 | + |
| 148 | + custom_checks: |
| 149 | + - name: "Performance and Algorithmic Complexity" |
| 150 | + mode: error |
| 151 | + instructions: | |
| 152 | + BLOCKING. Flag only meaningful performance regressions: |
| 153 | + 1. O(n^2)+ algorithms on non-trivial inputs (handlers, K8s list operations). |
| 154 | + 2. N+1 patterns: list-then-query-per-item (K8s API, DB). |
| 155 | + 3. Expensive work inside loops (API calls, JSON parsing, regex compilation). |
| 156 | + 4. Unbounded growth: caches, watchers, buffers without eviction/limits. |
| 157 | + 5. Missing pagination/limits on List operations or API endpoints. |
| 158 | + 6. Frontend: unnecessary rerenders, missing memoization, unvirtualized large lists, missing dependency arrays, unbounded localStorage, sessionStorage or Cookies. Blocking HTTP requests. |
| 159 | +
|
| 160 | + Per issue: file, lines, risk, fix category. If clean, mark PASSED. |
| 161 | +
|
| 162 | + - name: "Security and Secret Handling" |
| 163 | + mode: error |
| 164 | + instructions: | |
| 165 | + BLOCKING. Flag: |
| 166 | + 1. Secrets/tokens logged in plaintext or hardcoded in source. |
| 167 | + 2. Missing auth/authz on API endpoints. |
| 168 | + 3. Backend service account used where GetK8sClientsForRequest is required. |
| 169 | + 4. Injection vulnerabilities (SQL, command, path traversal). |
| 170 | + 5. Sensitive data leaked in API responses, WebSocket messages, or logs. |
| 171 | + 6. K8s Secrets missing OwnerReferences. |
| 172 | +
|
| 173 | + Per violation: file, lines, risk. If clean, mark PASSED. |
| 174 | +
|
| 175 | + - name: "Kubernetes Resource Safety" |
| 176 | + mode: warning |
| 177 | + instructions: | |
| 178 | + Flag: |
| 179 | + 1. Child resources (Jobs, Secrets, PVCs) missing OwnerReferences. |
| 180 | + 2. Missing resource limits/requests on containers. |
| 181 | + 3. Overly permissive RBAC (wildcard verbs/resources). |
| 182 | + 4. Missing namespace scoping or pod security context. |
| 183 | +
|
| 184 | + If clean, mark PASSED. |
| 185 | +
|
| 186 | + # --------------------------------------------------------------------------- |
| 187 | + # Tools |
| 188 | + # --------------------------------------------------------------------------- |
| 189 | + tools: |
| 190 | + # Enabled (all default to true; listed for completeness) |
| 191 | + golangci-lint: |
| 192 | + enabled: true # default |
| 193 | + eslint: |
| 194 | + enabled: true # default |
| 195 | + ruff: |
| 196 | + enabled: true # default |
| 197 | + hadolint: |
| 198 | + enabled: true # default |
| 199 | + actionlint: |
| 200 | + enabled: true # default |
| 201 | + shellcheck: |
| 202 | + enabled: true # default |
| 203 | + yamllint: |
| 204 | + enabled: true # default |
| 205 | + markdownlint: |
| 206 | + enabled: true # default |
| 207 | + buf: |
| 208 | + enabled: true # default |
| 209 | + gitleaks: |
| 210 | + enabled: true # default |
| 211 | + trufflehog: |
| 212 | + enabled: true # default |
| 213 | + checkov: |
| 214 | + enabled: true # default |
| 215 | + trivy: |
| 216 | + enabled: true # default |
| 217 | + github-checks: |
| 218 | + enabled: true # default |
| 219 | + timeout_ms: 90000 # default |
| 220 | + languagetool: |
| 221 | + enabled: true # default |
| 222 | + opengrep: |
| 223 | + enabled: true # default |
| 224 | + semgrep: |
| 225 | + enabled: true # default |
| 226 | + checkmake: |
| 227 | + enabled: true # default |
| 228 | + dotenvLint: |
| 229 | + enabled: true # default |
| 230 | + osvScanner: |
| 231 | + enabled: true # default |
| 232 | + |
| 233 | + # Disabled -- overlap with preferred linters |
| 234 | + biome: |
| 235 | + enabled: false # conflicts with eslint |
| 236 | + oxc: |
| 237 | + enabled: false # conflicts with eslint |
| 238 | + flake8: |
| 239 | + enabled: false # conflicts with ruff |
| 240 | + pylint: |
| 241 | + enabled: false # conflicts with ruff |
| 242 | + |
| 243 | +# ============================================================================= |
| 244 | +# Chat |
| 245 | +# ============================================================================= |
| 246 | +chat: |
| 247 | + auto_reply: false |
| 248 | + art: false |
| 249 | + allow_non_org_members: false |
| 250 | + integrations: |
| 251 | + jira: |
| 252 | + usage: auto # default |
| 253 | + linear: |
| 254 | + usage: auto # default |
| 255 | + |
| 256 | +# ============================================================================= |
| 257 | +# Knowledge base |
| 258 | +# ============================================================================= |
| 259 | +knowledge_base: |
| 260 | + opt_out: false # default |
| 261 | + web_search: |
| 262 | + enabled: false |
| 263 | + code_guidelines: |
| 264 | + enabled: true # default |
| 265 | + filePatterns: [] # default |
| 266 | + learnings: |
| 267 | + scope: global |
| 268 | + issues: |
| 269 | + scope: auto # default |
| 270 | + pull_requests: |
| 271 | + scope: auto # default |
| 272 | + jira: |
| 273 | + usage: auto # default |
| 274 | + project_keys: [] # default |
| 275 | + linear: |
| 276 | + usage: auto # default |
| 277 | + team_keys: [] # default |
| 278 | + mcp: |
| 279 | + usage: auto # default |
| 280 | + disabled_servers: [] # default |
| 281 | + linked_repositories: [] # default |
| 282 | + |
| 283 | +# ============================================================================= |
| 284 | +# Code generation |
| 285 | +# ============================================================================= |
| 286 | +code_generation: |
| 287 | + docstrings: |
| 288 | + language: en-US # default |
| 289 | + path_instructions: [] # default |
| 290 | + unit_tests: |
| 291 | + path_instructions: [] # default |
| 292 | + |
| 293 | +# ============================================================================= |
| 294 | +# Issue enrichment |
| 295 | +# ============================================================================= |
| 296 | +issue_enrichment: |
| 297 | + auto_enrich: |
| 298 | + enabled: true |
| 299 | + planning: |
| 300 | + enabled: true # default |
| 301 | + auto_planning: |
| 302 | + enabled: true # default |
| 303 | + labels: [] # default |
| 304 | + labeling: |
| 305 | + labeling_instructions: [] # default |
| 306 | + auto_apply_labels: false # default |
0 commit comments