skills/backend-kotlin/bill-backend-kotlin-code-review/SKILL.md
Use when conducting a thorough Kotlin backend/server PR code review. Preserve backend review depth by running bill-kotlin-code-review as the baseline Kotlin review layer, then add backend-specific specialists such as API contracts, persistence, and reliability. Produces a structured review with risk register and prioritized action items. Use when user mentions backend Kotlin review, server review, Ktor review, Spring review, or backend PR review.
npx skillsauth add sermilion/mobile-development-plugin bill-backend-kotlin-code-reviewInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are an experienced backend Kotlin architect conducting a code review.
Your job is to preserve backend/server review depth without duplicating the shared Kotlin review logic.
If .agents/skill-overrides.md exists in the project root and contains a ## bill-backend-kotlin-code-review section, read that section and apply it as the highest-priority instruction for this skill. The matching section may refine or replace parts of the default workflow below.
If an AGENTS.md file exists in the project root, apply it as project-wide guidance.
Precedence for this skill: matching .agents/skill-overrides.md section > AGENTS.md > built-in defaults. Pass relevant project-wide guidance and matching per-skill overrides to every delegated or inline specialist review pass.
Determine the review scope:
git diff --cached; index only)git diff; working tree only)git diff --cached + git diff) only when the caller explicitly asks for all local changesResolve the scope before reviewing. If the caller asks for staged changes, inspect only the staged diff and keep unstaged edits out of findings except for repo markers needed for classification.
Inspect both the changed files and repo markers (build.gradle*, settings.gradle*, gradle/libs.versions.toml, pom.xml, application.yml, application.conf, source layout, module names, imports).
When the caller already passed the detected stack, skip reading stack-routing.md. For standalone invocation, read it before classifying.
Before selecting backend specialist review passes or formatting the final report, read review-orchestrator.md unless the caller already passed the shared review contract.
Before delegating baseline or backend specialist review passes, read only your current runtime's section in review-delegation.md.
Classify the review as one of:
backend-kotlinmixed-backend-kotlinnot-backend-kotlinio.ktor.server, routing {}, Application.modulespring-boot, @RestController, @Controller, @Service, @Repository, @Transactionalapplication.yml, application.yaml, application.confbill-kmp-code-review, accept mixed Android/KMP + backend scope and focus only on backend/server coverage while leaving KMP-only concerns to the caller.bill-kotlin-code-review and stop instead of pretending backend-specific coverage exists.bill-kotlin-code-review handle shared Kotlin coverage while this skill adds backend specialists.Select inline or delegated using review-orchestrator.md.
inline only when the backend review scope stays small and low-risk under the shared execution-mode contractdelegated when the diff is large, backend-only specialist risk is present, multiple layers are meaningfully involved, or the safest choice is unclearbill-kotlin-code-review as the baseline reviewRun bill-kotlin-code-review against the same scope first. That skill owns:
When invoking it from this skill in either execution mode:
backend-kotlin-baselineIf execution mode is inline, apply bill-kotlin-code-review inline in the current thread.
If execution mode is delegated, run bill-kotlin-code-review as a delegated subagent and use the runtime-specific delegation contract from review-delegation.md.
| Signal in the diff | Specialist review to run |
|---------------------|--------------------------|
| Routes/controllers, request/response DTOs, serializers, content negotiation, validation, status-code mapping, OpenAPI/schema changes | bill-backend-kotlin-code-review-api-contracts |
| Repositories/DAOs, SQL, ORM mappings, transactions, migrations, optimistic locking, upserts, bulk writes | bill-backend-kotlin-code-review-persistence |
| Timeouts, retries, circuit breakers, queues, schedulers, idempotency, caching, metrics, tracing, startup/shutdown lifecycle | bill-backend-kotlin-code-review-reliability |
When execution mode is delegated, build a per-specialist file list before launching backend specialist subagents:
This is a lightweight file-level classification (names + imports), not a full review.
If execution mode is inline:
If execution mode is delegated:
If no backend-only triggers match but backend/server signals are clearly present, keep the baseline Kotlin review output and state that no extra backend-specific specialist was needed for this scope.
Review session ID: <review-session-id>
Review run ID: <review-run-id>
Detected review scope: <staged changes / unstaged changes / working tree / commit range / PR diff / files>
Detected stack: <stack>
Signals: <markers>
Execution mode: inline | delegated
Applied learnings: none | <learning references>
Specialist reviews: <selected specialists>
Reason: <why these specialists were selected>
Every finding in ### 2. Risk Register must use this exact bullet format (do NOT use markdown tables):
- [F-001] <Severity> | <Confidence> | <file:line> | <description>
Severity: Blocker | Major | Minor. Confidence: High | Medium | Low.
For telemetry ownership, triage ownership, and the orchestrated flag contract, follow telemetry-contract.md.
For action items, verdict format, merge rules, and review principles, follow review-orchestrator.md.
bill-feature-implement, bill-feature-verify, or another orchestration skill, do not pause for user selection. Return prioritized findings so the caller can auto-fix P0/P1 items and decide whether to carry Minor items forward.bill-quality-check as final verification when the project uses a routed quality-check path and this review is being run standalone.development
Use when running a governed editorial assignment desk from Readian recommendations through candidate selection and source-backed story packs.
testing
Use when reviewing unit tests in a file, current changes, or a commit to flag low-value, tautological, or coverage-only tests that do not validate real behavior. Use when user mentions check test quality, review tests, tautological tests, weak tests, or coverage-padding.
data-ai
Use when removing an existing skill or platform skill set and cleaning up agent installs, manifests, and supporting links.
development
Use when you want a generic quality-check entry point that detects the dominant stack in scope and delegates to the matching stack-specific quality-check skill. Use when user mentions run checks, validate, lint, format, quality check, or run quality.