Skip to main content

EventKind

Enum EventKind 

Source
pub enum EventKind {
Show 44 variants WorkflowStarted { workflow_id: String, workflow_version: String, initial_input: Value, }, WorkflowCompleted { final_state: Value, }, WorkflowFailed { error: String, }, WorkflowCancelled { reason: Option<String>, }, NodeScheduled { node_id: NodeId, queue_type: String, }, NodeStarted { node_id: NodeId, worker_id: String, attempt: u32, }, NodeCompleted { node_id: NodeId, output: Value, state_patch: Value, duration_ms: u64, gen_ai_system: Option<String>, gen_ai_model: Option<String>, input_tokens: Option<u64>, output_tokens: Option<u64>, finish_reason: Option<String>, cost_usd: Option<f64>, provenance: Option<Box<ProvenanceMetadata>>, }, NodeFailed { node_id: NodeId, error: String, attempt: u32, retryable: bool, }, NodeSkipped { node_id: NodeId, reason: String, }, NodeCancelled { node_id: NodeId, }, RetryScheduled { node_id: NodeId, attempt: u32, delay_ms: u64, }, InterruptRaised { node_id: NodeId, reason: String, state_for_review: Value, }, ApprovalReceived { node_id: NodeId, user_id: String, decision: ApprovalDecision, comment: Option<String>, state_patch: Option<Value>, }, TimerCreated { node_id: NodeId, fire_at: DateTime<Utc>, correlation_key: Option<String>, }, TimerFired { node_id: NodeId, correlation_key: Option<String>, }, ExternalEventReceived { correlation_key: String, payload: Value, }, ChildWorkflowStarted { node_id: NodeId, child_execution_id: String, child_workflow_id: String, }, ChildWorkflowCompleted { node_id: NodeId, child_execution_id: String, result: Value, }, ChildWorkflowFailed { node_id: NodeId, child_execution_id: String, error: String, }, BudgetExceeded { node_id: NodeId, kind: String, limit: u64, current: u64, }, TokenBudgetExceeded { node_id: NodeId, kind: String, limit: u64, current: u64, }, CostBudgetExceeded { node_id: NodeId, limit_usd: f64, current_usd: f64, }, AutonomyLimitReached { node_id: NodeId, agent_ref: String, limit_type: String, limit_value: Value, actual_value: Value, }, CircuitBreakerTripped { node_id: NodeId, agent_ref: String, consecutive_errors: u32, threshold: u32, }, EscalationRequired { node_id: NodeId, agent_ref: String, reason: String, escalation_target: String, }, PolicyViolation { node_id: NodeId, rule: String, decision: String, policy_scope: String, }, ToolApprovalRequired { node_id: NodeId, tool_name: String, approver: String, context: Value, }, StrategyStarted { strategy: String, config: Value, }, PlanGenerated { steps: Vec<String>, }, IterationStarted { iteration: u32, }, ToolCalled { node_id: NodeId, tool: String, }, CriticVerdict { node_id: NodeId, score: f64, passed: bool, feedback: Option<String>, }, IterationCompleted { iteration: u32, cost_delta_usd: Option<f64>, input_tokens: u64, output_tokens: u64, }, StrategyLimitHit { limit_type: String, limit_value: Value, actual_value: Value, }, StrategyCompleted { iterations: u32, total_cost_usd: Option<f64>, }, CoordinatorDiscovery { node_id: NodeId, query_skills: Vec<String>, query_trust_domain: Option<String>, candidates: Vec<Value>, filtered_out: Vec<Value>, }, CoordinatorScoring { node_id: NodeId, rankings: Vec<Value>, spread: f64, weights: Value, }, CoordinatorDecision { node_id: NodeId, selected: Option<String>, method: String, reasoning: Option<String>, confidence: f64, rejected: Vec<Value>, tiebreaker_tokens: Option<Value>, tiebreaker_cost: Option<f64>, }, AgentToolInvoked { node_id: NodeId, agent_uri: String, mode: String, protocol: String, input_hash: String, }, AgentToolProgress { node_id: NodeId, chunk_index: u32, partial_output_summary: String, }, AgentToolTurn { node_id: NodeId, turn_number: u32, direction: String, content_summary: String, tokens: u32, cost: f64, }, AgentToolCompleted { node_id: NodeId, output: Value, provenance: Option<Value>, total_cost: f64, latency_ms: u64, total_turns: Option<u32>, }, AgentToolTerminated { node_id: NodeId, reason: String, chunks_received: u32, partial_output: Option<Value>, cost: f64, }, AgentToolFailed { node_id: NodeId, failure_type: String, message: String, retryable: bool, },
}
Expand description

All possible event kinds in the JamJet event log.

Variants§

§

WorkflowStarted

Fields

§workflow_id: String
§workflow_version: String
§initial_input: Value
§

WorkflowCompleted

Fields

§final_state: Value
§

WorkflowFailed

Fields

§error: String
§

WorkflowCancelled

Fields

§reason: Option<String>
§

NodeScheduled

Fields

§node_id: NodeId
§queue_type: String
§

NodeStarted

Fields

§node_id: NodeId
§worker_id: String
§attempt: u32
§

NodeCompleted

Fields

§node_id: NodeId
§output: Value
§state_patch: Value

JSON merge patch to apply to workflow state.

§duration_ms: u64
§gen_ai_system: Option<String>

AI provider system (e.g. “anthropic”, “openai”). None for non-model nodes.

§gen_ai_model: Option<String>

Model name used.

§input_tokens: Option<u64>

Input tokens consumed.

§output_tokens: Option<u64>

Output tokens generated.

§finish_reason: Option<String>

Finish reason (e.g. “stop”, “length”, “tool_calls”).

§cost_usd: Option<f64>

Estimated USD cost for this node.

§provenance: Option<Box<ProvenanceMetadata>>

Provenance metadata for research traceability.

§

NodeFailed

Fields

§node_id: NodeId
§error: String
§attempt: u32
§retryable: bool
§

NodeSkipped

Fields

§node_id: NodeId
§reason: String
§

NodeCancelled

Fields

§node_id: NodeId
§

RetryScheduled

Fields

§node_id: NodeId
§attempt: u32
§delay_ms: u64
§

InterruptRaised

Fields

§node_id: NodeId
§reason: String
§state_for_review: Value
§

ApprovalReceived

Fields

§node_id: NodeId
§user_id: String
§comment: Option<String>
§state_patch: Option<Value>
§

TimerCreated

Fields

§node_id: NodeId
§fire_at: DateTime<Utc>
§correlation_key: Option<String>
§

TimerFired

Fields

§node_id: NodeId
§correlation_key: Option<String>
§

ExternalEventReceived

Fields

§correlation_key: String
§payload: Value
§

ChildWorkflowStarted

Fields

§node_id: NodeId
§child_execution_id: String
§child_workflow_id: String
§

ChildWorkflowCompleted

Fields

§node_id: NodeId
§child_execution_id: String
§result: Value
§

ChildWorkflowFailed

Fields

§node_id: NodeId
§child_execution_id: String
§error: String
§

BudgetExceeded

Fields

§node_id: NodeId
§kind: String
§limit: u64
§current: u64
§

TokenBudgetExceeded

Fields

§node_id: NodeId
§kind: String

“input_tokens” | “output_tokens” | “total_tokens”

§limit: u64
§current: u64
§

CostBudgetExceeded

Fields

§node_id: NodeId
§limit_usd: f64
§current_usd: f64
§

AutonomyLimitReached

Fields

§node_id: NodeId
§agent_ref: String
§limit_type: String

“max_iterations” | “cost_budget” | “token_budget” | “max_tool_calls”

§limit_value: Value
§actual_value: Value
§

CircuitBreakerTripped

Fields

§node_id: NodeId
§agent_ref: String
§consecutive_errors: u32
§threshold: u32
§

EscalationRequired

Fields

§node_id: NodeId
§agent_ref: String
§reason: String

“circuit_breaker” | “autonomy_limit” | “budget_exceeded”

§escalation_target: String

“supervisor_agent:” | “human_approval”

§

PolicyViolation

Fields

§node_id: NodeId
§rule: String

Which rule triggered (e.g. “block_tool:payments.*”)

§decision: String

“blocked” | “require_approval”

§policy_scope: String

“global” | “tenant” | “workflow” | “node”

§

ToolApprovalRequired

Fields

§node_id: NodeId
§tool_name: String
§approver: String
§context: Value
§

StrategyStarted

Emitted when a reasoning strategy begins execution.

Fields

§strategy: String
§config: Value
§

PlanGenerated

Emitted by plan-and-execute when the plan is generated.

Fields

§steps: Vec<String>
§

IterationStarted

Emitted at the start of each reasoning loop iteration.

Fields

§iteration: u32
§

ToolCalled

Emitted each time a tool is invoked within a strategy loop.

Fields

§node_id: NodeId
§tool: String
§

CriticVerdict

Emitted by critic/verifier nodes with a quality score.

Fields

§node_id: NodeId
§score: f64
§passed: bool
§feedback: Option<String>
§

IterationCompleted

Emitted at the end of each iteration with cost/token delta.

Fields

§iteration: u32
§cost_delta_usd: Option<f64>
§input_tokens: u64
§output_tokens: u64
§

StrategyLimitHit

Emitted when a strategy limit (max_iterations, max_cost_usd, timeout) is hit. Workflow transitions to LimitExceeded after this event.

Fields

§limit_type: String
§limit_value: Value
§actual_value: Value
§

StrategyCompleted

Emitted when strategy execution completes successfully.

Fields

§iterations: u32
§total_cost_usd: Option<f64>
§

CoordinatorDiscovery

Fields

§node_id: NodeId
§query_skills: Vec<String>
§query_trust_domain: Option<String>
§candidates: Vec<Value>
§filtered_out: Vec<Value>
§

CoordinatorScoring

Fields

§node_id: NodeId
§rankings: Vec<Value>
§spread: f64
§weights: Value
§

CoordinatorDecision

Fields

§node_id: NodeId
§selected: Option<String>
§method: String
§reasoning: Option<String>
§confidence: f64
§rejected: Vec<Value>
§tiebreaker_tokens: Option<Value>
§tiebreaker_cost: Option<f64>
§

AgentToolInvoked

Fields

§node_id: NodeId
§agent_uri: String
§mode: String
§protocol: String
§input_hash: String
§

AgentToolProgress

Fields

§node_id: NodeId
§chunk_index: u32
§partial_output_summary: String
§

AgentToolTurn

Fields

§node_id: NodeId
§turn_number: u32
§direction: String
§content_summary: String
§tokens: u32
§cost: f64
§

AgentToolCompleted

Fields

§node_id: NodeId
§output: Value
§provenance: Option<Value>
§total_cost: f64
§latency_ms: u64
§total_turns: Option<u32>
§

AgentToolTerminated

Fields

§node_id: NodeId
§reason: String
§chunks_received: u32
§partial_output: Option<Value>
§cost: f64
§

AgentToolFailed

Fields

§node_id: NodeId
§failure_type: String
§message: String
§retryable: bool

Implementations§

Source§

impl EventKind

Source

pub fn node_id(&self) -> Option<&str>

Returns the node_id associated with this event, if any.

Trait Implementations§

Source§

impl Clone for EventKind

Source§

fn clone(&self) -> EventKind

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 EventKind

Source§

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

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

impl<'de> Deserialize<'de> for EventKind

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 Serialize for EventKind

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

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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

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> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more