Skip to content

yusuf-bot/chessler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chessler

Train your mind's eye. A chess visualization trainer with adjustable Stockfish opponents and blindfold exercise modes.

Overview

Chessler is a web-based chess training tool that combines a full-featured chess engine with targeted exercises to improve board visualization. It wraps Stockfish with tunable ELO levels (400-2400) and provides a blindfold training system where pieces can be hidden to force mental visualization.

Features

  • Play against Stockfish at any ELO from 400 (beginner) to 2400+ (grandmaster)
  • Blindfold training — hide your pieces, opponent's pieces, or both during play
  • Visualization exercises:
    • Square Color — identify light/dark squares by name
    • Diagonals — name both diagonals for any square
    • Knight Attack — find all knight jump targets
    • Piece Tours — navigate a piece from A to B blindfolded
    • Knight vs Queen — navigate around queen attack patterns
  • Game analysis — Python CLI tool that replicates chess.com CAPS2-style move classification
  • Adjustable difficulty — three tiers per exercise (beginner, intermediate, advanced)
  • Progress tracking — scores saved to local storage

Quick Start

Prerequisites

  • Stockfish installed at /usr/games/stockfish
  • Go 1.22+ (for building from source)
  • Docker + Docker Compose (optional, for containerized deployment)

Run with Docker Compose

cd app
docker compose up --build

Open http://localhost:8009

Run from source

cd app
go run server.go

Using the CLI analyzer

pip install chess
python chess_analyzer.py game.pgn

Project Structure

chessler/
├── app/                    Web application
│   ├── server.go           Go HTTP server + Stockfish wrapper
│   ├── go.mod              Go module definition
│   ├── Dockerfile          Container build
│   ├── docker-compose.yml  Docker Compose config
│   └── public/             Frontend assets
│       ├── index.html      Single-page app
│       ├── css/style.css   Styles (298 lines)
│       └── js/             JavaScript modules
│           ├── engine.js   Chess move generation + rules
│           ├── game.js     Game state + Stockfish API calls
│           ├── nav.js      Navigation
│           ├── utils.js    Utilities
│           ├── exercises.js Exercise hub
│           └── exercises/  Exercise modules (ex1-ex6)
├── chess_analyzer.py       CLI game analysis tool
├── game_1.pgn              Sample game
├── real_game.pgn           Sample game
├── .gitignore
├── LICENSE
└── README.md

Tech Stack

  • Backend: Go 1.22, Stockfish chess engine
  • Frontend: Vanilla JavaScript, CSS
  • Analysis: Python 3, python-chess, Stockfish
  • Deployment: Docker, Docker Compose

API

The backend exposes two endpoints:

  • POST /api/move — Send FEN position and desired ELO, get best move back

    {"fen": "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1", "elo": 1000}

    Response: {"bestmove": "e2e4"}

  • GET /health — Health check

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors