The repository contains an example application for demonstration/educational purpose.
I designed the application and replaced the other person with an AI model. I created a frontend using JavaScript and HTML. The frontend communicates with the backend, which is written in PHP, via an API. The backend generates a prompt, processes the AI's response, and sends it to the frontend to display the result.
- docker compose up
- open the following page in your browser: http://localhost:8080
- open the following page in your browser for ultimate version: http://localhost:8080/ultimate
The game is played by two people who take turns marking on X or an O on a 3x3 grid. The first person to mark three of their signs in a horizontal, vertical, or diagonal row is the winner.
See the .env variable, here you can set any LLM model or if the OPENAI_API_URL variable is empty the local minimax AI algorithm be used.
For backend run: composer test
For frontend run: npm run test-win or npm run test-unix
