Trait Chat

Source
pub trait Chat: HasCapability {
    // Provided method
    fn chat<'life0, 'async_trait>(
        &'life0 self,
        messages: Vec<ChatMessage>,
    ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
}

Provided Methods§

Source

fn chat<'life0, 'async_trait>( &'life0 self, messages: Vec<ChatMessage>, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Implementors§

Source§

impl Chat for OpenAI

Source§

impl<P, C> Chat for Model<P, C>
where P: Provider + Chat, C: Chat + ?Sized + Send + Sync,