kilazi. blog
AI agents

From hand-drawn floor plans to AI agents that draw maps

Floor plans, zoning bylaws, masterplans: the same craft since 2019. Only the hands on the mouse changed.

The short answerAI agents can now turn floor plans, zoning bylaws and masterplan images into maps people can query. From 2019 to 2024 I built a browser editor where office floors were traced by hand; then AI read a city bylaw into 56 zoning districts; then agents digitised masterplans and checked official land-registry maps for 19,744 lots. An agent even revived my old editor, with fake data, in about 40 minutes.

For years I built the tool people used to draw office floors by hand: one rectangle per desk, one click at a time. Now AI agents do the drawing, and my maps hold 19,744 lots. I write the rules and check their homework.

The 45-second promo: from drawing desks by hand to agents drawing 19,744 lots.

Same craft the whole way through: I turn drawings and rules into maps people can use. Floor plan, zoning bylaw, masterplan: each starts as a picture or a pile of legal text and ends as shapes you can click and software can query.

What changed is who holds the mouse.

Then: by hand

A demo office floor in the Floor Plan Editor, with a meeting room being drawn along dashed snapping guides
Floor Plan Editor, revived with a fake office. One room, one polygon, one click at a time.

Now: by agents

A gated community rendered in 3D: lagoons, roads and over a thousand lot polygons
1,217 lots drawn by agents from one flat masterplan image, checked by a second crew.
2019 to 2026one thread, three chapters
708bylaw parameters extracted by AI
56zoning districts read by AI
1,217lots from one image, zero mismatches on review
19,744lots across 64 communities
~40 minto revive FPE and film both apps
  1. 2019At Pangeam I build FPE, a floor plan editor in the browser.
  2. 2024Years of floors traced by hand in it, then lit up with occupancy data.
  3. 2025A zoning platform: AI reads a city's land-use bylaw into structured rules.
  4. 2026tubarrio: agents digitise masterplans and verify cadastre maps, 19,744 lots.
  5. 2026An agent revives FPE and films both apps with fake data in about 40 minutes.

What is a floor plan editor, and why was drawing the bottleneck?

A floor plan editor turns a picture of a floor into geometry: rooms, doors and desks as shapes with names and types. Without that, sensor data is just dots.

Pangeam put its own sensors in offices. They could tell you where something happened. To say which desk, which room, how busy, someone first had to draw every floor. Drawing was the bottleneck, and I built the pencil.

FPE, the Floor Plan Editor, was a lightweight CAD in the browser, built on Mapbox GL Draw. Upload a floor image, trace the perimeter, draw rooms and desks with custom snapping, assign people, export GeoJSON and PDF. Then the same editor painted the analytics on top.

The demo office with an occupancy heatmap glowing over 60 workstations
The payoff: once the floor is geometry, the sensor data has somewhere to land. Synthetic occupancy, fake office.

Every desk became data: type, usage, assets. Every desk also cost a human a few clicks. Multiply by floors, by buildings, by customers. You see the problem.

Can AI read a zoning bylaw?

Yes, well enough to check a building against, as long as every rule keeps a link to its source.

Chapter two: a zoning-feasibility platform for a client. It answers what every developer asks before paying an architect: can I build this here? The usual method is reading the land-use bylaw by hand, then phoning a planner.

So I had AI read it. A scraper walked the bylaw and Gemini pulled out 56 districts and 708 parameters, flagging conflicts instead of smoothing them over. Then you draw a building on a real parcel, extrude it in 3D, cast winter shadows and get a compliance report on setbacks, height, coverage and floor-area ratio.

A citywide map with 13,713 development permits coloured by status
The citywide view: 13,713 development permits from public open data, coloured by status.

Same move as FPE, different bottleneck: last time the drawing, this time the legal text.

How do AI agents turn a masterplan into a map?

They split the job like a careful human would: one pass finds the shapes, one reads the numbers, one looks again, and an independent crew checks until the errors hit zero.

Chapter three is tubarrio, my portal of Buenos Aires gated communities. Developers sell lots from a flat render; buyers can't search a picture. One masterplan image became 1,217 numbered lot polygons, checked 1,242 times by a 10-agent QA panel. Zero mismatches. The saga, including two AIs confidently agreeing on the same wrong number, is in the lot map post.

Then it scaled. A second pipeline pulls real lot polygons from the provincial cadastre (the official land-parcel register) and refuses to publish a community unless the geometry matches the registry. Of 439 registered communities, 63 passed. Strict grader. Merge two that turned out to be one, add the masterplan builds: 64 communities, 19,744 lots.

One workflow, 64 communities, counting up to 19,744 real lots.

In 2020, one floor took a person an editor session. In 2026, I write the rules and the agents argue over the pixels.

How long does it take to revive an old codebase?

With an agent doing the digging: about 40 minutes for two apps, fake data included.

For my portfolio, I wanted real footage of FPE, a project from, in my own words, "YEARS ago before AI age". The code was pure 2019: TypeScript 3.6, webpack 4, Mapbox GL 1.3. Nobody runs that for fun.

So I wrote a ticket and handed it to a Codex worker, an AI coding agent that takes one ticket and grinds. The rules: no network call to the old company, no real people, no client branding, never push anything. Forty minutes later it reported back with both apps running and captured.

What it actually did:

  • Fixed the fossil. Swapped the dead node-sass for Sass and turned on the legacy OpenSSL option an old webpack needs.
  • Faked the backend. A tiny local mock stood in for the old API, the fake floor went in through the app's own GeoJSON loader, and the browser blocked every call to the old company.
  • Built an office that never existed. 89 features: a perimeter, 12 rooms, 12 doors, 60 desks, two cores and two zones. Plus four fake employees. Then fake occupancy, so the heatmap had something to glow about.
  • Anonymised the zoning app. Client branding swapped for a generic name at capture time; original repo untouched.
FPE running again: drawing a room with snapping, selecting a zone, then the occupancy heatmap. All data synthetic.

Better than fast, it was honest. No working 3D editor in that revision, so no 3D shot claimed. Old console errors stayed in the log. A parcel typed as 2,130 m² but measuring 2,101 m² from the geometry: left visible and written down. The worker's own label: "a private demonstration capture, not a production restoration." Correct.

What changed between hand-drawn floor plans and agents that draw?

Same job, new staff. I used to build the pencil; now I set the rules, and agents segment, read, look again, arbitrate and loop until the errors stop.

It's also how I pitch now: no deck, just a small working thing built on their problem (build the demo before you pitch). When reviving a 2019 app takes 40 minutes, "let me show you" is cheaper than "let me explain".

Here's what a masterplan looks like once it stops being a picture:

The Santa Clara lot map: once a JPEG, now 1,217 polygons. Type any lot number. Open full screen

At Pangeam I built the pencil. Now the pencils draw, and I hold the red pen.

Want AI agents that actually ship?

I build AI agents and the systems around them for businesses: memory, voice, overnight rigs, and the boring guards that make them safe to leave alone.

Talk to me on WhatsAppmax@kilazi.com

Questions people ask

Can AI convert a floor plan image into editable geometry?

Yes, with checks. Colour segmentation and vision models can find walls, rooms and labels in an image and output polygons, typically as GeoJSON. The first pass is the easy part. Proving it right is the job: an independent pass should compare every shape and label against the original image before anyone builds on it.

What is GeoJSON and why do maps use it?

GeoJSON is an open standard (RFC 7946) for describing points, lines and polygons with properties in plain JSON. Web map libraries like Mapbox GL read it directly, so a room, a parcel or a lot becomes something you can click, filter, measure and query instead of pixels in a picture.

Can AI tell me what I am allowed to build on a parcel?

It can give you a fast first answer. AI can read a land-use bylaw into structured rules (setbacks, height, coverage, floor-area ratio) and check a drawn building against them on a map. Treat it as a feasibility estimate with source links to every rule, not as a planning approval.

How do you revive an old JavaScript project without the original backend?

Pin or replace the dead build tools (node-sass to Sass, the legacy OpenSSL option for old webpack), stub the API with a small local mock that returns fixture data, block every outbound request you do not control, and feed the app synthetic data through its own loaders so the real UI renders.

Do you need a GIS team to get an interactive lot map?

Often not. If official cadastre geometry exists, a pipeline can pull it and verify it against the registry; if all you have is a masterplan image, agents can digitise it. You still need someone to set the rules and refuse to publish anything that fails them.

Max Sergeev

Max Sergeev. Max builds AI agents and the systems around them: long-term memory, voice, overnight rigs, and the boring guards that make them safe to leave alone. He runs kilazi labs from Buenos Aires. kilazi.com

Sources

  1. RFC 7946: The GeoJSON Format (IETF)
  2. Online Land Use Bylaw (City of Calgary)
  3. Indoor Mapping Data Format (OGC)
  4. mapbox-gl-draw (Mapbox, GitHub)