NX Live Control Architecture¶
Source files:
D:\02_Code\47_NXconnection\README.md,D:\02_Code\47_NXconnection\NATIVE_CPP_HOST_ARCHITECTURE.md, current Techstack operational tracking
Last synthesized: April 2026 Purpose: Explain how RapidDraft controls a real NX session for drawing review and generation, and how that runtime layer relates to the broader CAD SDK stack.
Why This Exists¶
TextCAD has two different CAD infrastructure problems that look similar from a distance but are not the same in implementation.
The first problem is headless geometry and translation: load STEP or other CAD data, analyze it, heal it, simplify it, and run deterministic geometry workflows. That is where OCCT, FreeCAD, and commercial translator SDKs matter most.
The second problem is live CAD-session control: drive the exact NX window an engineer is looking at, create or update drawing sheets, and inspect the result visually while the CAD session remains open. That is where NX Open matters.
This page documents the second layer.
Architectural Role¶
The NX live-control layer is not a replacement for the existing geometry stack.
Instead, the stack now has two complementary layers:
- Headless geometry layer
- OCCT / FreeCAD / translator SDKs
- neutral-format ingestion
-
geometry reasoning, feature extraction, DFM, and preprocessing
-
In-session CAD control layer
- NX Open host loaded into the real NX session
- live commands for opening parts, managing sheets, and creating review drawings
- Rapid Shot used as the visual verification gate after each mutating step
The important design choice is to stop pretending that all NX-driven work can be reduced to file translation. Some product workflows need the real CAD application in the loop.
Current Control Paths¶
The current D:\02_Code\47_NXconnection repo carries three NX control paths:
- Filesystem bridge
- oldest fallback path
-
useful for compatibility and debugging
-
Managed live host
- loaded once into NX
- targets the exact visible NX session
- currently the most complete review-loop path
-
already supports sheet lifecycle commands, review-sheet creation, layout updates, section-view attempts, and PDF export
-
Native NX Open C++ host
- current migration target
- uses a localhost named pipe instead of
.NETremoting - currently kernel-stage rather than review-loop complete
- already supports
ping,session_info,bridge_status,listing_message, andopen_part
Why the Long-Term Target Is Native C++¶
The managed host solved the transport question. It proved that the agent can target the exact visible NX session instead of a detached helper flow.
The remaining hard problems are deeper NX problems, especially drafting associativity and
section-view creation. Those are the places where the native NX Open C++ surface is more
attractive because:
- it is the deepest supported NX Open surface for this use case
- it sits naturally beside
Open C / UFUNC, which can be used when the higher-level drafting builders become too restrictive - it gives a stronger long-term path for treating NX as a real runtime boundary rather than a plugin-specific workaround
So the operating stance is:
- use the managed host as the working path today
- converge the architecture on the native C++ host as the long-term control surface
Relationship to the CAD SDK Decision¶
This architecture does not change the current recommendation that OCCT remains the right default headless geometry layer for TextCAD.
The better way to think about the stack is:
- OCCT / FreeCAD / translators answer: “How do we process CAD data without the CAD app?”
- NX Open live control answers: “How do we control the real NX session when the workflow must stay inside NX?”
That distinction matters because RapidDraft drawing review and generation for NX pilots is no longer purely a neutral-file problem.
Current Open Gaps¶
The native host is not yet the default path because several pieces still need to migrate:
- the full review drawing loop
- robust section-view creation
- the hardest associativity edge cases in NX drafting
The key remaining technical problem is section-view associativity. Live session control now works; the open question is how to express section definitions in the way NX drafting actually requires.
Practical Implication for Product Planning¶
This work moves NX from “one more CAD file source” to “a live runtime surface with its own control plane.” That is important for RapidDraft because some pilot workflows depend on interacting with the actual drafting environment, not only on parsing geometry offline.
In product terms, that means the CAD infrastructure story now has two bets:
- neutral geometry infrastructure for broad CAD reasoning
- native NX control for workflows that must stay inside NX
Sources¶
D:\02_Code\47_NXconnection\README.mdD:\02_Code\47_NXconnection\NATIVE_CPP_HOST_ARCHITECTURE.mdD:\02_Code\47_NXconnection\native\NxLiveHostCpp.cppC:\Users\adeel\OneDrive\100_Knowledge\203_TextCAD\01_Product_Project_Management\00_Project_Management_n_skills\01_tracks\techstack\TRACKING.mdC:\Users\adeel\OneDrive\100_Knowledge\203_TextCAD\01_Product_Project_Management\00_Project_Management_n_skills\03_decision_log\DL-006_nx-live-control-should-converge-on-native-cpp-host.md