pub struct ModelSettings {
pub model: String,
pub max_tokens: Option<u32>,
pub temperature: Option<f64>,
pub thinking_budget: Option<u32>,
pub reasoning_effort: Option<String>,
pub max_context_tokens: usize,
}Expand description
Model-specific settings that control LLM behavior.
Fields§
§model: StringModel name / ID.
max_tokens: Option<u32>Maximum output tokens (provider-specific default if None).
temperature: Option<f64>Sampling temperature.
thinking_budget: Option<u32>Anthropic extended thinking budget (tokens).
reasoning_effort: Option<String>OpenAI reasoning effort: “low”, “medium”, or “high”.
max_context_tokens: usizeMaximum context window size in tokens.
Implementations§
Source§impl ModelSettings
impl ModelSettings
Sourcepub fn defaults_for(model: &str, provider: &ProviderType) -> Self
pub fn defaults_for(model: &str, provider: &ProviderType) -> Self
Build settings with provider-appropriate defaults.
Trait Implementations§
Source§impl Clone for ModelSettings
impl Clone for ModelSettings
Source§fn clone(&self) -> ModelSettings
fn clone(&self) -> ModelSettings
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ModelSettings
impl RefUnwindSafe for ModelSettings
impl Send for ModelSettings
impl Sync for ModelSettings
impl Unpin for ModelSettings
impl UnsafeUnpin for ModelSettings
impl UnwindSafe for ModelSettings
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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 more