For Xboard, when using UCI engines, that have the Syxygy50MoveRule checkbox (see snapshot), it currently has no effect since polyglot by design enforces the 50 move rule. This version of Polyglot adds a Polyglot 50MoveRule on the righthand side. When unchecking both boxes, the 50 rule move will have no effect. Comes in handy if you want to see the line played for a cursed win ( a win that goes beyond the 50 move rule) when using EGTB's. Common situatioon with 6 Men EGTB's. This is a quick update to the source and Mac exe provided yesterday.
FYI, The current maintainer, HGM, does not believe this is a useful feature and has indicated he is not planning to add it. If you feel differently, let him know.
Note that I do not really consider myself the maintainer of Polyglot. Out of necessity I sometimes have to patch the version I include with WinBoard to support extensions of WB protocol. The repositiory is just my way of complying with the GPL for this version.
If there is enough demand for this option, I would be willing to add something like this. But I think it would be a bad idea to clutter the Engine Settings display with options that only a single person would ever use.
Apart from that, this particular patch also looks a bit like too much like a quick hack for my comfort. I don't like it at all that you would have to tick/untick two checkboxes for this. A better solution would be to suppress draw claiming as a side effect of the Syzygy50MoveRule setting.
hgm wrote:Note that I do not really consider myself the maintainer of Polyglot. Out of necessity I sometimes have to patch the version I include with WinBoard to support extensions of WB protocol. The repositiory is just my way of complying with the GPL for this version.
If there is enough demand for this option, I would be willing to add something like this. But I think it would be a bad idea to clutter the Engine Settings display with options that only a single person would ever use.
Apart from that, this particular patch also looks a bit like too much like a quick hack for my comfort. I don't like it at all that you would have to tick/untick two checkboxes for this. A better solution would be to suppress draw claiming as a side effect of the Syzygy50MoveRule setting.
Is it s hack - yes of course. Was it a quick hack, yes of course. Not sure why you say only a single person would use. Both the authors of Komodo and Stockfish , even though the number of UCI options are limited by GUI's, decided that adding Syzygy50MoveRule setting would be beneficial. Now what benefit is that serving if another program , in this case polyglot, overrides that settings and stops a game at rule move 50 point every time? Do you think I was responsible for getting both authors to add Syzygy50MoveRule setting to Stockfish and Komodo and they added it only for me? I don't think so. Besides it you let a 3rd party program (Polyglot) to call the draw, because a chess engine has problem seeing the draw , it is actually a form of cheating to begin with. All engines should be able identify 50 move rule draws and adding a "feature" to polyglot to call all draws is in fact a quick hack to make up for poorly designed chess engines. I agree with you that one checkbox is ideal - but currently one checkbox is not working.
The point is that so far no one has shown up here to say he thinks this feature is a good idea, and just what he needs. (You should really have posted this as a poll...)
At the moment Polyglot is still WinBoard's primary adapter for UCI engines, and the 'learn' branch, to which version 2.0.3 belongs, is what I do include with the WinBoard install. So its quality reflects directly on WinBoard, which is why I have to guard it. Once I dump Polyglot for UCI2WB I will be less critical to what happens to Polyglot (but also less likely to touch it).
I agree with you that using UCI is cheating. But unfortunately that makes it popular. A counter argument could be that Polyglot is supposed to make UCI engines look like WinBoard engines, and that these usually will claim draws. The claiming of draws really is a legacy from the days that the GUI did not have ny rule knowledge at all, and was relying on the engine for rule enforcement and mate detection. For Chess these days are long behind us, and the result-claim commands of WB protocol are nowadays only useful for variants of which the GUI does not know the rules (such as King of the Hill).
So perhaps the best solution would be to have an option "Polyglot ClaimDraws" which controls both 50-move and rep-draws, which does not show up in the Settings dialog, and which by default would be 'false'. That removes the problem you are trying to solve here automatically (and reduces the level of cheating). People who complain that the engine doesn't claim draws can then be pointed out that this is the fault of the engine being UCI, and thus dependent on the GUI for this. So they should set the appropriate adjudication in the GUI. That also liberates them from the need to make the setting change separately in both engines. Or, if they want to cheat, they could do so by editing the Polyglot ini file, to set the ClaimDraws option to 'true'.
There already exists an option HandleDraws, which is actually shown in the Engine Settings dialog. Currently it is only used to determine how to handle draw offers. The claiming of draws could be made subject to that same option, though. Then you would not need a new option at all.
All these seem better solutions to me than adding another checkbox.
I'm thinking that maybe linking the setting to those engines that have Syzygy50MoveRule and when that setting is false , it will automatically turn off PolyGlot automatic 50 move rule draw claim. If you can give me some pseudo code that on how you would capture that from engine and then send it to polyglot so it could be set that would be useful. Although each engine would be set separately , it would allow one to measure ELO gain with and without egtb. Perhaps combine that the handle draw option so a user could use global setting or as an engine setting. The global setting could also handle the repetition claims and draw offers if so desired.
Global handling of draw claiming is already done by the GUI. (And this is as it should be, IMO.) It might make sense to measure Elo from using DTZ50 vs DTZ, (and these can already be set for the engines separately, through their Syzygy50move option), but I don't think it would be useful to measure Elo differences between engines that claim, and engines that go on. For one, if you play them against each other, the opponent will claim, even if the engine itself doesn't!
I you want this to piggyback on the Syzygy50MoveRule option, the patch would be just the same as what you already did, except that you should probe the value of the Syzygy50MoveRule option rather than the Polyglot 50MoveRule option for deciding whether Polyglot should claim. (And you don't have to add a new option to the table.) I suppose you would get some error response when you probe the value of an option that doesn't exist. One problem is that there might be no guarantee that in every engine this option will be called the same. Standardization is a dirty word in UCI...
You seem to assume that I would know how to do this. But, like I said, I am not really the maintainer of Polyglot, and most of the code I have never seen. I would have to figure it out just like you would have to figure it out, and I think the task is logically yours. If you had problems using UCI2WB you could come to me for fixing them. (But you would of course not have this particular problem in the first place.) I know that Michel faced a similar problem when he had to implement the cores feature, because all UCI engines use different names for the option to set their number of cores. So perhaps you could check there to see how he solved it.
Btw, note that it is possible to make Polyglot options (and UCI engine options in so far the engines have them) globally shared by redefining the adapter command. Polyglot accept setting of any option from its command like, IIRC by options like
-polyglot NAME=VALUE
-uci NAME=VALUE
where the NAME=VALUE part is just what you would write in the Polyglot's ini file. The adapter command that I configure in the WinBoard install uses that to couple the EGTB cache settin of WinBoard to all UCI engines though
-uci nalimovCache=%defaultCacheEGTB
where the %xxx part represents the value of the XBoard command-line option xxx.