Skip to content

feat(elements): export structural framing, columns, foundations and generic models from element records (RE-36) - #318

Merged
DrunkOnJava merged 1 commit into
mainfrom
feat/structural-record-categories
Sep 23, 2026
Merged

DrunkOnJava merged 1 commit into
mainfrom
feat/structural-record-categories

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Sep 23, 2026 •

Copy link
Copy Markdown
Owner

Summary

Structural framing, structural columns, structural foundations and generic models now decode from partition element records, with ElementIds from RE-35's enclosing records. They export as IfcBeam (.BEAM.), IfcColumn (.COLUMN.), IfcFooting and IfcBuildingElementProxy.

Motivation

A free Revit reader has to open structural models. On Autodesk's Snowdon Towers structural sample rvt-rs exported only 60 walls and slabs; the framing, columns and foundations were never mapped. Nearly all of their frames use the second prologue, so they only became reachable with RE-35 (#317).

Changes

  • src/partition_element_records.rs: adds OST_STRUCTURAL_FRAMING, OST_STRUCTURAL_COLUMNS, OST_STRUCTURAL_FOUNDATION and OST_GENERIC_MODEL to PRODUCT_RECORD_CATEGORIES / RECOVERED_CATEGORIES. The mappings already exist in category_map.
  • examples/probe_re36_vim_oracle.rs (new) contains a small BFAST/VIM reader. It scores every placed-instance element record of a model against one document of a VIM export (vim-format, MIT): same category, other category, or absent.
  • reports/element-framing/RE-36-structural-categories.md (new).
  • docs/support-matrix.json: new element-records-structural-categories row, status experimental because the evidence is local-only.
  • README, docs/status.md, docs/supported-profile.md, ROADMAP, docs/export-diagnostics.md, CHANGELOG [Unreleased].

Measurements (local; the Snowdon samples have no licence and are not in CI)

probe_re36_vim_oracle over the Structural sample, against vimaec/vim-hackathon vims/Snowdon.r2027.vim (commit 50f4373):

category frames same category in the VIM absent other category
structural framing 942 914 28 0
structural columns 74 74 0 0
structural foundations 90 90 0 0
generic models 91 91 0 0
all categories 1,403 0

The VIM is the 2027 edition of the sample: 347 of its structural elements are not declared in the 2024 file. The 28 absent framing ids are 2024 beam-system members, which come in runs of three consecutive ids; 24 of them name a beam system in their reference list. Beam systems regenerate their members with new ids when they are edited.

End to end, the Structural sample exports 1,281 elements instead of 84, and 1,253 are in the VIM under the same category. On the architectural sample, 260 of the 261 generic models are in Revit's own IFC4 export. The other one carries non-primary design option 1500727 in frame slot +0x2a. Core Interior, the RE1 models and the 255ribeiro projects export unchanged.

Testing

  • tools/check-local.sh (fmt, clippy, rustdoc, workspace tests)
  • cargo +1.85.0 check --profile ci --all-targets
  • product_categories_are_distinct_mapped_and_counted covers the new rows
  • IFC fixtures unchanged

Audit-honesty checklist

  • Status is experimental. The evidence is a local VIM oracle, not a Revit IFC export and not CI.
  • Limits are stated:
    • braces would export as IfcBeam, since the structural type is not decoded;
    • Revit's own PredefinedType for framing is unmeasured;
    • rebar, connections and beam systems have correct ids but are not exported;
    • bodies are bounding boxes.
  • Reproducible probe under examples/

Legal and contribution hygiene

  • Apache-2.0
  • Clean-room: byte observations only. The VIM reader follows the public, MIT-licensed vim-format container layout. BuiltInCategory names come from the public enum. No Autodesk or ODA SDK source, decompiled internals or NDA material. The oracles are not committed.
  • No PII

Breaking changes

None. PRODUCT_RECORD_CATEGORIES and RECOVERED_CATEGORIES grow from 13 to 17 and from 20 to 24 entries.

Related issues

Refs #295. Builds on #317 (RE-35).


Note

Medium Risk
Expands real-project IFC export surface and category/id attribution on structural models; evidence is local-only and geometry remains coarse bounding boxes, but changes are additive with no breaking API.

Overview
RE-36 extends partition element-record recovery to four structural/product categories—structural framing, structural columns, structural foundations, and generic models—using the same RE-21 instance rule and RE-35 enclosing-record ElementIds as walls and doors. They are registered in PRODUCT_RECORD_CATEGORIES and RECOVERED_CATEGORIES (13→17 and 20→24 entries) and export through existing category_map mappings as IfcBeam (.BEAM.), IfcColumn, IfcFooting, and IfcBuildingElementProxy, with bounding-box bodies.

Documentation and honesty gates are updated (CHANGELOG, README, ROADMAP, status/support profile, export diagnostics, new element-records-structural-categories matrix row marked experimental). On Snowdon architectural, element_record_without_element_id is revised to 37 (adding 17 unattributed generic models). A new examples/probe_re36_vim_oracle.rs scores placed-instance records against a VIM export oracle; reports/element-framing/RE-36-structural-categories.md records local measurements. Rebar, connections, and beam systems keep correct ids but are not exported; braces would map to IfcBeam without structural-type decoding.

Reviewed by Cursor Bugbot for commit 2e5003d. Configure here.

…eneric models from element records (RE-36)

Four more BuiltInCategory values decode under the RE-21 instance rule,
with their ElementIds from RE-35's enclosing partition records, and export
as IfcBeam (.BEAM.), IfcColumn (.COLUMN.), IfcFooting and
IfcBuildingElementProxy with bounding-box bodies.

Measured locally on Autodesk's Snowdon Towers 2024 samples (no licence,
not in CI). Against the VIM export of the Structural sample, every
exported id the VIM carries has the record's category there: 914 framing
members, 74 columns, 90 foundations and 91 generic models, none under
another category. The 28 framing ids the VIM lacks are beam-system members
its later (2027) edition regenerated. On the architectural sample 260 of
261 generic models are in Revit's own IFC4 export; the other sits in a
non-primary design option.

examples/probe_re36_vim_oracle.rs parses a VIM file (vim-format, MIT) and
scores every placed-instance element record against one of its documents.
Core Interior, the RE1 models and the 255ribeiro projects export
unchanged.
@cursor

cursor Bot commented Sep 23, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_c781758e-ebaf-4bcf-9b77-b6def32d52af)

@DrunkOnJava
DrunkOnJava merged commit 9cf97d4 into main Sep 23, 2026
23 checks passed
@DrunkOnJava
DrunkOnJava deleted the feat/structural-record-categories branch September 23, 2026 05:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant