Time to bend the rules (Image: Johner/Plainpicture)

TEXAS Hold ‘Em or Five Card Stud? There could soon be a better way to settle a poker night argument. Julian Togelius at the IT University of Copenhagen in Denmark and colleagues have developed an AI system that generates new card games from scratch. The way it balances the rules could lead to an entirely new way of playing.

The researchers first had to come up with a way to describe rules that were general enough to capture games as diverse as blackjack and poker – and all the possible variations in between – while including number of players, actions taken each round, and winning conditions. The system searches through these possible variations, exploring sets of rules to see if they lead to a playable game. It chucks out games that end too quickly or lead to dead ends. It comes down to balance, says Togelius, who will present the work at the Foundations of Digital Games conference in Chania, Crete, later this month.

Card games could be just the start. Games with fixed rules are limited, says Togelius. “When you look at how five-year-old kids play, there are no rules.” He thinks AI designers might one day invent games on the fly, constantly making up new rules while keeping it balanced. It would be like improvisational theatre, he says.


Automatic rule-balancing systems could cater for a variety of player abilities, too, generating different rules for different players. A game with variations built in can be a great way to have fun without anyone having an unfair advantage, says Holly Gramazio at Hide&Seek, the UK company behind the Tiny Games app, which suggests game ideas based on who you are with and what is to hand.

And these systems could have applications beyond gameplay. One day they might be used to optimise turn-based processes such as traffic systems, says Togelius. They could also be used to automatically generate more games like Foldit, where players solve complex protein folding puzzles online.

Michael Cook at Imperial College London, who uses similar techniques to generate video games, says, “This system might allow us to think up games as compelling as poker and bridge but which couldn’t have been designed 100 years ago.”

Below, you can read the rules for a game made for New Scientist by the team.

This system might allow us to think up new games as compelling as poker and bridge

Pay the Price Julian Togelius’s colleagues José Font and Tobias Mahlmann have generated a brand new card game for New Scientist readers using the GenoCard system. Rules for the game – called Pay the Price – are below. Number of players: three (plus dealer) The game begins with the dealer giving nine cards and 99 tokens to each player. The remainder of the deck is placed in the middle of the table. Each player then makes a mandatory bet of one or more tokens. Each player then takes one card from the deck and shows it to the other players. Each player can then take further cards from the deck, if they want, without showing the other players. But for every card taken, the player must discard three cards from their current hand. Players can repeat the preceding until they have fewer than three cards left. Once all players are happy with their hand, they reveal their cards. Ace, Jack, King, and Queen are valued as 10. The player with the highest combination wins the round and takes all tokens on the table. “The player might notice a certain similarity to blackjack,” say Font and Mahlmann. Indeed, the rules to blackjack were part of the initial gene pool that seeded the evolutionary run that produced the game. “We believe that the game contains genetic material from blackjack. But we can’t be sure. We didn’t create the game, after all – our software did.”

This article appeared in print under the headline “AI creates card games to transform the way we play”