Files
rich-print/.opencode/skills/simplify/SKILL.md

2.2 KiB

name, description, compatibility, metadata
name description compatibility metadata
simplify Review changed code for reuse, quality, and efficiency, then fix issues found opencode
workflow parallel
code-review true

What I do

I review your recent changes from three angles in parallel, then fix the issues I find.

How to use me

  1. Identify the changed files using git diff (staged or unstaged).
  2. Launch three parallel review agents, each with a different focus:
    • Reuse Review: Look for duplicated logic, copy-paste patterns, or abstractions that already exist in the codebase. Check if the new code reinvents something that's already available as a utility, helper, or library function.
    • Quality Review: Look for hacky patterns, missing error handling, unclear naming, magic numbers, overly complex functions, and violations of existing project conventions.
    • Efficiency Review: Look for unnecessary allocations, N+1 queries, redundant iterations, missing early returns, and opportunities to simplify algorithms.
  3. Wait for all three agents to finish.
  4. Aggregate findings by severity (bugs > correctness > performance > style).
  5. Fix the highest-severity issues directly. For lower-severity items, report them for the user to decide.

Agent prompt template

For each review agent, use this structure:

You are a code reviewer focused on [REUSE|QUALITY|EFFICIENCY].

Review the following changed files. You are a sub-agent — do NOT modify files, only report findings. The parent skill will apply fixes after aggregating all reviews.

Changed files:
<list files from git diff>

For each finding, provide:
- File path and line number
- What is wrong
- Why it matters
- Suggested fix (if applicable)

Order findings by severity: bugs > correctness > performance > style.
If you find no issues, say so explicitly.

Output format

Findings

Ordered by severity. Each finding includes file, line, issue, and fix.

Applied Fixes

List of changes made with rationale.

Remaining

Lower-severity items left for the user to decide.

When to use me

Use this after making a set of changes and before committing. Do not use for exploratory reading — this skill modifies files.