Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

NLP classify sentences/paragraph as funny

Is there a way to classify a particular sentence/paragraph as funny. There are very few pointers as to where one should go further on this.

like image 678
Sundarram P.V. Avatar asked Feb 14 '09 11:02

Sundarram P.V.


2 Answers

There is research on this, it's called Computational Humor. It's an interdisciplinary area that takes elements from computational linguistics, psycholinguistics, artificial intelligence, machine learning etc. They are trying to find out what it is that makes stories or jokes funny (e.g. the unexpected connection, or using a taboo topic in a surprising way etc) and apply it to text (either to generate a funny story or to measure the 'funniness' of text).

There are books and articles about it (e.g. by Graeme Ritchie).

like image 73
Frank Avatar answered Nov 18 '22 03:11

Frank


Yes, you should use a Training Corpora to build a predictive model able to detect funny sentences. Sometimes this is known as "Sentiment Analysis" in the literature. Take a look at this article about Sentiment Analysis with LingPipe.

If you can use Java, you can use their library (see license matrix). I found it very useful, not exactly in the same context than you.

like image 5
Guido Avatar answered Nov 18 '22 03:11

Guido