pub struct SimpleApi<RT>where
RT: TaskInterface + HttpClientInterface,{ /* private fields */ }
Expand description
Simple API.
Implementations§
Source§impl<RT> SimpleApi<RT>where
RT: TaskInterface + HttpClientInterface,
impl<RT> SimpleApi<RT>where
RT: TaskInterface + HttpClientInterface,
Trait Implementations§
Source§impl<RT> LargeLanguageModel for SimpleApi<RT>where
RT: TaskInterface + HttpClientInterface,
impl<RT> LargeLanguageModel for SimpleApi<RT>where
RT: TaskInterface + HttpClientInterface,
Source§fn chat_stream(
&self,
prompt: ChatPrompt,
) -> Result<impl Future<Output = Result<StringStream>> + Send>
fn chat_stream( &self, prompt: ChatPrompt, ) -> Result<impl Future<Output = Result<StringStream>> + Send>
Chat with a model, returning a stream
Source§fn generate_stream(
&self,
prompt: GenerationPrompt,
) -> Result<impl Future<Output = Result<StringStream>> + Send>
fn generate_stream( &self, prompt: GenerationPrompt, ) -> Result<impl Future<Output = Result<StringStream>> + Send>
Run inference on a model, returning a stream
Auto Trait Implementations§
impl<RT> Freeze for SimpleApi<RT>where
RT: Freeze,
impl<RT> RefUnwindSafe for SimpleApi<RT>where
RT: RefUnwindSafe,
impl<RT> Send for SimpleApi<RT>
impl<RT> Sync for SimpleApi<RT>
impl<RT> Unpin for SimpleApi<RT>where
RT: Unpin,
impl<RT> UnwindSafe for SimpleApi<RT>where
RT: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more