Escalation Pipeline • AI Agent SDK
EscalationPipeline: Progressive escalation pipeline for agent execution.
EscalationPipeline
Defined in the pipeline module.
AI Agent
Progressive escalation pipeline for agent execution.
Implements a staged approach to task execution:
- Stage 0 (DIRECT): Immediate response without tools
- Stage 1 (HEURISTIC): Tool selection based on local signals
- Stage 2 (PLANNED): Lightweight planning with single LLM call
- Stage 3 (AUTONOMOUS): Full autonomous loop with verification
Constructor
ParamField
Optional[EscalationConfig]No description available.
ParamField
OptionalNo description available.
ParamField
OptionalNo description available.
ParamField
OptionalNo description available.
ParamField
OptionalNo description available.
Methods
analyze()
Analyze prompt and recommend initial stage.
execute()Execute prompt with automatic escalation.
execute_at_stage()Execute prompt at specific stage.
get_current_stage()Get current execution stage.
get_context()Get current execution context.
Usage
pipeline = EscalationPipeline()
# Analyze and execute
result = await pipeline.execute("Refactor the auth module")
# Or analyze first, then execute
stage = pipeline.analyze("Simple question")
result = await pipeline.execute_at_stage("Simple question", stage)Source
View on GitHubpraisonaiagents/escalation/pipeline.py at line 24