Prompt:
FEN: 8/8/5k2/1p3P2/2p1PPn1/2P2K2/B7/8 b - - 2 39
List pseudo-legal moves from g4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from g4: g4e3 g4e5 g4f2 g4h2 g4h6


Prompt:
FEN: 2k2b1r/ppp2ppp/8/q3p3/3r2n1/2N4P/PPPB1PP1/R2Q1RK1 b - - 0 12
For the piece on d4, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from d4: d4a4 d4b4 d4c4 d4d2 d4d3 d4d5 d4d6 d4d7 d4d8 d4e4 d4f4.
Legal: d4a4 d4b4 d4c4 d4d2 d4d3 d4d5 d4d6 d4d7 d4d8 d4e4 d4f4.
Rejected: none.


Prompt:
FEN: r2q1rk1/npp2ppp/4pn2/1P1p1b2/Pb1P4/2N1PN2/1B3PPP/R2QKB1R b KQ - 4 11
For move a7b5, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a7b5.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 8/8/4q3/8/2k2K2/8/8/8 w - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: f4 white king.
Moves by piece:
f4 white king: f4f3 f4g3 f4g5
All legal moves: f4f3 f4g3 f4g5


Prompt:
FEN: 4b3/7k/3R3p/p1p2Np1/2P2p2/7P/P5P1/2K2R2 b - - 3 33
Walk each ray for the slider on e8: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: e8 black bishop.
Ray NE: edge.
Ray SE: f7 empty; g6 empty; h5 empty; edge.
Ray SW: d7 empty; c6 empty; b5 empty; a4 empty; edge.
Ray NW: edge.
Moves from rays: e8a4 e8b5 e8c6 e8d7 e8f7 e8g6 e8h5


Prompt:
FEN: 8/8/6pp/1q3p2/4pP1P/2k3P1/5P2/K7 b - - 12 65
For every side-to-move piece, list pseudo-legal moves, reject illegal ones with reasons, then give all legal moves.

Answer format: include "Side to move:", "Pieces:", "Filter by piece:", one line per side-to-move piece with "pseudo-legal ... | rejected ... | legal ..." fields, and "All legal moves:".

Side to move: black.
Pieces: c3 black king; e4 black pawn; b5 black queen; f5 black pawn; g6 black pawn; h6 black pawn.
Filter by piece:
c3 black king: pseudo-legal c3b2 c3b3 c3b4 c3c2 c3c4 c3d2 c3d3 c3d4 | rejected c3b2 king_would_be_in_check | legal c3b3 c3b4 c3c2 c3c4 c3d2 c3d3 c3d4
e4 black pawn: pseudo-legal e4e3 | rejected none | legal e4e3
b5 black queen: pseudo-legal b5a4 b5a5 b5a6 b5b1 b5b2 b5b3 b5b4 b5b6 b5b7 b5b8 b5c4 b5c5 b5c6 b5d3 b5d5 b5d7 b5e2 b5e5 b5e8 b5f1 | rejected none | legal b5a4 b5a5 b5a6 b5b1 b5b2 b5b3 b5b4 b5b6 b5b7 b5b8 b5c4 b5c5 b5c6 b5d3 b5d5 b5d7 b5e2 b5e5 b5e8 b5f1
f5 black pawn: pseudo-legal none | rejected none | legal none
g6 black pawn: pseudo-legal g6g5 | rejected none | legal g6g5
h6 black pawn: pseudo-legal h6h5 | rejected none | legal h6h5
All legal moves: b5a4 b5a5 b5a6 b5b1 b5b2 b5b3 b5b4 b5b6 b5b7 b5b8 b5c4 b5c5 b5c6 b5d3 b5d5 b5d7 b5e2 b5e5 b5e8 b5f1 c3b3 c3b4 c3c2 c3c4 c3d2 c3d3 c3d4 e4e3 g6g5 h6h5


Prompt:
FEN: 1k2r3/b1p2p2/Pp4p1/1Rp1P2p/2P2P2/6N1/6PP/4K3 b - - 0 34
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: b8a8 b8c8 c7c6 e8c8 e8d8 e8e5 e8e6 e8e7 e8f8 e8g8 e8h8 f7f5 f7f6 g6g5 h5h4


Prompt:
FEN: 8/8/8/8/3N2pp/6k1/8/6K1 w - - 6 60
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: g1 white king; d4 white knight.


Prompt:
FEN: r4rk1/1p1bnp2/p1n1p1p1/2b3Np/q2pPQ2/P2P2N1/2P2PPP/R1B2RK1 w - - 2 17
What legal moves does the piece on f2 have?


Prompt:
FEN: r1b1k1nr/ppp2ppp/n7/1Nb5/3N4/3B4/PPP2PPP/R1B1K2R w KQkq - 3 10
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: rnbq1rk1/pp2b1pp/2pp1n2/5pB1/2P1p3/2NPPN2/PP2BPPP/R2Q1RK1 w - - 0 9
List all capture moves available.


Prompt:
Given FEN: 5rk1/R5p1/1p5p/2pP4/2P5/5bK1/P2R3P/5r2 w - - 0 36
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r1bqk2r/ppp2ppp/2n5/2b1P3/2BNp3/2P1B3/PP3PPP/R2QK2R b KQkq - 2 10
Is the move b7b5 legal?


Prompt:
FEN: r4k1r/p2b1ppp/2pN1n2/2p2P2/4P3/6P1/PPP3BP/R1B2RK1 w - - 1 17
List pseudo-legal moves from a1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: 5rk1/4bp2/6q1/3PP1p1/1p1P4/pP3P2/P3Q3/2K4R b - - 2 40
For the piece on g8, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from g8: g8g7 g8h7 g8h8.
Legal: g8g7.
Rejected: g8h7 king_would_be_in_check; g8h8 king_would_be_in_check.


Prompt:
FEN: r2kr3/p1pp2pp/2b2p2/8/1p1P4/2N5/PPP2PPP/R1BQ2K1 w - -
For move a1b1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a1b1.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 8/1pk4p/2ppP2N/p7/4P1P1/8/PB3r1K/8 w - - 1 34
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: a2 white pawn; b2 white bishop; h2 white king; e4 white pawn; g4 white pawn; e6 white pawn; h6 white knight.
Moves by piece:
a2 white pawn: no legal moves
b2 white bishop: no legal moves
h2 white king: h2g1 h2g3 h2h1 h2h3
e4 white pawn: no legal moves
g4 white pawn: no legal moves
e6 white pawn: no legal moves
h6 white knight: no legal moves
All legal moves: h2g1 h2g3 h2h1 h2h3


Prompt:
FEN: 6r1/8/3RR1pk/pbp2p2/8/1P5N/P1P2PPP/2K5 w - - 3 33
Walk each ray for the slider on d6: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: d6 white rook.
Ray N: d7 empty; d8 empty; edge.
Ray E: e6 white rook: own piece (stop, excluded).
Ray S: d5 empty; d4 empty; d3 empty; d2 empty; d1 empty; edge.
Ray W: c6 empty; b6 empty; a6 empty; edge.
Moves from rays: d6a6 d6b6 d6c6 d6d1 d6d2 d6d3 d6d4 d6d5 d6d7 d6d8


Prompt:
FEN: 6k1/5pp1/4p3/pr1r3p/n7/P1P3RP/5PP1/4R1K1 w - -
For every side-to-move piece, list pseudo-legal moves, reject illegal ones with reasons, then give all legal moves.

Answer format: include "Side to move:", "Pieces:", "Filter by piece:", one line per side-to-move piece with "pseudo-legal ... | rejected ... | legal ..." fields, and "All legal moves:".

Side to move: white.
Pieces: e1 white rook; g1 white king; f2 white pawn; g2 white pawn; a3 white pawn; c3 white pawn; g3 white rook; h3 white pawn.
Filter by piece:
e1 white rook: pseudo-legal e1a1 e1b1 e1c1 e1d1 e1e2 e1e3 e1e4 e1e5 e1e6 e1f1 | rejected none | legal e1a1 e1b1 e1c1 e1d1 e1e2 e1e3 e1e4 e1e5 e1e6 e1f1
g1 white king: pseudo-legal g1f1 g1h1 g1h2 | rejected none | legal g1f1 g1h1 g1h2
f2 white pawn: pseudo-legal f2f3 f2f4 | rejected none | legal f2f3 f2f4
g2 white pawn: pseudo-legal none | rejected none | legal none
a3 white pawn: pseudo-legal none | rejected none | legal none
c3 white pawn: pseudo-legal c3c4 | rejected none | legal c3c4
g3 white rook: pseudo-legal g3d3 g3e3 g3f3 g3g4 g3g5 g3g6 g3g7 | rejected none | legal g3d3 g3e3 g3f3 g3g4 g3g5 g3g6 g3g7
h3 white pawn: pseudo-legal h3h4 | rejected none | legal h3h4
All legal moves: c3c4 e1a1 e1b1 e1c1 e1d1 e1e2 e1e3 e1e4 e1e5 e1e6 e1f1 f2f3 f2f4 g1f1 g1h1 g1h2 g3d3 g3e3 g3f3 g3g4 g3g5 g3g6 g3g7 h3h4


Prompt:
FEN: r1b1kbnr/1pp2ppp/p1npp2q/8/1P6/P2BPN2/1BPP1PPP/RN1QK2R w KQkq - 0 7
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1a2 a3a4 b1c3 b2c1 b2c3 b2d4 b2e5 b2f6 b2g7 b4b5 c2c3 c2c4 d1c1 d1e2 d3a6 d3b5 d3c4 d3e2 d3e4 d3f1 d3f5 d3g6 d3h7 e1e2 e1f1 e1g1 e3e4 f3d4 f3e5 f3g1 f3g5 f3h4 g2g3 g2g4 h1f1 h1g1 h2h3 h2h4


Prompt:
FEN: r2q1k2/pb3ppp/1p1p4/2pP4/2P3n1/5NP1/PPQ2PBP/4R1K1 b - -
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: g4 black knight; c5 black pawn; b6 black pawn; d6 black pawn; a7 black pawn; b7 black bishop; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; d8 black queen; f8 black king.


Prompt:
FEN: 1k6/4N3/2Q5/4K3/8/8/8/8 w - -
What legal moves does the piece on e5 have?


Prompt:
FEN: rn1qkbnr/pp2pppp/8/2pp4/3P2b1/2P2N2/PP2PPPP/RNBQKB1R w KQkq -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 1r1q1rk1/p4pp1/B2pb2p/2b2n2/3P4/P4N1P/1P3PP1/R1BQ1RK1 b - - 0 16
List all capture moves available.


Prompt:
Given FEN: r1bqk1nr/pp1pppbp/6p1/4N3/4Q3/8/PPP2PPP/RNB1KB1R b KQkq -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: rn1k1b1r/pp3ppp/2p2n2/4p3/2b5/2N1B1P1/PP2PPBP/R3K1NR w KQ -
Is the move b3h3 legal?


Prompt:
FEN: 8/p2rkb1p/1p2pB2/5p2/5PpP/P2qP1P1/1Q4BK/8 b - -
List pseudo-legal moves from d3.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d3: d3a3 d3a6 d3b1 d3b3 d3b5 d3c2 d3c3 d3c4 d3d1 d3d2 d3d4 d3d5 d3d6 d3e2 d3e3 d3e4 d3f1


Prompt:
FEN: r1b1kbnr/2ppq1pp/p7/1p2N2Q/4P3/1P6/1PP2PPP/RNB1K2R b KQkq - 2 10
For the piece on b5, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from b5: b5b4.
Legal: none.
Rejected: b5b4 does_not_resolve_check.


Prompt:
FEN: 8/p3k3/3b1p1p/2p3p1/P1R5/2P5/r5PP/5K2 w - - 1 33
For move f1e2, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: f1e2.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: r5k1/pbppq1p1/np3n1p/2b1p3/1PN1P3/2PP1Q2/P4PPP/R1B2RK1 b - - 0 13
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: c5 black bishop; e5 black pawn; a6 black knight; b6 black pawn; f6 black knight; h6 black pawn; a7 black pawn; b7 black bishop; c7 black pawn; d7 black pawn; e7 black queen; g7 black pawn; a8 black rook; g8 black king.
Moves by piece:
c5 black bishop: c5b4 c5d4 c5d6 c5e3 c5f2
e5 black pawn: no legal moves
a6 black knight: a6b4 a6b8
b6 black pawn: b6b5
f6 black knight: f6d5 f6e4 f6e8 f6g4 f6h5 f6h7
h6 black pawn: h6h5
a7 black pawn: no legal moves
b7 black bishop: b7c6 b7c8 b7d5 b7e4
c7 black pawn: c7c6
d7 black pawn: d7d5 d7d6
e7 black queen: e7d6 e7d8 e7e6 e7e8 e7f7 e7f8
g7 black pawn: g7g5 g7g6
a8 black rook: a8b8 a8c8 a8d8 a8e8 a8f8
g8 black king: g8f7 g8f8 g8h7 g8h8
All legal moves: a6b4 a6b8 a8b8 a8c8 a8d8 a8e8 a8f8 b6b5 b7c6 b7c8 b7d5 b7e4 c5b4 c5d4 c5d6 c5e3 c5f2 c7c6 d7d5 d7d6 e7d6 e7d8 e7e6 e7e8 e7f7 e7f8 f6d5 f6e4 f6e8 f6g4 f6h5 f6h7 g7g5 g7g6 g8f7 g8f8 g8h7 g8h8 h6h5


Prompt:
FEN: rnbq1rk1/1pp2pbp/p2ppnp1/8/P1BPP3/2N2N2/1PP2PPP/R1BQ1RK1 w - -
Walk each ray for the slider on a1: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: a1 white rook.
Ray N: a2 empty; a3 empty; a4 white pawn: own piece (stop, excluded).
Ray E: b1 empty; c1 white bishop: own piece (stop, excluded).
Ray S: edge.
Ray W: edge.
Moves from rays: a1a2 a1a3 a1b1


Prompt:
FEN: rnbqk1nr/pp5p/2p1p2b/3p1p2/3P2p1/2NBPNBP/PPP2PP1/R2QK2R w KQkq - 0 9
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1b1 a1c1 a2a3 a2a4 b2b3 b2b4 c3a4 c3b1 c3b5 c3d5 c3e2 c3e4 d1b1 d1c1 d1d2 d1e2 d3a6 d3b5 d3c4 d3e2 d3e4 d3f1 d3f5 e1d2 e1e2 e1f1 e1g1 e3e4 f3d2 f3e5 f3g1 f3g5 f3h2 f3h4 g3b8 g3c7 g3d6 g3e5 g3f4 g3h2 g3h4 h1f1 h1g1 h1h2 h3g4 h3h4


Prompt:
FEN: r2qkb1r/pppbnppp/1n1pp3/8/3PP3/1BN2N2/PPP2PPP/R1BQK2R w KQkq -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1b1 a2a3 a2a4 b3a4 b3c4 b3d5 b3e6 c1d2 c1e3 c1f4 c1g5 c1h6 c3a4 c3b1 c3b5 c3d5 c3e2 d1d2 d1d3 d1e2 d4d5 e1d2 e1e2 e1f1 e1g1 e4e5 f3d2 f3e5 f3g1 f3g5 f3h4 g2g3 g2g4 h1f1 h1g1 h2h3 h2h4


Prompt:
FEN: r3k2r/pp1bbppp/1qn1p3/3pPn2/3P4/5N2/PPN1BPPP/R1BQ1RK1 w kq - 7 11
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a1 white rook; c1 white bishop; d1 white queen; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; c2 white knight; e2 white bishop; f2 white pawn; g2 white pawn; h2 white pawn; f3 white knight; d4 white pawn; e5 white pawn.


Prompt:
FEN: 3b4/3k4/2pp4/pp5p/6rP/P5P1/3R1P1K/4R3 w - - 0 36
What legal moves does the piece on a3 have?


Prompt:
FEN: 6k1/5p2/1p5p/2b2R2/p1rpp1Q1/P1P4R/1P3P1P/6K1 b - - 0 42
Detect the game state: check, checkmate, stalemate, or none.


Prompt:
FEN: rn1q1r2/pppbbkpp/3p1n2/5P2/3PP3/2N5/PPP3PP/R1BQKB1R w KQ -
List all capture moves available.


Prompt:
Given FEN: 6k1/1b3pp1/7p/1p6/5qQ1/2PKr1NP/1P6/R7 w - -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r1b1k2r/pp1n1ppp/2p5/q2pP1B1/1bP1n3/2N1P3/PP1N1PPP/2RQKB1R w Kkq -
Is the move g2g3 legal?


Prompt:
FEN: rn1qk2r/pbppbppp/1p2pn2/8/3P1P2/4PN2/PPP1B1PP/RNBQ1RK1 b kq -
List pseudo-legal moves from b6.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: r1b1qrk1/pp1n2b1/2pp3p/3PppNn/2P4B/2N1P3/PPB2PPP/2RQ1RK1 w - -
For the piece on c1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from c1: c1a1 c1b1.
Legal: c1a1 c1b1.
Rejected: none.


Prompt:
FEN: 2kr2n1/1pp2p1p/p1q3r1/3pP3/P2P4/R2b3P/2PQ1PP1/1N2K1NR w K - 0 19
For move e1e2, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: e1e2.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: 8/8/5k2/8/5K2/5PP1/8/8 b - - 3 55
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: f6 black king.
Moves by piece:
f6 black king: f6e6 f6e7 f6f7 f6g6 f6g7
All legal moves: f6e6 f6e7 f6f7 f6g6 f6g7


Prompt:
FEN: 2rq1rk1/pb2bppp/1p2pn2/2n5/8/P3PNB1/1P1NBPPP/2RQ1RK1 w - - 1 14
Walk each ray for the slider on c1: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: c1 white rook.
Ray N: c2 empty; c3 empty; c4 empty; c5 black knight: capture (stop, included).
Ray E: d1 white queen: own piece (stop, excluded).
Ray S: edge.
Ray W: b1 empty; a1 empty; edge.
Moves from rays: c1a1 c1b1 c1c2 c1c3 c1c4 c1c5


Prompt:
FEN: r1bq1rk1/ppp1p2p/6p1/3pbp2/3nB2P/1PP5/P4PP1/RNBQK1NR b KQ - 0 11
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 a8b8 b7b5 b7b6 c7c5 c7c6 c8d7 c8e6 d4b3 d4b5 d4c2 d4c6 d4e2 d4e6 d4f3 d5e4 d8d6 d8d7 d8e8 e5d6 e5f4 e5f6 e5g3 e5g7 e5h2 e5h8 e7e6 f5e4 f5f4 f8e8 f8f6 f8f7 g6g5 g8f7 g8g7 g8h8 h7h5 h7h6


Prompt:
FEN: 3r2k1/pp3ppp/8/2p5/6P1/2P2PNb/PP2rq1P/6RK w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a2a3 a2a4 b2b3 b2b4 c3c4 f3f4 g1a1 g1b1 g1c1 g1d1 g1e1 g1f1 g1g2 g3e2 g3e4 g3f1 g3f5 g3h5 g4g5


Prompt:
FEN: 8/8/8/3K4/R7/4kp2/8/8 w - -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a4 white rook; d5 white king.


Prompt:
FEN: rnb1kbnr/pppp1ppp/4p3/8/2PPq3/2N2N2/PP2PPPP/R1BQKB1R b KQkq - 4 4
What legal moves does the piece on c7 have?


Prompt:
FEN: 5rk1/Qp1n2pp/2pb4/1P1p4/8/P1NP1q2/2P3R1/4R2K b - - 3 27
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 2kr3r/5p1p/p1n5/4P3/1pp1p1P1/1P2P3/P5P1/R2K1B1R w - -
List all capture moves available.


Prompt:
Given FEN: r1bqkb1r/2p2ppp/p1np1n2/1p1Pp3/4P3/1B3N2/PPP2PPP/RNBQK2R b KQkq -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: rn1qkb1r/pbpppp1p/1p4pB/8/3PP3/6P1/PPP2PBP/RN1QK1NR b KQkq - 0 5
Is the move b8c6 legal?


Prompt:
FEN: 4k3/2p5/3p1p2/4pP2/2P3P1/PQ1P2P1/4K3/6n1 w - - 5 46
List pseudo-legal moves from e2.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from e2: e2d1 e2d2 e2e1 e2e3 e2f1 e2f2 e2f3


Prompt:
FEN: 7k/5R1p/1N4p1/1Kp5/2Pb4/8/1r6/8 w - - 1 46
For the piece on b5, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from b5: b5a4 b5a5 b5a6 b5b4 b5c5 b5c6.
Legal: b5a4 b5a5 b5a6 b5c6.
Rejected: b5b4 does_not_resolve_check; b5c5 does_not_resolve_check.


Prompt:
FEN: 8/8/3k4/Q4B2/5K2/8/8/8 w - -
For move f4e5, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: f4e5.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: r3r1k1/pp3pp1/1q4b1/3R1p1p/1P5P/P1N1pPPB/2P1Qn2/5RK1 w - - 1 21
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: f1 white rook; g1 white king; c2 white pawn; e2 white queen; a3 white pawn; c3 white knight; f3 white pawn; g3 white pawn; h3 white bishop; b4 white pawn; h4 white pawn; d5 white rook.
Moves by piece:
f1 white rook: f1a1 f1b1 f1c1 f1d1 f1e1 f1f2
g1 white king: g1g2 g1h2
c2 white pawn: no legal moves
e2 white queen: e2a6 e2b5 e2c4 e2d1 e2d2 e2d3 e2e1 e2e3 e2f2
a3 white pawn: a3a4
c3 white knight: c3a2 c3a4 c3b1 c3b5 c3d1 c3e4
f3 white pawn: f3f4
g3 white pawn: g3g4
h3 white bishop: h3f5 h3g2 h3g4
b4 white pawn: b4b5
h4 white pawn: no legal moves
d5 white rook: d5a5 d5b5 d5c5 d5d1 d5d2 d5d3 d5d4 d5d6 d5d7 d5d8 d5e5 d5f5
All legal moves: a3a4 b4b5 c3a2 c3a4 c3b1 c3b5 c3d1 c3e4 d5a5 d5b5 d5c5 d5d1 d5d2 d5d3 d5d4 d5d6 d5d7 d5d8 d5e5 d5f5 e2a6 e2b5 e2c4 e2d1 e2d2 e2d3 e2e1 e2e3 e2f2 f1a1 f1b1 f1c1 f1d1 f1e1 f1f2 f3f4 g1g2 g1h2 g3g4 h3f5 h3g2 h3g4


Prompt:
FEN: 8/5k2/6p1/5P2/6P1/r7/6K1/4R3 b - -
Walk each ray for the slider on a3: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: a3 black rook.
Ray N: a4 empty; a5 empty; a6 empty; a7 empty; a8 empty; edge.
Ray E: b3 empty; c3 empty; d3 empty; e3 empty; f3 empty; g3 empty; h3 empty; edge.
Ray S: a2 empty; a1 empty; edge.
Ray W: edge.
Moves from rays: a3a1 a3a2 a3a4 a3a5 a3a6 a3a7 a3a8 a3b3 a3c3 a3d3 a3e3 a3f3 a3g3 a3h3


Prompt:
FEN: 6n1/3B1kbr/1p1Bp3/3p4/3P2np/1Pr5/P1P2PPP/R3R1K1 w - - 0 28
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1b1 a1c1 a1d1 a2a3 a2a4 b3b4 d6a3 d6b4 d6b8 d6c5 d6c7 d6e5 d6e7 d6f4 d6f8 d6g3 d7a4 d7b5 d7c6 d7c8 d7e6 d7e8 e1b1 e1c1 e1d1 e1e2 e1e3 e1e4 e1e5 e1e6 e1f1 f2f3 f2f4 g1f1 g1h1 g2g3 h2h3


Prompt:
FEN: r2q1rk1/3nbppp/pp2pn2/1Np5/P7/1P3N2/1BPP1PPP/R2QR1K1 w - - 0 13
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1a2 a1a3 a1b1 a1c1 a4a5 b2a3 b2c1 b2c3 b2d4 b2e5 b2f6 b3b4 b5a3 b5a7 b5c3 b5c7 b5d4 b5d6 c2c3 c2c4 d1b1 d1c1 d1e2 d2d3 d2d4 e1e2 e1e3 e1e4 e1e5 e1e6 e1f1 f3d4 f3e5 f3g5 f3h4 g1f1 g1h1 g2g3 g2g4 h2h3 h2h4


Prompt:
FEN: r1bqk1nr/ppp2ppp/1N1p4/8/1PB1P3/8/P1Q2PPP/R1B2RK1 b kq - 0 11
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: d6 black pawn; a7 black pawn; b7 black pawn; c7 black pawn; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; c8 black bishop; d8 black queen; e8 black king; g8 black knight; h8 black rook.


Prompt:
FEN: r1bqr1k1/1p3pbp/n1pp1np1/4p3/1PP5/2NP1NP1/3BPPBP/1RQ2RK1 w - -
What legal moves does the piece on c3 have?


Prompt:
FEN: rn1qk2r/ppp2ppp/4pn2/3p4/1b1P2b1/5NP1/PPP1PPBP/RNBQ1RK1 w kq -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: rnbqk2r/pppp1ppp/3Bp3/8/3Pn3/5P2/PPP1P1PP/RN1QKBNR b KQkq -
List all capture moves available.


Prompt:
Given FEN: r1bq1rk1/pp1p1ppp/5n2/2p1p3/1nP1P3/1QNP1N2/1P3PPP/R1B1KB1R b KQ - 0 8
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r2qkb1r/4pppp/4b3/nB1n4/Q2P4/5N2/PP3PPP/R1B1K2R b KQkq -
Is the move d1h2 legal?


Prompt:
FEN: 8/pp6/3pk3/1P2p3/1nP3p1/6K1/8/8 b - - 3 43
List pseudo-legal moves from b4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from b4: b4a2 b4a6 b4c2 b4c6 b4d3 b4d5


Prompt:
FEN: 8/8/5p2/3k4/6P1/6P1/6K1/8 w - -
For the piece on g2, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from g2: g2f1 g2f2 g2f3 g2g1 g2h1 g2h2 g2h3.
Legal: g2f1 g2f2 g2f3 g2g1 g2h1 g2h2 g2h3.
Rejected: none.


Prompt:
FEN: r1bqkbnr/pp2pppp/2p5/n2P4/Q1p5/2N5/PP2PPPP/R1B1KBNR w KQkq -
For move a1b1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a1b1.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 2k2b1r/1b1r1qpp/1Bnp4/1B2p3/1P2n3/2P2PP1/R6P/1N1QK1NR w K - 0 19
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: b1 white knight; d1 white queen; e1 white king; g1 white knight; h1 white rook; a2 white rook; h2 white pawn; c3 white pawn; f3 white pawn; g3 white pawn; b4 white pawn; b5 white bishop; b6 white bishop.
Moves by piece:
b1 white knight: b1a3 b1d2
d1 white queen: d1a4 d1b3 d1c1 d1c2 d1d2 d1d3 d1d4 d1d5 d1d6 d1e2
e1 white king: e1e2 e1f1
g1 white knight: g1e2 g1h3
h1 white rook: no legal moves
a2 white rook: a2a1 a2a3 a2a4 a2a5 a2a6 a2a7 a2a8 a2b2 a2c2 a2d2 a2e2 a2f2 a2g2
h2 white pawn: h2h3 h2h4
c3 white pawn: c3c4
f3 white pawn: f3e4 f3f4
g3 white pawn: g3g4
b4 white pawn: no legal moves
b5 white bishop: b5a4 b5a6 b5c4 b5c6 b5d3 b5e2 b5f1
b6 white bishop: b6a5 b6a7 b6c5 b6c7 b6d4 b6d8 b6e3 b6f2
All legal moves: a2a1 a2a3 a2a4 a2a5 a2a6 a2a7 a2a8 a2b2 a2c2 a2d2 a2e2 a2f2 a2g2 b1a3 b1d2 b5a4 b5a6 b5c4 b5c6 b5d3 b5e2 b5f1 b6a5 b6a7 b6c5 b6c7 b6d4 b6d8 b6e3 b6f2 c3c4 d1a4 d1b3 d1c1 d1c2 d1d2 d1d3 d1d4 d1d5 d1d6 d1e2 e1e2 e1f1 f3e4 f3f4 g1e2 g1h3 g3g4 h2h3 h2h4


Prompt:
FEN: 1r6/4q1bk/3p2pp/p1pBp3/1pP1P3/3P1N2/PP1N1PPR/2K4R b - - 1 27
Walk each ray for the slider on e7: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: e7 black queen.
Ray N: e8 empty; edge.
Ray NE: f8 empty; edge.
Ray E: f7 empty; g7 black bishop: own piece (stop, excluded).
Ray SE: f6 empty; g5 empty; h4 empty; edge.
Ray S: e6 empty; e5 black pawn: own piece (stop, excluded).
Ray SW: d6 black pawn: own piece (stop, excluded).
Ray W: d7 empty; c7 empty; b7 empty; a7 empty; edge.
Ray NW: d8 empty; edge.
Moves from rays: e7a7 e7b7 e7c7 e7d7 e7d8 e7e6 e7e8 e7f6 e7f7 e7f8 e7g5 e7h4


Prompt:
FEN: r2qkb1r/pp1npp1p/2p2np1/3p1b2/3P4/BP3NP1/P1P1PPBP/RN1QK2R w KQkq - 0 7
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a3b2 a3b4 a3c1 a3c5 a3d6 a3e7 b1c3 b1d2 b3b4 c2c3 c2c4 d1c1 d1d2 d1d3 e1d2 e1f1 e1g1 e2e3 e2e4 f3d2 f3e5 f3g1 f3g5 f3h4 g2f1 g2h3 g3g4 h1f1 h1g1 h2h3 h2h4


Prompt:
FEN: 8/8/5kpp/3p1p2/Pb3PP1/4K2P/PpB5/8 b - - 6 48
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: b2b1b b2b1n b2b1q b2b1r b4a3 b4a5 b4c3 b4c5 b4d2 b4d6 b4e1 b4e7 b4f8 d5d4 f5g4 f6e6 f6e7 f6f7 f6g7 g6g5 h6h5


Prompt:
FEN: 8/1b6/5k2/5p2/BP3P1K/P7/8/8 b - -
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: f5 black pawn; f6 black king; b7 black bishop.


Prompt:
FEN: rnbqkb1r/ppp2ppp/1n1pp3/4P3/8/1B3N2/PPPP1PPP/RNBQK2R w KQkq - 0 6
What legal moves does the piece on b2 have?


Prompt:
FEN: rn3rk1/pQ4bp/2p1P3/4p3/4q3/3B3P/PPK2pP1/3R3R b - - 3 20
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r3kb1r/pbq2ppp/1pn1p3/2ppPn2/5P2/2PP2P1/PP1NN1BP/R1BQ1RK1 b kq - 4 10
List all capture moves available.


Prompt:
Given FEN: r1bqk2r/p4ppp/2pb4/n3p3/8/3P1N2/PP1P1PPP/RNBQR1K1 b kq -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 8/8/6p1/1R4k1/nP4N1/7P/6P1/6K1 b - - 0 51
Is the move a4c5 legal?


Prompt:
FEN: 1K6/P2q4/8/8/4k3/8/8/8 b - - 6 61
List pseudo-legal moves from e4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from e4: e4d3 e4d4 e4d5 e4e3 e4e5 e4f3 e4f4 e4f5


Prompt:
FEN: 8/5p2/7p/2n5/3K4/1k2N2P/1rp2PP1/2R5 b - - 2 41
For the piece on b3, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from b3: b3a2 b3a3 b3a4 b3b4 b3c3 b3c4.
Legal: b3a2 b3a3 b3a4 b3b4.
Rejected: b3c3 king_would_be_in_check; b3c4 king_would_be_in_check.


Prompt:
FEN: 3r2k1/3b1p2/2p1p1p1/p1p1P2p/P1Pp1P2/1r1P4/1P2K1PP/1RB3R1 w - -
For move e2e3, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: e2e3.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: 8/p6p/k4pp1/8/2r2B2/2P5/PP3PPP/3R1RK1 w - - 1 25
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: d1 white rook; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; f2 white pawn; g2 white pawn; h2 white pawn; c3 white pawn; f4 white bishop.
Moves by piece:
d1 white rook: d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1d7 d1d8 d1e1
f1 white rook: f1e1
g1 white king: g1h1
a2 white pawn: a2a3 a2a4
b2 white pawn: b2b3 b2b4
f2 white pawn: f2f3
g2 white pawn: g2g3 g2g4
h2 white pawn: h2h3 h2h4
c3 white pawn: no legal moves
f4 white bishop: f4b8 f4c1 f4c7 f4d2 f4d6 f4e3 f4e5 f4g3 f4g5 f4h6
All legal moves: a2a3 a2a4 b2b3 b2b4 d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1d7 d1d8 d1e1 f1e1 f2f3 f4b8 f4c1 f4c7 f4d2 f4d6 f4e3 f4e5 f4g3 f4g5 f4h6 g1h1 g2g3 g2g4 h2h3 h2h4


Prompt:
FEN: 6k1/1p1r1ppp/p4nq1/P2p4/3NpB2/2P4r/1P1R2P1/R4NK1 b - - 1 26
Walk each ray for the slider on h3: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: h3 black rook.
Ray N: h4 empty; h5 empty; h6 empty; h7 black pawn: own piece (stop, excluded).
Ray E: edge.
Ray S: h2 empty; h1 empty; edge.
Ray W: g3 empty; f3 empty; e3 empty; d3 empty; c3 white pawn: capture (stop, included).
Moves from rays: h3c3 h3d3 h3e3 h3f3 h3g3 h3h1 h3h2 h3h4 h3h5 h3h6


Prompt:
FEN: r2qk2r/pp3ppp/2nbbn2/2ppp3/8/1P2P1P1/PBPPNPBP/RN1Q1RK1 w kq -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a2a3 a2a4 b1a3 b1c3 b2a3 b2c1 b2c3 b2d4 b2e5 b3b4 c2c3 c2c4 d1c1 d1e1 d2d3 d2d4 e2c1 e2c3 e2d4 e2f4 e3e4 f1e1 f2f3 f2f4 g1h1 g2d5 g2e4 g2f3 g2h1 g2h3 g3g4 h2h3 h2h4


Prompt:
FEN: 2q3k1/p2n1pp1/bpr1p2p/3p4/3P1B2/PPb1P1NP/1Q3PP1/1B1R2K1 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a3a4 b1a2 b1c2 b1d3 b1e4 b1f5 b1g6 b1h7 b2a1 b2a2 b2c1 b2c2 b2c3 b2d2 b2e2 b3b4 d1c1 d1d2 d1d3 d1e1 d1f1 e3e4 f2f3 f4b8 f4c7 f4d6 f4e5 f4g5 f4h6 g1h1 g1h2 g3e2 g3e4 g3f1 g3f5 g3h1 g3h5 h3h4


Prompt:
FEN: r3k2r/1bq1bppp/p1nppn2/1p6/4P2P/PNN1B1Q1/1PP1BPP1/R4RK1 b kq -
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: b5 black pawn; a6 black pawn; c6 black knight; d6 black pawn; e6 black pawn; f6 black knight; b7 black bishop; c7 black queen; e7 black bishop; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; e8 black king; h8 black rook.


Prompt:
FEN: r1b1kb1r/1pp1pppp/p1n5/2Pp4/1P1P2n1/4P3/P2BBPPP/RN2K1NR b KQkq - 1 8
What legal moves does the piece on f7 have?


Prompt:
FEN: 8/2k5/p7/2p1K3/1pP5/1P6/P7/8 w - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r1bqk2r/1p3ppp/p1n1pn2/3pB3/3P4/2N1P3/PP2BPPP/R2QK2R b KQkq -
List all capture moves available.


Prompt:
Given FEN: r5k1/q4pp1/3b1n2/p1p4p/P2p1P2/1P1P1QP1/3B3P/R4RK1 b - - 0 26
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: rnbqk2r/ppppb2p/4pnpP/5pB1/3P4/2N5/PPP1PPP1/R2QKBNR b KQkq -
Is the move f6g4 legal?


Prompt:
FEN: r2qr1k1/p4pp1/2p1bn1p/3p4/1b3B2/P1NB1Q1P/1PP2PP1/3R1RK1 b - -
List pseudo-legal moves from b4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from b4: b4a3 b4a5 b4c3 b4c5 b4d6 b4e7 b4f8


Prompt:
FEN: 8/1k5p/1p4p1/1N6/2P5/1P3RB1/P1r3rP/R4K2 b - - 2 31
For the piece on b7, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from b7: b7a6 b7a7 b7a8 b7b8 b7c6 b7c7 b7c8.
Legal: b7a6 b7a8 b7c6 b7c8.
Rejected: b7a7 king_would_be_in_check; b7b8 king_would_be_in_check; b7c7 king_would_be_in_check.


Prompt:
FEN: r1bqk1nr/1p2bppp/p1n5/2pB4/8/2N5/PPPPQPPP/R1B1K1NR w KQkq - 3 8
For move a1b1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a1b1.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 8/3B1k2/8/8/3Q4/4K3/8/8 w - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: e3 white king; d4 white queen; d7 white bishop.
Moves by piece:
e3 white king: e3d2 e3d3 e3e2 e3e4 e3f2 e3f3 e3f4
d4 white queen: d4a1 d4a4 d4a7 d4b2 d4b4 d4b6 d4c3 d4c4 d4c5 d4d1 d4d2 d4d3 d4d5 d4d6 d4e4 d4e5 d4f4 d4f6 d4g4 d4g7 d4h4 d4h8
d7 white bishop: d7a4 d7b5 d7c6 d7c8 d7e6 d7e8 d7f5 d7g4 d7h3
All legal moves: d4a1 d4a4 d4a7 d4b2 d4b4 d4b6 d4c3 d4c4 d4c5 d4d1 d4d2 d4d3 d4d5 d4d6 d4e4 d4e5 d4f4 d4f6 d4g4 d4g7 d4h4 d4h8 d7a4 d7b5 d7c6 d7c8 d7e6 d7e8 d7f5 d7g4 d7h3 e3d2 e3d3 e3e2 e3e4 e3f2 e3f3 e3f4


Prompt:
FEN: 8/5k2/3K4/4Q3/8/3B4/8/8 b - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: f7f8 f7g8


Prompt:
FEN: r4rk1/ppqn1ppp/2pb4/3p2B1/3P1PP1/3Q2NP/P1P3K1/R4R2 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1b1 a1c1 a1d1 a1e1 a2a3 a2a4 c2c3 c2c4 d3a3 d3a6 d3b3 d3b5 d3c3 d3c4 d3d1 d3d2 d3e2 d3e3 d3e4 d3f3 d3f5 d3g6 d3h7 f1b1 f1c1 f1d1 f1e1 f1f2 f1f3 f1g1 f1h1 f4f5 g2f2 g2f3 g2g1 g2h1 g2h2 g3e2 g3e4 g3f5 g3h1 g3h5 g5d8 g5e7 g5f6 g5h4 g5h6 h3h4


Prompt:
FEN: 5r2/1p4pk/pb5p/P3P3/1P1p4/1b1K4/3B3P/4R3 b - - 0 35
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: b3a2 b3a4 b3c2 b3c4 b3d1 b3d5 b3e6 b3f7 b3g8 b6a5 b6a7 b6c5 b6c7 b6d8 f8a8 f8b8 f8c8 f8d8 f8e8 f8f1 f8f2 f8f3 f8f4 f8f5 f8f6 f8f7 f8g8 f8h8 g7g5 g7g6 h6h5 h7g6 h7g8 h7h8


Prompt:
FEN: r1bqk2r/ppp2pp1/2np1n1p/2b1p1B1/2B1P3/3P1N2/PPP2PPP/RN1Q1RK1 w kq - 0 7
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a1 white rook; b1 white knight; d1 white queen; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; c2 white pawn; f2 white pawn; g2 white pawn; h2 white pawn; d3 white pawn; f3 white knight; c4 white bishop; e4 white pawn; g5 white bishop.


Prompt:
FEN: 2r3k1/R5pp/5p2/1p1p1p2/1K2r3/8/2P3PP/8 w - - 4 33
What legal moves does the piece on c2 have?


Prompt:
FEN: rnb1kb1r/ppppqpp1/5n1p/4p3/2B1P3/1P3N2/P1PP1PPP/RNBQK2R w KQkq - 1 5
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 8/8/3n4/3k1pKp/7P/5NP1/8/8 b - - 7 47
List all capture moves available.


Prompt:
Given FEN: r1b1k2r/p4ppp/1qp2n2/8/1PpPpP2/2P3P1/5PBP/R1BQK2R b KQkq - 0 14
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 2kr1b1r/1bppq2p/p1n2pn1/1p2p1pQ/4P3/PBNP1NB1/1PP2PPP/R4RK1 b - - 0 12
Is the move b5b6 legal?

No, illegal. Reason: illegal piece movement or blocked path.


Prompt:
FEN: 8/8/r1k3p1/P4p1p/2K2P1P/6P1/R7/8 w - -
List pseudo-legal moves from a2.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from a2: a2a1 a2a3 a2a4 a2b2 a2c2 a2d2 a2e2 a2f2 a2g2 a2h2


Prompt:
FEN: r5k1/5p2/p6p/1p4p1/2p5/2P3P1/PP2QP1q/R4K2 b - -
For the piece on h2, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from h2: h2f2 h2g1 h2g2 h2g3 h2h1 h2h3 h2h4 h2h5.
Legal: h2f2 h2g1 h2g2 h2g3 h2h1 h2h3 h2h4 h2h5.
Rejected: none.


Prompt:
FEN: rnb1k2r/2p2ppp/1p2p3/3p1qB1/3P2n1/P1P2N2/4PPBP/R2QK2R b KQkq - 0 11
For move e8d8, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: e8d8.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: 2r5/1p1R1R2/1r5p/p1p1P2P/4kP2/1P6/P7/6K1 b - - 2 36
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: e4 black king; a5 black pawn; c5 black pawn; b6 black rook; h6 black pawn; b7 black pawn; c8 black rook.
Moves by piece:
e4 black king: e4e3 e4f3
a5 black pawn: a5a4
c5 black pawn: c5c4
b6 black rook: b6a6 b6b3 b6b4 b6b5 b6c6 b6d6 b6e6 b6f6 b6g6
h6 black pawn: no legal moves
b7 black pawn: no legal moves
c8 black rook: c8a8 c8b8 c8c6 c8c7 c8d8 c8e8 c8f8 c8g8 c8h8
All legal moves: a5a4 b6a6 b6b3 b6b4 b6b5 b6c6 b6d6 b6e6 b6f6 b6g6 c5c4 c8a8 c8b8 c8c6 c8c7 c8d8 c8e8 c8f8 c8g8 c8h8 e4e3 e4f3


Prompt:
FEN: 7r/3n1pkp/Q2p2p1/3P2q1/2B5/3K1P2/6PP/7R b - - 0 28
Walk each ray for the slider on g5: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: g5 black queen.
Ray N: g6 black pawn: own piece (stop, excluded).
Ray NE: h6 empty; edge.
Ray E: h5 empty; edge.
Ray SE: h4 empty; edge.
Ray S: g4 empty; g3 empty; g2 white pawn: capture (stop, included).
Ray SW: f4 empty; e3 empty; d2 empty; c1 empty; edge.
Ray W: f5 empty; e5 empty; d5 white pawn: capture (stop, included).
Ray NW: f6 empty; e7 empty; d8 empty; edge.
Moves from rays: g5c1 g5d2 g5d5 g5d8 g5e3 g5e5 g5e7 g5f4 g5f5 g5f6 g5g2 g5g3 g5g4 g5h4 g5h5 g5h6


Prompt:
FEN: 7R/8/8/R7/K7/8/3k4/8 w - -
For every side-to-move piece, list pseudo-legal moves, reject illegal ones with reasons, then give all legal moves.

Answer format: include "Side to move:", "Pieces:", "Filter by piece:", one line per side-to-move piece with "pseudo-legal ... | rejected ... | legal ..." fields, and "All legal moves:".

Side to move: white.
Pieces: a4 white king; a5 white rook; h8 white rook.
Filter by piece:
a4 white king: pseudo-legal a4a3 a4b3 a4b4 a4b5 | rejected none | legal a4a3 a4b3 a4b4 a4b5
a5 white rook: pseudo-legal a5a6 a5a7 a5a8 a5b5 a5c5 a5d5 a5e5 a5f5 a5g5 a5h5 | rejected none | legal a5a6 a5a7 a5a8 a5b5 a5c5 a5d5 a5e5 a5f5 a5g5 a5h5
h8 white rook: pseudo-legal h8a8 h8b8 h8c8 h8d8 h8e8 h8f8 h8g8 h8h1 h8h2 h8h3 h8h4 h8h5 h8h6 h8h7 | rejected none | legal h8a8 h8b8 h8c8 h8d8 h8e8 h8f8 h8g8 h8h1 h8h2 h8h3 h8h4 h8h5 h8h6 h8h7
All legal moves: a4a3 a4b3 a4b4 a4b5 a5a6 a5a7 a5a8 a5b5 a5c5 a5d5 a5e5 a5f5 a5g5 a5h5 h8a8 h8b8 h8c8 h8d8 h8e8 h8f8 h8g8 h8h1 h8h2 h8h3 h8h4 h8h5 h8h6 h8h7


Prompt:
FEN: rnbq1rk1/pp2ppbp/3p1np1/2pP2B1/2P1P3/2N2N2/PP3PPP/R2QKB1R b KQ - 0 7
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 b7b5 b7b6 b8a6 b8c6 b8d7 c8d7 c8e6 c8f5 c8g4 c8h3 d8a5 d8b6 d8c7 d8d7 d8e8 e7e5 e7e6 f6d5 f6d7 f6e4 f6e8 f6g4 f6h5 f8e8 g7h6 g7h8 g8h8 h7h5 h7h6


Prompt:
FEN: r1r3k1/2Rnqpbp/1p2p1p1/p2p4/3P1B2/3P1N1P/PP1Q1PP1/2R3K1 b - -
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: a5 black pawn; d5 black pawn; b6 black pawn; e6 black pawn; g6 black pawn; d7 black knight; e7 black queen; f7 black pawn; g7 black bishop; h7 black pawn; a8 black rook; c8 black rook; g8 black king.


Prompt:
FEN: 2b1kb2/2pp1p2/1p3p2/8/2NPB3/1PP1P3/P3N3/R3K3 w Q - 1 23
What legal moves does the piece on c4 have?


Prompt:
FEN: 2k1r3/pppr1p1n/4pq1p/PP1p2p1/3P2B1/4PQ1P/2P2PP1/R3K2R b KQ - 0 19
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r4rk1/p1qn1pp1/2pb1np1/1p1p2B1/3P2P1/2NB1Q1P/PPP2P2/1R3RK1 w - -
List all capture moves available.


Prompt:
Given FEN: r1bqkbnr/ppp3pp/2np4/4pp2/4P3/3P1N2/PPPN1PPP/R1BQKB1R w KQkq -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r2r2k1/p1qbbppp/4pn2/8/Q7/2N1B3/PP2BPPP/R4RK1 w - -
Is the move c3d1 legal?


Prompt:
FEN: r1b4r/p2npkN1/2pq1npB/1p2p2p/3P4/2N4P/PPP2PP1/R1Q1K2R b KQ -
List pseudo-legal moves from b5.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: 1k6/pbnp4/1p1p4/3Pqp2/2B4p/P1NQP2P/1PR2P2/3K2r1 w - - 0 25
For the piece on d1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from d1: d1c1 d1d2 d1e1 d1e2.
Legal: d1d2 d1e2.
Rejected: d1c1 does_not_resolve_check; d1e1 does_not_resolve_check.


Prompt:
FEN: rnbq1rk1/pp1p1p1p/2p2npB/2b1p3/4P3/3P2Q1/PPP1BPPP/RN2K1NR w KQ - 0 7
For move a2a3, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a2a3.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 3k4/4R3/3K4/8/6P1/P7/8/8 b - - 20 62
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: d8 black king.
Moves by piece:
d8 black king: d8c8
All legal moves: d8c8


Prompt:
FEN: 3rr1k1/p1p2pp1/5n2/6Q1/4P2P/BPq3Pb/P4P2/5RK1 w - - 3 27
Walk each ray for the slider on f1: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: f1 white rook.
Ray N: f2 white pawn: own piece (stop, excluded).
Ray E: g1 white king: own piece (stop, excluded).
Ray S: edge.
Ray W: e1 empty; d1 empty; c1 empty; b1 empty; a1 empty; edge.
Moves from rays: f1a1 f1b1 f1c1 f1d1 f1e1


Prompt:
FEN: r1bk3r/ppp2ppp/4p3/4P3/RPPn1P2/8/3K2PP/2B2B1R b - - 0 15
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 a8b8 b7b5 b7b6 c7c5 c7c6 c8d7 d4b3 d4b5 d4c2 d4c6 d4e2 d4f3 d4f5 d8d7 d8e7 d8e8 f7f5 f7f6 g7g5 g7g6 h7h5 h7h6 h8e8 h8f8 h8g8


Prompt:
FEN: 5rk1/pp1b3p/4pp2/1P1p1np1/r4P2/6B1/3RN1PP/5RK1 w - - 0 25
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: b5b6 d2a2 d2b2 d2c2 d2d1 d2d3 d2d4 d2d5 e2c1 e2c3 e2d4 f1a1 f1b1 f1c1 f1d1 f1e1 f1f2 f1f3 f4g5 g1f2 g1h1 g3e1 g3f2 g3h4 h2h3 h2h4


Prompt:
FEN: 1rbq1rk1/ppp2pp1/4p2p/n7/1bpP4/2N1P1P1/PPQN1PBP/R4RK1 w - -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a1 white rook; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; c2 white queen; d2 white knight; f2 white pawn; g2 white bishop; h2 white pawn; c3 white knight; e3 white pawn; g3 white pawn; d4 white pawn.


Prompt:
FEN: rn1qr1k1/pp3pp1/2pb1B1p/3pN3/3P4/8/PPP1QPPP/RN2R1K1 b - - 0 12
What legal moves does the piece on a8 have?


Prompt:
FEN: rnbq1rk1/1pp2pbp/3p1np1/p2Pp3/2P1P3/2N1B1PP/PP2BP2/R2QK1NR w KQ -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r2q1rk1/pp3ppp/2nbpn2/3p1b2/3P3N/2P3P1/PP2QPBP/RNB2RK1 b - - 7 11
List all capture moves available.


Prompt:
Given FEN: 8/5k2/6p1/R5Pp/p6b/8/4K3/8 w - -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: rr4k1/2p1qp1p/2b1pb2/2Pp2p1/pR1P1B2/P1Q1PN2/5PPP/1R4K1 w - - 0 20
Is the move b8f7 legal?


Prompt:
FEN: 3r2k1/p3b1p1/1p2p1rp/1qp1Bp2/3Pp3/P1P1P2P/1P3PPQ/3R1RK1 w - - 12 28
List pseudo-legal moves from d1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d1: d1a1 d1b1 d1c1 d1d2 d1d3 d1e1


Prompt:
FEN: r6k/6R1/7K/7P/8/8/8/8 b - -
For the piece on h8, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from h8: h8g7 h8g8 h8h7.
Legal: none.
Rejected: h8g7 king_would_be_in_check; h8g8 king_would_be_in_check; h8h7 king_would_be_in_check.


Prompt:
FEN: 8/3R3p/6p1/4k3/7P/1P2pP2/P3N1P1/6K1 b - - 3 43
For move e5d4, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: e5d4.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: r1bqkb1r/1p1n1ppp/p3pn2/2p5/2BP4/2N1PN2/PP3PPP/R1BQ1RK1 w kq -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: a1 white rook; c1 white bishop; d1 white queen; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; f2 white pawn; g2 white pawn; h2 white pawn; c3 white knight; e3 white pawn; f3 white knight; c4 white bishop; d4 white pawn.
Moves by piece:
a1 white rook: a1b1
c1 white bishop: c1d2
d1 white queen: d1a4 d1b3 d1c2 d1d2 d1d3 d1e1 d1e2
f1 white rook: f1e1
g1 white king: g1h1
a2 white pawn: a2a3 a2a4
b2 white pawn: b2b3 b2b4
f2 white pawn: no legal moves
g2 white pawn: g2g3 g2g4
h2 white pawn: h2h3 h2h4
c3 white knight: c3a4 c3b1 c3b5 c3d5 c3e2 c3e4
e3 white pawn: e3e4
f3 white knight: f3d2 f3e1 f3e5 f3g5 f3h4
c4 white bishop: c4a6 c4b3 c4b5 c4d3 c4d5 c4e2 c4e6
d4 white pawn: d4c5 d4d5
All legal moves: a1b1 a2a3 a2a4 b2b3 b2b4 c1d2 c3a4 c3b1 c3b5 c3d5 c3e2 c3e4 c4a6 c4b3 c4b5 c4d3 c4d5 c4e2 c4e6 d1a4 d1b3 d1c2 d1d2 d1d3 d1e1 d1e2 d4c5 d4d5 e3e4 f1e1 f3d2 f3e1 f3e5 f3g5 f3h4 g1h1 g2g3 g2g4 h2h3 h2h4


Prompt:
FEN: 8/1K4r1/P7/2k5/8/8/8/8 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: b7a8 b7b8 b7c8


Prompt:
FEN: R3r1k1/8/3p1p2/2pPnQp1/1P2P1P1/2P5/8/R4K1q w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: f1e2 f1f2


Prompt:
FEN: 1r1k1r2/3b1p1R/2np3R/p2Np3/1p2P1p1/3P2P1/PPP2P2/2K5 w - - 12 27
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a2a3 a2a4 b2b3 c1b1 c1d1 c1d2 c2c3 c2c4 d3d4 d5b4 d5b6 d5c3 d5c7 d5e3 d5e7 d5f4 d5f6 f2f3 f2f4 h6d6 h6e6 h6f6 h6g6 h6h1 h6h2 h6h3 h6h4 h6h5 h7f7 h7g7 h7h8


Prompt:
FEN: r4rk1/1p1nbppp/1q1p4/p1p5/2P1PP2/PPN1B2P/2P3P1/1R1QK2R b K - 0 15
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: a5 black pawn; c5 black pawn; b6 black queen; d6 black pawn; b7 black pawn; d7 black knight; e7 black bishop; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; f8 black rook; g8 black king.


Prompt:
FEN: r1bq1rk1/ppp2ppp/2np1n2/8/4PP2/2NBB3/PPP3PP/R2QK1NR b KQ - 5 9
What legal moves does the piece on f8 have?


Prompt:
FEN: 4rk2/p4r2/3R3p/1p3b2/3P2p1/1Q6/PP3b2/2BK4 w - - 0 34
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 4r1k1/1p1Q1pp1/4q2p/8/p7/B1N1N3/1P2KP1P/3R4 b - -
List all capture moves available.


Prompt:
Given FEN: 4k3/8/8/3q4/8/8/2Q5/4K3 w - -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 2k4r/p1p1np1p/Bpn1b1p1/2q3P1/4p3/7P/2PB1P2/3QK2R b K - 3 22
Is the move c8d7 legal?


Prompt:
FEN: 1rr5/1p1qnppk/p1pp1nbp/3Pp3/2PbP2N/3B1QNP/PP3PP1/1RB1R1K1 w - -
List pseudo-legal moves from b1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: 2r3k1/pp1q1ppp/4pb2/3p4/P1r5/2NRQ3/1PP2PPP/R5K1 b - - 5 20
For the piece on c4, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from c4: c4a4 c4b4 c4c3 c4c5 c4c6 c4c7 c4d4 c4e4 c4f4 c4g4 c4h4.
Legal: c4a4 c4b4 c4c3 c4c5 c4c6 c4c7 c4d4 c4e4 c4f4 c4g4 c4h4.
Rejected: none.


Prompt:
FEN: r1b2rk1/pp3ppp/1bn1pn2/8/PPB5/2P2N1P/5PP1/RNB2RK1 b - - 0 14
For move a7a5, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a7a5.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 6rk/p3qp1p/1pb2B2/2p5/2P3R1/1P2P1P1/P4Q1P/R5K1 b - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: c5 black pawn; b6 black pawn; c6 black bishop; a7 black pawn; e7 black queen; f7 black pawn; h7 black pawn; g8 black rook; h8 black king.
Moves by piece:
c5 black pawn: no legal moves
b6 black pawn: no legal moves
c6 black bishop: no legal moves
a7 black pawn: no legal moves
e7 black queen: e7f6
f7 black pawn: no legal moves
h7 black pawn: no legal moves
g8 black rook: g8g7
h8 black king: no legal moves
All legal moves: e7f6 g8g7


Prompt:
FEN: rn2k2r/1bq1n2p/4p1pR/p1pP4/Np6/1B1P1N2/PPPQ1PP1/R3K3 b Qkq - 0 15
Walk each ray for the slider on b7: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: b7 black bishop.
Ray NE: c8 empty; edge.
Ray SE: c6 empty; d5 white pawn: capture (stop, included).
Ray SW: a6 empty; edge.
Ray NW: a8 black rook: own piece (stop, excluded).
Moves from rays: b7a6 b7c6 b7c8 b7d5


Prompt:
FEN: rnbqk2r/ppp1ppbp/1n1p2p1/4P3/3P1B2/2N2N2/PPPQ1PPP/R3KB1R b KQkq -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 b6a4 b6c4 b6d5 b6d7 b8a6 b8c6 b8d7 c7c5 c7c6 c8d7 c8e6 c8f5 c8g4 c8h3 d6d5 d6e5 d8d7 e7e6 e8d7 e8f8 e8g8 f7f5 f7f6 g6g5 g7e5 g7f6 g7f8 g7h6 h7h5 h7h6 h8f8 h8g8


Prompt:
FEN: r1b1kbnr/ppp3pp/2n1pq2/3p4/3P1P2/2P5/PP4PP/RNBQKBNR b KQkq - 0 6
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 a8b8 b7b5 b7b6 c6a5 c6b4 c6b8 c6d4 c6d8 c6e5 c6e7 c8d7 e6e5 e8d7 e8d8 e8e7 e8f7 f6d4 f6d8 f6e5 f6e7 f6f4 f6f5 f6f7 f6g5 f6g6 f6h4 f6h6 f8a3 f8b4 f8c5 f8d6 f8e7 g7g5 g7g6 g8e7 g8h6 h7h5 h7h6


Prompt:
FEN: 3Q2k1/q5p1/P4p1p/4p3/2P1B3/3P2PP/5PK1/R7 b - - 1 35
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: e5 black pawn; f6 black pawn; h6 black pawn; a7 black queen; g7 black pawn; g8 black king.


Prompt:
FEN: 5rk1/1pq3p1/p1n4p/2b5/P3Qp2/2Pr1N1P/1P4P1/3R1R1K w - - 0 24
What legal moves does the piece on h1 have?


Prompt:
FEN: 1r1q1r1k/5pbp/3p1np1/2pPp3/1pP1Pnb1/1P1B1NN1/1B1Q1PPP/R2R2K1 w - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 8/8/5n2/R1K2k2/4p3/6r1/8/8 b - - 1 49
List all capture moves available.


Prompt:
Given FEN: 2r3k1/1b1pbppp/pq2pn2/1p6/3PP3/P2B1N2/1PRBQPPP/6K1 w - - 1 18
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 5r1k/p1R2NRp/8/2p5/8/3b4/P4PPK/2r5 b - - 2 33
Is the move g2h4 legal?


Prompt:
FEN: 4r1k1/pp1q1p1p/1n5p/8/8/2N3PP/PP4P1/3R2K1 w - -
List pseudo-legal moves from d1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d1: d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1d7 d1e1 d1f1


Prompt:
FEN: r1bq1rk1/pppp1ppp/2n2n2/8/1b1PPB2/2NB4/PPP3PP/R2QK1NR w KQ - 1 7
For the piece on c3, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from c3: c3a4 c3b1 c3b5 c3d5 c3e2.
Legal: none.
Rejected: c3a4 pinned_piece_exposes_king; c3b1 pinned_piece_exposes_king; c3b5 pinned_piece_exposes_king; c3d5 pinned_piece_exposes_king; c3e2 pinned_piece_exposes_king.


Prompt:
FEN: 8/4k3/8/3R1p1p/3K1Pp1/6P1/7P/8 b - -
For move e7d6, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: e7d6.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: k7/3Q4/8/8/8/3K4/8/8 w - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: d3 white king; d7 white queen.
Moves by piece:
d3 white king: d3c2 d3c3 d3c4 d3d2 d3d4 d3e2 d3e3 d3e4
d7 white queen: d7a4 d7a7 d7b5 d7b7 d7c6 d7c7 d7c8 d7d4 d7d5 d7d6 d7d8 d7e6 d7e7 d7e8 d7f5 d7f7 d7g4 d7g7 d7h3 d7h7
All legal moves: d3c2 d3c3 d3c4 d3d2 d3d4 d3e2 d3e3 d3e4 d7a4 d7a7 d7b5 d7b7 d7c6 d7c7 d7c8 d7d4 d7d5 d7d6 d7d8 d7e6 d7e7 d7e8 d7f5 d7f7 d7g4 d7g7 d7h3 d7h7


Prompt:
FEN: 2B5/8/5P2/2kb4/7K/8/6P1/8 b - -
Walk each ray for the slider on d5: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: d5 black bishop.
Ray NE: e6 empty; f7 empty; g8 empty; edge.
Ray SE: e4 empty; f3 empty; g2 white pawn: capture (stop, included).
Ray SW: c4 empty; b3 empty; a2 empty; edge.
Ray NW: c6 empty; b7 empty; a8 empty; edge.
Moves from rays: d5a2 d5a8 d5b3 d5b7 d5c4 d5c6 d5e4 d5e6 d5f3 d5f7 d5g2 d5g8


Prompt:
FEN: 1r4k1/pp1n1pp1/4p2p/3pP3/2rP1N2/P1P3P1/3B1P1P/1R4K1 b - - 1 26
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 b7b5 b7b6 b8a8 b8c8 b8d8 b8e8 b8f8 c4a4 c4b4 c4c3 c4c5 c4c6 c4c7 c4c8 c4d4 d7b6 d7c5 d7e5 d7f6 d7f8 f7f5 f7f6 g7g5 g7g6 g8f8 g8h7 g8h8 h6h5


Prompt:
FEN: rn3rk1/pp3ppp/3P1n2/3p4/3Q2b1/2P5/PP1N2PP/R3KBNR b KQ - 0 14
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 b7b5 b7b6 b8a6 b8c6 b8d7 f6d7 f6e4 f6e8 f6h5 f8c8 f8d8 f8e8 g4c8 g4d1 g4d7 g4e2 g4e6 g4f3 g4f5 g4h3 g4h5 g7g5 g7g6 g8h8 h7h5 h7h6


Prompt:
FEN: 8/ppk1Q3/2p5/3p1P2/3P2P1/P6K/1P5P/8 b - - 2 44
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: d5 black pawn; c6 black pawn; a7 black pawn; b7 black pawn; c7 black king.


Prompt:
FEN: 1r1qrbk1/p4pp1/3p1n1p/2p5/N3PB2/1PQ2P2/P1P3PP/4RR1K b - - 10 22
What legal moves does the piece on e8 have?


Prompt:
FEN: r2r2k1/p4ppp/8/qp6/8/bbRBP3/1N2KPPP/B7 b - - 1 23
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 8/1p1n4/p3k2p/P4pp1/5P2/1P1N1K2/2P4P/8 w - -
List all capture moves available.


Prompt:
Given FEN: 8/8/1n1k4/6N1/2p1p2p/4P1P1/1PK2P1P/8 b - - 0 49
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 5rk1/2p3pp/p3pn2/bb2N3/P1pqB3/2P5/1PQ2PPP/R1B1K2R w KQ - 0 17
Is the move a1a3 legal?


Prompt:
FEN: 8/8/3K4/3B4/3N1k2/8/8/8 b - -
List pseudo-legal moves from f4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from f4: f4e3 f4e4 f4e5 f4f3 f4f5 f4g3 f4g4 f4g5


Prompt:
FEN: rn2kr2/1p1q3p/p7/3P1p2/1P1Q1P2/P5P1/1B4KP/R7 w - - 1 24
For the piece on a1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from a1: a1a2 a1b1 a1c1 a1d1 a1e1 a1f1 a1g1 a1h1.
Legal: a1a2 a1b1 a1c1 a1d1 a1e1 a1f1 a1g1 a1h1.
Rejected: none.


Prompt:
FEN: r2q1rk1/pp3ppp/2n2n2/3pN3/3P4/4P2P/P3bPP1/R1BQ1RK1 w - - 0 14
For move a1b1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a1b1.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: rnbnk2r/4qppp/p2pp3/8/PPBN4/2R1Q3/5PPP/2B1K1R1 b kq -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: a6 black pawn; d6 black pawn; e6 black pawn; e7 black queen; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; b8 black knight; c8 black bishop; d8 black knight; e8 black king; h8 black rook.
Moves by piece:
a6 black pawn: a6a5
d6 black pawn: d6d5
e6 black pawn: e6e5
e7 black queen: e7a7 e7b7 e7c7 e7d7 e7f6 e7f8 e7g5 e7h4
f7 black pawn: f7f5 f7f6
g7 black pawn: g7g5 g7g6
h7 black pawn: h7h5 h7h6
a8 black rook: a8a7
b8 black knight: b8c6 b8d7
c8 black bishop: c8b7 c8d7
d8 black knight: d8b7 d8c6
e8 black king: e8d7 e8f8 e8g8
h8 black rook: h8f8 h8g8
All legal moves: a6a5 a8a7 b8c6 b8d7 c8b7 c8d7 d6d5 d8b7 d8c6 e6e5 e7a7 e7b7 e7c7 e7d7 e7f6 e7f8 e7g5 e7h4 e8d7 e8f8 e8g8 f7f5 f7f6 g7g5 g7g6 h7h5 h7h6 h8f8 h8g8


Prompt:
FEN: rnbqk1nr/pp2bpp1/7p/2p1P3/3p1B2/3P1NN1/PPP3PP/R2QKB1R b KQkq - 1 9
Walk each ray for the slider on e7: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: e7 black bishop.
Ray NE: f8 empty; edge.
Ray SE: f6 empty; g5 empty; h4 empty; edge.
Ray SW: d6 empty; c5 black pawn: own piece (stop, excluded).
Ray NW: d8 black queen: own piece (stop, excluded).
Moves from rays: e7d6 e7f6 e7f8 e7g5 e7h4


Prompt:
FEN: 7Q/4K3/8/5P2/8/6kp/8/8 w - -
For every side-to-move piece, list pseudo-legal moves, reject illegal ones with reasons, then give all legal moves.

Answer format: include "Side to move:", "Pieces:", "Filter by piece:", one line per side-to-move piece with "pseudo-legal ... | rejected ... | legal ..." fields, and "All legal moves:".

Side to move: white.
Pieces: f5 white pawn; e7 white king; h8 white queen.
Filter by piece:
f5 white pawn: pseudo-legal f5f6 | rejected none | legal f5f6
e7 white king: pseudo-legal e7d6 e7d7 e7d8 e7e6 e7e8 e7f6 e7f7 e7f8 | rejected none | legal e7d6 e7d7 e7d8 e7e6 e7e8 e7f6 e7f7 e7f8
h8 white queen: pseudo-legal h8a1 h8a8 h8b2 h8b8 h8c3 h8c8 h8d4 h8d8 h8e5 h8e8 h8f6 h8f8 h8g7 h8g8 h8h3 h8h4 h8h5 h8h6 h8h7 | rejected none | legal h8a1 h8a8 h8b2 h8b8 h8c3 h8c8 h8d4 h8d8 h8e5 h8e8 h8f6 h8f8 h8g7 h8g8 h8h3 h8h4 h8h5 h8h6 h8h7
All legal moves: e7d6 e7d7 e7d8 e7e6 e7e8 e7f6 e7f7 e7f8 f5f6 h8a1 h8a8 h8b2 h8b8 h8c3 h8c8 h8d4 h8d8 h8e5 h8e8 h8f6 h8f8 h8g7 h8g8 h8h3 h8h4 h8h5 h8h6 h8h7


Prompt:
FEN: 4k3/p4ppp/1p1p1n2/1P1pB3/8/5P1P/6PK/8 w - - 0 36
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: e5a1 e5b2 e5c3 e5d4 e5d6 e5f4 e5f6 e5g3 f3f4 g2g3 g2g4 h2g1 h2g3 h2h1 h3h4


Prompt:
FEN: 8/R4K2/1r5k/5P2/8/8/8/8 w - -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: f5 white pawn; a7 white rook; f7 white king.


Prompt:
FEN: 4n3/5pk1/1p3rpp/3Pp3/p3P2P/N2R1PP1/PPK5/8 b - -
What legal moves does the piece on f7 have?


Prompt:
FEN: 8/4k3/1K2n3/3Q4/8/8/8/8 w - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r1b1k2r/2p1bpp1/p4n1p/1p6/5B2/1BP5/PP3PPP/RN2R1K1 b kq -
List all capture moves available.


Prompt:
Given FEN: 1r1r4/1bq1ppkp/2p3p1/p3p3/4P1P1/2N1Q2P/PPP2P2/2KR3R w - - 0 19
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 2k5/5pr1/1B1R3p/p4Ppn/P1P1B1P1/6QK/3r4/4R3 w - -
Is the move f8e7 legal?


Prompt:
FEN: 5rk1/pr5p/b5p1/8/P1p5/2N1PP1P/6P1/3R2K1 w - - 1 26
List pseudo-legal moves from d1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d1: d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1d7 d1d8 d1e1 d1f1


Prompt:
FEN: 8/6pp/5b1k/5Q1P/2r5/6PK/8/8 w - - 3 55
For the piece on h3, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from h3: h3g2 h3g4 h3h2 h3h4.
Legal: h3g2 h3h2.
Rejected: h3g4 king_would_be_in_check; h3h4 king_would_be_in_check.


Prompt:
FEN: rnbq1rk1/ppp2ppp/8/3n4/1bBP4/2N5/PP3PPP/R1BQK1NR w KQ -
For move c3a4, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: c3a4.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; pinned_piece_exposes_king.


Prompt:
FEN: 8/8/8/ppk5/2pp4/8/2K5/6b1 w - - 2 60
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: c2 white king.
Moves by piece:
c2 white king: c2b1 c2b2 c2c1 c2d1 c2d2
All legal moves: c2b1 c2b2 c2c1 c2d1 c2d2


Prompt:
FEN: 5k2/5Pp1/3b4/1p6/2p5/2P4K/1P3q2/8 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: b2b3 b2b4 h3g4


Prompt:
FEN: r2q1rk1/ppp2ppp/1bn1pnb1/8/1P1P4/P1N1PN1P/3BBPP1/2RQ1RK1 b - - 2 13
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 a8b8 a8c8 b6a5 b6c5 b6d4 c6a5 c6b4 c6b8 c6d4 c6e5 c6e7 d8b8 d8c8 d8d4 d8d5 d8d6 d8d7 d8e7 d8e8 e6e5 f6d5 f6d7 f6e4 f6e8 f6g4 f6h5 f8e8 g6b1 g6c2 g6d3 g6e4 g6f5 g6h5 g8h8 h7h5 h7h6


Prompt:
FEN: 6k1/p4p2/1p2pp1p/8/8/2P2P2/PP4PP/3r1RK1 b - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 b6b5 d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1d7 d1d8 d1e1 d1f1 e6e5 f6f5 g8f8 g8g7 g8h7 g8h8 h6h5


Prompt:
FEN: r1nq1rk1/1b3pbp/p2p2p1/1p6/3NP3/1B6/PP3PPP/RN1QR1K1 w - -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a1 white rook; b1 white knight; d1 white queen; e1 white rook; g1 white king; a2 white pawn; b2 white pawn; f2 white pawn; g2 white pawn; h2 white pawn; b3 white bishop; d4 white knight; e4 white pawn.


Prompt:
FEN: B7/6p1/k6p/8/2P5/1K6/6P1/8 w - -
What legal moves does the piece on a8 have?


Prompt:
FEN: r1bq4/ppp2kp1/2np1n1p/2bNp3/4P3/3P4/PPP2PPP/R1BQ1RK1 b - - 1 10
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 6k1/ppp3b1/3p2r1/1P1Pp3/P4qp1/5P1P/4Q1K1/5R2 w - - 0 34
List all capture moves available.


Prompt:
Given FEN: r1b1k1nr/2bp1ppp/pp2pq2/8/B1n1P3/2NNB3/PPP2PPP/R2Q1RK1 w kq - 2 13
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r4r2/5pkp/N1p1p1p1/3n4/1P6/PR3B2/5PPP/R5K1 b - - 0 25
Is the move d5e7 legal?


Prompt:
FEN: r1b2kn1/pp1p1p1p/1q2p3/4Q3/2PbP3/8/PP1BK1PP/RN3B1R w - - 4 12
List pseudo-legal moves from b1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: r4rk1/pppq1ppp/3pbn2/4p3/2PbP3/1B1P3P/PP1N1PP1/R1BQ1RK1 w - - 3 11
For the piece on f2, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from f2: f2f3 f2f4.
Legal: none.
Rejected: f2f3 pinned_piece_exposes_king; f2f4 pinned_piece_exposes_king.


Prompt:
FEN: R4K1k/ppp3pp/3p4/2p2NP1/2b1rPN1/4P2R/PP1P2rP/8 w - -
For move f8e7, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: f8e7.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: r1bq1rk1/p2p2pp/2p2p2/1p5n/3PP2B/1PP2N2/2P3PP/R2QK2R b KQ - 1 14
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: b5 black pawn; h5 black knight; c6 black pawn; f6 black pawn; a7 black pawn; d7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; c8 black bishop; d8 black queen; f8 black rook; g8 black king.
Moves by piece:
b5 black pawn: b5b4
h5 black knight: h5f4 h5g3
c6 black pawn: c6c5
f6 black pawn: f6f5
a7 black pawn: a7a5 a7a6
d7 black pawn: d7d5 d7d6
g7 black pawn: g7g5 g7g6
h7 black pawn: h7h6
a8 black rook: a8b8
c8 black bishop: c8a6 c8b7
d8 black queen: d8a5 d8b6 d8c7 d8e7 d8e8
f8 black rook: f8e8 f8f7
g8 black king: g8f7 g8h8
All legal moves: a7a5 a7a6 a8b8 b5b4 c6c5 c8a6 c8b7 d7d5 d7d6 d8a5 d8b6 d8c7 d8e7 d8e8 f6f5 f8e8 f8f7 g7g5 g7g6 g8f7 g8h8 h5f4 h5g3 h7h6


Prompt:
FEN: rnbqkb1r/p2p1ppp/1p2pn2/2p5/3P1P2/3BPN2/PPP3PP/RNBQK2R b KQkq -
Walk each ray for the slider on a8: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: a8 black rook.
Ray N: edge.
Ray E: b8 black knight: own piece (stop, excluded).
Ray S: a7 black pawn: own piece (stop, excluded).
Ray W: edge.
Moves from rays: none


Prompt:
FEN: r6k/2p3pp/4N3/4P1B1/p2P3P/P7/1qPK2P1/5R2 w - - 1 27
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: d2d1 d2d3 d2e1 d2e2 d2e3 d4d5 e6c5 e6c7 e6d8 e6f4 e6f8 e6g7 f1a1 f1b1 f1c1 f1d1 f1e1 f1f2 f1f3 f1f4 f1f5 f1f6 f1f7 f1f8 f1g1 f1h1 g2g3 g2g4 g5d8 g5e3 g5e7 g5f4 g5f6 g5h6 h4h5


Prompt:
FEN: 7r/p5pp/4p1q1/2k2p2/4b3/8/PP3PPP/2R2RK1 b - - 1 24
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: c5b4 c5b5 c5b6 c5d4 c5d5 c5d6 e4c2


Prompt:
FEN: rrb3k1/2q1pp1p/3p1bp1/1ppP4/5PP1/1BPP1Q1P/1P1B4/1R2R1K1 w - - 1 22
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: b1 white rook; e1 white rook; g1 white king; b2 white pawn; d2 white bishop; b3 white bishop; c3 white pawn; d3 white pawn; f3 white queen; h3 white pawn; f4 white pawn; g4 white pawn; d5 white pawn.


Prompt:
FEN: 8/b1R4p/6p1/P5k1/8/8/6KP/8 b - - 2 40
What legal moves does the piece on h7 have?


Prompt:
FEN: rnb1k1nr/pp2bpp1/2pp2qp/4p3/2B1P3/P1NP1N2/1PP2PPP/R1BQR1K1 b - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: rnbqk1nr/pppp1pbp/6p1/4p3/2P5/2NP1N2/PP2PPPP/R1BQKB1R b KQkq - 0 4
List all capture moves available.


Prompt:
Given FEN: r2qk2r/ppp2ppp/2bp1n2/4P1B1/3Q4/8/PPP2PPP/RN3RK1 b kq - 0 10
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 6k1/3r1p1p/2n1p1p1/p7/4p2P/5P2/P1N1K1P1/3r4 w - -
Is the move a2a4 legal?


Prompt:
FEN: rn3rk1/1p2ppbp/1p1pb1p1/8/3PnB2/N1P2N1P/PP2BPP1/R3K2R w KQ -
List pseudo-legal moves from a1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from a1: a1b1 a1c1 a1d1


Prompt:
FEN: 8/8/4p1k1/3p4/3P2P1/2P3K1/8/8 w - -
For the piece on c3, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from c3: c3c4.
Legal: c3c4.
Rejected: none.


Prompt:
FEN: 8/4Nk2/8/3KQ3/8/8/8/8 w - -
For move d5e6, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: d5e6.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: 4r2k/p4R1p/3Qpp2/8/q7/4P2P/5PPK/8 b - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: a4 black queen; e6 black pawn; f6 black pawn; a7 black pawn; h7 black pawn; e8 black rook; h8 black king.
Moves by piece:
a4 black queen: a4a1 a4a2 a4a3 a4a5 a4a6 a4b3 a4b4 a4b5 a4c2 a4c4 a4c6 a4d1 a4d4 a4d7 a4e4 a4f4 a4g4 a4h4
e6 black pawn: e6e5
f6 black pawn: f6f5
a7 black pawn: a7a5 a7a6
h7 black pawn: h7h5 h7h6
e8 black rook: e8a8 e8b8 e8c8 e8d8 e8e7 e8f8 e8g8
h8 black king: h8g8
All legal moves: a4a1 a4a2 a4a3 a4a5 a4a6 a4b3 a4b4 a4b5 a4c2 a4c4 a4c6 a4d1 a4d4 a4d7 a4e4 a4f4 a4g4 a4h4 a7a5 a7a6 e6e5 e8a8 e8b8 e8c8 e8d8 e8e7 e8f8 e8g8 f6f5 h7h5 h7h6 h8g8


Prompt:
FEN: q3kR1Q/8/pp1p2P1/8/3pP2P/3P2rb/PP4P1/2R3K1 b - - 0 26
Walk each ray for the slider on g3: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: g3 black rook.
Ray N: g4 empty; g5 empty; g6 white pawn: capture (stop, included).
Ray E: h3 black bishop: own piece (stop, excluded).
Ray S: g2 white pawn: capture (stop, included).
Ray W: f3 empty; e3 empty; d3 white pawn: capture (stop, included).
Moves from rays: g3d3 g3e3 g3f3 g3g2 g3g4 g3g5 g3g6


Prompt:
FEN: 4r3/1p4b1/2p2k2/p1P1N3/1P2nPp1/P7/2b3K1/8 b - - 3 35
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a5a4 a5b4 b7b5 b7b6 c2a4 c2b1 c2b3 c2d1 c2d3 e4c3 e4c5 e4d2 e4d6 e4f2 e4g3 e4g5 e8a8 e8b8 e8c8 e8d8 e8e5 e8e6 e8e7 e8f8 e8g8 e8h8 f6e6 f6e7 f6f5 g4g3 g7f8 g7h6 g7h8


Prompt:
FEN: 4r1k1/2p4p/4N3/p4P2/1p6/4p3/PP2K1PP/8 b - - 1 30
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a5a4 b4b3 c7c5 c7c6 e8a8 e8b8 e8c8 e8d8 e8e6 e8e7 e8f8 g8f7 g8h8 h7h5 h7h6


Prompt:
FEN: rnb1kbnr/1p1p1pp1/p1p1p2p/q7/3PP2B/2N2N2/PPP2PPP/R2QKB1R b KQkq - 1 6
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: a5 black queen; a6 black pawn; c6 black pawn; e6 black pawn; h6 black pawn; b7 black pawn; d7 black pawn; f7 black pawn; g7 black pawn; a8 black rook; b8 black knight; c8 black bishop; e8 black king; f8 black bishop; g8 black knight; h8 black rook.


Prompt:
FEN: rn1q1rk1/4bppp/p2pbn2/1pp1p3/P3P3/2NPBN1P/1PP1BPP1/R2QR1K1 b - -
What legal moves does the piece on f8 have?


Prompt:
FEN: 8/3k4/4r3/8/8/3K4/8/1R6 b - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 6k1/1R3p1p/p3p1p1/3pP3/6PP/8/8/r6K w - - 1 36
List all capture moves available.


Prompt:
Given FEN: 3R4/8/8/5pp1/2k1p3/6P1/r4PK1/8 w - -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 8/8/2k5/7R/5N2/5Kp1/5b2/8 b - - 8 69
Is the move f2a7 legal?


Prompt:
FEN: 8/1p6/1B1K4/P7/k7/8/2p5/8 w - -
List pseudo-legal moves from a5.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".


Prompt:
FEN: 4kb1r/1p1b1Rp1/p2Pp2q/8/4P1B1/2r3Q1/P5PP/5R1K w k -
For the piece on f1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from f1: f1a1 f1b1 f1c1 f1d1 f1e1 f1f2 f1f3 f1f4 f1f5 f1f6 f1g1.
Legal: f1a1 f1b1 f1c1 f1d1 f1e1 f1f2 f1f3 f1f4 f1f5 f1f6 f1g1.
Rejected: none.


Prompt:
FEN: 2k5/8/1P2K3/1B3p2/7p/8/8/8 b - - 0 43
For move c8c7, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: c8c7.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: r1bqkbnr/pp3ppp/2n1p3/2pp4/3P1P2/2PBP3/PP4PP/RNBQK1NR b KQkq - 2 5
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: c5 black pawn; d5 black pawn; c6 black knight; e6 black pawn; a7 black pawn; b7 black pawn; f7 black pawn; g7 black pawn; h7 black pawn; a8 black rook; c8 black bishop; d8 black queen; e8 black king; f8 black bishop; g8 black knight; h8 black rook.
Moves by piece:
c5 black pawn: c5c4 c5d4
d5 black pawn: no legal moves
c6 black knight: c6a5 c6b4 c6b8 c6d4 c6e5 c6e7
e6 black pawn: e6e5
a7 black pawn: a7a5 a7a6
b7 black pawn: b7b5 b7b6
f7 black pawn: f7f5 f7f6
g7 black pawn: g7g5 g7g6
h7 black pawn: h7h5 h7h6
a8 black rook: a8b8
c8 black bishop: c8d7
d8 black queen: d8a5 d8b6 d8c7 d8d6 d8d7 d8e7 d8f6 d8g5 d8h4
e8 black king: e8d7 e8e7
f8 black bishop: f8d6 f8e7
g8 black knight: g8e7 g8f6 g8h6
h8 black rook: no legal moves
All legal moves: a7a5 a7a6 a8b8 b7b5 b7b6 c5c4 c5d4 c6a5 c6b4 c6b8 c6d4 c6e5 c6e7 c8d7 d8a5 d8b6 d8c7 d8d6 d8d7 d8e7 d8f6 d8g5 d8h4 e6e5 e8d7 e8e7 f7f5 f7f6 f8d6 f8e7 g7g5 g7g6 g8e7 g8f6 g8h6 h7h5 h7h6


Prompt:
FEN: r1b4N/pp2k1pp/4p3/2b5/3nnB2/8/PP2K1PP/1N6 w - - 1 24
Walk each ray for the slider on f4: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: f4 white bishop.
Ray NE: g5 empty; h6 empty; edge.
Ray SE: g3 empty; h2 white pawn: own piece (stop, excluded).
Ray SW: e3 empty; d2 empty; c1 empty; edge.
Ray NW: e5 empty; d6 empty; c7 empty; b8 empty; edge.
Moves from rays: f4b8 f4c1 f4c7 f4d2 f4d6 f4e3 f4e5 f4g3 f4g5 f4h6


Prompt:
FEN: 2kr3r/2p1q1p1/p1p5/Pp3p2/3pn2p/3QBP1P/1PP3P1/R2R2K1 w - - 0 18
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1a2 a1a3 a1a4 a1b1 a1c1 b2b3 b2b4 c2c3 c2c4 d1b1 d1c1 d1d2 d1e1 d1f1 d3a3 d3b3 d3b5 d3c3 d3c4 d3d2 d3d4 d3e2 d3e4 d3f1 e3c1 e3d2 e3d4 e3f2 e3f4 e3g5 e3h6 f3e4 f3f4 g1f1 g1h1 g1h2 g2g3 g2g4


Prompt:
FEN: 8/8/2k1B3/2B1K3/8/8/8/8 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: c5a3 c5a7 c5b4 c5b6 c5d4 c5d6 c5e3 c5e7 c5f2 c5f8 c5g1 e5d4 e5e4 e5f4 e5f5 e5f6 e6a2 e6b3 e6c4 e6c8 e6d5 e6d7 e6f5 e6f7 e6g4 e6g8 e6h3


Prompt:
FEN: r1b2rk1/pp1nq1pp/2n1pp2/1NppP3/3P1P2/2P2N2/PP4PP/R2QKB1R w KQ -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: a1 white rook; d1 white queen; e1 white king; f1 white bishop; h1 white rook; a2 white pawn; b2 white pawn; g2 white pawn; h2 white pawn; c3 white pawn; f3 white knight; d4 white pawn; f4 white pawn; b5 white knight; e5 white pawn.


Prompt:
FEN: 1r5r/p2bk2p/2p1pp2/q7/5P2/1P1BQ3/P5PP/R2R3K w - -
What legal moves does the piece on e3 have?

e3a7 e3b6 e3c1 e3c5 e3d2 e3d4 e3e1 e3e2 e3e4 e3e5 e3e6 e3f2 e3f3 e3g1 e3g3 e3h3


Prompt:
FEN: r5k1/p1p3pp/2pp1pn1/5Q1P/3P4/2NB2P1/PPP2RK1/2q3r1 w - - 1 24
Detect the game state: check, checkmate, stalemate, or none.


Prompt:
FEN: r1b1k2r/pp2ppbp/2p2np1/8/1q2P3/1BN1BP2/PPP3PP/R2QK2R b KQkq -
List all capture moves available.


Prompt:
Given FEN: 3N4/1R3pk1/4p1p1/4r2p/8/8/4nKPP/8 b - -
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 4r1k1/r6p/b4pq1/2pPnNp1/1pP1P1P1/pP2R1QP/P5B1/5R1K b - - 1 35
Is the move g4f1 legal?


Prompt:
FEN: 3r2k1/pB3ppp/3Prn2/8/5P2/2N5/PPP4P/3R1R1K w - - 1 24
List pseudo-legal moves from d1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d1: d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1e1


Prompt:
FEN: r2q1rk1/1pp3pp/2nppn2/p1b1p3/4P3/P1NP1N1P/1PP2PP1/R1BQ1RK1 w - - 0 10
For the piece on a1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from a1: a1a2 a1b1.
Legal: a1a2 a1b1.
Rejected: none.


Prompt:
FEN: r6k/2p5/5p1P/4p1p1/8/5N2/1Bq2K2/8 w - - 1 50
For move b2a1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: b2a1.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; does_not_resolve_check.


Prompt:
FEN: 8/8/2K5/7p/1r4k1/1P2R1P1/8/8 b - -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: b4 black rook; g4 black king; h5 black pawn.
Moves by piece:
b4 black rook: b4a4 b4b3 b4b5 b4b6 b4b7 b4b8 b4c4 b4d4 b4e4 b4f4
g4 black king: g4f5 g4g5 g4h3
h5 black pawn: h5h4
All legal moves: b4a4 b4b3 b4b5 b4b6 b4b7 b4b8 b4c4 b4d4 b4e4 b4f4 g4f5 g4g5 g4h3 h5h4


Prompt:
FEN: b6k/4K1np/3Np3/8/8/8/8/8 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: d6b5 d6b7 d6c4 d6c8 d6e4 d6e8 d6f5 d6f7 e7d7 e7d8 e7f6 e7f7 e7f8


Prompt:
FEN: r3kb1r/p2p1ppp/2qP4/p1B1P3/1P6/2P2N2/P1Q2PPP/R4K2 b kq - 0 18
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a5a4 a5b4 a7a6 a8b8 a8c8 a8d8 c6a4 c6a6 c6b5 c6b6 c6b7 c6c5 c6c7 c6c8 c6d5 c6d6 c6e4 c6f3 e8c8 e8d8 f7f5 f7f6 f8d6 f8e7 g7g5 g7g6 h7h5 h7h6 h8g8


Prompt:
FEN: 3qbk2/1QR2r2/1n1p4/2pPp1pp/2P1Pp2/2N2P1P/6PN/6K1 w - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: b7a6 b7a7 b7a8 b7b6 b7b8 b7c6 b7c8 c3a2 c3a4 c3b1 c3b5 c3d1 c3e2 c7c5 c7c6 c7c8 c7d7 c7e7 c7f7 g1f1 g1f2 g1h1 g2g3 g2g4 h2f1 h2g4 h3h4


Prompt:
FEN: r1bqrnk1/1p3ppp/pb6/3PP3/3p1P2/3P2P1/PP1BQ1BP/2R2RK1 w - -
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: c1 white rook; f1 white rook; g1 white king; a2 white pawn; b2 white pawn; d2 white bishop; e2 white queen; g2 white bishop; h2 white pawn; d3 white pawn; g3 white pawn; f4 white pawn; d5 white pawn; e5 white pawn.


Prompt:
FEN: 5r2/1p4pk/p2p3p/2qPp3/2PbP3/1P1B3P/P3R1P1/3Q3K w - - 5 31
What legal moves does the piece on c4 have?


Prompt:
FEN: r7/6P1/3k4/5K2/6R1/8/8/8 b - -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 7k/5Bp1/2Q4p/8/8/8/8/6K1 w - -
List all capture moves available.


Prompt:
Given FEN: 7r/p2k1p2/1nn1r2p/q2pP2P/1bpP4/4BN2/PPQN3R/1K4R1 b - - 3 26
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 4r1k1/pp2rpp1/2p2n1p/3pq3/6b1/2PQP3/PPB2PPP/2KR2NR b - - 1 18
Is the move b2e5 legal?


Prompt:
FEN: 1r3rk1/pp3pp1/1n2p2p/1b2P3/1P2N2P/P4N2/5PPK/R3R3 w - - 1 26
List pseudo-legal moves from a1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from a1: a1a2 a1b1 a1c1 a1d1


Prompt:
FEN: 4kbnr/2p4p/1p2b1p1/p2pp3/7P/2P3P1/PPQ1PPB1/RN2K1NR w KQ - 0 19
For the piece on b1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from b1: b1a3 b1d2.
Legal: b1a3 b1d2.
Rejected: none.


Prompt:
FEN: r2q1rk1/pp1n1pbp/2p1pnp1/2Pp4/3P4/2NQPN2/PP1B1PPP/R4RK1 b - -
For move a7a5, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a7a5.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: 3r3r/5kpp/4qp2/3p4/Pb6/3Q1PB1/1P3P1P/5RK1 b - - 1 27
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: b4 black bishop; d5 black pawn; e6 black queen; f6 black pawn; f7 black king; g7 black pawn; h7 black pawn; d8 black rook; h8 black rook.
Moves by piece:
b4 black bishop: b4a3 b4a5 b4c3 b4c5 b4d2 b4d6 b4e1 b4e7 b4f8
d5 black pawn: d5d4
e6 black queen: e6a6 e6b6 e6c6 e6c8 e6d6 e6d7 e6e1 e6e2 e6e3 e6e4 e6e5 e6e7 e6e8 e6f5 e6g4 e6h3
f6 black pawn: f6f5
f7 black king: f7e7 f7e8 f7f8 f7g8
g7 black pawn: g7g5 g7g6
h7 black pawn: h7h5 h7h6
d8 black rook: d8a8 d8b8 d8c8 d8d6 d8d7 d8e8 d8f8 d8g8
h8 black rook: h8e8 h8f8 h8g8
All legal moves: b4a3 b4a5 b4c3 b4c5 b4d2 b4d6 b4e1 b4e7 b4f8 d5d4 d8a8 d8b8 d8c8 d8d6 d8d7 d8e8 d8f8 d8g8 e6a6 e6b6 e6c6 e6c8 e6d6 e6d7 e6e1 e6e2 e6e3 e6e4 e6e5 e6e7 e6e8 e6f5 e6g4 e6h3 f6f5 f7e7 f7e8 f7f8 f7g8 g7g5 g7g6 h7h5 h7h6 h8e8 h8f8 h8g8


Prompt:
FEN: r6k/6pp/p2pbpq1/1p2p3/8/4PN1P/PPP1QRP1/R5K1 w - - 1 24
Walk each ray for the slider on a1: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: a1 white rook.
Ray N: a2 white pawn: own piece (stop, excluded).
Ray E: b1 empty; c1 empty; d1 empty; e1 empty; f1 empty; g1 white king: own piece (stop, excluded).
Ray S: edge.
Ray W: edge.
Moves from rays: a1b1 a1c1 a1d1 a1e1 a1f1


Prompt:
FEN: 4r3/4bkp1/3q1p1p/1Q1p4/3P4/1P5P/P3RP1P/4R1K1 w - - 1 32
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a2a3 a2a4 b3b4 b5a4 b5a5 b5a6 b5b4 b5b6 b5b7 b5b8 b5c4 b5c5 b5c6 b5d3 b5d5 b5d7 b5e8 e1a1 e1b1 e1c1 e1d1 e1f1 e2b2 e2c2 e2d2 e2e3 e2e4 e2e5 e2e6 e2e7 f2f3 f2f4 g1f1 g1g2 g1h1 h3h4


Prompt:
FEN: r1bqk1nr/ppp2p2/2nbp2p/1N1p2p1/3P1B2/P4N2/1PPQPPPP/R3KB1R w KQkq - 0 8
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a1a2 a1b1 a1c1 a1d1 a3a4 b2b3 b2b4 b5a7 b5c3 b5c7 b5d6 c2c3 c2c4 d2a5 d2b4 d2c1 d2c3 d2d1 d2d3 d2e3 e1c1 e1d1 e2e3 e2e4 f3e5 f3g1 f3g5 f3h4 f4d6 f4e3 f4e5 f4g3 f4g5 g2g3 g2g4 h1g1 h2h3 h2h4


Prompt:
FEN: 7k/2p5/1p1p3q/pPnPp3/P1P1Pn2/5Q1P/2B3rK/5RN1 w - - 3 31
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: f1 white rook; g1 white knight; c2 white bishop; h2 white king; f3 white queen; h3 white pawn; a4 white pawn; c4 white pawn; e4 white pawn; b5 white pawn; d5 white pawn.


Prompt:
FEN: 8/4r1k1/1R5p/6pP/6P1/5P2/5K2/8 b - -
What legal moves does the piece on g5 have?


Prompt:
FEN: 5k2/p4p1p/1pn1p1p1/2p5/4NP2/5KP1/PPP4P/8 w - - 2 27
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: 3n4/ppp4p/5kp1/4Np2/3P4/2P5/PP3R1P/2K1R3 w - - 3 25
List all capture moves available.


Prompt:
Given FEN: 6bk/6bp/8/pp2pnN1/2p1B3/2P4P/P2r1PP1/4R1K1 w - - 0 37
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: 8/2Pb3k/6p1/3P3p/4pP2/7P/6P1/6K1 w - - 1 42
Is the move g2g4 legal?


Prompt:
FEN: 2k4r/p6p/2bq2p1/p2rp1B1/2Rb3P/P7/3Q1PP1/2R3K1 b - -
List pseudo-legal moves from d4.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from d4: d4a1 d4b2 d4b6 d4c3 d4c5 d4e3 d4f2


Prompt:
FEN: rn6/1b1p4/p1p1pkp1/8/3P3p/2PB3P/PP3PP1/R4RK1 w - - 0 21
For the piece on a1, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from a1: a1b1 a1c1 a1d1 a1e1.
Legal: a1b1 a1c1 a1d1 a1e1.
Rejected: none.


Prompt:
FEN: 2k3r1/ppp2p1p/2n5/3p1p2/3P3P/N1P2P1R/PPK3N1/R7 w - - 1 22
For move a1b1, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: a1b1.
Pseudo-legal: yes.
King safe after move: yes.
Final: legal; legal.


Prompt:
FEN: r1bqkb1r/pp2pp1p/2np1p2/1Bp5/8/3P1N2/PPP2PPP/R1BQK2R w KQkq -
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: white.
Pieces: a1 white rook; c1 white bishop; d1 white queen; e1 white king; h1 white rook; a2 white pawn; b2 white pawn; c2 white pawn; f2 white pawn; g2 white pawn; h2 white pawn; d3 white pawn; f3 white knight; b5 white bishop.
Moves by piece:
a1 white rook: a1b1
c1 white bishop: c1d2 c1e3 c1f4 c1g5 c1h6
d1 white queen: d1d2 d1e2
e1 white king: e1d2 e1e2 e1f1 e1g1
h1 white rook: h1f1 h1g1
a2 white pawn: a2a3 a2a4
b2 white pawn: b2b3 b2b4
c2 white pawn: c2c3 c2c4
f2 white pawn: no legal moves
g2 white pawn: g2g3 g2g4
h2 white pawn: h2h3 h2h4
d3 white pawn: d3d4
f3 white knight: f3d2 f3d4 f3e5 f3g1 f3g5 f3h4
b5 white bishop: b5a4 b5a6 b5c4 b5c6
All legal moves: a1b1 a2a3 a2a4 b2b3 b2b4 b5a4 b5a6 b5c4 b5c6 c1d2 c1e3 c1f4 c1g5 c1h6 c2c3 c2c4 d1d2 d1e2 d3d4 e1d2 e1e2 e1f1 e1g1 f3d2 f3d4 f3e5 f3g1 f3g5 f3h4 g2g3 g2g4 h1f1 h1g1 h2h3 h2h4


Prompt:
FEN: r1bqk2r/ppppnppp/2n5/2PN4/2P5/1P2P3/P4PBP/R1BQK2R b KQkq -
Walk each ray for the slider on a8: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: a8 black rook.
Ray N: edge.
Ray E: b8 empty; c8 black bishop: own piece (stop, excluded).
Ray S: a7 black pawn: own piece (stop, excluded).
Ray W: edge.
Moves from rays: a8b8


Prompt:
FEN: r1bqkb1r/p1ppp1pp/1pn2n2/3P1p2/2P5/4PQ2/PP3PPP/RNB1KBNR b KQkq -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a7a5 a7a6 a8b8 b6b5 c6a5 c6b4 c6b8 c6d4 c6e5 c8a6 c8b7 d7d6 e7e5 e7e6 e8f7 f5f4 f6d5 f6e4 f6g4 f6g8 f6h5 g7g5 g7g6 h7h5 h7h6 h8g8


Prompt:
FEN: r4b2/2p1n3/2ppRNkr/q4bNp/3B1P1P/pPPQ2P1/P7/2K4R b - -
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a5a4 a5a6 a5a7 a5b4 a5b5 a5b6 a5c3 a5c5 a5d5 a5e5 a8a6 a8a7 a8b8 a8c8 a8d8 a8e8 c6c5 d6d5 e7c8 e7d5 e7g8 f5d3 f5e4 f8g7 g6g7 h6h7 h6h8


Prompt:
FEN: 5r2/2p1kr1p/ppnp1p2/3p4/P3P3/N1P5/4KRPP/1R6 w - - 0 26
List the side-to-move pieces and their squares.

Side to move: white.
Pieces: b1 white rook; e2 white king; f2 white rook; g2 white pawn; h2 white pawn; a3 white knight; c3 white pawn; a4 white pawn; e4 white pawn.


Prompt:
FEN: 4k2r/4nppp/r1p1q3/2b3B1/1n2P3/2N2N2/1P3PPP/R2Q1RK1 b k - 3 16
What legal moves does the piece on f7 have?


Prompt:
FEN: 2kr1bnr/ppq2ppp/2n5/3pP3/6b1/4PN2/PPP2PPP/RN1QKB1R w KQ -
Detect the game state: check, checkmate, stalemate, or none.

Normal position -- no check, checkmate, or stalemate.


Prompt:
FEN: r2q1rk1/pp1b1pbp/2nppnp1/2p5/4PPP1/3P2NP/PPP3B1/RNBQ1RK1 b - - 1 10
List all capture moves available.


Prompt:
Given FEN: 2kr3Q/ppp2p1p/8/8/2P2pq1/1P4P1/P4PKP/3RR3 w - - 9 33
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: r5k1/p1pbqpp1/2pp3p/2r1P3/8/1B3Q1P/PP3PP1/3RR1K1 b - - 0 20
Is the move c5d5 legal?


Prompt:
FEN: 8/r1k5/1p3p2/rPp1pP1p/2P1P1pP/pR1P2P1/R7/1K1B4 w - - 18 56
List pseudo-legal moves from b1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from b1: b1a1 b1b2 b1c1 b1c2


Prompt:
FEN: 3r3k/1p4b1/2p4p/2P2p1Q/1P2p3/4P1qP/6P1/3RR1K1 b - -
For the piece on g3, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from g3: g3b8 g3c7 g3d6 g3e1 g3e3 g3e5 g3f2 g3f3 g3f4 g3g2 g3g4 g3g5 g3g6 g3h2 g3h3 g3h4.
Legal: g3b8 g3c7 g3d6 g3e1 g3e3 g3e5 g3f2 g3f3 g3f4 g3g2 g3g4 g3g5 g3g6 g3h2 g3h3 g3h4.
Rejected: none.


Prompt:
FEN: 3r2k1/1q2n2p/2brp1p1/1pQ1Np2/4PP2/3P4/2R2NPP/4R1K1 b - -
For move g8f7, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: g8f7.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; king_would_be_in_check.


Prompt:
FEN: 5rk1/N2nbppp/1pr1p3/p2p4/3P4/8/PP3PPP/R1B2RK1 b - - 1 17
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: a5 black pawn; d5 black pawn; b6 black pawn; c6 black rook; e6 black pawn; d7 black knight; e7 black bishop; f7 black pawn; g7 black pawn; h7 black pawn; f8 black rook; g8 black king.
Moves by piece:
a5 black pawn: a5a4
d5 black pawn: no legal moves
b6 black pawn: b6b5
c6 black rook: c6c1 c6c2 c6c3 c6c4 c6c5 c6c7 c6c8 c6d6
e6 black pawn: e6e5
d7 black knight: d7b8 d7c5 d7e5 d7f6
e7 black bishop: e7a3 e7b4 e7c5 e7d6 e7d8 e7f6 e7g5 e7h4
f7 black pawn: f7f5 f7f6
g7 black pawn: g7g5 g7g6
h7 black pawn: h7h5 h7h6
f8 black rook: f8a8 f8b8 f8c8 f8d8 f8e8
g8 black king: g8h8
All legal moves: a5a4 b6b5 c6c1 c6c2 c6c3 c6c4 c6c5 c6c7 c6c8 c6d6 d7b8 d7c5 d7e5 d7f6 e6e5 e7a3 e7b4 e7c5 e7d6 e7d8 e7f6 e7g5 e7h4 f7f5 f7f6 f8a8 f8b8 f8c8 f8d8 f8e8 g7g5 g7g6 g8h8 h7h5 h7h6


Prompt:
FEN: 2q5/6pk/1P5p/8/5p2/3p4/1R1K3P/8 w - - 1 42
Walk each ray for the slider on b2: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: b2 white rook.
Ray N: b3 empty; b4 empty; b5 empty; b6 white pawn: own piece (stop, excluded).
Ray E: c2 empty; d2 white king: own piece (stop, excluded).
Ray S: b1 empty; edge.
Ray W: a2 empty; edge.
Moves from rays: b2a2 b2b1 b2b3 b2b4 b2b5 b2c2


Prompt:
FEN: r1bnkbnr/1pp2ppp/p7/4P1N1/4p3/2P5/PP3PPP/RNB1KB1R b KQkq - 1 7
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: black.
Legal moves: a6a5 a8a7 a8b8 b7b5 b7b6 c7c5 c7c6 c8d7 c8e6 c8f5 c8g4 c8h3 d8c6 d8e6 e4e3 e8d7 e8e7 f7f5 f7f6 f8a3 f8b4 f8c5 f8d6 f8e7 g7g6 g8e7 g8f6 g8h6 h7h5 h7h6


Prompt:
FEN: 8/p7/kp6/3R3r/2P5/6rP/P7/R5K1 w - - 0 38
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: g1f1 g1f2 g1h1 g1h2


Prompt:
FEN: 2k1r2r/pp1n1p2/2p2p2/6p1/3P3P/bP4B1/P1P5/1K1R1B1R b - - 0 24
List the side-to-move pieces and their squares.

Side to move: black.
Pieces: a3 black bishop; g5 black pawn; c6 black pawn; f6 black pawn; a7 black pawn; b7 black pawn; d7 black knight; f7 black pawn; c8 black king; e8 black rook; h8 black rook.


Prompt:
FEN: r1bqk2r/ppp2pp1/2np1n1p/2b1p3/1PB1P3/P2P1N1P/2P2PP1/RNBQK2R b KQkq - 0 7
What legal moves does the piece on h6 have?


Prompt:
FEN: 2kr3r/pp5p/1bp1Bp1B/4n3/4P3/7P/PPP3P1/2KR1R2 b - - 5 18
Detect the game state: check, checkmate, stalemate, or none.


Prompt:
FEN: 6k1/1rp3pp/8/6R1/4p1n1/1P6/P3K3/8 b - - 2 33
List all capture moves available.


Prompt:
Given FEN: 6r1/pp4kp/2pb3n/3p4/3P4/2P1R1PP/PPBN2P1/5RK1 b - - 6 28
List any special moves available (castling, en passant, promotion).


Prompt:
FEN: q4r1k/2pbbppp/Q2p1n2/8/P3P3/2P1BN2/3N1PPP/1R4K1 w - -
Is the move b1f1 legal?


Prompt:
FEN: 2R1r1k1/p7/1p2pp1Q/3pq3/7p/8/P4PP1/6K1 w - -
List pseudo-legal moves from g1.

Answer format: return exactly "Pseudo-legal moves from <square>: <space-separated UCI moves>".

Pseudo-legal moves from g1: g1f1 g1h1 g1h2


Prompt:
FEN: r1bqkb1r/5ppp/4pn2/1p2N3/3p4/3B1Q2/PP3PPP/R1B1K2R b KQkq - 1 13
For the piece on e8, split pseudo-legal moves into legal and rejected moves with rejection reasons.

Answer format: return exactly three lines starting "Pseudo-legal from", "Legal:", and "Rejected:". Rejected entries must be "<uci> <reason_label>" separated by semicolons, or "none" when no moves are rejected.

Pseudo-legal from e8: e8d7 e8e7.
Legal: e8e7.
Rejected: e8d7 king_would_be_in_check.


Prompt:
FEN: 1br2rk1/1b2qp2/p4Pn1/1p1p2Q1/3p1P1N/1B5P/PP4PK/3RR3 b - -
For move g6e5, decide whether king safety allows it.

Answer format: return exactly four lines starting "Move:", "Pseudo-legal:", "King safe after move:", and "Final:".

Move: g6e5.
Pseudo-legal: yes.
King safe after move: no.
Final: illegal; pinned_piece_exposes_king.


Prompt:
FEN: 6k1/5p1n/B3p3/3pP1p1/6P1/q7/4K3/7R b - - 6 46
Group all legal moves by side-to-move piece.

Answer format: include "Side to move:", "Pieces:", "Moves by piece:", one line per side-to-move piece, and "All legal moves:".

Side to move: black.
Pieces: a3 black queen; d5 black pawn; g5 black pawn; e6 black pawn; f7 black pawn; h7 black knight; g8 black king.
Moves by piece:
a3 black queen: a3a1 a3a2 a3a4 a3a5 a3a6 a3b2 a3b3 a3b4 a3c1 a3c3 a3c5 a3d3 a3d6 a3e3 a3e7 a3f3 a3f8 a3g3 a3h3
d5 black pawn: d5d4
g5 black pawn: no legal moves
e6 black pawn: no legal moves
f7 black pawn: f7f5 f7f6
h7 black knight: h7f6 h7f8
g8 black king: g8f8 g8g7 g8h8
All legal moves: a3a1 a3a2 a3a4 a3a5 a3a6 a3b2 a3b3 a3b4 a3c1 a3c3 a3c5 a3d3 a3d6 a3e3 a3e7 a3f3 a3f8 a3g3 a3h3 d5d4 f7f5 f7f6 g8f8 g8g7 g8h8 h7f6 h7f8


Prompt:
FEN: 3r2k1/5rb1/p3Q1p1/PpB5/8/2P2p2/1P2K3/6R1 w - - 0 48
Walk each ray for the slider on g1: list every square until a blocker, capture, or the board edge, then list the resulting moves.

Answer format: return a "Piece:" line, one "Ray <direction>:" line per ray in the listed order, and a final "Moves from rays:" line with space-separated UCI moves or "none".

Piece: g1 white rook.
Ray N: g2 empty; g3 empty; g4 empty; g5 empty; g6 black pawn: capture (stop, included).
Ray E: h1 empty; edge.
Ray S: edge.
Ray W: f1 empty; e1 empty; d1 empty; c1 empty; b1 empty; a1 empty; edge.
Moves from rays: g1a1 g1b1 g1c1 g1d1 g1e1 g1f1 g1g2 g1g3 g1g4 g1g5 g1g6 g1h1


Prompt:
FEN: r1b2rk1/ppp2pbp/4p1p1/1P6/8/5N2/1PN2PPP/2B1K2R w K - 1 19
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: b2b3 b2b4 b5b6 c1d2 c1e3 c1f4 c1g5 c1h6 c2a1 c2a3 c2b4 c2d4 c2e3 e1d1 e1d2 e1e2 e1f1 e1g1 f3d2 f3d4 f3e5 f3g1 f3g5 f3h4 g2g3 g2g4 h1f1 h1g1 h2h3 h2h4


Prompt:
FEN: 1rb2rk1/1p2qpp1/p1np3p/4p3/2B1P3/4QN2/PPP2PPP/3R1RK1 w - - 0 15
List all legal moves.

Answer format: return exactly two lines: "Side to move: <white|black>." then "Legal moves: <space-separated UCI moves>".

Side to move: white.
Legal moves: a2a3 a2a4 b2b3 b2b4 c2c3 c4a6 c4b3 c4b5 c4d3 c4d5 c4e2 c4e6 c4f7 d1a1 d1b1 d1c1 d1d2 d1d3 d1d4 d1d5 d1d6 d1e1 e3a3 e3a7 e3b3 e3b6 e3c1 e3c3 e3c5 e3d2 e3d3 e3d4 e3e1 e3e2 e3f4 e3g5 e3h6 f1e1 f3d2 f3d4 f3e1 f3e5 f3g5 f3h4 g1h1 g2g3 g2g4 h2h3 h2h4