DevToolsAICode QualityProductivity

Agent Cleanup Janitor

Automatically remove abandoned code and data structures after AI coding agents change direction

Problem
A common failure mode across coding agents: when an implementation hits a problem, the agent writes a replacement; if the overall approach changes, it starts a new path; if only a detail is off, it adds yet another helper or class. What it rarely does is remove the code and data definitions added for the abandoned approach, so dead code piles up across sessions.
Solution
Watch the git diff and workspace changes of an agent session, use a lightweight analyzer to flag newly added symbols, classes, and helpers that no existing path references as "abandoned candidates," produce a per-item reviewable cleanup list, and after user confirmation delete them and hand the action back to the originating agent for logging.
Users
Indie developers and small teams who heavily use Claude Code / Cursor / Codex
MVP
Parse the current repo's git diff and identify symbols added this session but never referenced; use AST static analysis to find orphan functions/classes/imports; generate a diff preview applied to the workspace with one click; keep a rollbackable cleanup log; support only Python + TypeScript at first.
Revenue
Subscription: $8/mo individual, $25/seat/mo team; or sell as a yearly-license VS Code / JetBrains plugin.
Why now
Agentic coding is now a mainstream workflow, yet tooling focuses on generation, not cleanup. Post-pivot code hygiene is almost untouched, and this can be built fully locally, making it a good fit for an indie developer.

Source discussions · 2

  1. Hacker NewsAsk HN: How do you get coding agents to clean up after changing direction?3↑ 1
  2. V2EX[程序员] 我要再次发出暴论, AGI 离我们还很遥远。0↑ 21
← Back to list