Templates / Generate dynamic JSON output formats for AI agents with Mistral

Generate dynamic JSON output formats for AI agents with Mistral

Needs changes

by Hybroht ✓ · 2,250 views · created 2025-07-10 · Engineering, Multimodal AI

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 19 nodes and runs manually, when you click “Execute workflow”. Along the way it connects Mistral Cloud Chat Model and Advanced Output Parser (community).

How it runs

Trigger: Manually, when you click “Execute workflow”.

  1. Prepare Input (Edit Fields (Set)): sets 5 fields: input, correction_required, last_json_format_attempt…
  2. Guarantee Input (Edit Fields (Set)): sets 4 fields: input, correction_required, last_json_format_attempt…
  3. If: checks a condition and branches into true / false
  4. Round Limit Reached (Stop and Error): stops the run with an error
  5. Loop Until it Works (Loop Over Items (Split in Batches)): loops over the items in batches
  6. JSON Generator (AI Agent): runs an AI agent, with model: Mistral Cloud Chat Model; output parser: JSON Output Parser
  7. JSON Validator (AI Agent): runs an AI agent, with model: Mistral Cloud Chat Model; output parser: JSON Output Parser
  8. If: checks a condition and branches into true / false
  9. JSON Reviewer (AI Agent): runs an AI agent, with model: Mistral Cloud Chat Model; output parser: Advanced JSON Output Parser
  10. Update Input (Edit Fields (Set)): sets 4 fields: input, correction_required, last_json_format_attempt…

…plus 2 more steps. See the full node list below.

Services it uses

Mistral Cloud Chat ModelAdvanced Output Parser (community)

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • AI Agent v1 (old agent modes) in JSON Generator (v1.6), JSON Validator (v1.6), JSON Reviewer (v1.6): replace with Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.

Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).

Removed in 3.0Replace with
AI Agent v1 (old agent modes)
JSON Generator (v1.6), JSON Validator (v1.6), JSON Reviewer (v1.6)
Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.

Nodes used (10)

From the author

This workflow contains community nodes that are only compatible with the self-hosted version of n8n. JSON Architect - Dynamically Generate JSON Output Formats for Any AI Agent Overview Version: 1.0 The JSON Architect Workflow is designed to instruct AI agents…

Excerpt from Hybroht's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.