pub struct SmartMemoryRetriever { /* private fields */ }Expand description
Smart memory retriever with advanced scoring.
Implementations§
Source§impl SmartMemoryRetriever
impl SmartMemoryRetriever
Sourcepub fn with_weights(
focus_weight: f32,
time_decay_weight: f32,
importance_weight: f32,
tfidf_weight: f32,
usage_weight: f32,
) -> Self
pub fn with_weights( focus_weight: f32, time_decay_weight: f32, importance_weight: f32, tfidf_weight: f32, usage_weight: f32, ) -> Self
Create with custom weights.
Sourcepub fn retrieve(
&self,
entries: &[MemoryEntry],
context_keywords: &[String],
active_foci: &[FocusPoint],
max_entries: usize,
) -> Vec<MemoryEntry>
pub fn retrieve( &self, entries: &[MemoryEntry], context_keywords: &[String], active_foci: &[FocusPoint], max_entries: usize, ) -> Vec<MemoryEntry>
Retrieve memories with smart scoring.
Sourcepub fn generate_smart_summary(
&self,
entries: &[MemoryEntry],
context_keywords: &[String],
active_foci: &[FocusPoint],
max_entries: usize,
) -> String
pub fn generate_smart_summary( &self, entries: &[MemoryEntry], context_keywords: &[String], active_foci: &[FocusPoint], max_entries: usize, ) -> String
Generate smart summary with focus awareness.
Sourcepub fn get_retrieval_stats(
&self,
entries: &[MemoryEntry],
context_keywords: &[String],
active_foci: &[FocusPoint],
) -> RetrievalStats
pub fn get_retrieval_stats( &self, entries: &[MemoryEntry], context_keywords: &[String], active_foci: &[FocusPoint], ) -> RetrievalStats
Get retrieval statistics.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SmartMemoryRetriever
impl RefUnwindSafe for SmartMemoryRetriever
impl Send for SmartMemoryRetriever
impl Sync for SmartMemoryRetriever
impl Unpin for SmartMemoryRetriever
impl UnsafeUnpin for SmartMemoryRetriever
impl UnwindSafe for SmartMemoryRetriever
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