feat: harden CAD showcase skill and delivery pipeline
This commit is contained in:
@@ -1,19 +1,28 @@
|
||||
# building_spec.json Schema
|
||||
|
||||
Use `building_spec.json` as the contract between CAD extraction, Blender generation, and the Web showcase.
|
||||
Use `building_spec.json` as the versioned contract between extraction, Blender, trimesh, IFC, and Web delivery. The executable schema is `schemas/building_spec.schema.json`; validate with `python3 scripts/showcase_schema.py spec <file>`.
|
||||
|
||||
## Contents
|
||||
|
||||
1. Top-level contract
|
||||
2. Segment/category/footprint semantics
|
||||
3. Generation config keys
|
||||
4. Object naming and metadata
|
||||
5. Precision labels
|
||||
|
||||
## Top Level
|
||||
|
||||
```json
|
||||
{
|
||||
"schema_version": 1,
|
||||
"project": {
|
||||
"name": "Project name",
|
||||
"description": "Short user-facing description"
|
||||
},
|
||||
"source": {
|
||||
"cad_folder": "work/XREF",
|
||||
"report": "outputs/cad_read_report.json",
|
||||
"dxf_dir": "work/cad_showcase/dxf_sanitized",
|
||||
"config": {
|
||||
"config_version": 1,
|
||||
"generate_footprints": true,
|
||||
"use_footprint_slabs": true,
|
||||
"use_footprint_roofs": true,
|
||||
@@ -66,7 +75,10 @@ Use `building_spec.json` as the contract between CAD extraction, Blender generat
|
||||
"detail_lines": [],
|
||||
"floor_lines": [],
|
||||
"grid": []
|
||||
}
|
||||
},
|
||||
"caps": [
|
||||
{"z": 4.2, "polygons": [[[0, 0], [80, 0], [80, 42], [0, 42]]]}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -134,6 +146,9 @@ Common `source.config` keys used by `derive_showcase_spec.py` and `build_blender
|
||||
- `column_support_distance`: XY tolerance for matching upper structural support.
|
||||
- `column_support_requires_upper_plate`: require an adjacent upper floor/roof footprint before accepting nearby upper structure as support.
|
||||
- `column_support_allow_plate_only`: if true, an upper plate alone is enough support; leave false when broad footprints would keep too many isolated columns.
|
||||
- `cap_groups`: ordered `[pattern, group]` pairs used by derive and both exporters; `floor.caps` is the canonical generated-cap geometry.
|
||||
|
||||
Unknown config keys, duplicate floor keys, missing source files, incomplete `floor_order`, empty floors, and unsupported schema versions are hard validation failures. The exporters consume canonical `floor.caps`; they do not independently choose another floor grouping.
|
||||
|
||||
## Object Naming
|
||||
|
||||
|
||||
Reference in New Issue
Block a user