pub struct ScalingReport {
pub samples: Vec<(usize, usize)>,
pub per_item: f64,
pub fixed_overhead: f64,
pub is_constant: bool,
}Expand description
How a program’s output token cost grows with result size — the curve that
matters at agent scale, not a single-size sample. Fit from samples at several
sizes: a marginal per_item cost (slope) and a fixed_overhead (intercept).
Fields§
§samples: Vec<(usize, usize)>The (size, output_tokens) samples measured.
per_item: f64Marginal tokens per additional item (least-squares slope); ~0 means O(1).
fixed_overhead: f64Fixed output overhead independent of size (intercept; header/framing).
is_constant: boolTrue iff output is effectively constant-size (per_item below ~0.5 tok/item).
Trait Implementations§
Source§impl Clone for ScalingReport
impl Clone for ScalingReport
Source§fn clone(&self) -> ScalingReport
fn clone(&self) -> ScalingReport
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 ScalingReport
impl Debug for ScalingReport
Source§impl Display for ScalingReport
impl Display for ScalingReport
Auto Trait Implementations§
impl Freeze for ScalingReport
impl RefUnwindSafe for ScalingReport
impl Send for ScalingReport
impl Sync for ScalingReport
impl Unpin for ScalingReport
impl UnsafeUnpin for ScalingReport
impl UnwindSafe for ScalingReport
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