pub struct InferenceParams {
pub max_tokens: u32,
pub temperature: f32,
pub context_size: u32,
pub n_threads: u32,
}Expand description
Inference parameters for a single generation request.
Fields§
§max_tokens: u32Maximum number of tokens to generate in the response.
temperature: f32Sampling temperature (0.0 = deterministic, higher = more random).
context_size: u32Context window size in tokens to allocate for this request.
n_threads: u32Number of CPU threads to use for inference.
Trait Implementations§
Source§impl Clone for InferenceParams
impl Clone for InferenceParams
Source§fn clone(&self) -> InferenceParams
fn clone(&self) -> InferenceParams
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 InferenceParams
impl Debug for InferenceParams
Auto Trait Implementations§
impl Freeze for InferenceParams
impl RefUnwindSafe for InferenceParams
impl Send for InferenceParams
impl Sync for InferenceParams
impl Unpin for InferenceParams
impl UnsafeUnpin for InferenceParams
impl UnwindSafe for InferenceParams
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