Let's explore an idea

Discussion of chess software programming and technical issues.

Moderators: hgm, Dann Corbit, Harvey Williamson

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Post Reply
Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 12:36 am

Bricabrac without any reductions.

FEN: rnbqkbnr/pppppppp/8/8/3P4/8/PPP1PPPP/RNBQKBNR b KQkq d3 0 1

Bricabrac:
1 00:00 20 20 +0.33 b1c3
2 00:00 218 218 +0.12 e2e4 d7d5
3 00:00 974 974 +0.34 d2d4 b8c6 e2e4
4 00:00 6k 6k +0.18 g1f3 d7d5 d2d4 e7e6
5 00:00 21k 21k +0.18 g1f3 d7d5 d2d4 g8f6 e2e3
6 00:00 153k 15,350k +0.16 e2e4 g8f6 e4e5 f6e4 d2d3 e4c5
7 00:00 628k 15,688k +0.20 e2e4 b8c6 g1f3 g8f6 e4e5 f6e4 d2d4
8 00:00 2,860k 10,593k +0.26 e2e4 b8c6 d2d4 g8f6 e4e5 f6d5 g1f3 e7e6
9 00:01 16,363k 13,523k +0.19 e2e4 b8c6 d2d4 e7e6 g1f3 d7d5 e4d5 e6d5 c2c3
10 00:12 142,213k 11,714k +0.18 d2d4 g8f6 g1f3 d7d5 b1c3 b8c6 c1f4 e7e6 a1c1 h7h6
11 00:39 531,503k 13,314k +0.14 d2d4 g8f6 g1f3 e7e6 b1c3 f8b4 c1g5 e8g8 e2e4 b8c6 h2h3

This is the basic most idea.

Code: Select all

    if (depth > 3) {
      mov->score = -Search(t, m + n, -beta, -alpha, depth - 3);
      if (mov->score > alpha && mov->score < beta)
      mov->score = -Search(t, m + n, -beta, -alpha, depth - 1);
    }
    else {
      mov->score = -Search(t, m + n, -beta, -alpha, depth - 1);
    }
Bricabrac with just this one idea for reduction.

FEN: rnbqkbnr/pppppppp/8/8/4P3/8/PPPP1PPP/RNBQKBNR b KQkq e3 0 1

Bricabrac:
1 00:00 20 20 +0.33 b1c3
2 00:00 218 218 +0.12 e2e4 d7d5
3 00:00 974 974 +0.34 d2d4 b8c6 e2e4
4 00:00 6k 6k +0.18 g1f3 d7d5 d2d4 e7e6
5 00:00 8k 8k +0.18 g1f3 d7d5 d2d4 g8f6 e2e3
6 00:00 18k 18k +0.14 b1c3 g8f6 e2e4 d7d5 e4d5 f6d5
7 00:00 35k 35k +0.18 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 e2e3
8 00:00 63k 63k +0.17 b1c3 g8f6 e2e4 b8c6 g1f3 d7d5 e4d5 f6d5
9 00:00 192k 19,224k +0.22 b1c3 g8f6 d2d4 d7d5 c1f4 c8f5 c3b5 b8a6 e2e3
10 00:00 408k 13,604k +0.18 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 c1f4 e7e6 a1c1 h7h6
11 00:00 1,199k 11,991k +0.30 b1c3 g8f6 e2e4 b8c6 g1f3 e7e5 f1b5 f8d6 b5c6 d7c6 e1g1
12 00:00 2,300k 12,104k +0.11 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 c1e3 c8e6 a1c1 h7h6 h2h3 a7a6
13 00:00 3,994k 12,481k +0.09 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 c1e3 c8e6 a1c1 a8c8 h2h3 h7h6 a2a3
14 00:00 6,884k 12,294k +0.18 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 f3e5 c8e6 e5c6 b7c6 c1f4 g7g6 f4e5 f8g7
15 00:01 12,972k 12,238k +0.07 b1c3 g8f6 g1f3 d7d5 d2d4 c8f5 c1e3 b8c6 a1c1 a8c8 h2h3 e7e6 g2g3 f8d6 f1g2
16 00:02 31,007k 11,880k +0.14 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 c1f4 c8e6 a1c1 a8c8 e2e3 f6h5 f4g5 h7h6 g5h4 a7a6
17 00:05 61,884k 11,993k +0.09 b1c3 g8f6 g1f3 d7d5 d2d4 b8c6 c1e3 c8e6 a1c1 a8c8 h2h3 h7h6 a2a3 g7g6 g2g3 f8g7 f1g2
18 00:11 135,566k 11,799k +0.10 b1c3 g8f6 g1f3 d7d5 d2d4 c8e6 c1f4 b8c6 e2e3 f6h5 f4g5 h7h6 g5h4 g7g6 f1d3 f8g7 e1g1 e8g8
19 00:23 281,382k 11,969k +0.35 e2e4 g8f6 e4e5 f6d5 g1f3 c7c5 b1c3 d5c3 d2c3 d7d5 c1e3 e7e6 f1b5 b8c6 e1g1 c8d7 a2a4 a8c8 h2h3

Game against TSCP. Bric does not know to move its king toward the center in the endgame yet. And note, Bric is still just material + pst. The pst's are PESTO.



One quick mod to the basic idea.

Code: Select all

    if (depth > 3) {
      mov->score = -Search(t, m + n, -beta - 10, -alpha + 10, depth - 3);
      if (mov->score > alpha - 10 && mov->score < beta + 10)
      mov->score = -Search(t, m + n, -beta, -alpha, depth - 1);
    }
    else {
      mov->score = -Search(t, m + n, -beta, -alpha, depth - 1);
    }
FEN: rnbqkbnr/pppppppp/8/8/3P4/8/PPP1PPPP/RNBQKBNR b KQkq d3 0 1

Bricabrac:
1 00:00 20 20 +0.66 b1c3
2 00:00 218 218 +0.45 e2e4 d7d5
3 00:00 974 974 +0.67 d2d4 b8c6 e2e4
4 00:00 6k 6k +0.51 g1f3 d7d5 d2d4 e7e6
5 00:00 11k 11k +0.51 g1f3 d7d5 d2d4 g8f6 e2e3
6 00:00 19k 19k +0.43 g1f3 d7d5 d2d4 g8f6 c1e3 e7e6
7 00:00 52k 52k +0.56 g1f3 d7d5 d2d4 g8f6 b1c3 c8e6 e2e3
8 00:00 170k 16,974k +0.50 b1c3 g8f6 e2e4 b8c6 g1f3 d7d5 e4d5 f6d5
9 00:00 580k 14,492k +0.50 e2e4 b8c6 g1f3 g8f6 b1c3 d7d5 e4d5 f6d5 c3d5
10 00:00 978k 12,220k +0.46 e2e4 b8c6 g1f3 e7e5 b1c3 g8f6 f1d3 d7d5 e1g1 c8e6
11 00:00 2,141k 12,595k +0.58 e2e4 e7e5 g1f3 g8f6 b1c3 f8d6 d2d4 b8c6 d4e5 c6e5 c1e3
12 00:00 6,735k 11,816k +0.50 d2d4 g8f6 g1f3 d7d5 b1c3 b8c6 c1f4 c8e6 a1c1 h7h6 e2e3 a7a6
13 00:02 26,556k 12,126k +0.47 d2d4 g8f6 g1f3 d7d5 b1c3 e7e6 e2e3 f8d6 f1d3 e8g8 e1g1 b8c6 e3e4
14 00:05 61,342k 11,981k +0.53 d2d4 g8f6 g1f3 d7d5 b1c3 b8c6 f3e5 c8e6 e5c6 b7c6 c1g5 h7h6 g5f6 e7f6
15 00:14 168,189k 11,996k +0.50 d2d4 g8f6 g1f3 d7d5 b1c3 b8c6 c1f4 c8e6 e2e3 a8c8 f1d3 c6b4 e1g1 b4d3 d1d3
16 00:33 402,191k 11,878k +0.50 d2d4 g8f6 g1f3 d7d5 c1f4 b8c6 e2e3 e7e6 f1b5 f8d6 e1g1 e8g8 f4d6 d8d6 b1c3 c8d7

A lot more like Bric's 'normal' pv lines.

Game vs TSCP. I did not cherry pick these games. The game above was the very first game. This game is the 3rd because the second was a quick draw.



There is something here but how do we get the most out of this idea?

Ras
Posts: 1875
Joined: Tue Aug 30, 2016 6:19 pm
Full name: Rasmus Althoff
Contact:

Re: Let's explore an idea

Post by Ras » Wed Mar 03, 2021 12:46 am

Mike Sherwin wrote:
Wed Mar 03, 2021 12:36 am
One quick mod to the basic idea.
I'm sceptical on both. Sure you can also reduce even the first move, but all it does is arbitrarily inflating the main search depth that you give to the GUI. And second, why would you want to open the window? Not only that this defeats recursive null window search, but a wider window neither can compensate for less search depth.
Rasmus Althoff
https://www.ct800.net

Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Re: Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 1:01 am

Ras wrote:
Wed Mar 03, 2021 12:46 am
Mike Sherwin wrote:
Wed Mar 03, 2021 12:36 am
One quick mod to the basic idea.
I'm sceptical on both. Sure you can also reduce even the first move, but all it does is arbitrarily inflating the main search depth that you give to the GUI. And second, why would you want to open the window? Not only that this defeats recursive null window search, but a wider window neither can compensate for less search depth.
Not arbitrarily. The interest is in those moves that fall within the AB window. And the AB window is very wide at first so it is not inflated because of the first move anyway. If anything searching depth - 3 with a too wide window is a waste of time. And searching depth - 3 with an open window does not throw out as many lines. It keeps the closest lines to the window to investigate further. The same rules that apply to nominal depth do not apply to reduced depth.

Edit: And besides this is the idea in its simplest form. A starting point only. The first move can be excluded if that would be an improvement.

How come no one ever understands me?

Edit 2: And if the window is opened further it is possible to reduce even more.

Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Re: Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 1:22 am

After my last post I continued the tournament and this is the 4th game of the tournament. The 5th game in total so far. And it is with the open window.

Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Re: Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 3:20 am

A dozen games into the match and the score is Bric +4 -1 =7. Yes, I know 12 games is not statistically enough. However, at this stage of the match before this reduction with an open window Bric +1 -4 =7 would be more like it. I really have to stop being distracted and add 3-fold repetition detection because 4 of the 7 draws using SF13 and my own judgement can be changed to wins for Bric. But, to be conservative I'm only changing 3 of them to wins. So Bric +7 -1 =4 is +191. That is a performance of ccrl 1692 for TSCP + 191 = 1883! :D Already 400 elo above Carnivor which is also about at this stage of development. I'll let this match go the full 100 games. It will be a pain adjusting the score for all those draws.

Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Re: Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 6:06 am

Just a bedtime update. Twenty five of 100 games is finished. The score is Bric +8 -5 =12, +42. If Bric wins the match without adjusting the draw scores that would be a fantastic result. If Bric wins the match by only adjusting the draw scores then it would depend by how much whether this is an improved performance. So far this is a greatly improved performance. With the draws adjusted the score is Bric +13 -5 =7, +115, 1692 + 115 = 1807.

Mike Sherwin
Posts: 281
Joined: Thu Aug 20, 2020 11:25 pm
Full name: Michael J Sherwin

Re: Let's explore an idea

Post by Mike Sherwin » Wed Mar 03, 2021 5:02 pm

A bug has shown up in the engine that caused Bric to lose a few games and at the halfway point the match was tied. When Bric's king is forced to a1 on the next move it commits suicide by capturing itself. :lol: So I ended the match.

Post Reply