Skip to main content

AiExtension

Trait AiExtension 

Source
pub trait AiExtension: Send + Sync {
    // Required methods
    fn name(&self) -> &str;
    fn execute(&self, input: &str) -> Result<String, PluginError>;
}
Expand description

AI 能力扩展点

Required Methods§

Source

fn name(&self) -> &str

扩展名称

Source

fn execute(&self, input: &str) -> Result<String, PluginError>

执行 AI 扩展能力

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§