feat: integrate SimpleCADAPI 2.0.2 CAD workflows

This commit is contained in:
Jerry
2026-08-03 11:17:05 +08:00
parent b5738e9109
commit c3a0f269b7
481 changed files with 110229 additions and 12826 deletions
@@ -0,0 +1,30 @@
# capture_result
## API Definition
```python
def capture_result(*, value: Any) -> Any
```
*Source: graph.py*
## Import Surface
- top-level: `from simplecadapi import capture_result`
## Description
Mark the graph nodes represented by `value` as explicit final outputs of the
active model session. The value is returned unchanged. Explicit capture keeps
intermediate/debug graph leaves out of `ModelResult.model_json`. Captured
geometry/product values are also the inputs to automatic artifact export when
the model decorator receives `export_dir=...`.
```python
@scad.model(graph_id="demo")
def build_demo():
body = scad.make_box_rsolid(width=10.0, height=4.0, depth=2.0)
return scad.capture_result(value=body)
```
Call it inside `@model` or another active `GraphSession`.