diff --git a/comcheck_api/schemas/comCheck.schema.json b/comcheck_api/schemas/comCheck.schema.json index 2099f4a..ecb3756 100644 --- a/comcheck_api/schemas/comCheck.schema.json +++ b/comcheck_api/schemas/comCheck.schema.json @@ -7,6 +7,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -212,6 +213,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -255,6 +257,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -285,6 +288,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -457,6 +461,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -607,6 +612,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -644,6 +650,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -655,6 +662,7 @@ "$comment": "This needs to be unique across all ag walls." }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Exterior Wall", @@ -935,6 +943,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -945,9 +954,11 @@ "default": "" }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Basement", + "pattern": "^Basement$", "$comment": "This shall always be 'Basement'" }, "bldgUseKey": { @@ -1154,6 +1165,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -1187,6 +1199,7 @@ "$comment": "This data is used for reference - no actual impact on calculations." }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Window", @@ -1394,6 +1407,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -1409,6 +1423,7 @@ "default": "" }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Door", @@ -1653,6 +1668,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -1668,6 +1684,7 @@ "default": "" }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Skylight", @@ -1877,6 +1894,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -1888,6 +1906,7 @@ "$comment": "This needs to be unique across all ag walls." }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "default": "Roof", @@ -2084,6 +2103,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2093,6 +2113,7 @@ "type": ["string", "null"] }, "assemblyType": { + "readOnly": true, "description": "The type of the component", "type": "string", "$comment": "This shall always be 'Roof'" @@ -2222,6 +2243,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2259,6 +2281,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2292,6 +2315,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2382,6 +2406,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2467,6 +2492,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2511,6 +2537,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2634,6 +2661,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2695,6 +2723,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -2858,6 +2887,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": "integer" }, @@ -2950,6 +2980,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3161,6 +3192,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3330,6 +3362,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3389,6 +3422,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3466,6 +3500,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3510,6 +3545,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3612,6 +3648,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3786,6 +3823,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3871,6 +3909,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3906,6 +3945,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3957,6 +3997,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." @@ -3973,6 +4014,7 @@ "type": "object", "properties": { "id": { + "readOnly": true, "description": "Scope-unique reference identifier for instances of this data group.", "type": ["string", "integer"], "$comment": "All id data elements are shown as required so that every data group can be explcitly identified." diff --git a/comcheck_api/types/core_types.py b/comcheck_api/types/core_types.py index 6258ae2..6888ff2 100644 --- a/comcheck_api/types/core_types.py +++ b/comcheck_api/types/core_types.py @@ -1,6 +1,6 @@ # generated by datamodel-codegen: # filename: comCheck.schema.json -# timestamp: 2026-06-10T04:00:05+00:00 +# timestamp: 2026-06-22T21:36:18+00:00 from __future__ import annotations @@ -36,7 +36,8 @@ class Project(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None projectTitle: Annotated[str | None, Field(description='Project title')] = ( @@ -126,7 +127,8 @@ class Location(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None state: Annotated[ @@ -2010,7 +2012,8 @@ class Control(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None version: Annotated[ @@ -2033,7 +2036,8 @@ class Requirements(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None category: Annotated[ @@ -2060,7 +2064,8 @@ class Window(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None bldgUseKey: Annotated[ @@ -2078,7 +2083,7 @@ class Window(CustomBaseModel): Field(description='Building type of the adjacent space'), ] = None assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, Field(description='The type of the component', frozen=True) ] = 'Window' propUValue: Annotated[ float | None, @@ -2154,7 +2159,8 @@ class Door(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None bldgUseKey: Annotated[ @@ -2164,7 +2170,7 @@ class Door(CustomBaseModel): str | None, Field(description='The name of the component') ] = '' assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, Field(description='The type of the component', frozen=True) ] = 'Door' adjacentSpaceType: Annotated[ AdjacentSpaceTypeOptions | None, @@ -2252,7 +2258,8 @@ class Skylight(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None bldgUseKey: Annotated[ @@ -2262,7 +2269,7 @@ class Skylight(CustomBaseModel): str | None, Field(description='The name of the component') ] = '' assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, Field(description='The type of the component', frozen=True) ] = 'Skylight' adjacentSpaceType: Annotated[ AdjacentSpaceTypeOptions | None, @@ -2338,14 +2345,15 @@ class Roof(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ str | None, Field(description='The name of the component') ] = '' assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, Field(description='The type of the component', frozen=True) ] = 'Roof' bldgUseKey: Annotated[ str, Field(description='key reference of the building use area data group') @@ -2424,11 +2432,14 @@ class Floor(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[str | None, Field(description='The name of the component')] - assemblyType: Annotated[str, Field(description='The type of the component')] + assemblyType: Annotated[ + str, Field(description='The type of the component', frozen=True) + ] bldgUseKey: Annotated[ str, Field(description='key reference of the building use area data group') ] @@ -2503,7 +2514,8 @@ class HVACSystem(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None altExemptType: Annotated[ @@ -2659,7 +2671,8 @@ class FixtureSchedule(CustomBaseModel): id: Annotated[ int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None lightingId: Annotated[ @@ -2719,7 +2732,8 @@ class HVACPlant(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None altExemptType: Annotated[ @@ -2856,7 +2870,8 @@ class Fan(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None brakeHp: Annotated[ @@ -2912,7 +2927,8 @@ class FanSystemPressureDropCredits(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None cfm: Annotated[ @@ -2952,7 +2968,8 @@ class ServiceWaterHeatingSystem(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None circulationPump: Annotated[ @@ -3039,7 +3056,8 @@ class EfficiencyPackage(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None bldgUseKey: Annotated[ @@ -3186,7 +3204,8 @@ class RenewableSystem(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ @@ -3211,7 +3230,8 @@ class OffsiteRenewableProcurement(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ @@ -3237,7 +3257,8 @@ class LightingControls(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None type: Annotated[ @@ -3252,7 +3273,8 @@ class ThermalBridge(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None thermalBridgeType: Annotated[ @@ -3281,14 +3303,15 @@ class AgWall(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ str | None, Field(description='The name of the component') ] = '' assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, Field(description='The type of the component', frozen=True) ] = 'Exterior Wall' bldgUseKey: Annotated[ str, Field(description='key reference of the building use area data group') @@ -3410,14 +3433,18 @@ class BgWall(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ str | None, Field(description='The name of the component') ] = '' assemblyType: Annotated[ - str | None, Field(description='The type of the component') + str | None, + Field( + description='The type of the component', pattern='^Basement:' + ), ] = 'Basement' bldgUseKey: Annotated[ str, Field(description='key reference of the building use area data group') @@ -3507,7 +3534,8 @@ class Fixture(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None advControlsAllowanceAperture: Annotated[ @@ -3591,7 +3619,8 @@ class FanSystem(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None complianceMessage: Annotated[ @@ -3641,7 +3670,8 @@ class Renewable(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None renewableException: Annotated[ @@ -3690,7 +3720,8 @@ class Envelope(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None agWall: Annotated[ @@ -3773,7 +3804,8 @@ class InteriorLightingSpace(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ @@ -3846,7 +3878,8 @@ class HVAC(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None hvacSystem: Annotated[ @@ -3864,7 +3897,8 @@ class ActivityUse(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None key: Annotated[ @@ -3917,7 +3951,8 @@ class ExteriorLightingSpace(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None description: Annotated[ @@ -3951,7 +3986,8 @@ class WholeBldgUse(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None areaDescription: Annotated[ @@ -4008,7 +4044,8 @@ class ExteriorUse(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None areaDescription: Annotated[ @@ -4042,7 +4079,8 @@ class Lighting(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None wholeBldgUse: Annotated[ @@ -4065,7 +4103,8 @@ class ComBuilding(CustomBaseModel): id: Annotated[ str | int | None, Field( - description='Scope-unique reference identifier for instances of this data group.' + description='Scope-unique reference identifier for instances of this data group.', + frozen=True, ), ] = None control: Annotated[ diff --git a/tools/generate_core_types.py b/tools/generate_core_types.py index 055915f..ee890eb 100644 --- a/tools/generate_core_types.py +++ b/tools/generate_core_types.py @@ -37,6 +37,7 @@ "--use-default", # Use default values from the schema "--field-constraints", # Generate validation constraints (e.g., max_length, minItems) "--use-annotated", # Best practice for Pydantic V2 validations + "--use-frozen-field", ], check=False, )