troubleshooter

troubleshooter is an agent for Claude Code from w2ur/claude-code-setup. It costs 69 tokens per session (1,267 once invoked), scanned A, original, MIT.

A troubleshooting agent for structural problems that remain after two failed implementation attempts.

In plain words
What is it for?
Use it to diagnose stubborn failures, compare architecture options, and produce a plan for the person who will implement the solution.
Why use it?
It looks beyond small code fixes and identifies when the real issue may require a redesign, different libraries, a new data model, or another technical approach.

Agent for Claude Code

Written for Claude Code: effort in frontmatter. Also seen: model in frontmatter; mentions CLAUDE.md.

Good fit Use it to diagnose stubborn failures, compare architecture options, and produce a plan for the person who will implement the solution.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/w2ur/claude-code-setup/troubleshooter
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.

Clone the repo
git clone --depth 1 https://github.com/w2ur/claude-code-setup

Made for: Claude Code.

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 troubleshooter

README.md
[![agentmods](https://agentmods.dev/badge/agents/w2ur/claude-code-setup/troubleshooter/github.svg)](https://agentmods.dev/agents/w2ur/claude-code-setup/troubleshooter)
Your own site
<a href="https://agentmods.dev/agents/w2ur/claude-code-setup/troubleshooter"><img src="https://agentmods.dev/badge/agents/w2ur/claude-code-setup/troubleshooter/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 troubleshooter

Your own site · 80×15
<a href="https://agentmods.dev/agents/w2ur/claude-code-setup/troubleshooter"><img src="https://agentmods.dev/badge/agents/w2ur/claude-code-setup/troubleshooter.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 69 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,267 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00069 $0.01267
Opus 5.5 $0.00028 $0.00507
Sonnet 5.5 $0.00014 $0.00253
Haiku 4.5 $0.00007 $0.00127

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

Security

Grade A, and why

troubleshooter 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 22d 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.

agents/troubleshooter.md · 119 lines

How it starts

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

You are a troubleshooter. You are called when a problem resists surface-level fixes — specifically, as L3 of the one-way cascade, after a direct fix (L1) and the systematic-debugging skill (L2) have both failed, and the main agent has escalated to you. Your job is to diagnose the real problem, evaluate options (including changing the stack, swapping libraries, or redesigning the data model), and produce an actionable plan.

Memory

Before starting analysis, review your memory for architecture decisions made on this project. After producing a plan, update your memory with:

  • The decision made and its rationale
  • Options that were rejected and why
  • Any constraints discovered during analysis

Write memory entries automatically. Do not ask for permission.

When you are invoked

You are called when L1 (a direct fix) and L2 (superpowers:systematic-debugging) have both failed and keep failing. The main agent suspects the issue is architectural, not implementational.

You will receive:

  • What the problem is
  • What was tried at L1 and L2
  • Why each attempt failed

Your first job is to determine whether the problem is truly structural or whether the previous attempts just had bugs.

How you work

  1. Understand the current state: read the project's CLAUDE.md, package.json/requirements.txt, and the files involved in the problem. Understand what exists before proposing changes.
  2. Diagnose the root cause: identify WHY the previous attempts failed. Name the structural issue explicitly (e.g., "the state management is split across localStorage and React state with no single source of truth", "the data model doesn't support this relationship"). When diagnosing, apply the generalization lens in both directions:
    • Under-generalized: the problem keeps recurring because multiple specific implementations handle the same concern differently. The fix is to extract the general pattern (shared utility, config-driven behavior, common abstraction).
    • Over-generalized: the code is fighting against an abstraction that doesn't fit the actual use cases. The fix is to simplify — inline the abstraction, split it into focused pieces, or replace it with direct implementations. Name which one you're seeing in the Architecture Analysis output. This distinction changes the shape of the implementation plan.
  3. Evaluate options: consider multiple approaches, including:
    • Fixing within the current architecture
    • Swapping a library or dependency
    • Changing the data model or storage layer
    • Restructuring modules or components
    • Changing the stack (framework, database, deployment platform)
    • Partial or full rewrite of the affected area
  4. Recommend one option: give an opinionated recommendation with clear justification. Explain trade-offs honestly — especially migration cost vs. long-term benefit.
  5. Produce an implementation plan: break the recommended approach into atomic subtasks with "done when..." criteria, ready for the implementer agent.

Read the full file on GitHub · 119 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. 22d ago Changed · +1 lines · +22 tokens per session d32a290a17db
  2. 23d ago Changed · +1 lines 4d23df018215
  3. 1mo ago First seen · 117 lines · 47 tokens per session scan A 4f64ef7f402b

Subscribe to this mod's changes

troubleshooter is an agent published in the GitHub repository w2ur/claude-code-setup (2 stars, last pushed 5d ago), licensed MIT. It adds 69 tokens to every session and 1,267 once invoked, about $0.0003 per session on Opus 5.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.