Machines That Play series has been broken into 7 parts. This is Part 4 of the series.
This series covers the history of Artificial Intelligence and games (until Deep Blue) and focuses on machines that played chess, checkers, and backgammon. The following topics are covered: how to build chess machines, Shannon’s work on chess, Turing’s work on chess, The Turk, El Ajedrecista, MANIAC, Bernstein chess program, Samuel’s checkers, Mac Hack VI, Cray Blitz, BKG, HiTech, Chinook, Deep Thought, TD-Gammon, and Deep Blue.
Part 1: Machines That Play (Overview) — this one
Part 2: Machines That Play (Building Chess Machines)
Part 3: Machines That Play (Chess-Before Deep Blue)
Part 4: Machines That Play (Deep Blue) — this one
Part 5: Machines That Play (Post Deep Blue)
If you want a summary of the first 5 parts, focusing on the human elements, go here.
Part 6: Machines That Play (Checkers)
Part 7: Machines That Play (Backgammon)
This part will cover the summary of innovations in chess programs, leading up to and including Deep Blue, focusing both on technical details (from papers of the Deep Blue team) as well as social and cultural reactions to Deep Blue vs. Kasparov face-off.
Garry Kasparov (Time Magazine)
*See last section for details
Why would anyone want to teach a machine how to follow some arbitrary man-made rules to move a bunch of wooden pieces on checkerboard, with the sole aim of cornering one special wooden piece? It’s so human to attack and capture pawns, knights, bishops and the queen to finally corner the king into an inescapable position. Those are our actions, that is our goal and we balance strategy and tactics to suit those. hen why teach machines to play chess?
“The public must come to see that chess is a violent sport. Chess is mental torture.” — Garry Kasparov (1990s)
Chess has long been regarded as the game of intellect. And many people argued that a machine that could successfully play chess would prove that thinking can be modeled/understood or that machines can be built to think. And that is exactly why people wanted to build a machine that could follow some arbitrary rules of our game and become so good at it that it could one day beat us at it.
Programming a machine to play chess is not tricky, but programming it so it can become a strong chess player is very hard. Many people argued that a machine that could successfully play chess would prove that thinking can be modeled/understood and that machines can be built to think.
It turned out that we would build a successful chess-playing machine in 1997, but it wouldn’t necessarily help us understand our mind — its way of playing would range from being extremely human to being almost alien to us and it would surely challenge our conception of what to call intelligence.
Creation of electronic computers began in the 1930s. ENIAC, which is considered to be the first general-purpose electronic computer, became operational in 1946. By the late 1940s computers were used as research and military tools in US, England, Germany, and the former USSR. Computer chess presented a fascinating and challenging engineering problem.
1940s — 1950s
Early pioneers focused on building machines that would play chess much like humans did, so early chess progress relied heavily on chess heuristics (rules of thumb) to choose the best moves. Researchers emphasized emulation of human chess thought process because they believed teaching a machine how to mimic human thought would produce the best chess machines.
Computing power was limited in the 1950s, so machines could only play at a very basic level. This is the period when researchers developed the fundamental techniques for evaluating chess positions and for searching possible moves (and opponent’s counter-moves). These ideas are still in use today.
1960s
In the 1960s, AI pioneers Herbert Simon and John McCarthy referred to chess as “the Drosophila of AI”, which meant that chess, like the common fruit fly, represented a relatively simple system that could also be used to explore larger, more complex real-world phenomena. Computer chess was the perfect test-bed for AI research.
By the end of the 1960s, computer chess programs were good enough to occasionally beat against club-level or amateur players.
1970s — 1980s
In 1970–1980, the emphasis was on hardware speed. In the 1950s and 1960s, early pioneers focused on chess heuristics (rules of thumb) to choose the best next moves. In the 1970s and 1980s, there was a much stronger focus was on software improvements as well as use of faster and more specialized hardware. Customized hardware and software allowed programs to conduct much deeper searches of game trees (involving millions of chess positions), something humans did not (because they could not) do.
The 1980s also brought an era of low cost chess computers. First microprocessor-based chess programs started becoming available. Because of the availability of home computers and these programs, anyone could now play chess (and improve their game) against a machine. By the mid-1980s, the sophistication of microprocessor-based chess software had improved so much they began winning tournaments — both against supercomputer based chess programs and some top-ranked human players.
1990s
In 1990s, chess programs began challenging International Chess masters and later Grandmasters. These programs relied much more on memory and brute force than on strategic insight, and they started to consistently beat the best humans. Some dramatic moments in computer chess occurred in 1989 — two widely-respected Grandmasters were defeated by CMU’s Hitech and Deep Thought.
Researchers felt machines could finally beat a World Chess Champion. This got IBM interested so they began working on this challenge in 1989 and built a specialized chess machine, named Deep Blue. It would end up beating Garry Kasparov, the best human chess player.
IBM researchers would be awarded the Fredkin prize, a $100,000 award for the first program to beat a reigning world chess champion, which had gone unclaimed for 17 years. This (and later) victories in computer chess were disappointing to many AI researchers because they were interested in building machines that would succeed via “general intelligence” strategies rather than brute-force. In this sense, chess had started to decouple from AI research.
The remaining sections are about Deep Blue. Deep Blue was a highly specialized machine designed to play chess:
Now:
No human can play the best computers (or even human + computer teams) on equal terms. We (humans) have had well over 1000 years to invent, play, and understand chess — machines have had less than 60 years and they are much much better than we are.
Six-game chess matches had been organized between world champion Garry Kasparov and IBM Deep Blue. First match took place in Philadelphia in February 1996. A rematch took place in New York City in May 1997.
At the time of the first match, Kasparov had a rating of 2800, which was the highest point total ever achieved. Deep Blue’s creators placed the machine at a similar level.
Popular Science asked David Levy about Garry Kasparov match against Deep Blue and Levy stated that,
“…Kasparov can take the match 6 to 0 if he wants to. ‘I’m positive, I’d stake my life on it.’”
On the other hand Monte Newborn, a computer science professor at McGill University said, “I’ll give the computer 4 1/2 to Kasparov 1 1/2 [A draw gives each player a half point.] Once a computer gets better than you, it gets clearly better than you very quickly. At worst, it will get a 4 1/2 score.”
“Once a computer gets better than you, it gets clearly better than you very quickly.”
The outcome was unclear. Deep Thought, predecessor of Deep Blue, was a tournament grandmaster, not a match grandmaster. And this was not a regular tournament, this was a match. This was a different challenge. Why did a match-play present a different challenge than a tournament-play? Because in a match, the players play multiple games against each other. This gave human grandmasters a opportunity to gauge the machine’s weaknesses and exploit those weaknesses to their advantage. According to Hsu,
“Human Grandmasters, in serious matches, learn from computers’ mistakes, exploit the weaknesses, and drive a truck thru the gaping holes.”
IBM needed to build a machine that would have very few weaknesses and those weaknesses needed to be very difficult for human grandmasters to exploit.
Kasparov won the 1996 match. A rematch took place in New York City in 1997. This time, Kasparov lost — Kasparov’s loss to Deep Blue was his first ever chess match loss in his entire life.
So what was so different in 1997?
According to Campbell, Hoane, Hsu, “In fact there are two distinct versions of Deep Blue, one which lost to Garry Kasparov in 1996 and the one which defeated him in 1997.”
In the next section(s), we’ll look into some of the factors that Campbell, Hoane, and Hsu said contributed to Deep Blue’s success in 1997:
In 1985, Feng-hsiung Hsu and (a little later) Murray Campbell worked on ChipTest and then later on Deep Thought, the first grandmaster level chess machine.
In 1988, Deep Thought had beaten grandmaster Bent Larsen (in tournament play) with its customized hardware: a pair of custom built processors, each of which included a VLSI chip to generate moves. Later, an experimental six-processor version of Deep Thought played a (two-games) match against Kasparov and lost.
In 1989, both Hsu and Campbell were hired to work at IBM Research; their new team members included computer scientists Joe Hoane, Jerry Brody and C. J. Tan. Their new project was named Deep Blue and they began to investigate how to use parallel processing to solve complex problems.
Deep Thought II or Deep Blue Prototype? (1991–1995)
What’s in a name? Turns out quite a bit.
The International Computer Chess Association (ICCA) was holding a World Computer Chess Championship tournament in Hong Kong 1995. Hsu, Campbell and team had won the event in 1989 and had not participated in 1992. ICCA approached IBM to sponsor the event and IBM agreed, which meant the team would have to participate.
According to Hsu, they would much rather have prepared for the 1996 face-off against Garry Kasparov, but IBM thought it was a great publicity opportunity.
By 1992, the Deep Blue team had begun working a new chip design. For Kasparov, they had planned to use the newest chips they had designed, but those chips would not be ready before the Hong Kong event. They had to compete with Deep Thought II.
What should the machine participating in the World Computer Chess Championship be called: Deep Thought II or Deep Blue Prototype?
This is when the naming debate took place.
Hsu wrote in his book Behind Deep Blue: Building the Computer that Defeated the World Chess Champion, “Jerry Present, our communications person at the time, wanted to use the name Deep Blue Prototype instead of Deep Thought II. I wanted to use the name Deep Thought II. My reasoning was as follows. Deep Blue, the new machine, would be at least 100 times faster than Deep Thought II in effective search speed, and furthermore, Deep Blue would have a far better grasp of positional concepts in chess. Comparing Deep Blue with Deep Thought II would be like comparing the sun with the moon. Well, I exaggerate a little bit, but the difference in computation power was roughly of the order of a thousand to one, taking into account the far more complicated chess evaluation computation carried out on the Deep Blue chess chips. I was proud of what had been done, and did not want anything to be linked to Deep Blue unless it did use the new chips. Deep Thought II was still using the chess chips that I designed back in 1985.” He continued_,_
“As far as I was concerned, Deep Thought II was a dinosaur about to become extinct. It was not going to usurp the name of our new megaton solar blaster, even if only partially.”
Hsu wanted Deep Thought II, but Brody wanted Deep Blue Prototype because they wanted to be able to say that Deep Blue was the “successor to the reigning World Computer Chess Champion, Deep Blue Prototype, at the time of the match with Garry Kasparov”.
Brody assumed their machine would probably win. And in the “unlikely” event that it did not win the championship, then they would say it was not really Deep Blue playing anyway. The problem, according to Hsu, was that they thought losing was not an “unlikely” event — the team placed their chance of winning at about 50–50.
We’ll refer to the machine as Deep Thought II because Hsu and team did so.
In 1995, Deep Thought II played in Hong Kong. Before that, Deep Thought II had been mostly off-line for at least six months before this tournament. Deep Thought II’s first round opponent was Star Socrates, a parallel chess program from MIT, running on a multi-million dollar supercomputer. According to Hsu, _“its machine was about a hundred times more expensive than the workstation that Deep Thought II ran on. And it’s search speed was at least comparable to Deep Thought I_I”. Star Socrates was a big threat to Deep Thought II.
Hsu wrote in his book Behind Deep Blue, “When Deep Thought II played Star Socrates the year before, I saw for the first time a program that actually “out-searched” Deep Thought II…Yet Deep Thought II had outclassed it easily. Would one year make a difference? Deep Thought II had been off-line for over half a year, and the MIT folk were probably not sitting idle.”
Deep Thought II beat Star Socrates.
While facing it’s last opponent, Fritz, and at one point in the game, Deep Thought II went into a “panic time” state. Deep Thought II was in a bad position and needed to play a move. It had found a move to play, but it was losing and it needed to find a better move. It entered a state where it spent extra time to find an alternative move. In trying to find a good alternative, Deep Thought II was searching a much larger tree (search was exploding). Hsu recalled that Grandmaster Robert Byrne stopped by and whispered to them which move he thought Deep Thought II should play.
Hsu and team could do nothing but wait for Deep Thought II to finish its massive search, wondering if Deep Thought II would actually find the move Robert suggested — the move it badly needed to improve its position. Time was up and after all that searching, Deep Thought II played its originally intended move. It did not find a better move. It was over. Deep Thought II lost. Fritz would go on to win the championship.
Deep Thought II was nowhere close to Deep Blue, but it was also not the same machine as Deep Thought. They had made improvements (from Campbell, Hoane, and Hsu):
On to Deep Blue — the project task was: win a match against the best human world chess champion under regular time control.
According Deep Blue team’s design philosophy, focusing on the integration level was most important:
Regarding speed, they said search speed would be obtained by increasing the level of integration (increasing single chip chess machines) and by using massive parallelism.
Deep Blue (1996)
Deep Blue (1996) was based on a single-chip chess search engine, designed over a period of three years. It ran on a 36-node IBM RS/6000 SP computer. It had 216 chess chips. Most of the evaluation function terms were computed directly on the chips — in order, “to perform the same computation on a general purpose computer, as that done by 1986 Deep Blue, would need at least one trillion instructions per second,” said Hsu. These chess chips evaluated the chess positions in a much greater detail than any other chess program before it.
Each chess chip could search about 1.6 million chess positions per second. And according to Hsu, the theoretical maximum search speed of Deep Blue (1996) was about 300 million positions per second. The observed search speed was about 100 million positions per second.
Deep Blue team had taken over 3 years to design these chips. They received the first chess chips in September of 1995, but there were problems with the chips. So they needed a revised version of the chips, which they didn’t receive until January of 1996. The first match was scheduled for February 1996, leaving them no time to test the entire system.
The full 36-node Deep Blue (1996) played its first tournament-condition games in the actual February 1996 match — against Garry Kasparov.
Some part of the system had played some matches in preparation, but the system that had played, known as Deep Blue Jr., was using just a single-node version of Deep Blue with only 24 chess chips. But even the relatively limited Deep Blue Jr. beat Grandmaster Ilya Gurevich 1.5–0.5, drew Grandmaster Patrick Wol 1–1, and lost to Grandmaster Joel Benjamin 0–2.
Deep Blue (1996) was far more powerful than Deep Blue Jr., in fact, it was the most power chess machine ever built. Still, the Deep Blue team didn’t know how it would actually play because they had never seen it play a single game. Deep Blue (1996) was only a two-week old baby, the most powerful baby ever, but a baby nonetheless. Hsu said,
“Would it be the baby Hercules that strangled the two serpents send by the Goddess Hera? Or were we sending a helpless baby up as a tribute to placate the sea monster Cetus, but without the aid of Perseus? We were afraid it would be the latter.”
The first game Deep Blue played against Kasparov, in February 1996, Deep Blue won.
According to Frederic Friedel, who was Kasparov’s computer consultant, the night after game one Kasparov went for a late night walk (in Philadelphia’s below freezing temperatures). During the walk he asked,
“Frederic, what if this thing is invincible?”
In this first game of the match, Kasparov wrote, “the computer nudged a pawn forward to a square where it could easily be captured. It was a wonderful and extremely human move. If I had been playing White, I might have offered this pawn sacrifice…Humans do this sort of thing all the time. But computers generally calculate each line of play so far as possible within the time allotted…computers’ primary way of evaluating chess positions is by measuring material superiority, they are notoriously materialistic. If they “understood” the game, they might act differently, but they don’t understand. So I was stunned by this pawn sacrifice. What could it mean? I had played a lot of computers but had never experienced anything like this. I could feel — I could smell — a new kind of intelligence across the table. While I played through the rest of the game as best I could, I was lost; it played beautiful, flawless chess the rest of the way and won easily.”
“I could feel — I could smell — a new kind of intelligence across the table.”
It turned out that the pawn was not a sacrifice at all. Deep Blue (1996) did calculate every possible move “all the way to the actual recovery of the pawn six moves later”. Kasparov then asked, “So the question is…
“…if the computer makes the same move that I would make for completely different reasons, has it made an “intelligent” move? Is the intelligence of an action dependent on who (or what) takes it?”
Later in his TED talk, Kasparov said, “When I first met Deep Blue in 1996 in February, I had been the world champion for more than 10 years, and I had played 182 world championship games and hundreds of games against other top players in other competitions. I knew what to expect from my opponents and what to expect from myself. I was used to measure their moves and to gauge their emotional state by watching their body language and looking into their eyes. And then I sat across the chessboard from Deep Blue. I immediately sensed something new, something unsettling. You might experience a similar feeling the first time you ride in a driverless car or the first time your new computer manager issues an order at work. But when I sat at that first game, I couldn’t be sure what is this thing capable of. Technology can advance in leaps, and IBM had invested heavily. I lost that game. And I couldn’t help wondering, might it be invincible? Was my beloved game of chess over? These were human doubts, human fears, and the only thing I knew for sure was that my opponent Deep Blue had no such worries at all.”
_“_And I couldn’t help wondering, might it be invincible? Was my beloved game of chess over? These were human doubts, human fears, and the only thing I knew for sure was that my opponent Deep Blue had no such worries at all.”
The 1996 match was finally won by Kasparov (4–2 score). The match was tied at 2–2 after the first four games and even though it looked like it was a decisive win, it was a fairly close match, closer than generally believed.
According to Monty Newborn’s Beyond Deep Blue: Chess in the Stratosphere, “In Game 5, Kasparov chose to avoid his favorite Sicilian Defense, having been unable to win with it in the first and third games. This implicitly showed some recognition of and respect for his opponent’s strength. Instead, he played the Four Knights Opening. Then out of nowhere, on the 23rd move, he offered a draw to this opponent? And why? Deep Blue thought it was behind by three tenths of a pawn and the team was surprised by the offer. The rules of play permitted the team to decide whether or not to accept the draw, the only decision that could be made by humans on behalf of the computer. Kasparov was a bit short on time — about 20 minutes to make the next 17 moves, about a minute a move in contrast with the rate of play that allotted three minutes per move on average. So perhaps he was playing it safe here, feeling he could defeat Deep Blue in the final game with white pieces….The Deep Blue team huddled to discuss the offer. It huddled so long that Deep Blue played its 24th move, effectively rejecting the offer.”
Kasparov ended up winning that game. Else after five games, going into the final sixth game, the match would have been tied.
Kasparov ended his essay in Time by talking about why he won the first match. He said “I could figure out its priorities and adjust my play. It couldn’t do the same to me. So although I think I did see some signs of intelligence, it’s a weird kind, an inefficient, inflexible kind that makes me think I have a few years left.”
He did not have a few years left. In May 1997, he would lose the rematch to Deep Blue.
The Deep Blue team knew that there were a number of deficiencies in Deep Blue (1996) that they needed to overcome, such as, gaps in chess knowledge and computation speed. So Campbell, Hoane, Hsu made the following changes for Deep Blue (1997):
Then they designed, tested, and tuned the new evaluation function.
Kasparov had defeated Deep Blue (1996).
It was May 1997 and it was time for a rematch. Kasparov won the first game of the rematch.
Predictions were in Kasparov’s favor, many experts predicted the champion to score at least four points out of six. Kasparov was coming off a superb performance at the Linares tournament and his rating was at an all-time high of 2820. In a 2003 movie, he recalled his early confidence:
“I will beat the machine, whatever happens. Look at Game One. It’s just a machine. Machines are stupid.”
The Deep Blue team was disappointed in game 1 and Joel Benjamin, a grandmaster who had imparted his grandmaster chess knowledge to the machine, was convinced Deep Blue (1997) could play much better than it had done in game 1. Postmortem analysis showed that Deep Blue could have drawn that game, if only it could have searched a few more plies deeper…
Then came game 2 — a game so different that a machine playing such a game had never been seen before.
Computers’ strength was in tactical chess; they didn’t play strategically, in other words, until then, computers chose materialistic gains over positional advantages. Until then.
Kasparov had set a trap in which Deep Blue would gain a pawn (a materialistic gain) but lose position. Instead of capturing the exposed pawn (as expected by everyone), Deep Blue (1997), chose another route; it chose a positional advantage. At the time, no machine was playing with, what grandmasters called, strategic foresight. Deep Blue had just shown a glimpse of that.
Deep Blue (1997) played game 2 like a human and that is not how machines were supposed to play. Grandmasters who were observing the game later said that had they not known who was playing, they would have thought that Kasparov was playing one of the greatest human players, maybe even himself. Joel Benjamin said he had witnessed a beautiful game of “chess”, not “computer chess”.
This play shook Kasparov and he never won a game against Deep Blue after that. He altered his style and went on the defensive. According to a (later) Wired article, grandmaster Yasser Seirawan said, “It was an incredibly refined move of defending while ahead to cut out any hint of countermoves, and it sent Garry into a tizzy.”
Malcolm Pein, chess correspondent for The Daily Telegraph of London said, “There were only three explanations:
Either we were seeing some kind of vast quantum leap in chess programming that none of us knew about, or we were seeing the machine calculate far more deeply than anyone heard it could, or a human had intervened during the game.”
Immediately after the game, Kasparov accused IBM of cheating; he alleged that a grandmaster (presumably a top rival) had been behind a certain move. The claim was repeated in the documentary Game Over: Kasparov and the Machine. He claimed a move like that was too human and there was no way a computer could have chosen such a move.
IBM hadn’t cheated, technically. According to the rules, they were allowed, in between games, to make adjustments to their system. “We would say we ‘tweaked’ the program during the match,” said Joel Benjamin, but they didn’t make any significant changes. After Deep Blue’s failure in game one, IBM went back to the drawing board and re-assigned relative weights for different features of the game.
Kasparov did not win the next three games, but neither did Deep Blue — three draws.
Leading up to the final game, the match was tied 2.5–2.5.
Later, the chess-playing community would begin analyzing game 2 and discover something shocking: Kasparov had resigned in a drawn position.
According to Jonathan Schaffer, “The analysis is quite deep and extends slightly beyond Deep Blue’s search horizon. And, apparently, also Kasparov’s. Kasparov’s team, which included Grandmaster Yuri Dokhoian and Frederic Friedel, were faced with the delicate task of revealing the news to Kasparov. They waited until lunch the next day, after he had had a nice glass of wine to drink. After they revealed the hidden drawing resource, Kasparov sunk into deep thought (no pun intended) for five minutes before he conceded that he had missed a draw. He later claimed that this was the first time he had resigned a drawn position.”
The last game was brisk and brutal, in just 19 moves Deep Blue stunned the world. Deep Blue had unseated Kasparov. [See rare footage of the last game.]
The final score was 3.5–2.5. Kasparov was such a great player that he had never lost a match until then — in his entire life. And he had played some of the greatest matches in chess history, including several against Anatoly Karpov.
But this time was different. Devastated, Kasparov said, “I lost my fighting spirit.” Until then he had never before lost a multi-game match against an individual opponent.
After game 6 he said,
“I was not in the mood of playing at all..I’m a human being. When I see something that is well beyond my understanding, I’m afraid.’’
Kasparov was frustrated and admitted at the press conference that he was embarrassed and ashamed of his performance. He later asked IBM to see the logs of the game and IBM refused to show them at the time. IBM was criticized for this, but one thing to remember was that the logs of Deep Blue’s computations and moves were understandable to chess masters. Giving logs to Kasparov during the match would be equivalent to giving away Deep Blue’s strategy, as Drew McDermott said, “…it would be equivalent to bugging the hotel room where he[Kasparov] discussed strategy with his seconds.”
A week after the match, Kasparov expressed his admiration for Deep Blue’s play in game 2: “The decisive game of the match was Game 2, which left a scare in my memory … we saw something that went well beyond our wildest expectations of how well a computer would be able to foresee the long-term positional consequences of its decisions. The machine refused to move to a position that had a decisive short-term advantage — showing a very human sense of danger. I think this moment could mark a revolution in computer science that could earn IBM and the Deep Blue team a Nobel Prize. Even today, weeks later, no other chess-playing program in the world has been able to evaluate correctly the consequences of Deep Blue’s position.”
Deep Blue played much better than in 1996. According to Jonathan Schaeffer some of the reasons why Deep Blue won were:
Garry Kasparov asked for a rematch, but it never occurred.
So who was the better player? Many believed Kasparov was a better player, but his emotions got in the way. That’s probably closer to truth than anything else. In any case, one of the biggest takeaways from this match was that we had collectively underestimated both the physiological and psychological aspects of the match. Our emotions, fears, desires, and doubts had a way of getting the best of us and sometimes we cannot do much more than just stand by and let it pass. And this is a uniquely human problem, one our machine opponents do not worry about.
Our emotions, fears, desires, and doubts had a way of getting the best of us…And this is a uniquely human problem, one our machine opponents do not worry about.
It’s a theme Kasparov hinted at throughout the match and continues to discuss even now [Kasparov’s TED talk].
[Side note: A video summary of Kasparov vs Deep Blue]
Next, a bit on what went into building Deep Blue (1997). Most of this information comes from the following sources:
Some innovations used in Deep Blue
Deep Blue (1997) was a massively parallel system designed for carrying out chess game tree searches. The distributed architecture was composed of 30-nodes (30 processor (one per node)) IBM RS/6000 SP computer, which did high level decision making, and 480 chess chips (each a single-chip chess search engine), with 16 chess chips per SP processor. All nodes had 1GB of RAM, and 4GB of disk.
The 480 chips were running in parallel to do a) deep searches, b) move generation and ordering, c) position evaluation (over 8000 evaluation features) effectively.
Each chess chip could search 2 to 2.5 million chess positions per second so the maximum system speed reached about 1 billion chess positions per second or 40 tera operations.
Deep Blue Architecture and System overview
A brief history of chess machines (repeated from earlier)
Deep Blue (1997) combined both software and hardware for maximum effect and flexibility (see here and here). The basic high-level strategy was as follows:
According to Deep Blue Team papers (Hsu and Campbell, Hoane, Hsu), Deep Blue was organized in three layers. For example, say the system needs to do a 12-ply search from a given position. Then,
Comparison of hardware and software searches (*these are not covered in the blog, but I might come back and write about them.)
To summarize, there were 16 chess chips per workstation in the system and the master workstation node distributed the work to chess chips and used MPI (Message Passing Interface) for communication via a high speed switch with other worker nodes to run a distributed and parallel search.
According to Campbell, Hoane, Hsu, overall system speed varied greatly, depending on the specific characteristics of the positions being searched. “For tactical positions, where long forcing move sequences exist, Deep Blue would average about 100 million positions per second. For quieter positions, speeds close to 200 million positions per second were typical. In the course of the 1997 match with Kasparov, the overall average system speed observed in searches longer than one minute was 126 million positions per second.”
[Side note: if a system can examine 200 million moves per second, then it means it can examine 50 billion positions, in the three minutes allocated for a single move in a chess game.]. It could average 12.2 moves ahead in a 3 minute search.
They said that more software work could speed up the system by a factor of two to four, but they decided to instead focus the software work on increasing the system’s chess knowledge.
Each chess chip operated as a full chess machine. The chess chip was divided into four parts: the move generator, the smart-move stack, the evaluation function, and the search control.
Hsu wrote, “The chess chips in 0.6-micron CMOS searched 2 to 2.5 million chess positions per second per chip. Recent design analysis showed that speedup to about 30 million positions/s is possible with a 0.35-micron process and a new design. Such a chip might make it possible to defeat the World Chess Champion with a desktop personal computer or even a laptop. With a 0.18-micron process and with, say, four chess processors per chip, we could build a chess chip with higher sustained computation speed than the 1997 Deep Blue.”
Block diagram of the chess chip
A chess chip’s basic search algorithm, search tree (left), flow chart (right)
Later, Hsu wrote, “If willing to spend the money, you could build a chess machine more than a hundred times faster than the 1997 Deep Blue without resorting to faster chess chips.”
The move generator in the Deep Blue chip was an extension of the Deep Thought move generator chip, which was an extension of the move generator of the Belle machine. The move generator was based on an 8 x 8 combinatorial array, one cell per square of the chess board and wired like a chess board. It was effectively a silicon chessboard, which meant the wiring corresponded to the way chess pieces move so could evaluate a position and find all legal moves at one time, in one flash.
Hsu described it as follows, “Each cell in the array has four main components: a find-victim transmitter, a find-attacker transmitter, a receiver, and a distributed arbiter. Each cell contains a four-bit piece register that keeps track of the type and color of the piece on the corresponding square of the chessboard.”
The chess chip also used an ordering of selected moves, as described by Campbell, Hoane, Hsu: 1) Capture: Low valued piece captures high valued piece 2) Capture: High valued piece captures low valued piece, 3) No capture.
The evaluation function was a weighted function of different “features” of a chess position. Features ranged from very simple, such as a particular piece on a particular square, to very complex and each feature was given a weighting. Here’s a sample of evaluation features: rooks on seventh rank, knight trap, rook trap, bishop pair, pawn structure, the number of times a move has been played, relative number of times a move has been played, recentness of the move, results of the move, strength of the players that played the moves, etc. The chess chip recognized about 8,000 different features, and each was assigned a value. Most of the features and weights were tuned by hand.
A fully parallel implementation of the evaluation function is too big so evaluation was divided into two parts, fast and slow. Fast evaluation computed in a single cycle and contained all the (easily computed) major evaluation terms. It calculated the fastest and most valuable features.
The game of chess consists of three phases: an opening phase, a middle-game phase and an endgame phase. Depending on the situation, Deep Blue used other strategies to play: opening book, extended book, endgame databases.
The opening phase lasts anywhere from 5 to 15 moves. Computers generally accessed large databases for selecting moves during this phase. Deep Blue had a hand curated (primarily by Grandmaster Joel Benjamin) opening book of 4,000 opening positions. Openings were chosen to emphasize positions that Deep Blue played well. These openings included both tactically complex openings as well as more positional openings that Deep Blue handled well in practice. Deep Blue, however, did not outplay Kasparov during this phase.
Computers also played endgames fairly well, but the best players still played better in this phase. But if the endgame had five or fewer pieces on the board then computers were better because they usually had a database of all five-piece endgames. Deep Blue had an endgame database of all chess positions with five or fewer pieces on the board as well as selected positions with six pieces. Each of the 30 processors in the system contained the 4-piece and some important 5-piece databases on their local disk. The rest of the database was was included on 20-GB RAID disk arrays for online lookup.
The hard part, for computers, was to reach the end game.
In the middle game, the opening book no longer provides guidance and the endgame databases are not yet useful. It is also in the middle game that search explodes. In a typical middle-game positions there are about 30 to 40 moves. And each move can lead to 30 or 40 new positions, each of those positions will have moves, which in turn lead to more positions, and so on. This is what is meant by the saying that the game tree grows at an exponential rate. Computers must somehow search these massive trees to make effective move decisions. And this is where search innovations really helped.
To address this problem, Deep Blue used all the major search innovations and it was equipped with an extended book of a 700,000 Grandmaster games database that it could use, in case the opening book was not sufficient. The idea was to summarize the information available at each position of this large game database and then use that to push Deep Blue in an effective direction.
Kasparov versus Deep Blue: Computer Chess Comes of Age By Monty Newborn
We’re now (finally) done with Deep Blue summary. This should have provided a glimpse of what went into building a machine that beat the best chess player. May 1997 was special point in Artificial intelligence and people have opinions about it even now.
At the press conference following game 6, Kasparov said, “I think it is time for Deep Blue to prove this was not a single event. I personally assure you that, if it starts to play competitive chess, put it in a fair contest and I personally guarantee you I will tear it to pieces.’’ [See rare footage of the last game.] He later appeared on Larry King Live and said he was willing to play Deep Blue “all or nothing, winner take all”. But that did not happen. Not long after the rematch, IBM decided to retire Deep Blue and ended all work on it.
James Coates of the Chicago Tribune wrote in October 1997, “IBM’s Deep Blue division needs dinging because its leaders announced on Sept. 23 that they will retire their massively hyped Deep Blue chess-playing computer with a one-win, one-loss record rather than give the flamboyant and unpredictable grandmaster Garry Kasparov a shot at a rematch. The geniuses who built a computer that whipped the world’s best chess player fair and square in May needs to learn here in October the first lesson that every back-room poker player and pool shooter learns from the git go. I’m talking about the rule of threes. Say we’re playing 9 ball or ping-pong and you wipe me out. I ask for a rematch and barely beat you. Then I say bye-bye, I’m the better player and now I’m going home?” He continued,
_“_Legs have been broken for less in pool halls and card rooms.”
Deep Blue had stunned the world. And everyone had an opinion about the match or Deep Blue or Kasparov or IBM or intelligence or creativity or brute-force or the mind…. Let’s start with Louis Gerstner, CEO of IBM’s view, “What we have is the world’s best chess player vs. Garry Kasparov.”
So, was Deep Blue really the best chess player? Or was Kasparov still the better player? The problem is that the rematch was only six games and Kasparov was only one point behind. Championship matches usually have a lot more games and most end in draws. So, it was hard to say if the rematch of six games said anything about who the better player was. Most would argue that Kasparov was still the better player. But may be that wasn’t the real point. We saw some very special humans put tremendous efforts to create a machine that forced even the best of us to doubt. It beat us at one of our most treasured games and it left us in awe (or some in fear).
Charles Krauthammer, in Be Afraid in the Weekly Standard wrote, “To the amazement of all, not least Kasparov, in this game drained of tactics, Deep Blue won. Brilliantly. Creatively. Humanly. It played with — forgive me — nuance and subtlety.”
“…Deep Blue won. Brilliantly. Creatively. Humanly. It played with — forgive me — nuance and subtlety.”
Even though Deep Blue played a game that appeared to have some elements of “humanness” and even though its victory seems mind-blowing, Rodney Brooks (and others) said that training a machine to play a difficult game of strategy isn’t intelligence, at least not as we use intelligence for other humans; this view was shared by many researchers in AI. On the other side was Drew McDermott, who said that the usual argument people used to say Deep Blue is not intelligent was faulty. He said, “Saying Deep Blue doesn’t really think about chess is like saying an airplane doesn’t really fly because it doesn’t flap its wings.”
So is Deep Blue intelligent?
May be, a little. Deep Blue was certainly not stupid, but it also wasn’t intelligent, in the same way we say another human being is intelligent. What Deep Blue showcased was a narrow kind of intelligence; the kind that shows brilliance in one domain and it does so because humans create better hardware, better software, better algorithms, and better representations. But if you ask these specialized machines to do anything else, they will fail. Deep Blue would have failed at all those other non-chess related tasks we do; it did not exhibit general intelligence. No machine till date has exhibited general intelligence and it appears that they still have a long way to go before they can.
How did Deep Blue do what it did then? When Murray Campbell was asked about a particular move the computer made, he replied, “The system searches through many billions of possibilities before it makes its move decision, and to actually figure out exactly why it made its move is impossible. It takes forever. You can look at various lines and get some ideas, but…
“…you can never know for sure exactly why it did what it did.”
Deep Blue could only play chess, it could do nothing else. This narrow intelligence, however, was already so complex that its makers could not trace its individual decisions. Deep Blue did not make the same move in a given position and it was simply too complicated, too complex, or too hard to understand its decisions. We’re used to hearing about lack of explainability in our systems now, but it was already too hard then.
Until Deep Blue, humans were winning at chess. Machines really couldn’t beat the best humans — not even close. But then Deep Blue won. And soon so did the other computers and they have been beating us ever since. And we don’t sometimes know how they do what they do. This massive growth is their identity — no matter what our rate of improvement, once machines begin to improve, their learning and progress ends up being measured exponentially. And ours doesn’t.
But it’s not really us vs. them, even though it was Garry Kasparov vs. Deep Blue. That was a game, a way to test how machines could learn, improve, and play. But the biggest win was for the humans because their intelligence had created Deep Blue. And what if the best human minds work together with the best machines?
It seems right to end with Garry Kasparov’s TED talk and his view on the experience.
“What I learned from my own experience is that we must face our fears if we want to get the most out of our technology, and we must conquer those fears if we want to get the best out of our humanity. While licking my wounds, I got a lot of inspiration from my battles against Deep Blue. As the old Russian saying goes, if you can’t beat them, join them. Then I thought, what if I could play with a computer — together with a computer at my side, combining our strengths, human intuition plus machine’s calculation, human strategy, machine tactics, human experience, machine’s memory. Could it be the perfect game ever played? But unlike in the past, when machines replaced farm animals, manual labor, now they are coming after people with college degrees and political influence. And as someone who fought machines and lost, I am here to tell you this is excellent, excellent news. Eventually, every profession will have to feel these pressures or else it will mean humanity has ceased to make progress. We don’t get to choose when and where technological progress stops.
We cannot slow down. In fact, we have to speed up. Our technology excels at removing difficulties and uncertainties from our lives, and so we must seek out ever more difficult, ever more uncertain challenges. Machines have calculations. We have understanding. Machines have instructions. We have purpose. Machines have objectivity. We have passion. We should not worry about what our machines can do today. Instead, we should worry about what they still cannot do today, because we will need the help of the new, intelligent machines to turn our grandest dreams into reality. And if we fail, if we fail, it’s not because our machines are too intelligent, or not intelligent enough. If we fail, it’s because we grew complacent and limited our ambitions. Our humanity is not defined by any skill, like swinging a hammer or even playing chess.There’s one thing only a human can do. That’s dream. So let us dream big.”
So let us dream big.
Here’s how the 1997 result stands: The machine won, humanity also won (even though we sometimes forget the latter).
Chess is an old game. It is believed to have originated in Eastern India (280–550). It reached Western Europe and Russia in the 9th century and by the year 1000, it had spread throughout Europe. It became popular and writings about chess theory (of how to play chess) began to appear in the 15th century. Throughout history, many people have said many different things about chess.
Norbert Wiener in 1948 book Cybernetics asked “whether it is possible to construct a chess-playing machine, and whether this sort of ability represents an essential difference between the potentialities of the machine and the mind.”
The idea of creating a chess-playing machine dates to the 18th century. Around 1769, von Kempelen built the chess-playing automaton called The Turk, which became famous before it was exposed as a hoax. In 1912, Leonardo Torres y Quevedo built a machine called El Ajedrecista, which played the endgame, but it was too limited to be useful.
Creation of electronic computers began in the 1930s. ENIAC, which is considered to be the first general-purpose electronic computer, became operational in 1946. By the late 1940s computers were used as research and military tools in US, England, Germany, and the former USSR. Computer chess presented a fascinating and challenging engineering problem.
1940s — 1950s
Early pioneers focused on building machines that would play chess much like humans did, so early chess progress relied heavily on chess heuristics (rules of thumb) to choose the best moves. Researchers emphasized emulation of human chess thought process because they believed teaching a machine how to mimic human thought would produce the best chess machines.
Computing power was limited in the 1950s, so machines could only play at a very basic level. This is the period when researchers developed the fundamental techniques for evaluating chess positions and for searching possible moves (and opponent’s counter-moves). These ideas are still in use today.
1960s
In the 1960s, AI pioneers Herbert Simon and John McCarthy referred to chess as “the Drosophila of AI”, which meant that chess, like the common fruit fly, represented a relatively simple system that could also be used to explore larger, more complex real-world phenomena. Computer chess was the perfect test-bed for AI research.
By the end of the 1960s, computer chess programs were good enough to occasionally beat against club-level or amateur players.
1970s — 1980s
In 1970–1980, the emphasis was on hardware speed. In the 1950s and 1960s, early pioneers focused on chess heuristics (rules of thumb) to choose the best next moves. Even though programs in 1970s and 1980s also used heuristics, there was a much stronger focus was on software improvements as well as use of faster and more specialized hardware. Customized hardware and software allowed programs to conduct much deeper searches of game trees (involving millions of chess positions), something humans did not (because they could not) do.
The 1980s brought an era of low cost chess computers. First microprocessor-based chess programs started becoming available. Because of the availability of home computers and these programs, anyone could now play chess (and improve their game) against a machine. By the mid-1980s, the sophistication of microprocessor-based chess software had improved so much they began winning tournaments — both against supercomputer based chess programs and some top-ranked human players.
1990s
In 1990s, chess programs began challenging International Chess masters and later Grandmasters. These programs relied much more on memory and brute force than on strategic insight, and they started to consistently beat the best humans. Some dramatic moments in computer chess occurred in 1989 — two widely-respected Grandmasters were defeated by CMU’s Hitech and Deep Thought.
Researchers felt machines could finally beat a World Chess Champion. This got IBM interested so they began working on this challenge in 1989 and built a specialized chess machine, named Deep Blue. It would end up beating Garry Kasparov, the best human chess player.
IBM researchers would be awarded the Fredkin prize, a $100,000 award for the first program to beat a reigning world chess champion, which had gone unclaimed for 17 years. This (and later) victories in computer chess were disappointing to many AI researchers because they were interested in building machines that would succeed via “general intelligence” strategies rather than brute-force. In this sense, chess had started to decouple from AI research.
This section is about these three points (Deep Blue was a highly specialized machine designed to play chess.):
Now:
Luke Muehlhauser Historical chess engines’ estimated ELO rankings