Parameter configuration
Use these parameter types when defining AI Accelerator model or task parameters in YAML so Magnolia knows how to render the input fields in the UI and how to send user input to the underlying model.
Common properties for every parameter are String name, String description, Boolean required, Boolean hidden, Boolean advanced, and Object defaultValue. Additional properties depend on the parameter type.
advanced defaults to false; when set to true the field moves to the collapsed Advanced section. hidden keeps the field out of the UI entirely (but you can still provide a default value), and required enforces user input before submission.
|
Parameters
| Parameter Type | Description | ||
|---|---|---|---|
|
Basic text parameter type. Supports all common parameters. |
||
|
Specialized string type for AI model prompts.
Usually used to render a |
||
|
Numeric parameter type.
Supports all common parameters plus optional |
||
|
Parameter with predefined options.
Requires an
|
||
|
Special string type for handling URLs or resource links.
Usually used to render a |
||
|
True/false parameter type. Supports all common parameters with boolean values.
|
||
|
Complex parameter type for nested configurations in JSON format.
The JSON schema is defined in the
|
||
|
Special string type for handling image URLs. Can either be a URL or a base64 encoded image. |
||
|
Special string type for handling base64 encoded images. |
||
|
A list of parameters.
Use
|
||
|
Complex parameter type for nested configurations. Supports all common parameters. This is used for complex input parameters without any specific type.
|
||
'switchable' |
Special parameter type for handling switchable parameters. This can be used when a model or task accepts different types of input in the same parameter. Below a more complex example where an image model allows to either use a preset (type
|