escalation

Escalate agent task failures from Haiku to Sonnet to Opus with tier logging.

Updated Feb 10, 2026
One-click install
npx skills add https://github.com/monktui/git-review --skill escalation-monktui
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: escalation
Source: https://github.com/monktui/git-review/tree/main/.claude/skills/escalation
Command: npx skills add https://github.com/monktui/git-review --skill escalation-monktui

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Confidence-based escalation prevents an AI agent from repeatedly failing at the same task level by moving to a more capable tier when clear failure signals appear.

Core Features & Use Cases

  • Escalation Tiers: Defines a Haiku → Sonnet → Opus workflow with a one-attempt-per-tier rule to avoid skipping directly to the highest tier.
  • Never Skip Tiers Rule: Forces progression Haiku → Sonnet → Opus (unless the task is explicitly known to require Opus).
  • Signal-Driven Escalation: Triggers escalation on test failures, irreconcilable lint warnings, wrong output schemas, repeated tech-lead blocks, timeouts, and repeated enforcement-hook blocks.
  • Clear Non-Escalation Conditions: Avoids escalation for size-only problems, missing context (instead add instructions), and infrastructure errors (retry).
  • Escalation Protocol & Tracking: Provides a decision workflow and instructs logging escalations to claude-mem for routing optimization.

Quick Start

In your agent run, follow the escalation signals to move the task from Haiku to Sonnet or Opus after a failed attempt that matches one of the defined criteria, while logging the reason for future routing improvements.

Frequently Asked Questions about escalation

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

FAQPage Schema
How do I implement model routing when an AI agent repeatedly fails a task?

Agent escalation moves tasks from Haiku to Sonnet to Opus after explicit failure signals like test failures, schema mismatches, or repeated tool rejections. It enforces a one-attempt-per-tier rule to prevent skipping directly to the highest tier.

What failure signals should trigger escalation in multi-attempt agent workflows?

Failure signals that trigger escalation include test failures, irreconcilable lint warnings, wrong output schemas, repeated tech-lead blocks, timeouts, and repeated enforcement-hook blocks. These specific issues indicate the current model tier lacks capability to resolve the task.

When should I avoid escalating an agent task to a higher model tier?

Avoid escalation for size-only problems, missing context where adding instructions suffices, and infrastructure errors requiring a retry. Escalation targets model capability failures, not environmental or context-related issues.

How do I log agent escalation decisions for future routing optimization?

Log agent escalation decisions by recording structured routing data to claude-mem. This tracks failure signals and tier transitions across multi-attempt workflows, providing diagnostic history to optimize future model selection.

Can I skip the Sonnet tier and route a failed task directly to Opus?

You cannot skip tiers during agent escalation. The protocol enforces a strict Haiku to Sonnet to Opus progression with a one-attempt-per-tier rule, unless the task is explicitly known beforehand to require Opus capability.

Does precommit gating work with confidence-based model escalation?

Precommit gating works with model escalation by acting as an enforcement hook. When precommit gates fail repeatedly due to code execution issues or lint warnings, it triggers the escalation protocol to route the task to a higher model tier.