A template for building AI apps. Flask & Gunicorn backend with a Nextjs frontend.
git clone https://github.com/chalabi2/ai-app-template.git
Nextjs app with shadcn/ui, queries the backend for image processing.
- Node.js
- npm
cd frontend
npm install
cp .env.example .env
npm run dev
The frontend is deployed to vercel. Be sure to add the environment variables to the vercel project and double check your auth sources redirects are set correctly.
Flask app with a pipeline from Huggingface.
- Python
- pip
cd backend
python -m venv venv
venv\Scripts\activate ## or on mac source venv/bin/activate
pip install -r requirements.txt
flask run
We containerize the python server with docker and use cloudflare to reverse proxy the Akash deployment to our domain. Within the backend directory you will find a deploy.yml
file for deploying the container to akash. Be sure to change the image to your own docker hub account. The dockerfile and various other deployment related files can be found in the backend as well.