pub struct ModelDescriptor {
pub id: String,
pub name: String,
pub family: Option<String>,
pub release_date: Option<String>,
pub cost: Option<ModelCost>,
pub limit: Option<ModelLimit>,
pub modalities: Option<ModelModalities>,
pub capabilities: Option<ModelCapabilities>,
pub knowledge: Option<String>,
}Expand description
A model offered by a provider (models.dev-compatible).
Fields§
§id: StringUnique model identifier (e.g. "gpt-4o", "claude-sonnet-4-6").
name: StringHuman-readable model name.
family: Option<String>Model family grouping (e.g. "gpt-4", "claude-3").
release_date: Option<String>ISO 8601 date the model was released.
cost: Option<ModelCost>Pricing information per million tokens.
limit: Option<ModelLimit>Token limits for context and output.
modalities: Option<ModelModalities>Input and output modalities.
capabilities: Option<ModelCapabilities>Capability flags (tool calling, streaming, etc.).
knowledge: Option<String>Knowledge cutoff date (ISO 8601).
Trait Implementations§
Source§impl Clone for ModelDescriptor
impl Clone for ModelDescriptor
Source§fn clone(&self) -> ModelDescriptor
fn clone(&self) -> ModelDescriptor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ModelDescriptor
impl Debug for ModelDescriptor
Source§impl<'de> Deserialize<'de> for ModelDescriptor
impl<'de> Deserialize<'de> for ModelDescriptor
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ModelDescriptor
impl RefUnwindSafe for ModelDescriptor
impl Send for ModelDescriptor
impl Sync for ModelDescriptor
impl Unpin for ModelDescriptor
impl UnsafeUnpin for ModelDescriptor
impl UnwindSafe for ModelDescriptor
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
Mutably borrows from an owned value. Read more