pub struct OpenAiSdk { /* private fields */ }Expand description
ChatCompletion client using your wrapped Request.
Implementations§
Trait Implementations§
Source§impl ModelSDK for OpenAiSdk
impl ModelSDK for OpenAiSdk
Source§fn chat_once<'life0, 'async_trait>(
&'life0 self,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<Self::Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn chat_once<'life0, 'async_trait>(
&'life0 self,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<Self::Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Send a chat request and get full response.
Source§fn chat_stream<'life0, 'async_trait>(
&'life0 self,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<ByteStream>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn chat_stream<'life0, 'async_trait>(
&'life0 self,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<ByteStream>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Send a chat request and get response stream (SSE).
type Input = LlmInput
type Output = LlmOutput
Auto Trait Implementations§
impl Freeze for OpenAiSdk
impl !RefUnwindSafe for OpenAiSdk
impl Send for OpenAiSdk
impl Sync for OpenAiSdk
impl Unpin for OpenAiSdk
impl !UnwindSafe for OpenAiSdk
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