AI Slop patterns.
AI coding agents leave specific tells behind: comments that restate the next line, as any casts, swallowed errors, dead imports, todo stubs, generic variable names. We named them. aislop catches them deterministically — across 14 patterns, in 8 language targets, on every edit. Each pattern below links to an evidence-backed page with its rule id and provenance.
Narrative comment
A multi-line comment block that walks through what the function does in prose. The signature already says it; the prose is decorative.
View pattern →Trivial comment
A single-line comment that restates exactly what the next line of code does. Removing it changes nothing for the reader.
View pattern →Swallowed exception
A try/catch where the catch block is empty or only contains a comment — failures vanish silently with no log, no rethrow, no recovery.
View pattern →Unsafe type assertion
An `as any` cast — bypasses TypeScript's checker entirely. Every guarantee from the type system is gone for that value forward.
View pattern →Double type assertion
An `as unknown as X` cast — a double-cast escape hatch used when the compiler refuses a direct `as X`. Smuggles types through without validation.
View pattern →Unexplained TypeScript directive
A `@ts-ignore`, `@ts-expect-error`, or `@ts-nocheck` directive without a reason comment. Silences the type checker on that line forever.
View pattern →Orphan TODO stub
A `// TODO` without an owner, ticket, or completion plan. The kind that survives years.
View pattern →Generic naming
Variables and parameters named `data`, `result`, `value`, `temp`, `obj`, `info`, `item`. Names that say "this is a noun" without saying which noun.
View pattern →Unused import
An import that no remaining code references. Usually left over after a refactor or a deletion the agent forgot to follow through on.
View pattern →Console leftover
`console.log` (or `print`, in other languages) left in production code after debugging.
View pattern →Empty function
A function with no body — usually a placeholder the agent stubbed to make a signature compile and forgot to fill in.
View pattern →Unreachable code
Code after a `return`, `throw`, `break`, or `continue` that can never execute.
View pattern →Constant condition
An `if` or `while` whose condition is a constant — `if (true)`, `while (false)`, `if (1)` — leaving a dead branch in the source.
View pattern →Thin wrapper
A function that exists only to call another function with the same arguments — no transformation, no added value, just an extra layer.
View pattern →Score your repo.
One command. 0–100 score. Every pattern above, every change. Auto-fix what's mechanical, hand off the rest with full context.
npx aislop scan