Skip to main content

resolve

Function resolve 

Source
pub fn resolve(
    cli_provider: Option<&str>,
    cli_model: Option<&str>,
    cli_thinking: Option<ThinkingLevel>,
    cli_api_key: Option<&str>,
    cli_base_url: Option<&str>,
) -> Result<ResolvedModel, ResolveError>
Expand description

Resolve the provider + model + thinking level from the CLI flags + env + ~/.rpi/ config.

cli_provider is the --provider value (optional). cli_model is the --model value (optional; may be provider/id[:thinking] or id[:thinking]). cli_thinking is the --thinking value (optional). cli_api_key is the --api-key value (optional; highest-priority x-api-key source). cli_base_url is the --base-url value (optional; overrides ANTHROPIC_BASE_URL + each model’s base_url).