unslop
GitHub用于代码提交前的清理审查,自动识别并移除LLM生成的冗余抽象、防御性代码、无意义注释及低效React钩子等“噪音”,在保持行为不变的前提下提升代码简洁度与质量。
Trigger Scenarios
Install
npx skills add nodetool-ai/nodetool --skill unslop -g -y
SKILL.md
Frontmatter
{
"name": "unslop",
"description": "Remove unnecessary abstractions, defensive code, comments, or prose from a requested diff or files. Preserve behavior and repository rules."
}
Unslop
A pre-commit pass that removes patterns LLMs add reflexively but humans wouldn't write. Apply it to the requested diff or files. The goal isn't to shorten the diff — it's to delete code whose absence would not be missed.
This skill complements (does not replace) AGENTS.md and web/src/components/ui_primitives/STRATEGY.md. Those define the rules. This skill defines the patterns to actively hunt and remove.
Unslop is a quality pass, not a bug hunt. For correctness review of a diff, branch, or PR — including the NodeTool-specific landmines — use code-review; a full pre-merge pass runs both.
How to use
- After making changes, run
git diffand read every added line through the lenses below. - For each "slop" you find, delete or rewrite it. Don't leave a
// removed Xcomment behind. - Complete mandatory post-change verification for code edits. For prose-only edits, check affected links and formatting. Reuse valid results for unchanged files.
- When deleting an abstraction, remove unused types and exports. Preserve behavior coverage by moving useful tests to the surviving public interface.
Pattern reference
Read patterns.md for the languages and frameworks in the diff. Repository rules take precedence over these cleanup heuristics.
Self-review checklist
Use the relevant questions to inspect the requested diff. Verify each concern against the repository rules before changing code.
- Did I add a comment that restates the code, names the PR, or describes a removed feature?
- Did I add a
try/catchwhose error path can't actually trigger here? - Did I write
any,as any, oras unknown asto silence the compiler? - Did I add
useEffectto compute a value from props/state I already have? - Did I
useCallback/useMemo/React.memowithout a memoized consumer or measurable cost? - Did I subscribe to a whole Zustand store (
const s = useFooStore()) or skipuseShallowon a multi-key selector? - Did I import a raw MUI component into a non-primitive file, or hardcode a color, spacing, radius, font size, or transition?
- Did I write a
useEffect+fetchinstead ofuseQuery? - Does any new test assert implementation rather than user-visible behavior?
- Are there
// TODO,// removed,// added by, or "useful elsewhere" leftovers? - Could three near-identical lines have been left as-is instead of becoming a helper?
- Does my prose contain any banned openers or filler ("delve", "robust", "seamlessly", "Here's the thing")?
- Have I left any required verification incomplete?
Report the concrete removals and verification results. A checklist alone does not establish correctness.
Sources
Patterns synthesized from these community skills, adapted to NodeTool's stack:
- theclaymethod/unslop — humanizing AI-generated prose
- hardikpandya/stop-slop — banned phrases and structural red flags
- jalaalrd/anti-ai-slop-writing — banned-word and banned-pattern catalog
- anthropics/skills/frontend-design — anti-generic-aesthetic principles
- vercel-labs/agent-skills/composition-patterns — composition over boolean-prop proliferation
- vercel-labs/agent-skills/react-best-practices — React/Next performance rules
- awesome-skills/code-review-skill — React 19 / TypeScript review patterns
- NodeTool's own
AGENTS.mdandSTRATEGY.md
Version History
- 9b979bc Current 2026-09-22 23:26


