Skip to main content

StructuredOutput

Trait StructuredOutput 

Source
pub trait StructuredOutput:
    Serialize
    + DeserializeOwned
    + JsonSchema
    + Clone
    + Send
    + Sync
    + 'static {
    // Provided methods
    fn schema_name() -> Cow<'static, str> { ... }
    fn json_schema() -> Schema { ... }
}

Provided Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<T> StructuredOutput for T
where T: Serialize + DeserializeOwned + JsonSchema + Clone + Send + Sync + 'static,