FreeCAD Plumbing Designer
Big Deal
Study this thread, which describes the steps for full CAD automation of design using part libraries. This applies to generating modules, assemblies, and final modifications - fully automated by schemas and compilers. One just runs compilers to regenerate new iterations of design. This is based on plumbing, which has an extra layer of complexity over structure in terms of more complicated mating surfaces and part orientations.
https://chatgpt.com/share/69784c9d-969c-8010-8eea-339e43a4811d
Concept 1
This is a concept procedure for complete CAD automation -
- I can generate schemas for all plumbing library parts, parametrized.
- Schemas are compiled, parts generated in CAD.
- CAD library can be uploaded to Chat
- Chat generates an assembly schema, whene I provide the parts and orientations in human language.
- I compile the schema for final assembly.
- To place in the house - i provide human languege for geometry - where plumbing starts and ends. This is a structured “constraints + adjustables” spec.
- I upload the full house file
- Chat provides a compilable schema which generates the final insertion of plumbing into house.
- Chat provides a compiler.
- I run compiler locally, providing CAD file + constraint schema.
- I get a final CAD file- which shows properly in FreeCAD
- From here I can get technical drawings and BOM automatically.
Declarative Plumbing CAD Pipeline (Schema → Assembly → Installation)
This document defines the canonical, robust process for designing, assembling, and installing plumbing systems using parametric schemas, automated compilation, and CAD backends (e.g. FreeCAD).
The system treats plumbing as a compiled artifact, not a hand-edited drawing. This procedure applies to all modules/systems, not just plumbing.
1. Generate schemas for all plumbing library parts (parametric)
Each plumbing part is defined by a long-lived, design-time schema.
Each part schema includes:
- Parametric dimensions (length, diameter, schedule, etc.)
- Named ports defined as Local Coordinate Systems (LCS / Datum CS)
- A clear part interface contract (required ports, parameters, orientation rules)
This is the part definition layer.
The schema is the source of truth. Geometry is not edited directly.
2. Compile schemas → generate CAD parts
Part schemas are compiled into CAD artifacts (e.g. .FCStd).
- Compiled CAD parts are authoritative library artifacts
- They are disposable and fully regenerable
- No manual edits are required or expected
Schema = source CAD file = compiled artifact
3. CAD library provided to Chat
Canonical part definitions are provided to Chat via:
- Representative
.FCStdexamples - Or a subset of parts plus the formal part interface contract
Chat uses these to:
- Learn port names and conventions
- Validate compatibility
- Generate correct assembly logic
The full library does not need to be re-uploaded once conventions are fixed.
4. Assembly topology schema generated from human language
Human-language instructions such as:
Use a 90° elbow, connect a 10-inch pipe to each side, then a tee.
are translated into a topology schema containing:
- Instance IDs
- Part types (from the library)
- Port-to-port connections
- Default parameters
- Optional roll/orientation rules
This schema defines pure topology. There is no site placement or house context at this stage.
5. Compile topology schema → local assembly
The topology schema is compiled into a local plumbing assembly:
- All parts are instantiated
- All ports are mated
- The assembly exists in its own local coordinate frame
This assembly is:
- Reusable
- Portable
- Independent of any specific building
6. Provide installation geometry constraints (human language → structured spec)
To place the plumbing in a building, installation constraints are provided, including:
- Start penetration pose (location + direction)
- End penetration pose (location + direction)
- Slope requirements (e.g. gravity drainage)
- Declaration of adjustable components (pipes, slip joints, telescoping sections)
This becomes the structured constraints + adjustables specification.
Human language is acceptable; it is compiled into a formal constraint schema.
7. Upload full house CAD file
The house CAD model provides:
- Real geometry
- Wall and floor reference frames
- Penetration locations
The plumbing assembly remains independent.
Plumbing is not edited into the house; it is placed into the house.
8. Generate solved assembly schema for final insertion
Using:
- The topology schema
- The constraints + adjustables spec
- The house geometry
Chat produces:
- A solved assembly schema including:
- Root placement transform
- Solved pipe lengths
- Resolved elbow rolls (if required)
- Or directly produces a FreeCAD Python macro (compiler output)
At this stage, the system is fully determined and unambiguous.
9. Run compiler locally
The compiler is executed locally with:
- Part library CAD files
- Solved assembly schema
- House CAD file
This ensures:
- Determinism
- Local control of execution
- Isolation from CAD version differences
This is the correct trust boundary.
10. Generate final CAD assembly
The output is a final CAD file that:
- Opens correctly in FreeCAD
- Is fully parametric
- Is regenerable
- Contains no broken constraints
The plumbing is correctly placed within the house model.
11. Generate downstream artifacts automatically
Because:
- Parts are structured
- Assemblies are explicit
- Ports and parameters are known
The following are generated automatically:
- Technical drawings
- Bills of Materials (BOM)
- Cut lists
- QA checklists
These are downstream artifacts, not manual work.
Required invariants (non-negotiable)
This pipeline is correct if and only if the following invariants are enforced:
- Ports are always defined as LCS / Datum Coordinate Systems
- Assemblies are built by port mating, not face-based constraints
- Topology ≠ placement ≠ installation
- Schemas are the source of truth
- CAD files are compiled artifacts
- Adjustable components are explicitly declared
- Solving occurs before CAD placement
These invariants guarantee robustness, regeneration, and long-term scalability.