Skip to main content

ToPrompt

Trait ToPrompt 

Source
pub trait ToPrompt {
    // Required method
    fn to_prompt(self) -> Result<Prompt, FMError>;
}
Expand description

Convert a Rust value into a FoundationModels prompt.

Required Methods§

Source

fn to_prompt(self) -> Result<Prompt, FMError>

Convert the value into a prompt.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl ToPrompt for &str

Source§

impl ToPrompt for String

Implementors§