Gold Bullion (Poker Bot) by Charles Bloom and Drew Card October 10, 2004 ========================================================== = What It Is GoldBullion is an Artificial Intelligence (AI) engine which plays Limit Texas Hold'Em. It plays only ring games of Limit Hold'Em ; it does not play well heads up. It currently does not learn about its opponents at all. I indented to use an entropy-minimization (ala Context Trie Weighting) form of machine learning to adapt an opponent model, but never got that far. It uses a fixed opponent model, so can be easily confused if you play strangely. Gold Bullion contains a fully functioning Bayesian Simulating Poker AI Engine, similar to the one used by the Alberta "Poki" bot. It's written in fast C++ and is much more powerful and more accurate than their Java bot. Gold Bullion can be run against itself, against a human player, or in various simulation modes. It can be used to test play strategies and AI play algorithms. ========================================================== = How It Works Bayesian estimation is used to guess the probability of each possible pair of hole cards that an opponent has. For each action we see an opponent make, we update their hole card weights using the simple Bayesian formula (in terms of weights, not probabilities) : P(hole H after action A) = P(action A given hole H) * P(hole H before action A) Initially all weights are equal (except for holes that intersect with our own two holes or cards on the table - we know those holes are impossible). The key term is the Opponent Model function - P(action A given hole H) Which is evaluated using the "Opponent AI". Of course, the Opponent AI is itself an AI engine, and it may work the same way, using its own Bayesian estimation of what we have. In fact, each of the AI players may have their own Bayesian estimation of everyone else, and they won't be the same. GoldBullion provides many different OpponentModels (the "PreFlop..." and "PostFlop..." routines). Now, to choose our own action, we use the P(H) for all our opponents. There are two primary ways to do this - 1) evaluate our hole vs. the holes of our opponents (weighted by probabilities), to determine our chance of winning (with and without drawing more table cards). This chance of winning can be used to make some simple algorithmic betting decisions (eg. bet good hands, call when you have pot odds, etc.) 2) simulate our three possible actions into the future - fold, call, or raise (FCR). For each possible action, run the AI on our opponents in the future to predict their likely moves (weighted by probability) and how well our action does in those cases. This produces an EV in each case, and you simply choose the action with the best EV. (this is PostFlopSim1) ========================================================== = Notes on Compiling You must use MSVC .NET to compile. Open GoldBullion.sln and cancel any messages about source control. You must have STL-Port version 4.5.3 installed. I put my STL-Port in C:\src\STLport-4.5.3 If you don't put it there, you must set the include paths for GoldBullion to find STL-Port. If you don't know how to do any of this, delete these files off your hard drive and go do some more learning before you try to work on Poker AI. (that's an homage to David Slansky) ==========================================================