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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CONTEXT FOR CLAUDE — ADSO FLOOR-PLAN AUTOMATION PROJECT
2
+
3
+ ## 1. PURPOSE
4
+
5
+ This is a handoff/context document for a Claude session working on the existing
6
+ floor-plan automation repository.
7
+
8
+ The project is an automated floor-plan generation system. The repository already
9
+ contains an upstream input-understanding pipeline and a downstream deterministic
10
+ layout-generation pipeline.
11
+
12
+ The current goal is to build a reliable system that can eventually generate and
13
+ compare many valid, space-efficient floor layouts for customer-defined office
14
+ requirements, while preserving exact geometry, clearances, boundaries, doors,
15
+ pillars, and other architectural constraints.
16
+
17
+ IMPORTANT:
18
+ - Do not replace or redesign the existing upstream Normalize -> Perceive ->
19
+ SpaceModel stages.
20
+ - The current implementation/testing covers a limited set of architectural and
21
+ product types, primarily private-room behavior, base kit, default configuration,
22
+ and some optional items.
23
+ - More architectural types and product types will be added later by developers.
24
+ - Do not invent new product standards or architectural rules from general LLM
25
+ knowledge.
26
+
27
+ ---
28
+
29
+ # 2. ARCHITECTURE NAME
30
+
31
+ ## ADSO
32
+
33
+ **Agentic Deterministic Spatial Optimization Architecture**
34
+
35
+ Full name:
36
+
37
+ > Agentic Deterministic Spatial Optimization Architecture for Automated
38
+ > Floor-Plan Generation.
39
+
40
+ Core principle:
41
+
42
+ > The Agent decides WHAT to try; the deterministic system decides WHICH valid
43
+ > alternatives to explore and EXACTLY WHERE they go.
44
+
45
+ The LLM/Agent must never become the authority for final geometry, measurements,
46
+ collision detection, clearance validation, boundary containment, or hard
47
+ architectural validity.
48
+
49
+ ---
50
+
51
+ # 3. FINAL TARGET ARCHITECTURE
52
+
53
+ ```text
54
+ CUSTOMER REQUIREMENTS
55
+ |
56
+ v
57
+ REQUIREMENT INTERPRETER
58
+ (LLM / Agent)
59
+ |
60
+ v
61
+ EXISTING INPUT UNDERSTANDING
62
+ Normalize
63
+ Perceive
64
+ SpaceModel
65
+ |
66
+ v
67
+ REAL BUILDING / PLACEABLE FLOOR
68
+ walls
69
+ inner-face boundary
70
+ doors
71
+ windows
72
+ pillars / obstacles
73
+ |
74
+ v
75
+ DESIGN-SPACE SEMANTICS
76
+ products
77
+ quantities
78
+ relationships
79
+ orientations
80
+ references
81
+ architectural rules
82
+ |
83
+ v
84
+ DETERMINISTIC SEARCH / SOLVER
85
+ candidate generation
86
+ movement / orientation
87
+ office placement
88
+ alternatives
89
+ deduplication
90
+ ranking
91
+ future backtracking
92
+ |
93
+ v
94
+ DECLARATIVE PLACEMENTS
95
+ |
96
+ v
97
+ DETERMINISTIC RESOLVER
98
+ |
99
+ v
100
+ EXACT INTEGER-MM GEOMETRY
101
+ |
102
+ v
103
+ HARD VALIDATOR / GATE
104
+ shell boundary
105
+ collisions
106
+ pillars
107
+ doors / functional access
108
+ clearances
109
+ architectural rules
110
+ |
111
+ v
112
+ SPATIAL QUALITY / OBJECTIVE
113
+ residual usability
114
+ route width
115
+ directness
116
+ enclosure efficiency
117
+ compactness
118
+ obstacle effects
119
+ |
120
+ v
121
+ BEST VALID LAYOUT(S)
122
+ |
123
+ v
124
+ VISION CRITIC
125
+ |
126
+ v
127
+ LLM / AGENT REFINEMENT
128
+ |
129
+ +--------------------> iterate
130
+ ```
131
+
132
+ ---
133
+
134
+ # 4. AUTHORITY BOUNDARIES
135
+
136
+ ## Normalize
137
+
138
+ Existing upstream stage.
139
+
140
+ Purpose:
141
+ - clean/normalize input geometry
142
+ - prepare reliable geometry for later processing
143
+
144
+ Do not replace or redesign this stage in the current work.
145
+
146
+ ## Perceive
147
+
148
+ Existing upstream stage.
149
+
150
+ Purpose:
151
+ - understand/detect walls, doors, windows, pillars, and other input entities
152
+
153
+ Do not replace or redesign this stage in the current work.
154
+
155
+ ## SpaceModel
156
+
157
+ Existing semantic representation of the input building.
158
+
159
+ It represents and relates:
160
+ - shell
161
+ - walls
162
+ - doors
163
+ - windows
164
+ - pillars
165
+ - floor
166
+ - references
167
+ - semantic relationships
168
+
169
+ ## Customer Requirements
170
+
171
+ Defines WHAT each office/tenant needs.
172
+
173
+ A customer may request:
174
+ - one office
175
+ - several offices
176
+ - different products/quantities per office
177
+ - same products/quantities in multiple offices
178
+ - different functional needs per office
179
+
180
+ ## LLM / Agent
181
+
182
+ Responsible for:
183
+ - interpreting requirements
184
+ - high-level strategy
185
+ - deciding what to try
186
+ - interpreting failures
187
+ - calling deterministic spatial tools
188
+ - later explaining/rationalizing the selected result
189
+
190
+ Must NOT:
191
+ - calculate final coordinates
192
+ - invent product standards
193
+ - invent architectural clearance values
194
+ - override the Gate
195
+ - declare an invalid layout valid
196
+
197
+ ## Deterministic Search
198
+
199
+ Responsible for:
200
+ - candidate generation
201
+ - product movement/orientation
202
+ - room/office placement
203
+ - alternative layouts
204
+ - deduplication
205
+ - ranking
206
+ - future backtracking/global search
207
+
208
+ ## Resolver
209
+
210
+ Responsible for:
211
+ - resolving declared semantic placement/reference relationships
212
+ - exact geometry
213
+ - exact integer-mm coordinates
214
+
215
+ R-3 established the resolver as the single geometry authority for the migrated
216
+ private-office base-kit relationships.
217
+
218
+ ## Geometry / CAD Layer
219
+
220
+ Responsible for exact geometric representation/output.
221
+
222
+ ## Gate
223
+
224
+ The Gate is the SOLE BLOCKING PHYSICAL/ARCHITECTURAL VALIDATION AUTHORITY.
225
+
226
+ It validates:
227
+ - shell/inner-floor containment
228
+ - collisions
229
+ - pillars/obstacles
230
+ - clearances
231
+ - door functionality/access
232
+ - reachability
233
+ - minimum widths
234
+ - architectural rules
235
+
236
+ Do not duplicate Gate ownership in the objective or resolver.
237
+
238
+ ## Objective
239
+
240
+ Ranks already-valid candidates.
241
+
242
+ It must not create new hard constraints.
243
+
244
+ ---
245
+
246
+ # 5. CORE USER REQUIREMENTS THE FINAL SYSTEM MUST SUPPORT
247
+
248
+ ## Single-office / single-tenant
249
+
250
+ One customer brief can request one office.
251
+
252
+ ## Multi-office / multi-tenant
253
+
254
+ Each office can have its own product set and quantities.
255
+
256
+ Example:
257
+
258
+ ```text
259
+ Office A:
260
+ table + owner chair + 2 visitors + pedestal
261
+
262
+ Office B:
263
+ different products / quantities
264
+ ```
265
+
266
+ Or:
267
+
268
+ ```text
269
+ Office A:
270
+ 2 desks + 4 chairs
271
+
272
+ Office B:
273
+ 2 desks + 4 chairs
274
+ ```
275
+
276
+ Even if two offices have the same products and quantities, their geometry may
277
+ still differ if the rules permit different valid arrangements.
278
+
279
+ The global solver must eventually reason over the whole floor rather than
280
+ permanently assigning an office to one computational region.
281
+
282
+ ---
283
+
284
+ # 6. REAL FLOOR / INNER SHELL BOUNDARY
285
+
286
+ The actual placeable floor is the whole usable floor bounded by the inner face
287
+ of the building shell.
288
+
289
+ IMPORTANT:
290
+ - The inner face of the input shell is the real geometric limit.
291
+ - Regions and seams are computational decomposition, NOT permanent architectural
292
+ boundaries.
293
+ - A generated office may span region boundaries.
294
+ - Future global search must use the whole placeable floor.
295
+
296
+ Never let generated geometry cross the actual inner shell boundary.
297
+
298
+ ---
299
+
300
+ # 7. DOOR FUNCTIONAL CONSTRAINTS
301
+
302
+ Doors are not merely gaps.
303
+
304
+ Door behavior must remain functional:
305
+ - access
306
+ - opening/swing
307
+ - approach
308
+ - clearance
309
+ - relationship to furniture
310
+ - relationship to pathways
311
+
312
+ The owner-face migration proved why semantic information matters:
313
+ a missing owner face could make `door_serves_visitor_end` pass vacuously.
314
+ S3-1c corrected this.
315
+
316
+ Never allow missing semantic information to silently disable a blocking rule.
317
+
318
+ ---
319
+
320
+ # 8. PRODUCT VARIABILITY
321
+
322
+ Products are not necessarily the same across customer requests.
323
+
324
+ The final system must eventually support:
325
+ - different product types
326
+ - different quantities
327
+ - optional items
328
+ - orientation
329
+ - movement
330
+ - product relationships
331
+ - legitimate grouping/separation where explicitly supported
332
+ - future architectural/product types
333
+
334
+ Current tests are intentionally limited to existing repository semantics,
335
+ mainly private-room behavior, base kit, default configuration and optional
336
+ items such as pedestal/waste_bin.
337
+
338
+ Future developers will add more architectural types after the current limited
339
+ system is stable.
340
+
341
+ Do NOT invent product behavior just because geometry technically allows it.
342
+
343
+ ---
344
+
345
+ # 9. EXACT MEASUREMENT / MILLIMETRE REQUIREMENT
346
+
347
+ The system must preserve exact geometry and measurements.
348
+
349
+ Target:
350
+ - integer-mm geometry
351
+ - exact gaps/clearances
352
+ - exact orientation
353
+ - exact product dimensions
354
+ - exact boundary checks
355
+
356
+ Important distinction:
357
+
358
+ ```text
359
+ Search
360
+ -> chooses candidate position
361
+
362
+ Resolver
363
+ -> calculates exact geometry
364
+
365
+ Gate
366
+ -> validates exact geometry
367
+ ```
368
+
369
+ Do NOT brute-force every coordinate at every 1 mm everywhere. That would cause
370
+ combinatorial explosion.
371
+
372
+ Instead, candidate values should be semantically legitimate, while the geometry
373
+ itself remains exact.
374
+
375
+ `Placement.along_mm` already supports exact signed movement along a reference.
376
+
377
+ Example:
378
+
379
+ ```text
380
+ table
381
+ |
382
+ | 150 mm perpendicular gap
383
+ v
384
+ pedestal
385
+ ```
386
+
387
+ Move the pedestal 300 mm along the table:
388
+ - `along_mm = 300`
389
+ - `offset_mm` remains 150
390
+ - resolver recomputes exact X/Y
391
+ - perpendicular table-to-pedestal gap remains exactly 150 mm
392
+
393
+ ---
394
+
395
+ # 10. R-3 STATUS — RESOLVER MIGRATION COMPLETE
396
+
397
+ Verified stages:
398
+
399
+ ```text
400
+ S3-1a side semantics PASS
401
+ S3-1b individual product instances PASS
402
+ S3-1c owner face semantics PASS
403
+ S3-1d orientation PASS
404
+ S3-2 table / center migration PASS
405
+ S3-3 owner / behind migration PASS
406
+ S3-4 visitors / facing migration PASS
407
+ S3-5 beside-table migration PASS
408
+ S3-6 single geometry authority PASS
409
+ ```
410
+
411
+ Repeated verification showed:
412
+ - 0.000 mm geometry differences
413
+ - unchanged measurements
414
+ - unchanged hard validation
415
+ - unchanged frozen baselines
416
+ - unchanged DXF drawn content
417
+
418
+ Current ownership:
419
+ - center/table -> resolver
420
+ - behind/owner -> resolver
421
+ - facing/visitors -> resolver
422
+ - beside-table -> resolver
423
+ - along_wall -> still search/placer responsibility
424
+ - pathways -> current placer/build layer
425
+ - enclosure -> current placer/build layer
426
+ - Gate -> sole validation authority
427
+
428
+ `ANY_WALL` remains search policy. The resolver resolves known references; it
429
+ does not choose an arbitrary wall.
430
+
431
+ ---
432
+
433
+ # 11. APPROVED PRODUCT / PLACEMENT SEMANTICS
434
+
435
+ ## beside_table
436
+
437
+ Approved domain meaning:
438
+
439
+ ```text
440
+ reference = table
441
+ gap = item_side_gap_mm = 150 mm minimum
442
+ alignment = centered on the table side
443
+ additional beside items stack outward
444
+ ```
445
+
446
+ Example:
447
+
448
+ ```text
449
+ table -> 150 -> pedestal -> 150 -> waste_bin
450
+ ```
451
+
452
+ No new clearance was invented.
453
+
454
+ ## along_mm
455
+
456
+ `offset_mm`:
457
+ - perpendicular distance from reference
458
+ - remains non-negative under its current semantics
459
+
460
+ `along_mm`:
461
+ - signed displacement along reference face
462
+ - independent from offset
463
+ - geometric parameter
464
+ - not a clearance
465
+
466
+ ## visitor count
467
+
468
+ Count expands into individual producer placements:
469
+
470
+ ```text
471
+ visitor#1
472
+ visitor#2
473
+ visitor#3
474
+ ```
475
+
476
+ Resolver does NOT own count semantics.
477
+
478
+ The row is centered with deterministic arithmetic derived from:
479
+ - product width
480
+ - existing `item_side_gap_mm`
481
+
482
+ ---
483
+
484
+ # 12. V1 STATUS — KIT ENUMERATION COMPLETE
485
+
486
+ V1 was implemented and VERIFIED.
487
+
488
+ Purpose:
489
+ - stop keeping only the first valid kit placement
490
+ - expose already-supported kit alternatives
491
+ - compare multiple valid placements
492
+
493
+ V1 does:
494
+ - kit-level enumeration only
495
+ - existing face order
496
+ - existing offset order
497
+ - existing `fits()`
498
+ - deterministic bounded enumeration
499
+ - geometry/arrangement reporting
500
+
501
+ V1 does NOT:
502
+ - invent product alternatives
503
+ - invent grouping
504
+ - invent relations
505
+ - add clearances
506
+ - scan arbitrary 1 mm values
507
+ - modify room-level search
508
+ - modify multi-office global search
509
+
510
+ V1 measured many fitting kit positions while the old system kept one.
511
+
512
+ V1 feature flag:
513
+ ```yaml
514
+ office:
515
+ candidate_enumeration: false
516
+ ```
517
+
518
+ Flag OFF:
519
+ - S0.5 = 0 differences
520
+ - diversity = 0 differences
521
+ - winner unchanged
522
+ - DXF unchanged
523
+ - measurements unchanged
524
+
525
+ ---
526
+
527
+ # 13. VISUAL REPORT REQUIREMENT
528
+
529
+ Visual reporting is now mandatory for layout-generation stages.
530
+
531
+ Every future report should include rendered layouts in Markdown.
532
+
533
+ Use:
534
+ - same scale
535
+ - same extents
536
+ - same annotation scheme
537
+
538
+ Show where relevant:
539
+ - shell
540
+ - actual inner-face boundary
541
+ - walls
542
+ - doors
543
+ - windows
544
+ - pillars
545
+ - products
546
+ - generated partitions
547
+ - pathways
548
+ - office labels
549
+ - entrances
550
+ - important dimensions
551
+
552
+ Measurements displayed on images MUST come from deterministic geometry.
553
+ Do not manually type approximate dimensions.
554
+
555
+ Visual review is supplementary:
556
+ - it can reveal awkward layouts, dead pockets, clustering, pathway issues, etc.
557
+ - it cannot override deterministic geometry or Gate validation.
558
+
559
+ ---
560
+
561
+ # 14. V1 FINDING THAT MOTIVATED V2
562
+
563
+ V1 exposed multiple valid kit positions, but the current objective scored them
564
+ identically.
565
+
566
+ Thus:
567
+
568
+ ```text
569
+ different valid geometry
570
+ |
571
+ v
572
+ same score
573
+ ```
574
+
575
+ Reason:
576
+ the old objective could not "see" furniture placement inside a room.
577
+
578
+ V2 exists to make the objective spatially aware.
579
+
580
+ ---
581
+
582
+ # 15. V2 OBJECTIVE POLICY
583
+
584
+ Approved decisions:
585
+
586
+ ## X1 — two-flag split
587
+
588
+ Approved.
589
+
590
+ ```yaml
591
+ office:
592
+ objective_v2: false
593
+ ```
594
+
595
+ V2 first MEASURES new metrics at weight 0.
596
+ Promoting weights is a separate explicit decision.
597
+
598
+ ## X2 — sequence
599
+
600
+ Approved:
601
+
602
+ ```text
603
+ C1 in-room residual
604
+ ->
605
+ C2 route width
606
+ ->
607
+ discrimination benchmark
608
+ ->
609
+ C4 enclosure efficiency
610
+ ->
611
+ C3 pathway directness
612
+ C5 group compactness
613
+ C6 obstacle cost
614
+ ->
615
+ weight decisions later
616
+ ```
617
+
618
+ ## X3
619
+
620
+ Preferred in-room circulation width is DEFERRED.
621
+
622
+ Do not invent a preferred 1500 mm in-room rule.
623
+ Do not reuse `min_common_corridor_mm = 1500` for in-room preference.
624
+
625
+ ## X4
626
+
627
+ Approved:
628
+ required functional clearance is NOT automatically dead/waste.
629
+
630
+ Examples:
631
+ - seat approach
632
+ - occupant pull-back
633
+ - circulation behind seating
634
+ - storage access
635
+
636
+ ## X5
637
+
638
+ Keep current `space_efficiency` weight during V2 measurement.
639
+ Do not change it yet.
640
+
641
+ ---
642
+
643
+ # 16. C1 STATUS
644
+
645
+ C1 = in-room residual classification.
646
+
647
+ C1 implemented:
648
+ - room interior clipped to real usable floor
649
+ - subtract furniture
650
+ - subtract partitions
651
+ - subtract door swing
652
+ - classify remaining floor
653
+ - reuse existing residual classes/settings
654
+ - reachability seeded from room door gap
655
+ - required functional clearance excluded from dead total
656
+ - weight 0
657
+
658
+ C1 implementation and zero-diff verification PASSED.
659
+
660
+ However, C1's explicit STOP condition FAILED honestly.
661
+
662
+ For four V1 candidates:
663
+ - room residual interior same area
664
+ - room residual connectivity same
665
+ - `room_residual_quality = 1.0000` for all
666
+
667
+ while `widest_mm` changed.
668
+
669
+ Reason:
670
+ rigid translation conserves leftover area and connectivity, so area/connectivity
671
+ ratios remain identical.
672
+
673
+ DO NOT patch C1.
674
+ DO NOT add a shape term to C1.
675
+ DO NOT change weights.
676
+
677
+ C1 is complete/honest but insufficient alone.
678
+
679
+ ---
680
+
681
+ # 17. CURRENT ACTIVE TASK — C2 ONLY
682
+
683
+ ## C2: in-room route-width measurement
684
+
685
+ Purpose:
686
+ - measure spatial quality C1 cannot distinguish
687
+ - measure narrowest clear route width along reachable path from room door to
688
+ required destinations
689
+ - reuse existing deterministic clearance/raster/reachability machinery
690
+
691
+ Existing primitives to reuse where possible:
692
+ - `check_in_room_circulation`
693
+ - `clear_square_width`
694
+ - clearance field
695
+ - reachability/flood machinery
696
+
697
+ C2 is a MEASUREMENT first.
698
+
699
+ Do NOT:
700
+ - create a new hard constraint
701
+ - invent preferred 1500 mm in-room standard
702
+ - reuse `min_common_corridor_mm = 1500`
703
+ - change weights
704
+ - tune metric merely to make candidates differ
705
+
706
+ If normalization needs an unsupported threshold:
707
+ - report raw width
708
+ - weight stays 0
709
+ - request domain decision later
710
+
711
+ ---
712
+
713
+ # 18. C2 FIRST TEST
714
+
715
+ Use the same four V1 kit positions that had:
716
+
717
+ ```text
718
+ score = 0.6124
719
+ room_residual_quality = 1.0000
720
+ ```
721
+
722
+ C2 must determine whether route geometry differs.
723
+
724
+ Use rendered layouts to verify numerical C2 measurement matches visible geometry.
725
+
726
+ If C2 also produces exactly one value for all four candidates:
727
+ STOP and report why.
728
+
729
+ Do not force discrimination.
730
+
731
+ ---
732
+
733
+ # 19. C2 CLEARANCE SEMANTICS
734
+
735
+ Required functional clearances are not waste.
736
+
737
+ Do not classify these as dead space merely because they are empty:
738
+ - seat approach
739
+ - pull-back
740
+ - circulation behind seating
741
+ - storage access
742
+
743
+ C2 measures route width/access quality and must not penalize compliance.
744
+
745
+ ---
746
+
747
+ # 20. C2 BOUNDARY / DOOR
748
+
749
+ C2 must remain aware of:
750
+ - actual inner-face floor boundary
751
+ - room partitions
752
+ - furniture
753
+ - door gap
754
+ - door functional zone
755
+ - pillars/obstacles
756
+
757
+ Reachability must start from the actual room door gap.
758
+
759
+ Gate remains the sole blocking authority.
760
+
761
+ C2 only measures quality.
762
+
763
+ ---
764
+
765
+ # 21. C2 FEATURE FLAG
766
+
767
+ Keep:
768
+
769
+ ```yaml
770
+ office:
771
+ objective_v2: false
772
+ ```
773
+
774
+ by default.
775
+
776
+ When ON:
777
+ - compute C1
778
+ - compute C2
779
+ - report both
780
+
781
+ but:
782
+ - C1 weight = 0
783
+ - C2 weight = 0
784
+
785
+ Therefore:
786
+ - score unchanged
787
+ - winner unchanged
788
+ - baselines unchanged
789
+
790
+ ---
791
+
792
+ # 22. C2 VERIFICATION REQUIREMENTS
793
+
794
+ After implementing C2, run:
795
+
796
+ 1. C2 unit tests
797
+ 2. full suite
798
+ 3. S0.5
799
+ 4. diversity
800
+ 5. D4 probes
801
+ 6. recipe_replay
802
+ 7. dxf_roundtrip
803
+ 8. geometry_json
804
+ 9. artifact/audit verification
805
+ 10. discrimination benchmark
806
+ 11. rendered visual report
807
+
808
+ Flag OFF:
809
+ - S0.5 = 0 differences
810
+ - diversity = 0 differences
811
+ - winner unchanged
812
+ - DXF unchanged
813
+ - measurements unchanged
814
+
815
+ Flag ON:
816
+ - C1 reported
817
+ - C2 reported
818
+ - both weights remain 0
819
+ - score unchanged
820
+ - winner unchanged
821
+
822
+ ---
823
+
824
+ # 23. PERMANENT VISUAL REPORT FOR C2+
825
+
826
+ Every C2/V2/V3/V4/V5/V6 layout report must include dimensioned rendered layouts.
827
+
828
+ For the four comparison candidates:
829
+ - same scale
830
+ - same extents
831
+ - same annotations
832
+
833
+ Show:
834
+ - shell / inner boundary
835
+ - room
836
+ - furniture
837
+ - door
838
+ - pathway
839
+ - relevant dimensions
840
+ - C1 result
841
+ - C2 result
842
+
843
+ Measurements must come from deterministic geometry.
844
+
845
+ If rendering cannot be generated:
846
+ visual verification remains UNVERIFIED.
847
+
848
+ ---
849
+
850
+ # 24. FUTURE ROADMAP
851
+
852
+ ```text
853
+ Existing Normalize / Perceive / SpaceModel EXISTING
854
+
855
+ R-3 deterministic resolver migration COMPLETE
856
+
857
+ V1 kit enumeration COMPLETE
858
+
859
+ V2 objective measurement CURRENT
860
+ C1 in-room residual COMPLETE, stop failed
861
+ C2 route width CURRENT TASK
862
+ discrimination benchmark later
863
+ C4/C3/C5/C6 later
864
+
865
+ V3 legitimate internal product alternatives later
866
+ V4 irregular enclosure later
867
+ V5 global multi-office optimization later
868
+ V6 pathway optimization later
869
+ LLM/Agent orchestration later
870
+ Vision refinement later
871
+ ```
872
+
873
+ ---
874
+
875
+ # 25. FUTURE V3 / V4 / V5
876
+
877
+ ## V3 — legitimate internal design alternatives
878
+
879
+ Only after product/domain standards are explicitly decided.
880
+
881
+ Potential pending questions include:
882
+ - owner_beside
883
+ - opposite-side beside item
884
+ - split visitor rows
885
+ - optional-item alternative placement
886
+ - daylight-driven orientation
887
+
888
+ Never invent these from general LLM knowledge.
889
+
890
+ ## V4 — irregular enclosure
891
+
892
+ Current enclosure is rectangular.
893
+
894
+ Future:
895
+ - rectilinear polygon / union of rectangles
896
+ - derived from products
897
+ - clearances
898
+ - pathways
899
+ - door access
900
+ - clipped to usable floor
901
+ - not clipped to a computational region
902
+
903
+ ## V5 — global multi-office
904
+
905
+ Future:
906
+
907
+ ```text
908
+ Customer requirements
909
+ |
910
+ +-- Office A brief
911
+ +-- Office B brief
912
+ +-- Office C brief
913
+ |
914
+ v
915
+ per-office alternatives
916
+ |
917
+ v
918
+ global combinations
919
+ |
920
+ v
921
+ backtracking
922
+ |
923
+ v
924
+ shared circulation
925
+ |
926
+ v
927
+ whole-floor objective
928
+ |
929
+ v
930
+ best valid complete floor
931
+ ```
932
+
933
+ The system must not permanently trap offices inside one region.
934
+
935
+ ---
936
+
937
+ # 26. FINAL TARGET BEHAVIOR
938
+
939
+ Ultimately the system should:
940
+
941
+ 1. Understand the real input shell.
942
+ 2. Understand the actual inner floor boundary.
943
+ 3. Understand walls, doors, windows, pillars and constraints.
944
+ 4. Understand each customer-defined office/tenant brief.
945
+ 5. Generate multiple legitimate alternatives.
946
+ 6. Move/orient products using exact integer-mm geometry.
947
+ 7. Preserve all required dimensions and clearances.
948
+ 8. Track product movement.
949
+ 9. Respect inner-shell boundary.
950
+ 10. Respect functional door constraints.
951
+ 11. Validate every candidate deterministically.
952
+ 12. Measure usable and residual space.
953
+ 13. Compare candidate layouts.
954
+ 14. Optimize single-office and multi-office floors.
955
+ 15. Derive appropriate office enclosure.
956
+ 16. Generate sensible pathways.
957
+ 17. Later use Agent + Vision to guide/refine strategy.
958
+
959
+ Ultimate objective:
960
+
961
+ > Generate and compare many legitimate, buildable layouts and select the most
962
+ > space-efficient one without sacrificing dimensional accuracy or violating
963
+ > real architectural constraints.
964
+
965
+ ---
966
+
967
+ # 27. NON-NEGOTIABLE PRINCIPLES
968
+
969
+ 1. Preserve Normalize -> Perceive -> SpaceModel.
970
+ 2. Customer requirements can differ per office.
971
+ 3. Products can differ across customer briefs.
972
+ 4. Product standards must not be invented.
973
+ 5. Geometry remains deterministic.
974
+ 6. Target geometry is integer-mm.
975
+ 7. Every movement/orientation needs a known geometric meaning.
976
+ 8. Actual inner shell face is the true boundary.
977
+ 9. Doors have functional constraints.
978
+ 10. Pillars and obstacles remain deterministic constraints.
979
+ 11. Gate is the sole blocking authority.
980
+ 12. Resolver is the geometry authority for migrated relationships.
981
+ 13. Search chooses alternatives; resolver calculates geometry.
982
+ 14. Objective ranks valid candidates; it does not validate them.
983
+ 15. Vision is supplementary.
984
+ 16. Visual reports are mandatory for layout-generation stages.
985
+ 17. Failed STOP conditions must be reported, not tuned away.
986
+ 18. Frozen baselines must not be refreshed to absorb changes.
987
+ 19. Regions/seams are not permanent architectural boundaries.
988
+ 20. Whole-floor optimization is the eventual multi-office goal.
989
+
990
+ ---
991
+
992
+ # 28. CURRENT STOP POINT / INSTRUCTION
993
+
994
+ CURRENT TASK:
995
+
996
+ **Implement C2 only.**
997
+
998
+ C1:
999
+ - implemented
1000
+ - verified
1001
+ - STOP condition failed honestly
1002
+ - no patch approved
1003
+
1004
+ V1:
1005
+ - verified and complete
1006
+
1007
+ R-3:
1008
+ - verified and complete
1009
+
1010
+ The current session MUST NOT automatically continue beyond C2.
1011
+
1012
+ Immediate instruction:
1013
+
1014
+ > C1 is approved as implemented, but its STOP condition failed as expected.
1015
+ >
1016
+ > Do NOT patch C1.
1017
+ > Do NOT add a shape term to C1.
1018
+ > Do NOT change weights.
1019
+ >
1020
+ > NEXT = C2 ONLY.
1021
+ >
1022
+ > Implement C2 as an in-room route-width measurement using existing deterministic
1023
+ > clearance/raster/reachability machinery.
1024
+ >
1025
+ > Do NOT invent a preferred 1500 mm in-room rule.
1026
+ > Do NOT reuse `min_common_corridor_mm = 1500`.
1027
+ > Do NOT create a new hard constraint.
1028
+ > Do NOT change weights.
1029
+ >
1030
+ > Test the same four V1 kit positions.
1031
+ >
1032
+ > C2 must determine whether route geometry differs.
1033
+ >
1034
+ > If C2 also produces exactly one value for all candidates:
1035
+ > STOP and report why.
1036
+ >
1037
+ > Required visual report:
1038
+ > - same scale
1039
+ > - same extents
1040
+ > - shell / inner boundary
1041
+ > - room
1042
+ > - furniture
1043
+ > - door
1044
+ > - pathway
1045
+ > - dimensions from deterministic geometry
1046
+ > - C1 result
1047
+ > - C2 result
1048
+ >
1049
+ > Keep:
1050
+ > `objective_v2 = false`
1051
+ >
1052
+ > C1 weight = 0
1053
+ > C2 weight = 0
1054
+ >
1055
+ > Run:
1056
+ > 1. C2 unit tests
1057
+ > 2. full suite
1058
+ > 3. S0.5
1059
+ > 4. diversity
1060
+ > 5. D4 probes
1061
+ > 6. recipe_replay
1062
+ > 7. dxf_roundtrip
1063
+ > 8. geometry_json
1064
+ > 9. artifact/audit verification
1065
+ > 10. discrimination benchmark
1066
+ > 11. rendered visual report
1067
+ >
1068
+ > Do NOT implement C3/C4/C5/C6, weight changes, V1b, V3, V4, V5, V6 or Agent
1069
+ > orchestration.
1070
+ >
1071
+ > STOP after C2 verification and report.
floorplan-core.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e034ac1938f2ed07312bf3e5adc594547fbb0427f59bd92dcf386fb953726137
3
+ size 2024990