# Models
pic talks to Anthropic, OpenAI (Chat Completions and Responses), OpenRouter, Google and any
OpenAI-compatible server, with Pi's thinking levels. One conversation can move between providers.
## Choosing a model
`--model provider/id` picks the model for one command; `pic models --default NAME`, or Ctrl+S in the
terminal interface's model picker, saves the default (setting `defaultModel`). `pic models` lists
the models whose provider has a key, `--all` every one, and `--refresh` fetches Pi's catalog now. In
the terminal interface, Alt+P or `/model` opens the picker and Ctrl+P cycles models;
`/scoped-models` (or `pic scoped-models --set PATTERN...`) chooses the models Ctrl+P cycles.
## Thinking
`--thinking LEVEL` takes off, minimal, low, medium, high, xhigh or max, as the model supports them.
Without it pic uses the level saved for the model (`thinkingLevel:MODEL`), then
`defaultThinkingLevel`, else medium. `pic models --thinking-default LEVEL` saves the default;
Shift+Tab cycles levels in the terminal interface.
## The catalog and models.json
The model list is Pi's catalog: a snapshot built into pic, refreshed from pi.dev when it is newer.
`PIC_MODEL_CATALOG=offline` never fetches it. Models and providers of your own go in
`~/.pic/models.json` (Pi's `~/.pi/agent/models.json` is read when pic has none), in Pi's format;
`PIC_MODELS_FILE` names another file. A key written there comes before the provider's variable and
the credential store ([credentials](credentials.md)).
## Prompt caching
The `cacheRetention` setting is short (the default), long (1 hour; OpenAI 24 hours) or none, as
Pi's; `PI_CACHE_RETENTION=long` works too.