reviewing-codebase-consistency
Reviews PR changes against the broader codebase to find inconsistencies, missed propagation, and stale references beyond the diff. Replicates senior reviewer codebase knowledge. Activates when reviewing PRs, checking consistency, or when changes touch shared entities across multiple files.
What this skill does
# Reviewing Codebase Consistency A senior reviewer has the full codebase in their head. When they read a diff, they instantly know what other files should also change. This skill replicates that by building codebase context around the diff and checking for inconsistencies. ## When to apply Apply on every PR review. The value scales with PR size and cross-cutting concerns. ## Workflow Copy this checklist and track progress: ``` Codebase Consistency Review: - [ ] Step 1: Build codebase context - [ ] Step 2: Run local build - [ ] Step 3: Trace change propagation - [ ] Step 4: Check related files outside the diff - [ ] Step 5: Verify cross-layer consistency - [ ] Step 6: Compile findings ``` ### Step 1: Build codebase context 1. Read the PR description to understand **intent** — what is this PR trying to accomplish? 2. From the diff, extract **changed entities**: renamed identifiers, modified types/interfaces, altered DB schemas, changed API contracts, modified configurations 3. For each changed entity, use Grep and Glob to map its **usage graph** — every file that imports, references, extends, or depends on it 4. Compare the usage graph against the diff file list. Files in the usage graph but NOT in the diff are **candidates for missed changes**. This is the most critical step. The usage graph is what a senior reviewer holds in their head. ### Step 2: Run local build Run the project's build, lint, and typecheck commands to collect concrete errors. Detect the appropriate commands from the project structure (Makefile, package.json, pyproject.toml, Cargo.toml, go.mod, etc.). Build errors provide a mechanical safety net that catches every compile-time inconsistency that code reading alone might miss. Categorize errors by file and type. ### Step 3: Trace change propagation For each changed entity from Step 1, verify the change has propagated to ALL dependent code: - **Data model changes** → query code, serializers, API responses, form fields, test fixtures, mock data, seed data - **API contract changes** → frontend components, integration tests, API clients, documentation - **Schema/migration changes** → List all migrations in execution order. Verify no migration that runs AFTER a rename/drop references old entity names. Check migrations added on the base branch since the PR branched. - **Type/interface changes** → implementations, callers, type assertions, casts - **Configuration changes** → all readers of the configuration, environment-specific configs For detailed propagation paths by change type, see [references/propagation-paths.md](references/propagation-paths.md). ### Step 4: Check related files outside the diff For each candidate file identified in Step 1 (in usage graph but not in diff): 1. Read the file 2. Check if it uses the old version of any changed entity 3. If it does, report it as a missed change with file:line and what needs updating Also check for files that are in the diff but only **partially updated** — for example, a variable was renamed but string literals or form field references using the old name were not. ### Step 5: Verify cross-layer consistency Check that changes are consistent across all layers of the application: - **DB layer ↔ ORM/model layer**: Schema changes reflected in model definitions, relation names, query code - **Backend ↔ API contract**: Changed types/routes reflected in API specifications, response shapes - **API contract ↔ Frontend**: Changed API responses reflected in frontend types, form fields, display logic - **Code ↔ Tests**: Changed behavior reflected in unit tests, integration tests, E2E tests, mock/fixture data - **Code ↔ Configuration**: Changed features reflected in config files, permissions, feature flags ### Step 6: Compile findings Output structured findings: ``` PR_INTENT: [one-line summary of what the PR is trying to accomplish] CHANGED_ENTITIES: [list of entities modified by the diff] BUILD_ERRORS: [categorized list or "none"] MISSED_FILES: [file:line list with what needs updating, or "none"] PARTIAL_UPDATES: [file:line list with what was missed, or "none"] CROSS_LAYER_ISSUES: [list or "none"] MIGRATION_ORDERING: [conflicts or "none"] ``` ## Report format For each finding: - **Severity**: Critical / High / Medium / Low - **Location**: file:line - **Issue**: Brief description - **Suggestion**: Specific fix
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.