科學(xué)奧秘:人工智能與圍棋

字號:

Early in the film "A Beautiful Mind," the mathematician John Nash is seen sitting in a Princeton courtyard, hunched over a playing board covered with small black and white pieces that look like pebbles.
    He was playing Go, an ancient Asian game. Frustration at losing that game inspired the real Nash to pursue the mathematics of game theory, research for which he eventually was awarded a Nobel Prize.
    In recent years, computer experts, particularly those specializing in artificial intelligence, have felt the same fascination and frustration.
    Programming other board games has been a relative snap. Even chess has succumbed to the power of the processor. Five years ago, a chess-playing computer called Deep Blue not only beat but thoroughly humbled Garry Kasparov, the world champion at that time.
    That is because chess, while highly complex, can be reduced to a matter of brute force computation. Go is different. Deceptively easy to learn, either for a computer or a human, it is a game of such depth and complexity that it can take years for a person to become a strong player. To date, no computer has been able to achieve a skill level beyond that of the casual player.
    The game is played on a board divided into a grid of 19 horizontal and 19 vertical lines. Black and white pieces called stones are placed one at a time on the grid's intersections. The object is to acquire and defend territory by surrounding it with stones. Programmers working on Go see it as more accurate than chess in reflecting the ways the human mind works. The challenge of programming a computer to mimic that process goes to the core of artificial intelligence, which involves the study of learning and decision-making, strategic thinking, knowledge representation, pattern recognition and perhaps most intriguingly, intuition.
    Danny Hillis, a computer designer and chairman of the technology company Applied Minds, said the depth of Go made it ripe for the kind of scientific progress that came from studying one example in great detail.
    "We want the equivalent of a fruit fly to study," Hillis said. "Chess was the fruit fly for studying logic. Go may be the fruit fly for studying intuition."
    Along with intuition, pattern recognition is a large part of the game. While computers are good at crunching numbers, peopl are naturally good at matching oetterns. Humans can recognize an acquaintance at a glance, even from the back.
    Daniel Bump, a mathematics professor at Stanford, works on a program called GNU Go in his spare time.
    "You can very quickly look at a chess game and see if there's some major issue,' he said. But to make a decision in Go, he said, players must learn to combine their pattern-matching abilities with the logic and knowledge they have accrued in years of playing.
    One measure of the challenge the game poses is the performance of Go computer programs. The past five years have yielded incremental improvements but no breakthroughs, said David Fotland, a programmer and chip designer in San Jose, California, who created and sells The Many Faces of Go, one of the few commercial Go programs.
    Part of the challenge has to do with processing speed. The typical chess program can evaluate about 300,000 positions in a second, and Deep Blue was able to evaluate some 200 million positions in a second. By midgame, most Go programs can evaluate only a couple of dozen positions each second, said Anders Kierulf, who wrote a program called SmartGo.
    In the course of a chess game, a player has an average of 25 to 35 moves available. In Go, on the other hand, a player can choose from an average of 240 moves. A Go-playing computer would need about 30,000 years to look as far ahead as Deep Blue can with chess in three seconds, said Michael Reiss, a computer scientist in London.
    But the obstacles go deeper than processing power. Not only do Go programs have trouble evaluating positions quickly; they have trouble evaluating them corectly. Nonetheless, the allure of computer Go incereases as the difficulties it poses encourages programmers to advance basic work in artificial intelligence.
    "We think we have the basics of what we do as humans down pat," Bump said. "We get up in the morning and make breakfast, but if you tried to program a computer to do that, you'd quickly find that what's simple to you is incredibly difficult for a computer."
    The same is true for Go. "When you're deciding what variations to consider, your subconscious mind is pruning," he said. "It's hard to say how much is going on in your mind to accomplish this pruning, but in a position on the board where I'd look at 10 variations, the computer has to look at thousands, maybe a million positions to come to the same conclusions, or to wrong conclusions."
    Reiss, an expert in neural networks, compared a human being's ability to recognize a strong or weak position in Go with the ability to distinguish between an image of a chair and one of a bicycle. Both tasks, he said are hugely difficult for a computer.
    For that reason, Fotland said, "writing a strong Go program will teach us more about making computers think like people than writing a strong chess program."
    電影《美麗心靈》里有這樣一幕場景:教學(xué)家約翰·納什坐在普林斯頓大學(xué)的庭院里,俯身看著一塊游戲,木板上點綴著黑色和白色的像鵝卵石那樣的東西。
    納什正在下圍棋,圍棋是一個源自亞洲的古老游戲。輸?shù)粲螒蚴顾芫趩?,卻促使他專注博弈的數(shù)學(xué)研究,他也最終由此獲得諾貝爾獎。
    近幾年來,計算機(jī)科學(xué)家們,特別是專攻人工智能這塊的科學(xué)家們也同樣感受到納什的這種癡迷和沮喪。
    其它棋類游戲的電腦程序都比較簡單編寫,國際象棋也在功能強(qiáng)勁的處理器面前乖乖屈服。五年前,一部叫“深藍(lán)”的電腦不僅擊垮了當(dāng)時的世界冠軍卡斯帕羅夫,而且還重挫了他的銳氣。
    這是因為國際象棋雖然錯綜復(fù)雜,但仍可簡化成強(qiáng)力運算。圍棋卻不大一樣,看上去好像很容易學(xué)會——無論人還是電腦,但事實上要達(dá)到精通的水平卻要付出多年的摸索。到目前為止,仍沒有電腦能夠超出業(yè)余圍棋手的水平。
    圍棋游戲是在一塊由19條水平線和19條垂直線圍成格子的木板上進(jìn)行的。黑色或白色的棋子每次只能下一顆于格子交叉處。目的是通過圍格子獲得或保衛(wèi)“領(lǐng)土”。編程人員認(rèn)為圍棋比象棋更能精確地反映人類思維的方式。要讓電腦模仿人那樣思考牽涉到人工智能的核心技術(shù),例如要教會電腦如何學(xué)習(xí)、下結(jié)論、戰(zhàn)略考慮、知識再現(xiàn)、模式識別,以及也許是最引人注目的技術(shù)——直覺認(rèn)知。
    電腦工程師兼Applied Minds科技公司的主席丹尼·席立斯表示:科學(xué)的進(jìn)步源于對典型事物的全面研究,而對深奧圍棋的研究正是促進(jìn)科學(xué)進(jìn)步的好時機(jī)。
    “我們要研究的是像果蠅那樣具有代表性的東西”,席立斯說。“國際象棋是研究邏輯的典型物,圍棋卻是研究直覺認(rèn)知的典型物”。
    跟直覺認(rèn)知一樣,模式識別在游戲中占了很大部分。電腦在運算數(shù)字方面很在行,但人天生就擅長模式匹配,匆匆一瞥甚至是背影都可以認(rèn)出熟人。
    斯坦福大學(xué)的數(shù)學(xué)教授,丹尼·巴布在空閑時編寫一個名叫GNU的圍棋程序。
    他說:“國際象棋比賽中我們只要看一眼就知道大致的結(jié)果,但下圍棋時,棋手必須運用多年積累的知識和邏輯并綜合自己的模式匹配能力,才能下好一盤棋”。
    大衛(wèi)·福蘭認(rèn)為衡量一個電腦圍棋游戲的標(biāo)準(zhǔn)是圍棋軟件的性能,在過去的五年里,圍棋軟件雖然進(jìn)步很大,卻沒有重大突破。福蘭是加州圣何塞市的編程人員和芯片設(shè)計師,他編寫并出售一套叫“多面圍棋”的軟件——為數(shù)不多的商業(yè)圍棋軟件之一。
    “游戲軟件的性能部分受制于數(shù)據(jù)處理速度。傳統(tǒng)的國際象棋程序每秒可以計算30萬步,深藍(lán)每秒更是可以計算2億步。然而大部分的圍棋程序到游戲進(jìn)行到一半時每秒只能計算幾十步”,“聰明圍棋”軟件的設(shè)計者安德·可魯夫這樣說。
    對國際象棋來說,每一步棋棋手大概有25到35種下法,但圍棋卻有240多種。照倫敦一位電腦專家邁克爾·雷斯的說法,深藍(lán)電腦在3秒鐘就能計算出國際象棋很多步以后的各種變化,而處理相同步數(shù)圍棋的變化情況,圍棋程序卻需要運行3萬年之久。
    但障礙還不止表現(xiàn)在數(shù)據(jù)的處理能力上,圍棋程序不但計算步數(shù)很慢,而且計算的準(zhǔn)確性也不高。盡管圍棋程序的開發(fā)如此之難,編程人員越發(fā)產(chǎn)生了濃厚的興趣,他們必須在人工智能的基礎(chǔ)研究上有所突破。
    “我們認(rèn)為我們已經(jīng)完全掌握了人類的行為規(guī)律”,巴布說,“我們在早上起床,然后準(zhǔn)備早餐。但你如果想要讓電腦做這種事情,你馬上會發(fā)現(xiàn)我們輕而易舉能做到的事,對電腦來說卻難似登天。”
    讓電腦下圍棋也是一樣。“當(dāng)你考慮棋局的種種變數(shù)時,你下意識地進(jìn)行篩選”,巴布說,“很難說得清這個篩選過程是怎樣的,我面對棋盤思考10種可能的變化情況,要得出相同的結(jié)論電腦卻需要考慮上千種,甚至是上百萬種的位置變化,而出來的結(jié)果還可能是錯誤的?!?BR>    雷斯他還是神經(jīng)網(wǎng)絡(luò)系統(tǒng)的專家,他比較了人類的兩種辨別能力,一種是辨別出圍棋棋局中的關(guān)鍵位點,另一種是辨別開椅子和自行車的圖片,他說,這兩種能力對電腦來說都是難乎其難。
    正因如此,大衛(wèi)·福蘭指出:“編寫一套好的圍棋程序比編寫一套好的象棋程序更具挑戰(zhàn)性,它能讓電腦更接近人的思維方式”。
    (注:果蠅,fruit fly,因其壽命短,繁殖力強(qiáng)而成為研究遺傳學(xué)的典型,在本文中指代有代表性的事物)