mermaid_to_workflow
Convert a Mermaid flowchart diagram into an executable ComfyUI workflow JSON. Parses nodes, connections with data type labels, and widget values using ComfyUI's object_info schemas.
Instructions
Convert a Mermaid flowchart diagram back into a ComfyUI workflow JSON. Parses node definitions, connections (with data type labels), and widget values from the mermaid syntax. Resolves node types and wires connections using ComfyUI's /object_info schemas. Fills missing inputs with defaults. Returns a valid, executable ComfyUI API workflow.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"mermaid": "<mermaid>"
},
"name": "mermaid_to_workflow"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mermaid | Yes | Mermaid flowchart text (with or without ```mermaid code fence). Nodes should use ComfyUI class_type names as labels. Connections should be labeled with data types (e.g., -->|MODEL|). |