How an 8-dimensional autoencoder turns 24 raw environmental simulations into an explainable diagnostic tool for real-estate agents and a precedent-search engine for renovation architects.

Program: Master in AI for Architecture & the Built Environment (MaAI), IAAC Barcelona
Team 5: Breno Sader, Diego Alpízar, Sindhuja Davuluri, Soumya Datta
Stack: PyTorch · ONNX Runtime · Gradio · Hugging Face · Render · Cloudflare Pages, Functions & D1

Resources: Live Web App  ·  Hugging Face Model Card  ·  Model Server

Figure 1: The Quiet & Bright Twin Finder web application and interactive 50-listing Portfolio Explorer.

01 · The Invisible Problem in Residential Data

When evaluating an apartment, square footage and room count are easy to read—but the qualities that actually define livability are far harder to parse. Traffic noise at the window, equinox sunlight penetration, sky viewshed, and spatial layout interact in complex, non-linear ways. Even when rich environmental simulations exist, they typically arrive as disjointed, multi-column spreadsheets that nobody in a real-world workflow has time to decode.

Quiet & Bright Twin Finder asks a focused question: Can a single lightweight neural network learn what a ‘normal’ apartment looks like across acoustics, sunlight, views, and layout—flag the units that deviate—and immediately retrieve better-performing architectural twins?

To ground the tool in real AEC workflows, we designed the experience around two distinct user stories:

  • The Real-Estate Agent (‘Is this listing abnormal—and why?’): Instead of relying on gut feeling or a 24-column spreadsheet, the agent needs a clear verdict paired with an explainable breakdown of which environmental domain drives the issue so they can communicate transparently with clients.
  • The Renovation Architect (‘Show me normal apartments like this one’): Once a unit is flagged, the architect needs 3 to 5 real reference precedents of comparable size (±25% floor area, ±2 rooms) that perform strictly better on every flagged domain—something impossible to query manually across tens of thousands of plans.

02 · From 367,678 Rooms to 24 Standardized Signals

Our pipeline builds on the Swiss Dwellings v3 dataset, which starts at the room level: 367,678 room rows across 369 columns. Rather than feeding raw, noisy tables into a model, we engineered a clean apartment-level representation:

  • Feature Selection & Aggregation: We extracted 35 core columns and grouped them by apartment (using mean, max, and sum aggregations), condensing the dataset into 44,195 multi-room apartments described by 24 standardized inputs across four environmental domains: Acoustics (8), Sunlight (6), Views (5), and Layout (5).
  • Leakage-Free Splitting: Apartments in the same building share acoustic and solar conditions. To prevent data leakage, we split the dataset 70/15/15 using GroupShuffleSplit by building and fit our StandardScaler strictly on the training set.
  • Proxy Labels for Evaluation: Because real-world renovation records are not included in the dataset, we defined a 15% proxy noise benchmark (>P90 indoor traffic, >P92 window noise, >P95 train noise) solely to evaluate how well our unsupervised models isolate severe acoustic outliers.

Figure 2: Data engineering pipeline transforming 367,678 room-level rows into 44,195 apartment-level training tensors across 24 environmental features.

03 · Teaching an Autoencoder What ‘Normal’ Looks Like

Because an autoencoder compresses inputs through a narrow bottleneck and tries to reconstruct them, a model trained on normal apartments will struggle to faithfully rebuild an abnormal one. That reconstruction error—mean((x − x̂)²) across the 24 standardized inputs—becomes our anomaly score.

We trained and benchmarked three compact architectures for 35 epochs (Adam optimizer, learning rate 1e-3, batch size 256, MSE loss, ReLU activations with linear output) to find the sweet spot between compression and reconstruction fidelity:

Table 1: Benchmark comparison of three autoencoder architectures evaluated on the Swiss Dwellings v3 test split (DenseAE-8 selected).

DenseAE-8 outperformed both the tighter 4D bottleneck and the 1D convolutional alternative, delivering the lowest test MSE (0.072) and highest ROC AUC (0.742) with just 7,904 parameters. We set our decision threshold at the 95th percentile (P95) of normal validation error: 0.1799. Any apartment scoring above 0.1799 is flagged as an unusual profile.

04 · One Bottleneck, Two Workflows

The core strength of DenseAE-8 is that a single forward pass powers both user stories:

  • Explainable Diagnostics (Agent View): Instead of returning a black-box flag, we break total reconstruction error down by domain. Take Site 3879 · Building 6051 (99.1 m², 9 rooms, Floor 4) from our live catalog: it returns a reconstruction score of 0.3693—2.05× the normality cutoff. The domain breakdown immediately tells the story: Acoustics accounts for 73.8% of the deviation (76.6 dBA window traffic), followed by Layout (17%), Views (8%), and Sunlight (1%).
  • Constrained Latent-Space Twin Search (Architect View): When switching to architectural precedents, the app uses the 8-dimensional bottleneck (z ∈ ℝ⁸) as a spatial-environmental fingerprint. First, it filters all 44,195 apartments to keep only units within ±25% floor area and ±2 rooms that satisfy the user’s selected upgrade priorities (such as −10 dBA quieter acoustics, brighter equinox sun, or wider sky and greenery viewshed). Filters are never relaxed. Next, it encodes an improved target vector into the 8D latent space and ranks surviving candidates by L2 distance. In practice, a noisy 69.1 dBA query retrieves comparable twins measuring 50.0, 47.1, and 54.7 dBA.

Figure 3: Single-pass inference—reconstruction error drives the Agent anomaly verdict while the 8-dimensional bottleneck drives the Architect twin search.

Figure 4: Live evaluation of Site 3879 · Building 6051, displaying the Spatial Bubble Topology & Environmental Halo alongside the 2.05× threshold gauge and 4-domain error breakdown.

05 · Designing the Interface: Making Metrics Spatial

Environmental data should not feel like a tax form. Inside the web application, users can browse an interactive 50-listing Portfolio Explorer—filterable by model-flagged ‘Need Renovation’ and ‘Market Ready’ labels—or expand the full panel to inspect and tweak all 24 environmental measurements directly.

To bridge raw numbers and architectural intuition, every selected apartment renders an illustrative Spatial Bubble Topology & Environmental Halo, placing room clusters inside concentric acoustic ripples, a warm solar halo, and a viewshed horizon.

Figure 5: End-to-end user journey from login or team access through Agent diagnostics and Architect twin retrieval.

06 · Full-Stack Architecture: From Edge to ONNX

Rather than leaving the model inside a notebook, we deployed Quiet & Bright Twin Finder as a resilient, end-to-end web application distributed across four cloud services:

  • Frontend & Edge API (Cloudflare Pages + Functions): Serves the static interface, handles session authentication (individual user registration/login or shared team-password entry), validates all 24 inputs before inference, and proxies requests to the ML server.
  • Model Hosting (Hugging Face Hub): Publishes the exported anomaly_ae.onnx model weights alongside the 44,195-apartment reference catalog.
  • Inference Engine (Render + Gradio + ONNX Runtime): Executes DenseAE-8 inference and constrained latent-space search. To handle free-tier cold starts gracefully, the frontend implements a bounded automatic retry loop (up to 6 attempts within 120 seconds) with a clear wake-up status message.
  • Dual Persistence (Cloudflare D1 SQLite): Two separate SQLite databases persist user accounts (team5-swiss-users) and inference logs (team5-swiss-dwellings-db), assigning each successful run a unique record ID.

Figure 6: System architecture connecting the browser SPA, Cloudflare Edge & D1 SQLite, Render ML server, and Hugging Face Hub.

Figure 7: Live read-only Wrangler query of the Cloudflare D1 predictions table verifying persisted anomaly scores and threshold verdicts.

07 · Reading the Model Honestly & What Comes Next

A responsible AI tool for architecture must be as transparent about its boundaries as its capabilities. Throughout the interface and documentation, we highlight three key caveats:

  • Precision vs. Recall: DenseAE-8’s precision of 0.81 means a flag is reliable when triggered. However, a recall of 0.21 means a ‘normal’ score is not a certification of quietness.
  • Proxies, Not Physical Inspections: Interface labels such as ‘Market Ready’ and ‘Need Renovation’ reflect model flags against simulated proxy thresholds—not verified acoustic testing or property surveys. Likewise, a latent-space twin is a performance precedent, not an identical floor plan or an available listing.
  • Privacy-First Persistence: Evaluations are logged privately in D1, but user-facing history reloading is intentionally disabled in the current UI; refreshing the page clears the visible report.

Looking ahead, two clear next steps stand out:

  • 1. Validate Twins with Real Users: Put the recommended spatial twins in front of practicing real-estate agents and renovation architects to test whether latent-space neighbors feel genuinely comparable—and genuinely better—in real design workflows.
  • 2. Production-Ready Access: Expand authentication with email verification, password recovery, and opt-in user history dashboards.

Credits & Project Links

Quiet & Bright Twin Finder (Swiss Dwellings) was developed by Team 5 — Breno Sader, Diego Alpízar, Sindhuja Davuluri, and Soumya Datta — for AI Methods I in the Master in AI for Architecture & the Built Environment (MaAI) at IAAC Barcelona. Explore the live web application or inspect the published ONNX model on Hugging Face.