authoring-workflow-postmortem

Drafts postmortem documents for failed agent-scaffold workflows with archived evidence and owned action items.

Updated Apr 26, 2026
One-click install
npx skills add https://github.com/Jin9/skillify-foundation --skill authoring-workflow-postmortem-jin9
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: authoring-workflow-postmortem
Source: https://github.com/Jin9/skillify-foundation/tree/main/treasury/authoring-workflow-postmortem
Command: npx skills add https://github.com/Jin9/skillify-foundation --skill authoring-workflow-postmortem-jin9

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? When an agent-scaffold workflow fails a stage, burns past its spend cap, gets rejected at the implement gate, or fails a sandbox egress test, teams need a structured postmortem within 48 hours — but gathering logs, spend data, and approval records manually is slow and error-prone. ## Core Features & Use Cases - Trigger Verification: Confirms a real trigger event fired (failed stage > $1, rejected gate, cap overrun, sandbox failure) against state.json and logs before drafting, refusing phantom postmortems. - Evidence Archiving: Copies runlogs, stage outputs, approval excerpts, and LiteLLM spend reports into a dated archive folder under docs/postmortems/ without modifying originals. - Root-Cause Discipline: Enforces mechanism-based root causes (not "the model hallucinated") using a 5-whys reference guide. - Actionable Outcomes: Routes every action item to a concrete PR target with a GitHub-handle owner and a due date within 14 days. - Use Case: After the dispatcher exits with a spend-cap overrun on workflow credit-check-v2, ask the agent to draft the postmortem; it verifies the trigger, archives evidence, builds a UTC timeline, and produces a ready-to-commit markdown document. ## Quick Start Draft a postmortem for the failed workflow credit-check-v2 using the runlog and spend logs in this repo.

Frequently Asked Questions about authoring-workflow-postmortem

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a postmortem for a failed AI agent workflow?▼

Verify the trigger event in state.json, archive runlogs and spend data into a dated folder, build a UTC timeline from runlog.jsonl, identify the mechanism-based root cause, and draft the document from the postmortem template with owned action items.

What events trigger a workflow postmortem?▼

Four triggers require a postmortem within 48 hours: a failed stage with more than $1 spent, a rejected implement gate, a spend-cap overrun where total cost meets the cap, and a sandbox egress test failure. Multiple triggers are covered in one document.

How do I verify a postmortem trigger actually fired?▼

Check state.json with jq filters: look for stages with status failed and cost over $1, an implement status of rejected, or total_cost_usd greater than or equal to spend_cap_usd. If verification fails, stop and ask the user rather than drafting on a phantom trigger.

What is a good root cause for an AI workflow failure?▼

A good root cause names the mechanism and system gap, not the agent. Instead of "the model hallucinated", state what allowed it, such as a plan-stage prompt that predates the citation rule. Apply at least three whys before declaring the cause.

When should I not write a workflow postmortem?▼

Do not write one for successful-workflow retrospectives, architecture decisions (use ADRs), or when no trigger event fired. If the approval chain fails verification or real PII appears in logs, escalate as a security incident first.

Does this skill execute remediation actions after a failure?▼

No. It only authors action items as PR targets with owners and due dates, then hands off to sibling skills like drafting-stage-prompt or authoring-scaffold-profile. The action owner runs the sibling skill so the PR has the right author.