pub enum SessionEventKind {
SessionStarted {
channel: String,
peer_id: String,
},
MessageReceived {
content: String,
attachments: Vec<AttachmentMeta>,
},
MessageSent {
content: String,
message_id: String,
},
ToolCalled {
tool_name: String,
params: Value,
},
ToolResult {
tool_name: String,
result: Value,
success: bool,
},
AgentResponse {
content: String,
model: String,
tokens: TokenUsage,
},
SessionEnded {
reason: String,
},
StateChanged {
key: String,
value: Value,
},
}Expand description
Types of session events.
Variants§
SessionStarted
Session started.
MessageReceived
Message received from peer.
MessageSent
Message sent to peer.
ToolCalled
Tool was called.
ToolResult
Tool returned result.
AgentResponse
Agent produced a response.
SessionEnded
Session ended.
StateChanged
Session state changed.
Trait Implementations§
Source§impl Clone for SessionEventKind
impl Clone for SessionEventKind
Source§fn clone(&self) -> SessionEventKind
fn clone(&self) -> SessionEventKind
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 SessionEventKind
impl Debug for SessionEventKind
Source§impl<'de> Deserialize<'de> for SessionEventKind
impl<'de> Deserialize<'de> for SessionEventKind
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 SessionEventKind
impl RefUnwindSafe for SessionEventKind
impl Send for SessionEventKind
impl Sync for SessionEventKind
impl Unpin for SessionEventKind
impl UnwindSafe for SessionEventKind
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