slop-score
One repeatable RSI pass over CODE SLOP — the slop the compiler can't see. Runs the code-slop scorecard (tools/code_slop_scorecard.py), reads the slop-debt…
от anthony-chaudhary★ 50 звёзд на GitHub
Установить slop-score в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
/slop-score — make "less slop" provable, then prove it moved
An instance of the generic scorecard doctrine (read that for the five laws and the RSI loop). It is the slop sibling of
quality-score(classic defects: gofmt, vet, untested packages) andappeal-score(prose voice). Wherequality-scoregrades the slop the compiler andgo vetalready catch, this grades the slop they can't see: code that builds, vets clean, and has a test present, yet rots the kernel from the inside — copy-paste clones, tests that assert nothing, dead unexported symbols, commented-out cruft.
The shape: run the scorecard → read the slop-debt work-list → retire debt worst-first (genuine fixes only) → re-measure and prove the drop → regenerate the snapshot → DOS-witness the commit → commit ONLY your lane by explicit path.
The headline metric is slop-debt (corpus.slop_debt): the count of concrete,
re-derivable HARD defects across the slop axes, re-derived from disk every pass so it
can't drift or be talked past. Drive it toward zero and "less slop" becomes a number
you moved, not a claim you made. The epic that tracks the program is #775; Track A
(drive the debt down) is what this skill runs.
The measure (six axes — four HARD, two SOFT; deterministic, same tree → same score)
tools/code_slop_scorecard.py folds these into a slop_score (0–100, A–F) and the
slop_debt integer. HARD axes emit slop-debt (they gate ok); SOFT axes score
but never gate. ok is False iff any HARD defect exists.
| KPI | HARD/SOFT | one unit of slop-debt is… | the genuine fix |
|---|---|---|---|
duplication |
HARD | a normalized Go token-window copy-pasted into 2+ distinct sites | extract ONE shared helper both sites call (behavior-preserving) — #776 |
dead_code |
HARD | an unexported symbol defined but referenced nowhere else | delete it, or wire it if it has a real intended caller (e.g. cmdTraj into main.go) — #777 |
vacuous_tests |
HARD | a Test* func body that makes zero assertions |
add a real assertion that can actually FAIL on a regression — #778 |
comment_slop |
HARD | a tautological doc comment (// X does X) or a commented-out code block |
delete the cruft (NOT an honest // TODO/[STUB] marker — see anti-gaming) |
stub_masquerade |
SOFT | an exported func whose body is only return nil / panic("unimplemented") |
advisory only — the honest [STUB] ledger is a feature; promotion to HARD is #781 (gated on a multi-release zero-FP soak), not this pass |
churn_bloat |
SOFT | recent commits that ADD .go files without ever removing any (HEAD-relative) |
advisory trend over --range, not a tree defect; never gate it, never "fix" it by deleting files |
Benchmark* and Fuzz* funcs are not graded by vacuous_tests (a benchmark's job
is to time, not assert) — so never demote a Test to a Benchmark to dodge the axis.
Step 1 — Run the scorecard (it builds your work-list)
From the repo root:
python tools/code_slop_scorecard.py # human scorecard (per-KPI + work-list)
python tools/code_slop_scorecard.py --json # machine payload (the loop reads this)
It exits non-zero whenever slop-debt > 0 (this is the gate the epic wires fully at
zero, #779). Read corpus.score, corpus.slop_debt, and corpus.breakdown (per-KPI
debt, worst first). The per-KPI defects arrays ARE the work-list: each entry names the
exact files+lines of a clone group, a dead symbol, or a vacuous test.
The scorecard walks the working tree (rglob("*.go"), not git ls-files) so an
uncommitted change scores — re-measure reflects what's on disk right now. The committed
snapshot docs/CODE-SLOP-SCORECARD.md can read LOWER than a live run when HEAD has grown
since the snapshot was last regenerated; the live number is the truth, and Step 4
re-stamps the snapshot to match. Skip the Go toolchain probe (faster, static-only):
--no-toolchain. Tune the SOFT churn window: --range HEAD~40..HEAD.
Record the baseline. Before touching anything, write down slop_debt = N,
score = S, and the heaviest KPI. The whole point is to prove the delta, so you need
the before-number.
Step 2 — Retire slop-debt worst-first, using GENUINE fixes only
Attack the heaviest KPI first (corpus.breakdown[0]), but only via fixes that are safe
on a shared trunk and genuine (they improve the code, not just the number):
duplication(usually heaviest). For a named clone group, extract the shared body into ONE helper (a package-level func, or a small internal package if the sites span packages) and have every site call it. Keep behavior byte-identical. Most clones live in thecmd/*benchand demo mains (flag wiring,readHFConfig,writeFile, output blocks) — those are the high-count groups. Do ONE group per pass and validate hard (Step 3); a half-done extraction that c
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
- 01
Read - 02
Bash - 03
Write - 04
Edit - 05
Grep - 06
Glob
FAQ
Что делает скилл slop-score?
One repeatable RSI pass over CODE SLOP — the slop the compiler can't see. Runs the code-slop scorecard (tools/code_slop_scorecard.py), reads the slop-debt work-list, retires debt worst-first using ONLY genuine fixes (extract a copy-paste clone into a shared helper, delete or wire a dead unexported symbol, add a real assertion to a vacuous test, drop tautological doc comments + commented-out code), re-measures to PROVE the number dropped, regenerates the committed snapshot, grounds the ship in DOS (dos commit-audit on the new. Use when this named workflow matches the task.
Как установить скилл slop-score?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл slop-score запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
doc-coauthoring
AnthropicGuide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
academy-guide
AnthropicStop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
internal-comms
AnthropicA set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
skill-development
AnthropicThis skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…