pub struct FailingProvider;Trait Implementations§
Source§impl Provider for FailingProvider
impl Provider for FailingProvider
fn complete<'life0, 'life1, 'async_trait>(
&'life0 self,
_prompt: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<ChatResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn complete_with_reasoning<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
prompt: &'life1 str,
_reasoning: &'life2 ReasoningConfig,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Source§fn complete_streaming<'life0, 'life1, 'async_trait>(
&'life0 self,
prompt: &'life1 str,
sender: UnboundedSender<StreamChunk>,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn complete_streaming<'life0, 'life1, 'async_trait>(
&'life0 self,
prompt: &'life1 str,
sender: UnboundedSender<StreamChunk>,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Stream completion tokens through
sender. Default implementation falls
back to complete() and sends a single chunk with the full result.Source§fn complete_with_tools<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
messages: &'life1 [ConversationMessage],
_tools: &'life2 [ToolDefinition],
reasoning: &'life3 ReasoningConfig,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
fn complete_with_tools<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
messages: &'life1 [ConversationMessage],
_tools: &'life2 [ToolDefinition],
reasoning: &'life3 ReasoningConfig,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
Complete with structured tool definitions. The provider sends tool schemas
to the LLM and returns any tool_use requests in
ChatResult::tool_calls.
Default falls back to complete_with_reasoning(), ignoring tools.Source§fn complete_streaming_with_tools<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
messages: &'life1 [ConversationMessage],
tools: &'life2 [ToolDefinition],
reasoning: &'life3 ReasoningConfig,
sender: UnboundedSender<StreamChunk>,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
fn complete_streaming_with_tools<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
messages: &'life1 [ConversationMessage],
tools: &'life2 [ToolDefinition],
reasoning: &'life3 ReasoningConfig,
sender: UnboundedSender<StreamChunk>,
) -> Pin<Box<dyn Future<Output = Result<ChatResult, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
Stream completion with structured tool definitions. Sends incremental
text deltas and tool call deltas through
sender. Default falls back
to non-streaming complete_with_tools().Auto Trait Implementations§
impl Freeze for FailingProvider
impl RefUnwindSafe for FailingProvider
impl Send for FailingProvider
impl Sync for FailingProvider
impl Unpin for FailingProvider
impl UnsafeUnpin for FailingProvider
impl UnwindSafe for FailingProvider
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