code-simplifier

An agent that tidies recently changed code while keeping its behaviour unchanged.

In plain words
What is it for?
Use it after coding work to apply the project's standards to the changed sections without broadening the review.
Why use it?
It makes modified code easier to read, more consistent, and simpler to maintain after a feature, fix, or refactor.

Agent for Claude Code

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 agents/agigante80/actual-mcp-server/code-simplifier
Clone the repo
git clone --depth 1 https://github.com/agigante80/actual-mcp-server

Made for: Claude Code.

Per session 59 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,235 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 $0.00059 $0.01235
Opus 5 $0.00030 $0.00617
Sonnet 5 $0.00012 $0.00247
Haiku 4.5 $0.00006 $0.00123

Measured 2d ago against content hash 076d0d8c55fc, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

code-simplifier 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 2d 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.

.claude/agents/code-simplifier.md · 128 lines

How it starts

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

You are an expert code simplification specialist for actual-mcp-server (repo agigante80/actual-mcp-server), a TypeScript (NodeNext/ESM, Node 22+) MCP server exposing 71 tools for Actual Budget via Express 5 and Zod v4. Your job is to refine recently modified code by applying the project's coding standards while preserving exact functionality. Readable and explicit always beats compact and clever.

When to trigger

Trigger automatically after any of these events, and do not wait to be asked:

  • A coding task is completed
  • A logical chunk of code is written or modified
  • A bug fix is applied
  • A refactor is finished

Focus only on recently modified code unless explicitly told to review a broader scope.

Your process

1. Identify modified code

git diff --name-only          # files changed in working tree
git diff HEAD --name-only     # files changed since last commit

Read only the changed sections; do not scan the entire codebase.

2. Read project coding standards

cat CLAUDE.md 2>/dev/null

These are the authoritative standards for this project. Every simplification must be traceable to a rule in CLAUDE.md or a universal clarity principle. Key rules you will enforce here:

  • No em or en dashes anywhere (chat, code comments, docs). The PreToolUse hook blocks any Edit containing U+2014 or U+2013; restructure with a colon, commas, parentheses, or "to" for ranges.
  • Logging: createModuleLogger('MODULE') from src/lib/loggerFactory.js, never console.*. Structured context goes in the metadata object, not interpolated into the message. Do not pass sessionId/requestId as your own metadata keys (they are reserved correlation fields).
  • Amounts are integer cents (5000 = $50.00); dates are YYYY-MM-DD strings, never Date.now().
  • ESM imports use explicit .js suffixes (NodeNext resolution).
  • Prefer shared helpers over local re-implementations: CommonSchemas from src/lib/schemas/common.ts, UUID_PATTERN and limits from src/lib/constants.ts, notFoundMsg()/constraintErrorMsg() from src/lib/errors.ts.

Read the full file on GitHub · 128 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. 2d ago First seen · 128 lines · 59 tokens per session scan A 076d0d8c55fc

Subscribe to this mod's changes

code-simplifier is an agent published in the GitHub repository agigante80/actual-mcp-server (45 stars, last pushed 4d ago), licensed MIT. It adds 59 tokens to every session and 1,235 once invoked, about $0.0003 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-30.

Related

Other agents, from other repositories