pub enum ChatEvent {
Show 20 variants
CanvasOpened(Arc<Canvas>),
CanvasRemembered(Arc<Canvas>),
CanvasClosed(String),
Ready {
session_id: String,
},
History(Vec<TranscriptEntry>),
Entry(TranscriptEntry),
Delta {
kind: EntryKind,
text: String,
},
TurnDone,
AttachmentsAccepted(Vec<u64>),
Error(String),
Failure(Box<TurnFailure>),
SelectedModel {
model: String,
effort: Option<String>,
},
ModelConfirmed {
model: String,
},
SelectedAgent(String),
SelectedMode(ChatMode),
Approval {
request_id: String,
summary: String,
},
Question {
request_id: String,
question: String,
choices: Vec<String>,
},
Usage(Usage),
Mode(bool),
Title(String),
}Expand description
What happened in one open chat.
Variants§
CanvasOpened(Arc<Canvas>)
CanvasRemembered(Arc<Canvas>)
CanvasClosed(String)
Ready
History(Vec<TranscriptEntry>)
Entry(TranscriptEntry)
Delta
TurnDone
AttachmentsAccepted(Vec<u64>)
The SDK accepted these exact draft images for delivery.
Error(String)
A notice for the chat, which ends no turn. A message refused while
the chat runs no turn is followed by ChatEvent::TurnDone.
Failure(Box<TurnFailure>)
A Copilot turn failed, or the runtime stopped or stopped answering.
A ChatEvent::TurnDone follows when a turn was running.
SelectedModel
ModelConfirmed
A model selected by the user and confirmed by the runtime.
SelectedAgent(String)
SelectedMode(ChatMode)
Approval
Question
Usage(Usage)
Mode(bool)
Title(String)
The chat’s display name, from the SDK session name or its summary.
Trait Implementations§
Auto Trait Implementations§
impl Forget for ChatEvent
impl Freeze for ChatEventwhere
*const ArcInner<Canvas> is !null: Freeze,
PhantomData<ArcInner<Canvas>>: Freeze,
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<TranscriptEntry>: Freeze,
PhantomData<u64>: Freeze,
*const TurnFailure is !null: Freeze,
PhantomData<TurnFailure>: Freeze,
PhantomData<String>: Freeze,
impl Move for ChatEvent
impl RefUnwindSafe for ChatEvent
impl Send for ChatEvent
impl Sync for ChatEvent
impl Unpin for ChatEvent
impl UnsafeUnpin for ChatEventwhere
*const ArcInner<Canvas> is !null: UnsafeUnpin,
PhantomData<ArcInner<Canvas>>: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<TranscriptEntry>: UnsafeUnpin,
PhantomData<u64>: UnsafeUnpin,
*const TurnFailure is !null: UnsafeUnpin,
PhantomData<TurnFailure>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
impl UnwindSafe for ChatEvent
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