Automatic residential floorplan generation has long been a central challenge bridging architecture and computer graphics, aiming to make spatial design more efficient and accessible. While early methods based on constraint satisfaction or combinatorial optimization ensure feasibility, they lack diversity and flexibility. Recent generative models achieve promising results but struggle to generalize across heterogeneous conditional tasks, such as generation from site boundaries, room adjacency graphs, or partial layouts, due to their suboptimal representations. To address this gap, we introduce Floorplan Markup Language (FML), a general representation that encodes floorplan information within a single structured grammar, which casts the entire floorplan generation problem into a next token prediction task. Leveraging FML, we develop a transformer-based generative model, FMLM, capable of producing high-fidelity and functional floorplans under diverse conditions. Comprehensive experiments on the RPLAN dataset demonstrate that FMLM, despite being a single model, surpasses the previous task-specific state-of-the-art methods.
Figures & tables
Figure 2: Floorplan Markup Language (FML). We represent floorplans, boundaries, and graphs in a markup manner, which unifies the various floorplan generation tasks into a single task of FML sequence generation.
Figure 3: Overview of FMLM. Similarly to LLMs, FMLM is based on a simple transformer model that is trained by next token prediction and performs autoregressive inference.
Figure 4: Floorplan completion and editing. (a) Our model complements incomplete floorplans by just starting with an incomplete sequence. (b) With this capability, our model can be incorporated into interactive editing with users.
Figure 5: Qualitative comparison with Graph2Plan and HouseDiffusion. Our model generates more consistent and realistic examples from various types of conditions, (a) boundary, (b) graph, (c) boundary and graph, than task-specific models such as Graph2Plan and HouseDiffusion. Note that Graph2Plan generates only a single floorplan for each condition. Best viewed in zoom.
Figure 6: Floorplan completion.
Figure 7: Effect of constrained decoding. Best viewed in zoom.