Trait Event Normalization Ext

View as Markdown

Generated from cargo doc --no-deps -p nemo-relay -p nemo-relay-adaptive -p nemo-relay-pii-redaction -p nemo-relay-ffi -p nemo-relay-types -p nemo-relay-plugin -p nemo-relay-worker-proto -p nemo-relay-worker.

pub trait EventNormalizationExt {
    // Required methods
    fn normalized_llm_request(&self) -> Option<Cow<'_, AnnotatedLlmRequest>>;
    fn normalized_llm_response(&self) -> Option<Cow<'_, AnnotatedLlmResponse>>;
}

Core-only normalized LLM accessors for ATOF events.

These helpers use built-in codec resolution, so they live in the runtime crate rather than the shared DTO crate.

Required Methods

normalized_llm_request

fn normalized_llm_request(&self) -> Option<Cow<'_, AnnotatedLlmRequest>>

Normalized LLM request: the codec annotation when present, otherwise a best-effort decode of the start-event input payload.

The fallback decode requires the start-event input to be the serialized LlmRequest wire shape ({headers, content}) emitted by the managed LLM pipeline; events whose input is a bare payload or a non-LLM shape yield None.

normalized_llm_response

fn normalized_llm_response(&self) -> Option<Cow<'_, AnnotatedLlmResponse>>

Normalized LLM response: the codec annotation when present, otherwise a best-effort decode of the end-event output payload.

Implementors

impl EventNormalizationExt for Event

impl EventNormalizationExt for Event