Skip to main content
Version: Next (nightly)

A floor plan from a file

Draw a whole home or workshop in one go: ask any AI to describe it as a cobblr-floorplan/1 file, then import the file. Rooms, levels, doors and windows, zones, and the racks, cabinets and toolboxes in each room arrive with their shelves and drawers, all at their real size.

To bring a house in:

  1. Open Locations, then the Floor Plan tab.
  2. Choose Copy a prompt for another AI, and paste it into any AI.
  3. Answer its questions about each room. It ends with one block of JSON.
  4. Choose Import a plan and paste the JSON (or pick the file).
  5. Check the preview: every room is drawn, and anything that reached outside its room has been moved inside and is outlined in red.
  6. Choose Import. Undo on the message that follows takes it all back.

Importing the same file again makes nothing new: places are matched by their name under the same parent, so fix a room in the file and import it again. Nothing that is missing from the file is deleted.

A file that does not read is listed with the line and field of each problem, for example line 5, rooms[0].w_mm: w_mm is more than 0.

Export saves a house's plan in the same format, to hand to another AI for changes and bring back.

The format​

The JSON Schema is at /schemas/cobblr-floorplan-1.json, and every Cobblr instance serves it at /api/v1/schemas/cobblr-floorplan-1.json.

  • Every measurement is a whole number of millimetres. units_entered says what you used, and Cobblr shows sizes back in it.
  • A room has its own coordinates: x to the right and y down from its top-left corner, seen from above. w_mm is its width and d_mm its depth.
  • walls are interior walls (and an outer wall that has a door or window). An opening sits on a wall, at_mm from its first end.
  • zones are named regions of a floor. containers stand on it, with their height in h_mm.
  • A container's face.shelves are its shelves, each at from_bottom_mm. Drawers or bins go in its own containers, placed on its front.
  • site holds every room; a room's level is the floor it is on.

The prompt​

This is what Copy a prompt for another AI copies:

I want a floor plan of my home or workshop as JSON in the "cobblr-floorplan/1" format, so I can import it into Cobblr. The format's JSON Schema is at https://docs.cobblr.xyz/schemas/cobblr-floorplan-1.json.

Ask me about each room one at a time until you have enough to draw it: its name, its floor or level, its size, where the doors and windows are, any interior walls, and the furniture or storage I want shown (shelving units, racks, cabinets, workbenches, toolboxes), with their sizes, where they stand, and their shelves or drawers. Use your best estimate when I'm vague, and tell me what you estimated.

Then output ONE JSON object, and nothing else, following these rules exactly:
- All measurements are integers in millimetres. Convert my feet and inches (1 in = 25.4 mm, 1 ft = 304.8 mm) and set "units_entered" to the unit I used.
- Each room has its own coordinates: x goes right and y goes down from the room's top-left corner, as if seen from above with the room's entry wall at the bottom.
- A room's "w_mm" is its width (left to right) and "d_mm" its depth (top to bottom). Its outer walls are implied; "walls" lists only interior walls, as segments from (x1, y1) to (x2, y2).
- Doors, windows and openings belong to a wall: "at_mm" is the distance from the wall's first end, "w_mm" is their width, and "kind" is "door", "window" or "opening". For an outer wall, add it to "walls" along the room's edge (e.g. y1 = y2 = d_mm for the bottom wall).
- "zones" are named regions of a room's floor (e.g. "Bench side"); "containers" are physical things that hold stuff (racks, shelves, cabinets, toolboxes), each with x_mm, y_mm (top-left corner), w_mm (width), d_mm (depth), h_mm (height) and "wall_mounted".
- A container's shelves go in "face": "shelves", each with "name" and "from_bottom_mm" (the height of the shelf's surface above the floor). Drawers or bins inside a container go in its own "containers" list, placed on its front face: x_mm from its left, y_mm down from its top, w_mm wide and d_mm tall.
- Every name must be unique within its parent. Don't invent rooms or furniture I didn't mention.

The shape:
{
"format": "cobblr-floorplan/1",
"units_entered": "ft",
"site": { "name": "House" },
"rooms": [
{
"name": "Printer room", "level": "Basement",
"w_mm": 4267, "d_mm": 3048,
"walls": [ { "x1": 0, "y1": 3048, "x2": 4267, "y2": 3048,
"openings": [ { "at_mm": 300, "w_mm": 815, "kind": "door" } ] } ],
"zones": [ { "name": "Bench side", "x_mm": 0, "y_mm": 0, "w_mm": 1500, "d_mm": 3048 } ],
"containers": [
{ "name": "Rack 1", "x_mm": 100, "y_mm": 100, "w_mm": 1220, "d_mm": 610, "h_mm": 1830,
"wall_mounted": false,
"face": { "shelves": [ { "name": "Shelf 1", "from_bottom_mm": 150 },
{ "name": "Shelf 2", "from_bottom_mm": 600 } ] },
"containers": [] }
]
}
]
}

Before the JSON, list your assumptions in one short paragraph. After it, say nothing.