homemaker-layout/src/homemaker_layout
Bruno Postle 479d4a57d5 3l6: leaf-sharing runs auto-finish (unfold+polish) before write
Leaf-sharing evolve runs optimised a sharing-credited objective (a shared
leaf of code X with share=k counts as k programme rooms, size re-centred on
k*target) but wrote the un-materialised genome, which the canonical
homemaker-fitness rates catastrophically worse (harbor-house: internal
1.03e-05 vs canonical 6.73e-29, 15 critical missing-room fails).

Fix: before write, driver.polish_finish() unfolds every live shared leaf
into k distinct rooms (operators.unfold_shared_leaves — pays down the count
deficit) then warm-starts a leaf_sharing=False polish search from the
unfolded genome so the materialised rooms get proportion/width/size cleanup.
Returned best.fitness is the canonical score (leaf_sharing off => internal
== canonical). This is yaa's proven unfold-then-polish path, made automatic.

evolve.py: new --polish-budget (env HOMEMAKER_POLISH_BUDGET; -1=auto=
budget//2, 0=unfold+rescore only). Interrupt forces polish_budget=0 for a
fast honest output. Default stays --leaf-sharing on (its topology-search
speed retained; output made honest by the finish). Schedule B in-run
annealing remains homemaker-py-kpu.

Verified (harbor-house 3000+1500): reported polish fitness 4.79788e-27
matches canonical homemaker-fitness exactly, 0 critical fails. Tests: 254
pass (+3 polish_finish).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M8566xAxTnwtJTkpXjYNZm
2026-07-15 10:21:58 +01:00
..
__init__.py Rename package: homemaker → homemaker-layout 2026-06-14 08:18:06 +01:00
dom.py erc.3: explicit per-leaf multiplicity closes the leak; driver A/B wired (§13.3) 2026-06-24 18:16:17 +01:00
driver.py 3l6: leaf-sharing runs auto-finish (unfold+polish) before write 2026-07-15 10:21:58 +01:00
evolve.py 3l6: leaf-sharing runs auto-finish (unfold+polish) before write 2026-07-15 10:21:58 +01:00
fitness.py 9o5: type superposition + per-eval collapse (multi-use leaves) 2026-06-30 07:08:46 +01:00
fitness_cmd.py Add homemaker-fitness: native Python CLI to replace urb-fitness.pl 2026-06-14 17:15:33 +01:00
genome.py Phase 6 §11.5: structural niching + restarts — negative result (c4c.5) 2026-06-18 23:42:39 +01:00
geometry.py Rename package: homemaker → homemaker-layout 2026-06-14 08:18:06 +01:00
graph.py erc.3: explicit per-leaf multiplicity closes the leak; driver A/B wired (§13.3) 2026-06-24 18:16:17 +01:00
innerloop.py x3b/§13.10: productionise leaf-sharing — per-code share grain + CLI wiring 2026-06-28 22:04:35 +01:00
operators.py yaa: unfold shared leaves at sharing->no-sharing transition 2026-07-12 16:34:33 +01:00
oracle.py Fix parity gap: oracle.py must run with URB_NO_OCCLUSION=1 2026-06-17 18:40:56 +01:00
programme.py 9o5: type superposition + per-eval collapse (multi-use leaves) 2026-06-30 07:08:46 +01:00
solver.py Rename package: homemaker → homemaker-layout 2026-06-14 08:18:06 +01:00