catia_describe_model
Reverse-engineers the active CATIA document to generate a spec and replay script for parts or assemblies, capturing geometry, constraints, and parameters without modification.
Instructions
Reverse-engineer the ACTIVE document without modifying it. CATPart: bodies, features in tree order, sketches with exact geometry (mm, sketch axes) and constraints, parameters, plane frames, volume, bounding box, inertia, plus the source of a replayable PartScript that rebuilds the part in a NEW document. A feature the reader does not understand is listed under 'opaque' (name, type, what is known, why) and the spec says replay.complete=false: nothing is guessed. CATProduct: components, poses, constraints and statuses. Limits: sketch constraints are described, not replayed; patterns, shell, draft, thickness and surfaces are opaque; edges are reproduced by a point on them. Units mm and degrees. Set output_dir to write _spec.json and _replay.py.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| measure | No | Measure volume, box and inertia (the exact bounding box costs ~0.25 s per face; parts above 400 faces skip it). | |
| validate | No | Dry-run the generated script against the tool schemas. | |
| output_dir | No | Folder to write the spec JSON and the replay script into (created if needed). | |
| replay_name | No | Part name of the replay (default '<part>_Replay'). | |
| include_spec | No | Return the full spec in the answer (false = summary only, useful for big models; the file is written either way). | |
| include_script | No | Return the script source in the answer (it is written to output_dir either way). |