Skip to main content

ProviderModelSupport

Trait ProviderModelSupport 

Source
pub trait ProviderModelSupport: AsRef<str> {
    // Required methods
    fn supports_reasoning_effort(&self, model: &str) -> bool;
    fn supports_service_tier(&self, model: &str) -> bool;

    // Provided methods
    fn supports_reasoning(&self, model: &str) -> bool { ... }
    fn supported_reasoning_efforts(
        &self,
        model: &str,
    ) -> &'static [&'static str] { ... }
    fn supports_service_tier_value(
        &self,
        model: &str,
        tier: OpenAIServiceTier,
    ) -> bool { ... }
}
Expand description

Extension trait on Provider for model-specific capability queries.

These methods require vtcode-config model catalogs and constants, so they cannot live in vtcode-commons with the core Provider type.

Required Methods§

Source

fn supports_reasoning_effort(&self, model: &str) -> bool

Determine if the provider supports configurable reasoning effort for the model.

Source

fn supports_service_tier(&self, model: &str) -> bool

Determine if the provider supports the service_tier request parameter.

Provided Methods§

Source

fn supports_reasoning(&self, model: &str) -> bool

Determine if the provider/model exposes structured reasoning output.

Catalog metadata is authoritative for curated models. Unknown routes retain the provider’s legacy capability fallback so custom endpoints continue to work without a catalog entry.

Source

fn supported_reasoning_efforts(&self, model: &str) -> &'static [&'static str]

Exact effort levels accepted by the provider/model route.

Source

fn supports_service_tier_value( &self, model: &str, tier: OpenAIServiceTier, ) -> bool

Determine if the provider supports a specific service_tier value. ultrafast is a native-OpenAI-only tier: every other provider, including OpenAI-compatible gateways that omit it wire-side, reports false even when it accepts flex/priority.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§