A Claude Code skill that detects and strips AI-slop in source code — the machine-authorship fingerprint (redundant comments, defensive bloat, one-implementation abstractions, generic names, banner comments, emoji-in-code, copy-paste blocks) — without changing behavior. Ships a deterministic 0–100 human-code scanner across JS/TS, Python, Go, Rust, Java, PHP.
Original work by ForgePlan, MIT. The code sibling of slopocop
(text) and slopocop-design (design). Also available as a full plugin (commands + reviewer agent)
via the ForgePlan marketplace.
# Global (recommended):
npx skills add ForgePlan/slopocop-code -g
# Project-only:
npx skills add ForgePlan/slopocop-codeThe skill installs as code-slop and is auto-loaded by Claude when de-slopping or auditing code.
code-slopknowledge base — ~35 AI-code tells (grouped A–F) + per-language idiom baselines so idiomatic Goif err != niland RustResult/matchare never flagged as slop.scripts/scan_code.py— a dependency-free (pure Python 3, no packages) 0–100 human-code scanner over 10 metrics. Exits non-zero below score 60 → drop it into pre-commit or CI.
python3 scripts/scan_code.py path/to/file.py # human-readable report
python3 scripts/scan_code.py path/to/dir --json # machine-readable, for CI
python3 scripts/tests/test_scan.py # regression (6 languages)- Bands: ≥85 clean · 60–84 spot-fix · <60 rewrite.
code-slop targets the machine-generated fingerprint, not correctness. A fully correct, fast
function can still be pure slop (over-commented, over-abstracted, generic-named) — this flags it.
For bugs use a code reviewer; for general quality, a simplifier.
MIT © ForgePlan. This is original work. Mirror of the code-slop skill in
ForgePlan/marketplace (plugins/slopocop-code) —
kept in sync automatically.