Autonomy Modes
PraisonAI CLI supports different autonomy levels that control how much freedom the AI has when making changes to your code. Inspired by Codex CLI’s approval modes, this feature lets you balance speed with safety.Overview
Autonomy modes determine whether the AI needs your approval before taking actions like editing files or running commands.Quick Start

Usage
Modes Explained
Suggest Mode (Default)
The safest mode. Every action requires your explicit approval.- ✅ File reads - Auto-approved
- ❓ File writes - Requires approval
- ❓ Shell commands - Requires approval
- ❓ File deletions - Requires approval
Auto-Edit Mode
Balanced mode for normal development. File edits are auto-approved, but shell commands still require approval.- ✅ File reads - Auto-approved
- ✅ File writes - Auto-approved
- ❓ Shell commands - Requires approval
- ❓ File deletions - Requires approval
Full Auto Mode
Maximum speed, minimum interruption. Use only for trusted tasks.- ✅ File reads - Auto-approved
- ✅ File writes - Auto-approved
- ✅ Shell commands - Auto-approved
- ✅ File deletions - Auto-approved
Python API
Basic Usage
Requesting Approval
Custom Approval Callback
reason field automatically: rejecting a tool call in the Rich prompt or Textual TUI captures your one-line reason and returns it to the agent. See Reject with a Reason.
Action Types
The system recognizes different types of actions:Approval Policies
Each mode has a policy that defines what’s auto-approved:Custom Policies
Create custom policies for specific needs:Remembered Decisions
The autonomy manager can remember your decisions for similar actions:Statistics
Track approval statistics:Best Practices
When to Use Each Mode
Safety Tips
- Start with suggest mode - Get familiar with what the AI does
- Review full_auto tasks - Read the task description carefully
- Use git - Always have uncommitted changes backed up
- Set blocked actions - Prevent dangerous operations
- Monitor statistics - Track what’s being auto-approved
SDK Bridge
The CLI autonomy system bridges to the Core SDK’s approval and autonomy systems:- DRY enum values: CLI
AutonomyModederives values from SDKAutonomyLevel(single source of truth) - Approval bridging:
AutonomyManager.set_mode(FULL_AUTO)setsPRAISONAI_AUTO_APPROVE=trueso SDK tools auto-approve - Conversion: Use
mode.to_sdk_level()to convert CLI mode to SDK enum
Since PR #4878, the
FULL_AUTO → PRAISONAI_AUTO_APPROVE=true → ApprovalRegistry bridge works reliably for CLI sessions too. CLI sessions install InteractiveCLIApprovalBackend, and before #4878 that attached backend skipped the env-var check and prompted anyway; now the env var is honoured on the attached-backend path. See Standing grants and attached backends.Environment Variables
Related Features
- AutonomyConfig - SDK autonomy configuration
- Autonomy Concept - Architecture and design
- Slash Commands - Interactive commands
- Sandbox Execution - Isolated command execution
- Git Integration - Safe code changes with git

