Fall 2023 Class At Columbia. Modern Recommendation Systems
must have docker
and docker-compose
installed. You can go to docker's website
to download the latest version of docker
(comes with compose). Once you install it, you'll need to click on the application to run it.
Running the docker app will add docker
and docker-compose
to your PATH so you can run those commands on your terminal
To do everything at once, open up a terminal and run the following command:
./docker_compose_run_setup_db.sh
The website will be at http://127.0.0.1:3007/feed
You must wait to see "FULLY DONE INSTANTIATION USE THE APP" to finish, you can comment out before_first_request if you don't need it
If you want to see the API docs, you can go to http://localhost:5004/doc
You can use control-c
to kill the local servers
If you don't want to re-seed the DB, you can:
docker-compose -f docker-compose.full_db.yaml up --build
If you get errors, you may need to install git lfs:
If you're running mac and have HomeBrew installed, then you can run brew install git-lfs
You NEED to download git lfs
. Go to https://git-lfs.github.com/ and download/install git lfs.
Then clone the repo (AFTER you have installed git lfs)
Clone repo
git clone https://github.com/kennethgoodman/Columbia-E4579.git
Then cd into the directory and run git lfs
git lfs install && git lfs pull
If you don't want to download git lfs, you can download directly from github or drive and place it in the right spot (services/db/02_rest.sql)
docker-compose down
docker-compose build --no-cache
docker-compose up
For instance, the api backend
docker-compose -f docker-compose.full_db.yaml up --build api
If you want to access the database in a mysql CLI, you can run the following command while docker-compose up
is running:
docker-compose exec api-db mysql --password=mysql api_dev
docker-compose exec api python manage.py shell
docker-compose exec api /bin/bash
docker-compose exec api python manage.py recreate_db
docker-compose exec api python manage.py seed_db
Run the scripts/deploy_frontend.sh
docker-compose -f docker-compose.prod.yml up --build
- testdrivenio for a template for docker + flask + react
- Aveek-Saha for their scripts to download movie scripts
- lexica.art for their collection of prompts/images to use as inspiration
- Reddit and all their users for allowing the ability to programmattically download user titles/prompts
- @SamuelSacco for their work on the frontend