Cosmonaut in spirit; pushing through to new frontiers.
Computing for common good.
Computer program that plays chess.
Cosmonaut in spirit; pushing through to new frontiers.
Computing for common good.
Hi Alan, since the readme suggests building on "Any UNIX derived OS", just wanted to point out a compilation error on macos (ventura 13.1):
src/util.h:140:16: error: definition of type 'stack_t' conflicts with typedef of the same name
typedef struct stack_t {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/sys/_types/_sigaltstack.h:48:33: note: 'stack_t' declared here
typedef _STRUCT_SIGALTSTACK stack_t; /* [???] signal stack */
it seems some internal structure in the macos developer stack is also named stack_t
. Would you consider wrapping in a namespace or renaming to support macos compilation?
Implement determination of game progression based on material remaining.
When considering different lines, worse lines are frequently swapped out for better lines. Create a data structure that is optimized to do this without dynamic memory allocation (slow) and excessive copying (also slow).
Replace current custom hash function with zobrist hashing and implement a transposition table.
Currently, there are two nearly identical functions to implement alpha-beta minimax. One for the minimizing side, one of the maximizing size. Use the relation: alphabeta(a,b) = -alphabeta(-b, -a) to convert to "negamax" therefore requiring less, more compact code.
Different Positions could have duplicate hash codes. Therefore, whenever the repetition count hits three during draw verification, we must verify the move history to see if the position is actually drawn by three-fold repetition.
Tell the search algo to keep searching until there are no more captures or checks remaining. Then evaluate the position.
Implement 3 fold repetition -> draw rule into evaluation function. Incentivize repeating moves when evaluation is unfavorable.
i just discovered your Juliette chess engine .. i managed to compile it and it seems a valid binary is created, but then it fails in CuteChess.
at first i let it play a 7m+3s game :
<4ku v4.0(149): readyok
>Juliette(148): ucinewgame
>Juliette(148): position startpos
>4ku v4.0(149): ucinewgame
>4ku v4.0(149): position startpos
>Juliette(148): isready
<Juliette(148): readyok
>Juliette(148): go wtime 423000 btime 423000 winc 3000 binc 3000
<Juliette(148): bestmove d2d4
>4ku v4.0(149): position startpos moves d2d4
>4ku v4.0(149): isready
<4ku v4.0(149): readyok
>4ku v4.0(149): go wtime 409231 btime 423000 winc 3000 binc 3000
<4ku v4.0(149): info depth 1 score cp 18 time 0 nodes 20 pv g8f6
<4ku v4.0(149): info depth 2 score cp 8 time 0 nodes 91 pv g8f6 b1c3
[...]
<4ku v4.0(149): info depth 23 score cp -30 time 12047 nodes 12539888 nps 1040913 pv d7d5
<4ku v4.0(149): info depth 24 score cp -41 time 19509 nodes 20353239 nps 1043274 pv d7d5
<4ku v4.0(149): bestmove d7d5
>Juliette(148): position startpos moves d2d4 d7d5
>Juliette(148): isready
<Juliette(148): juliette:: board initialization failed!
<Juliette(148): readyok
>Juliette(148): go wtime 409231 btime 406491 winc 3000 binc 3000
<Juliette(148): juliette:: a start position must be specified.
Juliette knows the UCI protocol but it can't interpret position startpos moves d2d4 d7d5
and quits by a start position must be specified
..
then i let it play a game with many hours thinking time, just to see what happens :
<4ku v4.0(144): readyok
>Juliette(143): ucinewgame
>Juliette(143): position startpos
>4ku v4.0(144): ucinewgame
>4ku v4.0(144): position startpos
>Juliette(143): isready
<Juliette(143): readyok
>Juliette(143): go wtime 423000 btime 423000 winc 3000 binc 3000
<Juliette(143): bestmove g1f3
>4ku v4.0(144): position startpos moves g1f3
>4ku v4.0(144): isready
<4ku v4.0(144): readyok
>4ku v4.0(144): go wtime 409222 btime 423000 winc 3000 binc 3000
<4ku v4.0(144): info depth 1 score cp -29 upperbound time 0 nodes 20
<4ku v4.0(144): info depth 1 score cp -29 time 1 nodes 40 nps 40000 pv b8c6
[...]
<4ku v4.0(144): info depth 22 score cp -27 time 8395 nodes 8957271 nps 1066976 pv d7d5 d2d4 g8f6 e2e3 e7e6 c2c4 c7c5 c4d5 e6d5 f1b5
<4ku v4.0(144): info depth 23 score cp -38 time 14169 nodes 15184113 nps 1071643 pv d7d5 d2d4 g8f6 c2c4 d5c4
<4ku v4.0(144): bestmove d7d5
>Juliette(143): position startpos moves g1f3 d7d5
>Juliette(143): isready
<Juliette(143): juliette:: board initialization failed!
<Juliette(143): readyok
>Juliette(143): go wtime 409222 btime 411832 winc 3000 binc 3000
<Juliette(143): juliette:: a start position must be specified.
Juliette doesn't output a bestmove
!?
it's a pitty Juliette can't play in CuteChess .. it seems a minor bug, maybe you didn't mention those errors in e.g. CuteChess ..
btw.
setoption
, but they're not visible in the CuteChess option pane !? I guess this is also easy to repair ..bestmove
output : you did a ':' after bestmove
but CuteChess (and other chess software) will fail such command bestmove: [move]
.[ i'm on Xubuntu 22.04 ]
We must know how many checks/captures there are in a move list. It may be convenient to create a "movelist" object backed by an array that also tracks additional information such as the number of checks, and the number of captures.
Implement a custom data structure for the move list with counters storing data for the number of checks, and captures. This data structure should be optimized for swapping elements and popping back.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.