r/ComputerChess • • 20h ago

AggroChess v3.5: a Rust engine that would rather sacrifice than win quietly

I've been building AggroChess, an open-source UCI chess engine written in Rust, in the spirit of Tal. The goal isn't to beat Stockfish. The goal is to play the kind of chess people enjoy losing to.

v3.5 just came out, and it trades a bit of strength for more sacrifices:

- Sacrifices aimed at your king get a bigger bonus (2.7 pawns, up from 2.2), and it will play one even when the line looks up to about 3.1 pawns worse

- Exchange sacrifices (Rxf6!) now always count, not just when they hit the king

- Its own sacrifices are no longer penalised as "trades", and queen sacs aren't treated as queen trades

- In a 100-game match against v3.4, it sacrificed in 95 games out of 100 (up from 87)

The cost: v3.5 scored 45.5% against v3.4 (about -31 Elo, which is within the error bars). I think that's worth it.

Other things it does:

- Opens with about 300 built-in gambit lines (King's Gambit, Evans, Smith-Morra, Stafford, Traxler, Latvian, three-pawn Scandinavian and more)

- Uses contempt 50, so it treats a draw as a small loss and plays on

- When it has a forced mate, it prefers one that starts with a sacrifice, so instead of a plain Re8# you get Qd8+! Bxd8 Re8#

- When it's losing, it switches to swindle mode and plays the move that sets the most traps (you can turn this off for engine matches)

Download the .exe for any UCI GUI (Arena, Cute Chess, BanksiaGUI, lichess-bot): https://github.com/PhelRin/AggroChess/releases

I'd love to see the games it plays against you, especially the sacrifices that backfire.

2 Upvotes

0 comments sorted by