3

I am writing a poker game where you play against 5 bots and I just can't get my head around playing straights and flushes. They are solid hands but you can get stacked by a boat or higher.

If opponent bets the pot when the board pairs do you release? I feel like that would make the bot exploitable. About all I can think is call a large bet (more than the pot) like 1/3 the time and keep track of how often opponents bluff and adjust from there. Right now bots are slow playing a flush or straight on flop or turn 2/3 of the time as long as the board is not paired.

Without writing the software part what would you do in position with a nut flush, the board pairs on the river, and opponent bets the pot? Goes all in for 5 pots?

1

How often should a bot call a human in this situation given different bet sizes is what I now understand the question to be, and with no previous information or statistics to go on. The goal then is to stay the least exploitable as possible while calling enough to start gathering stats to use in further hands.

Here's one possibility that I thought of that admittedly might not be the most optimal but I think it's decent and I'll give some reasoning for it: start out by calling 100% of the time for any bet up to a pot-sized bet and then for bets that are bigger than the pot, call at a rate of 1/(bet size/pot size). For example, in a pot of 100 if the bet is 200, call 1/(200/100) or 1/2 the time; for a bet of 500, call 1/5 of the time.

For a pot size bet, the assumption is that the human player is bluffing (or betting for value with a worse hand) 33% of the time and betting with a stronger hand 67% of the time. With nothing else to go on, this can't be too far off and the smaller the bet is the better the pot odds are for the bot to call.

For over-sized bets, take the example of a bet of 200 into a 100 pot. When the human player is bluffing, the bot calls 50% of the time (loss of 200 for the human) and the bot folds 50% of the time (gain of 100 for the human) which comes out to an EV of -50 to be bluffing. When the human player is betting for value with a stronger hand, the bot will call 50% of the time (gain of 300 total for the human) and the bot will fold 50% of the time (gain of 100 already in the pot for human) which leads to an EV of +200 for the value-bettor. But if the person had instead bet exactly the pot of 100, the bot would have called 100% of the time and there would be an EV of +200, so the person gained nothing by betting more.

Similarly, if the bet is 500 into a 100 pot, a bluff has a return of (1/5)(-500) + (4/5)(100) = -20, and a value bet has a return of (1/5)(600) + (4/5)(100) = 200, which again has no benefit over betting just the pot size.

So if a person knew this, they could increase their (negative)EV when bluffing by betting more, but there would be no EV change by betting more with value hands. It's a little bit arbitrary of a system but you could try something similar and I think it results in enough calls for the bot to start gathering information and adjusting.

  • How often for the bot to bluff I have something. It is the human the bot is wondering about. If the board hits a pair and the human OVER bets then how often does bot call prior to gather any statistics. If bot just lays down then it might take a long time to get any statistics. Need a starting point. Like you say human may think 3 of a kind is good. – paparazzo May 16 '16 at 14:32
  • @paparazzi, looks like I had it backwards thinking that a human was facing a bot's bet whereas you're talking about a bot facing a human's bet. I may edit this or make a new answer later. – Dr.DrfbagIII May 16 '16 at 19:28
  • Please do - answer still helped – paparazzo May 16 '16 at 20:10
  • Edited with completely new answer. – Dr.DrfbagIII May 17 '16 at 13:41
  • 2
    Imho it really depends on if the bot is slow-playing or not, if he is slow-playing calling a pot-sided bet seems obvious as they could very likely be value-betting a worse hand, if bot is agressively betting and the player donks/reraises the river for a decent (not blocker) bet it is very polarised between bluff and value (with value definitely only being a full house if the player is any decent). So in the slow-play scenario your system seems good but in aggressive play version you will definitly need more information on how the hand played (ex. where there any reraises ...). – Selenog May 17 '16 at 15:32
0

Well it all depends on the hand in question, which is why it is very hard to write a really good poker-bot.

Assuming no bluffing is involved, the basics are:

  • calculate the range of hands the player could have

  • calculate the odds of the player having a hand that beats you vs one you beat inside that range

  • compare that to the pot-odds

This would be what you do against a player who is playing at level one of poker, only looking at his hand. The problem lies however in calculating his range, there are reasonable implementations for doing this given a players statistics but you are never really sure as players are not bots themselves and might play strange.

When bluffing comes in the mix it becomes a lot more difficult, you have to consider all semi-bluff options and the frequency with wich he semi-bluffs and add to that the complete bluffs and the semi-bluffs that turn into complete bluffs. This is not easy but given you have those you can add them to his range of hands and do the same as above.

And remember, you need to calculate the odds of a specific hand, not a group of hands, for example there are 6 combinations of AA in a complete deck remember but if you take one A out of the deck (the bot or board has it) only 3 combinations remain.

Another question you might want to ask yourself is how difficult do you want to make beating those bots? What is the purpose of the game exactly?

  • Thanks for the general feedback and I don't plan on taking any cards out of the deck. There is a hand in question. Nut straight or flush and the board pairs. – paparazzo May 11 '16 at 10:31
  • @Paparazzi I'm not talking about taking cards out off the deck before dealing, I'm talking about when you calculate the odds of a player having a given hand you need to take into account the cards the bot has in his hand and the board cards as he can't have those. – Selenog May 11 '16 at 10:34
  • @Paparazzi You haven't really provided a "hand in question", it is way to general to do an analysis. Did you flop/turn/river the straight/flush, did the pair come on the flop/turn/river, did you slowplay or not, how did the betting go, and likely a lot more questions come into play when making a decission here. Hence I can only give a general answer. And given that it is an algoritm you are writing I think such a general answer is actually sufficient for this case. – Selenog May 11 '16 at 10:38
  • Again thanks for your time but I was looking for but I was looking for a specifics. The question states pair on the river. – paparazzo May 11 '16 at 10:58
  • 1
    @Paparazzi Ok, but you might have only had a draw on the flop. But say you had the nut flush on the flop and the board pairs on the river, and you where playing "normal" / "aggressive" then I would be inclined to just call and not raise as villain has shown a lot of strengtht. Without more information I wouldn't fold or raise. Say you where slow-playing it becomes a lot more difficult and without more information I would be split between calling and raising. – Selenog May 11 '16 at 11:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.