agent-failure-analysis
Diagnose AI and agent failures from trace evidence by locating the first meaningful divergence across routing, instructions, context, retrieval, tools, state…
от Dadmin88★ 52 звезды на GitHub
Установить agent-failure-analysis в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Agent Failure Analysis
Use when an AI or agent workflow produces a wrong answer, wrong action, malformed output, tool failure, looping behavior, inconsistent result, unsafe behavior, or unexplained regression.
Procedure
- Capture the failing task exactly: user input, relevant system/developer instructions, model and configuration, prompt/context revision, retrieved evidence, tool definitions, tool calls/results, state or memory, output, timestamps, and environment needed to reproduce it.
- Establish whether the failure is deterministic or probabilistic. Re-run the same case enough to distinguish a stable defect from variance without using repeated sampling as a substitute for diagnosis.
- Build the execution trace in order and locate the first meaningful divergence from the intended path. Later bad output may be a consequence of an earlier routing, context, retrieval, or tool error.
- Classify the failure by owning layer: task/routing, instructions, context construction, retrieval, tool selection, tool arguments, tool implementation/result, state or memory, model reasoning/instruction following, structured-output validation, safety policy, nondeterminism, latency/resource limits, or surrounding application/runtime.
- Compare with a successful trace for a similar case when available. Identify the smallest changed input, evidence, prompt, tool result, state, model/configuration, or environment that predicts the failure.
- Form a falsifiable hypothesis and test it with targeted counterexamples. Avoid changing prompt, model, retrieval, and tools simultaneously because a better result would not reveal which layer fixed the cause.
- Repair the lowest layer that actually owns the defect. Examples: fix missing corpus data rather than prompting around it; fix a misleading tool schema rather than adding tool-selection prose; fix validation rather than asking the model to "always output valid JSON."
- Add the failure and nearby variants to the evaluation set before accepting the fix. Check for regressions in cases that previously succeeded.
- Measure the repair under the same configuration and task distribution. For probabilistic failures, compare rates with enough repetitions to support the claimed improvement.
- Record the failure class, evidence, root cause, fix, evaluation impact, and remaining uncertainty so the case becomes reusable engineering knowledge rather than an anecdote.
Decision rules
- The final wrong sentence is not automatically the root cause.
- Do not label every unexplained failure a hallucination; identify what information and control path the model actually had.
- Prompt changes are justified when instructions are the failing layer, not by default.
- A stronger model can mask a system defect without repairing it.
- If the trace shows the primary defect belongs to product logic, security, infrastructure, or another specialist, hand off the evidence rather than stretching the AI layer around it.
Quality gate
The analysis is complete when the first meaningful failure point is supported by trace evidence, the owning layer is identified, the repair targets that cause, the failure is represented in evaluation coverage, and measured results show improvement without unacceptable regressions.
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл agent-failure-analysis?
Diagnose AI and agent failures from trace evidence by locating the first meaningful divergence across routing, instructions, context, retrieval, tools, state, model behavior, schemas, and runtime.
Как установить скилл agent-failure-analysis?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл agent-failure-analysis запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
AnthropicCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
discernment-nudge
AnthropicAfter you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
data-consolidate
AnthropicJoins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
inspection-to-capa
AnthropicRuns the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…