pub struct SpeculativeGenerationBatchOutput { /* private fields */ }Expand description
Completed speculative requests plus aggregate fair-scheduler telemetry.
Implementations§
Source§impl SpeculativeGenerationBatchOutput
impl SpeculativeGenerationBatchOutput
Sourcepub fn new(
requests: Vec<SpeculativeGenerationOutput>,
scheduler: SpeculativeSchedulerStats,
) -> Self
pub fn new( requests: Vec<SpeculativeGenerationOutput>, scheduler: SpeculativeSchedulerStats, ) -> Self
Creates a completed batch in stable submission order.
Sourcepub fn requests(&self) -> &[SpeculativeGenerationOutput]
pub fn requests(&self) -> &[SpeculativeGenerationOutput]
Per-request results in submission order.
Sourcepub fn into_requests(self) -> Vec<SpeculativeGenerationOutput>
pub fn into_requests(self) -> Vec<SpeculativeGenerationOutput>
Consumes the batch and returns its request results.
Sourcepub const fn scheduler(&self) -> &SpeculativeSchedulerStats
pub const fn scheduler(&self) -> &SpeculativeSchedulerStats
Aggregate scheduler telemetry.
Sourcepub fn push_request(&mut self, request: SpeculativeGenerationOutput)
pub fn push_request(&mut self, request: SpeculativeGenerationOutput)
Appends a result while adapting another backend-neutral execution path.
Sourcepub fn clear_requests(&mut self)
pub fn clear_requests(&mut self)
Clears adapted request results while retaining scheduler telemetry.
Auto Trait Implementations§
impl Freeze for SpeculativeGenerationBatchOutput
impl RefUnwindSafe for SpeculativeGenerationBatchOutput
impl Send for SpeculativeGenerationBatchOutput
impl Sync for SpeculativeGenerationBatchOutput
impl Unpin for SpeculativeGenerationBatchOutput
impl UnsafeUnpin for SpeculativeGenerationBatchOutput
impl UnwindSafe for SpeculativeGenerationBatchOutput
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