pub struct FrameMetadata {
pub schema_version: u8,
pub kind: FrameKind,
pub conversation_id: String,
pub chat_role: String,
pub dedup_key: String,
pub scope: Option<String>,
}Expand description
The typed schema written into a backend’s per-entry metadata map for every entry produced by a Rig memory lifecycle hook.
Downstream tools can decode the metadata map into this struct to reason about the origin of the retrieved entry.
Backends construct this envelope directly (struct literal); to keep that
usage ergonomic across crate boundaries the struct is not
#[non_exhaustive]. Any future field addition is therefore a breaking
change and must bump the major version of this crate.
Fields§
§schema_version: u8The schema version of this envelope. Currently 1.
kind: FrameKindWhat kind of memory lifecycle produced this entry.
conversation_id: StringThe conversation ID from the Rig CompactingMemory context.
chat_role: StringThe logical chat role (system, user, assistant).
dedup_key: StringThe deterministic content-hash dedup key.
scope: Option<String>The isolation scope under which this entry was written, if any.
Implementations§
Source§impl FrameMetadata
impl FrameMetadata
Trait Implementations§
Source§impl Clone for FrameMetadata
impl Clone for FrameMetadata
Source§fn clone(&self) -> FrameMetadata
fn clone(&self) -> FrameMetadata
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FrameMetadata
impl Debug for FrameMetadata
Source§impl<'de> Deserialize<'de> for FrameMetadata
impl<'de> Deserialize<'de> for FrameMetadata
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>,
Source§impl PartialEq for FrameMetadata
impl PartialEq for FrameMetadata
Source§fn eq(&self, other: &FrameMetadata) -> bool
fn eq(&self, other: &FrameMetadata) -> bool
self and other values to be equal, and is used by ==.