dfam-check
根据增材制造设计 (DfAM) 规则测量网格文件,并报告每个流程(FDM、SLS、SLA/DLP、金属 PBF、MJF)的适印性结果。当用户询问零件是否可打印,需要对“.stl”、“.obj”、“.ply”或“.3mf”网格进行悬垂/壁厚/支撑分析,需要构建方向建议,或者需要在使用“$gcode”切片或使用“$cad”重新生成几何图形之前获得 DfAM 重新设计指导时使用。
- License 许可
- MIT
- 最近更新
- 2026-09-29
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- dfam-check
- description
- 根据增材制造设计 (DfAM) 规则测量网格文件,并报告每个流程(FDM、SLS、SLA/DLP、金属 PBF、MJF)的适印性结果。当用户询问零件是否可打印,需要对“.stl”、“.obj”、“.ply”或“.3mf”网格进行悬垂/壁厚/支撑分析,需要构建方向建议,或者需要在使用“$gcode”切片或使用“$cad”重新生成几何图形之前获得 DfAM 重新设计指导时使用。
02 资源文件 5
- 参考文档agents/openai.yaml209 B
- 许可证LICENSE1.0 KB
- 参考文档references/process-limits.md3.0 KB
- 参考文档requirements.txt367 B
- 脚本scripts/dfam_tool.py13.8 KB
03 SKILL.md 正文
DfAM Check
Provenance: maintained in earthtojake/text-to-cad. Use the installed local skill files as the runtime source of truth; the repository link is only for provenance and release review.
Use this skill to produce conservative, evidence-backed DfAM reports for mesh files before slicing or printing. It measures geometry facts locally and compares them against per-process design limits; it never slices, uploads, or starts print jobs.
Geometry Inspection
Use scripts/dfam_tool.py in the active project Python environment for all
geometry facts (requires trimesh, numpy, rtree). The tool is fact-only:
it reports measurements and never emits pass/fail or readiness statuses.
Comparisons and verdicts belong to this workflow. Do not estimate wall
thickness, overhang angles, or support volume by eye or from renders when the
tool can measure them.
python scripts/dfam_tool.py measure part.stl --angle-limit 45
python scripts/dfam_tool.py orientations part.stl --angle-limit 45
Set --angle-limit to the target process's self-supporting angle from
references/process-limits.md before measuring, and re-run when the target
process changes: the aggregate support-area facts are binned against it.
STEP/STP input is boundary-representation CAD, not a mesh. When the $cad
skill is installed, export an STL sidecar with it first, then measure the STL
here. Report that remediation instead of attempting raw STEP parsing.
Workflow
- Collect print intent: target process, material, layer height, and any machine or material datasheet the user can provide. If the process is unknown, measure once with the default 45° limit, then present findings per candidate process rather than guessing a single verdict.
- Read
references/process-limits.mdand select the limit column for the target process. A user-provided machine/material datasheet overrides the defaults; cite whichever source is used for every comparison. - Run
measureon the exact upload file. Do not inspect only a generator script, source CAD model, or console summary of the file. - Run
orientationswhen the process requires supports and the measured support area is nonzero. Report any candidate that materially reduces support area, with its build-height tradeoff. - Compare each measured fact to the cited limit and report findings with
restrained status labels:
✅ pass: the measured fact satisfies the cited limit.❌ fail: a measured fact directly violates the cited limit.❓ need more info: missing process context, unmeasured geometry, sampling too sparse to trust, or tool limitations.
- Order findings by severity: watertightness first (blocks slicing for every process), then wall thickness, then overhangs/supports, then orientation and cost signals.
Comparison
Compare only trustworthy pairs of evidence.
- Cite the limit source (process-limits table row, or the user's datasheet field) and the measured fact (JSON field path) for every finding.
- Treat
p05_mmbelow the wall-thickness limit as a violation even whenmin_mmalone could be a sampling outlier; report both values. - On an assembly,
wall_thicknessreportsbody_countand aper_bodybreakdown. Attribute a violation to the body it belongs to; a thin figure pooled across bodies is not a finding against the part as a whole. - Do not apply support-angle findings to powder processes (SLS, MJF); the
relevant powder-process check is trapped-volume powder escape, which this
tool does not yet measure — report that as
❓ need more infowhen enclosed cavities are likely. - Do not silently rescale geometry.
scale.units_suspectis measured from the bounding-box diagonal: when it istrue, the source is probably in meters or inches, every down-facing face reads as resting on the plate, and overhang and support figures of 0.0 mean nothing. Report a unit/scale finding and ask the user to confirm units before comparing anything against a material limit. - Support-volume ratios are coarse upper bounds; report them as cost signals, not hard failures, unless the user has set an explicit budget.
Redesign Handoff
For every ❌ fail, include a concrete, plain-language redesign instruction
with target numbers (for example "thicken the wall at [12.4, 3.0, 8.1] from
0.6 mm to ≥1.2 mm" or "chamfer the overhang at [23.3, 10.0, 52.0] to ≥45°").
When the $cad skill is installed, offer to apply the redesign instructions
with it and re-measure the regenerated geometry here, repeating until no
❌ fail findings remain. When $cad-viewer is installed, hand the measured
file path(s) to it so the user can inspect the findings visually.
04 同仓库更多 Skills
vercel-react-view-transitions
使用 React 的视图转换 API(`<ViewTransition>` 组件、`addTransitionType` 和 CSS 视图转换伪元素)实现流畅、原生感觉的动画的指南。每当用户想要添加页面转换、为路线更改设置动画、创建共享元素动画、为组件的进入/退出设置动画、为列表重新排序设置动画、实现定向(向前/向后)导航动画或在 Next.js 中集成视图转换时,请使用此技能。当用户提及视图转换、startViewTransition、ViewTransition、转换类型或询问有关在 React 中的 UI 状态之间设置动画而无需第三方动画库时也可使用。
vercel-react-native-skills
React Native和Expo构建高性能移动应用程序的最佳实践。在构建React Native组件、优化列表性能、实现动画或使用本机模块时使用。涉及React Native、Expo、移动性能或本机平台API的任务的触发器。
vercel-react-best-practices
Vercel Engineering的React和Next.js性能优化指南。在编写、审查或重构React/Next.js代码时,应使用此技能,以确保最佳性能模式。涉及React组件、Next.js页面、数据获取、捆绑优化或性能改进的任务的触发器。
vercel-composition-patterns
可扩展的React组合模式。在重构具有布尔属性增殖的组件、构建灵活的组件库或设计可重用的API时使用。涉及复合组件、渲染道具、上下文提供者或组件架构的任务的触发器。包括React 19 API变更。
ui-styling
使用 shadcn/ui 组件(基于 Radix UI + Tailwind 构建)、Tailwind CSS 实用优先样式和基于画布的视觉设计创建美观、可访问的用户界面。在构建用户界面、实现设计系统、创建响应式布局、添加可访问组件(对话框、下拉菜单、表单、表格)、自定义主题和颜色、实现深色模式、生成视觉设计和海报或跨应用程序建立一致的样式模式时使用。
design
“综合设计技能:品牌标识、设计标记、UI 样式、徽标生成(55 种样式、Gemini 或 Atlas Cloud AI)、企业形象程序(50 个可交付成果、CIP 模型)、HTML 演示文稿(Chart.js)、横幅设计(22 种样式、社交/广告/网页/打印)、图标设计(15 种样式、SVG、Gemini 3.1 Pro)、社交照片(HTML→屏幕截图、多平台)。操作:设计徽标、创建 CIP、生成模型、构建幻灯片、设计横幅、生成图标、创建社交照片、社交媒体图像、品牌标识、设计系统:Facebook、Twitter、LinkedIn、YouTube、Instagram、Pinterest、TikTok、Threads、Google Ads。”