This is a GPT-2 model fine-tuned on Western zodiac signs. For more information about GPT-2, take a look at 🤗 Hugging Face's GPT-2
model card. You can use astroGPT to generate a daily horoscope by entering the current date.
1from transformers import AutoTokenizer, AutoModelWithLMHead
2
3tokenizer = AutoTokenizer.from_pretrained("stevhliu/astroGPT")
4model = AutoModelWithLMHead.from_pretrained("stevhliu/astroGPT")
5
6input_ids = tokenizer.encode('Sep 03, 2020', return_tensors='pt').to('cuda')
7
8sample_output = model.generate(input_ids,
9 do_sample=True,
10 max_length=75,
11 top_k=20,
12 top_p=0.97)
13
14print(sample_output)
astroGPT inherits the same biases that affect GPT-2 as a result of training on a lot of non-neutral content on the internet. The model does not currently support zodiac sign-specific generation and only returns a general horoscope. While the generated text may occasionally mention a specific zodiac sign, this is due to how the horoscopes were originally written by it's human authors.
The data was scraped from
Horoscope.com and trained on 4.7MB of text. The text was collected from four categories (daily, love, wellness, career) and span from 09/01/19 to 08/01/2020. The archives only store horoscopes dating a year back from the current date.
The text was tokenized using the fast GPT-2 BPE
tokenizer. It has a vocabulary size of 50,257 and sequence length of 1024 tokens. The model was trained with on one of Google Colaboratory's GPU's for approximately 2.5 hrs with
fastai's learning rate finder, discriminative learning rates and 1cycle policy. See table below for a quick summary of the training procedure and results.