Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/luanpdd/kit-mcpnpx agentmods add commands/luanpdd/kit-mcp/forenseWrote 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.
[](https://agentmods.dev/commands/luanpdd/kit-mcp/forense)<a href="https://agentmods.dev/commands/luanpdd/kit-mcp/forense"><img src="https://agentmods.dev/badge/commands/luanpdd/kit-mcp/forense.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00033 | $0.02377 |
| Opus 5 | $0.00016 | $0.01189 |
| Sonnet 5 | $0.00007 | $0.00475 |
| Haiku 4.5 | $0.00003 | $0.00238 |
Grade A, and why
forense 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 4d 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.
How it starts
The opening of the file, as written. The whole thing — 177 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Propósito: Diagnosticar workflows com falha ou travados para que o usuário possa entender a causa raiz e tomar ação corretiva.
Saída: Relatório forense salvo em .planning/forensics/, apresentado inline, com criação opcional de issue.
<execution_context> @./.claude/framework/workflows/forensics.md </execution_context>
Entrada do usuário:
- Descrição do problema: $ARGUMENTS (opcional — perguntará se não fornecido)
<success_criteria>
- Evidências coletadas de todas as fontes de dados disponíveis
- Pelo menos 4 tipos de anomalia verificados (loop travado, artefatos ausentes, trabalho abandonado, crash/interrupção)
- Relatório forense estruturado escrito em
.planning/forensics/report-{timestamp}.md - Relatório apresentado inline com descobertas, anomalias e recomendações
- Investigação interativa oferecida para análise mais profunda
- Criação de issue no GitHub oferecida se existirem descobertas acionáveis </success_criteria>
<critical_rules>
- Investigação somente leitura: Não modificar arquivos fonte do projeto durante forense. Apenas escrever o relatório forense e atualizar rastreamento de sessão no STATE.md.
- Redigir dados sensíveis: Remover caminhos absolutos, chaves de API, tokens de relatórios e issues.
- Fundamentar descobertas em evidências: Toda anomalia deve citar commits, arquivos ou dados de estado específicos.
- Sem especulação sem evidência: Se os dados forem insuficientes, diga isso — não fabrique causas raiz. </critical_rules>
<observability_integration> Integração com Core Analysis Loop (v1.9):
Forense usa skill core-analysis-loop — método científico iterativo (sintoma → hipótese de dados → validação → próxima iteração) em vez de inspeção ad hoc.
Cada anomalia detectada vira hipótese com query de validação:
| Tipo de anomalia | Hipótese formada | Query de validação |
|---|---|---|
| Loop travado | "phase X stuck há Yh" | git log --since="Yh ago" --grep=phase para confirmar zero commits |
| Artefatos ausentes | "PLAN.md ausente em phase X" | ls .planning/phases/X-*/X-PLAN-*.md |
| Trabalho abandonado | "branch sem merge nem commit recente" | git log -1 <branch> + git status |
| Crash/interrupção | "executor falhou em meio a fase" | grep no STATE.md por "in_progress" sem update recente |
Skill consultada explicitamente: abrir o arquivo kit/skills/core-analysis-loop/SKILL.md para padrão "documentação da trilha (formato canônico)" — o relatório forense em .planning/forensics/report-<ts>.md segue esse formato com cada hipótese tendo "Query / Resultado / Status (VALIDATED / REFUTED / INCONCLUSIVE)".
REQ: INT-FW-06. </observability_integration>
<sre_integration>
Chain /postmortem após Core Analysis Loop (v1.10 — INT-FW-V2-01):
Forense é diagnóstico evidence-based read-only — identifica o o que e o como via método científico (sintoma → hipótese → query → status VALIDATED | REFUTED | INCONCLUSIVE). Quando o Core Analysis Loop fecha com pelo menos uma hipótese VALIDATED apontando para root cause, o próximo passo canônico é postmortem blameless (cap 15 livro Google SRE — Postmortem Culture: Learning from Failure).
Distinção fundamental:
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.
- 4d ago First seen · 177 lines · 33 tokens per session scan A e463925d3eb4
forense is a command published in the GitHub repository luanpdd/kit-mcp (1 stars, last pushed yesterday), licensed MIT. It adds 33 tokens to every session and 2,377 once invoked, about $0.0002 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-09-03.
Other commands, from other repositories
bug-report
Draft a bug report issue for lean4-skills.
triage
Query open Node bugs, classify by priority and sub-team, suggest assignments, and generate a triage summary.
speckit.companion.doctor
Report on a spec's run health — unfinished steps, unjournaled tasks, step bleed, drift you can judge, a step that closed having verified nothing, a step that closed without the file it promised, and why completion did not land (read-only, retroactive, never halts).
harvest-errors
Analyze the latest test262 run results, cross-reference with existing issues, and create new issues for unaddressed error patterns.
postmortem
Deliver a structured post-mortem after incidents, mistakes, or stuck sessions. Use when the user requests a structured post-mortem after incidents, mistakes, or stuck sessions.
diagnostic
Command "diagnostic" from datacore-one/datacore, covering diagnostic, command context, when to reference dip-0002, quick reference and agents this command invokes.