Skip to main content

ServiceDescriptor

Struct ServiceDescriptor 

Source
pub struct ServiceDescriptor {
Show 19 fields pub id: String, pub display_name: String, pub description: String, pub category: String, pub family: String, pub auth_mode: String, pub key_var: String, pub literal_auth_token: String, pub base_url: String, pub default_model: String, pub model_tiers: HashMap<String, String>, pub model_choices: Vec<ModelChoice>, pub test_url: String, pub setup: Vec<String>, pub usage: Vec<String>, pub api_base_url: Option<String>, pub npm_package: Option<String>, pub doc_url: Option<String>, pub models: Vec<ModelDescriptor>,
}
Expand description

Describes an LLM provider service with all metadata needed to connect and use it.

Fields§

§id: String

Unique provider identifier (e.g. "openai", "anthropic").

§display_name: String

Human-readable display name.

§description: String

Short description of the provider.

§category: String

Provider category (e.g. "cloud", "local").

§family: String

Provider family used to group related providers.

§auth_mode: String

Authentication mode: "none", "literal", or "secret".

§key_var: String

Environment variable name that holds the API key (empty if not required).

§literal_auth_token: String

Literal auth token embedded in the catalog (only set when auth_mode = "literal").

§base_url: String

Base URL for the provider’s web interface.

§default_model: String

Default model ID used when no model override is specified.

§model_tiers: HashMap<String, String>

Named model tiers mapping tier name → model ID (e.g. "fast""gpt-4o-mini").

§model_choices: Vec<ModelChoice>

Legacy list of available model choices (claudy-specific).

§test_url: String

URL used to test connectivity to the provider.

§setup: Vec<String>

Setup instructions shown to the user during first-time configuration.

§usage: Vec<String>

Usage examples shown to the user in the install wizard.

§api_base_url: Option<String>

API base URL override (models.dev-compatible field).

§npm_package: Option<String>

npm package name (models.dev-compatible field, for AI coding tools).

§doc_url: Option<String>

Link to provider documentation.

§models: Vec<ModelDescriptor>

Full list of models offered by this provider.

Trait Implementations§

Source§

impl CapabilityProfile for ServiceDescriptor

Source§

fn auth_strategy(&self) -> AuthStrategy

How the provider authenticates API requests.
Source§

fn clears_anthropic_api_key(&self) -> bool

Whether the Anthropic API key should be cleared before calling this provider.
Source§

fn supports_model_tiers(&self) -> bool

Whether the provider supports model tiers (e.g. fast vs. powerful model aliases).
Source§

fn supports_tool_calling(&self) -> bool

Returns true if any model offered by this provider supports tool/function calling.
Source§

fn supports_vision(&self) -> bool

Returns true if any model offered by this provider accepts image input.
Source§

fn supports_streaming(&self) -> bool

Returns true if the provider supports streaming completions.
Source§

fn context_limit(&self) -> Option<u64>

Maximum context window in tokens across all models, or None if unknown.
Source§

impl Clone for ServiceDescriptor

Source§

fn clone(&self) -> ServiceDescriptor

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ServiceDescriptor

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for ServiceDescriptor

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.