SoarBot is a program written by Bob Follek for his Master's thesis in Computer Science at Pace University. We will examine the overall structure of his program, ignoring a lot of implementation details. He has a webpage giving the full details (and how to contact him).
Bob's thesis is well written. It gives the rules of the game and a basic description of Soar, followed by the details of his SoarBot program. SoarBot is designed to play a version of poker called Texas Hold'em with the poker server at the University of Calgary. This server is run by the University of Alberta Computer Poker Research Group. They have developed an online poker protocol that anyone can use to play with their server.
poker.soar is the top-level soar file, which loads in the other soar files. It also defines the basic structure of the program, which follows the structure of the game. There are four subgoals for the four stages of this version of poker: the preflop, the flop, the turn and the river. Each of these is an abstract operator that leads to an impasse and a new state.
As usual, these four states are named by the stage of the game they represent. The four soar files that contain the elaborations and operators for these states are:
SoarBot is told the current stage of the game by the poker server, and changes the ^stage attribute from preflop to flop to river to turn based on the info provided from that server. This is actually done in the pokerIo.tcl file, which is executed by soar automatically during every input phase and output phase.
The entire SoarBot is started and controlled by some Java and Python code. Here is the Java code. It constructs a Java class called SoarSession that runs tcl inside it. This class is used by SoarBot to run soar. This is an outdated way to run soar from Java, as the new version of soar has a Java API that permits Java to interact directly with soar.
There are also some general elaborations and operators for poker actions that might be applicable in all four states. These are in pokerElab.soar and defaultOps.soar.
P. Benjamin's home