Floorplan Classification and Data Extraction Pipeline using AI - n8n Workflow

An advanced n8n workflow for automated floorplan validation and data extraction using AI classification (JigsawStack) and heuristic scoring. Filters low-quality uploads to save costs.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

• Businesses or individuals needing to process a high volume of CAD drawings, blueprints, or floorplans.
• Technical teams looking for robust, cost-effective pre-filters for expensive OCR and measurement APIs.
• Automation specialists seeking a complex, multi-path n8n workflow example utilizing AI and core logic flow control.
• Users interested in building custom n8n templates for document analysis.

Overview

This sophisticated automation acts as a smart validation gateway for uploaded documents, specifically designed to process floorplans. By implementing a multi-stage filtering process—starting with essential checks like GDPR consent and file size limits—it ensures that only high-quality, relevant documents proceed to costly AI measurement steps. The core of this n8n workflow involves calculating a preliminary confidence score for PDF files based on heuristics (keyword detection like room names, area units, technical symbols) or using JigsawStack for image classification. This approach, built entirely within an n8n node sequence, drastically reduces API spending by dropping irrelevant uploads early. This comprehensive n8n workflow demonstrates how to combine core n8n node functionality with external AI services to create highly reliable data pipelines.

How it Works

The n8n workflow begins execution immediately upon receiving a file upload via the Webhook – Receive Upload n8n trigger.


  1. Initial Validation: The automation first checks for GDPR consent. If consent is missing, the n8n workflow stops and returns a rejection message. Valid files are then prepared by the Process – Multiple File Uploads code n8n node, which ensures multi-file inputs are handled correctly.

  2. File Type Routing: The Check – File Type n8n node splits the flow based on whether the input is a PDF or an Image (JPG, PNG).

  3. PDF Path (Heuristics): If it’s a PDF, the n8n workflow extracts text and metadata. It performs checks for size and page limits. The crucial Analyze – Confidence Score n8n node then applies heuristics (searching for technical keywords like ‘m²’ or ‘keuken’) to assign a confidence score (0.0–1.0) indicating how likely the document is a floorplan.

  4. Image Path (AI Classification): If it’s an Image, the file is uploaded to JigsawStack for temporary storage and then sent to the JigsawStack Classification API to determine if it is a 'floorplan' or 'not floorplan'.

  5. Confidence Routing: The Route – Confidence Levels n8n node (a Switch node) directs the flow based on the heuristic score:

Less than 40%: Immediately rejected (Respond – Low Quality/Drop).
40% to 85%: Routed for AI text classification (Classify – PDF Text) as uncertain, often leading to a manual review response.
* 85% or higher: Considered high quality and moves to the ‘Continue to JIG Note’ section, ready for full measurement extraction in a subsequent phase of this powerful n8n workflow.

This intelligent routing mechanism, powered by multiple n8n node interactions, ensures an efficient and cost-effective automation strategy.

Installation Guide


  1. Import the n8n workflow: Copy the provided JSON and import it into your n8n instance (Self-hosted or Cloud) by navigating to 'Workflows' > 'New' > 'Import from JSON'.

  2. Setup Credentials: This n8n workflow requires credentials for JigsawStack (HTTP Header Auth) and basic authentication for the Webhook n8n trigger.

JigsawStack: Create a new HTTP Header Auth credential in n8n. Use 'Authorization' as the Header Name and your JigsawStack API Key (prefixed with 'Bearer ') as the Header Value.
Webhook Authentication: The Webhook – Receive Upload n8n trigger is protected by basic authentication (stucstunter.nl). Update this credential to match your required security settings.

  1. Activate: Ensure all nodes are configured correctly and activate the n8n workflow. The webhook URL will be active and ready to receive POST requests containing binary file uploads.

Node Details

This n8n workflow heavily relies on custom logic and API interaction:

Webhook – Receive Upload (n8n trigger): Starts the n8n workflow upon a POST request to the /fp-mvp path. Crucial for handling file uploads as binary data. Uses Basic Auth for security.
Check – GDPR Consent (If n8n node): Essential logic flow control. Checks if the GDPR_check field is present in the request body. Gates the process based on consent before file processing begins.
Process – Multiple File Uploads (Code n8n node): Transforms incoming binary file data into multiple items, standardizing the format (fileName, mimeType, fileKey) for subsequent n8n node usage, supporting both single and bulk uploads.
Extract – PDF Metadata/Text (Extract From File n8n node): Specifically configured to extract text from PDF files, enabling heuristic text analysis on documents before calling expensive AI services.
Analyze – Confidence Score (Code n8n node): The core intelligence for PDF routing. This n8n node runs custom JavaScript to scan the extracted text for specific floorplan indicators (like 'woonkamer' or 'm²') and calculates a weighted confidence score, which is then used by the next n8n node.
Route – Confidence Levels (Switch n8n node): Manages the flow control based on the confidence score generated by the previous n8n node, routing files to 'Drop', 'Manual Review', or 'Auto-Process'. This is a prime example of complex flow control in an n8n workflow.
Upload – JigsawStack (HTTP Request n8n node): Handles secure temporary storage of images and PDFs, a necessary step before sending files to most cloud-based classification APIs that require a public URL. This is critical for the image processing path.
Classify – Image Files / PDF Text (HTTP Request n8n node): Sends data (public URL for image, extracted text for PDF) to the JigsawStack Classification API to determine if the content is a 'floorplan'.

Related n8n Workflows

Free

Nodes: 9 Nodes
Updated: December 26 2025
View all
Created by

Account Executive by day , Noco builder for fun at night and always a proud dad of Togo the Samoyed.

Featured*