{ "archgen": { "version": "0.1.0", "description": "ArchGen Schema — 建筑几何与核心实体", "tags": { "scale": { "building": "建筑尺度", "community": "社区/街区尺度", "urban": "城市尺度" }, "simulation": { "energy": "能耗模拟", "daylight": "采光分析", "solar": "日照分析", "thermal_comfort": "热舒适分析", "carbon": "碳排放核算", "wind": "风环境模拟", "general": "通用(不特定于某种模拟)" } } }, "types": { "Point3d": { "description": "三维点坐标", "fields": { "x": { "type": "number", "default": 0 }, "y": { "type": "number", "default": 0 }, "z": { "type": "number", "default": 0 } } }, "Polyline3d": { "description": "三维多段线(点列表)", "fields": { "points": { "type": "Point3d[]", "default": [] } } }, "Vector3d": { "description": "三维向量", "fields": { "x": { "type": "number", "default": 0 }, "y": { "type": "number", "default": 0 }, "z": { "type": "number", "default": 0 } } }, "Line3d": { "description": "直线(起点+终点)", "fields": { "from": { "type": "Point3d" }, "to": { "type": "Point3d" } } }, "TimePoint": { "description": "时刻点 [时, 分]", "fields": { "hour": { "type": "integer", "default": 0 }, "minute": { "type": "integer", "default": 0 } } }, "DatePoint": { "description": "日期点 [月, 日]", "fields": { "month": { "type": "integer", "default": 1 }, "day": { "type": "integer", "default": 1 } } }, "Period": { "description": "时间范围", "fields": { "start": { "type": "DatePoint" }, "end": { "type": "DatePoint" } } }, "UVRect": { "description": "UV 矩形坐标 [u, v, 宽比, 高比]", "fields": { "u": { "type": "number" }, "v": { "type": "number" }, "widthRatio": { "type": "number" }, "heightRatio": { "type": "number" } } } }, "enums": { "Direction": { "description": "朝向", "values": ["N", "NE", "E", "SE", "S", "SW", "W", "NW"] }, "BoundaryType": { "description": "边界类型", "values": [ "exterior_wall", "interior_wall", "curtain_wall", "roof", "floor", "slab", "foundation" ] }, "ElementType": { "description": "结构构件类型", "values": [ "column", "beam", "slab", "wall", "foundation", "stair", "ramp" ] }, "ApertureGeometryType": { "description": "洞口几何类型", "values": ["window", "door", "curtain_wall", "generic"] }, "ApertureContextType": { "description": "洞口内外上下文", "values": ["EXTERIOR", "INTERIOR"] }, "RoomCreationMethod": { "description": "房间创建方式", "values": ["planar_extrude", "mass_slice", "manual"] }, "RelationType": { "description": "拓扑关系类型", "values": ["adjacent", "contains", "crosses", "flows", "touches", "sight"] } }, "entities": { "Building": { "description": "建筑顶级实体", "tags": { "scale": ["building", "community", "urban"] }, "attributes": { "identifier": { "type": "string", "required": true, "description": "唯一标识符", "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "description": "显示名称", "tags": { "simulation": ["general"] } }, "schemaVersion": { "type": "string", "required": true, "description": "archgen-schema 版本", "tags": { "simulation": ["general"] } }, "siteBasePoint": { "type": "Point3d", "required": true, "description": "建筑基准点", "tags": { "simulation": ["general"] } }, "northAngle": { "type": "number", "required": true, "default": 0, "description": "建筑正北角度", "tags": { "simulation": ["energy", "daylight", "solar", "thermal_comfort", "wind"] } }, "globalSettings": { "type": "object", "description": "全局设置", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "description": "自定义元数据", "tags": { "simulation": ["general"] } } }, "children": { "floors": { "type": "Floor", "multiple": true, "description": "楼层列表", "tags": { "scale": ["building", "community"], "simulation": ["general"] } }, "masses": { "type": "MassEntity", "multiple": true, "description": "参数化体量", "tags": { "scale": ["building"], "simulation": ["general"] } }, "shafts": { "type": "Shaft", "multiple": true, "description": "竖井", "tags": { "scale": ["building"], "simulation": ["general"] } }, "shades": { "type": "Shade", "multiple": true, "description": "遮阳", "tags": { "scale": ["building", "community"], "simulation": ["energy", "daylight", "solar", "thermal_comfort"] } }, "siteShades": { "type": "Shade", "multiple": true, "description": "外部遮阳(树木、邻楼)", "tags": { "scale": ["building", "community", "urban"], "simulation": ["energy", "daylight", "solar", "wind"] } }, "gridSystem": { "type": "GridSystem", "description": "轴网系统", "tags": { "scale": ["building"], "simulation": ["general"] } }, "relations": { "type": "Relation", "multiple": true, "description": "拓扑关系", "tags": { "scale": ["building", "community", "urban"], "simulation": ["general"] } } } }, "Floor": { "description": "楼层", "tags": { "scale": ["building", "community"] }, "attributes": { "identifier": { "type": "string", "required": true, "description": "唯一标识符", "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "description": "显示名称", "tags": { "simulation": ["general"] } }, "elevation": { "type": "number", "required": true, "description": "楼层标高 Z", "tags": { "simulation": ["general"] } }, "height": { "type": "number", "required": true, "description": "层高", "unit": "m", "tags": { "simulation": ["energy", "daylight", "thermal_comfort", "carbon"] } }, "story": { "type": "integer", "required": true, "description": "楼层序号", "tags": { "simulation": ["general"] } }, "outline": { "type": "Polyline3d", "description": "楼板轮廓", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } }, "children": { "rooms": { "type": "Room", "multiple": true, "description": "房间" }, "apertures": { "type": "Aperture", "multiple": true, "description": "楼层级洞口", "tags": { "scale": ["building"], "simulation": ["energy", "daylight", "wind"] } }, "elements": { "type": "Element", "multiple": true, "description": "结构构件", "tags": { "scale": ["building"], "simulation": ["general"] } } } }, "Room": { "description": "房间", "tags": { "scale": ["building", "community"] }, "discriminator": "creationMethod", "variants": { "planar_extrude": { "description": "平面轮廓拉伸创建", "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "creationMethod": { "type": "RoomCreationMethod", "required": true, "default": "planar_extrude", "tags": { "simulation": ["general"] } }, "programType": { "type": "string", "description": "房间功能类型", "tags": { "scale": ["building"], "simulation": ["energy", "thermal_comfort", "carbon"] } }, "region": { "type": "Polyline3d", "required": true, "description": "房间轮廓", "tags": { "simulation": ["energy", "daylight", "solar", "wind", "thermal_comfort"] } }, "height": { "type": "number", "required": true, "description": "房间高度", "tags": { "simulation": ["energy", "daylight", "thermal_comfort"] } }, "elevation": { "type": "number", "description": "楼层内 Z 偏移", "tags": { "simulation": ["general"] } }, "boundaries": { "type": "Boundary[]", "description": "房间边界/墙体", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "apertures": { "type": "string[]", "description": "关联洞口 ID 列表", "tags": { "scale": ["building"], "simulation": ["energy", "daylight", "wind"] } }, "elements": { "type": "Element[]", "description": "房间内构件", "tags": { "scale": ["building"], "simulation": ["general"] } }, "geometryDriver": { "type": "object", "description": "几何驱动参数", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "mass_slice": { "description": "体量切片创建", "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "creationMethod": { "type": "RoomCreationMethod", "required": true, "default": "mass_slice", "tags": { "simulation": ["general"] } }, "programType": { "type": "string", "tags": { "scale": ["building"], "simulation": ["energy", "thermal_comfort", "carbon"] } }, "region": { "type": "Polyline3d", "required": true, "tags": { "simulation": ["energy", "daylight", "solar", "wind", "thermal_comfort"] } }, "height": { "type": "number", "required": true, "tags": { "simulation": ["energy", "daylight", "thermal_comfort"] } }, "elevation": { "type": "number", "tags": { "simulation": ["general"] } }, "boundaries": { "type": "Boundary[]", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "apertures": { "type": "string[]", "tags": { "scale": ["building"], "simulation": ["energy", "daylight", "wind"] } }, "elements": { "type": "Element[]", "tags": { "scale": ["building"], "simulation": ["general"] } }, "driverRef": { "type": "object", "required": true, "description": "体量引用", "tags": { "simulation": ["general"] }, "attributes": { "massId": { "type": "string", "required": true }, "sliceZ": { "type": "number", "required": true } } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "manual": { "description": "手动绘制", "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "creationMethod": { "type": "RoomCreationMethod", "required": true, "default": "manual", "tags": { "simulation": ["general"] } }, "programType": { "type": "string", "tags": { "scale": ["building"], "simulation": ["energy", "thermal_comfort", "carbon"] } }, "region": { "type": "Polyline3d", "required": true, "tags": { "simulation": ["energy", "daylight", "solar", "wind", "thermal_comfort"] } }, "height": { "type": "number", "required": true, "tags": { "simulation": ["energy", "daylight", "thermal_comfort"] } }, "elevation": { "type": "number", "tags": { "simulation": ["general"] } }, "boundaries": { "type": "Boundary[]", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "apertures": { "type": "string[]", "tags": { "scale": ["building"], "simulation": ["energy", "daylight", "wind"] } }, "elements": { "type": "Element[]", "tags": { "scale": ["building"], "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } } } }, "Aperture": { "description": "建筑洞口", "tags": { "scale": ["building"], "simulation": ["energy", "daylight", "solar", "wind"] }, "discriminator": "sourceType", "variants": { "hosted": { "description": "绑定到特定形体面", "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "sourceType": { "type": "string", "required": true, "default": "hosted", "tags": { "simulation": ["general"] } }, "geometryType": { "type": "ApertureGeometryType", "required": true, "tags": { "simulation": ["energy", "daylight", "solar", "wind"] } }, "width": { "type": "number", "tags": { "simulation": ["energy", "daylight"] } }, "height": { "type": "number", "tags": { "simulation": ["energy", "daylight"] } }, "sillHeight": { "type": "number", "description": "窗台高", "tags": { "simulation": ["energy", "daylight"] } }, "parent": { "type": "string", "description": "父实体 ID", "tags": { "simulation": ["general"] } }, "rooms": { "type": "string[]", "description": "相邻房间 ID", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "openRatio": { "type": "number", "default": 0, "description": "开启比", "tags": { "simulation": ["energy", "wind", "thermal_comfort"] } }, "operable": { "type": "boolean", "default": false, "tags": { "simulation": ["energy", "wind", "thermal_comfort"] } }, "hosting": { "type": "object", "required": true, "description": "宿主绑定信息", "tags": { "simulation": ["general"] }, "attributes": { "hostId": { "type": "string", "required": true }, "faceIndex": { "type": "integer", "required": true }, "uvRect": { "type": "UVRect", "required": true }, "context": { "type": "ApertureContextType", "required": true } } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "declarative": { "description": "声明式放置", "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "sourceType": { "type": "string", "required": true, "default": "declarative", "tags": { "simulation": ["general"] } }, "geometryType": { "type": "ApertureGeometryType", "required": true, "tags": { "simulation": ["energy", "daylight", "solar", "wind"] } }, "width": { "type": "number", "tags": { "simulation": ["energy", "daylight"] } }, "height": { "type": "number", "tags": { "simulation": ["energy", "daylight"] } }, "sillHeight": { "type": "number", "tags": { "simulation": ["energy", "daylight"] } }, "parent": { "type": "string", "tags": { "simulation": ["general"] } }, "rooms": { "type": "string[]", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "openRatio": { "type": "number", "default": 0, "tags": { "simulation": ["energy", "wind", "thermal_comfort"] } }, "operable": { "type": "boolean", "default": false, "tags": { "simulation": ["energy", "wind", "thermal_comfort"] } }, "placement": { "type": "object", "description": "放置描述", "tags": { "simulation": ["general"] }, "attributes": { "boundaryId": { "type": "string" }, "position": { "type": "string", "description": "center, start, end 或距离" }, "orientation": { "type": "Direction" } } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } } } }, "Boundary": { "description": "空间边界/墙体", "tags": { "scale": ["building", "community"], "simulation": ["energy", "thermal_comfort", "carbon"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "type": { "type": "BoundaryType", "required": true, "tags": { "simulation": ["energy", "thermal_comfort", "carbon"] } }, "region": { "type": "Polyline3d", "required": true, "description": "边界线段或多边形", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "thickness": { "type": "number", "description": "墙厚", "unit": "m", "tags": { "scale": ["building"], "simulation": ["energy", "thermal_comfort", "carbon"] } }, "height": { "type": "number", "description": "墙高", "unit": "m", "tags": { "simulation": ["energy", "thermal_comfort"] } }, "direction": { "type": "Direction", "description": "朝向", "tags": { "simulation": ["energy", "daylight", "solar"] } }, "pitch": { "type": "number", "description": "倾斜角度", "unit": "deg", "tags": { "simulation": ["energy", "solar"] } }, "hostRoomId": { "type": "string", "description": "所属房间 ID", "tags": { "simulation": ["general"] } }, "constructionId": { "type": "string", "description": "构造 ID", "tags": { "simulation": ["energy", "thermal_comfort", "carbon"] } }, "sharedBy": { "type": "string[]", "description": "共享此边界的房间 ID 列表", "tags": { "simulation": ["thermal_comfort"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "Element": { "description": "结构构件", "tags": { "scale": ["building"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "type": { "type": "ElementType", "required": true, "tags": { "simulation": ["general"] } }, "region": { "type": "Polyline3d", "description": "截面轮廓", "tags": { "simulation": ["general"] } }, "height": { "type": "number", "unit": "m", "tags": { "simulation": ["general"] } }, "materialId": { "type": "string", "description": "材料 ID", "tags": { "simulation": ["carbon"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "MassEntity": { "description": "参数化体量", "tags": { "scale": ["building"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "region": { "type": "Polyline3d", "tags": { "simulation": ["general"] } }, "height": { "type": "number", "unit": "m", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "Shaft": { "description": "竖井(楼梯/电梯/管道)", "tags": { "scale": ["building"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "type": { "type": "string", "description": "stair/elevator/duct", "tags": { "simulation": ["general"] } }, "spanLevels": { "type": "string[]", "description": "穿越的楼层 ID", "tags": { "simulation": ["general"] } }, "region": { "type": "Polyline3d", "description": "竖井截面", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "Shade": { "description": "遮阳构件", "tags": { "scale": ["building", "community"], "simulation": ["energy", "daylight", "solar", "thermal_comfort"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "region": { "type": "Polyline3d", "description": "遮阳轮廓", "tags": { "simulation": ["energy", "daylight", "solar", "thermal_comfort"] } }, "height": { "type": "number", "unit": "m", "tags": { "simulation": ["energy", "daylight", "solar"] } }, "transmittance": { "type": "number", "default": 0, "description": "透射率 0-1", "tags": { "simulation": ["energy", "daylight", "solar"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "GridSystem": { "description": "轴网系统", "tags": { "scale": ["building"] }, "attributes": { "identifier": { "type": "string", "required": true, "tags": { "simulation": ["general"] } }, "displayName": { "type": "string", "tags": { "simulation": ["general"] } }, "axisX": { "type": "string[]", "description": "X 向轴线名", "tags": { "simulation": ["general"] } }, "axisY": { "type": "string[]", "description": "Y 向轴线名", "tags": { "simulation": ["general"] } }, "spacingsX": { "type": "number[]", "description": "X 向跨距", "unit": "m", "tags": { "simulation": ["general"] } }, "spacingsY": { "type": "number[]", "description": "Y 向跨距", "unit": "m", "tags": { "simulation": ["general"] } }, "origin": { "type": "Point3d", "required": true, "description": "轴网原点", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } }, "Relation": { "description": "拓扑关系边", "tags": { "scale": ["building", "community", "urban"] }, "attributes": { "type": { "type": "RelationType", "required": true, "tags": { "simulation": ["general"] } }, "source": { "type": "string", "required": true, "description": "源实体 ID", "tags": { "simulation": ["general"] } }, "target": { "type": "string", "required": true, "description": "目标实体 ID", "tags": { "simulation": ["general"] } }, "metadata": { "type": "object", "tags": { "simulation": ["general"] } } } } } }