#[non_exhaustive]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 (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: StringUnique provider identifier (e.g. "openai", "anthropic").
display_name: StringHuman-readable display name.
description: StringShort description of the provider.
category: StringProvider category (e.g. "cloud", "local").
family: StringProvider family used to group related providers.
auth_mode: StringAuthentication mode: "none", "literal", or "secret".
key_var: StringEnvironment variable name that holds the API key (empty if not required).
literal_auth_token: StringLiteral auth token embedded in the catalog (only set when auth_mode = "literal").
base_url: StringBase URL for the provider’s web interface.
default_model: StringDefault 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: StringURL 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
impl CapabilityProfile for ServiceDescriptor
Source§fn auth_strategy(&self) -> AuthStrategy
fn auth_strategy(&self) -> AuthStrategy
Source§fn clears_anthropic_api_key(&self) -> bool
fn clears_anthropic_api_key(&self) -> bool
Source§fn supports_model_tiers(&self) -> bool
fn supports_model_tiers(&self) -> bool
Source§fn supports_tool_calling(&self) -> bool
fn supports_tool_calling(&self) -> bool
true if any model offered by this provider supports tool/function calling.Source§fn supports_vision(&self) -> bool
fn supports_vision(&self) -> bool
true if any model offered by this provider accepts image input.Source§fn supports_streaming(&self) -> bool
fn supports_streaming(&self) -> bool
true if the provider supports streaming completions.Source§fn context_limit(&self) -> Option<u64>
fn context_limit(&self) -> Option<u64>
None if unknown.Source§impl Clone for ServiceDescriptor
impl Clone for ServiceDescriptor
Source§fn clone(&self) -> ServiceDescriptor
fn clone(&self) -> ServiceDescriptor
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ServiceDescriptor
impl Debug for ServiceDescriptor
Source§impl Default for ServiceDescriptor
impl Default for ServiceDescriptor
Source§fn default() -> ServiceDescriptor
fn default() -> ServiceDescriptor
Source§impl<'de> Deserialize<'de> for ServiceDescriptor
impl<'de> Deserialize<'de> for ServiceDescriptor
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for ServiceDescriptor
impl PartialEq for ServiceDescriptor
Source§fn eq(&self, other: &ServiceDescriptor) -> bool
fn eq(&self, other: &ServiceDescriptor) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for ServiceDescriptor
impl Serialize for ServiceDescriptor
impl StructuralPartialEq for ServiceDescriptor
Auto Trait Implementations§
impl Freeze for ServiceDescriptor
impl RefUnwindSafe for ServiceDescriptor
impl Send for ServiceDescriptor
impl Sync for ServiceDescriptor
impl Unpin for ServiceDescriptor
impl UnsafeUnpin for ServiceDescriptor
impl UnwindSafe for ServiceDescriptor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::RequestSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().impl<T> Scalar for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.