skip to main content
10.1145/3472538.3472595acmotherconferencesArticle/Chapter ViewAbstractPublication PagesfdgConference Proceedingsconference-collections
research-article
Open access

Fine-tuning GPT-2 on annotated RPG quests for NPC dialogue generation

Published: 21 October 2021 Publication History

Abstract

GPT-2, a neural language model trained on a large dataset of English web text, has been used in a variety of natural language generation tasks because of the language quality and coherence of its outputs. In order to investigate the usability of GPT-2 for text generation for video games, we fine-tuned GPT-2 on a corpus of video game quests and used this model to generate dialogue lines for quest-giver NPCs in a role-playing game. We show that the model learned the structure of quests and NPC dialogue, and investigate how the temperature parameter influences the language quality and creativity of the output artifacts. We evaluated our approach with a crowdsource experiment in which human judges were asked to rate hand-written and generated quest texts on language quality, coherence and creativity.

References

[1]
Prithviraj Ammanabrolu, William Broniec, Alex Mueller, Jeremy Paul, and Mark Riedl. 2019. Toward Automated Quest Generation in Text-Adventure Games. In Proceedings of the 4th Workshop on Computational Creativity in Language Generation. Association for Computational Linguistics, Tokyo, Japan, 1–12. https://www.aclweb.org/anthology/2019.ccnlg-1.1
[2]
Chris Bateman. 2007. Game writing: Narrative skills for videogames. Charles River Media.
[3]
Blizzard Entertainment. 2004. World of Warcraft. Game [PC]. Blizzard Entertainment, Irvine, California, US.
[4]
Margaret A. Boden. 2007. Creativity in a nutshell. Think 5, 15 (2007), 83–96. https://doi.org/10.1017/s147717560000230x
[5]
Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language Models are Few-Shot Learners. In Advances in Neural Information Processing Systems, H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin (Eds.), Vol. 33. Curran Associates, Inc., 1877–1901. https://proceedings.neurips.cc/paper/2020/file/1457c0d6bfcb4967418bfb8ac142f64a-Paper.pdf
[6]
Bungie. 2014. Destiny. Game [PlayStation, Xbox]. Bungie, Bellevue, Washington, US.
[7]
CCP Games. 2003. EVE Online. Game [PC]. CCP Games, Reykjavík, Iceland.
[8]
Kate Compton, Quinn Kybartas, and Michael Mateas. 2015. Tracery: an author-focused generative text tool. In International Conference on Interactive Digital Storytelling. Springer, 154–161.
[9]
Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers). Association for Computational Linguistics, Minneapolis, Minnesota, 4171–4186. https://doi.org/10.18653/v1/N19-1423
[10]
Jonathon Doran and Ian Parberry. 2011. A Prototype Quest Generator Based on a Structural Analysis of Quests from Four MMORPGs. In Proceedings of the 2nd International Workshop on Procedural Content Generation in Games (Bordeaux, France) (PCGames ’11). Association for Computing Machinery, New York, NY, USA, Article 1, 8 pages. https://doi.org/10.1145/2000919.2000920
[11]
Jason Grinblat and C. Brian Bucklew. 2017. Subverting historical cause & effect: generation of mythic biographies in Caves of Qud. In Proceedings of the 12th International Conference on the Foundations of Digital Games (Hyannis, Massachusetts). ACM, ACM, New York, NY, USA, Article 76, 7 pages. https://doi.org/10.1145/3102071.3110574
[12]
Ari Holtzman, Jan Buys, Maxwell Forbes, Antoine Bosselut, David Golub, and Yejin Choi. 2018. Learning to Write with Cooperative Discriminators. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). Association for Computational Linguistics, Melbourne, Australia, 1638–1649. https://www.aclweb.org/anthology/P18-1152
[13]
Chloé Kiddon, Luke Zettlemoyer, and Yejin Choi. 2016. Globally coherent text generation with neural checklist models. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing. 329–339.
[14]
Tassilo Klein and Moin Nabi. 2019. Learning to Answer by Learning to Ask: Getting the Best of GPT-2 and BERT Worlds. arXiv preprint arXiv:1911.02365(2019).
[15]
Quinn Kybartas and Rafael Bidarra. 2017. A Survey on Story Generation Techniques for Authoring Computational Narratives. IEEE Transactions on Computational Intelligence and AI in Games 9, 3 (9 2017), 239–253. https://doi.org/10.1109/TCIAIG.2016.2546063
[16]
Quinn Kybartas and Clark Verbrugge. 2014. Analysis of ReGEN as a graph-rewriting system for quest generation. IEEE Transactions on Computational Intelligence and AI in Games 6, 2(2014), 228–242.
[17]
Jieh-Sheng Lee and Jieh Hsiang. 2020. PatentTransformer-2: Controlling Patent Text Generation by Structural Metadata. arXiv preprint arXiv:2001.03708(2020).
[18]
Jonathan Lessard, Etienne Brunelle-Leclerc, Timothy Gottschalk, Marc-Antoine Jetté-Léger, Odile Prouveur, and Christopher Tan. 2017. Striving for Author-Friendly Procedural Dialogue Generation. In Proceedings of the 12th International Conference on the Foundations of Digital Games (Hyannis, Massachusetts) (FDG ’17). Association for Computing Machinery, New York, NY, USA, Article 67, 6 pages. https://doi.org/10.1145/3102071.3116219
[19]
O.O. Marchenko, O.S. Radyvonenko, T.S. Ignatova, P.V. Titarchuk, and D.V. Zhelezniakov. 2020. Improving Text Generation Through Introducing Coherence Metrics. Cybernetics and Systems Analysis 56, 1 (2020), 13–21.
[20]
Curtis Onuczko, Duane Szafron, Jonathan Schaeffer, Maria Cutumisu, Jeff Siegel, Kevin Waugh, and Allan Schumacher. 2007. A Demonstration of SQUEGE: A CRPG Sub-Quest Generator. In Proceedings of the Third AAAI Conference on Artificial Intelligence and Interactive Digital Entertainment(Stanford, California) (AIIDE’07). AAAI Press, 110–111.
[21]
Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners. (2019). https://github.com/openai/gpt-2. Retrieved August 31, 2020.
[22]
James Ryan, Ethan Seither, Michael Mateas, and Noah Wardrip-Fruin. 2016. Expressionist: An authoring tool for in-game text generation. In International Conference on Interactive Digital Storytelling. Springer, 221–233.
[23]
James Owen Ryan, Casey Barackman, Nicholas Kontje, Taylor Owen-Milner, Marilyn A. Walker, Michael Mateas, and Noah Wardrip-Fruin. 2014. Combinatorial dialogue authoring. In International Conference on Interactive Digital Storytelling. Springer, 13–24.
[24]
Judith van Stegeren and Mariët Theune. 2019. Narrative Generation in the Wild: Methods from NaNoGenMo. In Proceedings of the Second Workshop on Storytelling. Association for Computational Linguistics, Florence, Italy, 65–74. https://www.aclweb.org/anthology/W19-3407
[25]
Judith van Stegeren and Mariët Theune. 2020. Fantastic Strings and Where to Find Them: The Quest for High-Quality Video Game Text Corpora. In Proceedings of the 2020 Workshop on Intelligent Narrative Technologies.
[26]
Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. 2017. Attention is All you Need. In Advances in Neural Information Processing Systems, I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett(Eds.), Vol. 30. Curran Associates, Inc.https://proceedings.neurips.cc/paper/2017/file/3f5ee243547dee91fbd053c1c4a845aa-Paper.pdf
[27]
Marilyn A. Walker, Ricky Grant, Jennifer Sawyer, Grace I. Lin, Noah Wardrip-Fruin, and Michael Buell. 2011. Perceived or not perceived: Film character models for expressive NLG. In International Conference on Interactive Digital Storytelling. Springer, 109–121.
[28]
Nick Walton. 2019. AI Dungeon. Game [PC, Android, IOS]. https://www.aidungeon.io.
[29]
Lili Yao, Nanyun Peng, Weischedel Ralph, Kevin Knight, Dongyan Zhao, and Rui Yan. 2019. Plan-And-Write: Towards Better Automatic Storytelling. In Thirty-Third AAAI Conference on Artificial Intelligence (AAAI-19).
[30]
Rowan Zellers, Ari Holtzman, Hannah Rashkin, Yonatan Bisk, Ali Farhadi, Franziska Roesner, and Yejin Choi. 2019. Defending Against Neural Fake News. In Advances in Neural Information Processing Systems 32, H. Wallach, H. Larochelle, A. Beygelzimer, F. d’Alché Buc, E. Fox, and R. Garnett (Eds.). Curran Associates, Inc., 9054–9065. http://papers.nips.cc/paper/9106-defending-against-neural-fake-news.pdf

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Other conferences
FDG '21: Proceedings of the 16th International Conference on the Foundations of Digital Games
August 2021
534 pages
This work is licensed under a Creative Commons Attribution International 4.0 License.

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 21 October 2021

Check for updates

Author Tags

  1. English
  2. GPT-2
  3. MMORPG
  4. NPC dialogue
  5. Natural language generation
  6. Transformers
  7. World of Warcraft
  8. procedural content generation for games
  9. quest generation

Qualifiers

  • Research-article
  • Research
  • Refereed limited

Funding Sources

Conference

FDG'21

Acceptance Rates

Overall Acceptance Rate 152 of 415 submissions, 37%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)1,286
  • Downloads (Last 6 weeks)147
Reflects downloads up to 12 Jan 2025

Other Metrics

Citations

Cited By

View all

View Options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

HTML Format

View this article in HTML Format.

HTML Format

Login options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media