Only alphabeta engine

Discussion of chess software programming and technical issues.

Moderator: Ras

Uri Blass
Posts: 11070
Joined: Thu Mar 09, 2006 12:37 am
Location: Tel-Aviv Israel

Re: Only alphabeta engine

Post by Uri Blass »

syzygy wrote: Sat Nov 15, 2025 5:43 am
Uri Blass wrote: Sat Nov 15, 2025 3:32 am
syzygy wrote: Sat Nov 15, 2025 12:47 am
OttoLau wrote: Fri Nov 14, 2025 10:47 pm Has anyone ever tried the limits of how strong of an engine you can get only using safe pruning methods and their enhancements?
Talking about:
Alphabeta
Mate distance pruning
PVS
TT
Aspiration windows
Good move ordering
And not using any unsafe pruning:
Razoring
NMP
LMR
Delta inside quiescence
etc.
Would be intresting to know the effect of full knowledge search versus the deeper but less accurate pruned search
See Deep Blue. You need 200Mnps to achieve around 2700 Elo.
Deep blue does not use NNUE evaluation. I guess that with NNUE evaluation that does not contradict only using alpha beta in search you can get a lot more than Deep Blue.
True, but we know that pre-NNUE versions of SF were already much stronger than Deep Blue (at much lower nps). But I will admit that it is not really fair to point to a nearly 30-year old "engine".

The Deep Blue creators decided against non-safe pruning methods (I think because its predecessor Deep Thought once missed a tactic). They will not have realized how much they crippled Deep Blue with that decision.

I once removed what I think are exactly the non-safe pruning methods from Stockfish(/Cfish) to create Cripplefish:
https://github.com/syzygy1/Cfish/commit ... 254428c6b0
Cripplefish tested 800 Elo weaker.
I see CrippleFish is from 2018.
I believe the difference today is clearly smaller than 800 elo because often the evaluation is good enough to find good moves without search.
syzygy
Posts: 5801
Joined: Tue Feb 28, 2012 11:56 pm

Re: Only alphabeta engine

Post by syzygy »

Uri Blass wrote: Sat Nov 15, 2025 3:53 pmI believe the difference today is clearly smaller than 800 elo because often the evaluation is good enough to find good moves without search.
I just created an up to date version:
https://github.com/syzygy1/Stockfish/tree/cripplefish

It compiles with some warnings (unused variables) but seems to work fine.
In the one game I let it play against unmodified SF, it actually did quite well, almost drawing but then losing in the endgame.

If someone wants to do a longer test... (and is willing to compile it himself).
gflohr
Posts: 66
Joined: Fri Jul 23, 2021 5:24 pm
Location: Elin Pelin
Full name: Guido Flohr

Re: Only alphabeta engine

Post by gflohr »

I believe that my engine plisco (https://github.com/gflohr/Chess-Plisco) is not using any unsafe pruning. Well, there may be unsafe prunings, but they will unfortunately qualify as a bug. ;)

It occasionally plays on Lichess (https://lichess.org/@/plisco-bot). If it does, it runs on an Apple M1 from 2021 or so, uses a 1GB Hash table (is that oversized?), at the time of this writing no endgame tablebase, and it uses an opening book, mostly to be less boring. Pondering is not yet implemented. The bot has a Lichess rating of approximately 1900 for rapid and classical. It is considerably weaker for blitz and bullet, probably because the evaluation function is too simple.

That is, of course, not impressive, but the p in plisco stands for Perl. It is entirely written in pure Perl. It very often beats bots written in other scripting languages, and also beats compiled bots regularly. I'm using these safe techniques:

- alphabeta ... sure
- iterative deepening
- aspiration windows
- null window searches

And I think that's it.

The underlying Perl library Chess::Plisco automatically sorts moves more or less by the achieved material gain. In the engine, I also take the results of an SEE (static exchange evaluation) into account, plus tt table hits and the pv of the previous iteration. And the engine is not meant to be competitive but rather a fun experiment to find out how much performance I can squeeze out of Perl.
User avatar
hgm
Posts: 28418
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Only alphabeta engine

Post by hgm »

NMP, LMR and razoring are not 'safe prunings', right? Only alpha-beta and futility pruning are guaranteed not to change the result of a fixed-depth minimax search.
OttoLau
Posts: 15
Joined: Wed Oct 22, 2025 7:10 pm
Location: Finland
Full name: Otto Laukkanen

Re: Only alphabeta engine

Post by OttoLau »

gflohr wrote: Sat Nov 15, 2025 8:16 pm I believe that my engine plisco (https://github.com/gflohr/Chess-Plisco) is not using any unsafe pruning. Well, there may be unsafe prunings, but they will unfortunately qualify as a bug. ;)

It occasionally plays on Lichess (https://lichess.org/@/plisco-bot). If it does, it runs on an Apple M1 from 2021 or so, uses a 1GB Hash table (is that oversized?), at the time of this writing no endgame tablebase, and it uses an opening book, mostly to be less boring. Pondering is not yet implemented. The bot has a Lichess rating of approximately 1900 for rapid and classical. It is considerably weaker for blitz and bullet, probably because the evaluation function is too simple.

That is, of course, not impressive, but the p in plisco stands for Perl. It is entirely written in pure Perl. It very often beats bots written in other scripting languages, and also beats compiled bots regularly. I'm using these safe techniques:

- alphabeta ... sure
- iterative deepening
- aspiration windows
- null window searches

And I think that's it.

The underlying Perl library Chess::Plisco automatically sorts moves more or less by the achieved material gain. In the engine, I also take the results of an SEE (static exchange evaluation) into account, plus tt table hits and the pv of the previous iteration. And the engine is not meant to be competitive but rather a fun experiment to find out how much performance I can squeeze out of Perl.
Hi, seems like a fun project. Any obstacles you have ran into using Perl?
gflohr
Posts: 66
Joined: Fri Jul 23, 2021 5:24 pm
Location: Elin Pelin
Full name: Guido Flohr

Re: Only alphabeta engine

Post by gflohr »

OttoLau wrote: Tue Nov 18, 2025 8:37 pm Hi, seems like a fun project. Any obstacles you have ran into using Perl?
Perl is a C-like language, which makes it easy to port code from C, like magic bitboards.

But being interpreted, Perl is really slow compared to C. That is the biggest obstacle, but also fun trying to squeeze the last bit of performance out of a language whose primary goal is definitely not number crunching.

One thing that I'm really happy about is the separation into a library and an engine. That makes it very easy to try out things, even swapping out the engine.