pub struct Caps {
pub max_depth: u32,
pub max_children: u32,
pub max_total: u32,
pub tree_token_ceiling: u64,
pub spawn_rate_burst: u32,
pub spawn_rate_per_sec: f64,
}Expand description
Fork-bomb / runaway-recursion caps, enforced at the one spawn chokepoint. Conservative defaults; a spawn exceeding any of these is refused as a tool result, never a crash — the requesting agent gets to adapt, and one greedy branch cannot take the tree down.
Fields§
§max_depth: u32§max_children: u32§max_total: u32§tree_token_ceiling: u64§spawn_rate_burst: u32Spawn-rate token bucket burst.
spawn_rate_per_sec: f64Spawn-rate token bucket refill, tokens per second.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Caps
impl RefUnwindSafe for Caps
impl Send for Caps
impl Sync for Caps
impl Unpin for Caps
impl UnsafeUnpin for Caps
impl UnwindSafe for Caps
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