The dataset viewer is not available for this split.
Error code: JobManagerCrashedError
Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
PAWN Lichess Full
~289M rated Lichess games from Q1 2025 (January-March), pre-tokenized in the PAWN training format. Validation and test splits are uniformly sampled from January 2026 (10-month temporal gap from training data).
Splits
| Split | Source | Games | Shards |
|---|---|---|---|
| train | Jan-Mar 2025 | ~289M | 289 |
| validation | Jan 1-14, 2026 | 50,000 | 1 |
| test | Jan 15-31, 2026 | 50,000 | 1 |
Val/test games are uniformly random-sampled from their respective date ranges via a two-pass approach (header-only count, then index-sampled parsing). Seed 42 for val, seed 43 for test.
Schema
| Column | Type | Description |
|---|---|---|
tokens |
list[int16] |
PAWN token IDs per ply (variable length, max 255) |
clock |
list[uint16] |
Seconds remaining per ply. 0 = no annotation. |
eval |
list[int16] |
Centipawns from white's perspective. Mate = ±(32767-N). -32768 = no annotation. |
game_length |
uint16 |
Number of half-moves |
result |
string |
1-0, 0-1, 1/2-1/2 |
white_player |
uint64 |
xxHash64 of username (Polars 1.39.3) |
black_player |
uint64 |
xxHash64 of username |
white_elo |
uint16 |
Lichess rating |
black_elo |
uint16 |
Lichess rating |
white_rating_diff |
int16 |
Rating change from this game |
black_rating_diff |
int16 |
Rating change from this game |
eco |
string |
ECO opening code (e.g. A03) |
opening |
string |
Opening name |
time_control |
string |
e.g. 600+0, 180+2 |
termination |
string |
Normal, Time forfeit, etc. |
date |
datetime[ms] |
Game start time (UTC) |
site |
string |
Lichess game URL |
Sentinel values
- Clock
0: no clock annotation (rare for rated games) - Eval
-32768(0x8000): no Stockfish eval (~92% of games lack evals) - Eval
±(32767-N): mate in N (bit 14 always set for mate scores) - Eval centipawns clamped to ±16383
Token vocabulary
4,278 tokens: 1 PAD + 4,096 grid moves (64×64 src/dst) + 176 promotions + 5 outcomes. See the PAWN architecture docs.
Usage
Direct loading with PAWN training pipeline
# Loads pre-tokenized data, ready for training — no parsing needed
from pawn.lichess_data import prepare_lichess_dataset
data = prepare_lichess_dataset(
"thomas-schweich/pawn-lichess-full",
max_games=500_000,
min_ply=10,
)
Polars with predicate pushdown
import polars as pl
# Filter to 1800-1900 Elo band without downloading the full dataset
df = (
pl.scan_parquet("hf://datasets/thomas-schweich/pawn-lichess-full/data/train-*.parquet")
.filter(
(pl.col("white_elo") >= 1800) & (pl.col("white_elo") < 1900) &
(pl.col("black_elo") >= 1800) & (pl.col("black_elo") < 1900)
)
.head(50_000)
.collect()
)
HuggingFace datasets
from datasets import load_dataset
ds = load_dataset("thomas-schweich/pawn-lichess-full", split="train", streaming=True)
for game in ds.take(5):
print(game["tokens"][:5], game["result"], game["white_elo"])
Eval coverage
Approximately 8.4% of games include Stockfish eval annotations ([%eval] from Lichess's server-side analysis). The remaining ~92% have -32768 (no annotation) for all plies. Games with evals can be filtered:
# Find games with eval annotations
df.filter(pl.col("eval").list.eval(pl.element() != -32768).list.any())
Player hashing
Usernames are hashed to uint64 via Polars' xxHash64 (pl.Series.hash(), Polars 1.39.3). Same player always maps to the same hash, enabling player-level grouping and analysis without republishing usernames. The site column (game URL) can be used to look up original usernames on Lichess.
Generation
Extracted from Lichess database dumps (CC0) using the PAWN Rust chess engine for tokenization. See scripts/extract_lichess_parquet.py in the PAWN repository.
Pipeline: zstd-compressed PGN → Rust enriched parser (single-pass extraction of moves, [%clk], [%eval], headers) → Polars DataFrame → zstd-compressed Parquet.
License
CC BY 4.0. Derived from the Lichess database, which is released under Creative Commons CC0.
- Downloads last month
- 166