architecture-simplification

architecture-simplification is a skill for Claude Code, Codex from yeaight7/agent-powerups. It costs 31 tokens per session (523 once invoked), scanned A, original, Apache-2.0.

A code-review aid for finding unnecessary abstractions, layers, and repeated logic in a codebase without changing its behavior.

In plain words
What is it for?
Use it to assess abstraction costs, combine equivalent code paths, inline simple logic, remove dead code, and verify the result with tests.
Why use it?
It helps reduce code that is harder to understand and maintain because of wrappers, interfaces, factories, or duplicate paths that add little value.

Skill for Claude CodeCodex

Part of the codebase-maintenance plugin — 8 skills, 4 commands, 3 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/yeaight7/agent-powerups/architecture-simplification
Any agent
npx skills add yeaight7/agent-powerups --skill architecture-simplification
Clone the repo
git clone --depth 1 https://github.com/yeaight7/agent-powerups

Made for: Claude Code, Codex.

Or install codebase-maintenance, the plugin that ships this one along with the rest of its 8 skills, 4 commands, 3 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for architecture-simplification

README.md
[![agentmods](https://agentmods.dev/badge/skills/yeaight7/agent-powerups/architecture-simplification.svg)](https://agentmods.dev/skills/yeaight7/agent-powerups/architecture-simplification)
Your own site
<a href="https://agentmods.dev/skills/yeaight7/agent-powerups/architecture-simplification"><img src="https://agentmods.dev/badge/skills/yeaight7/agent-powerups/architecture-simplification.svg" alt="Measured on agentmods" height="20"></a>
Per session 31 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 523 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00031 $0.00523
Opus 5 $0.00015 $0.00262
Sonnet 5 $0.00006 $0.00105
Haiku 4.5 $0.00003 $0.00052

Measured 5d ago against content hash 6ee9efda8da5, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

architecture-simplification scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/codebase-maintenance/skills/architecture-simplification/SKILL.md · 57 lines

How it starts

The opening of the file, as written. The whole thing — 57 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Purpose

Over time, codebases accumulate "just in case" abstractions. This skill guides the safe removal of unnecessary complexity: remove the noise around the core logic without changing the core logic itself.

When to Use

  • An interface has only one implementation and no second one is planned
  • A wrapper, factory, or layer only passes arguments straight through
  • Two code paths do the same thing and should be consolidated

Inputs

  • The suspect abstraction(s) and their call sites
  • A green test suite covering the affected area

Workflow

  1. Identify the abstraction cost. Does this interface have only one implementation? Does this wrapper class just pass arguments straight through? Measure before cutting:

    grep -rn "implements IUserRepository" src/    # count implementations
    grep -rn "IUserRepository" src/ | wc -l       # count references
    
  2. Run the tests first. The affected area must be green before any removal — this is the behavioral baseline.

  3. Inline the logic. Move the logic from the unnecessary abstraction directly into the caller.

  4. Delete the dead code. Remove the interface, wrapper, or factory that is no longer needed.

  5. Test verification. Re-run the same tests; the observable behavior of the system must not have changed.

Example: if a UserRepository implements IUserRepository but there is only ever one database, inline UserRepository and delete IUserRepository.

Output

  • The simplified code with the abstraction removed
  • Before/after test evidence showing unchanged behavior

Verification

  • Tests covering the area were green before the change (baseline)
  • Same tests green after the change — observable behavior preserved
  • No references to the removed abstraction remain (searched, not assumed)
  • Diff contains only removal/inlining — no core-logic rewrites

Failure Modes

  • Rewrite disguised as simplification — do not rewrite the entire subsystem; simplification removes the noise around the core logic, not the logic itself.
  • Cutting without a baseline — without a green pre-change test run, "tests pass after" proves nothing.
  • Speculative retention — keeping the interface "in case we need it later" recreates the original problem.

Read the full file on GitHub · 57 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 57 lines · 31 tokens per session scan A 6ee9efda8da5

Subscribe to this mod's changes

architecture-simplification is a skill published in the GitHub repository yeaight7/agent-powerups (6 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 31 tokens to every session and 523 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.