pub struct RuntimeConfig {
pub batch_size: u32,
pub beam_width: u32,
pub isl: u32,
pub osl: u32,
pub prefix: u32,
pub seq_imbalance_correction_scale: f64,
pub gen_seq_imbalance_correction_scale: f64,
}Expand description
Per-call runtime inputs. Field-for-field mirror of the Python
sdk/config.RuntimeConfig.
The imbalance-correction scales thread into the per-op queries exactly
where Python applies them (base_backend.py:331,372): context-attention
ops multiply by seq_imbalance_correction_scale, generation-attention ops
by gen_seq_imbalance_correction_scale. (The FPM telemetry path has no
scale concept and keeps 1.0.)
Fields§
§batch_size: u32§beam_width: u32Beam width. The generation phase queries token-major ops at
x = batch_size * beam_width (Python _run_generation_phase);
attention ops key on the raw decode batch.
isl: u32§osl: u32§prefix: u32Cached tokens already in the KV cache (context phase only).
seq_imbalance_correction_scale: f64Context-attention sequence-imbalance correction (default 1.0).
gen_seq_imbalance_correction_scale: f64Generation-attention sequence-imbalance correction (default 1.0).
Trait Implementations§
Source§impl Clone for RuntimeConfig
impl Clone for RuntimeConfig
Source§fn clone(&self) -> RuntimeConfig
fn clone(&self) -> RuntimeConfig
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 moreimpl Copy for RuntimeConfig
Source§impl Debug for RuntimeConfig
impl Debug for RuntimeConfig
Source§impl Default for RuntimeConfig
impl Default for RuntimeConfig
Source§impl PartialEq for RuntimeConfig
impl PartialEq for RuntimeConfig
impl StructuralPartialEq for RuntimeConfig
Auto Trait Implementations§
impl Freeze for RuntimeConfig
impl RefUnwindSafe for RuntimeConfig
impl Send for RuntimeConfig
impl Sync for RuntimeConfig
impl Unpin for RuntimeConfig
impl UnsafeUnpin for RuntimeConfig
impl UnwindSafe for RuntimeConfig
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