mirror of
https://github.com/openai/codex.git
synced 2026-05-06 06:12:59 +03:00
feat: add interrupt capabilities to send_input (#9276)
This commit is contained in:
@@ -71,6 +71,12 @@ impl AgentControl {
|
||||
result
|
||||
}
|
||||
|
||||
/// Interrupt the current task for an existing agent thread.
|
||||
pub(crate) async fn interrupt_agent(&self, agent_id: ThreadId) -> CodexResult<String> {
|
||||
let state = self.upgrade()?;
|
||||
state.send_op(agent_id, Op::Interrupt).await
|
||||
}
|
||||
|
||||
/// Submit a shutdown request to an existing agent thread.
|
||||
pub(crate) async fn shutdown_agent(&self, agent_id: ThreadId) -> CodexResult<String> {
|
||||
let state = self.upgrade()?;
|
||||
|
||||
Reference in New Issue
Block a user