pub struct PausedExecutionState {
pub original_input: String,
pub system_prompt: Option<String>,
pub history: Vec<Message>,
pub partial_content: String,
pub partial_thinking: Option<String>,
pub completed_tool_calls: Vec<ToolCallRecord>,
pub iteration: u32,
pub source: RequestSource,
pub session_id: Option<String>,
pub workspace_dir: Option<PathBuf>,
pub model_snapshot: Option<SessionLlmInfo>,
pub paused_at: DateTime<Utc>,
}Expand description
Captured execution state when an agent session is paused.
This is saved when the user pauses (cancels) a streaming response and enables the session to be resumed from the same point later. It captures the full conversational context, partial output, and pipeline configuration so the resume path can reconstruct the agent request faithfully.
Fields§
§original_input: StringThe original user input that initiated the paused request.
system_prompt: Option<String>System prompt in effect at pause time.
history: Vec<Message>Conversation history before the paused request (for context reconstruction).
partial_content: StringPartial assistant text accumulated before the pause.
partial_thinking: Option<String>Partial thinking content accumulated before the pause.
completed_tool_calls: Vec<ToolCallRecord>Tool calls that were executed in the paused request before the pause.
iteration: u32Zero-based agentic loop iteration the pipeline was on when paused.
source: RequestSourceSource of the original request.
session_id: Option<String>Session ID associated with this paused state.
workspace_dir: Option<PathBuf>Workspace directory at pause time.
model_snapshot: Option<SessionLlmInfo>Snapshot of the model/provider that was active at pause time.
If the model or provider changes between pause and resume, the UI can warn the user about potential inconsistencies.
paused_at: DateTime<Utc>Timestamp when the execution was paused.
Implementations§
Source§impl PausedExecutionState
impl PausedExecutionState
Sourcepub fn has_content(&self) -> bool
pub fn has_content(&self) -> bool
Returns true if this paused state has any meaningful content to resume.
Trait Implementations§
Source§impl Clone for PausedExecutionState
impl Clone for PausedExecutionState
Source§fn clone(&self) -> PausedExecutionState
fn clone(&self) -> PausedExecutionState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PausedExecutionState
impl Debug for PausedExecutionState
Source§impl<'de> Deserialize<'de> for PausedExecutionState
impl<'de> Deserialize<'de> for PausedExecutionState
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PausedExecutionState, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PausedExecutionState, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Serialize for PausedExecutionState
impl Serialize for PausedExecutionState
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for PausedExecutionState
impl RefUnwindSafe for PausedExecutionState
impl Send for PausedExecutionState
impl Sync for PausedExecutionState
impl Unpin for PausedExecutionState
impl UnwindSafe for PausedExecutionState
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].