Contempt

Code, algorithms, languages, construction...
User923005
Posts: 616
Joined: Thu May 19, 2011 1:35 am

Re: Contempt

Post by User923005 » Thu Jun 13, 2013 8:11 am

I agree with SJE. Beauty is symmetrical (this has been proven).

lucasart
Posts: 201
Joined: Mon Dec 17, 2012 1:09 pm
Contact:

Re: Contempt

Post by lucasart » Thu Jun 13, 2013 11:42 am

'sje' was refering to the contempt=f(elo_diff) part of the problem. 'hyatt' suggested to use such a function, which is surely a good idea, and can perhaps procure a small elo increase in tournament (or rating list, or internet server) conditions. But I do not like this, for the same reason that 'sje' mentionned (makes things messy and harder to reproduce, and philosophically it's wrong, and can easily be misused, nothing is idiot proof and you don't know how many idiots use our programs).

Also, as far as the UCI protocol is concerned, there is indeed a feature to indicate to the engine its elo and the one of the opponent, but you cannot rely on it: it is a dark corner of the protocol probably not largly implemented, and it is based on what the user input (lost of users are morons).

The symmetry side of things is with regards to the evaluatyion function itself, once it has been given a contempt value (either chosen by the user or as f(elo_diff)). All the suggestions by 'hyatt' and 'BB+' (like pawn struct asymetry, or drawing the score towards the contempt score on drawish positions) introduce eval assymetry, meaning they make the eval side to move dependant. This makes things messy to implement for me, as I use the post null move lazy eval (skip the eval and negate the eval of the parent node).

Anyway, I will keep contempt the way it is in DiscoCheck. I am very satisfied with it, and managed to reduce significantly the draw rate (especially "unfought" three-fold repetitions) while not harming elo at all.
"Talk is cheap. Show me the code." -- Linus Torvalds.

sje
Posts: 9
Joined: Sun Jan 29, 2012 3:03 pm
Real Name: Steven Edwards

Re: Contempt

Post by sje » Wed Jun 19, 2013 9:25 pm

While an ICS does send the opponent's rating, that rating cannot always be trusted. Many times Symbolic has had an opponent with a ~1200 rating magically play 2400 chess, obviously cheating. In those cases, a contempt offset doesn't work so well.

Aside: I've thought about adding a feature to Symbolic's ICS code to detect near-certain cheaters (opponent playing 1000+ elo above stated rating) and issue an automatic +noplay.

lucasart
Posts: 201
Joined: Mon Dec 17, 2012 1:09 pm
Contact:

Re: Contempt

Post by lucasart » Thu Jun 20, 2013 3:26 pm

sje wrote: Aside: I've thought about adding a feature to Symbolic's ICS code to detect near-certain cheaters (opponent playing 1000+ elo above stated rating) and issue an automatic +noplay.
That's a good idea. You could even send them an automated PM to say that you've sent the games to the ICS admin for evaluation. Even if it's not true (and admins probably don't have time to settle this kind of crap), it would surely scare them off :D
"Talk is cheap. Show me the code." -- Linus Torvalds.

bluefever
Posts: 22
Joined: Wed Jul 10, 2013 8:23 am

Re: Contempt

Post by bluefever » Fri Jul 12, 2013 4:59 pm

lucasart wrote:I recently implemented a contempt feature in DiscoCheck, as follows: the value of a draw by chess rules is -Contempt for the engine (root color) and +Contempt for the opponent.
A really silly question, but where do you apply this score if not in the evaluation?

lucasart
Posts: 201
Joined: Mon Dec 17, 2012 1:09 pm
Contact:

Re: Contempt

Post by lucasart » Thu Jul 18, 2013 12:51 pm

bluefever wrote:
lucasart wrote:I recently implemented a contempt feature in DiscoCheck, as follows: the value of a draw by chess rules is -Contempt for the engine (root color) and +Contempt for the opponent.
A really silly question, but where do you apply this score if not in the evaluation?
I said "draw by chess rules" (3-rep, 50-move, material, stalemate). This is different from "drawish by chess knowledge".
=> those are always detected by the search, not the eval. so you don't modify the eval.

Applying contempt in the eval to drawish positions by chess knowledge, is a further way to refine the approach. However, all my attempts in this direction have been unsuccesful.
"Talk is cheap. Show me the code." -- Linus Torvalds.

Post Reply