| as_foundry_schema | R Documentation |
as_foundry_schema() is a small validation/conversion helper. It returns raw
JSON Schema lists unchanged, so code can accept either schemas built with
foundryR constructors or hand-written JSON Schema lists. If the ellmer
package is installed, ellmer::type_object() specifications are converted to
the equivalent strict JSON Schema, so ellmer users can pass their existing
type definitions to foundry_extract() and foundry_response().
as_foundry_schema(x)
x |
Object to convert. Either a foundryR/JSON Schema list or an ellmer
|
A JSON Schema represented as an R list.
schema <- foundry_schema(label = schema_string())
as_foundry_schema(schema)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.