Man vs machine - how to beat chess engine

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

overlord
Posts: 198
Joined: Sun Jun 03, 2012 6:46 pm
Location: Trinec, Czech Republic

Re: Man vs machine - how to beat chess engine

Post by overlord »

Not exactly.You dont have to play antichess.Stockfish average depth in blitz on mobile phone is between 14-15 ply,so lets say 7 moves.The horizon effect is still valuable.Moreover,Stockfish drastically filters some lines.It has good and bad consequences.So even tactical hits are possible against him.I recommend it to every one.I believe that eg Larry Kaufman would be able to beat Stockfish or other engine on smartphone easily.Of course OC i7 is totally different story...
User avatar
fern
Posts: 8755
Joined: Sun Feb 26, 2006 4:07 pm

Re: Man vs machine - how to beat chess engine

Post by fern »

Maybe you are right. For my part, in any case Ii am interested more in playing a very entertaining game than to win or draw it. A defeat, almost always, does not hurt me. I am talking, of course, of powerful engines. To dedicated units I have another attitude: there feel I must win or draw at the very least.

I have a not too serious vision of chess, you know, never forgetting it is just a game.

my best
Fern
overlord
Posts: 198
Joined: Sun Jun 03, 2012 6:46 pm
Location: Trinec, Czech Republic

Re: Man vs machine - how to beat chess engine

Post by overlord »

For me the most interesting thing is artificial intelligence improvement.Chess is alnost like appled mathematics.It is nice to know that human kind os still able to achieve some good results.Although,playing against engine is little bit perverse...due to so msny bad loses :)
User avatar
fern
Posts: 8755
Joined: Sun Feb 26, 2006 4:07 pm

Re: Man vs machine - how to beat chess engine

Post by fern »

I consider to play a chess machine of any kind as going to the gym to keep your fitness. So it does not matter if you win or lose, the same you train and keep your mind sharp.

from the gym regards
fern
Lyudmil Tsvetkov
Posts: 6052
Joined: Tue Jun 12, 2012 12:41 pm

Re: Man vs machine - how to beat chess engine

Post by Lyudmil Tsvetkov »

Hi, Fernando.

When I am playing engines, it is more important for me to have a nice game than to win. So, after a couple of games I will be able to draw or win
with well-known methods, I will resort to playing enterprising, unusual chess, exposing myself to risks and losing a fair amount of games in the process, but still learning something.

With every game you play, even if you lose it, you learn something raise your strength with and infinitesimal amount of elos, whether measured or not. And the paradox is that when you are losing, you are usually learning more in the process. Besides, with modern engines, you not only learn, but
do it in a beautiful way.

Miroslav, keep up the good work challenging the engines!
I do not think humankind is doomed in the struggle for mastery in the long run. I think humans are going to gradually improve their skills to the point of being worthy opponents of engines. They just have to practice more:)

I think their are 3 ways of drawing strong engines:

- the first one is to block the position as much as possible, as in this case the proportion of variations requiring calculation decreases sharply
- the second one is to keep on exchanging as much material as possible, which will also result in simplification of the position and significant decrease in the number of variations requiring computation; proceeding in this way is simple - wherever you notice the engine has developed a piece, you attack it with you own and exchange it, even at the cost of some (but only reasonable) compromising on the pawn structure. When you echtange a couple of minor pieces and a pair of rooks, the position will already look very simple to you to hold. It will be difficult to skip some tactics, while engines are far superior in complex positions with many pieces being open to a large degree.

- and the third one is, of course, to play like an engine :D ; it is difficult to learn to do that, but not impossible - I have set myself a target of learning to do that in a couple of lifetimes :)

I think we humans playing engines benefit a lot from the fact that we know whom we are playing against, while the poor engines do not - and this is a significant psychological advantage, although some engines seem to take an unruffled approach to it. I remember playing Ruffian (one of the later versions, obviously on a single core) in the past. It was a nightmare. This used to be the engine against which I scored worst of all engines, much much stronger engines included. When I started playing it, I would get only one draw every 10 games, none other engine has ever come close to such a humiliating record, meaning taking only 5% of the games! Ruffian would surprise me in every single game, and every second move at that. It was unbelievably difficult to make sense of what was going on, its moves were fathomless. This went on for quite a long time - whatever I did, no matter what I tried, I would get my 5% heart's content. Gradually, however, I learned the hack of the 'beastly' engine and eventually began fighting against it on an equal footing. So that psychology is important. What I like about engines is that they do not talk to you during the game, they do not slurp beverages, they do not complain to the arbiters, they do not stare at you menacingly, and most importantly, they do not start suddenly shaking the table when you are trying to find the best continuation in time trouble.

And of course, there are always easy and difficult opponents. When I played more extensively years ago against a wider variety of engines, I remember that I was doing quite convincingly against engines like Phalanx and The Crazy Bishop (thanks to Dusan Dobes and Remi Coulom for the free downloads), while I had a hard time against engines like Crafty and Yace (thanks to Robert Hyatt and Dieter Buerssner). At the time, the elo gap between those engines was not big. But, of course, styles and preferences change with time and acquired experience.

To add a bit of a substance to this post, below are 2 games effortlessly drawn by way of exchanging pieces. Houdini is again serving as an example, simply because I have had to limit somewhat my engine activity recently, and in this situation you have to stick mostly to the top guns, and whenever possible to the top of the top. But of course, I promise to pay a way more attention in the future to other engines, whether belonging to the top or not.

[pgn]
[PlyCount "72"]
[Event "Blitz 2m+2s"]
[Site "Sofia"]
[Date "2013.01.05"]
[White "Tsvetkov, Lyudmil"]
[Black "Houdini 3 Pro x64"]
[Result "1/2-1/2"]
[ECO "D02"]
[TimeControl "120+2"]
[Annotator "Tsvetkov,Lyudmil"]
[MLNrOfMoves "36"]
[MLFlags "000100"]

{1024MB, Dell XPS 4Cores} 1. e3 {[%emt 0:00:00]} 1... d5 {[%emt 0:00:07]} 2. d4
{[%emt 0:00:02]} 2... Bf5 {[%emt 0:00:05]} 3. Nf3 {[%emt 0:00:02]} 3... e6
{[%emt 0:00:04]} 4. Bd3 {[%emt 0:00:03]} 4... Nc6 {[%emt 0:00:10]} 5. O-O
{[%emt 0:00:03]} 5... Nf6 {[%emt 0:00:12]} 6. a3 {[%emt 0:00:03]} 6... Be7
{[%emt 0:00:06]} 7. b3 {[%emt 0:00: 07]} 7... a5 {[%emt 0:00:04]} 8. Bb2
{[%emt 0:00:02]} 8... a4 {[%emt 0:00:06]} 9. b4 {[%emt 0:00:03]} 9... O-O
{[%emt 0:00:06]} 10. c4 {[%emt 0:00:07]} 10... Bxd3 {[%emt 0:00: 03]} 11. Qxd3
{[%emt 0:00:02]} 11... dxc4 {[%emt 0:00:13]} 12. Qxc4 {[%emt 0:00:02]} 12... Qd5
{[%emt 0:00:03]} 13. Nbd2 {[%emt 0:00:06]} 13... Qxc4 {[%emt 0:00:04]} 14. Nxc4
{[%emt 0:00:02]} 14... Na7 {[%emt 0:00:01]} 15. Rac1 {[%emt 0:00:06]} 15... Nb5
{[%emt 0:00: 12]} 16. Nfe5 {[%emt 0:00:17]} 16... Rfd8 {[%emt 0:00:06]} 17. f3
{[%emt 0:00:06]} 17... Ne8 {[%emt 0:00:04]} 18. Rfd1 {[%emt 0:00:08]} 18... Ned6
{[%emt 0:00:10]} 19. Nxd6 {[%emt 0:00:21]} 19... cxd6 {[%emt 0:00:03]} 20. Nd3
{[%emt 0:00:07]} 20... Rac8 {[%emt 0: 00:00]} 21. Kf2 {[%emt 0:00:20]} 21... Kf8
{[%emt 0:00:00]} 22. Ke2 {[%emt 0:00:02]} 22... Ke8 {[%emt 0:00:05]} 23. Rxc8
{[%emt 0:00:11]} 23... Rxc8 {[%emt 0:00:01]} 24. Rc1 {[%emt 0:00:06]} 24... Rxc1
{[%emt 0:00:06]} 25. Nxc1 {[%emt 0:00:02]} 25... Kd7 {[%emt 0: 00:03]} 26. e4
{[%emt 0:00:12]} 26... Kc6 {[%emt 0:00:03]} 27. f4 {[%emt 0:00:09]} 27... f5
{[%emt 0:00:04]} 28. exf5 {[%emt 0:00:17]} 28... exf5 {[%emt 0:00:03]} 29. Kd3
{[%emt 0:00:02]} 29... Bf6 {[%emt 0:00:01]} 30. Ne2 {[%emt 0:00:02]} 30... Kd5
{[%emt 0:00: 02]} 31. Nc3+ {[%emt 0:00:08]} 31... Nxc3 {[%emt 0:00:04]} 32. Bxc3
{[%emt 0:00:01]} 32... b5 {[%emt 0:00:03]} 33. g3 {[%emt 0:00:03]} 33... g6
{[%emt 0:00:00]} 34. h4 {[%emt 0:00:03]} 34... Bh8 {[%emt 0:00:03]} 35. Bb2
{[%emt 0:00:07]} 35... Bg7 {[%emt 0:00:03]} 36. Bc3 {[%emt 0:00:01]} 36... Bf6
{[%emt 0:00:03]} 1/2-1/2

[PlyCount "63"]
[Event "Blitz 2m+2s"]
[Site "Sofia"]
[Date "2013.01.27"]
[White "Houdini 3 Pro x64"]
[Black "Tsvetkov, Lyudmil"]
[Result "1/2-1/2"]
[ECO "D30"]
[TimeControl "120+2"]
[Annotator "Tsvetkov,Lyudmil"]
[MLNrOfMoves "31"]
[MLFlags "000100"]

{1024MB, Dell XPS 4Cores} 1. d4 {[%emt 0:00:07]} 1... d5 {[%emt 0:00:03]} 2.
Bf4 {[%emt 0:00:06]} 2... e6 {[%emt 0:00:02]} 3. e3 {[%emt 0:00:05]} 3... Nf6
{[%emt 0:00:02]} 4. Nf3 {[%emt 0:00:11]} 4... Nc6 {[%emt 0:00:05]} 5. c4
{[%emt 0:00:21]} 5... a6 {[%emt 0:00:06]} 6. Nbd2 {[%emt 0:00:04]} 6... Be7
{[%emt 0:00:11]} 7. Bd3 {[%emt 0:00:05]} 7... O-O {[%emt 0:00:03]} 8. cxd5
{[%emt 0:00:07]} 8... exd5 {[%emt 0:00:05]} 9. h3 {[%emt 0:00:04]} 9... Bd6
{[%emt 0:00:07]} 10. Ne5 {[%emt 0:00:03]} 10... Ne7 {[%emt 0:00: 07]} 11. O-O
{[%emt 0:00:05]} 11... Ng6 {[%emt 0:00:10]} 12. Bh2 {[%emt 0:00:04]} 12... Qe7
{[%emt 0:00:08]} 13. Ndf3 {[%emt 0:00:00]} 13... Nd7 {[%emt 0:00:39]} 14. Nxd7
{[%emt 0:00:03]} 14... Bxd7 {[%emt 0:00:07]} 15. Bxd6 {[%emt 0:00:06]} 15...
Qxd6 {[%emt 0: 00:08]} 16. Qc2 {[%emt 0:00:00]} 16... Bb5 {[%emt 0:00:12]} 17.
Rfd1 {[%emt 0:00:05]} 17... Bxd3 {[%emt 0:00:13]} 18. Rxd3 {[%emt 0:00:00]}
18... c6 {[%emt 0:00:10]} 19. Rb3 {[%emt 0:00:03]} 19... Qe7 {[%emt 0:00:21]}
20. Rc1 {[%emt 0:00:00]} 20... Rad8 {[%emt 0:00: 02]} 21. Ne1 {[%emt 0:00:04]}
21... Rd7 {[%emt 0:00:31]} 22. g3 {[%emt 0:00:04]} 22... Re8 {[%emt 0:00:26]}
23. Nd3 {[%emt 0:00:03]} 23... Rc7 {[%emt 0:00:04]} 24. Qc5 {[%emt 0:00:01]}
24... Qxc5 {[%emt 0:00:11]} 25. Nxc5 {[%emt 0:00:08]} 25... Ree7
{[%emt 0:00:02]} 26. Kg2 {[%emt 0:00:04]} 26... Nf8 {[%emt 0:00:02]} 27. Rb6
{[%emt 0:00:03]} 27... Ne6 {[%emt 0:00:04]} 28. b4 {[%emt 0:00:00]} 28... Nxc5
{[%emt 0:00:19]} 29. bxc5 {[%emt 0:00:03]} 29... f5 {[%emt 0:00:03]} 30. h4
{[%emt 0:00:03]} 30... h5 {[%emt 0:00:03]} 31. Rcb1 {[%emt 0:00:03]} 31... Kf7
{[%emt 0:00:04]} 32. Kf3 {[%emt 0:00:03]} 1/2-1/2
[/pgn]
User avatar
fern
Posts: 8755
Joined: Sun Feb 26, 2006 4:07 pm

Re: Man vs machine - how to beat chess engine

Post by fern »

Great post, Lyudmil. Clearly you are a far stronger player than me. If I had a 5% success against any engine, I would feel great. My score is lot nearer to 0. Sometimes I had had a draw, but against relatively old engines. Any machine better than 2200 probably will win 95% of time against me.
It is not that I am so weak or ignorant at chess, I have a good strategical view of it, but, as I know since ever, my mind -I am a writer- is not shaped to play chess. My brains is for imagination, understanding, writing, for anything but calculation. So tactics is my fault. I tend to lose concentration and interests and/or fall in blind spots. I am the kind of guy that say "what? A knight can jump backward? Where that rook came from?
Things like that.
From time to time, once in 20 or 30, I get enough concentration and interest to win a game against my dedicated units, but even to them I lose many games. Why? Again, the blind spot.

No matter: I get lot of fun and I do not care much about losing a game.
overlord
Posts: 198
Joined: Sun Jun 03, 2012 6:46 pm
Location: Trinec, Czech Republic

Re: Man vs machine - how to beat chess engine

Post by overlord »

Nice game, Lyudmil :) Until now I didn´t try go get some draw against Houdini 3. You gave me new motivation (I know that it will be not so easy, but anyway...). I completly agree with you. If you want to get a draw, fixed pawns structures and exchanges are very good method.Generally said, proper opening choice is essential, Kings indian and French defense are my favourite (normally, I play Scandinavian defence in my OTB, but against engines it is not good opening). Moreover, if I have to play as a black against engine playing Sicilian defence, 1.ec5 2.c3 gives me good drawing chances. Also playing with white, main lines of Grunfeld are suitable, if have good opening knowledge and some experience with such positions.
Uri Blass
Posts: 11096
Joined: Thu Mar 09, 2006 12:37 am
Location: Tel-Aviv Israel

Re: Man vs machine - how to beat chess engine

Post by Uri Blass »

fern wrote:Great post, Lyudmil. Clearly you are a far stronger player than me. If I had a 5% success against any engine, I would feel great. My score is lot nearer to 0. Sometimes I had had a draw, but against relatively old engines. Any machine better than 2200 probably will win 95% of time against me.
It is not that I am so weak or ignorant at chess, I have a good strategical view of it, but, as I know since ever, my mind -I am a writer- is not shaped to play chess. My brains is for imagination, understanding, writing, for anything but calculation.
I think that if you do not compare yourself with the best humans then you are certainly not weak in chess.

You may be weak in tactics relative to the best players but I believe that you are strong in chess relative to most humans.

I wonder if you tried to use chess tempo and what is your rating there.

I think that if you can achieve 1500 at standard in chess tempo(see www.chesstempo.com)
then it means that you are clearly better in tactics than most of the people who play chess(most of the people in this site have standard rating of less than 1500).
Lyudmil Tsvetkov
Posts: 6052
Joined: Tue Jun 12, 2012 12:41 pm

Re: Man vs machine - how to beat chess engine

Post by Lyudmil Tsvetkov »

fern wrote:Great post, Lyudmil. Clearly you are a far stronger player than me. If I had a 5% success against any engine, I would feel great. My score is lot nearer to 0. Sometimes I had had a draw, but against relatively old engines. Any machine better than 2200 probably will win 95% of time against me.
It is not that I am so weak or ignorant at chess, I have a good strategical view of it, but, as I know since ever, my mind -I am a writer- is not shaped to play chess. My brains is for imagination, understanding, writing, for anything but calculation. So tactics is my fault. I tend to lose concentration and interests and/or fall in blind spots. I am the kind of guy that say "what? A knight can jump backward? Where that rook came from?
Things like that.
From time to time, once in 20 or 30, I get enough concentration and interest to win a game against my dedicated units, but even to them I lose many games. Why? Again, the blind spot.

No matter: I get lot of fun and I do not care much about losing a game.
Fernando, I understand you are an artist.
lucasart
Posts: 3242
Joined: Mon May 31, 2010 1:29 pm
Full name: lucasart

Re: Man vs machine - how to beat chess engine

Post by lucasart »

Lyudmil Tsvetkov wrote: I think their are 3 ways of drawing strong engines:

- the first one is to block the position as much as possible, as in this case the proportion of variations requiring calculation decreases sharply
- the second one is to keep on exchanging as much material as possible, which will also result in simplification of the position and significant decrease in the number of variations requiring computation; proceeding in this way is simple - wherever you notice the engine has developed a piece, you attack it with you own and exchange it, even at the cost of some (but only reasonable) compromising on the pawn structure. When you echtange a couple of minor pieces and a pair of rooks, the position will already look very simple to you to hold. It will be difficult to skip some tactics, while engines are far superior in complex positions with many pieces being open to a large degree.

- and the third one is, of course, to play like an engine :D ; it is difficult to learn to do that, but not impossible - I have set myself a target of learning to do that in a couple of lifetimes :)
Realistically the third one is inaccessible to the albeit limited human brain: we don't compute millions of moves per second, especially the awkward and counter-intuitive ones. It would take Mikhail Tal multiplied by Bobby Fisher, elevated to the power Garry Kasparov to reach that level, at least...

But the first two, illustrated by the draws you posted, are indeed a threat to poor computers :oops:

The problem is that engine developpers tune their engine to increase their ELO against other engines. That increases strength against a GM to a certain extent, but eventually you reach a glass ceiling, and you can gain lots of elo in comp vs comp, you're still dumb in positions where there is nothing to calculate (like blockades or lots of pieces exchanged and symmetric pawn structures).

It is possible however, to compromise and make an anti-human setting of an engine, that may be weaker against other computers, but where the engine will seek to avoid:
* exchanging pieces
* symmetric pawn structures
* blocked pawns
I can easily code that up in DiscoCheck, and I'm quite sure it will be weaker in computer vs computer rating lists, but it will give you a hard time to draw against it. If the computer refuses to play it your way (ie. cowardly draw) and forces you to play complex and sharp positions (and refuses any unfought 3-repetition draw), you are dead meat :lol:
Theory and practice sometimes clash. And when that happens, theory loses. Every single time.