Skip to main content

WatchEvent

Enum WatchEvent 

Source
pub enum WatchEvent {
Show 26 variants RunStart { run_id: String, started_at: i64, lane: String, }, RunEnd { lane: String, run_id: String, status: Ended, error: Option<Failure>, from_tip_id: Option<String>, tip_id: Option<String>, ended_at: i64, }, MessageStart { run_id: Option<String>, lane: String, message: Value, }, MessageUpdate { run_id: Option<String>, lane: String, frame: Value, usage: Value, message: Option<Value>, }, MessageEnd { run_id: Option<String>, lane: String, message: Value, }, ToolStart { run_id: Option<String>, lane: String, tool_call_id: String, tool_name: String, args: Value, }, ToolUpdate { run_id: Option<String>, lane: String, tool_call_id: String, tool_name: String, args: Value, partial_result: Value, }, ToolEnd { run_id: Option<String>, lane: String, tool_call_id: String, tool_name: String, result: Value, is_error: bool, }, QueueUpdate { lane: String, queues: Vec<QueueItem>, }, SessionName { lane: String, name: Option<String>, }, SessionInfoChanged { lane: String, name: Option<String>, }, EntryAdded { lane: String, entry: Value, }, Usage { lane: String, row: Value, totals: Value, }, RetryScheduled { lane: String, run_id: Option<String>, step: String, attempt: u64, max_attempts: u64, delay_ms: u64, not_before: i64, error_message: String, }, RetryStart { lane: String, run_id: Option<String>, step: String, attempt: u64, }, RetryEnd { lane: String, run_id: Option<String>, step: String, attempt: u64, success: bool, final_error: Option<String>, }, BashExecutionUpdate { lane: String, id: Option<String>, delta: String, }, ConfigUpdate { lane: String, property: String, value: Value, }, SummarizationRetryScheduled { lane: String, attempt: u64, max_attempts: u64, delay_ms: u64, error_message: String, }, SummarizationRetryAttemptStart { lane: String, source: String, reason: Option<String>, }, SummarizationRetryFinished { lane: String, }, CompactionStart { lane: String, run_id: Option<String>, reason: String, }, CompactionEnd { lane: String, run_id: Option<String>, reason: String, status: Ended, error: Option<Failure>, }, NavigationStart { lane: String, run_id: String, target_id: Option<String>, started_at: i64, }, NavigationEnd { lane: String, run_id: String, status: Ended, error: Option<Failure>, from_tip_id: Option<String>, tip_id: Option<String>, ended_at: i64, }, Activity { lane: String, active: bool, },
}
Expand description

One lane-watch event.

Variants§

§

RunStart

Fields

§run_id: String
§started_at: i64
§lane: String
§

RunEnd

Fields

§lane: String
§run_id: String
§status: Ended
§error: Option<Failure>

A failed run’s error (code: run_failed).

§from_tip_id: Option<String>
§tip_id: Option<String>
§ended_at: i64
§

MessageStart

A message started: the run’s assistant answer or tool result, or a message outside a run (no runId).

Fields

§run_id: Option<String>
§lane: String
§message: Value
§

MessageUpdate

The streaming assistant message changed: the provider frame and the usage so far, not the message (a watcher folds the frame into the started message). An older worker’s update carries the whole message instead.

Fields

§run_id: Option<String>
§lane: String
§frame: Value
§usage: Value
§message: Option<Value>
§

MessageEnd

Fields

§run_id: Option<String>
§lane: String
§message: Value
§

ToolStart

Fields

§run_id: Option<String>
§lane: String
§tool_call_id: String
§tool_name: String
§args: Value
§

ToolUpdate

Fields

§run_id: Option<String>
§lane: String
§tool_call_id: String
§tool_name: String
§args: Value
§partial_result: Value
§

ToolEnd

Fields

§run_id: Option<String>
§lane: String
§tool_call_id: String
§tool_name: String
§result: Value
§is_error: bool
§

QueueUpdate

The queued items now.

Fields

§lane: String
§queues: Vec<QueueItem>
§

SessionName

The session’s name now (None: cleared); Rust-only, served as ultron.session-ops state.

Fields

§lane: String
§

SessionInfoChanged

AgentSession setSessionName (Pi’s RPC event).

Fields

§lane: String
§

EntryAdded

A journal entry joined the session (a message, a compaction, a branch summary, …).

Fields

§lane: String
§entry: Value
§

Usage

A usage row, with the lane’s totals after it.

Fields

§lane: String
§row: Value
§totals: Value
§

RetryScheduled

A generation’s request failed and is retried after delay_ms.

Fields

§lane: String
§run_id: Option<String>
§step: String
§attempt: u64
§max_attempts: u64
§delay_ms: u64
§not_before: i64
§error_message: String
§

RetryStart

The retry wait ended: the step’s next attempt starts.

Fields

§lane: String
§run_id: Option<String>
§step: String
§attempt: u64
§

RetryEnd

A retried request’s retries ended; final_error when the last attempt failed too.

Fields

§lane: String
§run_id: Option<String>
§step: String
§attempt: u64
§success: bool
§final_error: Option<String>
§

BashExecutionUpdate

A chunk of a user ! command’s output (AgentSession bash_execution_update), under the command’s id.

Fields

§lane: String
§delta: String
§

ConfigUpdate

A lane setting changed (thinkingLevel).

Fields

§lane: String
§property: String
§value: Value
§

SummarizationRetryScheduled

A compaction’s or branch summary’s request failed and is retried (AgentSession onRetryScheduled): the retry’s number, the retries allowed, the delay and the provider’s error.

Fields

§lane: String
§attempt: u64
§max_attempts: u64
§delay_ms: u64
§error_message: String
§

SummarizationRetryAttemptStart

The summary’s retry starts (onRetryAttemptStart): of a branch summary (source: branchSummary), or of a compaction (source: compaction) for reason.

Fields

§lane: String
§source: String
§reason: Option<String>
§

SummarizationRetryFinished

The summary’s retries ended, however they did (onRetryFinished).

Fields

§lane: String
§

CompactionStart

A compaction started: manual, or threshold / overflow for one the session runs on its own in a run.

Fields

§lane: String
§run_id: Option<String>
§reason: String
§

CompactionEnd

Fields

§lane: String
§run_id: Option<String>
§reason: String
§status: Ended
§

NavigationStart

A tree navigation started (target_id: the entry, None: the root).

Fields

§lane: String
§run_id: String
§target_id: Option<String>
§started_at: i64
§

NavigationEnd

Fields

§lane: String
§run_id: String
§status: Ended
§from_tip_id: Option<String>
§tip_id: Option<String>
§ended_at: i64
§

Activity

Whether detached work of the session is active (the worker does not retire while it is).

Fields

§lane: String
§active: bool

Implementations§

Source§

impl WatchEvent

Source

pub fn decode(event: &Value) -> Option<WatchEvent>

The event a lane-watch JSON object is; None for one of a type this build does not know (or a malformed one).

Source

pub fn to_value(&self) -> Value

The event as it goes on the wire.

Trait Implementations§

Source§

impl Clone for WatchEvent

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for WatchEvent

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for WatchEvent

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for WatchEvent

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for WatchEvent

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for WatchEvent

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.