IFC Model Author
This is an orchestration skill. It defines the order in which an IFC model is
built and names the syntax, impl and errors skill that owns each step. It does
not re-teach those skills: it sequences them.
ALWAYS author an IFC model in dependency order: a step depends on every step
above it. NEVER add an element before the project skeleton (project, units,
contexts, spatial tree) exists, because an element with no spatial parent and
no representation context is invisible to every downstream consumer.
Quick Reference
The authoring sequence
| # |
Step |
Key entities |
Owning skill |
| 0 |
Decide version and MVD |
(none) |
ifc-core-version-evolution, ifc-core-mvd |
| 1 |
STEP header |
FILE_SCHEMA, FILE_DESCRIPTION |
ifc-syntax-step-physical-file |
| 2 |
Project root |
IfcProject |
ifc-impl-authoring-file |
| 3 |
Units |
IfcUnitAssignment, IfcSIUnit |
ifc-syntax-units |
| 4 |
Representation contexts |
IfcGeometricRepresentationContext |
ifc-syntax-geometry-representations |
| 5 |
Owner history |
IfcOwnerHistory |
ifc-impl-authoring-file |
| 6 |
Spatial tree |
IfcSite, IfcBuilding, IfcBuildingStorey, IfcSpace, IfcRelAggregates |
ifc-impl-spatial-decomposition |
| 7 |
Elements |
IfcWall, IfcSlab, IfcRelContainedInSpatialStructure |
ifc-syntax-building-elements |
| 8 |
Geometry |
IfcProductDefinitionShape, IfcShapeRepresentation |
ifc-syntax-geometry-representations |
| 9 |
Placement |
IfcLocalPlacement |
ifc-syntax-geometry-placement |
| 10 |
Properties and quantities |
IfcPropertySet, IfcRelDefinesByProperties |
ifc-syntax-property-sets |
| 11 |
Materials and classifications |
IfcMaterial, IfcRelAssociatesMaterial |
ifc-syntax-materials |
| 12 |
Self-validate |
(none) |
ifc-agents-file-validator |
Steps 0 to 6 are the mandatory skeleton: nothing in steps 7 to 11 is valid
without them. Steps 8 to 11 repeat per element.
Version differences that change the build
| Concern |
IFC2x3 |
IFC4 |
IFC4.3 |
FILE_SCHEMA token |
IFC2X3 |
IFC4 |
IFC4X3_ADD2 |
IfcRoot.OwnerHistory |
mandatory |
optional |
optional |
| Element supertype |
IfcBuildingElement |
IfcBuildingElement |
IfcBuiltElement |
| Tessellated geometry |
not available |
available |
available |
| Top spatial container |
IfcBuilding |
IfcBuilding |
IfcFacility / IfcBuilding |
ALWAYS instantiate concrete subtypes (IfcWall, IfcSlab). NEVER instantiate
the abstract supertype. See ifc-errors-version-mismatch for the rename detail.
Decision Trees
Step 0 : version and MVD before any entity
What does the model contain ?
+-- infrastructure (road, rail, bridge, alignment, earthworks)
| -> IFC4.3 (token IFC4X3_ADD2). No earlier schema has these entities.
+-- a building, and the receiver is modern openBIM software
| -> IFC4 (token IFC4). The safe default for building models.
+-- a building, and the receiver is an IFC2x3-only tool
-> IFC2x3 (token IFC2X3). Accept the limits: no tessellation.
Which MVD does the deliverable target ?
+-- coordination / clash / viewing -> Reference View (IFC4)
+-- full round-trip / re-editing -> Design Transfer View (IFC4)
+-- IFC2x3 deliverable -> Coordination View 2.0
-> record the chosen MVD in FILE_DESCRIPTION as the ViewDefinition string.
-> see ifc-core-mvd and ifc-impl-mvd-export for MVD-conformant export.
The version and MVD are fixed BEFORE step 1. NEVER revisit them mid-build:
changing schema after elements exist forces a full migration.
Build-order dependency check
About to author entity X. Is every prerequisite present ?
IfcUnitAssignment requires IfcProject
IfcGeometricRepresentationContext requires IfcProject
IfcSite requires IfcProject + IfcRelAggregates
IfcBuildingStorey requires IfcBuilding (or IfcFacility in IFC4.3)
any IfcElement requires a spatial container to contain it
IfcShapeRepresentation requires an IfcGeometricRepresentationContext
IfcLocalPlacement requires the parent placement (or none for the site)
IfcRelDefinesByProperties requires the element it defines
IfcRelAssociatesMaterial requires the element it associates
prerequisite missing -> author the prerequisite first. NEVER forward-reference
a skeleton entity that does not exist yet.
Self-check before declaring the model done
Run ifc-agents-file-validator. Confirm every answer is YES :
[ ] FILE_SCHEMA token matches every entity used (ifc-errors-version-mismatch)
[ ] exactly one IfcProject, and it has a Name (WHERE rule HasName)
[ ] IfcUnitAssignment present, one unit per unit type (ifc-syntax-units)
[ ] at least one IfcGeometricRepresentationContext (ifc-syntax-geometry-representations)
[ ] spatial tree complete, wired with IfcRelAggregates (ifc-errors-spatial-structure)
[ ] every element contained exactly once (ifc-errors-spatial-structure)
[ ] every GlobalId present and unique (ifc-errors-schema-validation)
[ ] every #id reference resolves (ifc-errors-broken-references)
[ ] geometry sits in a declared context (ifc-errors-geometry-issues)
[ ] no abstract entity instantiated (ifc-errors-schema-validation)
any NO -> fix before delivery. NEVER declare a model done on an unrun check.
Patterns
Pattern 1 : fix version and MVD before authoring anything
The schema version and the MVD target are project-level decisions. They
determine the FILE_SCHEMA token, which entities are legal, whether
tessellation is available, and what the ViewDefinition string says.
ALWAYS complete step 0 before step 1. NEVER start writing entities and decide
the version later: every entity name and attribute layout depends on the
schema. Changing schema after elements exist is a migration, not an edit (see
ifc-impl-version-migration).
Pattern 2 : the mandatory skeleton precedes every element
An IFC file is not "configured" like software; its skeleton is the minimum
structure every valid model needs before any element can exist:
- Exactly one
IfcProject. IfcProject has no explicit attributes of its
own; it inherits from IfcRoot and IfcContext. The HasName WHERE rule
makes Name mandatory.
- One
IfcUnitAssignment, referenced by IfcProject.UnitsInContext, declaring
exactly one unit per unit type (length, area, volume, plane angle). A model
with no units is ambiguous by 1000x (see ifc-errors-property-set-mistakes).
- At least one
IfcGeometricRepresentationContext with ContextType set to
'Model' and CoordinateSpaceDimension of 3, referenced by
IfcProject.RepresentationContexts. Sub-contexts (Body, Axis,
FootPrint) are IfcGeometricRepresentationSubContext instances.
- An
IfcOwnerHistory: mandatory in IFC2x3, optional in IFC4 and IFC4.3 but
expected by many importers.
ALWAYS author the skeleton top-down: project, then units and contexts, then the
spatial tree. NEVER attach an element to a half-built skeleton.
Pattern 3 : two relationships, two jobs
The spatial tree and element containment use different relationships. Confusing
them is the most common authoring fault.
IfcRelAggregates builds the spatial hierarchy itself:
IfcProject aggregates IfcSite, IfcSite aggregates IfcBuilding or
IfcFacility, that aggregates IfcBuildingStorey or IfcFacilityPart, that
aggregates IfcSpace. Attributes: RelatingObject (the whole),
RelatedObjects (the parts).
IfcRelContainedInSpatialStructure places a physical element into one spatial
level. Attributes: RelatingStructure (one IfcSpatialElement),
RelatedElements (a set of IfcProduct). WHERE rule WR31: a spatial element
is never a RelatedElement here; spatial nesting uses IfcRelAggregates.
ALWAYS contain every physical element exactly once with
IfcRelContainedInSpatialStructure. NEVER use IfcRelAggregates to put a wall
on a storey, and NEVER use IfcRelContainedInSpatialStructure to nest storeys.
In IFC4.3 the spatial tree can use IfcFacility and IfcFacilityPart;
IfcBuilding and IfcBuildingStorey are re-parented under them.
Pattern 4 : geometry and placement attach per element
Each element repeats the same four-part attachment:
IfcProduct.Representation points to one IfcProductDefinitionShape.
- The shape holds one or more
IfcShapeRepresentation. Each has a
RepresentationIdentifier (Body, Axis, FootPrint) and a
RepresentationType (SweptSolid, Brep, Tessellation, and others).
IfcShapeRepresentation.ContextOfItems MUST point to an
IfcGeometricRepresentationContext (or a sub-context). The WHERE rule
requires the context to be a geometric representation context.
IfcProduct.ObjectPlacement points to an IfcLocalPlacement, chained to the
parent placement through PlacementRelTo. The site placement has no parent.
ALWAYS put geometry items in a declared context and chain the placement to the
spatial parent. NEVER emit geometry with no context: a viewer cannot scale or
position it (see ifc-errors-geometry-issues).
Pattern 5 : semantic enrichment is the last layer
Properties, quantities, materials and classifications attach to elements that
already exist, are placed and have geometry:
IfcPropertySet linked by IfcRelDefinesByProperties.
IfcElementQuantity linked by IfcRelDefinesByProperties.
IfcMaterial and the layer, profile and constituent set families linked by
IfcRelAssociatesMaterial.
IfcClassificationReference linked by IfcRelAssociatesClassification.
ALWAYS enrich after the element, its placement and its geometry exist. See
ifc-impl-data-enrichment for the enrichment workflow and
ifc-errors-property-set-mistakes for the reserved Pset_ prefix and
type-versus-occurrence traps.
Pattern 6 : self-validate before delivery
A model is done only when it passes validation, not when the last element is
written. Run ifc-agents-file-validator and the self-check decision tree above.
ALWAYS validate before declaring the model done. NEVER deliver a model on the
assumption that "it opened in one viewer": a viewer is lenient, the
buildingSMART validation pipeline is not (see ifc-core-validation).
Reference Links
references/methods.md : the full step-by-step authoring procedure, the
owning-skill map, and the version-specific build differences.
references/examples.md : a minimal valid IFC4 file built in sequence, and
the per-element repeat block.
references/anti-patterns.md : every authoring-orchestration failure mode.
Cross-references:
ifc-impl-authoring-file : the hands-on file-authoring workflow.
ifc-impl-spatial-decomposition : building the spatial tree correctly.
ifc-impl-data-enrichment : attaching properties, materials, classifications.
ifc-impl-mvd-export : exporting a model conformant to an MVD.
ifc-agents-file-validator : the validation orchestration this skill calls.
ifc-errors-version-mismatch, ifc-errors-spatial-structure,
ifc-errors-geometry-issues, ifc-errors-schema-validation : the failure
modes the self-check guards against.
Official sources (verify before asserting any entity or attribute):
1---2name: ifc-agents-model-author3description: Use when authoring a complete, coordinated IFC model from scratch and you need the correct build order, or when an IFC file you produced is rejected, opens empty in a viewer, or loses its elements, properties or geometry downstream. Prevents adding elements before the project skeleton exists, skipping units or representation contexts, wiring the spatial tree with the wrong relationship, attaching geometry with no context, and declaring a model done without validating it. Covers the end-to-end authoring sequence (version and MVD decision, STEP header, IfcProject, units, representation contexts, owner history, spatial tree, elements, geometry, placement, properties, materials, classifications), which syntax and impl skill owns each step, the IFC2x3 versus IFC4 versus IFC4.3 differences that change the build, and the self-check before delivery. Keywords: IFC model authoring, build a complete IFC file, IfcProject setup, IfcUnitAssignment, IfcGeometricRepresentationContext, spatial structure, IfcRelAggregates, Ifc4license: MIT5---67# IFC Model Author89This is an orchestration skill. It defines the order in which an IFC model is10built and names the syntax, impl and errors skill that owns each step. It does11not re-teach those skills: it sequences them.1213ALWAYS author an IFC model in dependency order: a step depends on every step14above it. NEVER add an element before the project skeleton (project, units,15contexts, spatial tree) exists, because an element with no spatial parent and16no representation context is invisible to every downstream consumer.1718## Quick Reference1920### The authoring sequence2122| # | Step | Key entities | Owning skill |23|---|------|--------------|--------------|24| 0 | Decide version and MVD | (none) | `ifc-core-version-evolution`, `ifc-core-mvd` |25| 1 | STEP header | `FILE_SCHEMA`, `FILE_DESCRIPTION` | `ifc-syntax-step-physical-file` |26| 2 | Project root | `IfcProject` | `ifc-impl-authoring-file` |27| 3 | Units | `IfcUnitAssignment`, `IfcSIUnit` | `ifc-syntax-units` |28| 4 | Representation contexts | `IfcGeometricRepresentationContext` | `ifc-syntax-geometry-representations` |29| 5 | Owner history | `IfcOwnerHistory` | `ifc-impl-authoring-file` |30| 6 | Spatial tree | `IfcSite`, `IfcBuilding`, `IfcBuildingStorey`, `IfcSpace`, `IfcRelAggregates` | `ifc-impl-spatial-decomposition` |31| 7 | Elements | `IfcWall`, `IfcSlab`, `IfcRelContainedInSpatialStructure` | `ifc-syntax-building-elements` |32| 8 | Geometry | `IfcProductDefinitionShape`, `IfcShapeRepresentation` | `ifc-syntax-geometry-representations` |33| 9 | Placement | `IfcLocalPlacement` | `ifc-syntax-geometry-placement` |34| 10 | Properties and quantities | `IfcPropertySet`, `IfcRelDefinesByProperties` | `ifc-syntax-property-sets` |35| 11 | Materials and classifications | `IfcMaterial`, `IfcRelAssociatesMaterial` | `ifc-syntax-materials` |36| 12 | Self-validate | (none) | `ifc-agents-file-validator` |3738Steps 0 to 6 are the mandatory skeleton: nothing in steps 7 to 11 is valid39without them. Steps 8 to 11 repeat per element.4041### Version differences that change the build4243| Concern | IFC2x3 | IFC4 | IFC4.3 |44|---------|--------|------|--------|45| `FILE_SCHEMA` token | `IFC2X3` | `IFC4` | `IFC4X3_ADD2` |46| `IfcRoot.OwnerHistory` | mandatory | optional | optional |47| Element supertype | `IfcBuildingElement` | `IfcBuildingElement` | `IfcBuiltElement` |48| Tessellated geometry | not available | available | available |49| Top spatial container | `IfcBuilding` | `IfcBuilding` | `IfcFacility` / `IfcBuilding` |5051ALWAYS instantiate concrete subtypes (`IfcWall`, `IfcSlab`). NEVER instantiate52the abstract supertype. See `ifc-errors-version-mismatch` for the rename detail.5354## Decision Trees5556### Step 0 : version and MVD before any entity5758```59What does the model contain ?60 +-- infrastructure (road, rail, bridge, alignment, earthworks)61 | -> IFC4.3 (token IFC4X3_ADD2). No earlier schema has these entities.62 +-- a building, and the receiver is modern openBIM software63 | -> IFC4 (token IFC4). The safe default for building models.64 +-- a building, and the receiver is an IFC2x3-only tool65 -> IFC2x3 (token IFC2X3). Accept the limits: no tessellation.6667Which MVD does the deliverable target ?68 +-- coordination / clash / viewing -> Reference View (IFC4)69 +-- full round-trip / re-editing -> Design Transfer View (IFC4)70 +-- IFC2x3 deliverable -> Coordination View 2.071 -> record the chosen MVD in FILE_DESCRIPTION as the ViewDefinition string.72 -> see ifc-core-mvd and ifc-impl-mvd-export for MVD-conformant export.7374The version and MVD are fixed BEFORE step 1. NEVER revisit them mid-build:75changing schema after elements exist forces a full migration.76```7778### Build-order dependency check7980```81About to author entity X. Is every prerequisite present ?8283 IfcUnitAssignment requires IfcProject84 IfcGeometricRepresentationContext requires IfcProject85 IfcSite requires IfcProject + IfcRelAggregates86 IfcBuildingStorey requires IfcBuilding (or IfcFacility in IFC4.3)87 any IfcElement requires a spatial container to contain it88 IfcShapeRepresentation requires an IfcGeometricRepresentationContext89 IfcLocalPlacement requires the parent placement (or none for the site)90 IfcRelDefinesByProperties requires the element it defines91 IfcRelAssociatesMaterial requires the element it associates9293 prerequisite missing -> author the prerequisite first. NEVER forward-reference94 a skeleton entity that does not exist yet.95```9697### Self-check before declaring the model done9899```100Run ifc-agents-file-validator. Confirm every answer is YES :101102 [ ] FILE_SCHEMA token matches every entity used (ifc-errors-version-mismatch)103 [ ] exactly one IfcProject, and it has a Name (WHERE rule HasName)104 [ ] IfcUnitAssignment present, one unit per unit type (ifc-syntax-units)105 [ ] at least one IfcGeometricRepresentationContext (ifc-syntax-geometry-representations)106 [ ] spatial tree complete, wired with IfcRelAggregates (ifc-errors-spatial-structure)107 [ ] every element contained exactly once (ifc-errors-spatial-structure)108 [ ] every GlobalId present and unique (ifc-errors-schema-validation)109 [ ] every #id reference resolves (ifc-errors-broken-references)110 [ ] geometry sits in a declared context (ifc-errors-geometry-issues)111 [ ] no abstract entity instantiated (ifc-errors-schema-validation)112113 any NO -> fix before delivery. NEVER declare a model done on an unrun check.114```115116## Patterns117118### Pattern 1 : fix version and MVD before authoring anything119120The schema version and the MVD target are project-level decisions. They121determine the `FILE_SCHEMA` token, which entities are legal, whether122tessellation is available, and what the ViewDefinition string says.123124ALWAYS complete step 0 before step 1. NEVER start writing entities and decide125the version later: every entity name and attribute layout depends on the126schema. Changing schema after elements exist is a migration, not an edit (see127`ifc-impl-version-migration`).128129### Pattern 2 : the mandatory skeleton precedes every element130131An IFC file is not "configured" like software; its skeleton is the minimum132structure every valid model needs before any element can exist:1331341. Exactly one `IfcProject`. `IfcProject` has no explicit attributes of its135 own; it inherits from `IfcRoot` and `IfcContext`. The `HasName` WHERE rule136 makes `Name` mandatory.1372. One `IfcUnitAssignment`, referenced by `IfcProject.UnitsInContext`, declaring138 exactly one unit per unit type (length, area, volume, plane angle). A model139 with no units is ambiguous by 1000x (see `ifc-errors-property-set-mistakes`).1403. At least one `IfcGeometricRepresentationContext` with `ContextType` set to141 `'Model'` and `CoordinateSpaceDimension` of 3, referenced by142 `IfcProject.RepresentationContexts`. Sub-contexts (`Body`, `Axis`,143 `FootPrint`) are `IfcGeometricRepresentationSubContext` instances.1444. An `IfcOwnerHistory`: mandatory in IFC2x3, optional in IFC4 and IFC4.3 but145 expected by many importers.146147ALWAYS author the skeleton top-down: project, then units and contexts, then the148spatial tree. NEVER attach an element to a half-built skeleton.149150### Pattern 3 : two relationships, two jobs151152The spatial tree and element containment use different relationships. Confusing153them is the most common authoring fault.154155- `IfcRelAggregates` builds the spatial hierarchy itself:156 `IfcProject` aggregates `IfcSite`, `IfcSite` aggregates `IfcBuilding` or157 `IfcFacility`, that aggregates `IfcBuildingStorey` or `IfcFacilityPart`, that158 aggregates `IfcSpace`. Attributes: `RelatingObject` (the whole),159 `RelatedObjects` (the parts).160- `IfcRelContainedInSpatialStructure` places a physical element into one spatial161 level. Attributes: `RelatingStructure` (one `IfcSpatialElement`),162 `RelatedElements` (a set of `IfcProduct`). WHERE rule WR31: a spatial element163 is never a `RelatedElement` here; spatial nesting uses `IfcRelAggregates`.164165ALWAYS contain every physical element exactly once with166`IfcRelContainedInSpatialStructure`. NEVER use `IfcRelAggregates` to put a wall167on a storey, and NEVER use `IfcRelContainedInSpatialStructure` to nest storeys.168In IFC4.3 the spatial tree can use `IfcFacility` and `IfcFacilityPart`;169`IfcBuilding` and `IfcBuildingStorey` are re-parented under them.170171### Pattern 4 : geometry and placement attach per element172173Each element repeats the same four-part attachment:1741751. `IfcProduct.Representation` points to one `IfcProductDefinitionShape`.1762. The shape holds one or more `IfcShapeRepresentation`. Each has a177 `RepresentationIdentifier` (`Body`, `Axis`, `FootPrint`) and a178 `RepresentationType` (`SweptSolid`, `Brep`, `Tessellation`, and others).1793. `IfcShapeRepresentation.ContextOfItems` MUST point to an180 `IfcGeometricRepresentationContext` (or a sub-context). The WHERE rule181 requires the context to be a geometric representation context.1824. `IfcProduct.ObjectPlacement` points to an `IfcLocalPlacement`, chained to the183 parent placement through `PlacementRelTo`. The site placement has no parent.184185ALWAYS put geometry items in a declared context and chain the placement to the186spatial parent. NEVER emit geometry with no context: a viewer cannot scale or187position it (see `ifc-errors-geometry-issues`).188189### Pattern 5 : semantic enrichment is the last layer190191Properties, quantities, materials and classifications attach to elements that192already exist, are placed and have geometry:193194- `IfcPropertySet` linked by `IfcRelDefinesByProperties`.195- `IfcElementQuantity` linked by `IfcRelDefinesByProperties`.196- `IfcMaterial` and the layer, profile and constituent set families linked by197 `IfcRelAssociatesMaterial`.198- `IfcClassificationReference` linked by `IfcRelAssociatesClassification`.199200ALWAYS enrich after the element, its placement and its geometry exist. See201`ifc-impl-data-enrichment` for the enrichment workflow and202`ifc-errors-property-set-mistakes` for the reserved `Pset_` prefix and203type-versus-occurrence traps.204205### Pattern 6 : self-validate before delivery206207A model is done only when it passes validation, not when the last element is208written. Run `ifc-agents-file-validator` and the self-check decision tree above.209210ALWAYS validate before declaring the model done. NEVER deliver a model on the211assumption that "it opened in one viewer": a viewer is lenient, the212buildingSMART validation pipeline is not (see `ifc-core-validation`).213214## Reference Links215216- `references/methods.md` : the full step-by-step authoring procedure, the217 owning-skill map, and the version-specific build differences.218- `references/examples.md` : a minimal valid IFC4 file built in sequence, and219 the per-element repeat block.220- `references/anti-patterns.md` : every authoring-orchestration failure mode.221222Cross-references:223224- `ifc-impl-authoring-file` : the hands-on file-authoring workflow.225- `ifc-impl-spatial-decomposition` : building the spatial tree correctly.226- `ifc-impl-data-enrichment` : attaching properties, materials, classifications.227- `ifc-impl-mvd-export` : exporting a model conformant to an MVD.228- `ifc-agents-file-validator` : the validation orchestration this skill calls.229- `ifc-errors-version-mismatch`, `ifc-errors-spatial-structure`,230 `ifc-errors-geometry-issues`, `ifc-errors-schema-validation` : the failure231 modes the self-check guards against.232233Official sources (verify before asserting any entity or attribute):234235- IFC4.3 specification: https://ifc43-docs.standards.buildingsmart.org/236- IFC4 ADD2 TC1: https://standards.buildingsmart.org/IFC/RELEASE/IFC4/ADD2_TC1/HTML/237- IFC2x3 TC1: https://standards.buildingsmart.org/IFC/RELEASE/IFC2x3/TC1/HTML/