Skip to main content

CompletionFeatures

Trait CompletionFeatures 

Source
pub trait CompletionFeatures: Sized {
    // Required methods
    fn completion(
        &self,
        req: CompletionRequest,
        resources: Vec<Resource>,
    ) -> impl Future<Output = Result<AgentOutput, BoxError>> + Send;
    fn model_name(&self) -> String;
}
Expand description

LLM completion capability exposed by an agent context.

Required Methods§

Source

fn completion( &self, req: CompletionRequest, resources: Vec<Resource>, ) -> impl Future<Output = Result<AgentOutput, BoxError>> + Send

Generates a completion for the request and optional resources.

Source

fn model_name(&self) -> String

Returns the name of the model.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§