fix

fix is a skill for Claude Code from martineserios/thebrana. It costs 38 tokens per session (3,124 once invoked), scanned B, original, MIT.

A methodical bug-fixing workflow that reproduces a problem with a failing test, diagnoses it, makes a minimal fix, verifies the result, and commits the change. Test-first means the failing test is created before changing the source code.

In plain words
What is it for?
Use it for bug reports or task-based fixes that need reproduction, diagnosis, verification, and an optional recurring-error safeguard.
Why use it?
It prevents fixes based only on guesswork and provides evidence that the bug is fixed. It also keeps the repair steps organised and resumable.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: model in frontmatter; reads .claude/ paths; mentions .claude-plugin.

Part of the brana plugin — 53 skills, 4 commands, 14 agents shipped together

Good fit Use it for bug reports or task-based fixes that need reproduction, diagnosis, verification, and an optional recurring-error safeguard.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/martineserios/thebrana/fix
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.

Any agent
npx skills add martineserios/thebrana --skill fix
Clone the repo
git clone --depth 1 https://github.com/martineserios/thebrana

Made for: Claude Code.

Or install brana, the plugin that ships this one along with the rest of its 53 skills, 4 commands, 14 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 fix

README.md
[![agentmods](https://agentmods.dev/badge/skills/martineserios/thebrana/fix/github.svg)](https://agentmods.dev/skills/martineserios/thebrana/fix)
Your own site
<a href="https://agentmods.dev/skills/martineserios/thebrana/fix"><img src="https://agentmods.dev/badge/skills/martineserios/thebrana/fix/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for fix

Your own site · 80×15
<a href="https://agentmods.dev/skills/martineserios/thebrana/fix"><img src="https://agentmods.dev/badge/skills/martineserios/thebrana/fix.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,124 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.00038 $0.03124
Opus 5.5 $0.00015 $0.01250
Sonnet 5.5 $0.00008 $0.00625
Haiku 4.5 $0.00004 $0.00312

Measured 8d ago against content hash e7207c835788, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

fix scanned grade B with 1 finding 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 8d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

cat > ~/.claude/run-state/active-goal.json <<JSON
system/skills/fix/SKILL.md · 263 lines

How it starts

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

Fix

Structured bug fixing workflow. Five steps: REPRODUCE → DIAGNOSE → FIX → VERIFY → COMMIT → (HARDEN). Enforces test-first debugging — no source changes until a failing test exists. HARDEN is optional: fires when the same errata class has appeared 2+ times — offers to convert the pattern into a PreToolUse gate.

Usage

/brana:fix [task-id or bug description]

If a task ID is provided, load it via brana backlog get <id> and use the description as the bug statement.

Step Registry

On entry, create CC Tasks for each step (for compression resilience):

TaskCreate: "/brana:fix — REPRODUCE"
TaskCreate: "/brana:fix — DIAGNOSE"   (blocked by REPRODUCE)
TaskCreate: "/brana:fix — FIX"        (blocked by DIAGNOSE)
TaskCreate: "/brana:fix — VERIFY"     (blocked by FIX)
TaskCreate: "/brana:fix — COMMIT"     (blocked by VERIFY)
TaskCreate: "/brana:fix — HARDEN"     (blocked by COMMIT, optional)

Mark each in_progress when starting, completed when done. Resume after compression by calling TaskList and finding the in_progress step.

After creating the step registry, call /goal and write active-goal.json unless --no-goal was passed.

If a task_id is known, first extract AC: lines from task context:

brana backlog get {task_id} | python3 -c "
import json, sys
t = json.load(sys.stdin)
lines = [l[3:].strip() for l in (t.get('context') or '').splitlines() if l.startswith('AC:')]
print('\n'.join(lines))
"
  • If AC: criteria found:
    /goal "fix {task-id} — Done when: {criteria joined with ' AND '}"
    
    Pin base_ref at goal start and initialize tests_required[] empty (hardened form — ADR-061 §4, identical to build's LOAD step 0):
    base_ref=$(git -C "{git_root}" rev-parse HEAD)
    cat > ~/.claude/run-state/active-goal.json <<JSON
    {"task_id": "{task_id}", "cwd": "{git_root}", "session_id": "$BRANA_SESSION_ID", "base_ref": "$base_ref", "criteria": ["{criterion1}", "{criterion2}"], "tests_required": []}
    JSON
    
    base_ref anchors the grader-immutability check; the REPRODUCE failing test is committed red in its own commit (the REPRODUCE step, Step 1) so the red-verification pre-commit hook (t-2216) registers it into tests_required[] — earning the exemption by observed redness. The Stop hook (goal-completion.sh) auto-completes the task when all criteria pass, behind the presence + immutability interlocks.

Read the full file on GitHub · 263 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. 8d ago Changed e7207c835788
  2. 1mo ago First seen · 263 lines · 38 tokens per session scan B 17ed4ba95bc9

Subscribe to this mod's changes

fix is a skill published in the GitHub repository martineserios/thebrana (3 stars, last pushed today), licensed MIT. It adds 38 tokens to every session and 3,124 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories