Standard Perpetual $799 – Freelance architects Floor-plan Compiler + Geometry Builder (PlanVec JSON Schema v5.0)
Wickerson Studios Floor-plan Compiler + Geometry Builder (PlanVec JSON Schema v5.0)
Standard Perpetual $799 – Freelance architects / small studiosScript 1 + Script 2 (full pipeline)
Wickerson Studios’ Floor Compiler + Geometry Builder is a two-stage pipeline that converts a 2D floor plan image into a strict, structured JSON “PlanVec” and then turns that data into clean Rhino/Grasshopper geometry—walls, openings, rooms, and connectivity—ready for downstream modeling.
Script_01 – Floor-Plan Generation
Full Version 5.0 (Wickerson Studios)
What this system is
Script_01 is a production-grade floor-plan vectorization engine written entirely in C# for Grasshopper. It converts a single raster floor-plan image into a fully structured, room-aware vector model with walls, doors, windows, labels, and room polygons — without hallucination, confidence inflation, or geometric conflicts.
Version 5.0 represents a major architectural maturity point: the system now reasons room-by-room, resolves opening–wall conflicts deterministically, and outputs schema-strict PlanVec JSON suitable for CAD, BIM, and web pipelines.
Core Capabilities (V5.0)
- Wall segmentation + ordered wall chains
- Door detection (swing-aware, wall-anchored)
- Window detection (thin-line + exterior bias)
- Room polygon generation (Rooms LOD)
- Room naming + conservative room typing
- Label extraction and spatial mapping
- Multi-pass refinement (topology → openings → labels)
- Binary free-space analysis for room inference
- Deterministic IDs and stable ordering
- Honest confidence scoring (no boosting)
- Rhino / Grasshopper coordinate correctness (+Y up)
Architectural Complexity (High-Level)
Pipeline stages:
- Image ingestion & preprocessing
- Upscaling, binarization, edge extraction
- Multi-scale image analysis
- Full image
- Overlapping grid crops
- Edge strips
- Corner zooms
- Room tile crops
- LLM-driven reasoning (3 passes)
- Pass 1: Global wall topology
- Pass 2: Topology refinement & chain quality
- Pass 3: Openings, windows, labels
- Room LOD generation
- Closed-loop wall inference
- Binary free-space fallback
- Polygon simplification
- Label-to-room assignment
- Geometry normalization & conflict resolution
- Ortho snapping
- Micro-segment cleanup
- Opening-on-wall validation
- Corner avoidance
- Automatic repair or safe removal
- Strict schema serialization
- Responses API json_schema enforcement
- PlanVec + Rooms LOD
- Web export pack
- Debug + logs
Why Version 5.0 is Important
- First room-aware release
- Eliminates door/window vs wall conflicts
- No mirrored or flipped geometry
- Deterministic, auditable output
- Stable enough for production use
- Designed for future extensions:
- room adjacency
- multi-story plans
- furniture LOD
- BIM export
Script 2 — Geometry Builder (STEP_FP_02_VECTOR_HI_LOD, PNG-LOCKED)
This script is the “data-to-geometry” engine. It takes PlanVec JSON (or the full EngineState from Script 1) and reconstructs the floor plan as Rhino geometry.
Key capabilities:
- Segment-first wall construction: Prefers wall_segments + wall_chains (most robust) and falls back to legacy wall polylines if needed.
- Correct opening placement via chain parameterization: Uses wall_chain_id + t0/t1 so door/window cutters land correctly along the chain polyline—stable even after snapping/cleanup.
- Topology cleanup: Snaps endpoints to detected corner IDs, optionally rectifies near-orthogonal segments, and cleans polylines.
- Model-ready solids: Generates wall Breps, door/window cutters, optional door swings and window assemblies (frames/glass/mullions), and optional boolean cuts.
- Space + adjacency enrichment: Auto-fills missing boundary segment IDs, can infer spaces from labels inside closed chains (low confidence), and can rebuild adjacency by connecting spaces through doors.
Together, these scripts turn messy 2D drawings into a stable, inspectable PlanVec JSON contract and then into editable, parametric Rhino geometry—a reliable bridge from image evidence to CAD/BIM-ready modeling.
Downloadable README
I generated a readme.txt describing the pipeline, schema concepts, inputs/outputs, key knobs, and troubleshooting.
Wickerson Studios — Floor Compiler + Geometry Builder
JSON Schema v1.0 (PlanVec)
OVERVIEW
This toolchain turns a 2D floor plan image (PNG/JPG or HTTPS URL) into a strict, machine-readable vector “PlanVec” JSON payload, then converts that payload into clean Rhino/Grasshopper 3D geometry (walls, doors, windows, rooms, and adjacency).
It is built as two Grasshopper C# script nodes:
1) Script 1 — Floor Compiler (STEP_FP_06z)
• Ingests an image (remote URL or local file).
• Calls OpenAI’s Responses API with a strict JSON Schema (v1.0).
• Produces a PlanVec JSON object containing walls, segments/chains, openings, labels, spaces, and adjacency.
• Emits “requirements” (units, wall/door/window defaults, snapping/boolean preferences) for downstream modeling.
• Uses deterministic seeds + caching to avoid repeat API calls.
2) Script 2 — Geometry Builder (STEP_FP_02_VECTOR_HI_LOD, PNG-LOCKED)
• Reads PlanVec JSON (or the EngineState from Script 1).
• Maps UV coordinates (0..1 image space) into Rhino world space using a base plane + unit width/depth.
• Builds per-segment wall solids, door/window cutters, optional door/window geometry, room slabs, and adjacency curves.
• Repairs and enriches topology: corner snapping, chain parameterization (t0/t1), auto boundary_segment_ids, and optional adjacency rebuild.
─────
WHAT YOU GET (OUTPUTS)
Script 1 outputs:
• PLAN_VEC_JSON_OUT: Strict PlanVec JSON (Schema v1.0)
• STATE_OUT: EngineState JSON (includes merged config, requirements, metadata, logs)
• CFG_MERGED_OUT / SFG_OUT: merged configuration + notes
• LLM_JSON_OUT: raw model output (already schema-shaped)
• LOG / DEBUG: diagnostics
Script 2 outputs (Rhino/Grasshopper geometry + updated JSON):
• WallBrepsOut, WallCurvesOut
• DoorCuttersOut, DoorBrepsOut, DoorSwingCurvesOut
• WindowCuttersOut, WindowBrepsOut
• GlassBrepsOut, MullionBrepsOut (optional modeling features)
• RoomBrepsOut, RoomCurvesOut
• AdjacencyCurvesOut (space-to-space connectivity)
• LabelPtsOut, LabelTextOut
• OverlayCurvesOut (fit box + guide curves)
• PLAN_VEC_JSON_OUT_UPDATED (PlanVec after topology fixes/inference)
• LOG / DEBUG
─────
PLANVEC JSON (SCHEMA v1.0) — CORE IDEAS
PlanVec uses FULL-IMAGE UV coordinates in [0..1] for all points.
Key elements:
• fit: UV bounding box describing where the usable plan area sits in the image.
• corners: stable corner IDs + UV positions to snap segments.
• wall_segments: explicit segment endpoints + corner references + chain membership.
• wall_chains: ordered lists of segment IDs (open or closed), used to parameterize openings.
• doors/windows: openings with either endpoints (a/b) OR chain parameterization (wall_chain_id + t0/t1).
• labels: room/space text and positions.
• spaces: rooms/spaces linked to boundary chains and segment lists, plus optional loops.
• adjacency: graph edges connecting spaces through doors.
• confidence/notes: per-object + global confidence and human-readable notes.
Why chains + t0/t1 matter:
Openings placed on a chain via t0/t1 remain stable even when endpoints are snapped/cleaned. Script 2 recomputes
chain polyline length and uses t0/t1 to precisely place door/window cutters on the correct wall.
─────
WICKERSON STUDIOS – FLOOR PLAN GENERATION PIPELINE
SCRIPT_01 – FULL VERSION 5.0
========================================
OVERVIEW
--------
Script_01 is a production-grade Grasshopper (C#) floor-plan vectorization engine.
It converts a single raster PNG/JPG floor-plan image into a fully structured,
machine-readable PlanVec model suitable for CAD, BIM, web viewers, and downstream
analysis.
Version 5.0 represents a major architectural milestone: room-aware, conflict-free,
multi-pass, schema-strict, and confidence-honest.
CORE CAPABILITIES
-----------------
• Wall topology extraction (segments + ordered chains)
• Door detection (swing-aware, wall-anchored)
• Window detection (thin-line, module, exterior bias)
• Room polygon generation (LOD: rooms)
• Room labeling and typing (BED, BATH, KITCHEN, etc.)
• Label extraction (text → spatial mapping)
• Confidence scoring (no artificial boosting)
• Full UV [0..1] coordinate system
• Rhino/GH +Y-up compatibility (V-axis correction)
ARCHITECTURE
------------
The system is intentionally multi-stage and conservative.
1. IMAGE INGEST
- Local or remote image support
- Pixel inspection and size logging
- Optional upscaling, binarization, and edge extraction
2. MULTI-SCALE CROPPING
- Full image
- Grid crops (overlapping)
- Edge strips
- Corner zooms
- Room-tile crops from free-space
3. LLM PASSES
PASS 1 – Global topology
• Walls, major chains, obvious openings
PASS 2 – Topology refinement
• Segment completeness, chain continuity
PASS 3 – Openings & labels refinement
• Doors, windows, text, symbols
4. ROOM LOD GENERATION
- Closed-loop wall chains → candidate rooms
- Binary free-space tiles → fallback rooms
- Polygon simplification and filtering
- Label-to-room assignment
- Room typing (conservative heuristic)
5. NORMALIZATION & VALIDATION
- UV clamping
- Ortho snapping
- Micro-segment removal
- Opening-to-wall validation
- Conflict resolution (doors/windows vs corners/walls)
- Deterministic ID assignment
6. CONFIDENCE HANDLING
- Raw confidence from model
- No scaling or inflation
- Strict clamping only
7. OUTPUT
- plan_vec JSON (strict schema)
- rooms LOD polygons
- web-export JSON pack
- debug + log streams
DATA MODEL (SIMPLIFIED)
-----------------------
plan_vec
├─ fit (UV bounding box)
├─ wall_segments
├─ wall_chains
├─ doors
├─ windows
├─ rooms
├─ labels
├─ confidence
└─ notes
Each entity:
• Fully explicit geometry
• Confidence per item
• Notes for auditability
KEY DESIGN PRINCIPLES
---------------------
• Image is the only source of truth
• Never hallucinate geometry
• Prefer omission over invention
• Resolve conflicts deterministically
• Schema correctness over flexibility
• Debuggability over opacity
WHY VERSION 5.0 MATTERS
-----------------------
• Room-aware (true spatial understanding)
• Conflict-free openings
• Stable, repeatable output
• Production-safe schema enforcement
• Ready for CAD, BIM, and web pipelines
• Designed for extension (adjacency, levels, furniture)
INTENDED USE
------------
• Architectural plan digitization
• CAD/BIM preprocessing
• AI-assisted drafting workflows
• Web-based plan viewers
• Research and prototyping
AUTHORSHIP
----------
Wickerson Studios
https://www.wickersonstudios.com
Script Series: Script_01 – Floor Plan Generation
Version: 5.0 (Room LOD, Conflict-Free)
─────
SCRIPT 2 — GEOMETRY BUILDER (STEP_FP_02_VECTOR_HI_LOD) DETAILS
Purpose:
Turn PlanVec JSON into Rhino geometry, while repairing and enriching topology for modeling.
Highlights:
• Segment-first wall building
- Prefers wall_chains + wall_segments (Script01d/Schema v1.0)
- Falls back to walls[].segments or walls[].pts for older payloads
• Corner snapping + ortho cleanup
- If corners exist, endpoints snap to corner UVs for crisp joins.
- Optional ortho rectify snaps near-orthogonal segments.
• Correct opening placement
- Uses wall_chain_id + t0/t1 when present, ensuring doors/windows land correctly after snapping.
- Uses thicknessAtChainT for local thickness-based cutters.
• Boolean-ready wall solids
- Optional boolean difference to cut doors/windows from walls.
• Spaces + adjacency enrichment
- Auto-fills boundary_segment_ids from boundary_wall_chain_id.
- If spaces are missing, infers spaces from labels inside closed chains (low confidence).
- Rebuilds adjacency via doors when missing or forced.
Inputs (Script 2):
• Run (bool)
• PLAN_VEC_JSON_IN (recommended) OR STATE_IN (EngineState from Script 1)
• BasePlaneIn (mapping plane)
• FitAspect, FitMarginPct
• OrthoSnap, OrthoSnapDeg
• MinSegLen
• DoBooleans
• MakeDoorGeometry, MakeWindowGeometry, MakeRoomBreps
• ForceRebuildAdjacency
─────
TROUBLESHOOTING
• “No openings detected”:
- Keep cropEnable=true and cropMode=2 (9-grid).
- Increase detailBias (e.g., 1.8–2.5).
- Ensure max_output_tokens are high enough (Script 1 already sets high budgets).
• Local image too large (>12MB):
- Downscale or provide an HTTPS URL.
• Doors/windows appear misplaced:
- Ensure wall_chain_id + t0/t1 are present; Script 2 is designed to use these.
- Turn on snapCorners for more stable topology.
• Weird over-detection (“runaway”):
- The compiler rejects extreme cases, but lowering detailBias can help.
- Reduce temperature to ~0.10–0.18 for more determinism.
─────
NOTES
• Coordinates in PlanVec are UV [0..1] of the FULL IMAGE.
• Geometry mapping uses unitW/unitD + fit box scaling to place plan in world space.
• This pipeline is “image-first”: it prefers measured evidence (image/crops) over hints.
Wickerson Studios — www.wickersonstudios.com
Pricing Structure
Pricing reflect both one-time license and subscription models, depending on buyer type.
One-Time License (Perpetual)
For users who want a standalone, lifetime license for the tools:
TierPriceWho It’s ForWhat’s Included
Basic Perpetual $299 – Individual designers / studentsScript 1 only (PlanVec JSON output)
Standard Perpetual $799 – Freelance architects / small studiosScript 1 + Script 2 (full pipeline)
Professional Perpetual $1,499 – Firms / power usersAll features + lifetime minor updates + priority support