forensic-deepdive: Skill for Claude Code

.claude/skills/forensic-deepdive-query/SKILL.md

forensic-deepdive-query is a skill for Claude Code from Dhevenddra/forensic-deepdive. It costs 119 tokens per session (704 once invoked), scanned A, original, Apache-2.0.

A way to answer questions about a code repository from prepared forensic notes, such as maps of files, critical paths, history, and architecture.

In plain words
What is it for?
Use it to find where code lives, identify ownership, trace important paths, understand architectural structure, and assess what may be affected by an edit.
Why use it?
It avoids repeatedly scanning the entire codebase for navigation questions when those notes already exist.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

This is Dhevenddra/forensic-deepdive's own configuration. It tells Claude Code how to work on forensic-deepdive itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything forensic-deepdive configures →

Part of the forensic-deepdive plugin — 3 skills, 1 MCP server shipped together

Reuse

Borrowing it

Nothing to install: this file belongs to Dhevenddra/forensic-deepdive. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Dhevenddra/forensic-deepdive/main/.claude/skills/forensic-deepdive-query/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/Dhevenddra/forensic-deepdive

Made for: Claude Code.

Or install forensic-deepdive, the plugin that ships this one along with the rest of its 3 skills, 1 MCP server.

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 forensic-deepdive-query

README.md
[![agentmods](https://agentmods.dev/badge/skills/dhevenddra/forensic-deepdive/forensic-deepdive-query.svg)](https://agentmods.dev/skills/dhevenddra/forensic-deepdive/forensic-deepdive-query)
Your own site
<a href="https://agentmods.dev/skills/dhevenddra/forensic-deepdive/forensic-deepdive-query"><img src="https://agentmods.dev/badge/skills/dhevenddra/forensic-deepdive/forensic-deepdive-query.svg" alt="Measured on agentmods" height="20"></a>
Per session 119 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 704 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.00119 $0.00704
Opus 5 $0.00060 $0.00352
Sonnet 5 $0.00024 $0.00141
Haiku 4.5 $0.00012 $0.00070

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

Security

Grade A, and why

forensic-deepdive-query 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 6d 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/forensic-deepdive-query/SKILL.md · 49 lines

How it starts

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

Forensic Deep-Dive — Query

Answer from precomputed artifacts instead of re-reading the codebase.

When to use

  • docs/codebase/MAP.md exists.
  • Question is navigational: "where", "who owns", "how did", "what are entry points", "blast radius of editing X".

When NOT to use

  • Artifacts >30 days old AND ≥50 commits since last extract → trigger forensic-deepdive-update first.
  • Question is code-semantic ("does this function handle null") → just read the file.
  • User wants to verify a specific implementation detail → read the source.

How to answer

  1. Always read docs/codebase/AGENT_BRIEF.md first — it's small and contains the rules.
  2. Match the question shape:
Question shape Artifact to grep
"Where does X live" / "who owns" docs/codebase/MAP.md
"How did X evolve" / "when was X introduced" / "who wrote X" docs/codebase/ARCHAEOLOGY.md
"Critical path through feature X" / "trace request lifecycle" docs/codebase/HOTPATHS.md
"Explain X" / "what's the architecture" docs/codebase/MENTAL_MODEL.md
"What rules apply when editing X" docs/codebase/AGENT_BRIEF.md
"Show me a diagram of X" / "visualize how X connects" forensic graph X --format mermaid (or the visualize MCP tool) — bounded Mermaid, confidence-styled edges
"What backend does this frontend call" / "who calls this endpoint" / trace a feature across the stack the trace MCP tool (downstream = component→endpoint→handler→callees; upstream = who-calls-endpoint) or docs/codebase/HOTPATHS.md ## Cross-stack routes
  1. Only if none answer, run:
    forensic query "<question>"
    
    (v0.2 — uses MCP server if installed, otherwise greps the artifacts.)

Citation rule

Always cite: docs/codebase/MAP.md:142-158. Never paraphrase without a line citation. If you can't find a citation, say so — don't fabricate.

What to report back

  • The answer, with file:line citations from the artifacts.
  • If multiple artifacts contain related context, link them all.
  • If the artifact seems stale (date in <!-- generated --> header > 14 days old), warn the user and offer to run forensic-deepdive-update.

Read the full file on GitHub · 49 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. 6d ago First seen · 49 lines · 119 tokens per session scan A 5809fea07ff3

Subscribe to this mod's changes

forensic-deepdive-query is a skill published in the GitHub repository Dhevenddra/forensic-deepdive (2 stars, last pushed 21d ago), licensed Apache-2.0. It adds 119 tokens to every session and 704 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-31.