Welcome to Chess Commentator, a Python-based application built with Streamlit that provides insightful commentary on chess games. This project uses the Lichess API to fetch game data, the ChatGPT API to generate commentary, and a Spring Boot application deployed on AWS Lambda to fetch pre-saved chess games and their commentaries. You can see the readme file for spring boot application from below link:
https://github.com/utkuaysev/ChessCommentator/tree/master/ChessCommentatorJavaSource
- Game Analysis: Fetch and analyze chess games using the Lichess API.
- Insightful Commentary: Receive detailed commentary on the strategic aspects of the game, generated by the ChatGPT API.
- Pre-Saved Games: Fetch pre-saved chess games and their commentaries from a Spring Boot application deployed on AWS Lambda.
- Easy to Use: Simple and user-friendly interface built with Streamlit.
- Extensible: Easily extendable to support more features in the future.
- Python 3.7 or higher
- pip
- OpenAI API key
-
Clone the repository:
git clone https://github.com/utkuaysev/ChessCommentator.git cd ChessCommentator
-
Create and activate a virtual environment (optional but recommended):
python -m venv venv source venv/bin/activate # On Windows, use `venv\Scripts\activate`
-
Install the dependencies:
pip install -r requirements.txt
-
Set up your environment variables:
- Create a
.env
file in the root directory of the project and add your OpenAI API key:API_GATEWAY_TOKEN=<> LICHESS_API_TOKEN=<>
- Create a
-
Run the Streamlit app:
streamlit run app.py
-
Fetch a Chess Game:
- Use the app interface to enter game ID to fetch and analyze the game.
-
Fetch Pre-Saved Games:
- Use the app interface to fetch pre-saved chess games and their commentaries from the AWS Lambda,DynamoDB powered Spring Boot application.
-
View Commentary:
- The application will provide detailed commentary for each move in the game, generated by the ChatGPT API.
You can directly use the application from below link:
https://chesscommentator.streamlit.app/
In this medium blog post you can see the detailed explanation about the application:
This project is licensed under the MIT License. See the LICENSE file for details.
For any questions or feedback, please reach out to:
- Victor Aysev
- GitHub Profile
- [email protected]