optimize_print_orientation
Rotates STL meshes to reduce overhangs and increase bed contact, selecting a candidate orientation and placing the model flat on the build plate for improved printability.
Instructions
Auto-rotate a mesh to minimize overhangs and maximize bed contact.
Tests multiple candidate orientations and picks the one with the
fewest overhangs and the most bed contact. Re-orients the mesh
and places it flat on the build plate (z_min = 0).
``printability_score`` / ``printability_grade`` are the chosen
orientation's score from ``analyze_printability`` itself, judged
for ``material`` and ``printer_id`` — pass the same ones you
gave ``analyze_printability`` and the two numbers match.
:param file_path: Path to the STL file.
:param output_path: Output path. Defaults to overwriting the input.
:param material: Material the score is judged for (default ``"pla"``).
:param printer_id: Optional printer the score is judged for.
:returns: Dict with rotation angles, overhang stats, the
printability score and grade, and new dimensions.INLINE 3D STAGE: on success this tool opens Kiln's interactive 3D stage — an inline viewer panel the user can orbit, zoom, and turn over — in hosts that render MCP Apps panels (Kiln's hosted connection attaches a browser stage link for hosts that don't). Oversized meshes are decimated automatically for the stage; the PNG preview is the floor, not the whole experience.
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>"
},
"name": "optimize_print_orientation"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| material | No | Material the score is judged for (default ``"pla"``). Default: "pla". | |
| file_path | Yes | Path to the STL file. | |
| printer_id | No | Optional printer the score is judged for. Default: "". | |
| output_path | No | Output path. Defaults to overwriting the input. Default: "". |