Agent skill

Code Refactor Review

by kcsujeet in kcsujeet/ilamy-calendar

Reviews code changes for reuse, composition, codebase consistency, and slop.

MITAuto-check passedDevelopment

Install Code Refactor Review

skills CLI
$ npx skills add kcsujeet/ilamy-calendar --skill code-refactor-review -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install kcsujeet/ilamy-calendar code-refactor-review --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/kcsujeet/ilamy-calendar.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/code-refactor-review .claude/skills/code-refactor-review && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
code-refactor-review
GitHub stars
351
Used in
2 other repos
Token cost
~1.6k tokens
SKILL.md length
865 words
Files
1
Skills in repo
3
Repo updated
First seen
Licence
MIT

At a glance

Reviews code changes for reuse, composition, codebase consistency, and slop.

  • Works in 6 steps: Reuse Existing Code → Codebase Consistency → Composition and Boundaries → …
  • Asked to review PRs/diffs
  • SKILL.md covers First Pass, Review Lenses, Output Format and Red Flags, plus 1 more section
  • Calls git

What it does

Code Refactor Review is an agent skill from kcsujeet/ilamy-calendar. Reviews code changes for reuse, composition, codebase consistency, and slop. Use when asked to review PRs/diffs, check code reuse, composition, cleanliness, or whether code fits the codebase.

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Refactoring. It works with React, TypeScript, shadcn/ui and Tailwind CSS. The repository describes itself as: A modern, open-source Full Calendar alternative for React. Month, week, day, and year views with drag-and-drop, horizontal and vertical resource views, and RFC 5545 recurring… The licence is MIT.

When your agent uses it

  • Asked to review PRs/diffs
  • Check code reuse
  • Whether code fits the codebase

Example prompts

  • “Use the code-refactor-review skill to review code changes for reuse, composition, codebase consistency, and slop”
  • “/code-refactor-review”

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. Reuse Existing Code
  2. Codebase Consistency
  3. Composition and Boundaries
  4. Slop Detection
  5. React / Next.js Quality
  6. Minimality

What it can do on your machine

Read from SKILL.md and the folder at commit be400a3. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Code Refactor Review loads about 1.6k tokens when it runs. Until then it costs about 53 tokens; SKILL.md has 865 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~53
When it runs · the whole SKILL.md, loaded when a task matches
~1.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from kcsujeet/ilamy-calendar at commit be400a3, republished under its MIT licence (© kcsujeet). 865 words, ~1,583 tokens.

Download SKILL.mdSave it as .claude/skills/code-refactor-review/SKILL.md (or your agent's skills folder).
name
code-refactor-review
description
Reviews code changes for reuse, composition, codebase consistency, and slop. Use when asked to review PRs/diffs, check code reuse, composition, cleanliness, or whether code fits the codebase.

Code Refactor Review

Review code changes the way Sahaj usually asks for review: go deep on reuse, composition, codebase consistency, and anything that reads like slop.

First Pass

  1. Inspect the full diff:
    • Use git diff for unstaged changes.
    • Use git diff HEAD if there are staged changes.
    • For a PR URL, inspect the changed files and understand the feature flow before reviewing details.
  2. Build the call stack / data flow when useful. Do not review isolated lines without understanding how the feature is wired.
  3. Search the codebase before judging new helpers, components, hooks, or patterns. Prefer nearby and sibling patterns over invented abstractions.

Review Lenses

1. Reuse Existing Code
  • Look for existing utilities, components, hooks, server actions, route patterns, copy patterns, and styling primitives before accepting newly written code.
  • Flag duplicated logic, copied helpers, or custom implementations of things the codebase already has.
  • Prefer reusing the existing flow even if it needs a small extension.
  • If the new code creates a shared helper, verify it has real reuse and is not just extracted private logic with a vague name.
2. Codebase Consistency
  • File placement should match the domain and neighboring features. Be suspicious of random top-level lib dumps.
  • Naming should match what the code actually does and follow sibling file/function names.
  • Avoid implementation details in names unless they are the actual product/API distinction.
  • Use existing result/error/loading patterns. Do not invent bespoke success/failure types when the codebase has a standard one.
  • Match existing copy and tone for user-facing text.
3. Composition and Boundaries
  • Functions should do one thing at the right level of abstraction.
  • Avoid grab-bag modules that mix unrelated concerns like flags, API calls, transformation, UI state, logging, and scheduling.
  • Avoid parameter sprawl. If a function needs many knobs, check whether the boundary is wrong.
  • Prefer simple composition over chains of callbacks, wrappers, memoized helpers, and prop plumbing.
  • When two backing entities are presented as one product concept, package them into one transport/view model across intermediate components. Black-box components should receive one unified prop/callback and should not care about distinctions like remote vs prebuilt; split back into core entities only at roots/adapters where persistence or payload formats require it.
  • Keep domain-specific logic close to its domain unless there is proven cross-domain reuse.
4. Slop Detection

Flag and, when asked, remove:

  • Comment slop: obvious comments, comments defending awkward code, long comments that should become clearer code, stale context in PR descriptions.
  • Helper slop: tiny wrappers that add no meaning, helper files created only to make one function look shorter, unnecessary indirection.
  • Type slop: exported one-off types, custom result shapes, annotations where inference is clearer, types that only paper over awkward code.
  • Memo/callback slop: useMemo / useCallback added without a measured or structural reason.
  • Effect slop: effects that mirror props/state, reset derived state, or handle events after the fact.
  • Compatibility cruft: bolted-on behavior that preserves accidental architecture instead of building the coherent end state.
  • Diff churn: unrelated renames, formatting, comments, or wrappers that make the PR larger without improving the design.
Show full SKILL.md (365 more words)Show less
5. React / Next.js Quality
  • Apply “You Might Not Need an Effect”: derive values during render, move event-caused work into event handlers, and reset state with keys when appropriate.
  • Avoid redundant state and synchronization effects.
  • Do not add memoization just to quiet performance anxiety. Memoization should solve a real render identity or expensive computation issue.
  • Prefer straightforward component boundaries over prop/callback gymnastics.
  • For server/data code, avoid unnecessary waterfalls and run independent work concurrently when the codebase has a pattern for it.
6. Minimality
  • Prefer deleting code over adding new structure.
  • Prefer one clear function over several helper-y fragments unless extraction improves reuse or readability.
  • Keep the fix proportional to the problem.
  • Do not add architecture, docs, or comments unless they remove ambiguity for future readers.

Output Format

Start with a verdict:

  • clean — no meaningful concerns.
  • mostly clean — minor cleanup only.
  • needs cleanup — important reuse/composition/consistency issues.

Then list findings by priority. For each finding include:

  1. File path and relevant symbol/area.
  2. What reads as slop or inconsistency.
  3. The existing pattern or code that should be reused, if found.
  4. The minimal recommended fix.

If the user asked for review only, do not edit files. If the user asked to fix it, make the changes directly and summarize what changed.

Red Flags

  • “Can we reuse existing code?” was not answered with a search.
  • New top-level helpers with vague names like utils, helpers, shared, or implementation-specific names.
  • A function whose name hides important side effects.
  • A directory containing only index.ts without a reason.
  • Re-exporting something that is already exported elsewhere.
  • New custom primitives where the product already has a component or pattern.
  • Large comments explaining why awkward props or flags exist.
  • Multiple new types just to support one local function.
  • New callback/memo/effect code that disappears if state ownership is simplified.

Rules

  • Be direct and concise. Avoid extra explanatory fluff.
  • Do not invent architecture. Ground claims in codebase patterns.
  • Search before claiming something is reusable or inconsistent.
  • If a pattern is not present in the codebase, say so and recommend the smallest clean alternative.
  • Prefer if statements over ternaries when suggesting code changes in v0.
  • When in doubt, optimize for code that reads obvious from left to right.

© kcsujeet, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/code-refactor-review of kcsujeet/ilamy-calendar.

Open the folder on GitHubat commit be400a3

Used in 2 other repositories

We found 2 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 2 other GitHub owners. This page covers the copy in kcsujeet/ilamy-calendar, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Code Refactor Review next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Code Refactor Review compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Code Refactor Review this skillkcsujeet/ilamy-calendar3512 repos~1.6kAutomated safety check: PassMIT
Finish Extensions Featuresenchabot-opensource/monorepo114—~554Automated safety check: PassGPL-3.0
Cleanup Specialistahaodev/shadmin174—~1.3kAutomated safety check: PassMIT
Frontend Developmentavibebuilder/claude-prime120—~1.3kAutomated safety check: PassMIT
Dify Component Writing Guidelanggenius/dify158k—~626Automated safety check: PassCustom licence
Shadmin CLIahaodev/shadmin174—~1.1kAutomated safety check: NotesMIT

Similar skills

  • Finish Extensions Feature

    senchabot-opensource/monorepo

    A skill your agent uses when completing a new feature or making a user-facing change in the apps/extensions workspace to ensure no required files or configurations are forgotten.

    114 GitHub stars~554 tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Cleanup Specialist

    ahaodev/shadmin

    Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features.

    174 GitHub stars~1.3k tokensUpdated 6 days ago
    DevelopmentAuto-check passed
  • Frontend Development

    avibebuilder/claude-prime

    A skill your agent uses for ANY work involving React, Next.js, TypeScript, or Tailwind in the browser layer.

    120 GitHub stars~1.3k tokensUpdated 4 mo ago
    Frontend & DesignAuto-check passed
  • Use when implementing or refactoring React/TypeScript components and the task requires decisions about component ownership, feature boundaries, state, data…

    158k GitHub stars~626 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Shadmin CLI

    ahaodev/shadmin

    A skill your agent uses when the user asks to query Shadmin admin platform resources (users, roles, menus, registered API resources) from a terminal — for example "list shadmin users", "show shadmin…

    174 GitHub stars~1.1k tokensUpdated 6 days ago
    Backend & APIsAuto-check: notes
  • Web Artifacts Builder

    anthropics/skills

    Official

    Builds multi-component claude.ai HTML artifacts as a small React, TypeScript and Tailwind project, then bundles it into one shareable HTML file.

    180k GitHub starsUsed in 40 repos~769 tokens
    Frontend & DesignAuto-check passed

More from kcsujeet/ilamy-calendar

  • Reduce Bundle Size

    kcsujeet/ilamy-calendar

    Systematically reduce the shipped bundle size of a JS/TS library without sacrificing code readability or breaking consumer APIs.

    351 GitHub stars~2.9k tokensUpdated 4 days ago
    Auto-check passed
  • Release New Version

    kcsujeet/ilamy-calendar

    Cut a new release of @ilamy/calendar — analyze commits since the last tag, suggest a semver bump, draft a CHANGELOG entry in the project's existing style, run the CI gate, commit, tag, push to…

    351 GitHub stars~5.8k tokensUpdated 4 days ago
    Auto-check passed

Categories

Questions about Code Refactor Review

What does Code Refactor Review do?

Reviews code changes for reuse, composition, codebase consistency, and slop. Code Refactor Review is an agent skill from kcsujeet/ilamy-calendar. Reviews code changes for reuse, composition, codebase consistency, and slop.

When should I use Code Refactor Review?

Code Refactor Review fits situations like: asked to review PRs/diffs; check code reuse; whether code fits the codebase.

How do I install Code Refactor Review in Claude Code?

Run `npx skills add kcsujeet/ilamy-calendar --skill code-refactor-review -a claude-code`. Or copy the skill folder (.agents/skills/code-refactor-review in kcsujeet/ilamy-calendar) into .claude/skills/code-refactor-review in your project. Claude Code loads it when a task matches its description.

How do I install Code Refactor Review in Codex?

Run `npx skills add kcsujeet/ilamy-calendar --skill code-refactor-review -a codex`. Or copy the skill folder (.agents/skills/code-refactor-review in kcsujeet/ilamy-calendar) into .agents/skills/code-refactor-review in your project. Codex loads it when a task matches its description.

Can I use Code Refactor Review in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kcsujeet/ilamy-calendar --skill code-refactor-review -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/code-refactor-review, .gemini/skills/code-refactor-review, .github/skills/code-refactor-review and .opencode/skills/code-refactor-review in your project.

What does Code Refactor Review need to run?

Going by SKILL.md and its folder, Code Refactor Review needs the command-line tools its instructions call (git).

Does Code Refactor Review access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Code Refactor Review safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Code Refactor Review use?

Code Refactor Review is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Code Refactor Review use?

About 1.6k tokens (SKILL.md is roughly 6.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Code Refactor Review?

Skills that share tags, products or a category with Code Refactor Review: Finish Extensions Feature (senchabot-opensource/monorepo, 114 stars), Cleanup Specialist (ahaodev/shadmin, 174 stars), Frontend Development (avibebuilder/claude-prime, 120 stars) and Dify Component Writing Guide (langgenius/dify, 158k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Code Refactor Review?

kcsujeet (a GitHub user) maintains it in kcsujeet/ilamy-calendar, which has 351 GitHub stars. The repository holds 3 skills in this directory. The repository was last updated on October 3, 2026.

Source: kcsujeet/ilamy-calendar on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.