We present GDF, a Gamification Design Framework for designing gamified applications through model-driven engineering mechanisms.
The framework is based on a set of well-defined modelling layers that start from the definition of the main gamification elements, followed by the specification on how those elements are composed to design games, and then progressively refined to reach concrete game implementation and execution.
The layers are interconnected through specialization/generalization relationships such that to realize a multi-level modelling approach. The approach is implemented by means of JetBrains MPS, a language workbench based on projectional editing, and has been validated through two gameful systems in the Education domain.
This work has been accepted at MODELS’19 (22nd International Conference on Model Driven Engineering Languages and Systems) and a live demonstration plus a related poster will be presented during the conference (check the program of the Conference and come to see GDF in action). Moreover, a prototype implementation of GDF and related artefacts are available at the demo GitHub repository, while an illustrative demo of the framework features and their exploitation for the case studies are shown with a video (you can also download the preprint versions of the main conference or demo paper).
This is a joint work by Antonio Bucchiarone – (Fondazione Bruno Kessler (FBK), Trento, Italy), Antonio Cicchetti – (IDT Department, Mälardalen University, Västerås, Sweden) and Annapaola Marconi – (Fondazione Bruno Kessler (FBK), Trento, Italy). See a video of the tool or keep reading for more details!
Introduction and Motivations
Gamification is gaining popularity in all those domains that would benefit from an increased engagement of their target users . Therefore, gamification applications are found in disparate contexts, such as education , , health and environment , , , e-banking , just to mention a few. The growing adoption of gamified solutions made their design and development increasingly complex, due to e.g. the number and variety of users, and the mission criticality of some of the applications. Therefore, in general a rigorous development process is recommended to avoid the gamification project to fail , .
An important challenge in the development and evolution of gameful systems is the ability to revise or introduce new game elements and mechanics during the system execution. This is needed in situations when the players’ attention decreases or when the impact of the realized system is not as expected. In most of the current approaches, the design, analysis and revision of gameful systems required a lot of development activities often unrelated to each other, with the use of various general purpose languages (i.e., java, rule/based, etc..). The different actors involved (i.e., domain expert, system developer, impact managers, etc..), were using different languages and tools to execute their tasks with a completely different understanding of the game concepts and their relations. This has led to managing unexpected game deviations with ad-hoc and not reusable solutions, making the monitoring and review of the game mechanics and dynamics a very difficult task.
In order to tackle the complexity of gamification design we propose a Gamification Design Framework (GDF). The framework provides a modular approach that can be customized for different gameful systems and is composed of a well-defined set of languages for designing a game, its main components, and the behavioural details. As a first validation, we re-designed and deployed a real gamification application in the education domain.
The Gamification Design Framework
The GDF architecture has been specified and is composed by different modelling layers, each of which defined on the basis of the layer above; moreover, utility layers are orthogonal to the others in the sense that they can be defined on the basis of any of them.
Gamification is generally referred to as the use of elements characteristic of games in non-game contexts . Therefore, the top layer of this architecture is represented by a core language defined to introduce the essential elements to describe a gameful system. The top component of the architecture shows an excerpt of the concepts defining the abstract syntax of the Gamification Modelling Language (GML) (the complete specification of the languages is included in the GitHub repository of the framework, available here.
In particular, a Game concept comprises a set of properties (i.e., id, domain, and owner) that characterise the specific gameful system, and a set of children representing its core ingredients. Each gamified application must be designed defining a set of game elements devoted to specify how the players should interact with the application. The children part of the Game concept of GML has been defined for this purpose. This core language provides the basic building blocks on top of which all the subsequent modelling layers can be described.
Based on the core ingredients in GML, the Game Model Language (GaML) relies on Game Mechanics and allows the game designer to design a certain concrete game. At this level of abstraction, the designer can specify in more details how the game components are assembled to create a gamification application. In particular dataDrivenAction are operators that act on data (i.e., kms, legs, etc.) while eventDrivenAction are related to specific events (i.e., surveys, check-in, etc.). skillPoint are points used to denote a user’s ability in a specific area, while experiencePoint are points used to quantify a player’s progression through the game. Finally, badgeCollection and challenge represent game elements that each players can collect and achieve, respectively. It is very important to notice that in this way GaML allows the designer to specify game components which are reusable in different gamification scenarios. Notably, the abstract concept experiencePoint can take the concrete forms of pedibus_distance or Walk_Km, depending on the target application.
A gamification engine is responsible for the execution of one or more instances of multiple games that may run concurrently. Therefore, we introduced GiML, a language that relies on the Game Dynamics and is used to specify the instantiation of the different games originating from the same GameDefinition as defined in GaML. A game instance is a GameDefinition, as prescribed in GaML, opportunely instantiated to be run by the gamification engine. In general an instantiation consists of the specification of the players/teams involved in the game, hence one or more instances of multiple games may run concurrently by means of the same engine. The Game Instance Model Language (GiML) binds game definitions coming from GaML with instantiation details. In particular, the classrooms defines teams and players that play in a certain instance of a game in the education domain.
When a game instance is running, the game state changes whenever one of the mechanics defined in the game (i.e., score update, challenge achievement, etc.) is used. In particular, this means that one of the game rules defined using GaML is executed in a specific instance defined through GiML. Therefore, the game state evolves as the right-hand side of the game rules prescribe to manipulate the object base through the gamification engine services. Based on this, our approach provides support for simulating the behaviour of a running game under certain conditions, by means of the GsML component. It is part of the Game Utility component of the GDF and its core concept is represented by the GameSimulation element.
This concept is composed by a GameDefinition and a set of SingleGameExecution. In this way, GsML allows to model specific game scenarios together with triggered mechanisms, and hence to simulate specific game state changes (e.g. for testing purposes).
The gamification engine exploited by the GDF includes a Recommendation System (RS) able to generate challenges tailored to each player’s history, preferences and skills , . In this context, the GadML language is used whenever a new game content (i.e., a new challenge generated by the RS), has to be assigned to a specific player on-the-fly.
This Figure shows the newChallenge concept that extends a simple game adaptation defining the ChallengeModel, the ChallengeData (i.e., bonusScore, virtualPrice, etc.) and ChallengeDate (i.e., start and termination date of the new challenge).
Prototype Implementation and Validation
The internal logic of the GDF is made by four components: (a) Game Model, (b) Game Instance, (c) Game Simulation, and (d) Game Adaptation. Each component is made up of two layers, the former is implemented using JetBrains MPS (briefly, MPS), a language workbench based on projectional editing, while the latter exploits an open-source Gamification Engine (the engine has been realised in GitHub under the Apache License Version 2.0 and is available as stand-alone application as well as software-as-a-service (SaaS).}.
We have used GDF to implement a real gamified application called Kids-go-Green (KGG) . KGG is an application for supporting active and sustainable mobility habits, both at the personal and collective level, and targeting younger citizens (elementary schools students). KGG is based on a virtual journey that can be travelled by players using the sustainable kilometres collected in real life. Every day each class accesses the KGG Web application and fills the Mobility Journal. The children indicate the way they reached school that day by expressing a specific sustainable transportation mode (i.e., by foot, bike, walking bus, or school bus). The number of kilometres travelled each day by the children in their trips to school contributes to the progress on a virtual journey. KGG also includes class-level and school-level challenges: upon completion of a specific objective (e.g., zero emission day, no-car week, etc.).
Using GDF, a gamification designer can design a new game defining the set of teams (i.e., schools and classrooms) and players (i.e., students) participating in the virtual journey. The specific Institute with its respective School and Classroom are specified with all the needed information . Starting from these models, all the game elements (i.e., points, actions, badges, challenges, etc..) that regulate the game behavior can be defined using a specific editor in GDF. It has been created using all the fields of the GamificationInstance concept of the GiML language. Once the designer have specified the new game, she/he can proceed with the game deployment in the gamification engine. The deployment step is done using the GiML generator able to generate Java code that, when executed, results in the creation of corresponding game instance in the gamification engine.
GDF also provides support for the simulation of the behaviour of a running game and the definition of new game contents and their assignment to a specific player on-the-fly. To simulate the defined games, GDF uses the GsML component. Starting from a GameSimulation model, a generator is used to generate the corresponding Java code. In this case, a JUnit test is generated. Finally, whenever a game adaptation (i.e., new challenge) must be executed for a specific player of team, we use the generator to generate a Java code that leads to the adaptation of a Database that the gamification engine uses to update the specific game instance.
Discussion and Research Outline
The proposed layered architecture makes GDF an open framework able to be extended easily both in terms of concepts and gamification mechanics but also in terms of supporting utilities. This is very important to go towards a framework able to be used in various application domains (i.e, education, mobility, etc..), as we have started to demonstrate in this paper.
The provisioning of notations and constructs tailored toward gamification domain has offered substantial gains in expressiveness and ease of use compared with the various general purposes languages, with corresponding gains in productivity and reduced maintenance costs. With GDF we have introduced the appropriate precision level of modeling shared by the different actors involved providing a unique framework that offers possibilities for design, monitoring, simulation, and adaptation if terms of a domain-specific language that would be much harder or unfeasible using the different general-purpose languages used before.
Starting from the shared gamification abstraction, the Game Utilities layer of GDF provides a set of facilities for the simulation and adaptation of the running gameful system. For the way it has been thought, and for the fact that each utility is related to specific concepts of some of the gamification languages specified, it is very easy to see how in the future new utilities can be specified and added at the framework. For instance, while the adaptation utility is strictly related to the Challenge game element and its goal is to generate and inject specific challenge code for a specific player instance, in the future we are planning to add a Monitor Utility devoted to the monitor a specific game property (i.e., player status) and suggest a specific game adaptation (i.e., new challenge). At the same time, we plan to investigate further towards adaptation and learning capabilities, possibly introducing more sophisticated self-adaptation mechanisms in gameful systems.
In this post we presented the experiences matured in the development of a framework for designing gameful systems. The proposed layered architecture allows domain experts to abstract implementation problems and focus on details closer to their expertise, namely gamification techniques and application domain targeted by the game. The resulting GDF not only reduces the complexity of defining gameful applications, but it also discloses the opportunities of specifying simulations and adaptations for particular gaming scenarios.
This work was partially funded by the EIT Climate KIC projects CLIMB Ferrara and SMASH.
Senior Researcher within the DAS Research Unit at Fondazione Bruno Kessler (FBK) of Trento, Italy. His main research interests include: Self-Adaptive (Collective) Systems, Domain Specific Languages for Socio-Technical System, and AI planning techniques for Automatic and Runtime Service Composition. He received a Ph.D. in Computer Science and Engineering from the IMT School for Advanced Studies Lucca in 2008 and since 2004 he has been a collaborator of Formal Methods and Tools Group at ISTI-CNR of Pisa (Italy). He has been actively involved in various European research projects in the field of Self-Adaptive Systems, Smart Mobility and Constructions and Service-Oriented Computing. He was the General Chair of the 12th IEEE International Conference on Self-Adaptive and Self Organizing Systems (SASO 2018) and he is an Associate Editor of the IEEE Transactions on Intelligent Transportation Systems (T-ITS) Journal, the IEEE Software Journal and the IEEE Technology and Society Magazine.