top of page

Unity and Machine Learning


It is no secret that Artificial Intelligence (AI) has awoken after a long sleep since the beginning of computer science. Many industries have a lot to gain from the continuous research and development in the field of AI and Machine Learning (ML). The video game industry is a prime example.

Now that the tools to enable and facilitate the advancement of AI are becoming more accessible, the really large video game producers have started to invest in internal AI divisions and departments in order to assist in homegrown game development mainly from a design, level design, structure and test ‘sound-board’ perspective. For example, AI is usually used to catch bugs in code and help animate characters in a more natural way.

Unity, the cross-platform game engine developed by Unity Technologies, is a widely used and highly popular software development environment designed for people to build video games. Significantly more than a tool itself, Unity made the ‘Unity ML-Agents Toolkit’ available about a year ago. This relatively new toolkit is open source and meant for creating and interacting with simulation environments using the Unity platform (here one cannot help but wonder whether this is a move that could eventually branch off into simulations, which are not too far from some games nowadays anyway). By taking advantage of Unity as a simulation platform, the toolkit enables the development of learning environments which are rich in sensory and physical complexity, providing compelling cognitive challenges, and supporting dynamic multi-agent interaction.

A couple of months ago, Unity announced their collaboration with DeepMind, a world leader in Artificial Intelligence research saying, “The partnership will enable DeepMind to develop virtual environments and tasks in support of their fundamental AI research program.”

Indeed, DeepMind needs a playground that is powerful enough to be a reasonable representation of a reality in order to test, explore and advance the field of AI through scientific research. Good examples of this are entire cities or complex terrains with rules that a self-driving vehicle needs to follow while it navigates safely, allowing the software to log millions of kilometres in a few days rather than years; or a complex environment rich in variability that could allow for the training of an Artificial General Intelligence. In this context, the Unity ML-Agents Toolkit will enable Machine Learning researchers to study complex behaviours using Unity and at the same time, hopefully provide game developers with the latest machine learning technologies. Mainly because of the ML-Agents Toolkit and somewhat because of the new partnership with DeepMind, Unity is well positioned to be the platform of choice for the development of intelligent agents.

However, there is a massive gap in knowledge, niche expertise and well balanced experience that the game developer company (and even more so the individual) needs in order to be able to use and make something out of these wonderful tools.

At Decisive AI, we believe that Unity’s ML-Agents Toolkit is irrefutable validation that ML is going to soon be the driving force behind all AI in video games, which is exactly what we are hard at work trying to achieve! Slowly but surely the industry is moving away from hard-coded, clumsy and limited artificial patterns. Game developers will soon needn’t worry about the quality or be concerned with huge development budgets going into the coder-driven so-called AI. True AI through ML and Reinforcement Learning (RL) will take care of the artificial agents. Not only producing them for a fraction of today’s cost, but of much higher quality and depth than money can currently buy.

We, at Decisive AI, have the critical expertise and knowledge necessary to train artificial agents is any environment. We have specialized ourselves is several game engines, including Unity, and know that Unity engine users have the advantage that it is easier to connect their games with the neural networks that, once developed with crucial and hard-to-come-by skill, will train repeatedly thus rendering an agent capable of playing such game. Yes, easy connectivity designed with true AI in mind is a great facilitator, but the expertise to develop the ‘brain’ that renders the player, that is the hard and extremely complex part. Decisive AI specializes in designing theses brains, the neural networks that are carefully weighted and calibrated to learn how to play a game. This learning is cemented in millions of episodes, and once the trainee reaches the desired level of performance, the agent is coded by the machine itself, with no human meddling. Different agents with varied levels of performance can thus be achieved depending on how proficient the artificial players need to be.

It is wonderful that Unity is facilitating this path which will lead to eventually ridding ourselves from the endless source of frustration that hard-coded human-developed limited patterns of behaviour are, and have always been. We hope that other popular engines like Unreal and GameMaker follow in these footsteps. Making it easier for artificial brains (neural networks) to connect with video game environments is a great step in the right direction for the betterment of the gaming experience. Designing, creating and nurturing the right neural networks to render the desired artificial players is what Decisive AI is here to help video game companies with.


bottom of page