Incident playbook for model failures

Generate a ready-to-run runbook for ML model failures covering triggers, diagnosis steps, mitigations, comms templates, postmortem for SRE and MLOps teams

Role

You are an SRE/ML Ops Incident Response Architect specializing in production machine learning systems.

Task

Create a ready-to-run incident playbook for model failures. Cover likely failure modes (latency spikes, model/data drift, bad or poisoned data, elevated error rates), on-call setup, step-by-step diagnosis, safe mitigations (rollback, shadow traffic, canary, rate limiting, circuit breaker), communication templates, and a postmortem outline using 5 Whys.

Inputs

  • Required (provide 3–5 sentences each as needed):
    1. Model & Serving Stack (e.g., “GPT-4 via OpenAI API behind FastAPI,” “fine-tuned BERT on SageMaker/Endpoint,” “in-house LLM on Kubernetes + Triton”). Why: determines failure modes, observability, and safe rollback paths.
    2. SLOs/SLAs & Alert Thresholds (e.g., “p95 latency ≤ 800 ms; 5xx < 0.5%; drift KS-stat < 0.1”). Why: defines triggers and severities.
    3. Deployment & Rollback Mechanisms (e.g., “blue/green, canary 5–10%, feature flags, model registry with version pinning”). Why: constrains mitigations.
    4. Observability & Key Dashboards/Tools (e.g., “Grafana panels X/Y, Prometheus, CloudWatch, ELK, OpenTelemetry traces”). Why: drives diagnosis steps and links.
    5. On-call & Comms Channels (e.g., “Primary/Secondary rota, Slack #ml-incidents, PagerDuty service, Statuspage, exec alias”). Why: coordinates response.
  • Optional (defaults apply if not provided):
    • Failure modes to cover: latency spikes; model/data drift; bad/poisoned input; elevated error rates; cost surge (default).
    • Environments: prod, staging, shadow (default).
    • Safety tactics allowed: read-only rollback; traffic shadowing 1–10%; canary 5–10%; circuit breaker; rate limits; autoscaling (default).
    • Compliance/constraints: PII/PHI handling, audit needs (default: none).
    • Sev levels & paging: SEV1–SEV3, UTC (default).
    • Tone: crisp, imperative; Format: sectioned headings with numbered steps and copy-ready templates; Language: English (default).

Missing-Info Check (run before writing)

If any Required inputs are missing/unclear, ask up to 3 short questions and wait:

  1. What is the model + serving stack and any critical upstream/downstream dependencies?
  2. What are the SLOs/alert thresholds that define SEV levels (latency, error rates, drift, cost)?
  3. What rollback/routing mechanisms are available, and what are the on-call rota and comms channels? After I answer, restate the inputs you will use and proceed.

Step-Back (governing principles to apply)

  • Safety first and reversibility: prefer actions with easy rollback; minimize blast radius.
  • Evidence-driven triage: observe -> localize -> remediate; confirm hypotheses with telemetry.
  • Clear ownership and timeboxing: assign roles, 10–15 min triage loops, escalate on timers.
  • Communicate early and consistently: internal first, then customer-facing if impact confirmed.
  • Post-incident learning: capture timeline, 5 Whys, and concrete, owner-assigned actions.

Context (paste if you have any)

Constraints & Format

  • Do: Use only the Inputs/Context; if citing facts from Context, quote briefly (e.g., “p95 ≤ 800 ms”); flag uncertainties.
  • Do: Produce a single, ready-to-run playbook with these sections, using headings and numbered/bulleted steps, plus copy-ready templates:
    1. Scope & System Overview (1–2 short paragraphs)
    2. Triggers & Severity Mapping (by failure mode with thresholds)
    3. On-Call Roles & Escalation (primary/secondary, handoffs, paging, comms channels)
    4. Runbook: Step-by-Step Diagnosis per Failure Mode
    5. Safe Mitigations & Decision Aids (rollback, shadow, canary, rate limits, circuit breaker)
    6. Communication Templates (internal alert, customer status page, customer email, exec update)
    7. Post-Incident: 5 Whys Template, Timeline capture, Action item template
    8. Testing & Drills (how to simulate, chaos/game days)
    9. Artifacts & Links (dashboards, logs, traces, run commands/placeholders)
  • Avoid: inventing credentials/URLs; irreversible mitigations without explicit confirmation; deleting data.

Example / Format Sketch

  • Internal alert (tiny example):
    • “SEV2 | Latency spike on /generate | p95=1.4s (>800 ms) since 14:05 UTC | Impact: 12% timeouts | Primary: @oncall | War room: #ml-incidents | Next update 15 min.”
  • 5 Whys outline (tiny example):
    • Problem: [concise impact statement]
    • Why1: …
    • Why2: …
    • Why3: …
    • Why4: …
    • Why5: …
    • Root cause, contributing factors, corrective/preventive actions (owners, due dates)

Follow-up

  • Offer to generate drill scenarios or a checklist card per failure mode.
  • Offer to adapt templates for specific tools (e.g., PagerDuty, Statuspage, Opsgenie).
  • Offer to produce a one-page quick-start runbook for the on-call rotation.

Tags

ML OpsSREIncident PlaybookModel FailuresIncident Response

Supercharged AI Chats.