GPT-2 User Interface based on HuggingFace's Pytorch Implementation
This repository uses HuggingFace's GPT2 Implementation and exposes an creates a nice user interface for testing GPT2 power. Even though it may not be exactly as good as authors' original tensorflow implementation, it still surprises sometimes.
Update: Only GPT-2 Small (117M paramter) model is supported on Cloud Run. Medium/Large or XL cannot be run on Cloud Run due to memory limits.
To get started on this project, follow these steps:
git clone https://github.com/NaxAlpha/gpt-2xy.git
and cd gpt-2xy
pip install -r requirements.txt
python main.py
http://localhost:8080/
Microsoft and Google
and press GENERATE TEXT
You may also want to build and run this project in docker container
docker build -t gpt-2xy .
(will take some time)docker run -p 8080:8080 --rm -d gpt-2xy
If successful, you will see something like this:
This repository contains code for my medium tutorial on Deploy Machine Learning Model in Google Cloud using Cloud Run