> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cascadeflow.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Presets

> One-line agent creation with preset profiles — cost-optimized, balanced, speed, quality, and development configurations.

# Presets

Create a `CascadeAgent` with a single function call using preset profiles that configure models, quality thresholds, and routing strategies.

## Preset Functions

```python theme={null}
from cascadeflow.utils.presets import (
    get_cost_optimized_agent,
    get_balanced_agent,
    get_speed_optimized_agent,
    get_quality_optimized_agent,
    get_development_agent,
    auto_agent,
)
```

### Cost Optimized

Maximizes savings by using the cheapest models first with aggressive cascading.

```python theme={null}
agent = get_cost_optimized_agent(verbose=True)
```

### Balanced

Default tradeoff between cost, quality, and speed.

```python theme={null}
agent = get_balanced_agent()
```

### Speed Optimized

Prioritizes low latency — prefers fast models and direct routing.

```python theme={null}
agent = get_speed_optimized_agent()
```

### Quality Optimized

Prioritizes response quality — higher thresholds, more willing to escalate to verifier.

```python theme={null}
agent = get_quality_optimized_agent()
```

### Development

Uses free/local models for development and testing.

```python theme={null}
agent = get_development_agent(verbose=True)
```

### Auto Agent

Create from a profile name string.

```python theme={null}
agent = auto_agent("cost_optimized")
agent = auto_agent("balanced")
agent = auto_agent("speed_optimized")
agent = auto_agent("quality_optimized")
agent = auto_agent("development")
```

## From Profile

`CascadeAgent.from_profile()` is the class method equivalent:

```python theme={null}
from cascadeflow import CascadeAgent

agent = CascadeAgent.from_profile("balanced", verbose=True)
```

## From Environment

Auto-detect available providers from environment variables:

```python theme={null}
agent = CascadeAgent.from_env(verbose=True)
# Detects OPENAI_API_KEY, ANTHROPIC_API_KEY, GROQ_API_KEY, etc.
```
