pub enum SdkCommand {
prompt {
id: Option<String>,
message: String,
},
continue_ {
id: Option<String>,
message: String,
},
steer {
id: Option<String>,
message: String,
},
follow_up {
id: Option<String>,
message: String,
},
abort {
id: Option<String>,
},
set_model {
id: Option<String>,
model: String,
},
set_thinking_level {
id: Option<String>,
level: String,
},
compact {
id: Option<String>,
},
session_info {
id: Option<String>,
},
quit {
id: Option<String>,
},
}Expand description
An SDK command for controlling the agent programmatically.
This is the canonical command type shared between the RPC runner and the
embedding API. It round-trips through JSON with #[serde(tag = "type")].
Each variant carries an optional id field for request/response
correlation in multiplexed scenarios.
Variants§
prompt
Send a user prompt, streaming agent events.
continue_
Continue conversation with additional text.
steer
Queue a steering message during agent operation.
follow_up
Queue a follow-up message for after agent stops.
abort
Cancel current agent operation.
set_model
Switch provider:model.
set_thinking_level
Set thinking/reasoning level.
compact
Trigger manual compaction.
session_info
Query session metadata.
quit
Shut down the session.
Implementations§
Trait Implementations§
Source§impl Clone for SdkCommand
impl Clone for SdkCommand
Source§fn clone(&self) -> SdkCommand
fn clone(&self) -> SdkCommand
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 SdkCommand
impl Debug for SdkCommand
Source§impl<'de> Deserialize<'de> for SdkCommand
impl<'de> Deserialize<'de> for SdkCommand
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 SdkCommand
impl RefUnwindSafe for SdkCommand
impl Send for SdkCommand
impl Sync for SdkCommand
impl Unpin for SdkCommand
impl UnsafeUnpin for SdkCommand
impl UnwindSafe for SdkCommand
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