How generative agents will revolutionise believability in Video Games

Thanks to the advancements in neural networks and large-scale language models, I believe we are on the brink of something groundbreaking.

How generative agents will revolutionise believability in Video Games

Introduction

As a deep tech enthusiast and passionate gamer for decades, I couldn’t help but be drawn to the ongoing advancements in neural networks and large-scale language models. These developments have truly captured my attention and sparked a deep curiosity within me. Thanks to the advancements in neural networks and large-scale language models, I believe we are on the brink of something groundbreaking.

In 2017, the researchers at Google Brain introduced the transformer architecture, which has become the prominent neural structure for creating large-scale language models. These models have the remarkable ability to generate text that closely resembles human writing, showcasing fluency and creativity.

One significant application of these models is the development of generative agents. These advanced non-player characters (NPCs) have the capability to generate content that enhances the player experience. By offering dynamic and personalised interactions, they contribute to increased immersion and replayability of games.

In this series of articles, I will be discussing a fascinating transformation that’s taking place in the gaming industry, virtual worlds and beyond.

The present article aims to explore how Artificial Intelligence can revolutionise immersion in video games and will also try to provide a general definition of generative agents along with their characteristics.

In the second article, I provide an overview of the generative agent architecture proposed by Google researchers in April 2023.

In the third article, I delve into how these agents have the potential to revolutionise various domains, extending beyond the confines of the gaming industry.

Ultimately in the fourth article, we will explore the current challenges and limitations, trying to identify some of the risks that are associated with generative agents.

Join me as we explore this transformative journey unfolding in the gaming industry and virtual worlds.

Believability of non-player characters

Contemporary games often feature worlds, characters, and story elements that play a central role, even if the game is not necessarily classified as a role-playing game.

Immersion is a vital component in many video games because it allows players to perceive the game world as if it were a genuine reality. When a good level of immersion is achieved, players can become so fully absorbed by the gameplay experience that they are prompted to perceive the game as though it were a genuine, tangible world.

Gameplay experiences and immersion are complex phenomena with many facets that can vary depending on the characteristics of the game and the player’s preferences. Immersion is not a singular or monolithic concept, and different aspects of immersion may be emphasised in different games and among different players.

Players usually seek games that elicit optimal emotional responses or response patterns, and the believability of Non-player characters (NPCs) can play a significant role in achieving an immersive environment and adding purpose to the player’s experience [1]. If NPCs are poorly portrayed or fail to contribute to a believable environment, it can be challenging for players to immerse themselves in the game.

NPCs with realistic behaviours and personalities can make the gameplay experience more enjoyable and engaging, allowing players to empathise with them and create deeper connections with the game world. Immersive NPCs can also enhance the imaginative immersion of players [2], as they offer a chance to use their imagination and enjoy the fantasy of the game. Therefore, designing NPCs that contribute to the sense of immersion is crucial in creating a successful gameplay experience.

Creating believable NPCs in video games is quite a challenging task, especially for sandbox and open world video games where there isn’t a linear storyline that can be followed. Coping with the vastness and unpredictability of such open environments can prove to be daunting, requiring substantial resources, time, and effort. Manually crafting NPC behaviour to cover all possible interactions is impractical and inevitably leads to limitations in the characters’ ability to fully represent the consequences of their actions and perform new procedures beyond their programmed script.

Machine Learning approaches have shown promise in creating more robust behavioural patterns for NPCs. However, these approaches still present certain limitations that put boundaries around their area of application or lead to unintended interactions between characters.

The NPCs in the video game The Elder Scrolls IV: Oblivion were criticised for their poor design and bizarre behaviour, leading to them to become memes in the gaming community.

With the recent advancements in Large Language Models, there is an opportunity to create a new architecture that could potentially push the boundaries of NPC believability. By harnessing the power of these models, it may be possible to transform NPCs into generative agents capable of dynamically responding to changes in the game world and even seeking out new behaviour that wasn’t originally conceived by game designers. This could revolutionise the way in which we design and implement NPCs in video games, offering a new level of depth and complexity to the gaming experience.

But what are generative agents?

Generative agents are AI-driven characters that offer dynamic, personalised, and immersive experiences by leveraging neural networks and large-scale language models to adapt to ever-changing world states, interact with other agents, objects, and human players, and exhibit believable behaviour [3]. While the technology to create fully functional generative agents does not yet exist, researchers and game developers have started experimenting with integrating large language models such as GPT-4 into non-player characters to create more sophisticated non-player characters.

By leveraging machine learning algorithms, these prototype agents can analyse past interactions and experiences to learn and adapt to changing circumstances. They can also understand and generate human-like language, which allows them to engage in meaningful interactions with human players and other agents in the virtual environment. These elements imbue NPCs with rationality and intentionality, as their underlying architecture allows them to understand the context they are immersed in and shape their behaviour and conversations according to how that evolves over time based on player actions, environmental changes and other agents’ behaviours.

Although still in the prototyping stage, these initial generative agents offer a glimpse into their potential to revolutionise the gaming industry and virtual experiences more in general. By providing more dynamic, personalised, and immersive interactions, generative agents could transform the way players act within virtual environments and open up new possibilities for social interaction, creative production, exploration, and gameplay.

Generative agents can generate dynamic outputs by continuously processing various inputs through the Language Model, without being limited by predetermined scripted states.

For generative agents to be successful, they need to include a certain set of key capabilities:

a. Inter-agent communication: They should be able to interact with other generative agents.

b. Agent-object interaction: They should be able interact with non-agent objects within the game or virtual environment.

c. Human-agent communication: They should be able to engage with human players effectively.

d. Believability: They must exhibit believable behaviour and responses.

e. Experience-based information retrieval: They should be able to access information based on events they have experienced.

f. Memory: They should be able to retain their experiences through short and long term memory.

g. Decision Making: They should be able to utilise the information stored in their memory to make informed decisions, adapt to changing circumstances, and engage in meaningful interactions with other agents, objects, and human players.

Initial experiments with generative agents [3], have demonstrated that equipping them with a sophisticated memory stream that allows them to store and retrieve observed events, reflect on past experiences, plan their behaviour and react to occurring events leads non-player characters to display believable behaviours.

Despite utilising language models in live environments, still represents a challenge due to the high processing costs and low response time, as the technology becomes more advanced and efficient, it becomes increasingly possible to bring generative agents to life.

In addition to this, more sophisticated language models could also allow generative agents to better understand human emotions and respond appropriately, learn and adapt to new situations more effectively, generate more creative responses, follow ethical guidelines and produce rich media.

With continued research and development of large language models, the potential for generative agents to create deeper, personalised and inclusive virtual worlds is immense.

The advent of generative agents powered by large language models holds tremendous promise for revolutionising the believability of non-player characters in video games. With their ability to dynamically respond, adapt, and push the boundaries of scripted behaviours, generative agents have the potential to create immersive and engaging gaming experiences like never before.

As we embark on this transformative journey, we anticipate a future where virtual worlds become deeper, more personalised, and inclusive, opening up a whole new realm of possibilities for gamers worldwide.

In the next article, we will delve deeper into the architecture proposed by Google researchers, unlocking the secrets to a truly remarkable gaming experience.

Read Part 2 here

References

[1] Niklas Ravaja, Mikko Salminen, Jussi Holopainen, Timo Saari. 2004.
Emotional Response Patterns and Sense of Presence during Video Games: Potential Criterion Variables for Game Design, in Proceedings of the Third Nordic Conference on Human-Computer Interaction, ACM Press, pp. 339–347

[2] Laura Ermi, Frans Mäyrä. 2005.
Fundamental components of the gameplay experience: Analysing immersion in Changing Views: Worlds in Play, Proceedings of the 2005 DiGRA International Conference, 2005.

[3] Joon Sung Park, Joseph C. O’Brien, Carrie J. Cai, Meredith Ringel Morris, Percy Liang, Michael S. Bernstein. 2023.
Generative Agents: Interactive Simulacra of Human Behavior. https://arxiv.org/pdf/2304.03442.pdf

[4] Georgios N Yannakakis, Antonios Liapis, and Constantine Alexopoulos. 2014.
Mixed-initiative co-creativity. In Proceedings of the 9th Conference on the Foundations of Digital Games. FDG, Liberty of the Seas, Caribbean, 8. http://www.fdg2014.org/papers/fdg2014_paper_37.pdf

[5]Max Kreminski, Melanie Dickinson, Michael Mateas, Noah Wardrip-Fruin. 2020.
Why Are We Like This?: The AI Architecture of a Co-Creative Storytelling Game https://dl.acm.org/doi/pdf/10.1145/3402942.3402953

[6]Marie-Laure Ryan, Jan-Noël Thon. 2014.
Storyworlds across Media. University of Nebraska Press. https://digitalcommons.unl.edu/cgi/viewcontent.cgi?referer=&httpsredir=1&article=1273&context=unpresssamples

Attributions

Icons by freepik.com

In–game screenshot: Elder Scrolls IV: Oblivion. Copyright held by UESP for use under the same Attribution-ShareAlike 2.5 Licence