pub struct MemoryGraph { /* private fields */ }Expand description
Memory Graph - manages causal memory for evolution
Implementations§
Source§impl MemoryGraph
impl MemoryGraph
Sourcepub fn with_config(
half_life_days: f32,
ban_threshold: f32,
similarity_threshold: f32,
) -> Self
pub fn with_config( half_life_days: f32, ban_threshold: f32, similarity_threshold: f32, ) -> Self
Create with custom config
Sourcepub fn append(&mut self, event: MemoryGraphEvent)
pub fn append(&mut self, event: MemoryGraphEvent)
Append an event
Sourcepub fn get_advice(&self, signals: &[String]) -> GeneAdvice
pub fn get_advice(&self, signals: &[String]) -> GeneAdvice
Get advice for gene selection
Sourcepub fn is_banned(&self, signal: &str, gene_id: &str) -> bool
pub fn is_banned(&self, signal: &str, gene_id: &str) -> bool
Check if a (signal, gene) pair is banned
Sourcepub fn find_similar(&self, signals: &[String]) -> Vec<(String, f32)>
pub fn find_similar(&self, signals: &[String]) -> Vec<(String, f32)>
Find similar signal patterns using Jaccard similarity
Sourcepub fn get_session_events(&self, session_id: &str) -> Vec<&MemoryGraphEvent>
pub fn get_session_events(&self, session_id: &str) -> Vec<&MemoryGraphEvent>
Get events for a specific session
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MemoryGraph
impl RefUnwindSafe for MemoryGraph
impl Send for MemoryGraph
impl Sync for MemoryGraph
impl Unpin for MemoryGraph
impl UnsafeUnpin for MemoryGraph
impl UnwindSafe for MemoryGraph
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