====== TransSECS Host: How to Build and Use the Digital Twin ====== ===== What Is the Digital Twin in TransSECS? ===== In TransSECS, a Digital Twin is a snapshot of the tool’s model as captured during the project build. It provides a read-only, simulation-ready copy of the tool interface, separate from any host-side modifications. The **DT (Digital Twin)** becomes a tool simulator that you can use to test your host project, as you build and test the host you are making. ===== What Exactly Is Saved as the Digital Twin? ===== When a project is built, TransSECS automatically creates a folder under the project named: **DigitalTwin** This folder contains copies of key project files, but those files reflect the tool model — not the host-side logic. Although the structure may resemble the main project, the content is frozen at build time and used strictly for simulation and validation — not for active host logic. ===== Why It Looks Like a Project Copy ===== The Digital Twin folder contains familiar .xml and config files. However: * It is a mirror of the tool-side configuration * It does not reflect host-side JavaScript, triggers, or logic * It is not modified by later project updates — making it ideal for regression testing Think of it as a preserved **“Tool View”** snapshot — perfect for comparing against evolving host implementations. {{ :transsecs_host:pasted:20250731-103633.png?400|}} ===== Where Is the Digital Twin Stored? ===== The Digital Twin folder is created automatically under your project directory at build time. It remains intact even if you later: * Delete CEIDs or reports * Modify variable mappings * Adjust host scripts This allows you to roll back or validate changes against the original tool definitions. ===== Why Use the Digital Twin? ===== The Digital Twin enables you to: * Simulate tool behavior without a live connection * Reproduce mismatches between tool and host CEIDs/SVIDs * Test robustness against unknown or unexpected events * Compare changes across project versions * Debug and regression test with confidence ===== Example of Use Case Workflow ===== - Build the project with the live tool or a tool file - TransSECS automatically saves the Digital Twin - Modify the host project — e.g., delete certain CEIDs - Test using the preserved tool model to simulate missing or extra events - Analyze the host’s behavior and ensure it gracefully handles mismatches ===== Summary ===== The TransSECS Digital Twin is a powerful and convenient feature that: * Captures the tool’s interface model at build time * Preserves the original CEIDs, VIDs, reports, and metadata * Enables offline simulation, testing, and validation * Supports version control, comparison, and error scenario emulation No setup is required — the Digital Twin is created automatically. For engineers developing and refining SECS/GEM host logic, it is an essential tool for building reliable, robust systems.