Structured Output
Structured Output reads free text (an email, a note, a conversation) and, with the help of an AI model, pulls out the information you need organized into fields. You define which fields you want and what type each one is; the component returns records with those fields filled in.
If the text contains several items that match your definition, for example several products in the same order, you get one record per item.
When to use it
- Pull each customer email’s name, order number and reason for contact.
- Turn a free-form incident description into a record with category, priority and responsible team.
- Extract every product and quantity that appears in an order written by hand or over chat.
- Prepare tidy data from texts to save it in a spreadsheet or a CRM.
Configuration
| Field | What it does |
|---|---|
| Model | The AI model that will read the text. Connect a model component here. |
| Input Message (required) | The text you want to pull the information from. |
| Schema Name (required) | A name for what you are extracting, for example Order or Incident. Spaces and symbols become _; if empty, StructuredOutput is used. |
| Output Schema (required) | The fields you want to get. Press Edit Argument Schema and add each field with Add Argument, giving its name, a description and its type. |
Advanced options
| Field | What it does |
|---|---|
| Format Instructions (required) | The instructions the model receives. The default ones ask it to extract every item that matches the fields, leave empty the values it can’t find and remove exact duplicates. You usually don’t need to change them. |
Output
The llm_structured_output output returns one record per item found in the text, with the fields you defined in Output Schema. You can connect it to a Loop, to Parse Data or to a component that stores the data.
Example
A distributor receives orders by email written freely: “I need 20 boxes of water and 5 of orange juice for Friday”. It connects the email text to Input Message, sets Schema Name to OrderLine and defines the fields product (string), quantity (integer) and delivery_date (string) in Output Schema. The component returns two records, one per product, which are added to the orders sheet.
Good practices
- Give each field a clear description of what it should contain. The model uses it to decide what to put there.
- If a detail may not appear in the text, expect that field to arrive empty.