Skip to main content

SpecReport

Struct SpecReport 

Source
pub struct SpecReport {
Show 20 fields pub tokens: Vec<u32>, pub rounds: usize, pub drafted: u64, pub accepted: u64, pub accept_hist: Vec<u64>, pub draft_ms: f64, pub verify_ms: f64, pub prefill_ms: f64, pub total_ms: f64, pub chain_ms: f64, pub replay_ms: f64, pub draft_prefill_ms: f64, pub cross_ms: f64, pub cross_bytes: u64, pub k_decays: Vec<(usize, usize)>, pub spec_off_at: Option<usize>, pub plain_steps: usize, pub round_wall: Vec<(usize, f64)>, pub zero_draft_rounds: usize, pub guard_stops: usize,
}
Expand description

One spec run’s counters (the accept-length table’s source).

Fields§

§tokens: Vec<u32>§rounds: usize§drafted: u64§accepted: u64§accept_hist: Vec<u64>

hist[a] = rounds that accepted exactly a drafts (a in 0..=k).

§draft_ms: f64§verify_ms: f64§prefill_ms: f64§total_ms: f64§chain_ms: f64

draft_ms split (the round-cost identity table): the K-step chain, the accepted- token catch-up replay, and the one-time draft prefill. draft_ms is their sum.

§replay_ms: f64§draft_prefill_ms: f64§cross_ms: f64

Card-1 crossing cost (mtp10 dev1 placement): wall time and bytes of the P2P wide-row copies (prefill seed + per-round replay seeds). 0 on one card.

§cross_bytes: u64§k_decays: Vec<(usize, usize)>

Dynamic-K admission (mtp10): every decay as (round, new_k). Empty = K never moved.

§spec_off_at: Option<usize>

Token count at which the policy turned spec fully OFF (k reached 0); the rest of the generation ran plain decode steps (counted in plain_steps, not rounds).

§plain_steps: usize§round_wall: Vec<(usize, f64)>

Per-round wall samples: (tokens committed so far, ms since generation start), appended after every round/plain step — lets a caller derive N timing sub-rounds from ONE generation (the x3-rounds protocol where a fresh prefill per timing round is prohibitive, e.g. the 1M ladder).

§zero_draft_rounds: usize

p-min guard accounting: rounds that drafted NOTHING (verify = plain t==1 step) and chain steps cut short (the sub-threshold token discarded uncounted).

§guard_stops: usize

Implementations§

Source§

impl SpecReport

Source

pub fn accept_rate(&self) -> f64

Source

pub fn mean_accept_len(&self) -> f64

Mean committed tokens per round (accepted + bonus).

Trait Implementations§

Source§

impl Clone for SpecReport

Source§

fn clone(&self) -> SpecReport

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for SpecReport

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for SpecReport

Source§

fn default() -> SpecReport

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.