Workflow blocks
Classify
Classify content into predefined categories using AI
ai/classify — Classify content into predefined categories using AI.
Where it appears
The Classify block lives in the AI group of the Workflow Builder.
Fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
prompt | text (multi-line, supports references) | Yes | — | Text the model should classify. Include the content to evaluate (e.g. ticket subject, customer message) using <StepName.field> references. |
categories | categories | Yes | — | Define the possible classification outcomes. Each category has an ID used in downstream references and a label shown in the UI. |
defaultCategory | text | No | — | Category ID to select when the model cannot confidently match any defined category. Leave empty to return no category on low-confidence inputs. |
Inputs and outputs
Inputs are the configurable fields above. The block produces these outputs:
Outputs
Reference an output downstream with <Classify.field>.
| Name | Type | Description |
|---|---|---|
success | boolean | Whether classification succeeded |
category | string | Selected category ID |
categoryLabel | string | Selected category label |
reasoning | string | AI reasoning for the selection |
error | string | Error message if failed |
Example
A minimal configuration for this block:
{
"type": "ai/classify",
"config": {
"prompt": "<PreviousStep.field>",
"categories": "..."
}
}Limits and failure modes
- Required fields (
prompt,categories) must be set, or the block fails validation before it runs. - On failure the
erroroutput is populated; downstream blocks that reference other outputs may not receive values.