Skip to main content
The escalation pipeline adjusts execution complexity from simple answers to full autonomous loops — all via Agent(autonomy=True).
The user sends a prompt; the agent escalates from direct answers to heuristic, planned, or autonomous execution based on task signals.

How It Works

Escalation Stages

Quick Start

1

Enable autonomy

2

Custom configuration


Stages and Signals


CLI


Pipeline Components

Under praisonaiagents/escalation/:
  • Doom loop detector — identical calls and no-progress patterns
  • Loop guard — idempotency-aware tool-call guardrails on every Agent. See Loop Guard.
  • Pipeline orchestration — escalation triggers and recovery
  • Observability hooks — metrics for escalation events

Best Practices

Pass autonomy=True or an AutonomyConfig — the agent selects the stage automatically during execution.
Call analyze_prompt() to preview complexity without an LLM call when building UIs or routing logic.
Lower the threshold (e.g. 3) for agents that may repeat tool calls; raise it for exploratory coding tasks.
No standalone pipeline objects — escalation, loop guard, and doom-loop detection live on Agent.

Doom Loop Detection

Pattern-based detection of stuck agent loops

Subagent Delegation

Delegate subtasks when autonomy escalates