pub struct FlaresConfig {
pub count: usize,
pub max_concurrent: usize,
pub max_iterations: usize,
pub total_iterations: usize,
pub total_tokens: Option<u64>,
}Expand description
[flares]: what a run costs and how wide it may go (#171).
Every number here is a limit, not a promise: a run is N jobs the lead named, and these are
what stops an N from being expensive. count is only the default for flares run -n — the
model-facing tool never gets a count, it names its jobs.
Fields§
§count: usizeThe default for flares run -n, and the number a local run starts from. An accidental
fan-out on a server that serves one model at a time is ten minutes of serial turns.
max_concurrent: usizeThe most flares one run may have in flight, whatever the routes would allow.
max_iterations: usizePer flare, when the job does not say: the same budget delegate gives a child.
total_iterations: usizeThe run’s own budget. Not count x max_iterations in disguise: this is what stops one
wandering flare before it eats the budget of the three beside it.
total_tokens: Option<u64>Optional spend cap for the whole run, in tokens. Unset: no cap beyond iterations.
Implementations§
Source§impl FlaresConfig
impl FlaresConfig
Sourcepub fn concurrency(&self) -> usize
pub fn concurrency(&self) -> usize
What this config can actually do: max_concurrent, floored by the slots the named routes
bring, and never below one.
Trait Implementations§
Source§impl Clone for FlaresConfig
impl Clone for FlaresConfig
Source§impl Debug for FlaresConfig
impl Debug for FlaresConfig
Source§impl Default for FlaresConfig
impl Default for FlaresConfig
Source§impl<'de> Deserialize<'de> for FlaresConfigwhere
FlaresConfig: Default,
impl<'de> Deserialize<'de> for FlaresConfigwhere
FlaresConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for FlaresConfig
Source§impl PartialEq for FlaresConfig
impl PartialEq for FlaresConfig
Source§impl Serialize for FlaresConfig
impl Serialize for FlaresConfig
impl StructuralPartialEq for FlaresConfig
Auto Trait Implementations§
impl Forget for FlaresConfig
impl Freeze for FlaresConfig
impl Move for FlaresConfig
impl RefUnwindSafe for FlaresConfig
impl Send for FlaresConfig
impl Sync for FlaresConfig
impl Unpin for FlaresConfig
impl UnsafeUnpin for FlaresConfig
impl UnwindSafe for FlaresConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.