Repository navigation
feat(elements): name families that nest others of their category (#324) (RE-42) - #330
Merged
Merged
Conversation
Bugbot couldn't run - usage limit reachedBugbot 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_4299837a-b6d8-41f2-b325-b9ef7549f758) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
RE-38 names an element
Family:Type:ElementIdwhen its type's partition record holds exactly one other named id of the type's category. When the type's family nests other families of that category, the record names those too, and RE-38 left the element unnamed (#324). The family is the one candidate whose own partition record names every other candidate, andpartition_names::resolve_familynow picks it. Every name this adds is Revit's own.Motivation
Closes #324. RE1 Electrical's 12 lighting fixtures had no names. Revit names them
265100-LIGHT-CAN:6":<id>and so on.Changes
src/partition_names.rs:resolve_familykeeps RE-38's single-candidate rule. With several candidates, it returns the one whose own record names all the others, and only when exactly one does. Doc states the sibling-type limit. There is a unit test for the rule, and the RE-38 test now uses two families that do not name each other.tests/element_names.rs: checks RE1 Electrical (12). RE1 Mechanical's pin moves from 36 to 42: 6 "300x150" fittings are now named, all equal to Revit's.examples/probe_re42_nested_families.rs(new).reports/element-framing/RE-42-nested-families.md, the support-matrix row, README, status, CHANGELOG, a reconnaissance addendum, and a cross-reference in RE-38.Measurements
Testing
tools/check-local.shelement_nameson RE1 Electricalcargo +1.85.0 check --profile ci --all-targets,cargo +nightly check --manifest-path fuzz/Cargo.tomlAudit-honesty checklist
Legal and contribution hygiene
Breaking changes
resolve_familynow returns a family for some types that had several candidates and returnedNonebefore. IFC names change for those elements, fromClass-ElementIdto Revit'sFamily:Type:ElementId.Related issues
Closes #324. Follows #329 (RE-41).
Note
Medium Risk
Changes IFC
Name/ObjectTypefor elements that previously had no resolved family (breaking for consumers of those strings), though selection is fail-closed and corpus-gated against Revit exports.Overview
RE-38 already produced Revit-matching
Family:Type:ElementIdIFC names when a type’s partition record listed a single same-category family id. Types whose family nests other families of that category list multiple candidates, sopartition_names::resolve_familyused to returnNoneand those instances keptClass-ElementIdnames (#324).The resolver now keeps the single-candidate path unchanged. With several candidates, it returns the unique id whose own partition record names every other candidate (the nested families). Ambiguous cases still return
None.Impact: newly named instances on corpus models—e.g. RE1 Electrical’s 12 lighting fixtures, six mechanical duct fittings, and many Snowdon elements—now match Revit’s IFC names; the documented cross-model count rises from 4,241 to 4,397 matching names. Integration coverage adds RE1 Electrical and bumps the mechanical name check to 42.
Also adds
probe_re42_nested_families, the RE-42 report, and doc/support-matrix updates.Reviewed by Cursor Bugbot for commit 1192545. Configure here.