ruthless-refactorer

ruthless-refactorer is a skill for Claude Code, Codex from galdawave/pickle-rick-extension. It costs 41 tokens per session (708 once invoked), scanned A, original, Apache-2.0.

A code-refactoring guide that makes software simpler, clearer, and easier to maintain by removing duplication, unnecessary code, and overly complex logic.

In plain words
What is it for?
It helps inspect dependencies, plan and carry out refactors, remove unreachable or redundant code, improve names and types, and split changes into focused commits.
Why use it?
It helps reduce technical debt—the buildup of code that makes future changes slower and riskier—and keeps refactoring grounded in test coverage.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It helps inspect dependencies, plan and carry out refactors, remove unreachable or redundant code, improve names and types, and split changes into focused commits.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/galdawave/pickle-rick-extension/ruthless-refactorer
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add galdawave/pickle-rick-extension --skill ruthless-refactorer
Clone the repo
git clone --depth 1 https://github.com/galdawave/pickle-rick-extension

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ruthless-refactorer

README.md
[![agentmods](https://agentmods.dev/badge/skills/galdawave/pickle-rick-extension/ruthless-refactorer/github.svg)](https://agentmods.dev/skills/galdawave/pickle-rick-extension/ruthless-refactorer)
Your own site
<a href="https://agentmods.dev/skills/galdawave/pickle-rick-extension/ruthless-refactorer"><img src="https://agentmods.dev/badge/skills/galdawave/pickle-rick-extension/ruthless-refactorer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ruthless-refactorer

Your own site · 80×15
<a href="https://agentmods.dev/skills/galdawave/pickle-rick-extension/ruthless-refactorer"><img src="https://agentmods.dev/badge/skills/galdawave/pickle-rick-extension/ruthless-refactorer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 41 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 708 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00041 $0.00708
Opus 5 $0.00020 $0.00354
Sonnet 5 $0.00008 $0.00142
Haiku 4.5 $0.00004 $0.00071

Measured 11d ago against content hash bcb836094b7c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

ruthless-refactorer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/ruthless-refactorer/SKILL.md · 64 lines

How it starts

The opening of the file, as written. The whole thing — 64 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Ruthless Refactor Engine

You are a Senior Principal Engineer. Your goal is to make code lean, readable, and maintainable. You value simplicity over cleverness and deletion over expansion.

The Ruthless Philosophy

  • Delete with Prejudice: Remove unreachable or redundant code.
  • DRY is Law: Consolidate duplicate patterns.
  • Complexity is the Enemy: Flatten nested logic; replace if/else chains with guards.
  • AI Slop is Intolerable: Remove redundant comments (e.g., // loop through items), defensive bloat, lazy typing (any), and verbose AI logic.

Workflow

1. Reconnaissance

  • Locate Session: Use ${SESSION_ROOT} provided in context.
  • Read target files FULLY.
  • Map dependencies using codebase_investigator.
  • Verify test coverage. If tests are missing, STOP and create a test plan first.

2. Planning

  • Create a refactor ticket in ${SESSION_ROOT}.
  • Create a refactor plan in ${SESSION_ROOT}.
  • Identify the "Kill List" (code to be deleted) and the "Consolidation Map."

3. Execution

  • Apply changes in atomic commits.
  • Rename variables for clarity.
  • Remove redundant AI-generated comments and bloat.
  • Replace any or unknown with specific project types.

4. Verification

  • Ensure 1:1 functional parity.
  • Run project-specific tests and linters.
  • Provide a summary of lines removed vs lines added.

Refactor Scope

  • Modified Code: Focus on the diff, but ensure file coherence.
  • AI Slop Removal: Specifically target low-quality patterns introduced by AI assistants.

Next Step (FINALIZE)

Check for Work:

  1. Mark Current Ticket Done: Update the current ticket status to 'Done'.
  2. Scan for Next Ticket: Search ${SESSION_ROOT} for tickets where status is NOT 'Done' (ignore the Parent ticket).
  3. Decision:
    • If found: Select the next highest priority ticket and Call activate_skill("code-researcher").
    • If ALL tickets are Done:
      • Output the completion promise (if defined in state.json).
      • Output <promise>I AM DONE</promise> if this is a Morty worker.
      • Output [STOP_TURN].

Read the full file on GitHub · 64 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 64 lines · 41 tokens per session scan A bcb836094b7c

Subscribe to this mod's changes

ruthless-refactorer is a skill published in the GitHub repository galdawave/pickle-rick-extension (453 stars, last pushed 3mo ago), licensed Apache-2.0. It adds 41 tokens to every session and 708 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.