pub enum SessionEntry {
User {
meta: SessionEntryMeta,
text: String,
workspace_root: Option<String>,
image_count: Option<u32>,
attachments: Option<Vec<FileAttachment>>,
source: Option<UserEntrySource>,
event_id: Option<String>,
},
Assistant {
meta: SessionEntryMeta,
text: String,
},
Notice {
meta: SessionEntryMeta,
text: String,
detail: Option<String>,
tone: Option<NoticeTone>,
cause: Option<String>,
},
Divider {
meta: SessionEntryMeta,
text: Option<String>,
},
Reasoning {
meta: SessionEntryMeta,
text: String,
duration_ms: Option<i64>,
},
Compaction {
meta: SessionEntryMeta,
status: CompactionStatus,
before_tokens: Option<i64>,
after_tokens: Option<i64>,
duration_ms: Option<i64>,
},
Tool {
meta: SessionEntryMeta,
command: Option<String>,
input: Option<Map<String, Value>>,
result: String,
running: Option<bool>,
preparing: Option<bool>,
tool: Option<String>,
tool_title: Option<String>,
session: Option<String>,
duration_ms: Option<i64>,
outcome: Option<String>,
},
}Expand description
One transcript entry on the wire (TS SessionEntry).
Variants§
User
Owner text (or an inbox message), with optional attachments.
Fields
§
meta: SessionEntryMeta§
attachments: Option<Vec<FileAttachment>>§
source: Option<UserEntrySource>Assistant
The model’s reply.
Notice
A statement from the machinery (durable, survives reconnects when it arrives as a promoted notification).
Divider
Turn separator.
Reasoning
A reasoning block the owner chose to show.
Compaction
Compaction is a visible event: it changes how much context the model can see, and a reader deserves to see when and how far.
Tool
One tool invocation: complete redacted input for the expanded view.
Implementations§
Source§impl SessionEntry
impl SessionEntry
Sourcepub fn meta(&self) -> &SessionEntryMeta
pub fn meta(&self) -> &SessionEntryMeta
Shared metadata of this entry, whatever its body.
Sourcepub fn meta_mut(&mut self) -> &mut SessionEntryMeta
pub fn meta_mut(&mut self) -> &mut SessionEntryMeta
The mutable shared metadata of this entry, whatever its body.
Trait Implementations§
Source§impl Clone for SessionEntry
impl Clone for SessionEntry
Source§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 PartialEq for SessionEntry
impl PartialEq for SessionEntry
Source§impl Serialize for SessionEntry
impl Serialize for SessionEntry
impl StructuralPartialEq for SessionEntry
Auto Trait Implementations§
impl Forget for SessionEntry
impl Freeze for SessionEntrywhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<FileAttachment>: Freeze,
*const LeafNode<String, Value> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, Value)>>: Freeze,
impl Move for SessionEntry
impl RefUnwindSafe for SessionEntry
impl Send for SessionEntry
impl Sync for SessionEntry
impl Unpin for SessionEntry
impl UnsafeUnpin for SessionEntrywhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<FileAttachment>: UnsafeUnpin,
*const LeafNode<String, Value> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, Value)>>: UnsafeUnpin,
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