LANGDEV MEETUP, MARCH 21-22, 2019, AMSTERDAM, NL
BREATHE LIFE INTO YOUR IDE
BENOIT COMBEMALE
PROFESSOR, UNIV. TOULOUSE, FRANCE
HTTP://COMBEMALE.FR
BENOIT.COMBEMALE@IRIT.FR
@BCOMBEMALE
BENOIT COMBEMALE
PROFESSOR, UNIV. TOULOUSE & INRIA, FRANCE
HTTP://COMBEMALE.FR
BENOIT.COMBEMALE@INRIA.FR
@BCOMBEMALE
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
Model Execution: Why Should I care?
▸ Various engineering: software engineering, systems
engineering, enterprise architecture, scientific
modeling...
▸ Various domains: Business Processes, Orchestrations,
Functional chains, Activities, Protocols, Scenarios...
▸ Various objectives: dynamic analysis, design-space
exploration, tradeoff analysis, models@runtime
breathe life into your
(domain-specific) behavioral models
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
Model Execution: Main Challenges
• A behavioral model is a structural description of an intended
behavior
• Challenge: how to support modelers in bridging the gap between
the model structure and the corresponding behavior, over the
time
• (some) Expected facilities ?
• debug the execution results (i.e. runtime state) instead of the model itself
• consider the dimension of time natively (if not already reified in the
model, e.g. message sequence charts)
• bridge the gap between the model execution and its interpretation within
a particular domain (e.g., moldable debugger [Chis et al.])
• ease the understanding of the impact of a model change
3
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
Model Execution: Main Challenges
• A behavioral model is a structural description of an intended
behavior
• Challenge: how to support modelers in bridging the gap between
the model structure and the corresponding behavior, over the
time
• (some) Expected facilities ?
• debug the execution results (i.e. runtime state) instead of the model itself
• consider the dimension of time natively (if not already reified in the
model, e.g. message sequence charts)
• bridge the gap between the model execution and its interpretation within
a particular domain (e.g., moldable debugger [Chis et al.])
• ease the understanding of the impact of a model change
4
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
The GEMOC Studio
5
Model Animator
Operational Semantics
(executable)
Model
(executable)
Modeling
Language
Metamodeling
LanguagesKermeta Ecore
aModel
trace
manager,
timeline,
control
panel,
omniscient
debugger
Concrete Syntax
Graphical
representation
Sirius
Graphical
representation
DSA Executor
Interpreter
Diagram
Model Editor
Diagram
Domain-Specific
Actions
Execution
Functions
Execution
Data
Abstract Syntax
Domain Model
(Metamodel)
Legend
code generation
<<dependsOn>>
<<conformsTo>>
ALE
https://eclipse.org/gemoc
ALE
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 6
▸ An Action Language for EMF [EclipseCon’17]
▸ To complement an Ecore metamodel with Runtime Data and Eoperation impl.
▸ To define any Interpreter, compiler, model transformation, analysis tools…
▸ ALE extends AQL (Acceleo Query Language)
▸ Provides side effects and additional complex control structures
▸ Main characteristics:
▸ Interpreted (though, a compiler also exist)
▸ Static typing, type inference
▸ Open class support
▸ Contributed to Eclipse EcoreTools
▸ Define behavior over an Ecore metamodel
▸ Modular specification (thanks to Sirius layers and open class)
▸ Integrated into the Eclipse GEMOC Studio
▸ Binding to the debug UI, control panel and trace manager
Coulon’s PhD,
Obeo & Inria
https://github.com/gemoc/ale-lang
http://gemoc.org/ale-lang
open class arduino.If {
@step
def void execute() {
if (self.condition.evaluate()) {
self.block.execute();
} else {
if (self.elseBlock != null) {
self.elseBlock.execute();
}
}
}
}
LANGDEV’18
SiriusAnimator
Animator
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
LANGDEV’18
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
https://github.com/gemoc/arduinomodeling
ArduinoDebugger
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
ActivityDiagramDebugger
https://github.com/gemoc/activitydiagram
9
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
PacMan!
10
- 11
HIGH PERFORMANCE COMPUTING
in collaboration with
Fostering metamodels and grammars within a dedicated environment for HPC: the NabLab environment
Benoît Lelandais, Marie-Pierre Oudot, Benoît Combemale
In International Conference on Software Language Engineering (SLE), 2018
- 12
HIGH PERFORMANCE COMPUTING
in collaboration with
- 13
HIGH PERFORMANCE COMPUTING
in collaboration with
in collaboration with
Current technical limitations:
• technical integration of Monaco, JupyterLab and the
language server
• Integration of Monaco in notebook’s cells
• syntax highlighting not supported by LSP
• collaborative editing
Ongoing work:
• automatic generation of REPL language servers
• graphical representation based on Sirius on the web
- 14
WATER FLOOD PREDICTION
in collaboration with
A. Cheron, Master Thesis, 2017
- 15
WATER FLOOD PREDICTION
in collaboration with
J. Sallou, PhD, 2018-…
Description / documentation of
the simulation process
Code of one step of the
simulation process
Visualization of the simulation
results
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
Towards Live Modeling
• Model execution and debugging ease the
understanding of the actual behavior that
describes a given model
• But are limited for understanding the impact of a
model change in the resulting behavior
17
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019
Some Scenarios for Live Modeling
Live coding
Design Space
Exploration
Tradeoff analysis &
Decision making
Arts
Computational
Sciences
Engineering
Digital twins
Rationales for Live Modeling
▸ Focus on executable modeling, where:
▸ the model(s) gathers the data and the behavior
▸ the model(s) conforms to a gray box operational semantics
▸ Live modeling should support the following main scenarios:
▸ Immediate feedback: changes at runtime of the model structure
(data or behavior)
▸ Direct manipulation: changes at runtime of the model state
▸ Additional scenarios: change at runtime of the input scenario, the
language semantics…
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 19
Live Modeling: Towards a Conceptual Model
▸3 dimensions of abstraction:
▸ structure (data/behavior)
▸ state
▸ time
▸Immediately observe the impact on the model state
▸ surimposition on top of the running model
▸ through specific views of the model state, and over the time
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 20
(BretVictor,http://worrydream.com)
Live Modeling: Processes
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 21
GEMOC Engine
(executable)
Model
(executable)
Modeling
Language
Metamodeling
Languages
ALE Ecore
MyDSML
.ale
MyDSML
.ecore
aRunningModel
VM
Model
State
AST
aRunningModel
Model
State
AST
Change on the model (AST):
• Compute the delta
• Check delta validity (e.g.,
conformity)
• Reconcile delta (i.e., compute
how to apply it to the static
model, and apply it)
• Reflect the syntactic delta in
the model state
Change on the model state:
• Compute the delta
• Check delta validity (e.g.,
conformity)
• Reconcile delta
NB: checking vs. reconciliation?
Breathe life into your…
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 22
▸ Operational Semantics
▸ Static introduction
with open classes
▸ Kermeta v1, v2, v3 and
ALE
metamodel
model execution
designer
animation and debug
IDE
live modeling
2005 2012 2018
▸ Execution trace
management
▸ Forward/backard step-
by-step execution
▸ GEMOC Studio
▸ Immediate feedback &
direct manipulation
▸ Reconciliation operators
▸ Extending LSP, GSP &
DAP
Pierre-Alain Muller, Franck Fleurey,
Jean-Marc Jézéquel: Weaving
Executability into Object-Oriented Meta-
languages. MoDELS 2005: 264-278
Erwan Bousse, Thomas Degueule, Didier
Vojtisek, Tanja Mayerhofer, Julien DeAntoni,
Benoît Combemale: Execution framework of the
GEMOC studio (tool demo). SLE 2016: 84-89
Jean-Marc Jézéquel, Benoît Combemale, Olivier Barais, Martin
Monperrus, François Fouquet: Mashup of metalanguages and
its implementation in the Kermeta language workbench.
Software and System Modeling 14(2): 905-920 (2015) …
Live Modeling: (some) Open Challenges
▸Model change:
▸ what to open to modification in the model and the model state?
▸ explicit language interfaces (similarly to debugging)
▸ how to ensure the validity of the changes?
▸Reconciliation operators:
▸ Pattern, techniques and heuristics for reconciliation operators?
▸ when can we reconcile or restart?
▸Impact visualization:
▸ what to open to visualization?
▸ Live modeling over related, heterogeneous, models
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019 23
Breathe life into your IDE
Abstract.
Live modeling brings facilities to enhance modeling environments with immediate feedback
(from changes on the model to the runtime state, and possibly the execution trace), and direct
manipulation (from changes on the runtime state to the model). Such facilities are helpful in
tuning specific solutions, exploring design spaces, or performing tradeoff analysis. Hence, live
modeling have a growing appeal among very different stakeholders, ranging from software
and systems engineers, to scientists, decision makers, artists or the general public.
After a brief introduction of several case studies illustrating the different scenarios expected by
language users, I explore in this talk live modeling from the point of view of a language
engineer. I describe a general approach to bring this new concern in the specification of
domain-specific languages. Then I explore the underlying challenges, review the current
initiatives, and propose a research roadmap.
As take away messages, the audience will learn about live modeling and how to support it in
the development of domain-specific languages. A description of the current initiatives, the
open challenges and an associated research roadmap is given to help the community in future
investigations.
LangDev Meetup @ Amazon
Benoit Combemale, March, 2019

Breathe Life Into Your IDE

  • 1.
    LANGDEV MEETUP, MARCH21-22, 2019, AMSTERDAM, NL BREATHE LIFE INTO YOUR IDE BENOIT COMBEMALE PROFESSOR, UNIV. TOULOUSE, FRANCE HTTP://COMBEMALE.FR BENOIT.COMBEMALE@IRIT.FR @BCOMBEMALE BENOIT COMBEMALE PROFESSOR, UNIV. TOULOUSE & INRIA, FRANCE HTTP://COMBEMALE.FR BENOIT.COMBEMALE@INRIA.FR @BCOMBEMALE
  • 2.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 Model Execution: Why Should I care? ▸ Various engineering: software engineering, systems engineering, enterprise architecture, scientific modeling... ▸ Various domains: Business Processes, Orchestrations, Functional chains, Activities, Protocols, Scenarios... ▸ Various objectives: dynamic analysis, design-space exploration, tradeoff analysis, models@runtime breathe life into your (domain-specific) behavioral models
  • 3.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 Model Execution: Main Challenges • A behavioral model is a structural description of an intended behavior • Challenge: how to support modelers in bridging the gap between the model structure and the corresponding behavior, over the time • (some) Expected facilities ? • debug the execution results (i.e. runtime state) instead of the model itself • consider the dimension of time natively (if not already reified in the model, e.g. message sequence charts) • bridge the gap between the model execution and its interpretation within a particular domain (e.g., moldable debugger [Chis et al.]) • ease the understanding of the impact of a model change 3
  • 4.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 Model Execution: Main Challenges • A behavioral model is a structural description of an intended behavior • Challenge: how to support modelers in bridging the gap between the model structure and the corresponding behavior, over the time • (some) Expected facilities ? • debug the execution results (i.e. runtime state) instead of the model itself • consider the dimension of time natively (if not already reified in the model, e.g. message sequence charts) • bridge the gap between the model execution and its interpretation within a particular domain (e.g., moldable debugger [Chis et al.]) • ease the understanding of the impact of a model change 4
  • 5.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 The GEMOC Studio 5 Model Animator Operational Semantics (executable) Model (executable) Modeling Language Metamodeling LanguagesKermeta Ecore aModel trace manager, timeline, control panel, omniscient debugger Concrete Syntax Graphical representation Sirius Graphical representation DSA Executor Interpreter Diagram Model Editor Diagram Domain-Specific Actions Execution Functions Execution Data Abstract Syntax Domain Model (Metamodel) Legend code generation <<dependsOn>> <<conformsTo>> ALE https://eclipse.org/gemoc
  • 6.
    ALE LangDev Meetup @Amazon Benoit Combemale, March, 2019 6 ▸ An Action Language for EMF [EclipseCon’17] ▸ To complement an Ecore metamodel with Runtime Data and Eoperation impl. ▸ To define any Interpreter, compiler, model transformation, analysis tools… ▸ ALE extends AQL (Acceleo Query Language) ▸ Provides side effects and additional complex control structures ▸ Main characteristics: ▸ Interpreted (though, a compiler also exist) ▸ Static typing, type inference ▸ Open class support ▸ Contributed to Eclipse EcoreTools ▸ Define behavior over an Ecore metamodel ▸ Modular specification (thanks to Sirius layers and open class) ▸ Integrated into the Eclipse GEMOC Studio ▸ Binding to the debug UI, control panel and trace manager Coulon’s PhD, Obeo & Inria https://github.com/gemoc/ale-lang http://gemoc.org/ale-lang open class arduino.If { @step def void execute() { if (self.condition.evaluate()) { self.block.execute(); } else { if (self.elseBlock != null) { self.elseBlock.execute(); } } } } LANGDEV’18
  • 7.
    SiriusAnimator Animator LangDev Meetup @Amazon Benoit Combemale, March, 2019 LANGDEV’18
  • 8.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 https://github.com/gemoc/arduinomodeling ArduinoDebugger
  • 9.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 ActivityDiagramDebugger https://github.com/gemoc/activitydiagram 9
  • 10.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 PacMan! 10
  • 11.
    - 11 HIGH PERFORMANCECOMPUTING in collaboration with Fostering metamodels and grammars within a dedicated environment for HPC: the NabLab environment Benoît Lelandais, Marie-Pierre Oudot, Benoît Combemale In International Conference on Software Language Engineering (SLE), 2018
  • 12.
    - 12 HIGH PERFORMANCECOMPUTING in collaboration with
  • 13.
    - 13 HIGH PERFORMANCECOMPUTING in collaboration with in collaboration with Current technical limitations: • technical integration of Monaco, JupyterLab and the language server • Integration of Monaco in notebook’s cells • syntax highlighting not supported by LSP • collaborative editing Ongoing work: • automatic generation of REPL language servers • graphical representation based on Sirius on the web
  • 14.
    - 14 WATER FLOODPREDICTION in collaboration with A. Cheron, Master Thesis, 2017
  • 15.
    - 15 WATER FLOODPREDICTION in collaboration with J. Sallou, PhD, 2018-… Description / documentation of the simulation process Code of one step of the simulation process Visualization of the simulation results
  • 16.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 Towards Live Modeling • Model execution and debugging ease the understanding of the actual behavior that describes a given model • But are limited for understanding the impact of a model change in the resulting behavior 17
  • 17.
    LangDev Meetup @Amazon Benoit Combemale, March, 2019 Some Scenarios for Live Modeling Live coding Design Space Exploration Tradeoff analysis & Decision making Arts Computational Sciences Engineering Digital twins
  • 18.
    Rationales for LiveModeling ▸ Focus on executable modeling, where: ▸ the model(s) gathers the data and the behavior ▸ the model(s) conforms to a gray box operational semantics ▸ Live modeling should support the following main scenarios: ▸ Immediate feedback: changes at runtime of the model structure (data or behavior) ▸ Direct manipulation: changes at runtime of the model state ▸ Additional scenarios: change at runtime of the input scenario, the language semantics… LangDev Meetup @ Amazon Benoit Combemale, March, 2019 19
  • 19.
    Live Modeling: Towardsa Conceptual Model ▸3 dimensions of abstraction: ▸ structure (data/behavior) ▸ state ▸ time ▸Immediately observe the impact on the model state ▸ surimposition on top of the running model ▸ through specific views of the model state, and over the time LangDev Meetup @ Amazon Benoit Combemale, March, 2019 20 (BretVictor,http://worrydream.com)
  • 20.
    Live Modeling: Processes LangDevMeetup @ Amazon Benoit Combemale, March, 2019 21 GEMOC Engine (executable) Model (executable) Modeling Language Metamodeling Languages ALE Ecore MyDSML .ale MyDSML .ecore aRunningModel VM Model State AST aRunningModel Model State AST Change on the model (AST): • Compute the delta • Check delta validity (e.g., conformity) • Reconcile delta (i.e., compute how to apply it to the static model, and apply it) • Reflect the syntactic delta in the model state Change on the model state: • Compute the delta • Check delta validity (e.g., conformity) • Reconcile delta NB: checking vs. reconciliation?
  • 21.
    Breathe life intoyour… LangDev Meetup @ Amazon Benoit Combemale, March, 2019 22 ▸ Operational Semantics ▸ Static introduction with open classes ▸ Kermeta v1, v2, v3 and ALE metamodel model execution designer animation and debug IDE live modeling 2005 2012 2018 ▸ Execution trace management ▸ Forward/backard step- by-step execution ▸ GEMOC Studio ▸ Immediate feedback & direct manipulation ▸ Reconciliation operators ▸ Extending LSP, GSP & DAP Pierre-Alain Muller, Franck Fleurey, Jean-Marc Jézéquel: Weaving Executability into Object-Oriented Meta- languages. MoDELS 2005: 264-278 Erwan Bousse, Thomas Degueule, Didier Vojtisek, Tanja Mayerhofer, Julien DeAntoni, Benoît Combemale: Execution framework of the GEMOC studio (tool demo). SLE 2016: 84-89 Jean-Marc Jézéquel, Benoît Combemale, Olivier Barais, Martin Monperrus, François Fouquet: Mashup of metalanguages and its implementation in the Kermeta language workbench. Software and System Modeling 14(2): 905-920 (2015) …
  • 22.
    Live Modeling: (some)Open Challenges ▸Model change: ▸ what to open to modification in the model and the model state? ▸ explicit language interfaces (similarly to debugging) ▸ how to ensure the validity of the changes? ▸Reconciliation operators: ▸ Pattern, techniques and heuristics for reconciliation operators? ▸ when can we reconcile or restart? ▸Impact visualization: ▸ what to open to visualization? ▸ Live modeling over related, heterogeneous, models LangDev Meetup @ Amazon Benoit Combemale, March, 2019 23
  • 23.
    Breathe life intoyour IDE Abstract. Live modeling brings facilities to enhance modeling environments with immediate feedback (from changes on the model to the runtime state, and possibly the execution trace), and direct manipulation (from changes on the runtime state to the model). Such facilities are helpful in tuning specific solutions, exploring design spaces, or performing tradeoff analysis. Hence, live modeling have a growing appeal among very different stakeholders, ranging from software and systems engineers, to scientists, decision makers, artists or the general public. After a brief introduction of several case studies illustrating the different scenarios expected by language users, I explore in this talk live modeling from the point of view of a language engineer. I describe a general approach to bring this new concern in the specification of domain-specific languages. Then I explore the underlying challenges, review the current initiatives, and propose a research roadmap. As take away messages, the audience will learn about live modeling and how to support it in the development of domain-specific languages. A description of the current initiatives, the open challenges and an associated research roadmap is given to help the community in future investigations. LangDev Meetup @ Amazon Benoit Combemale, March, 2019