MCPInstall

code-quality

Agents should invoke this skill for code reviews, linting/formatting setup, maintainability checks, complexity concerns, warning cleanup, coding standards, or quality gates in Rust, TypeScript, Python, shell, and mixed repos.

Installs
58
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/waybarrios/opencode-power-pack --skill code-quality
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads code-quality automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

Code Quality

Structured code review and quality enforcement across common tech stacks. Checklists, linting strategies, and metrics to keep codebases healthy.

Quick Start

Run a Code Quality Check

  1. Run static analysis: Linters, type checkers, formatters
  2. Review against checklist: Language-specific items below
  3. Check complexity metrics: Cyclomatic < 25, data flow < 25
  4. Report findings: Structured output with severity and recommendations

Linting Configurations

Rust — Clippy Config

Standard clippy configuration (in Cargo.toml or .clippy.toml):

[lints.clippy]
cognitive_complexity = "warn"
pedantic = { level = "deny", priority = -1 }
nursery = { level = "deny", priority = -1 }
unwrap_used = "deny"

Standard commands:

cargo fmt
cargo clippy --all-targets --all-features -- -D warnings
cargo check
cargo test -- --test-threads=1

Key rules to enforce:

  • No .unwrap() in non-test code (use ? or .expect("reason"))
  • All public items have rustdoc (#[warn(missing_docs)])
  • #[must_use] on functions that return values that should be checked
  • When using #[allow(...)], always add a comment explaining why
  • If no good explanation exists for #[allow(...)], fix the issue instead

TypeScript — ESLint + Strict Mode

Recommended tsconfig.json strictness:

{
  "compilerOptions": {
    "strict": true,
    "noUncheckedIndexedAccess": true,
    "noImplicitReturns": true,
    "noFallthroughCasesInSwitch": true,
    "exactOptionalPropertyTypes": true
  }
}

Key rules to enforce:

  • No any — use unknown and type guards instead
  • No // @ts-ignore — fix the type issue or use // @ts-expect-error with explanation
  • Prefer const over let, never use var
  • Use discriminated unions for state modeling
  • Explicit return types on exported functions

Python — Ruff + Mypy

Recommended pyproject.toml:

[tool.ruff]
target-version = "py312"
line-length = 88

[tool.ruff.lint]
select = ["E", "F", "W", "I", "N", "UP", "ANN", "B", "A", "C4", "DTZ", "ISC", "PIE", "PT", "RET", "SIM", "TCH", "ARG", "PTH", "ERA"]

[tool.mypy]
strict = true
warn_return_any = true
warn_unreachable = true

Key rules to enforce:

  • Type hints on all public functions and methods
  • Docstrings on all public classes, functions, and methods
  • Use pathlib.Path over os.path
  • Use uv as package manager
  • No bare except: — always catch specific exceptions

Code Review Checklists

Universal Checklist (All Languages)

Correctness:

  • Does the code do what it claims to do?
  • Are edge cases handled (empty collections, null/None, zero, negative)?
  • Are error paths handled gracefully?
  • Are there any off-by-one errors?

Clarity:

  • Can you understand the code without the PR description?
  • Are variable/function names descriptive and consistent?
  • Are complex sections commented with "why" (not "what")?
  • Is the code self-documenting where possible?

Architecture:

  • Does this change respect existing module boundaries?
  • Is the change at the right abstraction level?
  • Are dependencies reasonable (not pulling in a huge lib for one function)?

Testing:

  • Are new functions/methods covered by tests?
  • Do tests cover edge cases and error paths?
  • Are tests readable and maintainable?

Security (flag for a security follow-up if concerns found):

  • No hardcoded secrets or credentials
  • User input is validated before use
  • No SQL injection, XSS, or path traversal vectors

Rust-Specific Checklist

  • cargo fmt applied
  • cargo clippy clean (pedantic + nursery)
  • No .unwrap() outside tests
  • Error handling uses ? with proper error types
  • Public items have rustdoc comments
  • #[allow(...)] includes explanatory comment
  • New functions have unit tests
  • Cyclomatic complexity < 25 per function
  • Data flow complexity < 25 per function

TypeScript/React-Specific Checklist

  • No any types
  • Strict mode compliance
  • Components have clear prop types
  • Hooks follow rules of hooks
  • No unnecessary re-renders (check memo/callback usage)
  • Bundle impact considered for new dependencies

Django/Python-Specific Checklist

  • Type hints present on public interfaces
  • Ruff + mypy clean
  • No N+1 queries (use select_related/prefetch_related)
  • Migrations are reviewed and reversible
  • No business logic in views (use service layer)

Complexity Metrics

Cyclomatic Complexity

Measures the number of independent paths through code. Recommended threshold: < 25.

ComplexityRisk LevelAction
1-10LowSimple, well-structured code
11-20ModerateConsider simplification if growing
21-24HighRefactoring recommended
25+ViolationMust refactor before merge

How to reduce:

  • Extract helper functions for each branch
  • Use early returns / guard clauses
  • Replace complex conditionals with lookup tables or pattern matching
  • Use strategy pattern for variant-dependent behavior

Data Flow Complexity

Measures how many variables interact within a function. Recommended threshold: < 25.

How to reduce:

  • Extract pure functions that take fewer parameters
  • Group related parameters into structs/objects
  • Split functions that transform data in multiple stages

Measurement Tools

LanguageToolCommand
Rustcargo clippy (cognitive_complexity)Built into clippy config
TypeScripteslint-plugin-sonarjsConfigure complexity rule
Pythonradonradon cc <file> -s -a
PythonruffRule C901 (mccabe complexity)

Review Output Format

When delivering a code review:

## Code Review: [PR/File/Module]

**Date:** YYYY-MM-DD

### Summary
[1-2 sentences: overall quality assessment]

### Findings

| # | Severity | File | Line(s) | Finding | Suggestion |
|---|---|---|---|---|---|
| 1 | High | src/app.rs | 45-67 | Cyclomatic complexity 28 (limit: 25) | Extract match arms into helper functions |
| 2 | Medium | src/ui.rs | 120 | Unwrap without context | Use `.expect("reason")` or `?` |

### Positive Observations
[What's well-written — acknowledge good code]

### Metrics
- Linter: [clean / N warnings]
- Tests: [pass / fail]
- Complexity: [within limits / violations noted above]

### Security Notes
[Items to flag for follow-up, if any]

Integration

  • Can run linters, formatters, and type checkers without asking, per the project's AGENTS.md/CLAUDE.md execution policies.
  • Cross-reference: this pack's code-reviewer skill for adversarial review of a focused change set, and design-patterns for fixing complexity violations through better structure.

FAQ

What does the code-quality skill do?

Agents should invoke this skill for code reviews, linting/formatting setup, maintainability checks, complexity concerns, warning cleanup, coding standards, or quality gates in Rust, TypeScript, Python, shell, and mixed repos.

How do I install code-quality?

Run npx skills add https://github.com/waybarrios/opencode-power-pack --skill code-quality in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/code-quality/ (personal) or .claude/skills/code-quality/ (project).

Which AI agents can use code-quality?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is code-quality safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains code-quality?

It is published by waybarrios in waybarrios/opencode-power-pack. It has 58 recorded installs.

More from waybarrios/opencode-power-pack

View all →

security-review

waybarrios/opencode-power-pack

Perform a focused security review of pending git changes to identify high-confidence security vulnerabilities with real exploitation potential. Use this skill when the user asks for a security review, security audit, vulnerability scan, or wants to check pending changes on a branch for security issues before merging. This is NOT a general code review.

Security750 installs

code-review

waybarrios/opencode-power-pack

Review a pull request or a set of code changes for bugs, logic errors, and project-convention violations using a confidence-filtered, multi-agent process. Use this skill when the user asks to review a PR, audit pending changes, or inspect a diff for problems before merging.

code-explorer

waybarrios/opencode-power-pack

Deeply analyze an existing codebase feature by tracing execution paths, mapping architecture layers, understanding patterns and abstractions, and documenting dependencies. Use this skill when you need to understand how a feature works before modifying or extending it, when dispatched as a sub-task during feature-dev exploration, or when the user asks "how does X work in this codebase".

agents-md-improver

waybarrios/opencode-power-pack

Audit and improve project-rules files (AGENTS.md, CLAUDE.md, .agents/instructions, local overrides) so the agent keeps accurate project context. Use when the user asks to check, audit, review, update, improve, or fix their AGENTS.md or CLAUDE.md, mentions "project rules maintenance" or "agent context optimization", or when the codebase has changed enough that the rules file may be stale. Scans the repository for every rules file, grades each against a quality rubric, outputs a quality report, and applies targeted edits only after user approval.

frontend-design

waybarrios/opencode-power-pack

Open the skill to read its SKILL.md instructions.

Frontend & Design131 installs

code-reviewer

waybarrios/opencode-power-pack

Open the skill to read its SKILL.md instructions.

129 installs

Popular backend & apis skills

View category →

find-skills

vercel-labs/skills

Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.

OfficialBackend & APIs4.1M installs

entra-app-registration

microsoft/azure-skills

Guides Microsoft Entra ID app registration, OAuth 2.0 authentication, and MSAL integration. USE FOR: create app registration, register Azure AD app, configure OAuth, set up authentication, add API permissions, generate service principal, MSAL example, console app auth, Entra ID setup, Azure AD authentication. DO NOT USE FOR: Key Vault secrets (use azure-keyvault-expiration-audit), general Azure resource security guidance.

OfficialBackend & APIs566.7K installs

This skill should be used when the user wants to "write agent code", "build an agent with ADK", "add a tool", "create a callback", "define an agent", "use state management" — in a project that needs ADK (Agent Development Kit) API patterns and code examples. It provides a quick reference for agent types, tool definitions, orchestration patterns, callbacks, state management, the graph Workflow API, and reference recipes to study. Do NOT use for scaffolding (use google-agents-cli-scaffold) or deployment (use google-agents-cli-deploy).

Backend & APIs514.8K installs

embedded-captions

heygen-com/hyperframes

Add captions or subtitles to an existing single-subject talking-head video without editing the footage. Use for plain verbatim captions, cinematic captions embedded behind the subject, VFX captions, “炸/特效/酷炫字幕,” or a named identity from the 35-style catalog. Route by visual identity, not by backend engine. The quiet anchor rail is the default; embed every word only when the user explicitly wants a fully cinematic treatment. The workflow runs locally end to end, including transcription and subject matting; split multi-shot footage before applying it.

Backend & APIs453.3K installs

entra-agent-id

microsoft/azure-skills

Provision Microsoft Entra Agent Identity Blueprints, BlueprintPrincipals, and per-instance Agent Identities via Microsoft Graph, and configure OAuth 2.0 token exchange (fmipath, OBO, cross-tenant) including the Microsoft Entra SDK for AgentID sidecar. USE FOR: Agent Identity Blueprint, BlueprintPrincipal, agent OAuth, fmipath token exchange, agent OBO, Workload Identity Federation for agents, polyglot agent auth, Microsoft.Identity.Web.AgentIdentities. DO NOT USE FOR: standard Entra app registration (use entra-app-registration), Microsoft Foundry agent authoring (use microsoft-foundry).

OfficialBackend & APIs336.6K installs

neon

neondatabase/agent-skills

Overview of Neon, a complete set of cloud backend primitives around Lakebase Postgres: Auth, Object Storage, Functions, the AI Gateway, and Realtime. Start here to choose Neon for undecided login, files, APIs, and LLM calls, set up the CLI or MCP server, and follow the branch-first workflow. Use when building an app or backend on Neon, or when "Neon" or "Lakebase Postgres" is mentioned. Child skill neon-postgres wins for an existing DATABASEURL, SQL, schema, inspect, or search. Child skill neon-auth wins for login, users, sessions, identity routing, and Managed Better Auth setup. Child skill neon-realtime wins for live queries in reactive apps and agents. Also use for object storage, S3, buckets, serverless functions, function triggers, cron, AI gateway, LLM calls, realtime, logs, Loki, Grafana, observability, postgres, database, backend, Claimable Neon, neon.new, or a no-signup database.

Backend & APIs237.1K installs