Skill262 repo starsupdated today
investigate
The investigate skill orchestrates parallel evidence-based debugging by launching multiple specialized agents to trace different aspects of a reported bug simultaneously. Use this skill when troubleshooting production issues or complex defects by having error-path investigators, data-flow tracers, and domain specialists (concurrency, database behavior, etc.) work in parallel, with all findings grounded in codebase evidence or corroborated external sources rather than speculation.
Install in Claude Code
Copygit clone --depth 1 https://github.com/testdouble/han /tmp/investigate && cp -r /tmp/investigate/han-coding/skills/investigate ~/.claude/skills/investigateThen start a new Claude Code session; the skill loads automatically.
Definition
SKILL.md
## 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](../../references/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](../../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.
# Investigate
## Step 1: Research and Investigation
### Always dispatch
Launch at least 2 `han-core:evidence-based-investigator` agents in parallel, each investigating from a different angle —
for example, one tracing the error path and another following the data flow.
### Conditional specialist dispatch
Classify the bug from the user's symptom description before launching. Skip any specialist that does not apply. Dispatch
every applicable specialist in parallel with the `han-core:evidence-based-investigator` agents in the same message.
1. **Launch han-core:concurrency-analyst** — when the symptom involves intermittent failures, race conditions,
deadlocks, ordering issues, stale reads after writes, timeouts, dropped messages, or anything that only reproduces
under load or concurrent users. Prompt: "Investigate the concurrency and async behavior of the code paths implicated
by this symptom: {symptom}. Focus on race conditions, lock ordering, shared-resource contention, async error
handling, and missing cancellation/timeout handling. Return numbered findings keyed to file paths and line numbers."
2. **Launch han-core:behavioral-analyst** — when the symptom involves data transformed wrong, values lost between
modules, errors swallowed, state mutated unexpectedly, or integration boundaries passing bad data. Prompt: "Trace the
data flow for the code paths implicated by this symptom: {symptom}. Focus on data transformation across module
boundaries, error propagation and loss, state mutation, and integration-boundary assumptions. Return numbered
findings keyed to file paths and line numbers."
3. **Launch han-core:data-engineer** — when the symptom involves wrong data in the database, slow queries, N+1, lock
contention, migration failures, unbounded scans, lost data, broken referential integrity, or isolation-level
surprises. Prompt: "Investigate the schema, queries, migrations, and data-access code implicated by this symptom:
{symptom}. Focus on the specific data-engineering principles violated and the concrete data-level impact. Return
numbered findings keyed to file paths, line numbers, and schema or migration references."
Extra agents named in the project config's `## Extra Agents` list join this conditional-specialist pool under the same
symptom-driven selection, per [../../references/config-rule.md](../../references/config-rule.md): dispatch one only
when the classified bug type matches its stated specialty, and skip an entry that does not resolve to a dispatchable
agent with a one-line note.
After all agents complete (investigators and specialists), compile an **evidence summary** — a numbered list of concrete
findings (E1, E2, E3, ...) that will feed into the root cause analysis. Specialist findings go into the same E-series
list, tagged with the specialist's domain (e.g., `E3 (concurrency)`).
## Step 2: Document Root Cause
Write to the plan file using the template at [template.md](./references/template.md). Fill the sections in the workflow
order below; this is deliberately not the template's on-page order, which leads with the Summary and places the
supporting Evidence Summary, Validation Results, and Coding StandaMore from this repository
han-releaseSkill
>
han-update-documentationSkill
>
markdown-to-confluenceSkill
>
plan-a-feature-to-confluenceSkill
>
project-documentation-to-confluenceSkill
>
work-items-to-jiraSkill
>
architectural-analysisSkill
Performs deep architectural analysis of a specified module, directory, or feature area by examining structural
code-reviewSkill
Run a comprehensive code review on local source files. Use this skill when the user asks to review, audit, inspect,