pub struct MemoryContext {
pub short_term: Vec<TieredTurn>,
pub relevant_long_term: Vec<ScoredMemory>,
pub entity_facts: Vec<String>,
pub total_tokens_estimate: usize,
}Expand description
Assembled context passed back to the agent for prompt injection.
Fields§
§short_term: Vec<TieredTurn>Recent turns still in the short-term window.
relevant_long_term: Vec<ScoredMemory>Semantically relevant long-term episodes.
entity_facts: Vec<String>Facts associated with entities detected in the current query.
total_tokens_estimate: usizeRough token estimate (1 token ≈ 4 chars).
Trait Implementations§
Source§impl Clone for MemoryContext
impl Clone for MemoryContext
Source§fn clone(&self) -> MemoryContext
fn clone(&self) -> MemoryContext
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 moreAuto Trait Implementations§
impl Freeze for MemoryContext
impl RefUnwindSafe for MemoryContext
impl Send for MemoryContext
impl Sync for MemoryContext
impl Unpin for MemoryContext
impl UnsafeUnpin for MemoryContext
impl UnwindSafe for MemoryContext
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