Opening-Database / README.md
Rafs-an09002's picture
Create README.md
8083cbb verified
|
raw
history blame
2.01 kB
metadata
license: cc0-1.0
task_categories:
  - reinforcement-learning
  - tabular-classification
language:
  - en
tags:
  - chess
  - opening-theory
  - lichess
  - elite-games
  - gambitflow
size_categories:
  - 1M<n<10M
pretty_name: 'GambitFlow: Elite Chess Opening Theory'

♟️ GambitFlow: Elite Opening Theory (2000+ Elo)

📊 Dataset Overview

This dataset serves as the "Opening Memory" for the GambitFlow AI project (Synapse-Edge). It contains millions of chess positions extracted exclusively from Elite Level Games (Elo 2000+) played on Lichess.

The goal is to provide the AI with Grandmaster-level intuition during the opening phase, preventing early positional disadvantages.

  • Source: Lichess Standard Rated Games (Jan 2017 - Apr 2024)
  • Filter: White & Black Elo ≥ 2000
  • Depth: First 35 plies (moves)
  • Format: SQLite Database (.db)

📂 Dataset Structure

The data is stored in a positions table with the following schema:

Column Type Description
fen TEXT (PK) The board position in Forsyth–Edwards Notation (Cleaned: no move counters).
move_stats JSON Aggregated statistics of moves played in this position by elite players.

Example move_stats JSON:

{
  "e4": 15400,
  "d4": 12300,
  "Nf3": 5000
}

🛠️ Usage

import sqlite3
import json

conn = sqlite3.connect("opening_theory_v1.db")
cursor = conn.cursor()

# Get stats for the starting position
start_fen = "rnbqkbnr/pppppppp/8/8/8/8/PPPP1PPP/RNBQKBNR w KQkq - -"
cursor.execute("SELECT move_stats FROM opening_book WHERE fen=?", (start_fen,))
stats = json.loads(cursor.fetchone()[0])

print("Most popular elite move:", max(stats, key=stats.get))

⚖️ Credits & License

  • Raw Data: Lichess Open Database
  • Processed By: GambitFlow Team
  • License: CC0 1.0 Universal (Public Domain)

We gratefully acknowledge Lichess.org for providing open access to millions of chess games.