render_diagram
Renders the current model as an SVG stock-and-flow diagram, with auto-layout applied by default. Optionally writes the SVG to a specified file.
Instructions
Render the current model as an SVG stock-and-flow diagram. The SVG is returned inline (for clients without file access) and optionally written to a file. Defaults to running auto-layout first so freshly built models render sensibly.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "render_diagram"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filepath | No | Optional output path (.svg); parent directory must exist | |
| model_id | No | Session-scoped model ID. Optional; defaults to the current model for this session. | |
| auto_layout | No | Run auto-layout before rendering (same semantics as save_model) | |
| workspace_id | No | Opaque application workspace handle. Required by MCP 2026-07-28 clients; supported legacy stdio clients may omit it to use the process-local compatibility workspace. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| svg | Yes | ||
| layout | Yes | ||
| filepath | Yes | ||
| model_id | Yes |