#[non_exhaustive]pub struct ModelCost {
pub input: String,
pub output: String,
pub cached: String,
pub currency: Option<String>,
}Expand description
Per-1M-token catalog cost, carried verbatim for display and never rounded or re-formatted by the host. Cost arithmetic stays client-local view math.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.input: StringInput cost, a decimal string.
output: StringOutput cost, a decimal string.
cached: StringCached-input cost, a decimal string.
currency: Option<String>Currency; nullable — today’s catalogs are USD.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ModelCost
impl<'de> Deserialize<'de> for ModelCost
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
impl Eq for ModelCost
impl StructuralPartialEq for ModelCost
Auto Trait Implementations§
impl Forget for ModelCost
impl Freeze for ModelCost
impl Move for ModelCost
impl RefUnwindSafe for ModelCost
impl Send for ModelCost
impl Sync for ModelCost
impl Unpin for ModelCost
impl UnsafeUnpin for ModelCost
impl UnwindSafe for ModelCost
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