Struct LlmSanitize Response Context
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.
Per-call codec context for LLM response sanitize guardrails.
The context distinguishes no codec, Relay built-ins, runtime-registered codecs, and active codecs with no stable identity.
Implementations
impl LlmSanitizeResponseContext
impl LlmSanitizeResponseContext
with_identity
pub fn with_identity(codec: LlmCodecIdentity) -> Self
Construct a context that carries only a codec identity.
Identity-only contexts do not carry a codec handle, so Self::resolve_codec returns None even when the identity describes an active codec.
for_response_codec
pub fn for_response_codec(codec: Option<Arc<dyn LlmResponseCodec>>) -> Self
Construct response-sanitizer context from the active response codec.
codec
pub fn codec(&self) -> &LlmCodecIdentity
Return the identity of the codec active for this payload direction.
resolve_codec
pub fn resolve_codec(&self) -> Option<Arc<dyn LlmResponseCodec>>
Resolve the active response codec.
Returns None for contexts constructed with Self::with_identity.
Trait Implementations
impl Clone for LlmSanitizeResponseContext
impl Clone for LlmSanitizeResponseContext
clone
fn clone(&self) -> LlmSanitizeResponseContext
clone_from
fn clone_from(&mut self, source: &Self)
impl Debug for LlmSanitizeResponseContext
impl Debug for LlmSanitizeResponseContext
fmt
fn fmt(&self, formatter: &mut Formatter<'_>) -> Result
impl Default for LlmSanitizeResponseContext
impl Default for LlmSanitizeResponseContext
default
fn default() -> LlmSanitizeResponseContext