A chess engine implementation using chess.js and chessboard.js. This project aims to create a chess AI that can play against human players.
- Interactive chess board interface
- Legal move validation
- Position evaluation engine
- Responsive design
- Python Flask backend for chess engine calculations
- Move analysis and scoring
- chess.js
- chessboard.js
- jQuery
- Python 3.7+
- Flask
- Flask-CORS
-
Clone the repository:
git clone https://github.com/jorge1289/Solomon cd Solomon
-
Set up the Python environment:
# Create virtual environment python -m venv .venv # Activate virtual environment # On Windows: .venv\Scripts\activate # On macOS/Linux: source .venv/bin/activate # Install dependencies pip install flask flask-cors
-
Start the Flask server:
# Make sure you're in the project root directory python app.py
The engine will run on
http://localhost:5001
-
Start the frontend server: Using Python:
python -m http.server
Then visit
http://localhost:8000
If you have Node.js installed:
npm install -g serve serve
Open your browser to the URL it provides
======= Install a simple server: npm install -g serve Navigate to your project folder Run: serve Open your browser to the URL it provides
Solomon/
├── app.py # Flask server
├── engine/
│ ├── __init__.py
│ ├── evaluation.py # Chess position evaluation
│ ├── constants.py # Chess piece values and tables
│ └── board_utils.py # Board manipulation utilities
├── static/
│ ├── js/
│ │ ├── game.js # Game logic
│ └── css/
│ └── style.css
└── index.html
- Basic board setup and move validation
- Flask backend integration
- Position evaluation function
- Minimax algorithm implementation
- Alpha-beta pruning optimization
- Opening book integration
- Endgame tablebase integration
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the project
- Create your feature branch (
git checkout -b feature/AmazingFeature
) - Commit your changes (
git commit -m 'Add some AmazingFeature'
) - Push to the branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
This project makes use of the following open-source libraries:
- chess.js - Chess logic implementation
- chessboard.js - Chessboard UI
- jQuery - Required by chessboard.js
- Flask - Python web framework
- Flask-CORS - Cross-Origin Resource Sharing for Flask
Jorge Emanuel Nunez - [email protected]
Project Link: https://github.com/jorge1289/Solomon