pub trait Summarizer: Send + Sync {
// Required methods
fn name(&self) -> &str;
fn summarize<'life0, 'life1, 'async_trait>(
&'life0 self,
entries: &'life1 [MemoryEntry],
kind: SummaryKind,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Summarization backend for memory compaction.
Implementations call LLM APIs or use deterministic fallbacks.
Required Methods§
Sourcefn summarize<'life0, 'life1, 'async_trait>(
&'life0 self,
entries: &'life1 [MemoryEntry],
kind: SummaryKind,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn summarize<'life0, 'life1, 'async_trait>(
&'life0 self,
entries: &'life1 [MemoryEntry],
kind: SummaryKind,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Summarize a batch of entries into a single summary string.