Skip to main content

InjectionScreen

Trait InjectionScreen 

Source
pub trait InjectionScreen: Send + Sync {
    // Required method
    fn screen(&self, text: &str) -> Option<String>;
}
Expand description

Flags suspicious untrusted spans before they reach the model.

Required Methods§

Source

fn screen(&self, text: &str) -> Option<String>

Return a reason string if the span looks like an injection attempt.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§