Skip to content

ysskrishna/ai-agent-skills / skills/pre-mortem

pre-mortem

Verified

Use for a pre-mortem, or before committing to a plan, launch or migration: "what could go wrong?", "stress test this plan", "how might this fail?", "risks before we ship". Assumes failure, lists causes, ranks them and sets mitigations. Skip for explaining a failure that already happened.

FileKindSize
SKILL.mdskill md3.7 KB
references/example.mdmarkdown2.1 KB

references/example.md

View on GitHub
# Example: Pre-mortem (light path)

Illustrative case. All details are invented.

**User:** "Next Friday we cut over our customer database to a new managed Postgres. Run a pre-mortem."

**Plan:** migrate the customer database to managed Postgres next Friday evening; two engineers, one rehearsal done.
**Failure definition:** customers see errors or stale data for more than 30 minutes, or data is lost.
**Pass:** Imagine, Causes, Rank, Mitigate, Decide.

**Imagine**
- It is the following Monday. The migration failed badly: checkout ran against stale data for two hours and some orders were lost.

**Causes** (specific stories)
1. The final sync lags and the cutover starts before it catches up. 
2. A scheduled job still writes to the old database after cutover.
3. The connection pool limit on the new database is lower, so the app runs out of connections under Friday load.
4. The rollback plan exists on paper, but nobody has tested restoring the old database to a writable state.
5. Only two engineers know the procedure; one is unavailable at the critical moment.
- Inversion: "what guarantees failure?" Cutting over with no way back and no check that writes stopped on the old side.

**Rank**

| Cause | Likelihood | Impact | Early warning |
|-------|-----------|--------|---------------|
| 2 Job writes to old DB | plausible, nobody has listed all writers | data loss | rows appearing in old DB after cutover test |
| 4 Rollback untested | likely, it was never run | long outage | rehearsal log has no rollback step |
| 3 Connection limit | plausible | errors under load | load test errors in rehearsal |

**Mitigate**
- Cause 2: **Prevent** by listing every writer and revoking old-DB write access at cutover. Owner: backend lead.
- Cause 4: **Respond** by rehearsing rollback end to end before Friday. Owner: second engineer.
- Cause 3: **Detect** with a load test at Friday traffic levels. Owner: to be assigned.

**Decide**
- Plan changes: add the writer inventory, a rollback rehearsal and a load test before the date.
- Tripwires: if rollback rehearsal fails or the writer list is incomplete on Thursday, move the date.
- Statement: go with changes; hold if either tripwire fires.
finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the workStars: 322kUpdated Claude CodeCodexVerifiedInstall
systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixesStars: 322kUpdated Claude CodeCodexVerifiedInstall
test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation codeStars: 322kUpdated Claude CodeCodexVerifiedInstall
skill-creatoranthropics/skillsCreate 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 existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.Stars: 198kUpdated Claude CodeCodexVerifiedInstall