pub struct RemoteHarness<'runtime> { /* private fields */ }Implementations§
Source§impl<'runtime> RemoteHarness<'runtime>
impl<'runtime> RemoteHarness<'runtime>
pub fn new( provider: Provider, endpoint: &str, key: Option<Secret>, transport: &'runtime dyn RemoteTransport, ) -> Result<Self, HarnessError>
pub fn with_limit(self, maximum: usize) -> Result<Self, HarnessError>
pub async fn chat( &self, input: &HarnessRequest, cancel: &CancellationToken, on_delta: &mut DeltaSink<'_>, ) -> Result<String, HarnessError>
Trait Implementations§
Source§impl ChatHarness for RemoteHarness<'_>
impl ChatHarness for RemoteHarness<'_>
fn name(&self) -> &'static str
fn available<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn chat<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
request: &'life1 HarnessRequest,
cancel: &'life2 CancellationToken,
on_delta: &'life3 mut DeltaSink<'life4>,
) -> Pin<Box<dyn Future<Output = Result<String, HarnessError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Auto Trait Implementations§
impl<'runtime> !RefUnwindSafe for RemoteHarness<'runtime>
impl<'runtime> !UnwindSafe for RemoteHarness<'runtime>
impl<'runtime> Forget for RemoteHarness<'runtime>
impl<'runtime> Freeze for RemoteHarness<'runtime>
impl<'runtime> Send for RemoteHarness<'runtime>
impl<'runtime> Sync for RemoteHarness<'runtime>
impl<'runtime> Unpin for RemoteHarness<'runtime>
impl<'runtime> UnsafeUnpin for RemoteHarness<'runtime>
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