Skip to content

Build Text Generator app with GPT-Neo by EleutherAI and GPT2 by OpenAI using Transformer

Notifications You must be signed in to change notification settings

marwanmusa/AI-Text-Generation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Text Generation using GPT-Neo and GPT2

Build Text Generator app with GPT-Neo by EleutherAI and GPT2 by OpenAI using Transformer.

Source :

  1. GPT-Neo : Github, HuggingFace
  2. GPT2 : Github, HuggingFace
  3. Transformers - Text Generation Strategies : HuggingFace

How to run:

  1. Clone this repository
git clone https://github.com/marwanmusa/AI-Text-Generation.git
  1. Make virtual environment on your local directory
python -m venv "your_env_name"
  1. Activate the environment
"your_env_name"/Scripts/Activate.ps1
  1. Install dependencies in requirements.txt
pip install -r path/to/requirements.txt

or if you are using pipenv, then

pipenv install -r path/to/requirements.txt
  1. Run .py files
python GPTNeo.py # for GPTNeo
python GPT2.py # for GPT2

Note
You need to adjust your torch installation version to match with your cuda toolkit version installed.

About

Build Text Generator app with GPT-Neo by EleutherAI and GPT2 by OpenAI using Transformer

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published