ҹ1000

Understanding human intentions will be the next big breakthrough in AI

With the recent news that the ChatGPT AI can pass a theory of mind test, how far away are we from an artificial intelligence that fully understands the goals and beliefs of others?

SUPERHUMAN artificial intelligence is already among us. Well, sort of. When it comes to playing games like chess and Go, or solving difficult scientific challenges like predicting protein structures, computers are well ahead of us. But we have one superpower they aren’t even close to mastering: mind reading.

Humans have an uncanny ability to deduce the goals, desires and beliefs of others, a crucial skill that means we can anticipate other people’s actions and the consequences of our own. Reading minds comes so easily to us, though, that we often don’t think to spell out what we want. If AIs are to become truly useful in everyday life – to collaborate effectively with us or, in the case of self-driving cars, to understand that a child might run into the road after a bouncing ball – they need to establish similar intuitive abilities.

The trouble is that doing so is far harder than training a chess grandmaster. It involves dealing with the uncertainties of human behaviour and requires flexible thinking, which AIs have typically struggled with. But recent developments, including evidence that the AI behind ChatGPT understands the perspectives of others, show that socially savvy machines aren’t a pipe dream. What’s more, thinking about others could be a step towards a grander goal – AI with self-awareness.

“If we want robots, or AI in general, to integrate into our lives in a seamless way, then we have to figure this out,” says at Columbia University, New York. “We have to give them this gift that evolution has given us to read other people’s minds.”

Psychologists refer to the ability to infer another’s mental state as theory of mind. In humans, this capacity starts to develop at a very young age, says at the University of California, Berkeley. By the age of 9 months, babies understand that people’s actions are linked to their goals. Between 18 months and 2 years, they start to grasp that each person’s goals can be different because we have unique desires.

Theory of mind

At around 4, they pass the “false belief test”. This involves a child watching someone place an object, which is then moved without that person’s knowledge. The child is then asked where the other person will look first, and getting this right requires them to understand that the other person has different, and false, beliefs. Remarkably, by the age of about 5, humans have a fairly sophisticated ability to infer what others are thinking, says Gopnik.

People aren’t the only mind readers. Some animals also seem to display varying degrees of theory of mind. Chimpanzees, bonobos and orangutans are all capable of passing the false belief test, and birds including ravens and jays are also capable of inferring others’ mental states.

Bornean Orangutan (Pongo pygmaeus wurmbii) female 'Peta' carrying her daughter 'Petra' aged 12 months on her back. Camp Leakey, Tanjung Puting National Park, Central Kalimantan, Borneo, Indonesia. July 2010. Rehabilitated and released (or descended from) between 1971 and 1995.
Orangutans can pass a “false belief” test, as can some AIs
Anup Shah/naturepl.com

How to reproduce these capabilities in machines is far from clear, though. Part of the problem is that what we describe as theory of mind is, in fact, not just one thing. “There are so many elements to what people call theory of mind,” says at Brown University, Rhode Island. “It’s a large collection of abilities.” At the simpler end of the spectrum is the capacity to understand the motivations behind actions, whereas at the other extreme is the kind of complicated social manoeuvring you get in a Jane Austen novel.

One of the main challenges is context, says at Yale University. For instance, if someone asks if you are going for a run and you reply “it’s raining”, they can quickly deduce that the answer is no. But this requires huge amounts of background knowledge about running, weather and human preferences.

When it comes to teaching AIs these skills, it make sense to start simple, says Malle, especially as it seems that there is some kind of hierarchy to theory of mind skills. “Some capacities are just more frequent in the animal world, appear much earlier in human development and probably have lower complexity,” he says.

Yet even the simplest social skills are far from trivial to translate into machines. The kind of calculations involved are quite different from the formulaic logic that computers normally use. Most importantly, they need to be able to deal with uncertainty, says at the University of Manchester, UK.

A person’s internal mental processes are impossible to observe directly, so the best you can do is make informed guesses based on the evidence available. Doing so typically involves flipping a classic machine learning technique called reinforcement learning on its head. In its conventional form, this involves setting an AI a goal and rewarding it for taking actions that work towards that goal. Through trial and error, the agent learns behaviours that achieve the goal. “Inverse reinforcement learning” works the other way round: observing someone’s actions over time and using this to build up a picture of what that person is trying to achieve. This is similar to a child watching a game of hide-and-seek for the first time and quickly deducing what the goals of the different players are.

A popular way to do inverse reinforcement learning relies on a statistical technique called Bayesian inference. This lets you analyse new data while taking into account prior knowledge. The technique is powerful, says Kaski, because it deals well with uncertainty and lets you make use of what you already know about a problem as well as adapting to new information as it becomes available.

In 2022, Kaski and his colleague Sebastiaan De Peuter used Bayesian approaches to develop a prototype digital assistant that could help someone solve problems that require making a series of interrelated decisions. In this case, the AI helped someone plan a weekend sightseeing trip based on their budget, time constraints and preferences. The example might seem trivial, but Kaski says it is fundamentally similar to helping solve more complex tasks like engineering design, and his goal is to develop AI assistants that accelerate the work of scientists and doctors. “The motivation really comes from being able to solve harder problems better,” he says.

Robot surgery. Surgeon (lower left) performing minimally invasive surgery (MIS) on a patient's heart using da Vinci, a remotely-controlled robot surgeon (centre right). The surgeon views a three- dimensional image of the operation site in the black box at left. The robot arms are controlled using instruments under the box. An endoscopic view of the area from the robot is seen at upper right. Another surgeon is examining chest X-rays at upper left. The da Vinci system allows precise control of surgical tools through an incision just 1cm wide, with greater control than manual MIS procedures. Da Vinci was designed by Intuitive Surgical Incorporated, based in California, USA.
Machines that infer what we are thinking could cooperate better
PETER MENZEL/SCIENCE PHOTO LIBRARY

Most research on machine theory of mind to date has relied on simplified scenarios, such as inferring the goals of agents moving around in basic two-dimensional grid worlds. But at the Massachusetts Institute of Technology is trying to bring these techniques into the real world. In 2020, his group combined Bayesian approaches with a programming language used by robots, which he says could ultimately help apply these techniques to practical robotics challenges. More recently, they upped the complexity of the task into three dimensions.

One of the key ways to test theory of mind in infants, says Tenenbaum, is to show them videos of people and then quiz the children about what the people are trying to achieve, and his team wanted to try this with AIs. In 2021, Tenenbaum and his colleagues unveiled a new challenge in which AI agents watch 3D animations of cartoon characters running up ramps, jumping over walls and going through doors. Their Bayesian model got close to human-level prediction in several scenarios.

While it is still early days, Tenenbaum says his team is working with researchers at Microsoft, IBM and Google who are interested in applying their ideas to real products . “We are far from having a complete model of theory of mind,” he says. “But we have enough of the building blocks that actually, with engineering scale, it could already be quite useful in a range of applications.”

Deep learning

Other researchers are taking a fundamentally different approach to this problem. Most of the headline-grabbing AI developments in recent years have relied on deep-learning neural networks, a family of algorithms loosely inspired by the brain. A key feature is that programmers build very little prior knowledge into these systems, instead allowing them to learn from experience by ingesting mountains of data.

Cute asia children
Advanced social skills are needed to understand hide-and-seek
real444/Getty Images

This is the approach taken by researchers at Google-owned DeepMind to develop their so-called Theory of Mind-net, or ToM-net for short. , they showed that ToM-net could pass a false belief test, when the researchers hid or moved objects other agents were searching for in a two-dimensional grid world. Since then, others have applied similar ideas to more complex domains.

A key milestone in children’s development of theory of mind is understanding that people’s point of view can differ from their own, says Lipson. For instance, children under the age of 4 often try to hide by closing their eyes, assuming that if they can’t see you, you can’t see them. So, in 2019, Lipson and his colleagues challenged a deep-learning AI to a game of hide-and-seek. They created a 3D simulation dotted with obstacles and dropped in two agents, a predator and a prey, whose only information came from their first-person view of the environment.

The seeker was governed by a set of rules designed to help it hunt out the other agent and the hider was governed by a neural network that, over many trial rounds, successfully learned how to hide. To solve the challenge, the hider had to see the world through the seeker’s eyes, says Lipson. “I think that’s the root of theory of mind,” he adds. “To be able to actually visually see the world from another person’s perspective, not just think about it logically.”

In 2021, Lipson and his colleagues extended their approach, trained on thousands of images of a robot carrying out simple activities could learn to guess what its plans were with 99 per cent accuracy. It even passed a false belief test when the researchers hid one of the robot’s objectives.

Understanding intentions

A key motivation of Lipson’s approach is that he wants theory of mind to emerge spontaneously from the learning process. Building prior knowledge into AI makes it reliant on our imperfect understanding of theory of mind, he says. In addition, AI may be capable of developing approaches we could never imagine. “There can be many forms of theory of mind that I don’t know about simply because I live in a human body that has certain types of senses and a certain ability to think,” says Lipson.

Tantalising evidence of this kind of emergence was reported earlier this month by Michal Kosinski at Stanford University, California. In a he described feeding the deep-learning AI behind ChatGPT text descriptions of the classic false belief test and another involving a package with unexpected contents. Without any special training, the AI did as well on the tests as a 9-year-old human would be expected to do. 

Fresh results from researchers at Meta suggest a combination of approaches might be an even more powerful way to reproduce some of the capabilities involved in theory of mind. In November, they unveiled an AI called Cicero that learned to play the board game Diplomacy, which sees up to seven people fighting to conquer Europe. Before each round, players get a chance to negotiate and form alliances. This is highly challenging for AIs, as it requires both effective communication and predicting other players’ intentions to work out how to cooperate.

The team solved this challenge by linking a deep-learning language model that can interpret and generate messages with a strategic planning model that learned the game by playing copies of itself. Crucially, the planning model relied on concepts from game theory, which uses mathematical models to understand strategic decision making. Cicero trained on data from real Diplomacy games to predict what players will do based on the state of the board and previous dialogue. This was then fed into the planning model, which comes up with a strategy balancing the theoretically optimal moves for all players against what their messages suggest they will do. Cicero then generates messages to help it achieve its goals. In an online league, it ranked in the top 10 per cent without raising suspicions that it was an AI.

Noam Brown, one of the lead researchers, says the team decided against using the term theory of mind to avoid getting bogged down in semantics, but he believes their work makes fundamental contributions. “A rose by any other name,” he says. “It’s really the substance that matters, and I think that the substance of what we’re doing is understanding the beliefs, goals and intentions of the other players.”

This is another significant step on the path to socially savvy machines. But Cicero’s ability to model players’ mental processes still falls short of true theory of mind, says Tenenbaum, because the models are highly specific to Diplomacy and can’t be repurposed for other tasks. “They seem to have acquired some strategies that reflect what humans do using theory of mind, but that’s not the same as saying that they’ve acquired a theory of mind.”

That might seem like splitting hairs, but there are practical reasons why we might want AI to have a more human-like form of theory of mind, says Tenenbaum. Deep-learning systems are typically black boxes – it is hard to decipher how exactly they came to a decision. Humans, on the other hand, can clearly explain their goals and desires to each other using common language and ideas. While learning-based approaches are likely to play an important role in developing more potent AIs, says Tenenbaum, explicitly building in shared ways to represent knowledge may be crucial for humans to trust and communicate with AI.

“There should be a fundamental human-likeness to them, which I don’t think you’re going to get if you just go about the route of building a big data set and doing a lot of machine learning on it,” says Tenenbaum. This will also be critical if we want to use AI to help us better understand how theory of mind works for us too, he adds.

It is important to remember, though, that the quest to imbue machines with theory of mind is about more than just building more useful robots, says Lipson. It is also a stepping stone on the path towards a deeper goal for AI and robotics research: building truly sentient machines. “The most fascinating thing about theory of mind is that it’s on the path towards self-awareness and consciousness,” says Lipson. “Thinking about other people and other agents is on the path to learning to think about yourself.”

Whether we will ever get there remains to be seen. But perhaps, along the way, we will learn something about ourselves too.

Topics: AI / Artificial intelligence / DeepMind / Machine learning