Skip to content

AlexRivasMachin/2048AI

Repository files navigation

2048AI 🤖

alt text 2048AI is an artificial intelligence project that plays the popular game 2048.

Try it at: https://2048.borjagomez.eus

How to Run

Follow these steps to run 2048AI:

  1. Clone the repository to your local machine and navigate to the project directory.
git clone && cd ./2048AI
  1. Install the necessary dependencies.
npm install
  1. 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
  1. Once enviroment variable is set, you can build the project.
npm run build
  1. Use a server to serve the files, for development enviroment you can use serve.
npm install -g serve
serve -d /dist
  1. Without closing this terminal, create another one.
  2. In the new terminal navigate to the project directory using cd backend.
  3. Install the necessary dependencies.
npm install
  1. Once the dependencies are installed, you can build the project.
npm run build
  1. Finally, use node to run the backend.
export NODE_ENV=production
node ./dist/index.js
  1. The server will be running in port 3001 unless you specify another one using APP_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.

Who are we:

Sertis Members:

  • AlexRivasMachín 🌶️
  • gomezbc 🥥
  • MartinLopezDeIpina 🍍

Githubs

Portfolios

TechStack 🧰

Backend ⚙️

  • Node.js
  • Express
  • Typescript
  • LangChain
  • Docker

Frontend 💻

  • React
  • Typescript