Runtime state helpers for normalized session event emission.
Summary
Functions
Returns runtime metadata for observability and session inspection.
Creates a new runtime state.
Emits the next normalized event and increments the runtime sequence.
Stores a single metadata key on the runtime state.
Replaces the provider session identifier tracked by the runtime.
Types
@type t() :: %CliSubprocessCore.Runtime{ metadata: map(), profile: module(), provider: atom(), provider_session_id: String.t() | nil, sequence: non_neg_integer() }
Functions
Returns runtime metadata for observability and session inspection.
Creates a new runtime state.
@spec next_event( t(), CliSubprocessCore.Event.kind(), CliSubprocessCore.Event.payload(), keyword() ) :: {CliSubprocessCore.Event.t(), t()}
Emits the next normalized event and increments the runtime sequence.
Stores a single metadata key on the runtime state.
Replaces the provider session identifier tracked by the runtime.