pub struct MemoryItem {
pub id: MemoryId,
pub agent_id: AgentId,
pub content: String,
pub importance: f32,
pub timestamp: DateTime<Utc>,
pub tags: Vec<String>,
pub recall_count: u64,
}Expand description
A single memory record stored for an agent.
Fields§
§id: MemoryIdUnique identifier for this memory.
agent_id: AgentIdThe agent this memory belongs to.
content: StringTextual content of the memory.
importance: f32Importance score in [0.0, 1.0]. Higher = more important.
timestamp: DateTime<Utc>UTC timestamp when this memory was recorded.
Searchable tags attached to this memory.
recall_count: u64Number of times this memory has been recalled. Updated in-place by recall.
Implementations§
Trait Implementations§
Source§impl Clone for MemoryItem
impl Clone for MemoryItem
Source§fn clone(&self) -> MemoryItem
fn clone(&self) -> MemoryItem
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MemoryItem
impl Debug for MemoryItem
Source§impl<'de> Deserialize<'de> for MemoryItem
impl<'de> Deserialize<'de> for MemoryItem
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 MemoryItem
impl RefUnwindSafe for MemoryItem
impl Send for MemoryItem
impl Sync for MemoryItem
impl Unpin for MemoryItem
impl UnsafeUnpin for MemoryItem
impl UnwindSafe for MemoryItem
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