diagnose_mesh
Analyze a mesh file for self-intersections, holes, inverted normals, and fragments. Receive a structured defect report with severity and actionable repair steps to avoid print failures.
Instructions
Deep mesh defect analysis — self-intersections, holes, normals, fragments (defect-focused).
Goes deeper than ``analyze_mesh_geometry`` (which focuses on printability
scoring and overhang detection). Use this when you suspect mesh defects
or when ``repair_mesh`` didn't fix the issue.
Analyzes: self-intersections, inverted/inconsistent normals, degenerate
(zero-area) faces, floating fragments, detailed hole reporting (count,
size, location), and polygon count assessment for FDM printing.
Returns a structured report with severity level, defect list, and
actionable fix recommendations (specific MeshLab/Blender steps).
Requires the optional ``trimesh`` package (``pip install trimesh``).
Supports STL, OBJ, PLY, OFF, GLB, and GLTF formats.
Use this BEFORE slicing to catch problems that would cause print
failures or slicer errors. Complements ``validate_generated_mesh``
(basic checks) and ``analyze_printability`` (print-readiness scoring).
Args:
file_path: Path to a mesh file (STL, OBJ, PLY, OFF, GLB, GLTF).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes |