Slashdot Mirror


Microsoft Research Takes On Go

mikejuk writes "Microsoft Research has used F# and AI to implement a consumer-quality game of Go — arguably the most difficult two-person game to implement. They have used an interesting approach to the problem of playing the game, which is a pragmatic cross between tree search with pruning and machine learning to spot moves with a 'good shape.' The whole lot has been packaged into an XNA-based game with a story."

38 of 175 comments (clear)

  1. Confusing title by PhrostyMcByte · · Score: 3, Interesting

    When I saw "Microsoft takes on Go", I thought of Google Go. It only adds to the confusion that both F# and Go attempt to solve some concurrency issues, though I thought it odd to compete with an imperative language using a functional one. I had to do a double-take to understand it was talking about a game.

    Sheesh, I need sleep. And perhaps to stop learning so many useless programming languages.

    1. Re:Confusing title by PolygamousRanchKid+ · · Score: 2

      And perhaps to stop learning so many useless programming languages.

      FORTRAN, ALGOL, COBOL ... Forth ... ? Hey, if you can make money programming it, it's not useless.

      --
      Schroedinger's Brexit: The UK is both in and out of the EU at the same time!
  2. Go is not a game by Kim0 · · Score: 5, Interesting

    Go is not a game because it does not have rules that are clearly interpretable, except the new Tromp/Taylor rules.
    One sign of this is that Japanese monks have for about 400 hundred years quarreled about how certain patterns should be interpreted.

    When I started to learn the game, I was told that it was exceedingly simple, but learned that there was a thick book of how to interpret patterns, which obviously is not simple. And after playing it a little, and thinking about it, it became apparent to me that there were end game effects that were simply ignored. The Japanese versus Chinese "rules" give very different endgames, but the practice is to simply ignore that and pretend there is no problem. One just stops when the players agree that the rest of the game would be obvious and boring, without that necessarily being true.

    Robert Jasiek has done extensive analysis of Go, and seems to be the only one actually understanding the game as it is played in practice.
    Here are a short list of the major mistakes that Go rulesets contain.
    Here are lots of short analyses of different scoring methods.
    Here are some game patterns that give different problems in different rulesets.

    When it is not even possible to analyze parts of games then true optimal play regresses to quarreling about it, which is precisely what the Japanese tradition has done for at least some hundred years. Robert Jasiek has made the only consistent interpretation of the Japanese "rules", and it is somewhat insane to read, with 3 levels of recursion. It means that instead of there just being an ordinary game tree, the rules at each node in the game tree are determined by hypothetical game trees at these nodes, and the same goes for the hypothetical game trees. Gaaahrgle!

    Those programming Go players typically do statistics on games played by humans instead of having a scoring function, or they use the Tromp/Taylor rules.

    So Go is riddled with quarrels and pretense. Not a game in practice. More like politics, or Zen.

    Kim0+

    1. Re:Go is not a game by Anonymous Coward · · Score: 2, Insightful

      Sir, I think you should re-read what you just wrote.

      Since when is Go not a game? Because it's just complicated?

      Have you ever actually played go? If so, you'd know it takes alot of skill and even more practice to master.

      Anything that takes practice, skill and involves fun is a game.

      Red Rover does not have any 'rules' or 'regulations'. Yet, I bet you played it when you were little.

      ~Valk

    2. Re:Go is not a game by dair · · Score: 5, Insightful

      In practice the problem you see (ambiguities in the endgame) are only really an issue for computer Go. Human players rarely disagree over when a game is "over", as typically the outcome becomes obvious long before each stone is played out to the absolute end.

      Perhaps a good analogy is poetry: it is perfectly possible for a poem to convey meaning, even if it does not conform to the rules of the language or have a literal meaning (and yet, people still understand it).

      The thick book of "how to interpret patterns" is simply a set of standard plays that people have found empirically to work well (in exactly the same way as opening books are used in chess). Like chess, you are free to ignore those patterns if you like, but typically that leaves you in a weaker position than you would be in otherwise.

      These patterns are most commonly used in the opening moves, but local instances of them pop up all the time ("if he moves there, I should move here, then he *has* to move there I'll capture these stones").

      The rule is that game is over when both players agree that it is over: if there is a disagreement, the game is played on. Some positions lead to an infinite repeat (A captures B, B captures A, A captures B, etc) but thee plays typically don't determine the final score (if the score was equal, and there was an infinite repeat, then humans would simply call it a draw). Computers can recognise trivial cases of this easily, and do OKish with heuristics for simple cases.

      However the real difficulty in computer Go is understanding just why humans make the moves they do, as outside of the standard sequences a move is often made intuitively as a way to steer the other player even though the consequences of that move may be some way off (or may need to be abandoned, or redirected, or reused in some unplanned way).

      Go is a truly fascinating game, and also a very human one (computers will play it well one day, but probably about the same time that they get good at writing poems, playing tricks, or asking why).

    3. Re:Go is not a game by Anonymous Coward · · Score: 4, Interesting

      Rubbish

      Go is a great game. The chinese and aga rules are precise and assign a score to every position in a simple way with no arguement. The japanese rules are potentially complex but in practise the sort of positions in which difficulties arise rarely if ever occur. The Japanese rules are more conveniant to play with although not as mathematically complete. Still, in 10 years of tournament play I have never seen a position the outcome of which depended on the rules employed.

    4. Re:Go is not a game by Anonymous Coward · · Score: 2, Insightful

      Do you actually play the game. From your post it seems like you are trying to program it without any insight as a player. Sorry, but that will fail.

      Go is not a game because it does not have rules that are clearly interpretable, except the new Tromp/Taylor rules.

      Wrong, the rules are simple and clearly interpretable for humans. There are some odd cases, in which the different rule sets disagree, but they are very rare and it practice the game in exactly the same regardless of which set of rules you use.

      The Japanese versus Chinese "rules" give very different endgames, but the practice is to simply ignore that and pretend there is no problem.

      Wrong. Except a few rare situation they are equivalent.

      Robert Jasiek has done extensive analysis of Go, and seems to be the only one actually understanding the game as it is played in practice.

      Jasiek has done a nice job of cleaning up the rules text, but again, in practice it is no difference at all. I've been playing for ten years and I have never ever made a different move because of the rule set.

      Please try to learn the game a bit deeper before making judgements. Go is a hard game for beginners to grasp, and you will have to play many games before the confusion starts to clear.

    5. Re:Go is not a game by Demonoid-Penguin · · Score: 2

      Sir, I think you should re-read what you just wrote.

      Since when is Go not a game? Because it's just complicated?

      Have you ever actually played go? If so, you'd know it takes alot of skill and even more practice to master.

      Anything that takes practice, skill and involves fun is a game.

      Red Rover does not have any 'rules' or 'regulations'. Yet, I bet you played it when you were little.

      ~Valk

      Everything is a game. There's always a winner, and a loser, the trick is to determine when you are the latter, to become the former. All games have consequences. In the end the only guarantee you have is, that sooner or later, you lose.

      Wake up Jake!

    6. Re:Go is not a game by Vintermann · · Score: 3, Informative

      Not under Japanese rules, or Korean rules, or any ruleset lacking a superko rule. What dair(210) says is also wrong: The corner cases are NOT a problem for computer go, because programs rarely play with the traditional, informal rulesets lacking superko. (When they are forced to, such as in certain tournaments, they perform slightly worse, but not disastrously so).

      A more common problem for Go programs is bugs in the superko handling. Nick Wedd runs monthly bot tournaments at KGS, if you take a look at his reports, you'll see hardly a tournament goes by without some program crashing, or timing out due to wanting to play an illegal move (forbidden by superko)

      --
      xkcd is not in the sudoers file. This incident will be reported.
    7. Re:Go is not a game by spottedkangaroo · · Score: 3, Informative

      You only see these kinds of "problems" with the game when you haven't played long enough to understand the game. There really aren't any problems along the lines you're thinking. Nearly everything you said is incorrect. The Chinese vs Japanese rules do sometimes differ by a few points here and there, but rarely, and if you know which ruleset you're playing under it really shouldn't matter. In fact, if you include stone passing (see AGA Rules) then Chinese and Japanese rules work out the same. Oh, the horror.

      As to the Ko rules, ... yes, I've personally fretted over the dreaded triple Ko and I've been frustrated over 4 in the corner, but the triple ko never really comes up and you can play out 4 in the corner if you're obstinate. There are complicated solutions to the tripple ko, such as Ing rules, but nobody cares. It just doesn't matter.

      I've also played many new players, presumably like yourself, that can't tell when a game should end. That's normal when you're starting out. What we do with those new players is keep playing until they feel like stopping and sometimes comment on why their plans don't work or why they're losing points. You see, if you keep playing in Japanese rules, you will lose points. Under Chinese rules, you simply keep playing until you get really bored, so you only need to point out that the score isn't changing and isn't likely to change. Problem solved.

      The thing that really puzzles me more than anything is why you'd take the time to claim Go isn't a game. Clearly it is, people play it all the time; millions in fact. It's even televised in many Asian countries. Is it some kind of grudge? Are you a chess player that's really jealous? I don't get it. Weird.

      --
      Imagine if you weren't allowed to use roads because a bus company complained about your driving 3 times. --skunkpussy
    8. Re:Go is not a game by shadowofwind · · Score: 3, Interesting

      This is like saying that real numbers are political and not mathematical because of the funny way that infinities are defined and handled.

    9. Re:Go is not a game by nloop · · Score: 3, Insightful

      19-10 kyu is a casual player. gnu go is 5 kyu, beyond the casual range, actually getting pretty close to a dan rating. A few months gets you within spitting distance of dan? Perhaps you haven't seen beginners play gnu go. The reputation of go engines seems stuck in the 90s while their gameplay isn't. Watch them play, especially against someone with less experience.

    10. Re:Go is not a game by zacronos · · Score: 2

      Go is not a game because it does not have rules that are clearly interpretable, except the new Tromp/Taylor rules.
      [...]
      When it is not even possible to analyze parts of games then true optimal play regresses to quarreling about it
      [...]
      So Go is riddled with quarrels and pretense. Not a game in practice. More like politics, or Zen.

      So are you saying anything that has any ambiguities or regional variations in the rules (even if just in edge cases) cannot qualify as a game? Or that only games where the concept of "optimal play" is valid can qualify as games? I would disagree strongly with either of those positions.

      I have played PLENTY of board games where not-so-uncommon edge cases are not adequately handled. That doesn't stop me from playing, and it doesn't stop me from having fun. Every time I sit down with a new group of people to play, say, Hearts or Euchre, I preemptively ask how we're going to handle certain situations. Different people play slightly different ways, and that's fine with me.

      There is also such a thing as games which are played for the enjoyable experience of playing them, and so "optimal play" makes no sense. The children's game "patty-cake" is a pretty clear example, or any number of children's games, especially the ones that children make up on the spot. What about improv games such as on the TV show "Whose Line is it Anyway?" My friends and I sometimes have improv parties, where we exclusively play games like that. Or what about pencil-and-paper RPGs? Optimal play is often not the most enjoyable way to play, if it is even a concept that can be defined for a given game.

      Maybe more importantly, I'd like to point out that quarrels, pretense, and politics are central tenets upon which many games are built -- I would argue that those things are likely the most prolific inspirations for games that one could find. Formal game theory is very useful for analyzing politics and quarrels, and has also been used to study the effects of pretense and lying. Aren't chess and Go both likely inspired by war?

      The only way I can make sense of your post is if I conclude that when you use the word "game", you mean something very much more specific than the rest of us, containing only a tiny subset of what is generally referred to as a game in common language.

    11. Re:Go is not a game by nloop · · Score: 2

      Fuego playing 9x9 has a 5d rank on KGS, looks like 2k for 19x19. I'm pretty sure crazystone can also play that well.

      It was crazystone that used a 9 stone handicap to beat a 9p player with a 9 stone handicap if I'm not mistaken.

    12. Re:Go is not a game by Raenex · · Score: 2

      The upshot of this is that endgames of almost maximally strong Go players may be almost infinitely long and complicated.

      No, it isn't. You need to get your head out of the clouds and actually learn Go. The game simplifies greatly the closer it gets to the endgame. That's why experienced human players can almost always agree on what stones are dead under Japanese rules without using Jasiek's precise definition of Japanese rules.

    13. Re:Go is not a game by Raenex · · Score: 2

      Interesting, can you name any such software that can play go and has a 4 dan rank?

      http://www.gokgs.com/graphPage.jsp?user=zen19

    14. Re:Go is not a game by Raenex · · Score: 2

      I got into Go several years ago

      As you state, your experience is several years out of date. Go programs went through a great leap from 2006 to present, due to the technique of Monte Carlo Tree Search.

    15. Re:Go is not a game by Raenex · · Score: 2

      In fact, if you include stone passing (see AGA Rules) then Chinese and Japanese rules work out the same.

      As if by magic? You're confused. The AGA rules are just Chinese rules in disguise. They let you mechanically count the board as you would with Japanese rules, but the winner would be determined as if played under Chinese rules, not Japanese rules. Dame is worth 1 point and needs to be strategically considered.

      I've also played many new players, presumably like yourself, that can't tell when a game should end. That's normal when you're starting out. What we do with those new players is keep playing until they feel like stopping and sometimes comment on why their plans don't work or why they're losing points. You see, if you keep playing in Japanese rules, you will lose points.

      A smart and logical student will plunk a stone done in the middle of his opponent's territory and point out that it takes 4 stones for their opponent to kill the stone, thus causing the opponent to lose points. The student is then berated and made to feel ashamed for being "stubborn" for trying to apply logic.

      Under Chinese rules, you simply keep playing until you get really bored, so you only need to point out that the score isn't changing and isn't likely to change. Problem solved.

      Yes, Chinese rules actually make sense when you try to play the game out. That's why new players should learn them first.

    16. Re:Go is not a game by Raenex · · Score: 4, Informative

      In practice the problem you see (ambiguities in the endgame) are only really an issue for computer Go.

      Wrong. New players frequently have a hard time understanding Japanese rules. This is why people like Kim0 exist. On their own, the Japanese rules logically don't make sense. You have to know how to play to end the game, and you have to know how to end the game before you can learn how to play.

      Instead, new players should be referred to Chinese-style rules. The Japanese rules are fine for experienced players.

      Perhaps a good analogy is poetry

      No, that's a terrible analogy. There are no rules to poetry, and there is no winner and loser. You're just adding confusion.

      The rule is that game is over when both players agree that it is over: if there is a disagreement, the game is played on.

      That's the problem with Japanese rules. It is not easy to "play on" and determine the score. It is trivial with Chinese-style rules.

      Go is a truly fascinating game, and also a very human one (computers will play it well one day, but probably about the same time that they get good at writing poems, playing tricks, or asking why).

      Computers already play the game well. They have reached dan status.

  3. WTF? by mac1235 · · Score: 2
    "Many games are written in C++, but this requires a lot of ‘libraries’ to store information, along with a lot of man power to create them. XNA comes with a number of pre-made libraries, making it a lot easier to program with."

    I thought C++, (as a well established Programming language) would have more libraries than XNA, which I had not previously heard of?

    1. Re:WTF? by mustPushCart · · Score: 3, Informative

      XNA is effectively a game specific library that lets you develop for the xbox and windows. When they say XNA they really mean XNA + .net which combined has a pretty extensive library for game development. While XNA has a lot of helper libraries that let you work with DirectX and managed code, it does not really have anything specific related to AI and since this is an AI project primarily that statement seems to be an advertisement for XNA.

    2. Re:WTF? by bcmm · · Score: 3, Insightful
      --
      # cat /dev/mem | strings | grep -i llama
      Damn, my RAM is full of llamas.
    3. Re:WTF? by phantomfive · · Score: 2

      It was described poorly in the article. XNA is Microsoft's framework for writing games in C#, in other words, it IS a library. It's one way to program graphics on the Xbox, and the only way on Windows Phone 7. It's not as capable as some other frameworks (if you want to see games like this on WP7, forget about it). If you like C#, you will probably like XNA. In my opinion it's as good as any other sprite framework.

      --
      Qxe4
  4. I seem to recall by thesk8ingtoad · · Score: 3, Interesting

    Reading a research paper a few years ago that presented the idea that the best way to approach the game was through catastrophe avoidance. The idea was to identify the moves that would lead to a massive loss, then to take another move at random. I wonder how their AI would fare in comparison.

  5. It isn't very strong by Anonymous Coward · · Score: 4, Insightful

    Q: How strong is the AI?
    A: The AI is strong enough that the game could challenge the vast majority of newcomers to the game. It doesn't compare like-for-like with other high performance computing solutions that have been developed for Go - which only Go experts would be able to compete with - but it does give it a more natural feel and makes the game accessible for a broader audience.

    I got excited when I saw the story. Sigh. This won't appeal to people who already play Go. It may appeal to people who have never played. I'm guessing that the game itself won't produce many more Go players. On the other hand, people may read the story on Slashdot and become curious.

    It is relatively easy to beat the existing Go games on a 19x19 board. On the other hand, the existing games are OK on a 9x9 board. On the smaller board, tactics rule. On the full size board, strategy rules. If you make a mistake on the small board, you will be ruthlessly punished.

    What does "beat" mean in Go? In Go, it is possible for an expert and a beginner to have a satisfying game. The weaker player gets to place a certain number of stones on the board before the stronger player makes his first move. The handicap system is pretty reliable and is part of Go culture. If they are properly handicapped, the weaker player will beat the stronger player 50% of the time.

    If we want to seriously talk about how strong a computer game is, we have to talk about handicap. A computer game that needs only a one stone handicap to keep up with an expert would be exciting. With a zero stone handicap, it wouldn't sound very good because it would lose most of the time. Currently, the best programs, running on heavy duty computers, can keep up if they are given a six or seven stone handicap. Wiki

    1. Re:It isn't very strong by Vintermann · · Score: 3, Informative

      It is relatively easy to beat the existing Go games on a 19x19 board.

      Really. When you say such a thing, it can mean one of two things: You're stronger than European 1 Dan (corresponding to Japanese/AGA 4 Dan, KGS 2-3 Dan) or you haven't been playing computer Go much lately. Many Faces of Go, Zen, Fuego, Aya play on a level it will take years of serious club play to beat (for most of us).

      --
      xkcd is not in the sudoers file. This incident will be reported.
  6. Go is a pretty cool game by Anonymous Coward · · Score: 5, Funny

    Go's a pretty cool game, but maybe some of you have heard of Chess? It involves pieces that can do a lot of interesting moves and some of the existing boards out there can be incredibly ornate.

    Sorry, I wanted to be the equivalent of "That Guy" that shows up to discuss Go every time there's a chess story anywhere on the planet.

    1. Re:Go is a pretty cool game by shadowofwind · · Score: 2

      Ha ha, enjoy the moment. 'That go guy' managed to get a scene inserted in the new TRON movie. What was the last cool movie you got into? Blade Runner? And a movie chess scene is always a display of raw intellectual strength, as opposed to a zen-like power to master nature.

  7. Re:Capitalization by EnglishTim · · Score: 2

    The British Go Association would capitalise Go, Chess and Checkers, although it would be more likely to refer to the last one as Draughts.

    I don't know whether they're correct.

  8. Re:Explanation of go AI by cheesecake23 · · Score: 4, Informative

    Monte Carlo

    Yes, it's just a variant of Monte Carlo, but don't knock it. Recent programs implementing the algorithm have improved their handicaps by up to 5 stones, which is huge. The top bots at the KGS Go server are now ranked up to 4 dan (like a good amateur player) in games against humans.

    You may want to read this short article in the Guardian about these recent improvements in the MoGo go bot. In October 2009 (6 months after this article appeared) a version of MoGo finally beat a top-ranking (9 dan) professional in an even game on a 9x9 board.

  9. Want to play the game for free? Some pointers by Reemi · · Score: 4, Informative

    This article reads like a commercial without any scientific background w.r.t. the algorithms used. They even state it does not perform as well as other available programs.

    Still, interested giving the game a try? It is really simple.

    Start here to learn the rules: http://playgo.to/iwtg/

    Like the problem solving, this is a good site for problems: http://goproblems.com/ Note, 30kyu problems are the easiest, then 25kyu etc. Hardest are the dan problems. (Believe me, they are really difficult)

    Want to play against the computer? GnuGo is your friend> http://www.gnu.org/software/gnugo/gnugo.html

    Playing against real oponents on the web, there are 2 options: Turn-based (the slow progress variant) or real-time. I can recommend for the turn-based variant Dragon Go Server and Online Go Server: http://www.dragongoserver.net/ http://www.online-go.com/

    Personally, I'm not into real-time, but KGS is an alternative: http://www.gokgs.com/ Note, people might not always be in the mood for chatting here.

    Getting hooked, try to find a local club or check for players in your neighbourhood: http://igolocal.net/

    Have fun.

  10. Re:Hikaru no Go by Anonymous Coward · · Score: 2, Interesting

    Watashi ha Hikaru. Why I no go? I must know. Naze da! Naze da! Sabedu ka!

    Please, Hikaru is good. Hikaru go, OK?

  11. Re:Capitalization by adamdoyle · · Score: 2

    You don't capitalize "checkers" or "chess"; you shouldn't capitalize "go".

    It's one of those areas in which you're dealing with shades of gray. You wouldn't say "the chess" or "the go," which is a characteristic of a proper noun. (not being preceded by "the") Proper nouns are, obviously, capitalized. It really comes down to whether or not "chess" and "go" are proper nouns. They are names, which are generally proper nouns, but it's usually more _brand_ names than anything. It's not really something I would criticize though. It could really go either way..

  12. Re:General applicability? by Kim0 · · Score: 2

    My mental image is a rabbit running into a thicket to avoid a fox, or eagle.

    The Norwegian young chessmaster Magnus Karlsen is said to rely on making the game so complex that only he understands it.

    Kim0+

  13. Re:Capitalization by BitterOak · · Score: 2

    You don't capitalize "checkers" or "chess"; you shouldn't capitalize "go".

    The difference is, the words "checkers" and "chess" do not have any other meanings in the English language besides the games, so there is no ambiguity. The word "go", however, is a very common verb in the English language, so capitalizing the name of the game helps to clarify the meaning.

    --
    If I can be modded down for being a troll, can I be modded up for being an orc, or a balrog?
  14. Re:Circular reasoning (nothing is obvious) by mangu · · Score: 2

    Q: What groups are "alive"?
    A: Those groups that Go masters agree are alive.

    Q: Who is a Go master?
    A: People who know which groups are alive.

    As I said, circular reasoning.

    Assuming a set of rules that is unambiguous and algorithmic, then the problem of writing a perfect software for playing Go should be only a question of having enough machine power, just like for chess.

    It's interesting that after machines started beating the top chess players they discovered some endings that were formerly thought to be draws that actually could be won if played perfectly, although it would take a large number of plays to win. I'm willing to bet that some day the same will be found to be true for Go.

  15. Re:Circular reasoning (nothing is obvious) by Anonymous Coward · · Score: 2, Informative

    What you point out is a problem of Japanese rule, which is inherently flawed. Basically it replies on the agreement of both parties on the live/death of each group, and do not support playing out the actual result, because by playing out the result (like actually killing a group) can change your score and may alter the game winner. However, it's only a problem with the Japanese rules, not with the Chinese rules. In Chinese rules, all stones and territory are counted together, and if there's a dispute, the game can go on without affecting the score. Under Chinese rules, theoretically the ultimate end game is the entire board being filled up withe stones, except the empty spots you need to keep your groups alive. So, from this view, in practice all games did not actually end, but the rest of the game is too obvious to be played out. It's like entering check mate in chess, you don't need to really capture the king to know the game has ended.

    It's a long story how the Japanese 'misunderstood' the rules when they imported Go into Japan at around 700AD. Since Japan dominated the Go world in the past 100 years up to the 1990s, and Go is introduced to the west mainly by the japanese, thus their rule set became the most taught and known to westerners. Ideally, the japanese rule set should be abandoned, but then nationalism and pride makes it very hard to do. The lucky thing is these issues are mostly theoretical, and do not affect practice much.

  16. IGO for DOS, Windows, iPhone by northerner · · Score: 2
    The Microsoft Go program is only for Xbox.

    For those that would like to try Go on a PC, there is a good version on Go for DOS & Windows called IGO by David Fotland, and it's free.
    I've been using the DOS version which runs fine in a DOS window on a Windows PC.
    There is a Windows version called Igowin and a version for the iPhone or iPod Touch or iPad.
    I haven't tried the iPhone version yet.

    IGO plays on a reduced sized 9x9 board, but is good for an introduction to the game.
    The fill size version with a 19x19 board is called The Many Faces of Go and is available for purchase.
    The readme.txt file says:
    This program contains the same go engine as The Many Faces of Go, but only uses the first 5 levels (out of 10). It uses the same graphics as The Many Faces of Go, but is limited to 9x9 boards only.

    To download:
    http://www.smart-games.com/igo.html
    http://www.smart-games.com/igowin.html
    [the Windows has info on the iPod version]