SOLIDWORKS Geometry Airflow
Use this skill when SOLIDWORKS is already open and the user wants measurements from the live model instead of estimating from a screenshot.
Assume Windows, PowerShell, Python 3, and pywin32 are available. Keep the workflow read-only unless the user explicitly asks to modify the model.
Workflow
- Confirm that
SLDWORKSis running. - Connect to the active SOLIDWORKS application through COM.
- Read the active document and verify it is a part document.
- Run the appropriate bundled script for the requested metric.
- Report the measured values with units and note any assumptions used in airflow calculations.
Bundled Scripts
scripts/solidworks_active_part_metrics.pyRead the active part and output title, body count, face count, volume, and surface area.scripts/solidworks_selected_face_metrics.pyRead the first selected face in the active part and output its area.scripts/solidworks_selected_face_airflow.pyRead the first selected face, apply a supplied air velocity, and output area, volumetric flow, and velocity pressure.
Default Commands
Read active part metrics:
python ".\skills\solidworks-geometry-airflow\scripts\solidworks_active_part_metrics.py"
Read selected face area:
python ".\skills\solidworks-geometry-airflow\scripts\solidworks_selected_face_metrics.py"
Compute airflow from the selected face at 12 m/s:
python ".\skills\solidworks-geometry-airflow\scripts\solidworks_selected_face_airflow.py" --velocity 12
Important Rules
- Treat the model as the source of truth. Prefer live SOLIDWORKS measurements over screenshot estimates.
- Require an already open SOLIDWORKS session. Do not launch SOLIDWORKS unless the user explicitly asks.
- Require an active part document for these scripts. If the active document is an assembly or drawing, report that clearly.
- For face-based calculations, use the first selected face and tell the user if nothing is selected.
- Report airflow in
m^3/s,L/s, andm^3/h. - Report velocity pressure as
0.5 * density * velocity^2. - Do not present velocity pressure as system static pressure. Static pressure cannot be uniquely determined from face area and velocity alone.
Interpretation Rules
BODY_COUNTis the number of visible solid bodies returned byGetBodies2(0, True).FACE_COUNTis the sum ofGetFaceCount()across the returned solid bodies.- Volume comes from the active part mass properties and is reported in both
m^3andmm^3. - Selected face area comes from
IFace2.GetArea()and is reported in bothm^2andmm^2. - Airflow uses
Q = A * v. - Velocity pressure uses air density
1.2 kg/m^3by default unless the user provides another density.
What To Report
Include the requested metrics, units, and any assumptions.
For airflow questions, include:
- selected face area
- velocity used
- volumetric flow in
m^3/s,L/s, andm^3/h - velocity pressure in
Pa - a note that static pressure is not determined from velocity and area alone