# 🔀Output Parsers

#### 1)CSV Output Parser

Parse the output of an LLM call as a comma-separated list of values.&#x20;

#### Key Features:

• CSV Formatting: Converts responses into comma-separated values\
• Structured Output: Ensures consistent tabular data format\
• Autofix Option: Automatically fixes minor formatting issues

#### Setup Requirements:

1. Add CSV Output Parser node to the canvas
2. Enable Autofix if required
3. Connect the parser to a chat model output

#### Use Cases:

• Exporting data in CSV format\
• Tabular data generation

<figure><img src="https://1720595571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxWXmt1Z68dgle5JORrEw%2Fuploads%2FtpJpUwm92n9Lhy8ZeOpt%2FScreenshot%202024-07-08%20121840.png?alt=media&#x26;token=3622add7-5943-4300-a5cd-85c120ad1f43" alt=""><figcaption></figcaption></figure>

#### **2)Custom List Output Parser**

Parse the output of an LLM call as a list of values.&#x20;

#### Key Features:

• Custom Formatting: Define list length and separator\
• Flexible Output: Supports different list structures\
• Autofix Option: Handles formatting inconsistencies

#### Setup Requirements:

1. Add Custom List Output Parser node to the canvas
2. Set Length (number of items)
3. Define Separator (example: comma, newline)
4. Enable Autofix if required
5. Connect to model output

#### Use Cases:

• Generating lists from responses\
• Structured text formatting

<figure><img src="https://1720595571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxWXmt1Z68dgle5JORrEw%2Fuploads%2Faque7dIY7SYumyA14stv%2FScreenshot%202024-07-08%20121846.png?alt=media&#x26;token=e69c8158-7764-473f-a694-c317c5653bfb" alt=""><figcaption></figcaption></figure>

#### 3)Structured Output Parser

Parse the output of an LLM call into a given (JSON) structure.

#### Key Features:

• Structured Data: Converts output into defined schema\
• Autofix Support: Fixes minor formatting issues\
• Consistent Responses: Ensures predictable output

#### Setup Requirements:

1. Add Structured Output Parser node to the canvas
2. Enable Autofix if required
3. Connect parser with model output

#### Use Cases:

• Structured response generation\
• API-ready outputs

<figure><img src="https://1720595571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxWXmt1Z68dgle5JORrEw%2Fuploads%2FIjEpHXhWU3ttUtLWighR%2Fimage.png?alt=media&#x26;token=627d2259-f0a2-4363-bd7b-94a11dc7071f" alt=""><figcaption></figcaption></figure>

#### 4)Advanced Structured Output Parser

Parse the output of an LLM call into a given structure by providing a Zod schema.

#### Key Features:

• JSON Schema Support: Uses schema for structured output\
• High Accuracy: Ensures correct format strictly\
• Autofix Option: Handles minor formatting errors

#### Setup Requirements:

1. Add Advanced Structured Output Parser node to the canvas
2. Enable Autofix if required
3. Provide Example JSON schema
4. Connect parser to model output

#### Use Cases:

• JSON-based applications\
• Data validation and structured responses

<figure><img src="https://1720595571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxWXmt1Z68dgle5JORrEw%2Fuploads%2FQXwnHwkbtKav7KAPd50z%2FScreenshot%202024-07-08%20121906.png?alt=media&#x26;token=412d8c5e-17f2-47bc-b015-006abe1fc26a" alt=""><figcaption></figcaption></figure>
