Git Product home page Git Product logo

games-ai's Introduction

Games AI

What is it?

This is a backend web service using FastAPI that facilitates the interaction between strategy game AI bots and the user interface located at http://play.gamesai.co.in

While the web app is built in python, the AI Bot itself is coded in c++ due to its better performance. Bridging of python and cpp was achieved by ctypes. More about it here.

The AI bot utilizes the minimax search, an algorithm that formed the basis of Deep Blue's victory over Kasparov, a renowned chess grandmaster.

The UI itself is a seperate reactjs web application - https://github.com/cant12/games-ai-UI

How do I set up?

Create and activate a virtual environment with python 3.11, preferably using conda. One can install conda by following the steps here

conda create -n games-ai python=3.11
conda activate games-ai

Install python requirements

pip install -r requirements.txt

Launch the application using the launch script

./launchscript.sh

Note: Make sure that g++ compiler is installed. This is required to compile the c++ component of the code.

How do I deploy?

The web server is currently hosted in the aws ec2 instance. At this stage, the deployment is mostly mannual. We might automate it based on future needs.

Get the permission file ("games-ai-key-pair.pem") from the owner and save it in your .ssh folder.

Then, login to the ec2 machine using the following command

./gamesai-ssh

Once you are in, pull the latest code and restart the server using the following steps

cd /opt/games-ai

git checkout main
git pull origin main

pm2 restart GamesAIBackend

games-ai's People

Contributors

veeramakalivignesh avatar

Watchers

Lucian avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.