pub struct NoopRuntimeHooks;Expand description
A RuntimeHooks that ignores every event — the default when a session
installs no observer.
Trait Implementations§
Source§impl Debug for NoopRuntimeHooks
impl Debug for NoopRuntimeHooks
Source§impl Default for NoopRuntimeHooks
impl Default for NoopRuntimeHooks
Source§impl RuntimeHooks for NoopRuntimeHooks
impl RuntimeHooks for NoopRuntimeHooks
fn env_connected<'life0, 'async_trait>(
&'life0 self,
_event: EnvConnectedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn model_connected<'life0, 'async_trait>(
&'life0 self,
_event: ModelConnectedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn session_started<'life0, 'async_trait>(
&'life0 self,
_event: SessionStartedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn episode_started<'life0, 'async_trait>(
&'life0 self,
_event: EpisodeStartedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn episode_completed<'life0, 'async_trait>(
&'life0 self,
_event: EpisodeCompletedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn episode_completed<'life0, 'async_trait>(
&'life0 self,
_event: EpisodeCompletedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
The last event under its episode id: no observation or step of that
episode follows it. Under
NEXT_STEP autoreset the ended episode is
observed and stepped once more (the autoreset step) before this fires.fn action_received<'life0, 'async_trait>(
&'life0 self,
_event: ActionReceivedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn transform_action<'life0, 'async_trait>(
&'life0 self,
event: ActionReceivedEvent,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Bytes>>, HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn transform_action<'life0, 'async_trait>(
&'life0 self,
event: ActionReceivedEvent,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Bytes>>, HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Fatal hook: a failed transform leaves the next action payload undefined,
so the route fails rather than send something undefined to the env.
fn step_completed<'life0, 'async_trait>(
&'life0 self,
_event: StepCompletedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn observation_emitted<'life0, 'async_trait>(
&'life0 self,
_event: ObservationEmittedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn transform_observation<'life0, 'async_trait>(
&'life0 self,
event: ObservationEmittedEvent,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Bytes>>, HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn transform_observation<'life0, 'async_trait>(
&'life0 self,
event: ObservationEmittedEvent,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Bytes>>, HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Fatal hook; see
Self::transform_action.fn session_ended<'life0, 'async_trait>(
&'life0 self,
_event: SessionEndedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn on_telemetry<'life0, 'async_trait>(
&'life0 self,
_event: TelemetrySnapshotEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_telemetry<'life0, 'async_trait>(
&'life0 self,
_event: TelemetrySnapshotEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Live telemetry push, best-effort. A background ticker streams a
Window
snapshot (the live tier, cleared each RuntimeLimits::telemetry_window)
while the session runs; one final cumulative Session snapshot is
delivered at session end (the durable tier, also returned on
RuntimeReport.telemetry). Branch on event.snapshot.horizon for window
vs session. Dispatched from a separate task, so this may run concurrently
with the other hooks — do not assume serialized delivery.fn session_failed<'life0, 'async_trait>(
&'life0 self,
_event: SessionFailedEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn log<'life0, 'async_trait>(
&'life0 self,
_event: LogEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn relay_advisory<'life0, 'async_trait>(
&'life0 self,
_event: RelayAdvisoryEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn relay_advisory<'life0, 'async_trait>(
&'life0 self,
_event: RelayAdvisoryEvent,
) -> Pin<Box<dyn Future<Output = Result<(), HookError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Best-effort; see
RelayAdvisoryEvent.Auto Trait Implementations§
impl Freeze for NoopRuntimeHooks
impl RefUnwindSafe for NoopRuntimeHooks
impl Send for NoopRuntimeHooks
impl Sync for NoopRuntimeHooks
impl Unpin for NoopRuntimeHooks
impl UnsafeUnpin for NoopRuntimeHooks
impl UnwindSafe for NoopRuntimeHooks
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
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request