OutputScanner

Trait OutputScanner 

Source
pub trait OutputScanner: Scanner {
    // Required method
    fn scan_output<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        prompt: &'life1 str,
        output: &'life2 str,
        vault: &'life3 Vault,
    ) -> Pin<Box<dyn Future<Output = Result<ScanResult>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait;
}
Expand description

Output scanner specialization

Scans LLM responses/outputs before returning to user

Required Methods§

Source

fn scan_output<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, prompt: &'life1 str, output: &'life2 str, vault: &'life3 Vault, ) -> Pin<Box<dyn Future<Output = Result<ScanResult>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Scan LLM output with context of original prompt

Implementors§