forensics
БесплатноБез исполняемых скриптовНе проверенPost-mortem a failed GSD auto-mode run. Traces symptom to root cause via `.gsd/` activity, journal, metrics, and lock artifacts, producing a filing-ready bug…
от open-gsd★ 1 399 звёзд на GitHubОб этом скилле
activity/{seq}-{unitType}-{unitId}.jsonl— full tool-call and message stream per unitjournal/YYYY-MM-DD.jsonl— iteration-level events. Orchestrator path emitsorchestrator-*events (orchestrator-dispatch-match,orchestrator-guard-block,orchestrator-terminal, etc.); legacy loop events (dispatch-match,stuck-detected,guard-block,unit-start/end,terminal) can still appear on non-orchestrator paths.metrics.json— token/cost ledger; duplicatetype/identries indicate a stuck loopauto.lock— JSON snapshot of the currently-owning PID; stale lock = crash mid-unitforensics/— saved prior reportsdebug/— debug logs if enabledruntime/paused-session.json— serialized session when auto-mode pauseddoctor-history.jsonl— doctor check history
The /gsd forensics command pre-computes a forensic report with anomalies flagged. This skill is the manual investigation that goes deeper, or runs when the automated report isn't enough.
Invocation points:
/gsd forensicshas been run and user wants deeper analysis- Auto-mode exited unexpectedly, no obvious cause
- Same unit dispatched multiple times (stuck loop suspected)
- A session crashed and
auto.lockis stale - User reports "it just stopped" or "it did the wrong thing"
RECOVERY IS A BOUNDARY, NOT A BYPRODUCT. If the failure involves a GSD auto-pause blocker or a failed Task attempt, the recovery routes are authority-controlled: /gsd blocker resolve is cleared only by the human in the native terminal, and a recovery resume (gsd_task_recovery_resume or the operator's /gsd recover <recoveryActionId>) is a gated continuation with its own repair-evidence requirements. Forensics recommends those routes in its Recovery section; it never performs them, and it never recommends direct database, runtime KV/counter, or rendered-file manipulation to unblock a run. Read the gsd-blocker-recovery skill before writing the Recovery section.
SYMPTOM → ROOT CAUSE, WITH CITATIONS. Every claim in the report is backed by an artifact path and either a line number or a JSONL field. "The loop got stuck because of a race" is not useful; ".gsd/journal/2026-04-19.jsonl:142 shows stuck-detected with flowId X, caused by dispatch-guard.ts:87 returning the same unit after unit-end" is.
PRE-PARSED LEADS, NOT CONCLUSIONS. If /gsd forensics has surfaced anomalies, treat them as hypotheses to verify, not answers.
Step 1: Locate the evidence
Read what's in .gsd/:
auto.lock— is it stale? Check PID againstps(read-only inspection, allowed). Stale = crash.- Most recent
.gsd/activity/*.jsonl— sort by mtime, newest first. That's the last unit that ran. - Today's
.gsd/journal/YYYY-MM-DD.jsonl— the iteration-level view. .gsd/metrics.json— does anytype/idappear more than once? (stuck loop signal).gsd/runtime/paused-session.json— if present, what was the pause reason?
Step 2: Reconstruct the failure from the activity log
Activity JSONL format:
- Each line is
{type: "message", message: {...}}. message.role: "assistant"→content[]withtype: "text"reasoning andtype: "toolCall"invocations.message.role: "toolResult"→{toolCallId, toolName, isError, content}.usageon assistant messages tracks tokens and cost.
To trace a failure:
- Search for
isError: truetool results in the last activity log. That's usually the proximate symptom. - Walk backwards to the assistant message that made the call. Read the
textcontent — that's the agent's reasoning at the moment of failure. - Keep walking back. Find where the agent's model of the state diverged from reality.
Step 3: Cross-reference the journal
For each symptom from the activity log, find the matching journal events:
stuck-detected+ sameflowId→ the loop detected repetition.data.reasonsays why.guard-block→ a dispatch guard refused to run a unit. Checkdata.reasonand trace todispatch-guard.tslogic.unit-endfollowed by anotherunit-startfor the sameunitId→ re-dispatch. If tie
Установить forensics в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл forensics?
Post-mortem a failed GSD auto-mode run. Traces symptom to root cause via `.gsd/` activity, journal, metrics, and lock artifacts, producing a filing-ready bug report with file:line refs and a fix suggestion. Use when asked to "forensics", "post-mortem", "why did auto-mode fail", "trace the stuck loop", "debug the crash", after `/gsd forensics`, or when a session ended in an unexpected terminal state. Reads artifacts only — re-runs nothing.
Как установить скилл forensics?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл forensics запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic