Business·Analysis

The challenges of playing the market against artificial intelligence: Don Pittis

Can AI corner the market? And what happens when the computers decide we are on the verge of another great crash?

AI has already creamed humans in checkers, chess and the complex game of Go. Are markets next?

Japan's third biggest lender, the Mizuho Financial Group, has reportedly begun using artificial intelligence in equity trading, and it is not the first company to do it. (Toru Hanai/Reuters)

Elon Musk has raised the alarm about artificial intelligence wiping out humanity, but the SpaceX and Tesla boss still hasn't warned you that AI may be coming for your investments.

When Google-owned DeepMind's AlphaGo conquered a human champion at the game of Go last year, it was widely regarded as a watershed in machine learning. 

"Go is considered to be the pinnacle of game AI research," said DeepMind's Demis Hassabis at the time.

Bigger game, bigger stakes

But the money game is bigger, and there is a lot more at stake.

​Last week the business news service Bloomberg reported that Japan's third biggest lender is taking AI into the equities market.

"Mizuho Financial Group Inc. will start artificial-intelligence trading this month to bolster its Japanese equity business," Bloomberg reporter Takahiko Hyuga wrote, saying it would offering algorithm-based services to institutional clients.
Lee Se-Dol, one of the greatest modern players of the ancient board game Go, reacts during a press conference after losing the second game to Google's DeepMind in Seoul on March 10, 2016. (Jung Yeon-Je/AFP/Getty Images)

The firm is far from alone. And like others who are already using AI, expecting to win at the stock market game, the Japanese giant has been far from forthcoming about how its trading strategies will work.

Just as AlphaGo did to beat a champion player, in theory AI can use machine learning, sometimes called deep learning, to pick investment strategies based on how markets have reacted in the past.

In the classic example of machine learning a computer is given thousands of pictures of cats, gradually using trial and error to create a complex mathematical description of cat-ness, allowing it to reliably recognize cat pictures it has never seen before.

The flash crash and computerized trading

In the case of markets, the computer would recognize various hidden clues for when markets will rise or fall, buying before a rise and selling before a fall.

Even before adding artificial intelligence to the trading process, the introduction of non-AI computerized trading has resulted in unpredictable market events. 

During the flash crash in 2010 when U.S. stocks plunged by trillions of dollars over less than half an hour and then just as suddenly rebounded, fortunes were won and lost during the moments of chaos. 

While a single British trader working from his London apartment took the blame for making the initial trade, the reasons for the complex cascade of events that actually led to the crash are still widely disputed by market experts. In such entangled systems, researchers say, flash events are pervasive.

Not Skynet yet

As AI creeps into just about everything, stealing jobs and creating an existential threat, according to experts that include Musk, Microsoft founder Bill Gates and physicist Stephen Hawking, it may be leading to a market environment more complex than humans can understand.

Among those who at least have a chance of comprehending the complexity of modern electronic market systems that include artificial intelligence and algorithmic trading is Andreas Park a finance professor at the University of Toronto's Rotman School of business. 

"We're not going to have Skynet yet," he quips, referring to the artificial intelligence that becomes conscious and takes over the world in Arnold Schwarzenegger's Terminator movies.
'Not Skynet yet' says stock market AI expert Andreas Park, referring to the computer invented by the fictional Cyberdyne Systems that dominates the world in the Terminator series of films. (TriStar Pictures)

"It is certainly new and different and it is amazing the kinds of things that people can come up with, but at the end of the day it's trying to predict what happens in the future," says Park. "Artificial intelligence at its core is predictive analytics."

So what if AI foresees a giant market crash of the kind that we saw in 1929, 1987 or 2008?

Whether human or artificially intelligent, every trader looks smart when markets keep going up and up as they have been since 2011.

Markets already high-priced

But as respected financial whiz and Yale professor Robert Shiller said on television last week, "The market is about as highly priced as it was in 1929."

"In 1929 from the peak to the bottom, it was 80 per cent down," he said in an interview on business network CNBC. "You give pause when you notice that."

Mark Kamstra, who has co-authored papers with the Yale economist, is quick to point out that Shiller was not predicting another Great Crash. Kamstra, Canadian Securities Institute Research Foundation Professor at York University's Schulich School of Business, says whether they use AI or not, the biggest advantage of modern computer trading is speed.

"Basically they have algorithms that have captured the wisdom, as best they can, of the traders and just implement trades more quickly than you or I could, standing in front of our computer," says Kamstra.

Rather that betting on giant rises or falls, current algorithms tend to make many trades sometimes less than a second apart, predicting and exploiting tiny differences in prices, creaming off a small profit that author Michael Lewis has described as something like a tax.

Kamstra says in normal trading that can benefit markets by making sure there is always a buyer for every seller, what markets refer to as liquidity.

Many of these artificial intelligence algorithms...are trained with typical data and the trouble with typical data is that it doesn't perform well when you get into atypical situations-  Jonathan Schaeffer, AI expert

But when something really unusual happens in a market such programs are generally trained to get out and stay on the sidelines. That could have the opposite effect, removing liquidity when it is most needed.

The trouble is, as with the flash crash, once artificial intelligence programs are competing with humans and against other different AI trading programs, no one can be certain what will happen when markets receive an unexpected shock.

One of Canada's ​artificial intelligence pioneers, Jonathan Schaeffer, says most electronic trading programs described as AI really aren't.

Schaeffer cut his AI teeth conquering the game of checkers but now he's Dean of Science at the University of Alberta, host and collaborator with a newly established laboratory for Google's DeepMind, the first outside Britain.

"Many of these artificial intelligence algorithms...are trained with typical data and the trouble with typical data is that it doesn't perform well when you get into atypical situations," says Schaeffer. 

That may be different from true AI, trained using machine learning with historical data. But that kind of AI is a mystery even to the people who build it because such systems learn by experience, not through programming, making the logical steps they follow a black box that programmers cannot see inside.

But whether trading algorithms step aside and let markets fall or think of some other way to make money, Schulich's Kamstra says such programs are single-minded. Their purpose is to make profit for the human masters who own them, not to stabilize the market for everyone else.

"Their duty is only to their shareholders," he says.

Follow Don on Twitter @don_pittis

More analysis from Don Pittis

ABOUT THE AUTHOR

Don Pittis

Business columnist

Based in Toronto, Don Pittis is a business columnist and senior producer for CBC News. Previously, he was a forest firefighter, and a ranger in Canada's High Arctic islands. After moving into journalism, he was principal business reporter for Radio Television Hong Kong before the handover to China. He has produced and reported for the CBC in Saskatchewan and Toronto and the BBC in London.