Borrowing heavily from these open source products
Steps:
- Run finetune_gpt2.py to train GPT2 on Grimm's fairy tales
- Run make_a_novel.py
make_a_novel.py generates a story with TextWorld and walks through a play run (that part isn't fully automated yet). It then takes the narrative from the playthrough and passes it through gpt2 to add lots of words, which are hopefully embellishments on the story thus generating a novel.
It's not very coherent yet, but ya know.
As a shortcut, if you have a gpt-2 model, and want to use the example text you should be able to just do:
import make_a_novel
make_a_novel.makethenovel()
which will load a model available to gpt-2-simple and generate text from a pre-played TextWorld output storyguide.
Check out notes here:
And the NaNoGenMo topic here: