Expand description
Model selection and detection logic.
Handles model name resolution with the following priority:
- CHANT_MODEL env var (explicit override)
- ANTHROPIC_MODEL env var (Claude CLI default)
- defaults.model in config
- Parse from
claude --versionoutput (last resort)
All model names are normalized to shorthand (e.g., “claude-sonnet-4-20250514” -> “sonnet”).
Functions§
- get_
model_ name - Get the model name using the following priority:
- get_
model_ name_ with_ default - Get the model name with an optional default from config. Used by parallel execution where full Config isn’t available.