LlmService

Trait LlmService 

Source
pub trait LlmService: Send + Sync {
    // Required method
    fn generate_text<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        prompt: &'life1 str,
        config: &'life2 HydeConfig,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
}
Expand description

Trait for LLM services that can generate hypothetical documents

Required Methods§

Source

fn generate_text<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, prompt: &'life1 str, config: &'life2 HydeConfig, ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Implementors§