AiProvider

Trait AiProvider 

Source
pub trait AiProvider: AiProviderBase + Send {
    // Required method
    fn parse_response<T>(
        &self,
        res: Response,
    ) -> impl Future<Output = Result<T>> + Send
       where Self: Sized,
             T: DeserializeOwned + JsonSchema + Debug;
}
Expand description

A trait that defines the provider-specific logic for the generic AiClient

Required Methods§

Source

fn parse_response<T>( &self, res: Response, ) -> impl Future<Output = Result<T>> + Send
where Self: Sized, T: DeserializeOwned + JsonSchema + Debug,

Parse the provider-specific response

Implementors§