Created by and forked from https://github.com/SnowCheetos/CassMantle
Play here! Inspired by pimantle, but with images (potentially soundtracks) and powered by a ton of AI!
You are required to guess the missing parts of the prompt (semi-randomly generated by a language model) given a blurred image (generated from the previously generated prompt with a diffusion model). The closer your guesses are to the actual answers, the less blurry the image gets! Prompts and images update every 15 minutes (as of now).
The prompts are generated in sequential fashion. A seed prompt (story name) is used to generate the first prompt, all episodes after will use the previous prompt as its seed prompt, until the maximum number of episodes are reached.
- Get a Hugging Face API key
- Put the APK_KEY contents in api_key.txt
# setup up python virtual environment
python -m venv venv
# activate virtual environment
source venv/bin/activate
# install requirements
pip install -r requirements.txt
# download NTLTK dependencies
python download_model.py
# serve application
uvicorn main:app --host 0.0.0.0 --port 8000
# setup up python virtual environment
python -m venv venv
# activate virtual environment
source venv/bin/activate
# install requirements
pip install -r requirements.txt
# download NTLTK dependencies
python download_model.py
# deactivate virtual environment
deactivate
# run redis container
docker run -d -p6379:6379 redis
# build image and run CassMantle
docker build -t cassmantle .
docker run cassmantle -p '8000:8000'
# setup up python virtual environment
python -m venv venv
# activate virtual environment
source venv/bin/activate
# install requirements
pip install -r requirements.txt
# download NTLTK dependencies
python download_model.py
# deactivate virtual environment
deactivate
# build image and run CassMantle
docker build -t cassmantle .
docker-compose up -d
Add the following to your site configuration file (sometimes located in /etc/nginx/sites-available/your-domain-name-here) within the server {} nesting:
location /clock {
proxy_pass http://127.0.0.1:8000/clock;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
}
location /app/cassmantle/ {
proxy_pass http://127.0.0.1:8000/;
proxy_set_header Host $host;
}
Test configuration and restart nginx
# nginx -t && nginx -s reload