Skip to main content

vtcode_exec_events/
harness_kind.rs

1//! Coarse-kind taxonomy for harness lifecycle events.
2
3use serde::{Deserialize, Serialize};
4
5#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
6#[cfg_attr(feature = "schema-export", derive(schemars::JsonSchema))]
7#[serde(rename_all = "snake_case")]
8pub enum HarnessEventKind {
9    PlanningStarted,
10    PlanningCompleted,
11    ContinuationStarted,
12    ContinuationSkipped,
13    /// A turn was blocked before success could be confirmed. Carries the fuse
14    /// counters so UI layers can render without correlating multiple events.
15    TurnBlocked,
16    /// A bounded tool-free recovery pass was scheduled after blocked calls.
17    BlockedRecoveryStarted,
18    /// A bounded tool-free recovery pass finished.
19    BlockedRecoveryFinished,
20    BlockedHandoffWritten,
21    /// The owning session resolved its archived blocked handoff and removed
22    /// the live recovery pointer.
23    BlockedHandoffResolved,
24    EvaluationStarted,
25    EvaluationPassed,
26    EvaluationFailed,
27    RevisionStarted,
28    EscalationTriggered,
29    EscalationBypassed,
30    VerificationStarted,
31    VerificationPassed,
32    VerificationFailed,
33    /// Agent recovered from a transient error (e.g. after retry succeeded).
34    ErrorRecovered,
35    /// A transient tool failure triggered an automatic retry attempt.
36    ToolRetryAttempted,
37    /// Latency record for a tool execution, emitted on turn completion.
38    ToolLatencyRecorded,
39    /// A checkpoint snapshot was created for the current turn.
40    SnapshotCreated,
41    /// A checkpoint snapshot was restored (rewind operation).
42    SnapshotRestored,
43    /// The user granted additional session tool-call capacity and the
44    /// pending call will be retried in the same turn.
45    ///
46    /// No longer emitted: the per-turn/session tool-call count budget was
47    /// removed. Retained for wire compatibility with older session logs.
48    SessionToolLimitIncreased,
49    /// The user granted additional tool-loop capacity for the current turn.
50    ///
51    /// No longer emitted: the per-turn tool-loop budget was removed.
52    /// Retained for wire compatibility with older session logs.
53    ToolLoopLimitIncreased,
54    /// A background subprocess or exec session reached a terminal state.
55    BackgroundSubprocessCompleted,
56    /// A native delegated agent's public status and ancestry were observed.
57    DelegatedAgentStatus,
58    /// A message was sent to a peer session's mailbox.
59    SessionMessageSent,
60    /// A peer session's message was received from this session's mailbox.
61    SessionMessageReceived,
62    /// A mailbox message expired before delivery.
63    SessionMessageExpired,
64    /// A `/skills use` command finished in the skill side loop, outside any
65    /// turn. `status` is `completed` or `failed`; the item records the skill
66    /// so the run is never missing from the event log.
67    SkillCommandCompleted,
68}