As I mentioned in an earlier post, I wrote a poker bot in 2004. I learned a lot from that project, and I’d like to share some of the lessons learned over a series of blog posts.
All poker players are familiar with the game’s swings. Poker’s unpredictable sequence of wins and losses stems from the addictive cocktail of uncertainty and randomness that makes the game so popular. There are many lessons to learn while riding the roller coaster of wins and losses, but I’ll focus on one that’s particular to a poker bot author (or an investor in the markets).
Imagine if you unleashed your poker bot algorithm and observed the following performance over the first 10,000 hands.

Pokerbot performance over 10,000 hands
It takes a poker bot about 22 hours to play 10,000 hands. This assumes that the bot plays 10 tables simultaneously, averaging 45 hands per hour at each table. For comparison, it takes a human about 28 days to play 10,000 hands, assuming he plays an intense 30 hands an hour, 12 hours a day. Although it’s not a large enough sample to yield a statistically significant win rate, it’s a sizable sample.
The first couple of times that this happened to me, I couldn’t help myself from leaning back and thinking that my troubles were over. Instead of analyzing more data or writing more code, I’d relax. Then I’d see this turn of fortune.

Fictional graph of big bets won or loss over time.
The downturn would give me a kick in the pants, and I’d dive in again to my work with vigor.
After this pattern happened a couple times, I realized how much time I was wasting. Frustrated by this inefficient cycle, I made a point of staying vigilant even when the results looked promising. I learned that you have to work hard even when everything’s going smoothly.
This lesson is applicable to both investing and software development. When your PnL is positive, you need to make an extra effort to stay sharp. When you’re writing software, you can’t assume that your program is correct just because it runs without throwing off errors. Be suspicious and stay vigilant, even when things seem okay.
bigtpoker said
Perhaps other players just starting recognizing your bot and altered their strategy to beat it. If I saw a player at the table following the same strategy religiously for a very long time I would start taking advantage of it.
Greg said
Yes, I’m sure that happened many times over the millions of hands that the bot played. That’s additional motivation to keep working hard on improving the pokerbot, even when it’s winning.