investigate

An evidence-based software investigation workflow for finding the cause of a problem. It traces symptoms through code, data, and recent changes instead of relying on guesses.

In plain words
What is it for?
Use it to debug failures, follow an error path, examine data flow, or investigate changes that may have introduced a problem.
Why use it?
It helps explain why a bug, failed API call, broken integration, or other software issue occurs. The focus is diagnosis and solutions, not general code-quality review.

Skill for Claude CodeCodex

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/testdouble/han/investigate
Any agent
npx skills add testdouble/han --skill investigate
Clone the repo
git clone --depth 1 https://github.com/testdouble/han

Made for: Claude Code, Codex.

Per session 139 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,581 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.00139 $0.02581
Opus 5 $0.00069 $0.01290
Sonnet 5 $0.00028 $0.00516
Haiku 4.5 $0.00014 $0.00258

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

Security

Grade A, and why

investigate 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.

han-coding/skills/investigate/SKILL.md · 164 lines

How it starts

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

Project Context

  • CLAUDE.md: !find . -maxdepth 1 -name "CLAUDE.md" -type f
  • project-discovery.md: !find . -maxdepth 3 -name "project-discovery.md" -type f
  • personal config directory: !bash "${CLAUDE_PLUGIN_ROOT}/scripts/han-config-dir.sh" 2>/dev/null || echo "$HOME/.claude"
  • project .han/config.md: !cat .han/config.md 2>/dev/null || echo ""

As your first action, use the Read tool on .han/config.md inside the personal config directory path above. A read that returns no file is no personal configuration: continue silently. When that file or the project .han/config.md probe supplies content, apply it per config-rule.md, which governs precedence between the two files, relative-path resolution, and what to do with a file that reads but cannot be used.

Investigation Approach

  • Trace backward from symptoms — don't guess, follow the code.
  • Launch parallel han-core:evidence-based-investigator agents for different angles simultaneously — one for the error path, one for the data flow, one for recent changes.
  • Add one or more specialist analysts in parallel with the investigators when the bug type calls for it (concurrency, data flow across boundaries, database or query behavior). Specialist analysts find root causes generalists miss.
  • The han-core:adversarial-validator agent handles all three validation strategies (challenge evidence, challenge fix, challenge assumptions) internally.
  • Apply the evidence rule from ../../references/evidence-rule.md to every finding. Codebase findings (file path, line number, log line, test output) carry the trust-class label "codebase" and stand on their citation. Web-source context (RFCs, vendor docs, Stack Overflow, blog posts) carries the trust-class label "web" and is subject to the corroboration gate when it drives the proposed fix. When the investigation hits a point where no evidence at any tier resolves a question, label the no-evidence state rather than guessing.
  • Lazy-create the output sections. Include a section in the plan file only when the investigation produced meaningful content for it; omit any section that would be empty, and keep the sections that remain in the template's order. Never emit a heading with placeholder or "N/A" content.
  • Invoke han-communication:readability-guidance to source the shared readability standard into your context, then apply it as you write the findings, holding the named audience: the engineer who will implement the fix and may be paged on the bug. Scope that frame per section so the technical specifics the engineer needs (function names, exact failing conditions, file:line citations) are preserved, never simplified away.

Read the full file on GitHub · 164 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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 · 164 lines · 139 tokens per session scan A 0404147851f8

Subscribe to this mod's changes

investigate is a skill published in the GitHub repository testdouble/han (247 stars, last pushed 5d ago), licensed MIT. It adds 139 tokens to every session and 2,581 once invoked, about $0.0007 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 skills, from other repositories

golden-rss

Use when testing the rss golden build.

yusufkaraaslan/Skill_Seekers · 12 tokens

golden-chat-single

Use when testing the goldenchatsingle golden build.

yusufkaraaslan/Skill_Seekers · 14 tokens

decided-import

Reformat ONE existing document (a decision, requirement, design, roadmap, or prompt) into ONE valid RAC (requirements-as-code) artifact, with a mandatory human-review step before any file is written and decided validate as the deterministic close. Use when a user wants to add or import a single existing decision or…

asdecided/core · 98 tokens

keep-the-why

Preserves or recovers the reasoning behind a codebase - architectural decisions, rejected alternatives, workarounds, incident learnings, operational constraints, and historical context the code itself cannot explain. Use when implementing or reviewing a non-trivial change involving a design decision, workaround…

oliver-zehentleitner/keep-the-why · 163 tokens

architectural-decisions

Use when encountering questions about WHY code is built a certain way, when about to make architectural changes (new patterns, restructuring, choosing between approaches), or when the user asks about design rationale in a Repowise-indexed codebase (.repowise/ directory exists). Also activates when commit messages or…

repowise-dev/repowise · 87 tokens

pre-modification-check

Use before modifying, refactoring, moving, or deleting files in a Repowise-indexed repository, especially shared utilities, core modules, public APIs, or files the user did not explicitly identify.

repowise-dev/repowise · 45 tokens