Unify (D)FRC castling rights notation to X-FEN#71
Unify (D)FRC castling rights notation to X-FEN#71robertnurnberg wants to merge 1 commit intoofficial-stockfish:masterfrom
Conversation
|
just dont use KQkq notation at all? |
|
That would also be possible. But (a) the KQkq seems to be more common (and natural tbh) and (b) the edit from KQkq to rook files is a bit more involved. I believe in master all FRC books use the KQkq notation. Out of curiosity, what does fastchess use for the FEN tag in a pgn, say? |
|
b) that makes little sense to me as for DFRC you would need to be able to parse both formats, easier to assume only the file encoding than KQkq fastchess only uses file encoding |
|
With (b) I meant that the effort for this PR virtually involved I checked Lichess analysis board and python-chess, and both revert to import chess
fen = "bbqnnrkr/pppppppp/8/8/8/8/PPPPPPPP/BBQNNRKR w HFhf - 0 1"
print(fen)
board = chess.Board(fen, chess960=True)
print(board.fen())giving the output To me I guess we were just unlucky that vondele used a tool/script with rook file notation in #31. PS: As a bonus, using |
|
So it turns out that the X-FEN standard says to use This "strict" X-FEN standard is also used by cdb, by the way. See vondele/cdbdirect#19. |
|
Now that chess-lib also has x-fen support, any chance we can merge this? @vondele |
|
wouldn't we a) need to update fastchess and b) fishtest ? |
|
Hm, x-fen input has worked for a long time in fastchess, stockfish and fishtest, I believe. Like testing with My reference to today's x-fen patch to chess-lib was meant to say that now it is trivial for everyone to produce x-fen books in future. So I believe we should consistently use that from now on. |
I would like to mention that the x-fen form is much less commonly supported in non-SF engines than the shredder fen form ( of course this doesn't matter for books that are purely used for cutechess and fastchess, and I think at least cutechess will always pass shredder fens to engines(?), but it is not uncommon for engines to want to directly ingest lists of fens for one purpose or another |
In master we have:
In the past this has caused some confusion, especially because in
DFRC_4852_v1.epdboth notations can be found.This patch changes all the castling rights for the DFRC start positions to
KQkq. This is a "non functional" change, since in the start positions there can be no ambiguity. All the other positions inDFRC_4852_v1.epdalready use theKQbased notation (where possible), as they were emitted by python-chess, which defaults to this standard.