hk-rca

hk-rca is a skill for Claude Code from deepklarity/harness-kit. It costs 111 tokens per session (1,421 once invoked), scanned A, original, MIT.

A guided root-cause analysis process for debugging software problems. RCA means root-cause analysis: a structured investigation that reproduces the failure, locates its source, tests a hypothesis, verifies the fix, and records the result.

In plain words
What is it for?
Use it to investigate bugs and unexpected behavior by documenting the reproduction, expected and actual results, affected layer, failing test, fix, live verification, and final notes.
Why use it?
It prevents jumping from a symptom straight to an untested fix. Each stage must be addressed before the next one, making the reasoning and evidence visible.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Good fit Use it to investigate bugs and unexpected behavior by documenting the reproduction, expected and actual results, affected layer, failing test, fix, live verification, and final notes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/deepklarity/harness-kit/hk-rca
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 deepklarity/harness-kit --skill hk-rca
Clone the repo
git clone --depth 1 https://github.com/deepklarity/harness-kit

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 hk-rca

README.md
[![agentmods](https://agentmods.dev/badge/skills/deepklarity/harness-kit/hk-rca/github.svg)](https://agentmods.dev/skills/deepklarity/harness-kit/hk-rca)
Your own site
<a href="https://agentmods.dev/skills/deepklarity/harness-kit/hk-rca"><img src="https://agentmods.dev/badge/skills/deepklarity/harness-kit/hk-rca/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 hk-rca

Your own site · 80×15
<a href="https://agentmods.dev/skills/deepklarity/harness-kit/hk-rca"><img src="https://agentmods.dev/badge/skills/deepklarity/harness-kit/hk-rca.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 111 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,421 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00111 $0.01421
Opus 5 $0.00056 $0.00711
Sonnet 5 $0.00022 $0.00284
Haiku 4.5 $0.00011 $0.00142

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

Security

Grade A, and why

hk-rca 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 9d 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.

.claude/skills/hk-rca/SKILL.md · 154 lines

How it starts

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

/hk-rca — Root Cause Analysis Protocol

This skill enforces the discipline of methodical debugging. The protocol exists because the most common debugging failure is jumping from "I see the symptom" to "I'll try this fix" — skipping the hypothesis, the test, and the verification.

Each step gates the next. You don't write a fix until you have a hypothesis. You don't have a hypothesis until you've located the layer. You don't locate the layer until you've reproduced the bug.

Context

<bug_context> $ARGUMENTS </bug_context>

If the context above is empty, ask the user: "What's broken? Describe the symptom — what you expected vs. what happened."

The Protocol

Work through these steps in order. Present each step's output visibly before moving to the next. Do not skip steps.

Step 1: REPRODUCE

Before anything else, confirm the bug exists and define its boundaries.

Produce this checklist (fill it in, don't just print it empty):

REPRODUCE:
- Symptom: [what's wrong — exact error, unexpected behavior, missing data]
- Expected: [what should have happened]
- Actual: [what did happen]
- Input: [exact input that triggers it — command, URL, spec, task ID]
- Deterministic? [yes/no/unknown]
- Environment: [local, staging, which agent, which harness]

If you cannot reproduce it, stop and tell the user. Do not guess. Do not "fix" something you haven't seen fail.

Step 2: LOCATE

Narrow the failure to a specific layer. Follow this order — stop when you find the discrepancy:

  1. Data layer: Run diagnostic scripts if available (task_inspect, spec_trace, etc.)

    • Does the data look correct in the database/store?
    • If NO → bug is in the backend (model, serializer, view, pipeline)
    • If YES → data is correct but not reaching the consumer
  2. API layer: Check the API response or function output

    • Does the output include the expected fields/values?
    • If NO → serializer, view, or processing bug
    • If YES → bug is in the consumer (frontend, CLI, downstream code)

Read the full file on GitHub · 154 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. 9d ago First seen · 154 lines · 111 tokens per session scan A f33e4d435797

Subscribe to this mod's changes

hk-rca is a skill published in the GitHub repository deepklarity/harness-kit (96 stars, last pushed 1mo ago), licensed MIT. It adds 111 tokens to every session and 1,421 once invoked, about $0.0006 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.