Presentation is loading. Please wait.

Presentation is loading. Please wait.

Opening Computational Door on Knock Knock Jokes Julia M. Taylor & Lawrence J. Mazlack Applied Artificial Intelligence Laboratory University of Cincinnati.

Similar presentations


Presentation on theme: "Opening Computational Door on Knock Knock Jokes Julia M. Taylor & Lawrence J. Mazlack Applied Artificial Intelligence Laboratory University of Cincinnati."— Presentation transcript:

1 Opening Computational Door on Knock Knock Jokes Julia M. Taylor & Lawrence J. Mazlack Applied Artificial Intelligence Laboratory University of Cincinnati

2 2 Introduction This is an initial investigation into computational humor recognition using wordplay The program  Learns statistical patterns of text  Recognizes utterances similar in pronunciation to a given word  Determines if found utterances transform a text into a joke

3 3 Restricted Domain: Knock Knock Jokes Line 1 : “Knock, Knock” Line 2 : “Who’s there?” Line 3 : any phrase Line 4 : Line 3 followed by “who?” Line 5 : One or several sentences containing  Type 1 : Line 3  Type 2 : A wordplay on Line 3  Type 3 : A meaningful response to a wordplay of Line 3 or Line 4

4 4 Restricted Domain: Knock Knock Jokes Type 1 : Line 3 --Knock, Knock --Who’s there? --Water --Water who? --Water you doing tonight? Type 2 : A wordplay on Line 3 --Knock, Knock --Who’s there? --Ashley --Ashley who? --Actually, I don’t know. Type 3 : A meaningful response to a wordplay of Line 4 --Knock, Knock --Who’s there? --Tank --Tank who? --You are welcome.

5 5 Experimental Design Training set:  66 Knock Knock jokes  Enhance similarity table of letters  Select N-gram training texts 66 texts containing wordplay from 66 training jokes Test set:  130 Knock Knock jokes  66 Non-jokes that have similar structure to Knock Knock jokes

6 6 Similarity Table Contains combination of letters that sound similar Based on similarity table of cross- referenced English consonant pairs Modified by: o translating phonemes to letters o adding vowels that are close in sound o adding other combinations of letters that may be used to recognize wordplay Segment of similarity table

7 7 Training Corpus Training texts were entered into N-gram database Nurse: I need to get your weight today. Impatient patient: 3 hours and 45 minutes.  Wordplay validation: bigram table (I need 1) (need to 1) (to get 1) (get your 1) (your weight 1) (weight today 1) (today end-of-sentence 1)  Punchline validation: trigram table (I need to 1) (need to get 1) (to get your 1) (get your weight 1) (your weight today 1) (weight today end-of- sentence 1)

8 8 How It Works Step1: joke format validation Step2: computational generation of sound-alike sequences Step3: validations of a chosen sound-alike sequence Step4: last sentence validation with sound-alike sequence

9 9 Step 1: Joke Format Validation Line 1 : “Knock, Knock” Line 2 : “Who’s there?” Line 3 : any phrase Line 4 : Line 3 followed by “who?” Line 5 : One or several sentences containing Line 3 –Knock, Knock –Who is there? –I, Felix –I, Felix who? –I, Felix-ited! –Knock, Knock –Who is there? –I, Felix –I, Felix who? –I feel excited!

10 10 Step 2: Generation of Wordplay Sequences Repetitive letter replacements of Line 3 Similarity used for letter replacements Resulting utterances are ordered according to their similarity with Line 3 Utterances with highest similarity are checked for decomposition into several words Segment of similarity table

11 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

12 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

13 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

14 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

15 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

16 16 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

17 17 Step 3: Wordplay Validation one word? if el exited divide into pairs each pair in bigram? Step 4Step 2 if el el exited NOYES NOYES

18 18 Step 2: Generation of Wordplay Sequences ae.23 ao ea ei eo ie ksh.11 lr.56 rm.44 rre.23 td.39 tth.32 tz.17 wm.44 wr.42 wwh.23

19 19 Step 3: Wordplay Validation one word? i feel excited divide into pairs each pair in bigram? Step 4Step 2 I feel feel excited NOYES NOYES

20 20 Step 4: Last Sentence Validation with Wordplay Wordplay is meaningful Could occur  In the beginning of last sentence  In the middle of last sentence  At the end of last sentence

21 21 Step 4: Last Sentence Validation with Wordplay In the beginning of sentence: i feel excited One word? (wordplay N-1, wordplay N, punch1) in trigram? (wordplay N, punch1, punch2) in trigram? Step 2joke NOYES NO Step 2

22 22 Step 4: Last Sentence Generation with Wordplay In the beginning of sentence: i feel excited Is there sentence in the training text with wordplay? YES Step 2 joke NO

23 23 Knock Knock Joke Generation --Knock, Knock --Who’s there? --Ammonia --Ammonia who? --Ammonia … Ammonia = I’m only --Knock, Knock --Who’s there? --Ammonia --Ammonia who? --Ammonia trying to be funny

24 24 Results 66 training jokes  59 jokes were recognized  7 unrecognized, no wordplay found 66 non-jokes  62 correctly recognized as non-jokes  1 found wordplay that makes sense  3 incorrectly recognized as jokes 130 test jokes  8 jokes were not expected to be recognized  12 identified as jokes with expected wordplay  5 identified as jokes with unexpected wordplay  80 expected wordplays found

25 25 Possible Enhancements Improve last sentence validation  Increasing size of text used for N-gram training  Parser  N-grams with stemming Improve wordplay generator  Use of phoneme comparison Use wider domain  All types of Knock Knock jokes  Other types of wordplay jokes

26 26 Conclusion Initial investigation into KK joke recognition using wordplay The program was designed to  Recognize wordplay in KK jokes 67%  Recognize KK jokes containing wordplay 12% Alternate result of this program  KK joke generator


Download ppt "Opening Computational Door on Knock Knock Jokes Julia M. Taylor & Lawrence J. Mazlack Applied Artificial Intelligence Laboratory University of Cincinnati."

Similar presentations


Ads by Google