## Install ControlFlow

Install ControlFlow with your preferred package manager:

<CodeGroup>
```bash pip
# ControlFlow requires Python 3.9 or greater
pip install -U controlflow 
```

```bash uv
# ControlFlow requires Python 3.9 or greater
uv pip install -U controlflow --prerelease=allow
```
</CodeGroup>

## Provide an API Key

### OpenAI

ControlFlow's default LLM is OpenAI's GPT-4o model, which provides excellent performance out of the box. To use it, you'll need to provide an API key as an environment variable:

```bash
export OPENAI_API_KEY="your-api-key"
```

### Anthropic

ControlFlow also ships with built-in support for Anthropic. To use an Anthropic model, you'll need to provide an API key as an environment variable and configure the default LLM:

```bash
export ANTHROPIC_API_KEY="your-api-key"
export CONTROLFLOW_DEFAULT_LLM="anthropic/claude-3-5-sonnet-20240620"
```

### Other Providers

ControlFlow supports many other LLM providers as well, though you'll need to install their respective packages and configure the default LLM appropriately. See the [LLM documentation](/guides/llms) for more information.
