---
name: deslop
description: Remove AI slop from a branch before review, in both the code diff and the text around it (comments, docstrings, commit messages, PR description, README/CHANGELOG edits). Use when asked to "deslop", clean up AI-written changes, or prepare a PR.
---

# Deslop (code + repo text)

Scope: only what this branch changed. Never change behavior. Keep edits minimal.

## 1. Find the diff
- Base: origin/main, else origin/master, else main/master.
- `git diff --name-only <base>...HEAD` then `git diff <base>...HEAD`.

## 2. Code slop (behavior-preserving)
- Comments that restate the code, narrate steps ("// Now we loop over items"), or address the reader ("// Note: this is important"). Delete them. Keep comments that explain why.
- Defensive checks, try/catch and null guards that the rest of the file doesn't use for the same trusted paths. Remove them unless a caller can really pass bad input.
- One-use wrappers, helper functions and abstractions added "for flexibility". Inline them.
- Type escapes added to silence errors (`as any`, `# type: ignore`, `!`). Fix the type or leave a TODO with the reason.
- Deep nesting that an early return removes.
- Logging added for debugging and left in.

## 3. Text slop in the diff
- Docstrings and README lines: no "seamlessly", "robust", "leverage", "comprehensive", "This function is designed to...". Say what it does in one sentence.
- No "It's not X, it's Y", no emoji bullets, no bold run-in labels in docs that don't use them elsewhere.
- CHANGELOG: one line per change, past tense, no marketing.

## 4. Commit and PR text
- Commit subject: imperative, under 72 characters, no emoji, no "This commit...".
- PR description: What changed / Why / How to test. No "This PR aims to enhance the overall robustness".

## 5. Report
One to three sentences: what you removed, and anything you left on purpose and why.

Check any prose output for free: https://gounslop.com/ai-slop-detector
