Skip to content

feat(elements): rooms take off the round columns their stored solid holds, and a Measure pair for rac_advanced against the public IFC2X3 export (#1354) - #1377

Merged
DrunkOnJava merged 15 commits into
mainfrom
fix/1354-rac-advanced-rooms
Nov 4, 2026
Merged

DrunkOnJava merged 15 commits into
mainfrom
fix/1354-rac-advanced-rooms

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Nov 4, 2026 •

Copy link
Copy Markdown
Owner

Summary

Two changes for #1354 (rac_advanced's rooms against the public IFC2X3 export):

  1. A Measure pair. -f racadv=true fetches Autodesk's rac_advanced_sample_project of 2015 to 2020 and the IFC2X3 export of it in the three.js repository (pinned by sha256 and byte count in research/rac-advanced-export.tsv) as models racadv-2015 to racadv-2020. Both are fetched for the run and never stored or cached (racadv-* is on the score cache's never-cache list). The export has no licence of its own and its terms are not established (RE-330 section 1), so only the run's summary counts are uploaded (tools/ci/scrub-holdout-results.sh), as for BIMcollab's example (Griffin, 2026-10-26; the main session, 2026-11-04).
  2. A reader change. The walk of RE-101 reads the arcs of vertical cylinders that reach the floor (round columns) first, so a room's outline takes them off as voids and notches; where that does not close and the solid has a cylinder, it reads the faces as main did. The resolved span reads them too, but a span with a cylinder closes undirected or not at all.

Motivation

Closes #1354. Why 43 rooms were 0.17% to 1.24% over Revit's area (RE-334 section 1, read from the earlier run 41832628804's kept IFC and the pinned export as plain STEP, which reproduces the scorer's 58 of 107): Revit's export takes every round column off a room as a void (48 of its 116 spaces have voids, each a 34-vertex circle of radius 0.4917 ft), and rvt-rs ignored the cylinder faces. With the circles subtracted, the 43 are within 0.007% of Revit's area. The 6 rooms that kept their record box have columns against their walls, so their loops needed the arcs to close. RE-316 section 4 left it open which reading was right; two Revit exports now say.

Changes

  • research/rac-advanced-export.tsv, tools/ci/fetch-rac-advanced-pair.sh, tools/ci/measure-reference-models.sh, .github/workflows/measure.yml (input racadv, shard racadv, fetch step), tools/ci/scrub-holdout-results.sh and tools/ci/measure-cache.py (racadv-* is counts only and never cached), docs/reference-models.md, docs/maintaining.md, docs/validation-evidence.md.
  • src/research/partition_room_boundaries.rs: wall_edges takes the arcs as a parameter; the walk asks for them and falls back to none; resolved_outline_of_solids asks; span_outline does not use region_boundary for a span with a cylinder (an arc's direction is not read); PLAN_SEGMENTS_MAX (2048) bounds the segments. probes/examples/probe_re316_hostile_solid.rs gains two cylinder cases (13 columns in a room; 512 columns of 1024 chords).
  • reports/element-framing/RE-334-room-round-columns.md; the caveat in RE-316 section 4, docs/rooms.md and docs/status.md updated; changelog.d/fixed/room-round-columns.md.

Testing

No local build or test run (repository rule). cargo fmt --all -- --check, shellcheck of the two measure scripts (the scrub script's existing SC2043 warnings aside), actionlint of measure.yml (its only finding is the existing fetch-corpus line), changelog.py check and api-doc-ids.py pass.

Measured on 5559e8f (Measure, filtered, dispatched from this branch's workflow, the reader against main at a0cf63d; the later commits are documents and merges of main):

  • rac_advanced 2015 to 2020 against the IFC2X3 export, run 41909372124, counts only: area within 0.1% 58 of 107 on main, 107 of 107 with the reader; outline and boundary 58 to 107; rooms: stored solid 85 (42 within 0.1%) and record box 6 (0) on main, stored solid 91 of 91 with the reader. The six saves give the same counts. Vertices within 0.01 ft stay at 47 of 107: the reader draws a circle as 70 chords and Revit's export as 34. Outside the scorer (STEP parse of run 41900428551's kept IFC at f4f3da5, before the fallback and the cap, which change no room whose arcs close): the same number of voids in all 107 spaces on all six saves (48 with voids), the largest area difference 0.0058%.
  • A second exporter, Revit 2018's public IFC4 export of rac_basic (RE-326 section 5), read outside Measure against run 41909414507's kept IFC of the 2015 save: its room 101 has one void; main is 1.710% over its area, the reader 0.628% over with one void, 0.57% larger than Revit's; the other 13 rooms are equal on both sides. No room gets worse. Revit's own GSA Space Areas for room 101 is the geometry with the column taken off.
  • The other exporters: the office, Core Interior, RE1 and the R2025 models (33 models), run 41909377642: every export byte for byte as before and every scorer output equal. Held-out and BIMcollab models (20), run 41909388707, counts only: every export byte for byte as before and every scorer output equal. Samples 2015 to 2027 (58 pairs), run 41909382808: 43 exports as before; rac_advanced on all 13 releases (rooms on their box 6 to 0), Snowdon Towers architectural 2024 (2 of 7 boxed rooms take an outline) and rac_basic 2015 (above) move.
  • So two Revit exporters confirm the voids, the IFC2X3 one of rac_advanced and the IFC4 one of rac_basic, and none disagrees. If a Revit export of such a room disagrees, the standing rule says to leave the voids out.

Not measured: the 2021 to 2027 saves of rac_advanced and Snowdon's two rooms against any export (the Snowdon sample's Revit IFC4 export holds no IfcSpace); the 4.95 ft² still over in rac_basic room 101's outer ring (not changed here); Revit's own areas for the rac_advanced rooms (its export carries none); a concave cylinder (the arc direction is not read; the walk does not need it and a span with a cylinder is never resolved to a boundary); a short column, and a prism room's NetVolume with columns (written for Revit 2024 and 2025 only; the prism check does not read a cylinder's height and no Revit NetVolume of such a room was compared).

Audit-honesty checklist

  • README / docs reflect the state after this PR; the old caveats are removed in docs/rooms.md, docs/status.md and RE-316 section 4 (CHANGELOG.md's historic entries stay).
  • A user-visible change has its entry as a fragment under changelog.d/fixed/.
  • New limitations are in the PR body and RE-334 section 5.
  • No emojis, no private paths.

Breaking changes

None known. Exports of rooms with round columns change (the outline has voids, and a room's schedule area and a prism room's NetVolume follow it); 96 other exports measured do not (33 reference models, 20 held-out and BIMcollab models, 43 samples).

Related issues

Closes #1354.

…3 export, fetched for the run and never cached (#1354)

Refs #1354. -f racadv=true fetches Autodesk's rac_advanced_sample_project of 2015 to 2020 and the IFC2X3 export of it in the three.js repository (pinned by sha256 and byte count in research/rac-advanced-export.tsv; no licence of its own, so never stored or cached) as models racadv-2015 to racadv-2020, for space_profiles_vs_ifc and the rest of the suite. The score cache never holds racadv-*. Its results are uploaded in full, as the Autodesk samples' are.
…ed solid holds, as arcs (#1354)

Refs #1354. The walk of RE-101 read only planar wall faces, so a vertical cylinder (a round column) in a room was ignored: 43 of rac_advanced's 85 walked rooms were 0.17% to 1.24% over the area of the public IFC2X3 export, which takes each column off as a hole, and 6 rooms with columns against their walls kept the record box. The walk and the resolved span now read the arcs of vertical cylinders that reach the floor (the chords RE-316 already read for its probes, within 0.0005 ft), bounded to 4096 plan segments. Not yet measured on this head.
…lid holds, with the runs against the IFC2X3 export and the 33 other models (#1354)
…n as a void, and its own room area takes it off (#1354)
@DrunkOnJava DrunkOnJava added the ready-when-green Draft whose code is complete: marked ready for review once its fast CI passes label Nov 4, 2026
@DrunkOnJava
DrunkOnJava marked this pull request as ready for review November 4, 2026 20:30
@DrunkOnJava DrunkOnJava removed the ready-when-green Draft whose code is complete: marked ready for review once its fast CI passes label Nov 4, 2026
… not close, a span with a cylinder is never resolved to a boundary, and racadv-* leaves the runner as counts (#1354)

Refs #1354. The walk of RE-101 reads the arcs of round columns first and, where that does not close and the solid has a cylinder, as main read it, so a room whose walls closed before still does. A span with a cylinder closes undirected or not at all, since an arc's direction is not read. PLAN_SEGMENTS_MAX is 2,048, with two cylinder cases in probe_re316_hostile_solid. racadv-* is scrubbed to counts like bimcollab-* (the export carries no licence). RE-334 states the fallback, the direction, the span, the prism check and the NetVolume that was not compared. Not yet measured on this head.
@DrunkOnJava DrunkOnJava added ready-when-green Draft whose code is complete: marked ready for review once its fast CI passes and removed ready-when-green Draft whose code is complete: marked ready for review once its fast CI passes labels Nov 4, 2026
@DrunkOnJava
DrunkOnJava enabled auto-merge (squash) November 4, 2026 21:22
@DrunkOnJava
DrunkOnJava merged commit 9445191 into main Nov 4, 2026
38 checks passed
@DrunkOnJava
DrunkOnJava deleted the fix/1354-rac-advanced-rooms branch November 4, 2026 21:30
DrunkOnJava added a commit that referenced this pull request Nov 5, 2026
…dumps and Jev scores the diff (#1334) (#1419)

## Summary

The advisory semantic merge check of #1334. Measure diffs the two sides'
MCP dumps for each openly licensed model, and a `workflow_run` workflow
gives the diff to Jev `jev-1.13.0` beside the pull request's own `##
Summary` and `## Testing` and asks whether the export moves in a way
they do not state specifically (Griffin, 2026-11-05: a described,
intended change passes, an unexplained move fails; the main session,
2026-11-05: a move that only a general description such as "improves how
walls are exported" covers fails too). The verdict is the check run
`semantic diff (advisory)` on the commit Measure measured: not in the
ruleset, no pull request comment, and a `fail` is a red check. Only a
Measure run of every open model with a base on main writes it, it is
written on the commit Measure measured and no other, and it cannot be a
pass unless all 34 open models are compared in full and a
same-repository pull request has that commit as its head.

## Motivation

Measure is the byte-level oracle. A pull request that moves meaning
should say so, specifically, before it is armed, not only show that
bytes moved. The agent that makes a change also writes its Summary, so a
sweeping Summary must not cover a change. Refs #1334.

## Changes

- `tools/re/semantic_diff.py`: a pure function of two dumps. Elements
added, removed and changed with the value before and after; byte offsets
inside `provenance` dropped; order ignored; values compared to the
dump's six decimals; an empty object or list the same as no field;
identical changes collapsed by the whole (path, before, after) triple.
Its `measure` mode is what the compare job runs: it fails the job on a
dump in a model that is restricted or on neither list, and records in
the manifest the open models no diff covers (`OPEN_MODEL_NAMES`, 34),
each skipped model with its own reason, the groups dropped for size, and
whether the run was asked for every open model (`--requested-all`). The
measured commit and the base are the ones the compare job passes from
the plan job's resolved refs (`--head-sha`, `--base-sha`); the
`commit.txt` of a result folder is written by a shard job that runs the
measured code and is read only when none is passed.
- `tools/re/test_semantic_diff.py` and `tools/ci/test_jev_check.py`:
failure-first tests of pure helpers, run in the PII guard job. The diff:
0.35 vs 0.3500001, a reorder with moved offsets, a bulk collapse that
hides a different value, an uncovered model. The verdict logic: a model
with no dump, a diff that failed, a dropped group, an unscored chunk or
partial coverage never reads as a pass; an answer whose probabilities do
not add up is refused; a chunk of non-ASCII text is never sent over the
16,000-character cap; a head commit that is not a 40-character SHA, a
manifest with a non-string model, HTML and invisible characters in the
pull request's text, and control characters in printed text. Each was
checked to fail under the mutation it guards against.
- `.github/workflows/measure.yml`: the compare job checks out the
script, runs `measure` when there is a base, tells it whether the run
was dispatched with no `models` filter and the office and Revit 2025
models on, and uploads `semantic-diff`. The documented command is `-f
base=main -f nordic=true -f r2025=true` with no `models` filter.
- `tools/ci/jev_check.py`: merges findings across models, chunks them
(at most 8 findings, 16,000 characters as sent), reads the
same-repository pull request whose head is the measured commit through
the API, takes its `## Summary` and `## Testing` (HTML element tags and
invisible characters removed, each cut at 2,500 characters as sent, all
of it shown in the check's summary; text in angle brackets that is not
an HTML element, such as `<set>.<property>`, stays), and asks Jev blind
(labels A and B randomised per chunk; no model name, pull request
number, title or branch in the state). Per finding Jev chooses: stated
specifically / follows from a specific change they state / covered only
by a general description / unstated / only rounding, a reordering or a
spelling; "general" plus "unstated" is the finding's score, and the
probabilities must add up to 1. A finding at 0.85 or more is a fail in a
chunk rated 1.5 or more and a warn in one rated 1.0 or more. NOT
MEASURED, never a pass, for no key, no same-repository pull request
whose head is the measured commit (a fork's included, and an empty diff
does not excuse it: the lookup is first), a check asked for on a commit
other than the measured one (both commits in the title), a base that is
missing or could not be checked, a pull request with no `## Summary`
where the diff has findings, HTTP 402, a refused key, another model's
reply, a time-out, an error (named by its type), no model compared, any
open model not compared in full, a dropped group or a missing count,
sampled property sets that one of a model's dumps alone holds too often
(none held by both while either holds any, or more than a tenth of
them), or an unscored chunk. A run whose base is not main or an ancestor
of main writes no check, and names the base. The Jev call does not
follow a redirect. An empty diff passes without a call and needs no
Summary, but only on a complete run.
- `.github/workflows/semantic-check.yml`: `workflow_run` on Measure
(environment `jev`, main only), `workflow_dispatch` with a run id, and a
keyless run on a pull request that changes the check. It scores only a
Measure run whose event is `workflow_dispatch` and whose head repository
is this repository, from `measure.yml` at that path; any other run posts
nothing, with a notice. It writes the check on the commit the artifact
names as measured, not on a pull request's live head. actionlint reports
nothing on it and zizmor 1.32.0 reports nothing on it, `measure.yml` and
`ci.yml` (the one `dangerous-triggers` finding, on `workflow_run`, is
ignored inline with its reason).
- `docs/maintaining.md` (where to find the verdict: it is on the
measured commit, not necessarily the head, which the pull request page
does not show, so look it up with `gh api
repos/<repo>/commits/<sha>/check-runs?check_name=...`; a later commit
does not clear a fail, only a new score of the same pull request does; a
filtered Measure run writes no verdict, so a pull request that changes
output needs its final unfiltered run; the Summary must state each
change specifically: which classes, which property or geometry, how many
where measured; a fail is fixed by changing the code or by stating the
change in the Summary; a warn is answered in the body; the complete
command; what a pass means: the dumps agree, not that the exports are
identical, since the dump samples five elements per entity; what is
sent, including element names and values that can hold an ElementId), a
changelog fragment.

## Testing

No local build (the lane runs no cargo); the tests above are the
pure-helper exception and run in CI's PII guard job. End to end on real
dumps:

- [x] N/A for `tools/check-local.sh`: no Rust changed.
- [x] Verified end to end on real Measure runs: see "Output samples".
The keyed path (main's `workflow_run` job with the secret) is not yet
exercised.

## Audit-honesty checklist

- The keyed path cannot run before the workflow is on main:
`environment: jev` takes only main, and a `workflow_run` workflow runs
from the default branch. After the merge: `gh workflow run
semantic-check.yml --ref main -f run_id=<a complete Measure run with a
base>`.
- The keyless path is exercised by this pull request's own run of the
workflow, and it can only say NOT MEASURED: it writes on the pull
request's head, which is never the commit Measure measured. At c36b71f
(before the delta review) it did so with the wrong reason: Measure run
41987903774 (dispatched from this branch for #1425's head c8e55f5
against main 182ed21, `-f nordic=true -f r2025=true -f
scorers=mcp_answers_vs_ifc`, no `models` filter) compared all 34 open
models (0 skipped, 0 uncovered, `requested_all` true; findings only in
the two office files, 7 each), and this workflow's run 41987854258
(attempt 2) wrote check run 127117767677 on c36b71f through
`GITHUB_TOKEN` saying only "no Jev key", a check on a commit Measure had
not measured. At b4d1932 such a check says "this check is for <the
head>, but Measure measured <the other commit>" in its title (local
scenario below; the CI proof is Measure run 41993282068 on #1425's head
722244e against main a4044dc, and this workflow's pull-request run
after it: not yet measured on this head). Measure's own pull-request run
41987854320 covered 6 of 34 models and its compare step says "the
semantic check writes no check run (this run was not asked for every
open model)", the filtered path in a real run. An earlier pass of the
keyless path (run 41966963563, attempt 2, on fd90cdc: no semantic
difference in 6 models) predates the coverage rule and the commit check.
- A pass means the dumps agree, not that the exports are identical: the
dump samples five elements per entity, and a mesh vertex or a profile
point is not in it.
- The thresholds and the wording of the per-finding question were set on
the in-sample cases below, so those cases are in-sample for them. The
held-out round is the second table. Jev's answers move by about 0.02
between two calls with the same request (#1412's own Summary passes at
0.84 and fails at 0.86 on byte-identical requests, against a gate of
0.85), so a verdict within 0.05 of the gate is not stable.
- B3 (a fork's run) and the redirect behaviour are tested by reading the
code and the unit helpers, not by a fork's run: no fork pull request was
opened.

## Breaking changes

None.

## Output samples

Everything below was scored with `tools/ci/jev_check.py` and
`tools/re/semantic_diff.py` as committed at 49d5378, and the
delta-review block below as committed at b4d1932 (which changes who may
write a check, the gaps, and the stripping of HTML and invisible
characters in the pull request's text; no prompt, threshold or
chunking), and the key from the Keychain on this Mac, from the
`semantic-diff` and `measure-*` artifacts of the Measure runs named.
Nothing was scored with a threshold or a prompt other than the committed
ones.

**Ground truth is `ifc.sha256` per model**, not a pull request's title.
Of 13 pull requests in the in-sample set (Core Interior, Einhoven, RE1
and the Revit 2025 models in every run; 34 models with the BIM4LCA
office where `nordic` was on, 30 for #1402 and #1403 and 6 for #1398),
the IFC differs on the two office files for #1388, #1400, #1401 and
#1405 and on no model measured for the other nine. The semantic diff has
findings on exactly those two models in each of those four runs, and
none on any model whose IFC is identical, except the dump-only changes
of #1373, #1379 and #1412. The documented command (no `models` filter)
is what finds them: the earlier documented command, which filtered to
Core Interior, Einhoven and RE1, reads "pass" on all four.

**In-sample: the 7 pull requests whose diff is not empty** (runs
41972569847 #1388, 41972650013 #1400, 41972664107 #1401, 41972583508
#1405, 41972597118 #1373, 41972610208 #1379, 41972636527 #1412; each 34
models). "Own" is the pull request's real Summary and Testing.
"Sweeping" is a one-line Summary that names an area and no kind of
change ("Improves how walls and floors are exported." for #1388,
"Improves how openings are written in the export." #1400, "Improves how
walls are drawn in the export." #1401, "Improves how floors and walls
are exported." #1405, "Improves how rooms, profiles and pipes are
exported." #1373, "Improves how roofs are exported." #1379, "Improves
the MCP server's answers." #1412), alone and beside the pull request's
real Testing. "Wrong" is another pull request's full body: #1329 (a
memory change that states the output does not change) and one other. The
number in parentheses is the highest probability that Jev gave a finding
as not stated specifically.

| Pull request | Findings | Own | Sweeping alone | Sweeping + its
Testing | Wrong: #1329 | Wrong: other |
| --- | --- | --- | --- | --- | --- | --- |
| #1388 | 7 | pass (0.31) | fail (0.99) | pass (0.74) | fail (0.99) |
#1412: fail (0.95) |
| #1400 | 14 | **fail (0.94)** | fail (0.99) | fail (0.98) | fail (0.98)
| #1373: fail (1.00) |
| #1401 | 12 | pass (0.63) | fail (1.00) | pass (0.77) | fail (0.96) |
#1379: fail (1.00) |
| #1405 | 2 | pass (0.51) | warn (0.99) | warn (0.90) | warn (0.96) |
#1379: **pass (0.78)** |
| #1373 | 88 | pass (0.63) | fail (1.00) | fail (0.99) | warn (0.97) |
#1400: fail (1.00) |
| #1379 | 94 | pass (0.24) | fail (0.99) | warn (0.90) | fail (0.96) |
#1401: fail (1.00) |
| #1412 | 23 | pass (0.84) | fail (1.00) | fail (0.89) | fail (0.99) |
#1388: fail (1.00) |

- **No sweeping Summary alone passes (0 of 7): 6 fail, 1 warns.** Beside
the pull request's own Testing two pass (#1388 and #1401), because their
Testing states the figures: that is the rule working, since a measured
figure in Testing counts as stated.
- **False positives: 1 of 22 expected passes, a fail.** The 22 are the 7
own Summaries, 6 jitter controls, 6 reordered controls and 3 empty-diff
pull requests on complete runs (#1329, #1377, #1382: no finding on any
model, IFC identical, each a pass without a call to Jev). #1402 and
#1403 ran without the office, so under the new rule they write no check
and are not counted. #1400 is a diff of 14 counters of the diagnostics,
and the figure its Summary and Testing leave unstated is
`parameter_value_count` +188 (office as built) and +174 (permit); its
Motivation, which Jev is not given, gives 182. #1412's own Summary sits
at the gate: the same request scored 0.84 (pass) at 4e81a95, 0.86
(fail) in one rescoring on this head's code and 0.84 (pass) in the table
above, so it is a verdict the gate cannot hold; it could as well be
counted a second false positive.
- **False negatives: 1 of 21 expected non-passes** (7 sweeping alone, 7
with #1329's body, 7 with another's): #1405's whole diff is
`total_entities` +8 on each office file, which a roofs Summary does not
state (0.78, below the gate).
- **Controls, complete** (all 34 models on both sides, one model
changed; built from the dumps of run 41972569847): six jitter controls
pass, a move of 1e-6 in every measurement of the sampled elements, the
rooms' areas and the levels' elevations in Core Interior, RE1
architecture and mechanical, Einhoven, the office as built and a Revit
2025 model, scored beside #1329's body: highest probability 0.73 to
0.79, highest chunk rating 0.6 to 0.7, below the 1.0 rating gate; 412
findings in 65 chunks on the office. Six reordered controls (every row,
set and room in another order, every byte offset shifted) are empty
diffs.
- **Coverage, on #1401's stored diff** (run 41972664107, own Summary),
changing only the manifest: complete, **pass**; one model with no dump
on the head side, **NOT MEASURED** naming it; one model whose diff
failed, **NOT MEASURED** with that reason; a dropped group, **NOT
MEASURED**; the same missing model with a run not asked for every open
model, **no check run**; a manifest with a non-string model, an error
and no check run.
- **Unchanged by the review fixes:** 34 of 35 verdicts of the in-sample
matrix are as scored at 4e81a95 (the one that moved is #1373 with
#1329's body, fail to warn; both are non-passes), and #1401 and #1405
(the two the review asked for, runs 41972664107 and 41972583508) are
unchanged in all five bodies. 18 of the 35 requests are byte-identical
to the earlier scoring; the other 17 carry a Summary or Testing that is
now cut by its length as sent (a newline or a quote in the text counts
two, so a section over the cap is cut about 20 characters earlier),
which is the review's cap fix and not a change of method.

**Delta review (b4d1932).** Run on stored complete runs, with the key
from the Keychain and real GitHub lookups, nothing posted:

- Run 41972569847 (#1388's merge commit, base 240c7d7): the pull
request is found through the API from the measured commit, the base is
on main, Jev is asked with #1388's real Summary and Testing: **pass (7
findings in 34 models)**, as before. Run 41972583508 (#1405's merge
commit): **pass (2 findings)**, as before. Run 41972664107 (#1401's head
2a35ede, which has since moved): NOT MEASURED, "no pull request of this
repository has this commit as its head", the head-moved case in a real
run; scored offline with #1401's real body the verdict is **pass**, and
all five of its bodies give the verdicts of the table above (pass, fail,
pass, fail, fail). #1388's five bodies and #1405's five are the same
verdicts as the table, except #1405 with #1329's body, warn to fail (a
non-pass either way, at a rating of 1.5).
- Run 41987903774 (PR #1425's head c8e55f5 when measured): its head has
since moved to 722244e, so the real-lookup scenario reads NOT MEASURED,
"no pull request ... has this commit as its head". Asked to write on
another commit (c36b71f), the same run reads NOT MEASURED with "this
check is for c36b71f, but Measure measured c8e55f5". An empty diff
on a merged pull request's commit (run 41980023307, #1358) is a pass;
the same empty diff with a commit no pull request has is NOT MEASURED; a
base that is the pull request's own head writes no check and names the
base.
- **Property sets held by one dump only** (`details_one_side`) are a gap
per model only when none is held by both while either holds any, or when
more than a tenth of all of them are held by one dump only (exactly a
tenth is not a gap; main session, 2026-11-05). The dump samples the five
lowest ElementIds of each entity, so a change that adds or removes
elements of an entity moves the sample and a few are held by one dump
only: that is not a defect, and the literal rule (any non-zero count)
would have turned #1412's pass into NOT MEASURED. The defect it guards
against is a head that lost its details. The check's summary says how
many are held by one dump only, gap or not. On run 41972636527 (#1412, 1
of 115 sampled elements held by one dump only in each office file, no
gap), scored offline with #1412's body three times: pass (0.84), fail
(0.85), pass (0.83), all with no gap and the same chunk (a finding at
the 0.85 gate, in a chunk rated 3.6), so its own Summary is a pass
again, at the gate, and not a stable one. No other stored complete run
has a non-zero count.

**Held-out, thresholds and wording unchanged since they were set
above.** Ten merged pull requests that were not used to set them, run
with the same 34 models (`nordic` and `r2025` on):

- #1337, #1352, #1356, #1372, #1341 and #1344 (Measure runs 41973688732,
41973701739, 41973714367, 41973727101, 41973740400, 41973754042): the
IFC is identical on all 34 models and the dumps agree, so each has an
empty diff and passes without a call to Jev, with its own Summary, a
sweeping one, #1329's or another's alike. **They test the empty-diff
path and nothing else**: none of their changes lands on an open model.
- #1350, #1358, #1364 and #1370 (provenance and diagnostics additions;
the IFC is identical on all 34 models in each, so these are dump-only
changes), Measure runs 41980008692, 41980023307, 41980037727 and
41980053223, scored with the same four bodies per pull request (own
Summary and Testing, a sweeping one-liner written before the runs
finished, that line beside the real Testing, #1329's body, and another
pull request's body). Scored first with `jev_check.py` as it was at
4e81a95 and again with the code of this head; nothing was changed after
seeing a result, and the 20 verdicts are the same in both.

| Pull request (run) | Findings | Own | Sweeping alone | Sweeping + its
Testing | Wrong: #1329 | Wrong: other |
| --- | --- | --- | --- | --- | --- | --- |
| #1350 (41980008692) | 1034 in 142 chunks | **warn** (0.86, one chunk,
rated 1.13) | fail (1.00) | fail (0.88) | fail (0.99) | #1358: **pass
(0.84)** |
| #1358 (41980023307) | 0 | pass, empty diff | pass, empty diff | pass,
empty diff | pass, empty diff | pass, empty diff |
| #1364 (41980037727) | 159 in 37 chunks | pass (0.14) | fail (1.00) |
pass (0.60) | fail (0.97) | #1370: fail (0.92) |
| #1370 (41980053223) | 98 in 16 chunks | **warn** (0.90, one chunk,
rated 1.33) | fail (1.00) | fail (0.95) | fail (0.97) | #1350: **pass
(0.21)** |

The sweeping lines were "Improves what the export records about
elements." (#1350), "Improves the diagnostics of the export." (#1358),
"Improves what the export records about bodies." (#1364) and "Improves
what the export records about profiles and stairs." (#1370).

- **The held-out result is weaker than the in-sample one.** Real
Summaries: 1 of 3 non-empty pull requests passes, 2 warn and none fail.
Sweeping alone: 0 of 3 pass (all fail). #1329's body: 0 of 3 pass.
Another pull request's body: 2 of 3 pass. With the empty diff counted,
false positives are 2 warns (no fail) of 4 expected passes, and false
negatives 2 of 9 expected non-passes.
- **Why the two warns.** #1350 added fields to the dump's `summary.file`
block (`layout_release`, `omitted_entries`, `partition_count`), which
its Summary and Testing do not name: one chunk of 0.86 at a rating of
1.13, where a warn needs 0.85 and 1.0. #1370's warn is one chunk of
`value_sources` parts of Core Interior's shading devices at 0.90, rated
1.33; a fail needs 1.5. Both are near their gates.
- **The two cross-body passes are neighbours, not strangers.** #1350
(the provenance of every decoded element), #1358 (why an element was
left out) and #1370 (value sources for profiles, stair runs and
landings) all add provenance and diagnostics, so another's Summary
covers part of the diff. They are counted as false negatives as defined.
- **Run-to-run movement.** Jev's answers move by about 0.02 between two
calls with the same request, and by more in the maximum of very many
findings: with #1358's body on #1350 (1,034 findings) the highest scored
0.83, 0.97 and 0.84 in three scorings, only the middle one on a
different grouping of the chunks (since reverted: a chunk is packed at
full context). A verdict near a gate (0.85) is not stable.
- **What it says about the thresholds.** On provenance and diagnostics
additions Jev's probabilities for a change the pull request states sit
near 0.9 where in-sample they sat at 0.2 to 0.8, so the 0.85 gate is
close to the edge for real Summaries. A recalibration follow-up is
warranted.

#1314, #1316 and #1328 cannot be calibrated: their parents predate the
server crate (71c0677), so Measure builds no `rvt-rs-mcp` there.

## Related issues

Refs #1334
DrunkOnJava added a commit that referenced this pull request Nov 5, 2026
…s' arrangement, and counts only from the three.js export (#1261, #1194) (RE-333)

Code:
- native_area_regions: a circuit is refused once its edges pass
  MAX_CIRCUIT_SIDES or its lines' offset parts pass MAX_CIRCUIT_OFFSET_PARTS,
  before the edges are built or cloned; a circuit side whose line has no u32
  ElementId refuses the Area.
- partition_area_records: chain_entries uses checked_add; the dropped chain
  records are counted by ElementId and the warning says an area boundary line
  among them is not accounted; byte_range includes the entry block that was
  skipped; where the topology and the lines both give a region and they are
  not the same one (net area to 1e-6, the same corners within 1e-4 ft) the
  Area has no body and says area_regions_disagree.
- An Area drawn from the topology has BodySource and ProfileSource
  native_area_plan_topology, with its own body_readers row; the schedule and
  the plan-profile reader accept it.
- tests/value_sources_offsets.rs: the plan records are read with
  NATIVE_RELEASES, and the new body source has its COVERAGE row; the comment
  at MIN_READERS says no gate model pins area_boundary_lines and area_point.

Docs: the per-Area data of the three.js IFC2X3 export leaves RE-333 (counts
only, #1377); six plan-topology reasons, not five; the decision of 2026-11-05
(ship, labelled, with a gate) in RE-333 section 9, the fragments and the
docs; the office's vertex wording made exact.
DrunkOnJava added a commit that referenced this pull request Nov 5, 2026
#1261, #1194) (#1428)

## Summary

This reopens #1371 by puzzbobb on a branch of this repository, as
puzzbobb agreed on that pull request ("it can be reopened on a branch
here"). puzzbobb's two commits are cherry-picked in order and keep them
as author (`fec15008`, `c4889e7f`, signed by the committer, as
`main-protection` requires); the maintainer's five commits that followed
on #1371's branch come after them, with the archived head
`refs/archive/2026-11-04/pr1371-area-plan-topology` (`e5b1c8be`) as the
source. Their reader is the substance: an Area that the arrangement of
its lines leaves without a region takes the loop of Revit's own plan
topology, checked against the area Revit saves for it, and the Areas of
Revit 2025 to 2027 are read.

It supersedes the wall-line rule of #1367, which was worked out from the
same IFC2X3 export it is scored against; #1367 becomes research notes
only once this lands (Griffin, 2026-11-04).

## The gate (Griffin, 2026-11-05, "Ship, labelled", then "Same-project
gate")

The Areas of Revit 2025 to 2027 and the 108 Area spaces of the recorded
Autodesk 2024 Snowdon Towers samples are written by default. They are
**not measured against any Revit export**; RE-333 section 9, the
changelog fragments and `docs/rooms.md`, `status.md`, `evidence.md` and
`supported-profile.md` say so and name the evidence: the drawn loop
equals the area Revit saves in the file for it and holds the Area's
point, and on 2025 to 2027 the same project's 2024 save gives the same
Areas.

**The marker (Griffin, 2026-11-05, "Mark 2025 to 2027 in the file").**
His earlier "their own outline source value" had two readings, and the
docs-only one was mine; he wants the file to show it. Areas read from
Revit 2025, 2026 and 2027 now get `SpaceOutlineSource`
`area_plan_topology_unchecked`, wherever the marker shows: the IFC
property, `list_rooms` (`space_outline_source`), the schedule CSV's
outline source column, and the MCP field's description (the watcher
syncs the contract). Snowdon Towers 2024 and every other 2024 file keep
`area_plan_topology`, because they share a release and a code path with
the office and a release is not split; 2015 to 2023 keep it too (they
are the Areas with the IFC2X3 check). It is decided by release in one
place, `partition_area_records::area_release_unchecked`
(`AREA_UNCHECKED_RELEASES`, 2025 to 2027), which sets a field of the
decoded Area that `export_content` reads. `BodySource` and
`exported.body_sources` do not split: the body is read by the same code,
and the marker says how far it is checked, not how it was read.
`tools/re/areas_across_saves.py` expects exactly that per release: a
2025 Area reading `area_plan_topology` and a 2024 Area reading the
unchecked value are failures. Consumers checked: `export_content`
(marker, `contain_in_spaces`), `schedule_csv` and
`element_record_plan_profiles` (keyed on `ProfileSource`, which does not
split), `element_provenance` and the COVERAGE rows (keyed on
`BodySource`, unchanged), `rvt-mcp` (passes the text through;
descriptions updated), `space_profiles_vs_ifc.py` (knows the value).
`#1439`'s `SpaceKind` scorer has its own list of Area values, and that
lane adds the new one.

**The first gate tested nothing, and I recommended it.** It was "no Area
written that Revit's export lacks (`only in rvt-rs` 0) on every held-out
Revit 2025 to 2027 model with Areas". None of the seven held-out Revit
2025 to 2027 models writes an Area, and all seven exports are
byte-identical to main's (Measure run 42003913780 on `bcb02107`), so
`only in rvt-rs` 0 could not have failed. I did not count what it would
count before recommending it.

**The gate now (Griffin's "Same-project gate"): this lands only if
rac_advanced's 25 Areas on its 2025, 2026 and 2027 saves equal its 2024
save's, Area by Area.** The fields are GlobalId, number, name, storey,
outline source (the value each release gets, above), body area (1e-6
relative), top surface (the symmetric difference of the two top
surfaces, 1e-6 relative), height (1e-5 ft) and lowest vertex (1e-5 ft);
Griffin's list is the first six and the rest are a floor raised, so that
a translation, a rotation, a shear that keeps the area, a raised base or
another outline source is a difference. `tools/re/areas_across_saves.py`
compares them. `tools/ci/measure-reference-models.sh` runs it on the
head side of any Measure run of the samples that holds the four
rac_advanced samples (whatever `sample_years` says, as long as it
includes 2024 to 2027), once every export is done and before any
sample's IFC is deleted; with fewer than the four it checks nothing and
prints a notice. The job "The Areas agree across rac_advanced's saves"
in `measure.yml` turns the run red unless the output ends `exit 0` and
has the scorer's `passed` line. It fails on a missing or unreadable
save, on other than 25 Areas or other than 25 Areas with a body on any
save (so 26 fails the same way the workflow's grep does), on an Area
with no storey, and on any difference, missing or extra Area; a pass on
nothing is impossible. **Measure is not a required check, so "blocks
landing" means by the landing rule: the result is read before merging.**
It prints counts by field and the number of Areas compared on each save,
nothing else.

**What the first two passes got wrong, found by the second review.**
Runs 42008539696 and 42010805118 read "storey 25 equal" on `None` equal
to `None`: the first version of the scorer read the storey with
`get_container`, and rvt-rs writes a space under its storey with
`IfcRelAggregates`, so the storey was never compared; and it pinned 25
Areas but not 25 bodies, so all four saves losing their bodies stayed
green. Both are fixed (`get_aggregate`, a missing storey, other than 25
bodies and a missing body are failures). The real storeys of the four
saves are `01 - Entry Level` (9), `02 - Floor` (9) and `03 - Floor` (7)
with 0 differences, so the fix cannot turn a correct head red.

**The proof, run through `read_areas` on written IFC and not through
`compare()` on dictionaries.** The reviewer's generator (IfcOpenShell)
writes the four saves, each Area an `IfcSpace` aggregated under an
`IfcBuildingStorey` with its `SpaceOutlineSource` and an extruded body,
and the fixed scorer reads them as it reads an export, then the
workflow's own check reads its output file. 23 cases, 0 wrong. Green:
the control (25 Areas, 25 with a body, every field equal) and a height
5e-6 ft off (within the tolerance). Red: (1) no body on any save; (2)
one body on every save; (3) later saves that lose their bodies; (4) one
Area moved to another storey; (5) storeys renamed on a later save; (6)
no storey on any save; (7) every body of a later save moved 100 ft; (8)
every body turned a quarter turn; (9) one body sheared to the same area;
(10) the base of every body raised 5 ft; (11) a different outline source
on a later save; (11b) one 2025 Area reading `area_plan_topology`; (11c)
one 2024 Area reading `area_plan_topology_unchecked`; (11d) every later
Area reading `area_plan_topology`, the release rule not applied; (11e) a
lines value on 2027; (12) 26 Areas on every save; (13) 24 on every save;
(14) one Area missing from the last save; (15) a save missing; (16) a
height 2e-4 ft off; (17) a body area 1e-4 relative off. The harness is
in the lane's scratch directory (it needs IfcOpenShell to write files),
not in the repository.

**Tried on real data.** Run 42008535484, main's exports of the four
saves (this branch's scorer and workflow, main's binaries at `ce0b2398`,
no #1428): 2024 has 25 Areas, 16 with a body, and 2025, 2026 and 2027
have 0, so each later save fails and the job turned red. Run 42008539696
and run 42010805118 (the pushed head `401f5244`, finished green): 25
Areas on each of the four saves, the gate passed, and the 58 sample
exports' hashes are identical to run 42003913780's (I read the second
run's myself). Both ran the scorer before the fix above, so their
"storey equal" counts were `None` against `None`; the final run below is
the first with the fixed scorer on real files.

**What it cannot catch:** an error that the 2024 read shares with the
later reads (the same wrong region, number, name or height on all four
saves), and an error in how the saves are exported that is the same in
all of them. It compares rvt-rs with itself, on one project of 25 Areas.

## The 2021 save does not move (a measured residual)

Autodesk's `rac_advanced` 2021 save keeps its 25 Areas as
`area_without_proven_body` (22 `boundary_lines_not_readable`, 3
`named_lines_not_in_scheme_and_level`), as on main, although RE-333
section 4 says the topology has a region for all 25 on it. From the
code: the save holds both states of the model (RE-324 section 4), so 16
area boundary lines have two disagreeing copies; `group_arrangement`
returns `Group::Unreadable` for a group that holds one, and `locate`
returns that before the plan topology is asked; `draw_area` refuses the
3 Areas that name such a line. That order is the refusal about safety
that the review of #1371 asked for (no fallback to the topology after
conflicting copies, stray heights or a design option), so it is not
changed here. Measured (probe run 42008543772): the topology's 25
regions on the 2021 save equal the 2022 save's and the 2023 save's, Area
by Area, in vertex count, holes, arcs and area, so its current native
copy holds the later state; no Revit export of that state exists. It
gets its own issue.

## Motivation

#1261: BIM Whale's 2021 Areas were not written, and on Autodesk's
`rac_advanced` main writes 16 of the 25 Areas (the 9 it leaves out are
the ones the plan topology draws; #1367's "18 of the 25 drawn" is not on
main). #1194: Areas were read on Revit 2015 to 2024 only. RE-333 has the
measurements and the reasons.

## Changes

- **puzzbobb's reader** (`fec15008`, `c4889e7f`):
`src/research/native_area_regions.rs` (the plan topology's loops,
offsets, holes and checks) and the chain-entry count that lets Revit
2025 to 2027 records be read (`partition_area_records.rs`).
- **The maintainer's commits on #1371's branch, cherry-picked**: the
joins cross-check and RE-333 measurements, the vertex where a third line
meets, `SpaceOutlineSource` `area_plan_topology`, the warning for
dropped chain records only where an Area could be lost, arcs written as
arcs (an `IfcIndexedPolyCurve`), the Snowdon Towers 2025 figures removed
(below), `tools/re/space_profiles_vs_ifc.py` and the MCP tool
descriptions for the new value. The archive's generated contract commit
(`e5b1c8be`) is not carried: `docs/mcp-tools.json` and `.md` are never
hand-edited, and `rvt-mcp/src/schema.rs` and `server.rs` gain the new
`space_outline_source` value, so CI's `tool_contract_is_committed` needs
the watcher's contract sync before the full CI is green.
- **This branch's own commit** (`94cd0fd7`), the reconciliation with
what landed on main since the merge base (`fdff7018`), whose conflicts
git reported in `src/reader.rs`,
`src/research/partition_area_records.rs`, `docs/status.md`,
`docs/export-diagnostics.md` and `docs/format-reconnaissance.md`:
- **Value sources (#1368).** #1403 gave Areas `area_boundary_lines` and
`area_point`, noted for the lines' frames and the partition's point. An
Area drawn from the plan topology was not drawn from either, so it no
longer carries them; it carries `area_plan_topology` (rule `native`,
`parts`): the Area's own `RoomElem`, the `LevelRoomPlan` that holds its
circuit and the `CurveElem` of each line that bounds it, each at its
place in its partition (`native_area_regions.rs` `record_place`, kept
only while the handle records value sources, so the flag-off path
allocates nothing; `partition_area_records.rs` `note_topology_source`).
`tests/value_sources_offsets.rs` has the reader in `COVERAGE`, reads
each part's id at its offset, and reads the records again from their
ElementIds (`check_topology_areas`): the Area's record names a circuit
and a point, exactly one part is the plan whose topology holds that
circuit and the Area, and the other parts are the lines of that circuit
and of the circuits it encloses, all of them and no others. The office's
`MIN_READERS` pin `area_plan_topology`; `area_boundary_lines` and
`area_point` are no longer pinned on any model of the gate, because the
office's 30 Areas all take the topology first, and the test says so
beside the row.
- **Export decisions (#1326).** `exported.area_body_refusals` and
`model_decisions` both derive from the Area's `AreaBodyRefusal`
property, so the new reasons (`area_not_in_one_plan_topology`,
`area_circuit_not_found`, `area_circuit_side_not_read`,
`area_circuit_area_differs`, `area_arc_not_finite`,
`area_point_outside_circuit`) are counted by both and there is no list
to extend. The diagnostics schema and `docs/export-diagnostics.md` list
them (`area_arc_not_finite` was missing from both).
- **`SpaceOutlineSource` values and descriptions** (#1351, #1405,
#1412): auto-merged; `area_plan_topology` is in the MCP tool
descriptions and the docs.
- `src/reader.rs` keeps #1389's record stages beside the new
dropped-chain-entries note. The two merges of main that #1371's branch
carried are carried by this commit and by a signed merge of main.
- **The same-project gate** (this round):
`tools/re/areas_across_saves.py`; `tools/ci/measure-reference-models.sh`
runs it between the exports and the deletion of the samples' IFCs, on
the head side of a shard that holds the 2024 to 2027 saves of
rac_advanced; `measure.yml` turns the job red unless
`areas_across_saves.txt` ends `exit 0` and has the scorer's `passed`
line, and lists its counts in the summary. `actionlint` reports nothing
on the lines this adds (its only findings are the `uses: $/...` forms
already in main's workflows); the workflow parses with a YAML safe
loader (ruby's, no PyYAML here), and `bash -n` and `shellcheck` pass on
the script. No test target is added: `tools/ci/test-targets.txt` is
unchanged.
- **Docs and changelog** (`6dacca98`): `docs/rooms.md`,
`docs/status.md`, `docs/evidence.md`, `docs/supported-profile.md` and
`docs/support-matrix.json` say Revit 2015 to 2027 and name the plan
topology; the fragments `changelog.d/added/1261-area-plan-topology.md`
and `1194-areas-2025-2027.md` credit puzzbobb by name.

## The review findings on #1371, in code

1. **Crafted file panics.** `partition_area_records.rs:497-498`:
`buf.get(span.start..body)` and `buf.get(body +
span.entries..span.end)`; a narrow record is taken whole through
`buf.get(span.start..span.end)`, and a span that does not lie in the
partition is skipped. No raw slice of parsed spans is left in the
module.
2. **The fallback to the topology after a refusal about safety.**
`locate` returns `Group::Unreadable` (a non-primary design option, stray
heights, conflicting copies, a missing line) before the topology is
looked at (`partition_area_records.rs:1166`, from `group_arrangement` at
`:1043-1062`); the topology is asked for only where the lines are sound
but not arranged (`Group::Unarranged`) or an Area's region touches a
line off the axes (`group.blocks`). The refusals before it (no Levels,
an unaccounted line, no lines) refuse every Area as before.
3. **Arcs as chords.** Written as arcs, `IfcIndexedPolyCurve` with
three-point arcs (`src/ifc/export_content.rs`, `indexed_area_curve`);
the outline is checked as written, arcs as arcs, against the circuit's
saved area, and an arc that cannot be read finitely refuses the Area
(`area_arc_not_finite`).
4. **Unrecorded Snowdon Towers 2025 claims.** Out of the report, the
changelog and the docs (Griffin, 2026-11-04). The Snowdon Towers figures
that remain are the recorded Autodesk 2024 samples in
`research/autodesk-sample-projects.tsv` (sha256 `33271010...`,
`6dc833f9...`), quoted as counts of what rvt-rs writes. Nothing in the
tree cites the 2025 file, its Revit 2025 export or the Japanese sample
except RE-333 section 7's sentence that they await a recorded source.
5. **Behind main, RE number.** Rebuilt on main at 182ed21, then a
signed merge of `a4044dc8`; RE-333 is free on main and in the open pull
requests.
6. **Smaller.** The `REFUSED_*` reasons reach the diagnostics
(`topology.remove(&u64::from(id))` is passed whole, with no
`.and_then(Result::ok)`). `!sub` replaces `-sub - 1`
(`native_area_regions.rs:784`, `:836`). `docs/status.md` and
`docs/support-matrix.json` say 2015 to 2027.

## The second review, in code

- **Bounds against a crafted file** (`native_area_regions.rs`): a
circuit is refused before its edges are built once they pass
`MAX_CIRCUIT_SIDES` (10,000), or once its lines' offset parts pass
`MAX_CIRCUIT_OFFSET_PARTS` (20,000); the edges are no longer cloned.
- **`checked_add`** in `chain_entries`; a circuit side whose line has no
`u32` ElementId refuses the Area (`add_line_ids`); `byte_range` includes
the skipped entry bytes (`AreaRecord::skipped`).
- **Two readers, one region.** Where Revit's plan topology and the
lines' arrangement both give a region and they are not the same one (net
area to 1e-6, the same corners within 1e-4 ft, no arc in the
topology's), the Area has no body and says `area_regions_disagree` in
`exported.area_body_refusals` (and in the decisions log). Measured at
`e9124b3a`, before the check: the regions were the same on 16 of 16 and
30 of 30; with the check, not yet measured, so whether it loses an Area
is what the new run says.
- **`dropped` chain records** are counted by ElementId, not by record
and partition, and the warning says an area boundary line among them is
not among the lines an Area is checked against. The Areas of the Snowdon
Towers samples are still written.
- **`BodySource` and `ProfileSource`** of an Area drawn from the
topology are `native_area_plan_topology`, with their own `body_readers`
row and `COVERAGE` row; `schedule_csv` and the plan-profile reader
accept it. This moves `exported.body_sources` (the count of
`partition_area_boundary_lines` splits) and nothing else that is
measured.
- **Tests.** The plan records are read with `NATIVE_RELEASES`.
`area_boundary_lines` and `area_point` are pinned on no gate model: the
office's 30 Areas all take the topology first and no other gate model is
known to draw an Area from its lines, so a regression in
`note_area_sources` would pass until one does (said at `MIN_READERS`).
- **Docs.** RE-333 keeps no per-Area data of the three.js export (counts
only, #1377; the archived commits of #1371 carry the earlier version,
which is already public, and the policy is applied from here on); six
plan-topology reasons, not five; the office's vertex wording is exact (3
outlines start at another vertex and the holes of 6 come in another
order as built; 2 and 6 at permit); every figure says which run measured
it: the counts of what is written come from Measure run 42003913780 on
`bcb02107`, the vertex-level and equality figures from the archived head
`e9124b3a`.

## The third round (the second review of this PR), in code

- **Hole bound** (`native_area_regions.rs`): a hole that a plan lists
again is one hole (`plan()` keeps the first listing of each pair); more
than `MAX_REGION_HOLES` (1,000) is `area_circuit_too_large`; one
`Budget` for sides, edges and offset parts covers the outer loop and
every hole of a region, so duplicates cannot each ask for a full budget.
- **A topology read and failed is not replaced by the lines**
(`partition_area_records.rs`, `locate`): when
`area_circuit_area_differs`, `area_point_outside_circuit`,
`area_arc_not_finite` or `area_circuit_too_large` is the topology's
answer and the lines draw the Area, the Area has no body and says that
reason, counted in `exported.area_body_refusals`. Where the saved area
disagrees with the face the lines give, the rule is fail closed. Where
the topology was not read (`area_not_in_one_plan_topology`,
`area_circuit_not_found`, `area_circuit_side_not_read`) the lines draw
as before. No public model had an Area in the first case in run
42003913780: none of its refusals is one of these but Snowdon
Architectural's single `area_circuit_area_differs`, and that Area was
refused, so the lines did not draw it.
- **`area_regions_disagree`, helpers and tests** (`regions_agree`,
`same_outline`, `near_outline`, `ring_perimeter`,
`point_segment_distance`): the comparison was by corner counts, which a
step jog of a few micrometres changes and a ring over 5,000 corners
refused outright. It is now by distance: every vertex of each outline
within 1e-4 ft of the other's edges, and the area difference within 1e-6
relative plus the band that tolerance allows along the outline. The
failure-first tests (a few, next to the helpers, under the pure-helper
exception) cover a region of another area, a shifted, a sheared and a
curved one, a hole one reader lacks and two holes matched to one, an
outline that is not finite, and then the same region called the same: a
ring turned to start elsewhere, a vertex on a straight edge, a 5e-5 ft
step, a ring of 6,000 vertices, and the same holes in another order.
**Which branch has run on real data:** the agree branch (16 of 16
`rac_advanced` joins and 30 of 30 office Areas at `e9124b3a`, and no
`area_regions_disagree` refusal on any public model in run 42003913780);
the refusal branch has run on no Revit file, only in those tests. A
scheme whose lines all have one offset, where the arrangement could
close at other positions than the topology, is not found in any file
here; if it exists the Area is refused, the fail-closed side.
- **Bounds on the gate's reach and wording**: see above. `arm.sh` should
read "blocks landing by the landing rule".
- **Docs.** No per-Area figure of the three.js export is left in the
tree (RE-333 said "three four-sided Areas of under 83 ft2" and how that
export writes the curved Area; `docs/rooms.md` said "worst 2.0e-7"; now
"all 25 within 1e-6 relative", counts only). `docs/rooms.md` and
`docs/status.md` name `area_regions_disagree`, mark `area_plan_topology`
"not measured" on Revit 2025 to 2027 and the Snowdon samples, say that
it is the Areas' own outline source and not per release (a 2024 Snowdon
Towers Area and an office Area take the same path), no longer say "Areas
as on 2024" beside models that write none, and say that the office no
longer writes `area_boundary`. Snowdon's counts say which head they are
from everywhere. RE-333 section 3 reports the disagree check measured
(it said "not yet measured").

## What the evidence is, exactly

- **Revit's IFC4 export has no export of these Areas.** The
`rac_advanced` check is against the one public export of it, from the
three.js repository: IFC2X3, by a build of Revit 2021's exporter whose
string ends "IU alternativa 21.0.0.383" (publisher not established),
showing the project's 2015 to 2020 state. It is counted apart, never
used to remove a value or to settle a disagreement between exporters,
and its Measure uploads are counts only (`racadv-*`, #1377).
- **It is out of sample for this rule.** The topology's loops, and the
areas Revit saves for them (`PlanCircuit m_area`) that every loop is
checked against, are in the file; nothing was read off the export. That
is the difference from #1367's wall-line rule, whose rule was worked out
from the export it was scored on. On the 2020 save, measured on the
archived head `e9124b3a`: 25 Areas written, 25 in that export, 0 extra,
all within 0.1% in area and 0.01 ft in outline; main's 16 joined Areas
equal their topology loops.
- **Revit 2025 to 2027** are checked against the same project's 2024
save only.
- Per Griffin (2026-11-04): Areas checked against a non-IFC4 or
third-party export may ship labelled; the trust marker
`area_plan_topology` names the rule, and RE-333, the docs and the
changelog name the oracle.

## Testing

Unit tests are banned in this repository: none added. The test that
changes is a real-file one (`tests/value_sources_offsets.rs`).

- [ ] `tools/check-local.sh` passes: not run locally (no local builds on
this checkout); `cargo fmt --all -- --check` and `python3
tools/release/changelog.py check` pass here, CI's clippy, MSRV and doc
jobs and the corpus tests are the gate. No let-chains; every nested
tuple in a collection has a `type` alias.
- [x] Verified end to end on real Revit files, **on `5008247d`, the code
before the `area_plan_topology_unchecked` marker**: Measure run
42017400629 (unfiltered, base main, nordic, r2025, holdout, samples,
racadv). These are the figures of record for that code; the run after
the marker (below) replaces them where it differs:
  - 26 of 117 exports move, the same set as in run 42003913780 (below);
  - `rules:` findings 0 on 90 models and on 18 held-out;
- held-out spaces move on one model only, from (0 in both, 0 only in
rvt-rs's, 8 only in Revit's) to (6, 0, 2);
- the racadv pairs 2015 to 2020: 116 in both files, 0 only in rvt-rs's,
0 only in Revit's;
  - MCP: 0 differ on 629 lines;
- refusals: `next_storey_not_proven` 9, `area_circuit_area_differs` 1,
`point_not_read` 4, and no `area_regions_disagree` and no
`area_circuit_too_large`;
- the gate passes on the `2024 2099` shard, 25 Areas and 25 with a body
on each of the 4 saves, every field equal, and says `skipped` on the
`2008 2023` shard;
- the semantic merge check (#1334) reads a pass, with 5 findings for
#1428.
Earlier, on `bcb02107`: Measure run 42003913780 and timing run
42003917325: 25 public exports move and one held out; bodies
`native_area_plan_topology` 30 on each office, 25 on each `rac_advanced`
save above, 96 on Snowdon Towers Architectural and 2 on Structural; time
over main's at most 1.05 (`rst_basic` 2026), peak memory at most 1.03
(`rme_advanced` 2027, 559 to 573 MiB), and the lost `samples-2008-2023`
job of run 41990405944 did not recur. The vertex-level and equality
figures in RE-333 section 8 are from the archived head `e9124b3a` and
were not re-read.
The check on the earlier pushed head `401f5244`: run 42010805118, green,
with the scorer that compared the storey as `None`; its `ifc.sha256`
equal to run 42003913780's on 58 of 58.
**The final unfiltered run on this head `7188e2e8`: 42023345111** (`-f
base=main -f nordic=true -f r2025=true -f holdout=true -f samples=true
-f racadv=true`), unread when this body is written. Expected, against
run 42017400629: only the exports of `rac_advanced` 2025, 2026 and 2027
move (their Areas read `area_plan_topology_unchecked`), the gate passes
on the new expectation, nothing else changes. No timing run: what
changed since the timing run bounds crafted input, compares two regions
by distance (quadratic in one ring's vertices, tens on the files
measured) and sets a marker.
- [ ] If this touches the IFC exporter: the witness verdicts replay or
the changed observations are refreshed. Core Interior has no Areas, so
its export is expected to be unchanged; the replay is CI's.
- [ ] If this is a performance change: N/A.

**Final unfiltered Measure on the code of this head, run 42023345111
(7188e2e; the later commit is the MCP contract sync), read by the
maintainer:** against 42017400629's head exactly 3 exports move,
`rac_advanced` 2025, 2026 and 2027, by the new marker. Against main 91
of 117 are identical and 26 move, the same set as before, 1 of them held
out. The same-project gate passes on the expected values: 25 Areas with
25 bodies on each of the 4 saves, every field equal,
`area_plan_topology` on 2024 and `area_plan_topology_unchecked` on 2025
to 2027. `rules:` findings 0 on 90 models and 18 held-out, MCP 0 differ
on 629 lines, semantic check `pass: 5 findings in 34 models`.

## Audit-honesty checklist

- [x] Docs reflect the state after this PR.
- [x] A user-visible change has its fragment under `changelog.d/added/`,
not in `CHANGELOG.md`.
- [x] Limitations: the RE-333 report's "not measured" list is kept
(Revit 2026 and 2027 against a Revit export, the Snowdon Towers 2025
file, a scheme with more than one plan on a Level, an Area Revit reports
as not enclosed, the straight step where two offset curves do not cross,
Revit 2008 to 2014).
- [x] Commit messages describe what changed and why.
- [x] No emojis, no private paths in committed files.
- [x] Reverse-engineering finding:
`probes/examples/probe_re333_area_plan_topology.rs`,
`reports/element-framing/RE-333-area-plan-topology.md` and an addendum
in `docs/format-reconnaissance.md`.

## Legal and contribution hygiene

The declaration is puzzbobb's on #1371, quoted here, and the
maintainer's commits are Apache-2.0 as the rest of the repository:

> - [x] I agree this work is licensable under Apache-2.0 (see
`CONTRIBUTING.md`)
> - [x] This PR contains no Autodesk proprietary source, decompiled
internals, or NDA'd SDK content (see `CLEANROOM.md`)
> - [x] Any new test fixtures use synthetic values (`testuser`,
`111111`, `FY-20XX`, etc.) and contain no real-world PII
>
> The class and field names come from the schema each file embeds
(`Formats/Latest`), as `rvt-schema` prints them. Autodesk's samples are
fetched for the run and never stored. The office is CC BY-SA 4.0, read
by byte range and never stored.

(The last sentence of that declaration on #1371 about a local Revit 2025
export of Snowdon Towers is not repeated: those figures are out of this
pull request.)

## Breaking changes

None. `native_area_regions` is a new public module and `AreaRegion` a
new public type. Areas of Revit 2025 to 2027 files are new `IfcSpace`,
and an Area that main draws from its lines now says `area_plan_topology`
where the topology is read.

## Output samples

`SpaceOutlineSource` on `rac_advanced` (the archived head `e9124b3a`,
run 41894715743): the 6 Areas main marks `area_boundary` and the 10 it
marks `area_boundary_joined` say `area_plan_topology`, as do the 9 it
did not write.

## Related issues

Refs #1261, Refs #1194, Refs #763. Reopens #1371. Supersedes the
wall-line rule of #1367.

Co-authored-by: puzzbobb <[email protected]>

---------

Co-authored-by: puzzbobb <[email protected]>
DrunkOnJava added a commit that referenced this pull request Nov 5, 2026
…-hosted line is the offset the file stores (#1261) (RE-332)

Merge main into the wall-line branch with its tree set to main plus the
research only: no reader, exporter, MCP, schema or docs change. The rule
that drew Areas 2 and 5 along a wall-hosted line is dropped; the plan
topology of RE-333 (#1428) draws all 25 Areas of every rac_advanced save but
2021's from the offsets the file stores. The branch tip before this commit is
kept at refs/archive/2026-11-05/feat/1261-areas-bounded-by-walls.

Kept: the probe, and the report rewritten as notes (the 127 lines against the
walls they name; the two compound lines; the reader's measurements, labelled
as not landed). Added: tools/re/wall_lines_vs_offsets.py, which joins the
probe with probe_re333_area_plan_topology and shows that each line's position
is its stored offset on all 127 lines. Corrected: the first version said
nothing in the file records where a line steps from face to centre; the
stored offsets (AreaMeasureCurveData) do. The three.js export's per-Area
positions are replaced by counts (#1377).
DrunkOnJava added a commit that referenced this pull request Nov 5, 2026
…line is the offset the file stores (#1261) (#1367)

## Summary

Research notes only, no export change. This pull request first carried a
reader that drew two more Areas of Autodesk's `rac_advanced` along a
boundary line Revit picked from a wall (`area_boundary_wall_line`, 18 of
25 Areas, read off the three.js IFC2X3 export). #1428 landed the plan
topology (RE-333), which draws all 25 Areas of every save but 2021's
from the offsets the file stores, so that reader is not landed
(decision: Griffin, 2026-11-05, research notes only). What stays is what
was measured.

**Kept**

- `probes/examples/probe_re332_wall_hosted_lines.rs`: each area boundary
line against the wall its reference list names (centre line, face,
compound, other, no host).
- `reports/element-framing/RE-332-wall-hosted-lines.md`, rewritten as
notes: the 127 lines against the walls they name (61 name a basic wall,
50 a curtain wall, 16 none), the two compound lines (177377 and 177363),
the numbers the rule used and what the data pins, and the measurements
of the reader that was not landed, labelled as such.
- `tools/re/wall_lines_vs_offsets.py` (new): joins the probe with
`probe_re333_area_plan_topology` line by line. On the 2021, 2022 and
2023 saves, all 127 lines match: a face line has an offset of half its
wall's thickness, a centre line none, a curtain wall's line 0.041010 ft,
a line naming no wall none, and the two compound lines both; 71 lines
have an offset, RE-333's 71.
- `changelog.d/research/1261-wall-hosted-lines.md`.

**Dropped** (everything else the branch changed): the reader in
`partition_area_records.rs`, the `area_boundary_wall_line` marker in
`export_content.rs`, the MCP schema and contract, the docs and support
matrix paragraphs, the `changed` fragment. The tree is main's plus the
four files above.

**Corrected.** The first version said nothing in the file records where
a line steps from face to centre, and read the step from the export. The
file stores it: `AreaMeasureCurveData.m_schemeSegments` of 177377 is 0
from 0 to 0.833320 of the line and -0.497047 after, of 177363 0 to
0.310893 and 0.497047 after, a step at x -13.405 on both. The export's
per-Area positions that the first version kept are replaced by counts
(#1377).

**History kept.** The branch tip before this change,
`98ba33b3a4e0b6d9723ee8f5b1f821aaaf9ddb17`, is at
`refs/archive/2026-11-05/feat/1261-areas-bounded-by-walls`. The branch
itself moves forward (a signed merge of main whose tree is main plus the
four files), with no force push.

## Testing

Unit tests are banned: none added.

- [x] `python3 tools/release/changelog.py check`, `python3
tools/ci/api-doc-ids.py`, `python3 -m py_compile` and `rustfmt --check`
pass locally; no local build, per this checkout's rules.
- [x] End to end on real Revit files: Measure run 42027944261 (`--ref
main`, `ref` 19d27bb, which differs from the head only in two lines of
the report, samples 2020 to 2022, both probes, no scorers) is green, so
the probe builds and runs on main's library;
`tools/re/wall_lines_vs_offsets.py` on its output for the 2020, 2021 and
2022 saves reads `passed: 127 lines, 71 with an offset, every position
matches its stored offsets`. The same on the outputs of runs 41862228192
and 42008543772 (the 2021, 2022 and 2023 saves). Fed one line with a
changed offset, one missing line, a compound line with its step removed
and a centre line with an offset, it exits 1.
- [x] No export changes: the tree is main's plus a probe, a report, a
research tool and a fragment, so no IFC moves.

## Audit-honesty checklist

- [x] The report says what is measured and what was not: no Revit IFC4
export of these Areas exists; the three.js export is counts only; the
reader of section 7 was in-sample and is not on main.
- [x] A changelog fragment (`research`), not `CHANGELOG.md`.
- [x] No emojis, no private paths.
- [x] Probe under `probes/examples/`.

## Legal and contribution hygiene

- [x] Apache-2.0.
- [x] No Autodesk proprietary source; the corpora are fetched, not
stored (CLEANROOM.md).
- [x] No new fixtures.

## Breaking changes

None.

## Related issues

Refs #1261. The 2021 save of `rac_advanced` is #1434.
DrunkOnJava added a commit that referenced this pull request Nov 15, 2026
…t's Revit 2018 export of rac_basic or the MIT tutorial house (#2070)

## Summary

The repository quoted absolute figures from two sources that carry no
licence. These are now differences, lengths and percentages, as #2065
and #2066 did for Snowdon's export. The two sources:
- the Revit 2018 IFC4 export of `rac_basic_sample_project`, attached to
a forum post;
- the MIT 4.567 tutorial house, which is "copyright reserved".

## Changes

- **RE-334, `docs/rooms.md` and the #1354 entry of `CHANGELOG.md`.**
Room 101's areas and its void's, which were Revit's from the export or
ours equal to them, are replaced by percentages. The differences already
given stay.
- **RE-358 section 5.** The export's volumes of `rac_basic` walls 198694
and 493612 become rvt-rs's volume over Revit's.
- **RE-56.** The tutorial house's roof edge endpoints, its record box's
base and top elevations and its mesh's x, y and z extents become the
edge's length, the box's height and the mesh's plan size.

Done outside this PR:
- **PR #1377's body.** It quoted the export's void area and room area.
It was edited the same way and its earlier revisions deleted.
- **v0.15.0's release notes.** They held the #1354 entry and were edited
by API. Release notes keep no history.

Main's git history (including #1377's squash message), notification
emails and GH Archive keep the old text, and they cannot be changed.

## Testing

`tools/ci/api-doc-ids.py` passes. Docs only, no output change: no
Measure.

## Audit-honesty checklist

- [x] The changed figures are the differences and percentages the old
ones gave, recomputed from them.

## Legal and contribution hygiene

- [x] Apache-2.0. Docs only.

## Breaking changes

None.

https://claude.ai/code/session_01TFTgj3Ddfs7cFGMNAgVAut
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.

rac_advanced rooms against the public IFC2X3 export: 42 of 85 stored-solid rooms within 0.1% of Revit's area

1 participant