A Runbook Authoring Prompt That Writes the Whole Runbook
Turn a service description into a complete runbook with one reusable runbook authoring prompt: failure modes, diagnostics, recovery, and an escalation matrix.
The honest truth about runbooks: most teams know they need them, write three, and let the rest rot as TODO links in a wiki. Writing a good one from scratch takes an afternoon nobody has during a quiet week and that nobody can spare during a loud one. A runbook authoring prompt breaks that loop by turning a service description into a complete draft you edit instead of author.
The keyword here is complete. A prompt that returns "here are some steps you might take" wastes your time. The one worth reusing returns four locked sections: a failure-mode catalog, a diagnostic guide per failure, recovery and rollback procedures with actual commands, and an escalation matrix. Same shape for every service.
This post shows how to build it, why the vendor guides won't help, and where the model needs a human before the runbook goes live.
What a runbook authoring prompt produces
A runbook authoring prompt is a reusable AI prompt that converts a service description plus its dependencies and recent incidents into a structured operational runbook. The output contract is fixed: failure modes, diagnostics, recovery, escalation. The reliability of the format is the product.
Search "runbook automation" and you'll find vendor tooling, not authoring help. The incident.io runbook automation guide is a thorough comparison of platforms that execute runbooks, and it assumes the hard part, writing the thing, happens somewhere else. The one popular AI runbook gist on GitHub is a single prompt with no variables and no locked output, so two engineers get two different shapes. Neither solves the repetition problem.
What you can do with this prompt
- Generate a first-draft runbook for a service that has none, in minutes instead of an afternoon.
- Backfill runbooks across a whole service catalog with one consistent structure.
- Turn the patterns from your last ten incidents into named failure modes with diagnostics.
- Produce an escalation matrix that maps severity to who gets paged and when.
- Refresh a stale runbook by re-running with the latest dependency list and incident history.
Anatomy of the prompt pack
Variables
{{service_description}} – what it does, runtime, key dependencies
{{dependencies}} – upstream/downstream services, data stores
{{recent_incidents}} – last 5-10 incidents: symptom + cause + fix
{{severity_levels}} – your sev definitions (sev1..sev4)
{{escalation_contacts}} – teams/roles, NOT individuals' phone numbers
Prompt
Role: SRE writing a runbook on-call will use under pressure.
Task: build a runbook from the service description and incident history.
Output contract (locked):
1. Failure-mode catalog – named modes, likely symptoms
2. Diagnostic guide – per mode: what to check, in what order
3. Recovery & rollback – exact steps, marked [VERIFY] where guessed
4. Escalation matrix – severity -> who to page -> when
5. Gaps – what the author must fill before publishing
The recent_incidents variable is what turns a generic runbook into yours. Anthropic and others have noted the pattern that works: audit the last 50 incidents, find the top 10 repeating modes, and define diagnostics for each rather than handing an agent open-ended authority. The prompt does the same with whatever incident history you paste in.
The single most dangerous thing an AI-authored runbook can do is print a confident rollback command that's wrong for your setup. Instruct the prompt to tag any command it inferred rather than knows with a literal [VERIFY] marker. Then your review pass is a search for [VERIFY], not a re-read of the whole document. A runbook with three honest [VERIFY] tags beats one that reads clean and bricks prod on the first rollback.
How models behave when authoring runbooks
The differences are concrete enough to plan around.
Claude is the steadiest at holding the four-section contract through a long service description and keeps diagnostics ordered by likelihood rather than dumping a flat checklist. GPT-4o writes crisper recovery steps but tends to omit the escalation matrix unless it's the last instruction in the prompt; restate it on the final line. Gemini produces good failure-mode catalogs from sparse input but is the most likely to invent a command, so the [VERIFY] discipline matters most there.
| Job | Claude | ChatGPT (GPT-4o) | Gemini |
|---|---|---|---|
| Holds the 4-section contract | Strong | Good | Moderate |
| Orders diagnostics by likelihood | Strong | Good | Moderate |
| Keeps the escalation matrix | Reliable | Needs it stated last | Reliable |
| Avoids inventing commands | Good with [VERIFY] | Good with [VERIFY] | Needs [VERIFY] most |
No model knows your rollback command. That's not promptable. It's why the gaps section exists.
Prompt-craft patterns
Pattern 1 — incident-grounded failure modes. Derive the catalog from real history, not from imagination.
Build the failure-mode catalog primarily from {{recent_incidents}}.
Only add modes not seen in history if they're obvious for this
service type, and label those "INFERRED".
Pattern 2 — diagnostics as ordered checks. A runbook used under stress needs an order, not a menu.
For each failure mode, list diagnostic checks in the order an
engineer should run them, fastest-to-rule-out first. Number them.
Pattern 3 — the escalation refusal. Don't let the model invent who to page.
Use only the roles in {{escalation_contacts}}. Never invent a
person, team, or contact method. If a severity has no mapped
contact, write "ESCALATION GAP" and list it under Gaps.
Here's the opinionated part: an escalation matrix is the section everyone skips and the one that matters most at 3 a.m. A runbook that nails diagnostics but leaves "who gets paged" blank fails exactly when it's needed. Force the matrix, and force the model to flag the gap rather than fill it with a guess.
Variables you'll set
| Variable | Required | What it is |
|---|---|---|
{{service_description}} | Yes | What the service does, runtime, key deps |
{{dependencies}} | Yes | Upstream/downstream services and data stores |
{{recent_incidents}} | Recommended | Last 5-10 incidents as symptom/cause/fix |
{{severity_levels}} | Yes | Your sev definitions |
{{escalation_contacts}} | Yes | Roles/teams to page, not personal numbers |
Getting started
- List the service's dependencies and pull the last ten incidents.
- Fill
{{recent_incidents}}with a one-line symptom, cause, and fix for each. - Run the prompt on Claude for contract fidelity.
- Search the output for
[VERIFY]and confirm every tagged command. - Resolve every line under "Gaps" and "ESCALATION GAP" before publishing.
- Re-run quarterly with fresh incidents so the runbook doesn't rot.
A runbook is the thing your on-call shift reaches for. The handoff that hands it over matters just as much, which is why this pairs with the on-call handoff brief prompt for turning 48 hours of alert noise into a clean shift summary. And when a runbook step fails to prevent an outage, the blameless incident postmortem prompt feeds new failure modes right back into your next runbook draft.
An untested runbook is a hypothesis. A gameday is how you test it. The recovery steps a runbook prompt drafts should be exercised in a controlled failure injection before you bet an outage on them. Author the runbook, then schedule the gameday that proves the rollback actually works.
In the catalog, the Agent Operations Runbook Generator covers this exact job, and the Incident Postmortem Agent Pack turns the incidents that feed your {{recent_incidents}} variable into structured timelines.
The Agent Operations Runbook Generator ships this end-to-end as four locked prompts: a Failure Mode Catalog, a Diagnostic Steps Guide, Recovery & Rollback Procedures, and an Escalation Matrix, so you fill variables instead of inventing structure. It's part of The Complete AI Prompts Bundle, a one-time lifetime license to the whole catalog plus future packs, worth it if you're backfilling runbooks across more than one service.
Write the runbook the way you'd want it at 3 a.m.: named failure modes, ordered diagnostics, verified commands, and a clear page. The prompt gets you 80% there. The [VERIFY] pass and the gaps section get you the rest.
Common questions
What is a runbook authoring prompt?
Can AI write a runbook for incident response?
What should every runbook contain?
Get the prompt packs this guide is built on
Ready-to-paste prompts with documented variables and usage guides for ChatGPT, Claude, and Gemini. One-time payment, own it forever.
More prompt guides

Gemini vs Claude for Long-Context Code: Window or Accuracy
The honest framing of Gemini vs Claude for long-context code isn't which model is smarter. It's a tradeoff between two different things: how much code you can fit in one prompt, and how often the mode…

An OKR Drafting Prompt That Catches Vanity Key Results
An OKR drafting prompt has to fight the model's strongest instinct: handing back something that sounds like a goal but can't be measured. Ask any model for key results and you'll get "increase user en…

A Technical Design Doc Prompt That Holds the RFC Structure
A technical design doc prompt earns its keep when it stops every author from inventing a new doc structure. Context, the options you considered, why you picked one, what breaks, how you roll it out. S…