ppt_add_flowchart
Add an editable flowchart or architecture diagram to a PowerPoint slide from Mermaid code. Converts Mermaid syntax into native PowerPoint shapes and arrows that remain fully editable.
Instructions
Add an editable flowchart or architecture diagram to a PowerPoint slide using Mermaid syntax.
Nodes are rendered as native PowerPoint shapes (Rounded Rectangles, Diamonds for conditions,
Ovals/Stadiums) connected by native connector arrows with arrowheads.
All text, colors, shapes, and layouts remain 100% editable inside PowerPoint.
Supported Mermaid Syntax:
- Direction: 'graph TD' / 'flowchart TD' (Top-Down), 'graph LR' / 'flowchart LR' (Left-Right)
- Box node: `NodeID[Node Label]`
- Rounded node: `NodeID(Node Label)`
- Condition/Decision node: `NodeID{Condition Label}`
- Stadium/Pill node: `NodeID([Label])`
- Line breaks in labels: `<br/>` or `\n`
- Arrows: `A --> B`, `A -->|label| B`, `A --- B`, `A ==> B`, `A -.-> B`
- Chain connections: `A --> B --> C`
Args:
file_path: Path to the PowerPoint file (.pptx).
slide_idx: 0-based index of the slide (auto-creates slide if presentation is empty).
mermaid_code: Mermaid diagram code string.
title: Optional slide title to display at the top.
direction: Layout direction: 'auto' (detect from code), 'TD' (Top-Down), or 'LR' (Left-Right).
left: Left margin offset in inches (default: 0.8).
top: Top margin offset in inches (default: 1.6).
width: Total width allocated for diagram in inches (default: 8.4).
height: Total height allocated for diagram in inches (default: 5.0).
backup: If True, create a backup of the original file before modifying.
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": {
"file_path": "<file_path>",
"slide_idx": "<slide_idx>",
"mermaid_code": "<mermaid_code>"
},
"name": "ppt_add_flowchart"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| top | No | ||
| left | No | ||
| title | No | ||
| width | No | ||
| backup | No | ||
| height | No | ||
| direction | No | auto | |
| file_path | Yes | ||
| slide_idx | Yes | ||
| mermaid_code | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |