Submitted:
05 May 2024
Posted:
07 May 2024
You are already at the latest version
Abstract
Keywords:
1. Introduction
2. Background
2.1. Architecture Diagrams
2.2. Behavioral (Activity) Diagrams
2.2. Logical Network Diagrams
2.3. Cloud Architecture Diagrams

2.4. Structural Diagrams
2.5. Other Diagram Types
- Sequence Diagrams
- Use Case Diagrams
- Deployment Diagrams
- Component Diagrams
- State Machine Diagrams
- Class Diagrams
- Package Diagrams
3. Tooling
3.1. Diagrams.net (Draw.io) and MxGraph
3.2. Draw.io VSCode Integration
3.3. Other Tool Considerations & Tool Selection
4. Methodology
- Begin with a Draw.io diagram, saved as a .drawio.png file. Those wishing to reproduce this method may use the image below as it uses this format. In this case, a simple activity diagram is used.

- 2.
- Extract the MxFile data from the image. The MxFile XML is stored as metadata in the image. This can be extracted and converted into a usable format.
- 3.
- Convert to JSON (optional). As an intermediate step, the method used in this paper converts the MxFile XML to JSON. This is done primarily for the convenience of working with JSON over XML and can be skipped if needed.
- 4.
- Convert to NetworkX. Next, data is converted into a usable model. The primary method used for the demonstration is Draw.io, but there are no technical limitations to the format at this point. With a NetworkX model, a usable format is available for analysis or visualization.

- 5.
- Infer Additional Information (optional). A final step is to infer additional information that might be useful in a model that was not present in the original diagram. This is discussed in detail later in this paper.
5. Extracting Data from Informal Artifacts
5.1. File Formats

5.2. The .drawio File Format

5.3. The .drawio.svg File Format


5.4. The .drawio.png File Format

6. Extracting Data from PNGs
6.1. Extracting the MxFile

7. Creating Models

8. Inferring Information
8.1. Geometric Inferences

8.2. Parent-Child Relationships

8.3. Other Inferences
- Traversing intermediate connections. Another example is traversing intermediate connections. This could address the need to understand the relationships in a diagram while traversing the graph (e.g. element A is linked to B is linked to C). It will be shown later in this paper that by leveraging modern graph databases, this sort of pattern can be identified without the need for making the inference manually.
- Grouping by proximity. Grouping related elements together based on proximity, within some specified tolerance, has also been suggested.
- Element type identification. Identifying different types of diagram elements can also be useful. This can be done either by adding data fields to elements or considering element style.
- Edge types / edge labels. The demonstrated approach ignores edge labels in MxGraph due to the added complexity and distraction for the core method being presented. In MxGraph, edge labels are vertices making their role in the graph more complex. In future work, it is recommended that this be reconciled and edge labels.
9. End-to-End Example
9.1. Creating the Model


9.2. Indexing with Graph Databases

9.3. Querying with Cypher



10. Results
11. Next Steps: Incorporating Artificial Intelligence to Enhance the Methodology
11.1. Methodology Evolution and Optimization
11.2. Machine Learning Integration
11.3. Innovative Aspects and Improvements
- Automation of Model Transformation: AI largely automates transforming diagrams, reducing the time and resource investment required and allowing engineers to focus on more strategic tasks.
- Enhanced Analysis Capability: AI enhances the capability to analyze complex diagrams by interpreting intricate patterns and relationships that may not be immediately apparent to human analysts.
- Scalability and Adaptability: AI algorithms can quickly adapt to new types of diagrams and scale to handle large datasets, which is crucial for enterprises with extensive systems architectures.
11.4. Practical Applications and Future Work
12. Conclusions
Author Contributions
Institutional Review Board Statement
Data Availability Statement
Conflicts of Interest
References
- Basili, V.; Briand, L.; Bianculli, D.; Nejati, S.; Pastore, F.; Sabetzadeh, M. Software Engineering Research and Industry: A Symbiotic Relationship to Foster Impact. IEEE Software 2018, 35, 44-49. [CrossRef]
- M. Richards and N. Ford. Fundamentals of Software Architecture. O'Reilly Media, Inc. https://learning.oreilly.com/library/view/fundamentals-ofsoftware/9781492043447/.
- E. Carroll and R. Malins. Systematic Literature Review: How is Model-Based Systems Engineering Justifed?. Sandia National Laboratories. 2016. [CrossRef]
- M. Ozkaya. Do the informal & formal software modeling notations satisfy practitioners for software architecture modeling? Information and Software Technology 2018, 95, 15-33. [CrossRef]
- J. Keim, Y. Schneider, and A. Koziolek. Towards consistency analysis between formal and informal software architecture artefacts. In Proceedings of the 2019 IEEE/ACM 2nd International Workshop on Establishing the Community-Wide Infrastructure for Architecture-Based Software Engineering (ECASE), 27-27 May 2019, 2019; pp. 6-12.doi: https://ieeexplore.ieee.org/document/8815606.
- Ali, N.; Baker, S.; O’Crowley, R.; Herold, S.; Buckley, J. Architecture consistency: State of the practice, challenges and requirements. Empirical Software Engineering 2018, 23, 224-258. [CrossRef]
- M. Fowler. Software Architecture Guide. https://martinfowler.com/architecture/.
- Object Management Group. OMG® Uni ed Modeling Language® (OMG UML®), Versionb2.5.1. 2023. https://www.omg.org/spec/UML/2.5.1/PDF.
- Object Management Group. OMG Systems Modeling Language™ (SysML®), Version 2.0 Beta, Part 1 Language Specification. 2023. https://www.omg.org/spec/SysML/2.0/Beta1/Language/PDF.
- JGraph Ltd.. draw.io. July 2023. https://www.drawio.com/.
- JGraph Ltd.. Github - jgraph/drawio-desktop (Source Code). July 2023. https://github.com/jgraph/drawio-desktop.
- Henning Dieterichs. Github - hediet/vscode-drawio (Source Code). July 2023. https://github.com/hediet/vscode-drawio.
- Henning Dieterichs. Draw.io Integration - Visual Studio Marketplace. July 2023.https://marketplace.visualstudio.com/items?itemName=hediet.vscode-drawio.
- JGraph Ltd. MxGraph. https://jgraph.github.io/mxgraph/.
- J. Kaplan. Agile Architecture in Practice. 2023. https://jdkaplan.com/articles/agile-architecture-in-practice.
- GCHQ. CyberChef. https://gchq.github.io/CyberChef/.
- Robinson, J. Webber, and E. Eifrim. Graph Databases, 2nd Edition. O'Reilly Media, Inc.. 2015. https://learning.oreilly.com/library/view/graph-databases-2nd/9781491930885/.
- Kassab, M.; Mazzara, M.; Lee, J.; Succi, G. Software architectural patterns in practice: an empirical study. Innovations in Systems and Software Engineering 2018, 14, 263-271. [CrossRef]
- Schilling, R.D.; Aier, S.; Winter, R. Designing an Artifact for Informal Control in Enterprise Architecture Management. In Proceedings of the ICIS, 2019, Munich, Germany, Dec 15-18, 2019.
- Object Management Group. OMG Systems Modeling Language™ (SysML®), Version 2.0 Beta. 2023. https://www.omg.org/spec/SysML/2.0/Beta1.
- Zhang, T.; Ladhak, F.; Durmus, E.; Liang, P.; McKeown, K.; Hashimoto, T.B. Benchmarking Large Language Models for News Summarization. Transactions of the Association for Computational Linguistics 2024, 12, 39-57. [CrossRef]
- Hosna, A.; Merry, E.; Gyalmo, J.; Alom, Z.; Aung, Z.; Azim, M.A. Transfer learning: a friendly introduction. Journal of Big Data 2022, 9, 102. [CrossRef]
- Zhang, L.; Bian, Y.; Jiang, P.; Zhang, F. A Transfer Residual Neural Network Based on ResNet-50 for Detection of Steel Surface Defects. Applied Sciences 2023, 13, 5260.



Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2024 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).