YAMTL: Yet Another Model Transformation Language

12 May 2020 - Artur Boronat -

Yet Another Model Transformation Language (YAMTL) is an expressive model-to-model transformation language that is offered as an internal domain-specific language (DSL) of Java/Xtend. YAMTL was found to be the fastest incremental model transformation tool, in general, for dealing with complex transformations between AADL models according to independent industrial case study. YAMTL is available as an IDE-agnostic Java dependency that augments the Java ecosystem with model analysis and model transformation capabilities that are not yet available in the latest version of Java. YAMTL transformations can be developed, debugged and analysed using the preferred Java IDE of choice and they can build upon existing Java dependencies in order to automate complex tasks. YAMTL operates on models defined with the Eclipse Modeling Framework.

yamtl logo

Two reasons that have usually hindered the adoption of model transformation technology in industry are lack of good tool support and the ability to cope with complex transformations that may have to process very large models, with millions of objects. On the one hand, existing tools for MDE are often developed by small research teams whose main interests are to innovate or to analyse novel MDE techniques, without having resources for developing industry-standard tools. Hence, having model transfomation languages as internal DSLs of mainstream programming languages facilitates the reuse of standard IDEs and industry-level productivity tools. On the other hand, model transfomations need to add value to existing transformation processes both by enabling the integration of existing transformation logic and by providing new model transformation abstractions for developing highly performant, concise and understandable model transformations.

Furthermore, YAMTL has been shown to be as expressive as ATL and one of the most performant model transformation engines to date in several benchmarks over the past five years. Specifically, when a YAMTL transformation is executed in batch mode it shows a gain of several orders of magnitude with respect to other tools and a small memory footprint. Subject to an appropriate design of transfomation rules, incremental propagation of modifications is normally performed in real-time.

Why to use YAMTL?

Cool, what can I do in YAMTL that I cannot do in Java yet?

YAMTL helps practitioners adopt model transformations by reusing Java productivity tools, by reusing existing codebases that may already implement parts of complex model transformation processes; and by providing model transformation abstractions, like:

Can you show me some examples?

Some use cases that have already been documented are:

In addition the combination of YAMTL and Xtend is a good fit for developing declarative MODEL-TO-TEXT TRANSFORMATIONS, let me know if you want to explore this use case ;-)

Show me the code!

Using a YAMTL transformation is as easy as…

  1. Importing the YAMTL dependency in your Java project and your EMF-based metamodel projects.
  2. Declaring a model transformation. See any of the following examples:
  3. Executing the model transformation (code snippet in Xtend):
// INSTANTIATE THE TRANSFORMATION DECLARATION 
val xform = new cd2db 
// PREPARE MODELS 
xform.loadInputModels(#{'cd' -> inputModelPath}) 
// EXECUTE TRAFO 
xform.execute() 
// STORE MODELS 
var String outputModelPath = '''src/main/java/cd2db/targetInitial.xmi''' 
xform.saveOutputModels(#{'db' -> outputModelPath})

Publications

The semantics of the language can be found at (Boronat, 2018) and support for incremental execution of model transformations is presented in (Boronat, 2020).

The complete list of publications involving YAMTL is as follows: