Skip to content

Guide · Agent skill

How to use the Code Comment Cleanup skill (antislop-code)

Updated · written with AI from the project's own documentation and checked against our catalogue data

antislop-code is an agent skill for AI coding assistants that cleans up code comments. It targets filler that reads as machine-written, such as decorative banners, comments that restate the code, step-by-step narration, vague TODOs and emoji, and it keeps comments that carry real information. This guide explains what the skill does, how to install it, how to ask for it in plain language, and where it should not be used.

Code Comment Cleanupmiqdadbadjuber/anti-slop · MIT

Quick start

  1. 1Download the ZIP. Download the antislop-code skill ZIP from this page and unzip it on your computer.
  2. 2Place the skill folder. Move the skill folder into ~/.claude/skills/ for personal use, or into .claude/skills/ inside your project.
  3. 3Or upload it in the Claude apps. In the Claude apps, open Settings, go to Capabilities, then Skills, and upload the skill.
  4. 4Add antislop.md. Obtain the companion antislop.md core file, which the skill references and which is not included in the files provided.
  5. 5Ask in plain words. Ask the agent to clean up comments in a named file, and state what you want kept, then review the diff.

What the antislop-code skill makes the agent do

When an AI coding agent writes or edits comments, this skill tells it to filter out comments that read as generically AI-written. Its rules cover decorative separators, restated obvious code, workflow narration, empty labels, vague placeholders, signature echoes, decorative emoji and end markers. It also covers over-long comments and stiff or loud wording.

The skill also tells the agent what to keep. Comments explaining business logic, architectural decisions, security considerations, performance trade-offs, concurrency behaviour, protocol details, API contracts, workarounds, edge cases, assumptions and licensing notices should stay. The skill is restricted to comments: it is told never to modify executable code, identifiers, imports, formatting, indentation, whitespace, control flow or logic. When in doubt, it leaves the code alone.

  • Removes banner comments built from repeated characters or ALL CAPS labels
  • Removes comments that repeat the next line, such as a comment saying Initialize the variable above a variable declaration
  • Removes step-numbered narration and generic labels like Main logic
  • Shortens over-explained comments to one or two lines
  • Keeps comments that explain why, not what

Install the antislop-code skill

Download the ZIP of the skill from this page and unzip it. Place the skill folder in one of two locations. For a personal setup, use ~/.claude/skills/. For a single project, use the .claude/skills/ folder inside that project.

If you use the Claude apps instead, open Settings, go to Capabilities, then Skills, and upload the skill there.

  • Personal install: ~/.claude/skills/
  • Project install: .claude/skills/ inside your project folder
  • Claude apps: Settings → Capabilities → Skills, then upload

Add the companion antislop.md core file

The SKILL.md file refers to a companion core file called antislop.md, and it relies on a Delivery Gate defined in that core. The core file is not included in the files this skill provides. The skill says to load it together with antislop.md whenever a task touches code comments.

Without antislop.md, the skill's rules still describe the comment patterns, but the core mechanism (the purpose test, the three tiers and the Delivery Gate) is missing. Obtain the core file and install it alongside this skill before relying on the results.

Trigger the skill with natural requests

You do not need a special command. The skill is meant to load when the task writes or edits code comments, so describe that task in ordinary words. Name the file or code you want cleaned, and say what you want from the comments.

Requests that match the skill's purpose include asking the agent to tidy the comments in a file, remove filler comments from code it just generated, or review its comments before you commit. Say explicitly if you want useful comments kept as they are.

  • Clean up the comments in src/checkout.js, keep anything about business rules or security
  • Remove decorative banners and restating comments from the auth module
  • Review the comments the agent just wrote and cut the filler, but do not change any code
  • Shorten the over-long comments in this file to one or two lines each

Example: what changes and what stays

The skill removes comments that restate the code and keeps comments that explain a non-obvious rule. The first example below is a comment the skill would remove. The second is a pair of comments it would keep, taken from the skill's own example of content that must stay.

  • Removed: a comment that says Initialize the variable above a declaration of a count variable set to zero
  • Replaced: a banner like a line of equals signs around the word Authentication becomes one plain line, or is removed if the label adds nothing
  • Kept: explanations of retry behaviour and duplicate handling for webhook events
// Stripe may retry webhook deliveries for up to three days. // Ignore duplicate events using the event ID.

Safety notes: scripts, network and file writes

This skill runs no scripts and uses no network access, according to its listing. Its allowed tools are Read, Write, Edit, Glob and Grep. It does not need to run commands to do its job.

The skill does write to files. It edits source files in place. The edits are limited to comments, but they are still writes, so do not use it where the agent must not touch files at all. Review the diff before committing, and check the skill's rules first if your codebase depends on specific comment formats that tools parse, because the skill may remove comments those tools expect.

  • Runs scripts: no
  • Uses network: no
  • Edits files in place: yes, comments only
  • Check first: comment formats read by tools or linters

Tips for getting good results

Run the skill on one file or module at a time so the diff is easy to review. Keep version control clean before the run so you can revert any change you do not want. Use the skill as a second pass after the agent writes code, and ask it to leave executable code alone in your request as well.

If a comment was legitimately valuable but got shortened, the skill's guidance says to keep the constraint itself in one line rather than the full history. Consider reviewing any comment that cites issue numbers or version history before accepting the change.

  • Work on one file or module per run
  • Commit or stash your work first so changes are easy to revert
  • Review the diff before merging
  • Check tool-parsed annotations before accepting removals

What people use it for

  • Tidying comments in AI-generated code before a pull request
  • Removing decorative banners and restating comments from a legacy module
  • Keeping a consistent comment style across code an agent produces for a team
  • Shortening over-long comments while preserving security and edge-case notes

Frequently asked questions

How do I install the antislop-code skill?

Download the ZIP from this page and unzip it into ~/.claude/skills/ for personal use, or into .claude/skills/ inside a project. In the Claude apps, you can instead upload it under Settings, Capabilities, then Skills.

Does antislop-code need anything else to work?

Yes. The SKILL.md refers to a companion core file, antislop.md, and to a Delivery Gate defined in it. Those files are not included in the files provided, so you need to obtain antislop.md separately. The skill also needs an agent that can read and edit files, such as Claude Code.

Is antislop-code free?

The skill is listed under the MIT licence. The licence terms are the authoritative source for what you may do with it. This page does not state any price.

Does the skill run scripts or access the internet?

According to its listing, it runs no scripts and uses no network access. It edits comment text in source files, which is a file write, so it is not suitable where an agent must not touch files.

Will antislop-code change my code or just the comments?

Its rules restrict it to comments. The skill is told never to modify executable code, identifiers, imports, formatting, whitespace, control flow or logic. Still, review the diff before committing, because comment edits are real file changes.

Can I use this instead of other comment or linting tools?

This page does not compare antislop-code with other tools. It is best suited to cleaning up filler in comments written by an agent. Do not use it where tools depend on specific comment formats unless you have checked the rules first.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

antislop-code suits developers who review AI-generated code and want leaner, more useful comments, and teams that want one comment style across agent output. Skip it if the agent must never write to your files, if your tooling parses specific comment annotations, or if you cannot obtain the antislop.md core file it depends on.

Download the skill