pub struct LearnedCycleStrategy { /* private fields */ }Expand description
Learned autonomous cycle strategy.
Instead of hardcoded cycle ordering, the bicameral system learns which cycle types are most effective and adapts the strategy.
Implementations§
Source§impl LearnedCycleStrategy
impl LearnedCycleStrategy
Sourcepub fn with_strategy(strategy: CycleStrategy) -> Self
pub fn with_strategy(strategy: CycleStrategy) -> Self
Create with a specific strategy.
Sourcepub fn record_cycle(
&mut self,
cycle_type_idx: u8,
proposals: u64,
usefulness: f32,
duration_ms: u64,
)
pub fn record_cycle( &mut self, cycle_type_idx: u8, proposals: u64, usefulness: f32, duration_ms: u64, )
Record a cycle execution.
Sourcepub const fn strategy(&self) -> CycleStrategy
pub const fn strategy(&self) -> CycleStrategy
Get the current strategy.
Sourcepub fn priority_order(&self) -> &[u8] ⓘ
pub fn priority_order(&self) -> &[u8] ⓘ
Get the priority order for cycle execution.
Sourcepub fn cycles_to_run(&self) -> Vec<u8> ⓘ
pub fn cycles_to_run(&self) -> Vec<u8> ⓘ
Get the cycle types to run, in order.
For FixedOrder, returns all types in default order.
For PriorityBased, returns types sorted by effectiveness.
For BestOnly, returns only the top type.
For Adaptive, returns priority order with occasional exploration.
Sourcepub fn effectiveness(&self, cycle_type_idx: u8) -> Option<&CycleEffectiveness>
pub fn effectiveness(&self, cycle_type_idx: u8) -> Option<&CycleEffectiveness>
Get effectiveness data for a cycle type.
Sourcepub fn set_strategy(&mut self, strategy: CycleStrategy)
pub fn set_strategy(&mut self, strategy: CycleStrategy)
Set the strategy manually.
Trait Implementations§
Source§impl Clone for LearnedCycleStrategy
impl Clone for LearnedCycleStrategy
Source§impl Debug for LearnedCycleStrategy
impl Debug for LearnedCycleStrategy
Source§impl Default for LearnedCycleStrategy
impl Default for LearnedCycleStrategy
Source§impl<'de> Deserialize<'de> for LearnedCycleStrategy
impl<'de> Deserialize<'de> for LearnedCycleStrategy
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 LearnedCycleStrategy
impl RefUnwindSafe for LearnedCycleStrategy
impl Send for LearnedCycleStrategy
impl Sync for LearnedCycleStrategy
impl Unpin for LearnedCycleStrategy
impl UnsafeUnpin for LearnedCycleStrategy
impl UnwindSafe for LearnedCycleStrategy
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