Incorporating Uncertainty into Bidirectional Model Transformations and their Delta-Lens Formalization

Zinovy Diskin, Romina Eramo, Alfonso Pierantonio, Krzysztof CzarneckiBx@ETAPS 2016

Abstract

Bidirectional model transformations (bx) are critical for maintaining consistency between synchronized models in Model-Driven Engineering. However, existing frameworks often necessitate deterministic synchronization strategies at design time, which can be overly restrictive when multiple valid updates exist. This paper introduces a formal categorical extension to the delta-lens framework that incorporates uncertainty. By utilizing "incomplete models" to intentionally represent sets of possible solutions through logical constraints, the framework enables deferred decision-making and runtime refinement. We define uncertain model spaces (u-spaces and uu-spaces) and demonstrate that "uu-lenses" provide a mathematically rigorous foundation for non-deterministic synchronization, treating consistency restoration as a progressive uncertainty-reduction process.

Introduction

In Model-Driven Engineering, keeping related models—such as high-level architectures and low-level implementations—in sync is a recurring challenge. When one model is updated, the "view update problem" arises: there are typically multiple ways to propagate that change back to the source model to restore consistency. Traditional "lens" frameworks require developers to define a single, deterministic "put" policy upfront. This rigidity is problematic when the optimal policy is unknown at design time or requires human intervention at runtime. This paper addresses these limitations by formalizing uncertainty within the delta-lens framework.

Methods

The proposed framework shifts the focus from the transformation logic to the model spaces it operates on. The authors introduce two key constructs: u-spaces (spaces of uncertain models) and uu-spaces (spaces allowing for uncertain updates).

Standard delta-lens synchronization cycle showing the 'put' operation.

Standard delta-lenses, as illustrated in Figure 4, consist of a get (forward) and put (backward) operation. In the authors' extended "uu-lens" framework, the put operation maps a view update to a "completion delta" in the source space. Instead of returning a single concrete model, the transformation can return an incomplete model.

An incomplete model (A'1) representing uncertainty via salary ranges and logical constraints.

As shown in Figure 5, an incomplete model ($A'_1$) uses intentional representations—such as attribute ranges (e.g., salary = [65..85]) and logical constraints (e.g., $C_1: e3.salary + e4.salary <= 150$)—to encode a set of possible "full completions." This allows the system to remain in a valid, albeit uncertain, state until further information or user input narrows down the choices.

Key Insights and Ideas

  • Uncertainty as a Process: Synchronization is viewed as a continuous process of reducing uncertainty rather than a discrete, one-time event. Design-time ambiguity is preserved and translated into manageable runtime choices.
  • Intentional vs. Extensional: Rather than generating an exhaustive set of all possible models (extensional), the framework uses a single model with embedded constraints (intentional). This approach is significantly more efficient for automated tools and more comprehensible for users.
  • Algebraic Elegance: By redefining model spaces to include uncertainty, the core synchronization operations can remain single-valued. This allows the framework to leverage the existing algebraic machinery of traditional lenses while supporting non-deterministic outcomes.

Key Results

The paper provides a rigorous categorical definition of "well-behaved" uncertainty spaces and lenses. A major theoretical contribution is the establishment of a Galois correspondence for models and updates, linking syntactic logical theories with semantic sets of completions. The authors also prove that "uu-lenses" are essentially equivalent to multi-valued update policies, providing a sound mathematical foundation for their approach.

Limitations and Future Work

While theoretically robust, the authors note that the current formal framework is somewhat complex and suggest that a bicategorical approach might offer future simplifications. Additionally, there is a need for practical user interface representations of uncertainty, such as feature models. Future research will focus on integrating "uu-lenses" into production-grade bidirectional transformation tools to evaluate their performance in real-world software engineering workflows.

Summary updated

BibTeX
@inproceedings{diskin2016incorporating,
  author = {Zinovy Diskin and Romina Eramo and Alfonso Pierantonio and Krzysztof Czarnecki},
  title = {{Incorporating Uncertainty into Bidirectional Model Transformations and their Delta-Lens Formalization}},
  booktitle = {Bx@ETAPS},
  year = {2016},
  url = {https://openreview.net/forum?id=LEL8gR_71XMx},
}
Figure