CoolFace
Apppublic

Mrtiger007/Chess-game

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes
App README

♟️ Chess Game with Adaptive AI

Chess Game Demo

An interactive chess game with three AI difficulty levels, created by Akhilesh Kumar Tiwari. Play against a computer opponent that adapts to your skill level.

🌟 Features

AI Difficulty Levels

  • —Easy: Perfect for beginners (makes occasional mistakes)
  • —Medium: Balanced challenge (uses basic strategies)
  • —Hard: Advanced opponent (minimax algorithm with alpha-beta pruning)

Game Features

  • —Standard chess rules enforcement
  • —Real-time board visualization
  • —Move validation with helpful hints
  • —Computer thinking time display
  • —Responsive web interface

🚀 How to Play

  1. 1.Select your difficulty level
  2. 2.Enter moves in algebraic notation (e.g., e4, Nf3, O-O)
  3. 3.Press Enter or click "Make Move"
  4. 4.Computer responds automatically
  5. 5.Use "New Game" to reset anytime

Quick Move Reference

Move TypeExamples
Basic movese4, Nf3, Bb5
Capturesexd5, Nxe5
CastlingO-O, O-O-O
ChecksQh5+, Bxf7+
CheckmateQh7#, Nf7#
Promotione8=Q, a1=N

🛠️ Technical Details

AI Implementation

  • —Easy: Random moves with occasional blunders
  • —Medium: Piece-value evaluation with simple tactics
  • —Hard: Minimax algorithm (depth=2) with alpha-beta pruning

Requirements

  • —Python 3.9+
  • —gradio for the web interface
  • —python-chess for game logic
  • —stockfish recommended for optimal hard-level play

📦 Deployment

This space is deployed using:

  • —Gradio SDK v5.35.0
  • —Docker container with Stockfish support
  • —Custom chess AI implementation

👨‍💻 About the Creator

Akhilesh Kumar Tiwari Chess enthusiast and AI developer GitHub Profile Contact: akhilesh.tiwari@example.com

📜 License

MIT License - Free to use and modify