ai-slop-cleaner

Clean AI-generated code slop while preserving behavior with regression tests.

1|Updated Apr 1, 2026
One-click install
npx skills add https://github.com/OliverOuyang/shuhe-work-skills --skill ai-slop-cleaner-oliverouyang
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: ai-slop-cleaner
Source: https://github.com/OliverOuyang/shuhe-work-skills/tree/main/skills/ai-slop-cleaner
Command: npx skills add https://github.com/OliverOuyang/shuhe-work-skills --skill ai-slop-cleaner-oliverouyang

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

AI-generated or machine-assisted edits can leave working code bloated, duplicated, weakly tested, or over-abstracted, making maintenance harder and increasing regression risk; this Skill guides a safe, deletion-first cleanup that preserves behavior.

Core Features & Use Cases

  • Behavior-preserving cleanup: Prioritizes locking behavior with targeted regression tests before making edits.
  • Deletion-first, smell-focused passes: Structured passes for dead code removal, duplicate consolidation, naming and error-handling cleanup, and test reinforcement.
  • Reviewer-only workflow: Supports a --review mode to separate writer and reviewer responsibilities for high-impact anti-slop passes.
  • Ralph and scoped-file support: Operates on explicit file lists, changed-file scopes, or Ralph session changed files to limit risk and surface area.

Quick Start

Run an anti-slop cleanup on the specified files by invoking /oh-my-claudecode:ai-slop-cleaner <target> and add --review to perform a reviewer-only inspection.

Frequently Asked Questions about ai-slop-cleaner

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I safely remove AI-generated code bloat without changing behavior?▼

To remove AI-generated code bloat safely, lock behavior with focused regression tests first, then apply a deletion-first workflow to eliminate dead code, duplicates, and over-abstractions while preserving the original functionality.

What is the best way to clean up duplicated code left by AI edits?▼

The best way to clean up duplicated AI code is to run smell-focused passes that consolidate duplicates, improve naming, and reinforce error handling. Using a reviewer-only --review mode separates inspection from editing for safer consolidation.

How do I perform a code cleanup pass on only changed files?▼

You can perform a targeted code cleanup by applying the anti-slop pass to explicit file lists, changed-file scopes, or Ralph session changed files, limiting the risk and surface area to only the recently modified code.

Can I inspect AI code slop without automatically modifying the files?▼

Yes, you can inspect AI code slop without modifications by using the reviewer-only --review mode, which separates writer and reviewer responsibilities to surface dead code and over-abstractions for inspection before any deletion occurs.

Why should I write regression tests before deleting dead code?▼

Writing regression tests before deleting dead code locks the current behavior, ensuring that your deletion-first cleanup and duplicate consolidation do not introduce regressions or alter the working application's output.

Does ai-slop-cleaner require any external dependencies to run?▼

No, ai-slop-cleaner does not require any external dependencies to run. It operates directly on bounded file lists or Ralph session changed files to perform behavior-preserving cleanup and test reinforcement.