From Code to Models-as-Data: GEMS, a High-Level Language for Energy System Modeling
Event Recap: FOSDEM 2026
TL;DR
At FOSDEM 2026, Antoine Oustry (RTE) presented GEMS (Generic Energy Systems Modelling Scheme), a graph-based algebraic modeling language that treats mathematical component models as data rather than software code, with the goal of enabling more flexible and maintainable energy system modeling.
From Code to Models-as-Data
Oustry opened by explaining that the word “model” can mean different things in energy system modeling. Here, the term is used to mean the abstract mathematical formulation of a type of energy system component, such as a storage unit, nuclear power plant, or transmission line.
Introducing GEMS
GEMS, or Generic Energy Systems Modelling Scheme, is a high-level language for representing energy system components and study cases.
Oustry described GEMS as a graph-based algebraic modeling language used to configure and extend mathematical models of energy system components.
Representing Energy Systems as Graphs
GEMS represents an energy system as a hypergraph.
Components are represented as vertices, while connections between components are represented through edges and ports. Component models are described separately in library files, which contain mathematical expressions, parameters, variables, ports, constraints, and objective contributions.
Separating Models from Software Code
A central theme of the presentation was separating mathematical component models from simulator code.
Oustry explained that in many modeling environments, component equations are embedded directly in the software. With GEMS, those equations become inputs that can be read dynamically to build an optimization problem.
This allows users to introduce new component types or adjust existing formulations by changing model library files rather than modifying the underlying software code.
Supporting Flexible Energy System Studies
Oustry positioned GEMS between algebraic modeling languages and object-oriented energy system modeling tools.
According to the presentation, GEMS is designed to provide mathematical expressiveness while also representing the graph structure of energy systems. Target applications include adequacy assessment, production cost simulation, and capacity expansion planning.
Maintainability and Model Evolution
Oustry described maintainability as one motivation for developing GEMS.
As users request new component types or changes to existing models, embedding each change directly in software can make the code harder to maintain. By separating mathematical formulations from simulator implementations, GEMS is intended to make models easier to evolve and maintain over time.
Interoperability Between Tools
The session also explored interoperability between energy system modeling tools.
Oustry contrasted semantic approaches, such as ontologies, with a symbolic approach focused on sharing the mathematical formulation behind a study case. He described GEMS as a way to share study cases with the information needed to reproduce simulations, while recognizing that solution workflows may remain tool-specific.
Connecting with PyPSA
Oustry presented ongoing work to connect PyPSA study cases with the GEMS ecosystem.
The team built a converter from a PyPSA network to a GEMS study case, with the goal of testing the expressiveness of the language and building bridges between modeling communities. Oustry said early comparison work produced the same objective value between PyPSA and the GEMS interpreter for supported components, while noting that the work remains in progress.
Looking Ahead
Oustry concluded by describing GEMS as a project that began nearly three years earlier, first with a Python prototype and later with integration into Antares Simulator.
Future work includes developing a data interface for GEMS objects, adding language features, expanding PyPSA compatibility, and exploring new collaborations around tool interoperability, reference model libraries, and graphical interfaces.
AI Disclosure
This post used artificial intelligence tools for research, structural assistance, or grammatical refinement. The final content was reviewed, edited, and validated by human contributors to LF Energy to ensure accuracy and alignment with our community standards. We remain committed to transparency in the use of generative technologies within the open source ecosystem.