pub struct PredictorConfig {
pub lr: f64,
pub l2: f64,
}Expand description
Per-query gate-pass predictor configuration (ADR 0008 Phase 2). The model is an online
logistic regression (firstpass_core::predictor::PassPredictor) trained from the trace
store. Its prediction is recorded on the receipt in shadow — it does not change routing
in this phase; whether it is good enough to act on is decided offline (firstpass predictor-eval).
Fields§
§lr: f64SGD learning rate, in (0, 1]. Validated by Config::parse.
l2: f64L2 shrinkage on the weights (bias excluded), >= 0. Validated by Config::parse.
Trait Implementations§
Source§impl Clone for PredictorConfig
impl Clone for PredictorConfig
Source§fn clone(&self) -> PredictorConfig
fn clone(&self) -> PredictorConfig
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 moreimpl Copy for PredictorConfig
Source§impl Debug for PredictorConfig
impl Debug for PredictorConfig
Source§impl<'de> Deserialize<'de> for PredictorConfig
impl<'de> Deserialize<'de> for PredictorConfig
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for PredictorConfig
impl RefUnwindSafe for PredictorConfig
impl Send for PredictorConfig
impl Sync for PredictorConfig
impl Unpin for PredictorConfig
impl UnsafeUnpin for PredictorConfig
impl UnwindSafe for PredictorConfig
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