mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-30 13:10:47 +00:00
Add comment explaining floor-dim synthesis guard and bungalow coverage gap
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
76d07dba39
commit
e62e5fbfe4
1 changed files with 11 additions and 0 deletions
|
|
@ -2946,6 +2946,17 @@ def _sap_17_1_building_part(
|
|||
perimeter_per_storey = exposed_area / total_height
|
||||
party_length_per_storey = party_area / total_height
|
||||
|
||||
# Guard: synthesise only when floor dims are absent AND we can confirm
|
||||
# single-storey single-part. `is_flat` (sap_flat_details present) is the
|
||||
# current signal — flats are always single-storey within the dwelling.
|
||||
# Bungalows are equally single-storey but carry no equivalent structural
|
||||
# field; `dwelling_type` string matching is the only handle, and has not
|
||||
# been confirmed necessary (no bungalows with empty floor dims were found
|
||||
# in the failing batch). An alternative worth considering: drop `is_flat`
|
||||
# entirely and trigger on `not bp.sap_floor_dimensions and is_single_part`
|
||||
# alone — if the cert lodged no dims at all, there is no per-storey data to
|
||||
# misattribute regardless of dwelling type. Requires corpus evidence that
|
||||
# multi-storey single-part certs never omit floor dims before widening.
|
||||
if not bp.sap_floor_dimensions and is_single_part and is_flat:
|
||||
floor_dimensions = [
|
||||
SapFloorDimension(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue