pub struct SessionEntry {
pub id: String,
pub parent_id: Option<String>,
pub timestamp: DateTime<Utc>,
pub role: String,
pub content: String,
pub metadata: SessionMetadata,
}Expand description
A single entry in a session branch.
Each entry has a unique ID and an optional parent ID that links it to a previous entry, enabling tree-structured branching conversations.
Fields§
§id: StringUnique identifier for this entry.
parent_id: Option<String>ID of the parent entry. None for root entries (first entry in a branch).
timestamp: DateTime<Utc>When this entry was created.
role: StringThe role of this entry: "user", "assistant", or "system".
content: StringThe content of this entry.
metadata: SessionMetadataOptional metadata about this entry.
Trait Implementations§
Source§impl Clone for SessionEntry
impl Clone for SessionEntry
Source§fn clone(&self) -> SessionEntry
fn clone(&self) -> SessionEntry
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 moreSource§impl Debug for SessionEntry
impl Debug for SessionEntry
Source§impl<'de> Deserialize<'de> for SessionEntry
impl<'de> Deserialize<'de> for SessionEntry
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
Source§impl From<&SessionEntry> for TranscriptEntry
impl From<&SessionEntry> for TranscriptEntry
Source§fn from(entry: &SessionEntry) -> Self
fn from(entry: &SessionEntry) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SessionEntry
impl RefUnwindSafe for SessionEntry
impl Send for SessionEntry
impl Sync for SessionEntry
impl Unpin for SessionEntry
impl UnsafeUnpin for SessionEntry
impl UnwindSafe for SessionEntry
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