You can’t (not cumulative). A way to enforce (and fairness) can be to switch to the opponent as the new AI’s target after each occurence.
Besides the AI don’t mention if it’s a good or bad move. (Graph is not visible )
A variant could be to switch when the winning color changes (not telling who is winning)
If we switch colors each time the balance of winning chances switches, then the loser will stay loser and winner winner.
So what counts is if you can reverse more times as your opponent, as the final result.
It’s still not simple as only one player can reverse. (Loser staying loser after each reverse)This will need two games, with a different leading player in the first moves. So we can compare the “getting a reverse performance”.
Another way to avoid to play two games would to let the reversing happening only half of times. But in many games, there are not that many times that the lead switch.
Player A color O takes the lead
After one of his moves he has + 5ptz(as an example, Arbitrary value ) and that triggers reverse
B play his color X and then play again O
B after his move -5pts triggers reverse
He plays again, O this time.)
Game continues, A playing X(leading) and B O
At some point the winning change,
A keep playing X (losing) and B O
One more reverse situation happen X (winning)
Exchange of colors happens
A plays now O (losing) and B X
Each player played each color .one time losing, one time winning with each of them.
Even with less sophistication, if we could have a program which switch colors for passing over a win% or for a switch between white and black leading, we could imagine teaching games too where every time the stronger has a too big lead, he get a new challenge to reverse the game, or the weaker playing well got the chance to take white…
And could be a nice training between same level players to share ideas around a game with a little bit of AI input.
Under good play, to maximize the value/EV of doubling, if you are ahead, you generally want to offer a double no later than when you think your practical chances are ~80% or higher to win, since that’s the point where your opponent will want to resign rather than accept a game that is both doubled and highly unfavorable for them (if they do accept past that point, it’s even better on average for you than them resigning even if some percent of doubled games you end up losing).
You don’t want to wait any longer than that to double, because if the opponent is behaving sensibly then there’s no upside to waiting. Wait longer to gain even more of an advantage before doubling and they’ll still only just resign in response, so you might as well double and have them resign now. And there is downside to waiting, since you could blunder in the meantime.
So anyways, the result would be that players would be incentivized to use the double not merely as a way to cut short a won game, but actually well before that, when they feel they are ahead but when the game is still not certain. It might be interesting to see for players of each different level where that point is, where they would subjectively estimate their own practical chances to be 75-80%.
Permutable branches in conditional moves: during endgme, it is quite frequent that several parts of the board don’t interact, so that sequences ABCD… and A’B’C’D’… can be permuted. So we should be able to select 2 or more branches starting from the same vertex and declare them permutable.