IN THE DISTANT Koprulu Sector of the Milky Way, Facebook's Zerglings lingered in a restless swarm outside the enemy's base. After the commander ill-advisedly opened the gate, the social network's alien horde stormed in and slaughtered forces stationed inside, in a battle fought on the frontiers of artificial-intelligence research.
The bloody incident was part of an annual competition of the videogame StarCraft for AI software bots that wrapped up Sunday. Facebook quietly entered a bot called CherryPi designed by eight people employed by or affiliated with its AI research lab.
The social network's stealthy space war suggests Facebook is serious about competing with Google and others to set showy new milestones in AI smarts. Google's London-based DeepMind AI research unit made headlines last year when its AlphaGo software defeated a champion at the board game Go. In August, DeepMind declared StarCraft II, the latest version of the game, as its next target.
The contest Facebook entered, like most AI research in the area, used an older version of StarCraft, which is considered equally difficult for software to master. Facebook's AI research group, which lists 80 researchers on its website and is led by NYU professor Yann LeCun, has produced many research papers but not notched up an achievement as striking as Google's with Go. Facebook has released three research papers on StarCraft, but not announced a special effort to conquer the game.
Final results released Sunday indicate Facebook still has a way to go: CherryPi finished sixth in a field of 28; the top three bots were all made by lone, hobbyist coders.
Gabriel Synnaeve, a research scientist at Facebook, described CherryPi to WIRED as an "baseline" on which to build future research on StarCraft. "We wanted to see how it compares to existing bots, and in particular test if it has flaws that need correcting," he said. CherryPi competed in a long-running contest that is part of AIIDE, an academic conference on applying AI in entertainment. Facebook also sponsored this year's contest, paying for hardware used to run the thousands of bot-on-bot games.
Games such as tic-tac-toe, checkers, chess, and Go have been testbeds for new ideas in artificial intelligence since the field's beginnings in the 1950s. These days, there's also a serious business purpose, as companies increasingly use AI to hone their product and service offerings. Facebook, Google, and other tech companies use AI to improve ad-targeting and personalization systems, and enable new products, such as virtual assistants and augmented reality.
StarCraft is alluring to AI researchers for more than just the fun of commanding weapons like the building-leveling Yamato plasma cannon. Although the videogame may appear more approachable than Go or chess, it is many times more complex, because players' pieces and actions aren't limited to a tightly regimented board and always in full view of their opponent. The number of valid positions on a Go board is a 1 followed by 170 zeros. Researchers estimate that you'd need to add at least 100 more zeros to get into the realm of StarCraft's complexity.
The winning bot in this year's competition, ZZZKBot, was made by Chris Coxe, a software developer in Perth, Australia, who previously worked for NASDAQ. He built his bot alone, and lately took a break from work in part to dedicate more time to it. A day before the final results were announced, Coxe spoke self-deprecatingly of his handiwork. "It was supposed to be a proof of concept," he said. "The source code isn't all that great."
Like all StarCraft bots so far, ZZZKBot wouldn't last long against even a moderately skilled human StarCraft player. The feats of planning and memory required to predict and react to the maneuvers of an alien army are beyond today's software.
The days of amateurs building the best StarCraft bots appear to be numbered now that two giant companies that compete in both online ads and AI prowess have taken an interest. David Churchill, a professor at Memorial University of Newfoundland who organized the AIIDE contest, predicts the StarCraft bot scene is set for a big shake up over the next few years.
Facebook and Google say they are approaching StarCraft differently than most individual programmers have. Leading bots are based mostly on rules and strategies specified by their creators. Coxe says one of his bot's best features is a simple learning feature, in which it tries out pre-programmed strategies against each bot it plays and notes which one works so as to be prepared in their next matchup.
The tech giants are planning to lean more heavily on machine learning, planning to have bots develop their own strategies from scratch by examining large caches of data from past games, or repeated experimentation. Facebook didn't build ideas it has published along those lines into CherryPi. Machine learning was central to making Google's AlphaGo unbeatable.
Facebook's bot may not have won the StarCraft competition, but Dan Gant, whose bot PurpleWave placed second, saw hints of the future in its play. Most bots choose to either attack frontally, or retreat, based on the relative numbers in opposing armies. In videos released from the contest prior to the final results, CherryPi appeared to know when it could move fast enough to sneak around an enemy to attack its base, says Gant.
Still, don't expect lone bot builders to disappear overnight-or StarCraft to be conquered soon. "The problem is still so difficult," says Churchill. "For a couple of years I predict the hobbyist, mostly rule-based bots, will still do well." He guesses it may be five years before any bot can beat expert humans-but acknowledges it may be sooner.
Gant, a software developer in New York, took a break this year and spent months working full-time on PurpleWave. He says the entrance of tech giants adds to the appeal of a pursuit that presents a unique learning opportunity. "You can be Facebook or DeepMind or a kid just learning programming and you're competing on a level playing field," he says. "You're limited by your own effort and what you can teach yourself."
Making a superhuman StarCraft player could deliver tech companies more than just satisfaction. Google says machine learning from DeepMind has helped cut cooling bills in its datacenters. A Microsoft research paper on machine learning this year said that improving predictions of when a user will click on an ad by just 0.1 percent would yield hundreds of millions of dollars in new revenue. A bot capable of leading armies of alien zergs to crush any human might quickly earn its keep.