Interview with Sahar Asadi (King)

Interview with Sahar Asadi (King)

Everyone knows that Candy Crush Saga is one of the most popular games in the world. What you may not know is that AI plays a very important part in the level design of this game.

How AI is being used in the development of the world's most popular mobile game: Interview with Sahar Asadi (King)
Sahar Asadi is the director of the AI ​​Labs team at King

Millions of developers, graphic designers, game designers and many other types of technology professionals already use different services generative artificial intelligence in their daily lives, as a complement to conventional tools. And as much as the most catastrophic believe that this technology is going to steal thousands of jobs, the truth is that the implementation of generative AI has meant a clear improvement in productivity of this type of workers over the last two years.

So much so that large companies were quick to adopt the use of this type of tool, with the aim of improving the efficiency of their employees. Companies such as Google, for example, have their own internal tools designed to help their developers program faster and Github CopilotAI capable of writing code, is saving dozens of hours each month to companies like Amazon, according to recent reports.

In the field of the video gamegenerative artificial intelligence has also made its way into the industry in recent years. Top-tier companies such as Kingcreator of Candy Crush Saga, was one of the pioneers in adopting the use of these tools, with the aim of make your employees’ jobs easier in the development of new levels or the automation of tasks.

Today, in fact, a part of the levels available in Candy Crush Saga have been developed with the help of generative AI. A risky bet considering that it has been the mobile game with the largest player base in the world.

But, How does King use AI in the development of Candy Crush Saga? To find out more about the processes and techniques used, we at Andro4all have been able to chat with Sahar Asadi, Director of AI Labs Division in King.

AI as a great ally in the level design of Candy Crush Saga

Sahar Asadi is the director of King’s division focused on experimentation with artificial intelligence technologies. The division, which Asadi has led for five years, is part of the company’s central organization and collaborates closely with the different teams in charge of game development like Candy Crush Saga. Its main mission is to “bring value to game development by applying and adopting artificial intelligence”, and it is focused on the Research into new AI techniques and trends that can be incorporated into the company’s long-term strategy.

One of the most recent and impactful applications of the work of the division led by Asadi concerns the Automation in Candy Crush Saga level designWith over $20 billion in revenue generated by September 2023, and over 5 billion installations since its launch in 2012, Candy Crush Saga remains King’s main asset, and the company’s big challenge is not only to attract new players, but to offer sufficient variety of levels as to keep those more veteran players hooked, who have already overcome a good part of the 16,000 levels currently available in the game.

Asadi herself explains that “one of the great pillars of the game are the levels”. Players spend most of their time inside levels, and their goal is to deliver the best possible gaming experience. So one of the first missions for King’s AI team was to Collaborate with the level design team to apply artificial intelligence techniques in the process of developing new levels. During this process, so-called test “bots” were created.

“What playtesting bots do is help designers get an assessment of level difficulty and many other metrics about the gameplay experience before releasing the level.”

Reinforcement learning and supervised learning: the AI ​​techniques used by King in level automation

When it came to developing these bots, the company opted for the technique known as supervised learning with neural networksconsisting of taking the game data generated from millions of real games and “feeding” the bot with the information necessary to learn by itself the most frequent movement patterns of the players and thus predict their next move.

In parallel to these bots, the AI ​​team also developed “adjustment agents”, whose purpose is to help designers improve certain aspects of the levelssuch as difficulty or the number of possible moves in each phase, based on the criteria described in the level design process.

He reinforcement learning has been the technique used by the team to develop these agents, and its use has been key for several reasons. Since it is not always possible to feed the model with correctly labeled information, thanks to reinforcement learning it was possible to make the agents themselves “learn” by playing the levels themselves, rewarding or penalizing each of the actions carried out.

“Positive and negative rewards are based on whether an action contributes to winning or losing the level. So by playing the game and earning these rewards, the agent learns how to play the level. You can also define rewards to reflect the learning of certain skills.”

With these two components, Asadi and his team have managed to make the division focused on level design able to Spend less time on repetitive tasksand focus on those that truly require creativity of the levels.

Of course, implementing AI into Candy Crush Saga’s level design hasn’t been an easy process. Nor a short one. Asadi explains, over the past few years, his team has encountered different challenges which had to be overcome before reaching the point where it is today.

Not all the challenges were technicalHe explains that implementing AI in level design required a “huge effort from all parties” who had to collaborate, each with their own needs, demands and organizational methodologies.

Candy Crush Saga 16000

Candy Crush Saga now has more than 16,000 different levels

As for the more technical part, the phase of testing of the levels was one of the most complex. When developing the test bots, an attempt was made to make them They will act as similarly as possible to that of a human. to obtain accurate information that would allow the necessary adjustments to be made in order to improve the gaming experience. But as has been seen on more than one occasion, Getting an AI to act like a human is not always easyand in the case of King it was necessary to readjust the model of machine learning used to be able to adjust to their criteria.

On the other hand, the generalization was another of the key challenges during this process. Although Candy Crush Saga may seem like a simple game, within each level there are a series of unique characteristics that make it especially complex to create a unique type of game. bot of tests capable of adjusting to the necessary criteria of each of the levels.

“Each level comes with 70-80 types of game pieces, and then you have different objectives (clearing frost from the board, getting a high score…) within a limited number of moves. There’s also a design part of how difficult a level should be. All in all, it’s a pretty diverse content. So this bot needs to play like a human, picking up on different player styles and preferences, but also be able to generalize well across all the different levels we have.”

From King they put special emphasis on how the gaming experience benefits from automation in level design through AI. To achieve this, they focus on ensure that the levels have the expected quality and that difficulty requirements are met to ensure that levels are neither too easy nor too difficult.

The gaming experience also refers to keep the user “hooked” with new levels that encourages them to return to the game day after day. In this sense, he explains that this automation process has facilitated the development of new levels, up to the figure of 16,000 in an increasingly agile way.

King, however, is not betting everything on levels generated by generative AI. Although it is already possible to find some self-generated levels in Candy Crush, the vast majority of the new levels have been designed using other existing levels as a basisand making some adjustments and modifications.

In this sense, they make it clear that The company considers AI as an assistance tool in the design processand carry out quality assessment phases of the levels that are designed using this type of tools.

It is also taken into account he feedback of the different types of players. Both for those who have just started, and for those who have already overcome the more than 16,000 levels available. They do this through techniques that calculate the “perceived difficulty” of each level during the games, and this metric is compared with the results obtained through the bots test. Thus, if both metrics are close or coincide, it is guaranteed that the bot is performing its purpose adequately. If not, the model may need to be retrained with new data.

Ethics is another of the key points when implementing AI in the development of Candy Crush. So much so that the company has established a Ethics Committee of which Asadi herself is a part.

This committee establishes different review processes that ensure the development of responsible AI solutions. In the case of level design automation, the company has ensured that The design team itself has been involved in refining the model based on their criteria and requirements, to ensure that the tools are created responsibly.

What comes next

King has big plans for the future when it comes to using AI in its operations. In the case of Candy Crush Saga, the team is focused on making it possible to the game is able to understand the context of each player and generate the best possible gaming experience for all of them.

“We want to make sure that all players have a good gaming experience at all times. Sometimes one player might come and only have a few minutes on the bus to play, while another is playing in the afternoon for half an hour. They expect two different experiences and making sure that the entire gaming experience takes into account the player’s context is an interesting step for the future.”

In the levels part, of course, King wants to delve deeper into the automatic level generationbut also in continuing to improve the tools that help its designers and developers ensure they meet quality requirements.

You can follow Andro4all on Facebook, WhatsApp, Twitter (X) or check out our Telegram channel to stay up to date with the latest tech news.

Leave a Comment

Your email address will not be published. Required fields are marked *