quick-fix

quick-fix is a command for Claude Code from Sagargupta16/claude-cost-optimizer. It costs 10 tokens per session (483 once invoked), scanned A, original, MIT.

A narrowly focused command for applying a described bug fix with minimal investigation and output.

In plain words
What is it for?
Use it when the bug and usually its file or line are already clear. It reads the relevant area, edits it directly, and runs a known relevant test when appropriate.
Why use it?
It keeps a small fix from expanding into unrelated exploration, refactoring, or explanation.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter.

Part of the claude-cost-optimizer plugin — 1 skill, 3 commands 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 commands/sagargupta16/claude-cost-optimizer/quick-fix
Clone the repo
git clone --depth 1 https://github.com/Sagargupta16/claude-cost-optimizer

Made for: Claude Code.

Or install claude-cost-optimizer, the plugin that ships this one along with the rest of its 1 skill, 3 commands.

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 quick-fix

README.md
[![agentmods](https://agentmods.dev/badge/commands/sagargupta16/claude-cost-optimizer/quick-fix.svg)](https://agentmods.dev/commands/sagargupta16/claude-cost-optimizer/quick-fix)
Your own site
<a href="https://agentmods.dev/commands/sagargupta16/claude-cost-optimizer/quick-fix"><img src="https://agentmods.dev/badge/commands/sagargupta16/claude-cost-optimizer/quick-fix.svg" alt="Measured on agentmods" height="20"></a>
Per session 10 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 483 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.00010 $0.00483
Opus 5 $0.00005 $0.00242
Sonnet 5 $0.00002 $0.00097
Haiku 4.5 $0.00001 $0.00048

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

Security

Grade A, and why

quick-fix 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 6d 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.

templates/commands/quick-fix.md · 59 lines

What it actually says

Quick Fix

Apply a targeted bug fix with minimal token usage. No exploration, no discussion — just fix.

Process

  1. Identify: The user has described a bug or pointed to a specific file/line. If the file path is provided, read only the relevant section (use offset/limit if possible).

  2. Fix: Apply the edit immediately. Do not:

    • Explain the root cause in detail
    • Show "before and after" comparisons
    • Suggest related improvements
    • Refactor surrounding code
    • Read other files "for context"
  3. Verify (only if a test command is known): Run the relevant test in one command. If no test file is obvious, skip this step.

  4. Report: Respond with a single line describing the fix:

Fixed: {what was wrong} in {file path}

Rules

  • ONE file edit per bug. If the fix truly requires multiple files, do them all in parallel in one turn.
  • Do NOT read the entire file — read only the area around the reported issue.
  • Do NOT suggest follow-up improvements or "while we're here" changes.
  • Do NOT explain the fix unless the user asks "why."
  • If the bug description is ambiguous, ask ONE clarifying question — do not guess.

Example

User: "The login button doesn't submit the form — it's in src/components/LoginForm.tsx around line 45"

Good response:

[Reads lines 40-55 of LoginForm.tsx]
[Edits: changed type="button" to type="submit" on line 47]
Fixed: button type was "button" instead of "submit" in src/components/LoginForm.tsx

Bad response:

Let me take a look at the LoginForm component to understand the issue...
[Reads entire file]
I can see the problem! The button on line 47 has type="button" which prevents
form submission. This is a common issue in React forms because...
[Long explanation]
[Edit]
I've fixed the issue. The button was using type="button" instead of type="submit".
You might also want to consider adding form validation...
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. 6d ago First seen · 59 lines · 10 tokens per session scan A 4c6c6fa75509

Subscribe to this mod's changes

quick-fix is a command published in the GitHub repository Sagargupta16/claude-cost-optimizer (35 stars, last pushed 2d ago), licensed MIT. It adds 10 tokens to every session and 483 once invoked, about $0.0001 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.