A thought on originality

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

Moderators: hgm, Rebel, chrisw

Dann Corbit
Posts: 12540
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: A thought on originality

Post by Dann Corbit »

Uri Blass wrote: Mon Jan 18, 2021 8:17 pm
For example
I saw some mate solvers but do not see draw solvers that calculate if the side to move can force at least a draw in x plies and it is not because it is hard to do it but because programmers are not interested in it for some reason.

I do not see engines that calculate if the side to move can win material in x plies based on some material values.
That reminds me, a friend of mine had an idea. It was to create a chess engine that never tries to win and always tries to draw.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
User avatar
Ovyron
Posts: 4556
Joined: Tue Jul 03, 2007 4:30 am

Re: A thought on originality

Post by Ovyron »

maksimKorzh wrote: Mon Jan 18, 2021 5:16 pm Did you play versus WukongJS?
https://maksimkorzh.github.io/wukongJS/wukong.html
I just did and here's the game:

[pgn][Event "?"]
[Site "?"]
[Date "2021.05.06"]
[Round "?"]
[White "Ovyron"]
[Black "WukongJS"]
[Result "*"]

1. Nc3 Nc6 {(b8c6 g1f3 g8f6 d2d4 d7d5 c1e3 c8e6) -0.38/7 1}
2. f4 {11} d5 {(d7d5 d2d4 c8e6 e2e3 g8f6 g1e2 d8d6 c1d2)
-0.63/8 1} 3. e4 {3} d4 {(d5d4 c3e2 g8f6 d2d3 c8g4 g1f3
g4f3 g2f3) -0.79/8 1} 4. Nce2 {2} e6 {(e7e6 g1f3 f8c5 d2d3
g8e7 c1d2 e8g8 f3e5) -0.87/8 1} 5. Ng3 {1} Nf6 {(g8f6 f1c4
h7h5 h2h4 c8d7 g1e2) -0.79/6 1} 6. a3 {6} e5 {(e6e5 f4e5
c6e5 d2d3 c8e6 g1e2) -1.02/6 1} 7. f5 {2} Bc5 {(f8c5 d1f3
e8g8 g1e2 c8d7) -1.33/5 0} 8. Bc4 {2} O-O {(e8g8 g1e2 d8d6
d2d3 c8d7 e1g1) -1/6 1} 9. d3 {1} Bd7 {(c8d7 g1f3 d8b8 e1g1
b7b5 c4d5 f6d5 e4d5) -0.85/6 1} 10. Nh5 {3} Na5 {(c6a5 c4a2
a5c6 h5g3 a7a5 g1e2) -1.41/6 1} 11. Ba2 {6} Nc6 {(a5c6 c1g5
c5e7 h5f6 e7f6 g5f6 d8f6 g1e2) -1.27/7 1} 12. Bg5 {2} Be7
{(c5e7 h5g3 h7h6 g5d2 e7c5 g1e2 d8e7) -1.23/7 1} 13. g4 {4}
Nxh5 {(f6h5 g5e7 d8e7 g4h5 e7h4 e1f1 a8e8 a2d5 h4f6)
-1.44/8 1} 14. Bxe7 {4} Qxe7 {(d8e7 g4h5 e7h4 e1f1 a7a5
a2c4 a8e8 d1f3 h4f6) -1.31/8 1} 15. gxh5 {2} Qh4+ {(e7h4
e1f1 a8e8 d1f3 h4f4 a2d5 f4e3) -1.2/6 1} 16. Kf1 {6} g6
{(g7g6 f5g6 h7g6 h5g6 h4f6 g1f3 f6g6) -1.08/6 1} 17. hxg6
{4} hxg6 {(h7g6 f5g6 d7e6 g6f7 f8f7 g1f3 e6a2 a1a2 a8f8
h1g1 g8h8 g1g3 h4h2) -0.49/9 1} 18. Nf3 {7} Qh3+ {(h4h3
f1f2 g6f5 d1f1 f5e4 h1g1 g8h8 f1h3 d7h3 d3e4) -1.59/7 1}
19. Kf2 {5} gxf5 {(g6f5 d1f1 h3h5 h1g1 g8h8 g1g5 h5h7 a2d5
f5e4 d3e4) -1.65/7 1} 20. Rg1+ {7} Kh8 {(g8h8 a2d5 f5f4
d1f1 h3h6 f1e2 h6f6 f2f1) -1.54/7 1} 21. Rg3 {5} Qh6 {(h3h6
a2d5 a8e8 d1d2 h6d6 f2g1 f5f4) -1.66/7 1} 22. Qf1 {5} fxe4
{(f5e4 d3e4 h6e3 f2g2 e3e4 a2b3 a8e8 f1d3 e4f4) -2.62/8 1}
23. dxe4 {6} Qe3+ {(h6e3 f2g2 e3e4 a2b3 a8e8 a1e1 e4h7)
-2.58/6 1} 24. Kg2 {4} Qxe4 {(e3e4 a2b3 f8e8 a1e1 e4f4 f3g5
f4d2) -2.48/7 1} 25. Qf2 {18} Rae8 {(a8e8 a1e1 e4f4 f3g5
f4f2 g2f2 e8e7) -2.49/6 1} 26. Rh3+ {3} Bxh3+ {(d7h3 g2h3
e4f5 h3g2 e5e4 f2h4 h8g7 h4g3 f5g6 f3g5 e8e5 h2h4) -4.41/7
1} 27. Kxh3 {2} Qf5+ {6} 28. Kg2 {9} e4 {(e5e4 f2h4 h8g7
f3d2 d4d3 a1f1 f5g6) -4.57/6 0} 29. Nh4 {3} Rg8+ {(f8g8
g2f1 f5b5 f1e1 b5b2 f2f6 g8g7 f6h6 h8g8 h6c1 b2c1 a1c1)
-5.7/7 1} 30. Kf1 {2} Qb5+ {(f5b5 f1e1 b5b2 f2f6 g8g7 a1d1
b2c3 e1f1 c3c2 d1a1 c6e5) -6.64/8 1} 31. Ke1 {5} Qxb2
{(b5b2 f2f6 g8g7 a1d1 b2c3 e1f1 c3c2 f6h6 h8g8 h6d2 c2d2
d1d2) -6.65/9 1} 32. Qf6+ {10} Rg7 {(g8g7 a1d1 b2c3 e1f1
c3c2 f6h6 h8g8 h6d2 c2d2 d1d2 d4d3) -6.98/8 0} 33. Qh6+ {3}
Kg8 {(h8g8 a2f7 g7f7 h6g5 f7g7 g5d5 g8f8 d5f5 g7f7 f5c5
c6e7 a1d1 b2c3 c5c3 d4c3 e1e2) -7.72/9 1} 34. Nf5 {10}
Qxa1+ {(b2a1 a2b1 a1b1 h6c1 b1c1 e1f2 c1g1 f2e2 g7g2) NaN/8
0} 35. Kd2 {3} Rg2# {(g7g2) NaN/2 0 # Mate} *[/pgn]

I've been able to defeat 2000 rated humans with attacks like that, so at the point WukongJS plays the perfect defense and finds the perfect attack it feels inhuman.
User avatar
towforce
Posts: 11575
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: A thought on originality

Post by towforce »

Dann Corbit wrote: Mon Jan 18, 2021 1:39 pm One man finds a pretty math equation and puts it into his chess program. Then like a million itty-bitty workers, they smash the giant slab of marble that is "the game of chess" into magic pixie dust. We take that pixie dust (I call it that because nobody even knows how it works) and vacuum it up so we can use it. When we sprinkle the pixie dust on a chess position, the right answer pops out.

Another man labors intensively, reading books on chess and programming. He does least squares fits, levenberg-marquardt fits, and gradient descents to beautifully hone the resulting information. Again and again, term after term, he chases the same elusive goddess. Finally, he tops his beautiful meat grinder off with some whip cream and nuts and feeds a chess position into it. A pretty good answer pops out,

I'd rather have the right answer, pixie dust and all. Because that is what I am after, the right answer.
And the fact that it fell out of a math equation and is simple is not ugly. It is beautiful and somehow fundamental.
Even though the pixie dust does bother me a little bit because I don't know exactly how it works. E.g, "What is this bit of pixie dust doing?"
Response, "shrug"

From previous discussions: it's wonderfully simple - but you've all failed to see it. Here's the quick version: old chess programs look for shallow patterns. NNs learn a large number of shallow patterns. Humans see deep patterns, but don't have AB search.

The key is to find a way for machines to find deep patterns. I discussed this in depth on this forum last year.
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
User avatar
mvanthoor
Posts: 1784
Joined: Wed Jul 03, 2019 4:42 pm
Location: Netherlands
Full name: Marcel Vanthoor

Re: A thought on originality

Post by mvanthoor »

Dann Corbit wrote: Mon Jan 18, 2021 1:39 pm One man finds a pretty math equation and puts it into his chess program. Then like a million itty-bitty workers, they smash the giant slab of marble that is "the game of chess" into magic pixie dust. We take that pixie dust (I call it that because nobody even knows how it works) and vacuum it up so we can use it. When we sprinkle the pixie dust on a chess position, the right answer pops out.

Another man labors intensively, reading books on chess and programming. He does least squares fits, levenberg-marquardt fits, and gradient descents to beautifully hone the resulting information. Again and again, term after term, he chases the same elusive goddess. Finally, he tops his beautiful meat grinder off with some whip cream and nuts and feeds a chess position into it. A pretty good answer pops out,

I'd rather have the right answer, pixie dust and all. Because that is what I am after, the right answer.
And the fact that it fell out of a math equation and is simple is not ugly. It is beautiful and somehow fundamental.
Even though the pixie dust does bother me a little bit because I don't know exactly how it works. E.g, "What is this bit of pixie dust doing?"
Response, "shrug"
The "right" answer is not what I'm after. Personally, I'm after beautiful chess games. I'm certain that I could beat computers of much higher strength if I didn't play like an idiot all the time. What I mean is: I'm good at calculation and combinations. Against engines however, they often don't work, because I'm incapable of seeing stuff like "check, check, check, check, zwischenzug/check, damn, check, check, mate" strings. What I mean is: I see the first few checks, and against humans, I'm sure I'd be able to escape those and then deliver the mate. The human will probably not see the "zwischenzug" that makes the combination not work. A grandmaster will, probably.

I've tested it against my own engine. When I play against it as I would play against a human, I often lose. When I play against it in a massively positional, solid way, I can very often defeat it, but the games are bo-hooor-ing.

I'd rather have an engine that plays like a low-end Tal, Ivanchuk or Kasparov, than an engine that plays like a low-end Karpov or Petrosian.

At this time, my engine plays very tactical chess, because it has non-tuned, hand-written PST's that play as I would play. I often like to see Rustic play. In the last gauntlet though, I played Rustic against MinimalChess 0.4, and even though MinimalChess 0.4 is stronger by about 50-60 Elo, and though it has much better positional awareness than Rustic because of its tuning, it plays like Karpov... it'll happily take a 150 moves of shuffling to grind Rustic into the ground.

On the other hand, if CuteChess happens to select an opening that goes against MMC 0.4's PST sensibilities, Rustic makes the board explode. A typical game is this one:

[pgn]
[Event "Rustic Alpha 2 Gauntlet"]
[Site "Roermond"]
[Date "2021.05.06"]
[Round "29"]
[White "MinimalChess 0.4.1"]
[Black "Rustic Alpha 2"]
[Result "0-1"]
[ECO "E00"]
[PlyCount "62"]
[EventDate "2021.??.??"]
[TimeControl "60"]

1. d4 {book} Nf6 {book} 2. c4 {book} e6 {book} 3. g3 {book} Bb4+ {book} 4. Bd2
{book} a5 {book} 5. Bg2 {book} Nc6 {book} 6. Nf3 {book} d5 {book} 7. Qc2 {book}
dxc4 {book} 8. Qxc4 {book} Qd5 {book} 9. Qd3 {[%eval 24,7] 3.0s} Bxd2+ {
[%eval 35,6] 2.0s} 10. Nbxd2 {[%eval 32,7] 1.4s} Nb4 {[%eval 20,7] 2.0s} 11.
Qb1 {[%eval 41,7] 3.0s} Qb5 {[%eval 0,7] 1.7s} 12. a3 {[%eval 62,7] 1.8s} Nc6 {
[%eval 0,7] 2.1s} 13. e4 {[%eval 61,7] 2.8s} O-O {[%eval 0,7] 2.2s} 14. Rf1 {
[%eval 63,7] 3.0s} Rd8 {[%eval 5,7] 1.7s} 15. e5 {[%eval 24,7] 1.6s} Ne8 {
[%eval 65,7] 2.3s} 16. Ng5 {[%eval 31,7] 0.99s} Nxd4 {[%eval 125,8] 2.0s} 17.
Qxh7+ {[%eval 60,7] 0.95s} Kf8 {[%eval 120,7] 2.4s} 18. Qh5 {[%eval 79,7] 3.2s}
g6 {[%eval 235,7] 2.5s} 19. Qh8+ {[%eval -109,7] 3.5s} Ke7 {[%eval 475,7] 2.0s}
20. Kd1 {[%eval -239,7] 2.0s} Qa4+ {[%eval 520,7] 1.9s} 21. Ke1 {[%eval -216,7]
0.88s} Nc2+ {[%eval 510,7] 2.9s} 22. Ke2 {[%eval -251,7] 1.6s} Qb5+ {[%eval
502,7] 3.0s} 23. Kd1 {[%eval -365,7] 1.3s} Nxa1 {[%eval 505,7] 3.2s} 24. Qg8 {
[%eval -396,7] 1.3s} Qb3+ {[%eval 32738,8] 3.4s} 25. Ke1 {[%eval -905,8] 2.0s}
Nc2+ {[%eval 32742,8] 3.6s} 26. Kd1 {[%eval -905,7] 0.83s} Nb4+ {[%eval 32746,
6] 0.62s} 27. Ke1 {[%eval -9999,8] 2.4s} Nd3+ {[%eval 32750,7] 0.63s} 28. Ke2 {
[%eval -9999,8] 0.84s} Nf4+ {[%eval 32754,7] 0.64s} 29. Ke1 {[%eval -9999,7] 0.
25s} Nxg2+ {[%eval 32758,7] 0.66s} 30. Ke2 {[%eval -9999,5] 0.019s} Qd3+ {
[%eval 32762,7] 0.68s} 31. Kd1 {[%eval -9999,3] 0.001s} Qxd2# {[%eval 32766,7]
0.69s, Black mates} 0-1
[/pgn]

After 13. e4, the thing that pops into my mind is "Stuck in the middle with you" from Gerry Rafferty. MMC gets its king stuck, and it can't castle... but it still plays Rf1, because that is where the rook is 'supposed' to be. With 15 e5 and 16 Ng5, MinimalChess tries to be tactical, probably because its PST's tell it that this setup with knight and queen is advantageous. Indeed, most humans playing black would probably freak out. Rustic however, ignores the entire attack, and starts its own attack with Nxd4, because it has already seen that white will run out of checks... and then it's Rustic's turn, with the white king stuck in the middle, and a knight, a rook (on d8) and a queen in the attack, while the white queen is out of play on h8. As soon as the checks run out, the combination follows that first gains some material and finally mates. Game over in 31 moves. With white, I would not have dared to capture on h7 with the queen, seeing that I have no checks after Qh8; after which black basically takes over the attack; even though I can't see the end of the black combination, it must be successful because the white king is so open. (Actually, after capturing on h7, Stockfish immediately says "Black has a decisive advantage.")

Note that I'm not panning MinimalChess here. Thomas has done a great job with such a simple program. What is shown here, is the difference between an engine that is somewhat slow (about 20% of Rustic's speed), but has highly tuned positional awareness, against an engine that is very fast and has a very aggressive playing style, because that is what _I_ put into its PST's. If MinimalChess is a slow meat grinder, Rustic Alpha 2 is a chainsaw... and yes, because of that, Rustic sometimes takes its own head off if it starts a combination that actually DOESN'T work because of a positional thing or two that it yet doesn't know about.

I'll go the tuned way as well, in some time (because I want the engine to increase in strength as much as possible), but I might actually keep an untuned version of the evaluation function. (It will be "tapered" because the tuned function is, but it'll use the same PST's in the middle-game and end-game, so effectively it's just a single set of PST.) I'd keep it specifically to play against, as a UCI option, in combination with a level / skill setting. It will be weaker, but it will play much more interesting chess.

Neural network engines are a magnitude worse than MinimalChess (or any other tuned engine). Earlier versions of Leela actually got the complaint that it was trolling other engines by stretching out games; what it was doing was following the most sure path to victory from a better position. I don't know yet if this was changed / improved, but this was one of the reasons I never seriously tried Leela.

Personally, my favorite engine is still Stockfish 10, on a lower skill level around 7 or so.
Author of Rustic, an engine written in Rust.
Releases | Code | Docs | Progress | CCRL
User avatar
lithander
Posts: 881
Joined: Sun Dec 27, 2020 2:40 am
Location: Bremen, Germany
Full name: Thomas Jahn

Re: A thought on originality

Post by lithander »

mvanthoor wrote: Fri May 07, 2021 1:31 am [pgn]
[Event "Rustic Alpha 2 Gauntlet"]
[Site "Roermond"]
[Date "2021.05.06"]
[Round "29"]
[White "MinimalChess 0.4.1"]
[Black "Rustic Alpha 2"]
[Result "0-1"]
[ECO "E00"]
[PlyCount "62"]
[EventDate "2021.??.??"]
[TimeControl "60"]

1. d4 {book} Nf6 {book} 2. c4 {book} e6 {book} 3. g3 {book} Bb4+ {book} 4. Bd2
{book} a5 {book} 5. Bg2 {book} Nc6 {book} 6. Nf3 {book} d5 {book} 7. Qc2 {book}
dxc4 {book} 8. Qxc4 {book} Qd5 {book} 9. Qd3 {[%eval 24,7] 3.0s} Bxd2+ {
[%eval 35,6] 2.0s} 10. Nbxd2 {[%eval 32,7] 1.4s} Nb4 {[%eval 20,7] 2.0s} 11.
Qb1 {[%eval 41,7] 3.0s} Qb5 {[%eval 0,7] 1.7s} 12. a3 {[%eval 62,7] 1.8s} Nc6 {
[%eval 0,7] 2.1s} 13. e4 {[%eval 61,7] 2.8s} O-O {[%eval 0,7] 2.2s} 14. Rf1 {
[%eval 63,7] 3.0s} Rd8 {[%eval 5,7] 1.7s} 15. e5 {[%eval 24,7] 1.6s} Ne8 {
[%eval 65,7] 2.3s} 16. Ng5 {[%eval 31,7] 0.99s} Nxd4 {[%eval 125,8] 2.0s} 17.
Qxh7+ {[%eval 60,7] 0.95s} Kf8 {[%eval 120,7] 2.4s} 18. Qh5 {[%eval 79,7] 3.2s}
g6 {[%eval 235,7] 2.5s} 19. Qh8+ {[%eval -109,7] 3.5s} Ke7 {[%eval 475,7] 2.0s}
20. Kd1 {[%eval -239,7] 2.0s} Qa4+ {[%eval 520,7] 1.9s} 21. Ke1 {[%eval -216,7]
0.88s} Nc2+ {[%eval 510,7] 2.9s} 22. Ke2 {[%eval -251,7] 1.6s} Qb5+ {[%eval
502,7] 3.0s} 23. Kd1 {[%eval -365,7] 1.3s} Nxa1 {[%eval 505,7] 3.2s} 24. Qg8 {
[%eval -396,7] 1.3s} Qb3+ {[%eval 32738,8] 3.4s} 25. Ke1 {[%eval -905,8] 2.0s}
Nc2+ {[%eval 32742,8] 3.6s} 26. Kd1 {[%eval -905,7] 0.83s} Nb4+ {[%eval 32746,
6] 0.62s} 27. Ke1 {[%eval -9999,8] 2.4s} Nd3+ {[%eval 32750,7] 0.63s} 28. Ke2 {
[%eval -9999,8] 0.84s} Nf4+ {[%eval 32754,7] 0.64s} 29. Ke1 {[%eval -9999,7] 0.
25s} Nxg2+ {[%eval 32758,7] 0.66s} 30. Ke2 {[%eval -9999,5] 0.019s} Qd3+ {
[%eval 32762,7] 0.68s} 31. Kd1 {[%eval -9999,3] 0.001s} Qxd2# {[%eval 32766,7]
0.69s, Black mates} 0-1
[/pgn]

After 13. e4, the thing that pops into my mind is "Stuck in the middle with you" from Gerry Rafferty. MMC gets its king stuck, and it can't castle... but it still plays Rf1, because that is where the rook is 'supposed' to be. With 15 e5 and 16 Ng5, MinimalChess tries to be tactical, probably because its PST's tell it that this setup with knight and queen is advantageous. Indeed, most humans playing black would probably freak out. Rustic however, ignores the entire attack, and starts its own attack with Nxd4, because it has already seen that white will run out of checks... and then it's Rustic's turn, with the white king stuck in the middle, and a knight, a rook (on d8) and a queen in the attack, while the white queen is out of play on h8. As soon as the checks run out, the combination follows that first gains some material and finally mates. Game over in 31 moves. With white, I would not have dared to capture on h7 with the queen, seeing that I have no checks after Qh8; after which black basically takes over the attack; even though I can't see the end of the black combination, it must be successful because the white king is so open. (Actually, after capturing on h7, Stockfish immediately says "Black has a decisive advantage.")
An interesting game you've picked there as it contains not only one but two blunders caused directly by the PST based evaluation failing to grasp an unusual position. Thanks for pointing it out to me!

Why two blunders due to PSTs? Well, that's how I would explain what MinimalChess is doing with the queen up there: The difference in PST value between the from-square and the to-square of 19.. ke7 is worth more than a pawn. That's because the PST encourages kings to remain on safe squares on the king or queen side (reached through castling) behind a pawn shield and MinimalChess doesn't realize that the King was already pretty exposed due to a lack of shielding pawns. It just saw a chance to threaten the king and presumed forcing it to move to e7 would weaken the enemies position by ~100cp. Maybe in a typical position that would have been true but in atypical positions the PST don't adapt and can lead the engine astray.

What we've seen with the stupid Rf1 move is just another example of the same situation: normally it would have been a castling move but the black queen threatens the f1 square and so makes castling impossible. Doesn't stop MMC from playing "half" of the castling anyway because it still improves the eval by placing the rook on a "good" square. That the king didn't move, too, wasn't reducing the evaluation enough to discourage playing that move.

I might have to look into adding a dynamic component to the eval if I want to counter such strange play. Don't see how it can be fixed with PST's only evaluation.
Minimal Chess (simple, open source, C#) - Youtube & Github
Leorik (competitive, in active development, C#) - Github & Lichess
User avatar
towforce
Posts: 11575
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: A thought on originality

Post by towforce »

lithander wrote: Sun May 09, 2021 10:21 pmAn interesting game you've picked there as it contains not only one but two blunders caused directly by the PST based evaluation failing to grasp an unusual position. Thanks for pointing it out to me!

I don't blame you in the slightest: since the beginning of computer chess, we've been discovering that shallow, surface-level evaluation misses important information about the position. The remedy has been to relentlessly drive search depth deeper and deeper. This has been very successful to be fair.

We now have a second sticking-plaster: nets which combine large amounts of shallow, surface-level knowledge, reducing the risk of something important being missed.

For me, the better solution is to find a way to capture the deep patterns in chess.
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
chrisw
Posts: 4317
Joined: Tue Apr 03, 2012 4:28 pm

Re: A thought on originality

Post by chrisw »

towforce wrote: Sun May 09, 2021 11:17 pm
lithander wrote: Sun May 09, 2021 10:21 pmAn interesting game you've picked there as it contains not only one but two blunders caused directly by the PST based evaluation failing to grasp an unusual position. Thanks for pointing it out to me!

We now have a second sticking-plaster: nets which combine large amounts of shallow, surface-level knowledge,
Not even wrong.
User avatar
mvanthoor
Posts: 1784
Joined: Wed Jul 03, 2019 4:42 pm
Location: Netherlands
Full name: Marcel Vanthoor

Re: A thought on originality

Post by mvanthoor »

lithander wrote: Sun May 09, 2021 10:21 pm What we've seen with the stupid Rf1 move is just another example of the same situation: normally it would have been a castling move but the black queen threatens the f1 square and so makes castling impossible. Doesn't stop MMC from playing "half" of the castling anyway because it still improves the eval by placing the rook on a "good" square. That the king didn't move, too, wasn't reducing the evaluation enough to discourage playing that move.
Yes. What MMC should have done, is castle first, THEN play e4 and e5, and THEN go after the black king with Ng5, Rd1, and by pushing (and if necessary, sacrificing) the d-pawn to open files. Capturing the d4 and/or e2 pawns in this scenario is actually very dangerous for black, because the king is driven to e7. If the center files are then open, it's over; especially if the other king is safe.

In essence, Rustic turned the table on MMC (checking to get pieces closer, and attacking over open lines), due to the fact that MMC lost the initiative. After Qh8+ Ke7, white threatens to be mated in one. You have to abandon the attack and go and defend. (Such a move, made out of necessity, is called "gote" in Go. It means that you have to make a slow move for some reason, which cedes the initiative to your opponent.) You only want to make such a move if there is an impasse: i.e., if -you- make the slow move, the opponent -can't- make a forcing move either, so the initiative ends up with you again.

In Go, a "gote" move will probably cost you some points, and you'll have to start fights to try and come back from that again. In Chess, in an open position, it can cost you the game. In this case, both sides are on the verge of being mated in one, but it was Rustic's move after Qg8. (And thus, Rustic's initiative.)

This is one of the most intangible things in both chess and go. If you watch some of the video's of "GothamChess" on YouTube, he often talks about "danger levels". "If you threaten my knight, I threaten your rook, so you can't take my knight. If you then threaten my Queen so I can't take your rook, I'll threaten your king." What GothamChess calls danger levels, is actually the fight for the initiative.

To summarize: if possible, you want to make moves that will make it necessary for your opponent to react to them, instead of doing what he wanted to do. Then, it's your move again, so -you- dictate the flow of the game.

This is actually very hard to program into an engine, because initiative is very easy to slip beyond the horizon. It doesn't matter how deep you think: if you lose the initiative on your last move, the opponent can do whatever he wants, but it's outside of your horizon. There should be a function in the evaluation that says "do I have the initiative in this position", similar to qsearch (but positionally instead of materialistic), but I can't really begin to think how to write one that is correct for every position.
Author of Rustic, an engine written in Rust.
Releases | Code | Docs | Progress | CCRL
User avatar
towforce
Posts: 11575
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: A thought on originality

Post by towforce »

chrisw wrote: Mon May 10, 2021 12:48 pm
We now have a second sticking-plaster: nets which combine large amounts of shallow, surface-level knowledge,
Not even wrong.

You must have missed the previous discussion on this. To summarise, it's not proven, but the evidence suggests that chess nets are encoding a large amount of shallow knowledge (simple patterns), and that strong human players must have some deep knowledge (complex patterns) that chess nets don't.

Here are some quick thoughts (the discussion went a lot deeper than this):

* the nets have been trained on a huge number of positions (billions?)

* it seems likely that human knowledge is based on a few hundred thousand positions that the player has studied deeply

* without AB search, a strong human can still beat a net right now

It seems likely, then, that the human must have formed some patterns that the nets have not, despite having only seen a tiny, tiny fraction of the positions that the nets have. Thinking about the way strong humans learn in relation to the way that nets learn, the humans are likely to be forming deep knowledge (a small number of complex patterns), while the nets are forming a large amount of shallow (simple) patterns.

Where there is usable regularity in complex environments, it tends to be the case that a small number of complex patterns will trump a large number of simple patterns.

Hand-coded evaluations lie at the opposite end of the scale: they are not very accurate, but they run very quickly and hence become useful in big AB searches.
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
chrisw
Posts: 4317
Joined: Tue Apr 03, 2012 4:28 pm

Re: A thought on originality

Post by chrisw »

towforce wrote: Mon May 10, 2021 3:23 pm
chrisw wrote: Mon May 10, 2021 12:48 pm
We now have a second sticking-plaster: nets which combine large amounts of shallow, surface-level knowledge,
Not even wrong.

You must have missed the previous discussion on this. To summarise, it's not proven, but the evidence suggests that chess nets are encoding a large amount of shallow knowledge (simple patterns), and that strong human players must have some deep knowledge (complex patterns) that chess nets don't.
Not even wrong.