2048AI is an artificial intelligence project that plays the popular game 2048.
Try it at: https://2048.borjagomez.eus
Follow these steps to run 2048AI:
- Clone the repository to your local machine and navigate to the project directory.
git clone && cd ./2048AI
- Install the necessary dependencies.
npm install
- Once the dependencies are installed. Set
VITE_API_HOST
enviroment variable to the host of the backend. Don't use/
at the end of the host. Example in Linux:
export VITE_API_HOST=https://localhost:3001
- Once enviroment variable is set, you can build the project.
npm run build
- Use a server to serve the files, for development enviroment you can use serve.
npm install -g serve
serve -d /dist
- Without closing this terminal, create another one.
- In the new terminal navigate to the project directory using
cd backend
. - Install the necessary dependencies.
npm install
- Once the dependencies are installed, you can build the project.
npm run build
- Finally, use node to run the backend.
export NODE_ENV=production
node ./dist/index.js
- The server will be running in port
3001
unless you specify another one usingAPP_PORT
enviroment variable.
Please note that these instructions assume you have Node.js and npm installed on your machine. If you don't, you'll need to install those first.
- AlexRivasMachín 🌶️
- gomezbc 🥥
- MartinLopezDeIpina 🍍
- Node.js
- Express
- Typescript
- LangChain
- Docker
- React
- Typescript