Skip to main content

TextModel

Trait TextModel 

Source
pub trait TextModel:
    Send
    + Sync
    + Debug {
    // Required method
    fn complete(
        &self,
        request: TextRequest,
    ) -> BoxFuture<'_, Result<String, TextModelError>>;
}
Expand description

A model that answers one request with text.

Required Methods§

Source

fn complete( &self, request: TextRequest, ) -> BoxFuture<'_, Result<String, TextModelError>>

Answer request.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§