mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-12 13:29:04 +00:00
Dominant secondary-glazing split resolves deterministically to SECONDARY 🟥
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
f873d5cad3
commit
787f0066c8
1 changed files with 21 additions and 0 deletions
|
|
@ -63,10 +63,31 @@ def test_dominant_era_stated_double_or_triple_resolves_deterministically(
|
|||
assert result is expected
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"description",
|
||||
[
|
||||
"95% secondary glazing (sap 9.94), 5% single glazing",
|
||||
"90% secondary glazing, 10% double glazing 2002 or later",
|
||||
],
|
||||
)
|
||||
def test_dominant_secondary_glazing_resolves_to_secondary(description: str) -> None:
|
||||
# Secondary glazing is era-free like single (SAP10 code 5, U = 2.9 regardless
|
||||
# of install year), so a dominant-secondary split is fully determined — the
|
||||
# guard must claim it rather than let the LLM flatten it onto the minority
|
||||
# type (Model#1416).
|
||||
|
||||
# Act
|
||||
result = glazing_mix_guard(description)
|
||||
|
||||
# Assert
|
||||
assert result is GlazingType.SECONDARY
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"description",
|
||||
[
|
||||
"100% double glazing 2002 or later", # uniform — one type
|
||||
"100% secondary glazing (sap 9.94)", # uniform — one type
|
||||
"90% double glazing unknown age, 10% single glazing", # dominant but era unstated
|
||||
"80% double glazing 2002 or later, 20% double glazing pre-2002", # same base type
|
||||
"some double glazing and a bit of single", # unparseable — no percentages
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue