Hooks, abstract base classes, configuration knobs, and parameters added 'in case the team needs them' — but no real call site uses them.
Abstract base classes, hooks, configuration knobs, or parameters with no real call site exercising them — the agent must learn vocabulary it never gets to use.
The code expresses exactly what it does today — abstraction earns its keep when a real second user shows up.
The code expresses exactly what it does today; the agent's mental model has no concepts that don't correspond to active behavior.
Smellier version
class Strategy { execute() {} }class OnlyStrategy extends Strategy { execute() { /* the real one */ } }new OnlyStrategy().execute();
Fresher version
function execute() {// the real one}execute();
Tests are forced to cover branches no one exercises; readers learn a vocabulary they don't need; YAGNI debt compounds.
Tests cover branches no one exercises; readers (human and agent) learn dead vocabulary; refactoring proposals must consider phantom users that aren't real.
Removing the unused abstraction can break a real (if rare) future need; YAGNI is a useful default, but historical context sometimes justifies the option-value.
Removing speculative scaffolding is sometimes a real loss — the abstraction may document a coming feature or a deliberately-preserved seam; the agent collapsing it must verify no current or imminent caller relies on the option.
Smaller surface, fewer concepts, fewer test branches.
Smaller surface; fewer concepts the agent must hold in its reasoning context; tests align with actual behavior so green tests mean live coverage.
Aggressive removal of every unused hook on principle — including ones that document a known coming feature or a stable boundary the team agreed to preserve.
Collapsing every unused hook on sight removes options the team had reason to hold; the agent must judge intent before deleting, or risk shipping cleanups the maintainers reject.