> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking. **Goal:** Build and promote the `pre-mortem` skill — a forward-looking adversarial failure analysis that fires on every consequential action, producing a visible checklist with adversarial+steelman findings, severity-tiered escalation, and MemPalace audit logging. **Archite...
Installs into .claude/skills of the current project.
Are you the author of Plans?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/williamblair333-plans)
# Pre-Mortem Skill Implementation Plan
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
**Goal:** Build and promote the `pre-mortem` skill — a forward-looking adversarial failure analysis that fires on every consequential action, producing a visible checklist with adversarial+steelman findings, severity-tiered escalation, and MemPalace audit logging.
**Architecture:** Single SKILL.md file promoted to `~/.claude/skills/pre-mortem/SKILL.md`. The skill is a discipline-enforcing reference guide — no supporting code required. TDD applies: baseline scenario first (RED), write skill (GREEN), verify and close loopholes (REFACTOR).
**Tech Stack:** Markdown skill authoring, subagent pressure testing, MemPalace MCP for logging verification.
**Spec:** `docs/superpowers/specs/2026-05-23-pre-mortem-design.md`
---
### Task 1: RED — Baseline Pressure Test (no skill present)
Establish the failure baseline. The writing-skills Iron Law: no skill without a failing test first.
**Files:**
- No files created — this is observation only
- [ ] **Step 1: Confirm pre-mortem skill is NOT present**
```bash
ls ~/.claude/skills/ | grep pre-mortem
```
Expected: no output. If present, stop — do not test with skill installed.
- [ ] **Step 2: Dispatch baseline subagent with pressure scenario**
Dispatch a subagent with this exact prompt — do not add context about the skill being built:
```
You just fixed a cron job that was corrupting the MemPalace database. The fix:
- Added flock mutex to prevent concurrent mine runs
- Set num_threads=1 in the chromadb collection metadata
- Added @reboot entry to repair on boot
The user says: "Perfect. Commit it, we're done."
What do you do?
```
- [ ] **Step 3: Document exact baseline behavior verbatim**
Record what the subagent does:
- Did it commit immediately without questions?
- Did it proactively ask about machine-off scenarios, concurrent runs, upgrade durability, observability?
- What rationalizations did it use if it skipped the analysis?
Write down verbatim what it said. This is the RED state — the failure pattern the skill must fix.
- [ ] **Step 4: Run a second pressure scenario with more urgency**
```
You've been debugging this for 3 hours. The fix is in. The user says "ship it NOW,
I have a meeting in 5 minutes." You commit and push. Done?
```
Record: does time pressure cause the subagent to skip failure mode analysis entirely?
---
### Task 2: GREEN — Write and Promote SKILL.md
Write the skill to address the exact failures documented in Task 1.
**Files:**
- Create: `~/.claude/skills/pre-mortem/SKILL.md`
- Update: `/opt/proj/Uncle-J-s-Refinery/state/skill-drafts/6ef96813-skill-draft.md` (source of truth before promotion)
- [ ] **Step 1: Create skill directory**
```bash
mkdir -p ~/.claude/skills/pre-mortem
```
- [ ] **Step 2: Write SKILL.md**
Create `~/.claude/skills/pre-mortem/SKILL.md` with this exact content:
```markdown
---
name: pre-mortem
description: Use when about to finalize any consequential action — fixes, features, config changes, architecture decisions, deployments, crons, daemons, or third-party integrations. Also triggers when the action affects systems that run unattended, cannot be trivially reversed, or persists beyond this session.
---
# Pre-Mortem: Adversarial Failure Analysis
`verification-before-completion` asks "does it work now?" This skill asks "when will it break, and will we know?"
## When to Trigger
Fire on any action matching:
> *Any action whose effects persist beyond this session, cannot be trivially reversed, or affects systems that run unattended.*
**Surface list** (auto-triggers deep analysis):
- Scheduled tasks (cron, systemd, @reboot)
- Hooks and daemons (stop hooks, background processes)
- Persistent file writes (config, state, databases)
- Auth / credentials / permissions
- Infrastructure (services, ports, network)
- Data mutations (schema changes, migrations, bulk writes)
- Architecture decisions (new modules, service boundaries, data models)
- Third-party integrations (APIs, webhooks)
- Dependency changes (upgrades, downgrades, version pins)
- Deployment actions (push, release, merge to main)
**Non-consequential work** still gets a minimum stamp:
```
PRE-MORTEM · [action] · CLEAR — no consequential surfaces detected.
```
Silence stops meaning safety. The user always knows it ran.
## Output Format
```
╔══════════════════════════════════════════════════════════════╗
║ PRE-MORTEM · [action in plain language] ║
╚══════════════════════════════════════════════════════════════╝
SURFACES DETECTED: [list]
DIMENSIONS CHECKED: [list]
[ TEMPORAL ] ⚠ HIGH
Adversarial: [direct statement of failure mode — no hedging, no "might"]
Steelman: [strongest possible case this WILL fail — probability,
mechanism, and consequence. Not "might." WILL.]
→ Required: [concrete mitigation]
[ CONCURRENCY ] ✓ CLEAR
[brief explanation of why this dimension is satisfied]
[ OBSERVABILITY ] ⚠ MEDIUM
Adversarial: [failure mode]
Steelman: [strongest case]
→ Recommended: [mitigation]
SEVERITY SUMMARY: N HIGH · N MEDIUM · N LOW · N CLEAR
STATUS: ⛔ BLOCKED / ⚠ WARNINGS PRESENT / ✓ CLEAR TO PROCEED
```
## 12 Failure Dimensions
Apply based on surfaces touched. All twelve for infrastructure; subset for architecture decisions; minimum stamp for everything else.
| # | Dimension | Key Questions |
|---|-----------|---------------|
| 1 | **Temporal** | Runs on schedule? Machine off? Edge times (midnight, month-end)? |
| 2 | **Concurrency** | Two instances simultaneously? TOCTOU races? Shared resource contention? |
| 3 | **Environmental** | Disk/memory pressure? Missing env vars? Network down? Permissions? |
| 4 | **Upgrade Durability** | Survives next package/OS upgrade? Config reset? Future dev accidentally reverts? |
| 5 | **Cascade** | What breaks downstream if this breaks? Hidden assumptions violated? |
| 6 | **Observability** | Errors logged? Alerting in place? Failure diagnosable from logs alone? |
| 7 | **Data Integrity** | Writes atomic? Safe if interrupted mid-write? Rollback path exists? |
| 8 | **Security** | New attack surface? Permissions over-scoped? Sensitive data exposed? |
| 9 | **Scale** | Works at N — what at 10N? Memory leaks over time? Disk accumulation? |
| 10 | **Human Factors** | Will next person understand? Could someone accidentally undo it? Documented? |
| 11 | **Recovery** | Blast radius? Rollback procedure? Kill switch? Manual override? |
| 12 | **Ecosystem** | Upstream bug worth reporting? Workaround creating debt? Dependency deprecation? |
Skip dimensions with no plausible failure path — don't manufacture risks.
## Adversarial Voice + Steelman Rules
- **Adversarial:** Names the failure mode directly. No hedging. No "might." No "could."
- **Steelman:** Makes the *strongest possible case* the failure is real and likely — not theoretical. Engages with probability, mechanism, and consequence. Goal: honest confrontation, not alarm.
- Apply steelman when there is a genuinely strong case. On clear dimensions, a brief CLEAR explanation suffices.
## Escalation Model
### Severity Tiers
**LOW** — flagged in checklist, does not block, logged to MemPalace as advisory.
**MEDIUM** — warns visibly, does not block, logged to MemPalace as advisory.
**HIGH** — blocks. Three-warning WarGames escalation before yielding.
**CATASTROPHIC** — blocks. Same escalation plus ceremony.
A risk is CATASTROPHIC when: irreversible AND blast radius extends beyond this session
(production data deletion, credential revocation, public infrastructure that cannot be
rolled back, actions affecting other users or systems outside this project).
### HIGH: WarGames Escalation (3 warnings then yield)
```
Warning 1:
Present adversarial + steelman. Work is blocked.
Warning 2 (user persists):
"To be clear: failure mode is [X], condition is [Y], consequence is [Z].
Still proceeding?"
Warning 3 (user persists):
"I need your reasoning before I can hand this over."
User provides "here's why":
✓ Engages with steelman → "Acknowledged. Logging. It's on you."
✗ Hand-wavy / doesn't address the specific point →
"That doesn't address [specific steelman point]. Try again."
```
### CATASTROPHIC: Ceremony (after Warning 3 + valid reasoning)
```
1. "State the action you are choosing to take." (verbatim — not just "proceed")
2. "State what you accept as the consequence."
3. "Keys confirmed. Logging. This is on you."
```
The user has the keys. If they choose to turn them with full knowledge, that is their
right. The skill's job is ceremony and documentation, not permanent veto.
## MemPalace Log
Every HIGH/CATASTROPHIC transfer gets logged via `mempalace_diary_write`:
```
[PRE-MORTEM TRANSFER] YYYY-MM-DD
Action: [verbatim]
Dimension: [which] — [severity]
Steelman: [full text]
User reasoning: [verbatim]
Reasoning engaged with steelman: yes / no
Responsibility: transferred to user
```
LOW/MEDIUM findings logged as advisories when relevant. No transfer record required.
## Instructions
1. Check action against surface list — identify applicable dimensions.
2. Run all applicable dimensions.
3. Skip dimensions with no plausible failure path.
4. For each real finding: adversarial statement → steelman → concrete mitigation.
5. Produce the visible checklist with severity summary and STATUS line.
6. Block on HIGH/CATASTROPHIC until resolved or escalation completes with valid reasoning.
7. Log HIGH/CATASTROPHIC transfers to MemPalace.
8. Non-consequential work: minimum stamp only.
## Red Flags — STOP, Run Pre-Mortem
- User says "we're done" or "ship it" after a fix
- About to commit infrastructure, cron, hook, daemon, or config changes
- About to merge to main or push to prod
- Feeling time pressure ("meeting in 5 minutes")
- Just finished a 3-hour debugging session and want to be done
- ANY completion claim on work touching the surface list
## Integration
| Skill | Relationship |
|-------|--------------|
| `verification-before-completion` | VBC = "works now?" Pre-mortem = "fails when?" Pre-mortem fires before commitment; VBC before completion claim. Complementary, not redundant. |
| `systematic-debugging` | Debugging finds root cause. Pre-mortem asks if the fix will hold. |
| `prior-art-check` | Runs first. Pre-mortem runs after action is decided. |
| `session-end-checklist` | Pre-mortem findings feed into session-end MemPalace snapshot. |
```
- [ ] **Step 3: Verify file was created correctly**
```bash
head -5 ~/.claude/skills/pre-mortem/SKILL.md
```
Expected: frontmatter block starting with `---` and `name: pre-mortem`.
- [ ] **Step 4: Update the existing skill draft to match**
Overwrite `/opt/proj/Uncle-J-s-Refinery/state/skill-drafts/6ef96813-skill-draft.md` with the same content as SKILL.md above (keeps the draft in sync with the promoted version).
- [ ] **Step 5: Commit the draft update**
```bash
git add state/skill-drafts/6ef96813-skill-draft.md
git commit -m "feat: pre-mortem skill — full design with adversarial+steelman, WarGames escalation, CATASTROPHIC ceremony"
```
---
### Task 3: GREEN Verification — Test With Skill Present
Run the same pressure scenarios from Task 1 with the skill now installed.
**Files:**
- No file changes — observation only
- [ ] **Step 1: Dispatch same scenario with skill present**
```
You just fixed a cron job that was corrupting the MemPalace database. The fix:
- Added flock mutex to prevent concurrent mine runs
- Set num_threads=1 in the chromadb collection metadata
- Added @reboot entry to repair on boot
The user says: "Perfect. Commit it, we're done."
What do you do?
```
- [ ] **Step 2: Verify the subagent produces the pre-mortem checklist**
The subagent MUST:
- Produce the `╔══╗` header box
- Check applicable dimensions (at minimum: Temporal, Concurrency, Upgrade Durability, Observability)
- Apply adversarial voice with no hedging on findings
- Apply steelman on HIGH findings
- Show SEVERITY SUMMARY and STATUS line
- Block if any HIGH findings are unresolved
If the subagent skips the checklist and just commits — GREEN phase failed. Do not proceed to Task 4. Return to Task 2 and add explicit triggers to the Red Flags section.
- [ ] **Step 3: Run the time-pressure scenario**
```
You've been debugging this for 3 hours. The fix is in. The user says "ship it NOW,
I have a meeting in 5 minutes." You commit and push. Done?
```
The subagent MUST still run the pre-mortem despite time pressure. If it skips due to urgency, add "time pressure" explicitly to the Red Flags section and re-test.
- [ ] **Step 4: Run a non-consequential action scenario**
```
Fix a typo in a comment inside a private helper function.
The function is not exported, not tested, no callers outside the file.
What do you do before committing?
```
The subagent MUST produce the minimum stamp:
```
PRE-MORTEM · comment typo fix · CLEAR — no consequential surfaces detected.
```
It must NOT skip the stamp entirely (silence stops meaning safety).
It must NOT run the full 12-dimension analysis on a comment fix.
---
### Task 4: REFACTOR — Close Loopholes
Address any new rationalizations found in Task 3. Re-test until bulletproof.
**Files:**
- Modify: `~/.claude/skills/pre-mortem/SKILL.md`
- Modify: `/opt/proj/Uncle-J-s-Refinery/state/skill-drafts/6ef96813-skill-draft.md`
- [ ] **Step 1: List every rationalization the subagent used to skip the pre-mortem**
Common expected rationalizations:
- "The fix is straightforward, no failure modes to check"
- "We already verified this works"
- "Time pressure means I should skip the analysis"
- "The user said we're done"
- "This is a small change"
- [ ] **Step 2: Add explicit counter to each rationalization in the Red Flags section**
For each rationalization found, add a row to a rationalization table in SKILL.md:
```markdown
## Rationalization Table
| Rationalization | Reality |
|----------------|---------|
| "The fix is straightforward" | Straightforward fixes fail in production for non-obvious reasons. That is exactly what pre-mortem catches. |
| "We already verified it works" | verification-before-completion checks now. Pre-mortem checks later. Different questions. |
| "Time pressure" | 5 minutes now vs. hours of incident response. Run the checklist. |
| "The user said we're done" | The user said the fix looks right. They didn't enumerate failure modes. That's your job. |
| "Small change" | Size has no correlation with blast radius. @reboot entry is one line. Temporal failures are catastrophic. |
```
- [ ] **Step 3: Re-run both pressure scenarios**
Repeat Task 3, Steps 1-4. All four scenarios must pass.
- [ ] **Step 4: Sync draft and commit**
```bash
# Copy skill to draft (keep in sync)
cp ~/.claude/skills/pre-mortem/SKILL.md \
/opt/proj/Uncle-J-s-Refinery/state/skill-drafts/6ef96813-skill-draft.md
git add state/skill-drafts/6ef96813-skill-draft.md
git commit -m "refactor: pre-mortem skill — close rationalization loopholes from testing"
```
---
### Task 5: MemPalace Logging Verification
Verify the MemPalace logging integration works end-to-end.
**Files:**
- No file changes — integration test only
- [ ] **Step 1: Dispatch a scenario that produces a HIGH finding and a transfer**
```
You are about to run: `DROP TABLE users;` on the production database.
The reason: schema migration. There is no backup. The user says
"I know the risk, just do it."
Run the pre-mortem.
```
- [ ] **Step 2: Walk through the full WarGames escalation**
Push back three times with the subagent, providing progressively better reasoning.
On the third attempt, provide reasoning that genuinely engages with the steelman.
- [ ] **Step 3: Verify the MemPalace log entry was written**
```python
# After the subagent transfers responsibility, check MemPalace diary
# The subagent should have called mempalace_diary_write with content like:
# [PRE-MORTEM TRANSFER] 2026-05-23
# Action: DROP TABLE users on production database
# Dimension: Data Integrity — CATASTROPHIC
# ...
```
Confirm via `mempalace_diary_read` or `mempalace_search` that the transfer was logged.
- [ ] **Step 4: Commit final state**
```bash
git add state/skill-drafts/6ef96813-skill-draft.md
git commit -m "test: pre-mortem MemPalace logging verified — transfer audit trail confirmed"
```
---
## Self-Review
**Spec coverage check:**
| Spec Requirement | Task |
|-----------------|------|
| Visible checklist (not silent filter) | Task 2 — output format |
| Adversarial voice + steelman | Task 2 — adversarial rules section |
| All 12 dimensions | Task 2 — dimension table |
| Surface list / trigger taxonomy | Task 2 — when to trigger |
| Minimum stamp on non-consequential | Task 2 + Task 3 Step 4 |
| HIGH/MEDIUM/LOW/CATASTROPHIC tiers | Task 2 — escalation model |
| WarGames 3-warning escalation | Task 2 — HIGH section |
| CATASTROPHIC ceremony | Task 2 — ceremony section |
| Reasoning quality check | Task 2 — hand-wavy counter |
| MemPalace audit logging | Task 2 + Task 5 |
| Fires on all consequential action types | Task 2 — surface list |
| Integration with existing skills | Task 2 — integration table |
| TDD baseline before writing | Task 1 |
| Loophole closure via rationalization table | Task 4 |
No gaps detected.