Automating Humor: A Novel Approach to Joke Generation Using Template Extraction and Infilling

Mayank Goel, Parameswari Krishnamurthy, Radhika Mamidi


Abstract
This paper presents a novel approach to humor generation in natural language processing by automating the creation of jokes through template extraction and infilling. Traditional methods have relied on predefined templates or neural network models, which either lack complexity or fail to produce genuinely humorous content. Our method introduces a technique to extract templates from existing jokes based on semantic salience and BERT’s attention weights. We then infill these templates using advanced techniques, through BERT and large language models (LLMs) like GPT-4, to generate new jokes. Our results indicate that the generated jokes are novel and human-like, with BERT showing promise in generating funny content and GPT-4 excelling in creating clever jokes. The study contributes to a deeper understanding of humor generation and the potential of AI in creative domains.
Anthology ID:
2024.icon-1.51
Volume:
Proceedings of the 21st International Conference on Natural Language Processing (ICON)
Month:
December
Year:
2024
Address:
AU-KBC Research Centre, Chennai, India
Editors:
Sobha Lalitha Devi, Karunesh Arora
Venue:
ICON
SIG:
Publisher:
NLP Association of India (NLPAI)
Note:
Pages:
442–448
Language:
URL:
https://aclanthology.org/2024.icon-1.51/
DOI:
Bibkey:
Cite (ACL):
Mayank Goel, Parameswari Krishnamurthy, and Radhika Mamidi. 2024. Automating Humor: A Novel Approach to Joke Generation Using Template Extraction and Infilling. In Proceedings of the 21st International Conference on Natural Language Processing (ICON), pages 442–448, AU-KBC Research Centre, Chennai, India. NLP Association of India (NLPAI).
Cite (Informal):
Automating Humor: A Novel Approach to Joke Generation Using Template Extraction and Infilling (Goel et al., ICON 2024)
Copy Citation:
PDF:
https://aclanthology.org/2024.icon-1.51.pdf