Sandbox
@MrZoyo/deslop-GPT

Deletion-first agent skill for Claude Code and Codex

deslop is a cleanup skill that looks for repeated tests, producer-checking-producer loops, and fallback chains that no longer protect a real contract. It uses evidence chains to decide what can go, and keeps behavior that still has an independent caller, protocol, trust boundary, or persistence boundary.

125 stars0 forksPythonUpdated 13d ago
Who it's for

Builders who want Claude Code or Codex to remove accumulated slop without deleting real behavior.

What it delivers

You can shrink noisy test and fallback layers while keeping the behavior that still matters.

What it does

Evidence-backed cleanup

Audits code with justification chains instead of deleting by smell alone.

Read-only by default

Runs in audit mode unless the user explicitly authorizes apply.

Behavior-preserving subtraction

Keeps real success, failure, edge-case, and boundary behavior while removing redundant machinery.

Host support for Claude Code and Codex

Ships a shared Skill payload plus Claude Code plugin metadata.

Evaluation and field-trial records

Includes focused evals, runtime controls, and real-world cleanup cases.

How to get it

  1. 1Invoke the bundled installer with this GitHub Skill URL
    $skill-installer
    Install the Skill from:
    https://github.com/MrZoyo/deslop-GPT/tree/v0.3.2/skills/deslop
  2. 2For a reviewable local checkout, symlink the runtime directory into Codex's canonical…
    git clone --branch v0.3.2 --depth 1 https://github.com/MrZoyo/deslop-GPT.git "$HOME/.local/share/deslop-GPT"
    mkdir -p "$HOME/.agents/skills"
    ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.agents/skills/deslop"
  3. 3Inside Claude Code, add this repository as a marketplace and install the Plugin
    /plugin marketplace add MrZoyo/deslop-GPT
    /plugin install deslop@deslop
  4. 4The same released runtime payload can be linked into each host's user Skill directory
    mkdir -p "$HOME/.agents/skills" "$HOME/.claude/skills"
    ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.agents/skills/deslop"
    ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.claude/skills/deslop"

README

deslop — deletion-first cleanup for agent-maintained codebases

deslop

A deletion-first Agent Skill for agent-maintained codebases

简体中文 · English

Evidence-backed cleanup that reduces accumulated machinery while preserving real behavior.

Validate workflow MIT license Codex and Claude Code compatible Agent Skill Read-only by default Manually adjudicated field trial

deslop audits and, when explicitly authorized, removes complexity accumulated through repeated coding-agent implementation and correction cycles. Those cycles often leave overlapping regression tests, producer-verifies-producer checks, and fallback layers that hide failures instead of handling a current contract.

This is semantic subtraction, not source beautification. deslop is not a formatter, style humanizer, test-count minimizer, blanket ban on defensive code, or automatic permission to edit a repository. It follows justification chains to independent evidence and preserves behavior whose contract remains real or uncertain.

Reduce test surface, not behavior surface.

What it targets

The percentages below are design priorities, not measured prevalence.

PriorityTargetQuestion
~50%Test-suite bloatDoes each test protect a distinct failure domain with a current owner and an independent oracle?
~25%Verification theaterCan the verifier fail independently from the producer, or do both share the same information and failure domain?
~25%Defensive / fallback bloatDoes the recovery path implement a current contract, or merely mask an unexpected internal error?

Generic dead code, wrappers, abstractions, and comments are secondary. They matter only when they belong to one of these clusters or have direct high-confidence deletion evidence.

Subtract machinery. Preserve behavior.

RemovePreserve
Self-justifying or duplicate testsDistinct success, rejection, error, and edge-case behavior
Checksums, receipts, or validators with no independent consumerPersistence and corruption checks across a real failure boundary
Speculative or obsolete fallback chainsSupported compatibility and documented protocol behavior
Repeated defenses inside trusted call graphsReal handling at external and untrusted boundaries
Wrapper/test clusters with no independent purposeSecurity, transactions, concurrency, resource, and scientific invariants

Resemblance to a smell is a lead, not a verdict. Security and trust boundaries, supported callers, persisted formats, and numerical constraints are preserved by default when evidence is incomplete.

Quick Start

Codex: install v0.3.2 as a standalone Skill

Invoke the bundled installer with this GitHub Skill URL:

$skill-installer
Install the Skill from:
https://github.com/MrZoyo/deslop-GPT/tree/v0.3.2/skills/deslop

For a reviewable local checkout, symlink the runtime directory into Codex's canonical user Skill location:

git clone --branch v0.3.2 --depth 1 https://github.com/MrZoyo/deslop-GPT.git "$HOME/.local/share/deslop-GPT"
mkdir -p "$HOME/.agents/skills"
ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.agents/skills/deslop"

Codex supports symlinked Skill directories and detects changes automatically. The tagged v0.3.2 path is the current released, pinned standalone Skill; main is the development branch and may contain unreleased changes.

Claude Code: install the Plugin from GitHub

Inside Claude Code, add this repository as a marketplace and install the Plugin:

/plugin marketplace add MrZoyo/deslop-GPT
/plugin install deslop@deslop

The canonical Plugin command is /deslop:deslop. For a local checkout, load the repository directly with claude --plugin-dir . from the repository root. The marketplace catalog is read from main, but its Plugin source uses an explicit HTTPS Git URL pinned to the v0.3.2 tag and release commit 0cc15c036b07691c600bda1219b8cc5c197ca3f1. This patch release makes missing-evidence limits explicit in the closed-loop rule. The v0.3.1 evaluation evidence remains tied to its exact released payload.

One checkout, standalone discovery on both hosts

The same released runtime payload can be linked into each host's user Skill directory:

mkdir -p "$HOME/.agents/skills" "$HOME/.claude/skills"
ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.agents/skills/deslop"
ln -s "$HOME/.local/share/deslop-GPT/skills/deslop" "$HOME/.claude/skills/deslop"

Use only the link for the host you need, and run each ln command only when its destination does not already exist. A standalone Claude Code installation invokes the Skill as /deslop. See Getting Started for installation scope, v0.1.0 migration, updates, removal, and a safer review-first workflow. deslop is an independent community project, not an OpenAI or Anthropic product.

Distribution status

The shared skills/deslop/ payload follows the open Agent Skills structure and is used unchanged by Codex and Claude Code. .claude-plugin/plugin.json and .claude-plugin/marketplace.json provide Claude Code packaging. Codex Plugin distribution remains withheld because the tested Codex host installed and cached a Skills-only Plugin without registering its bundled Skill; Codex standalone installation remains supported. See the distribution compatibility note.

Invoke it explicitly

Host and distributionCommand name
Codex standalone Skill$deslop
Claude Code standalone Skill/deslop
Claude Code Plugin/deslop:deslop

Append the same mode and scope arguments to the command name for each host:

ArgumentsEffect
noneRead-only audit of the established scope
auditExplicit read-only audit
applyApply reviewed cleanup within scope
tests applyPrioritize test signal and mutual-support test/code clusters
current branch applyClean current work relative to its actual merge base
deepRepository-wide read-only audit
deep applyRepository-wide cleanup without redesign

Only apply authorizes edits. Staging, commits, pushes, branch changes, resets, and fetching still require separate permission.

Example workflow

Start with evidence, not edits:

$deslop deep

HIGH
- two fallback layers handle the same internal parse failure;
  current callers and history show no supported legacy input
- a local receipt is produced and verified by the same workflow;
  no external consumer or persisted trust boundary exists

PRESERVE
- a persisted readback detects truncated output across a write/read boundary
- a compatibility branch is required by a documented external protocol

Review each evidence chain and preservation decision. Apply only the supported scope:

$deslop deep apply

The example is schematic; it does not represent a benchmark fixture or performance claim.

How deslop decides

  • Independent evidence roots: current requirements, real callers, public contracts, protocols, trust boundaries, persistence boundaries, or scientific invariants.
  • Closed justification loops: production code and tests do not become necessary merely by justifying each other.
  • Production reachability and edge closure: prove the current input-to-consumer path, not only isolated callers or test-injected branches.
  • Production/test asymmetry: redundant test evidence can be removed without deleting the behavior it observes.
  • Fail-visible bias: unexpected internal failures should surface unless a concrete recovery or translation contract exists.
  • Subtraction without redesign: dependencies, abstractions, wrappers, compatibility layers, and replacement scaffolding have a default budget of zero.

The full decision model is documented in Design. The self-contained runtime SKILL.md remains authoritative for agent behavior.

Safety model

Codex enforces explicit invocation through allow_implicit_invocation: false. Claude Code does not read that OpenAI-specific metadata; the shared standards-compatible frontmatter instead tells Claude to invoke deslop explicitly. Claude Code may still select the Skill from its description — a 2026-09-03 control run recorded it doing exactly that — but such an invocation remains read-only unless the user includes apply. Default and audit modes are read-only, and suspicious constructs can be recorded as deliberate preservation decisions. Code is not removable merely because it looks defensive, was written by an agent, or has a test that could be deleted.

Read-only verification should redirect caches or generated output when practical and disclose incidental residue. Apply authorization permits scoped edits; it does not resolve uncertainty in favor of deletion. See Getting Started for the review sequence and Design for confidence classes and preserved boundaries.

Evidence

Validation status

Runtime payloadHost and pathRunsWhat it establishes
v0.3.2 candidate exact hashCodex collaboration subagents, gpt-5.6-sol with high reasoning, direct Skill loading4 selected dev-v2 cases, 2 runs per payload and case, 16 callsv0.3.2 passed 8/8 versus v0.3.1 at 7/8; t02b was 2/2 versus 1/2, while all 12 deletion-case runs passed
v0.3.1 release payload hashClaude Code 2.1.259 CLI, Haiku 4.5, .claude/skills discovery3 runtime controls, 1 run each, no baselineClaude selected the Skill from its description alone and still stayed read-only; a question asking for no cleanup did not pull it in
v0.3.1 release payload hashClaude Code 2.1.259 CLI, Haiku 4.5, .claude/skills discovery5 dev-v2 micro cases, 3 apply runs each, no baseline12 of 15 runs passed every hidden gate; t02b lost its supported legacy header path in 2 of 3 runs
v0.3.1 release payload, pre-release exact hashCodex subagents loading the Skill by path1 default audit plus t02b and t03b preservation casesNarrow development regression smoke; all three left fixture content unchanged
v0.3.1 tagged PluginClaude Code 2.1.259, isolated config and remote main catalog1 marketplace installation, no model callRemote HTTPS source resolved the v0.3.1 tag to commit a19128d; installed version and runtime hash matched
v0.3.0, exact release hashCodex subagents loading the Skill by path3 mini-repository apply runs plus 1 auditAll three cleaned artifacts passed hidden behavior, reduction, and negative-change gates; no CLI discovery or baseline evidence
v0.3.0, exact release hashClaude Code 2.1.259 local Plugin, Haiku 4.51 audit plus 1 applyPlugin loading and one valid cleanup artifact; apply stopped at its turn ceiling before the final report
Earlier development payloadsCodex CLI 0.149.1, gpt-5.6-solrc3 micro, rc4 mini, and targeted rc5 diagnosticsHistorical development evidence tied only to those payload hashes

Version-bound forward smokes are published under evals/release-smoke/. The 2026-09-04 cross-version smoke is the v0.3.2 release gate; it uses known cases and two runs per payload, so it supports only the narrow release decision recorded above. The earlier Claude Code CLI runs remain under evals/runtime-controls/results/ and evals/dev-v2-focused/results/. Those Haiku runs exposed the t02b ambiguity but remain secondary host diagnostics, not target-model release evidence. None of these records is held-out model-effect evidence. The older rc3 micro pilot measured 63.1% more total tokens and 16.5% more wall time with its then-current Skill; that one-run result does not predict v0.3.x cost, but it supports using deslop for deliberate accumulated-slop work rather than routine tiny diffs.

Focused development evaluation

dev-v2-focused tests preservation and simplification decisions across paired micro cases and three end-to-end miniature repositories. Behavior gates run before reduction metrics. Micro and mini-repository results remain separate, and the repository publishes no project-level performance score.

The follow-up dev-v3-evidence-edges draft records 19 anonymized field observations and implements 7 new executable pairs. It is validated as a draft, not reported as model-performance evidence.

See Evaluation for interpretation limits and evals/README.md for the canonical protocol.

Real-world field trials

CaseMethodStatus
cluster-gpu-monitorReal repository; read-only audit, human adjudication, then two reviewed cleanup batchesFrozen historical evidence

The first field trial records both accepted cleanups and deliberate preservation decisions with public before/after provenance. It had no independent baseline run from the same frozen state, so it is not a controlled A/B comparison and does not establish general superiority, 100% precision, or production-proven correctness.

Future cases can be added without becoming Skill-tuning inputs; see Field Trials.

Documentation

DocumentPurpose
Documentation indexChoose a user, design, evidence, or development path
Getting StartedInstallation, invocation modes, scopes, updates, and safe workflows
DesignEvidence roots, closed loops, preservation, and subtraction principles
EvaluationFocused corpus, hard gates, run discipline, and interpretation limits
Field TrialsReal-world methodology, provenance, isolation, and case registry
DevelopmentRepository layout, validation, contribution, and release boundaries

Repository structure

.claude-plugin/                 Claude Code Plugin and marketplace metadata
skills/deslop/                   Self-contained runtime Skill payload
docs/                            User, design, evidence, and development guides
evals/dev-v2-focused/            Active focused development evaluation
evals/dev-v3-evidence-edges/     Follow-up evidence-edge draft
evals/runtime-controls/          Authorization and host/runtime controls
evals/release-smoke/             Version-bound forward-smoke records
evals/real-world/                Manually adjudicated real-world evidence
evals/archive/                   Retired historical evaluation material
scripts/                         Validation and evaluation tooling
assets/                          README and project presentation assets

Project status and contributing

Public releases use semantic versioning, beginning with v0.1.0. A 0.x release is usable but still evolving; it is not a stable, production-ready, or 1.0-quality claim. Immutable Git tags identify released runtime and distribution states. Benchmark candidates retain their separate evaluation tags.

The most useful contribution is an evidence-backed case with a nearby preservation counterexample and an independent behavioral oracle—not an isolated snippet that merely looks verbose. Read Development before proposing a Skill policy or evaluation change.

License

MIT

Files in the repo

Repository payload11 top-level entries
  • .claude-plugin
  • .github
  • assets
  • docs
  • evals
  • scripts
  • skills
  • .gitignore
  • LICENSE
  • README.md
  • README.zh-CN.md

Discussion (0)

Ask about usage, or say what you built with it

Sign in to join the discussion.

No comments yet. Be the first to say what this is good for.

More skills

obra/
superpowers

An agentic skills framework & software development methodology that works.

285k
1 add

Turn any codebase, with its docs, SQL schemas, configs, and PDFs, into a queryable knowledge graph. A /graphify skill for Claude Code, Cursor, Codex, and Gemini CLI: local deterministic AST parsing, every edge explained, no vector store.

117k
1 add
Vincentwei1021/
anything2explainer

Topic in, narrated explainer video out. A Claude Code / Codex skill that turns any topic into a black-canvas motion-graphics explainer video with TTS voiceover, subtitles and a chapter progress bar. Chinese or English; every frame drawn in code with Remotion.

666

Open-source AI job search: scan job portals, evaluate listings into a structured A-H report with a global 1-5 score, tailor your CV, track applications — runs locally in your AI coding CLI (Claude Code, Codex, OpenCode, Antigravity…)

71k