pub struct AlloyClient { /* private fields */ }Expand description
Randomly chooses the first model for every completion — see https://xbow.com/blog/alloy-agents. With fallback enabled, a failed random pick falls through the remaining configured reviewers in declaration order.
Implementations§
Source§impl AlloyClient
impl AlloyClient
pub fn new(slots: Vec<AlloySlot>) -> Result<Self>
pub fn new_with_fallback_routes(slots: Vec<FallbackSlot>) -> Result<Self>
Trait Implementations§
Source§impl LLMClientDyn for AlloyClient
impl LLMClientDyn for AlloyClient
fn completion( &self, completion: Completion, ) -> Pin<Box<dyn Future<Output = Result<CompletionResponse>> + Send + '_>>
Source§fn fork_for_agent(&self) -> Option<Arc<dyn LLMClientDyn>>
fn fork_for_agent(&self) -> Option<Arc<dyn LLMClientDyn>>
Fork mutable routing state for an independently progressing agent while retaining shared
provider clients and run-wide route availability. Stateless clients return
None and may
safely be shared by Arc.Auto Trait Implementations§
impl !RefUnwindSafe for AlloyClient
impl !UnwindSafe for AlloyClient
impl Forget for AlloyClient
impl Freeze for AlloyClient
impl Move for AlloyClient
impl Send for AlloyClient
impl Sync for AlloyClient
impl Unpin for AlloyClient
impl UnsafeUnpin for AlloyClient
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