JU CSE NLP @ SemEval 2017 Task 7: Employing Rules to Detect and Interpret English Puns
Paper · 2017 · Aniket Pramanick and Dipankar Das
Summary
The paper describes a rule-based entry to SemEval-2017 Task 7, which asks systems to decide whether an English sentence contains a pun (Subtask 1) and, if so, which word carries it (Subtask 2). The organizers supplied no training data, so the authors assembled their own collection of 413 pun-bearing sentences, mostly from Project Gutenberg. They used it to estimate simple statistics.
Each sentence is POS-tagged with NLTK and parsed with the Stanford Parser to recover clause structure. Every word then gets a pun score built from several cues:
- a per-POS prior,
- the depth of clause nesting around it,
- its suffix,
- the tags of its neighbours,
- its position in the sentence.
Stop words are fixed at zero. The scores form a "pun vector". If the highest value exceeds 0.25, the sentence is flagged as punning and the top-scoring word is chosen as the pun.
Detection reached F1 of about 0.81 (homographic) and 0.83 (heterographic), largely thanks to high recall. Location was much weaker, at roughly 0.33–0.38. The work shows how far cheap structural heuristics can go on a task that is fundamentally about word senses.
Key points
- The test data for Subtask 1 had 2250 homographic and 1780 heterographic contexts, and each sentence holds at most one pun.
- The POS priors came from the self-collected 413 sentences:
- noun 0.1538, adjective 0.1111, verb 0.0806, other words 1/(sentence length);
- 30 of 195 nouns in that set were puns.
- Clauses were sorted into three types by how they nest. Words in Type 3 clauses (the outermost) scored about 0.1 higher.
- Smaller boosts came from several cues:
- 0.01 for an "-ing"/"-ed" ending;
- 0.01–0.02 depending on the tag of the previous or next word, with wrap-around;
- 0.02 for sentence-final position.
- Results:
- Subtask 1: P 0.7251/0.7369, R 0.9079/0.9402, F1 0.8063/0.8261 (homographic/heterographic);
- Subtask 2: P = R = F1 0.3348/0.3792, with full coverage.
Interesting ideas
- I1. The system produces a per-word score vector and then makes a single argmax decision with a threshold, so the same structure both detects the phenomenon and locates the word.
- I2. Function words and "be"-verbs are excluded outright with a hard zero before any statistics apply, which shrinks the candidate space cheaply and transparently.
- I3. Clause nesting depth taken from the parse is used as a salience signal, on the observation that words in outer, embedding clauses are likelier to carry the joke.
- I4. Without any supplied training data, the authors built a small corpus by hand and derived human-readable priors from it, rather than training an opaque model.
- I5. Sentence-final position and suffix cues act as cheap positional and morphological evidence for a semantic phenomenon.
For Mova
How these ideas could serve Mova, our small open language model — its files, stages and tests:
- I1 (frames): The irony/implicature module could score each token as a candidate trigger and expose the full vector, so a reader can see why one word won and another lost.
- I2 (frames): Pun or wordplay candidates could be restricted to content lemmas from the UD tree (NOUN/ADJ/VERB, excluding copula
copandaux), keeping the rule explicit rather than learned. - I3 (frames): Depth of
ccomp/advcl/conjnesting in the UD tree could serve as an explainable feature for where the punchline or focus of an utterance sits. - I4 (learn): Small curated sets can yield inspectable count-based priors that seed rule weights. These priors should be checked against negative controls, since the paper's high recall and weak location score hint at overfit thresholds.
- I5 (tokens): Morphology output (suffix, -ing/-ed participles) and token position could be passed upward as explicit features, so later stages can cite them as reasons.
Institutions
Fields, topics and concepts
📚 Shelves 4The field of science this work belongs to (OpenAlex fields).Computer Science · 16,667 worksArtificial Intelligence · 16,194 worksArts and Humanities · 16,039 worksLanguage and Linguistics · 15,891 works
🧭 Topics 1Research subjects and languages the work is about.English · 2,263 works
Cite
Cite as Aniket Pramanick and Dipankar Das. 2017. JU CSE NLP @ SemEval 2017 Task 7: Employing Rules to Detect and Interpret English Puns. Proceedings of the 11th International Workshop on Semantic Evaluation (SemEval-2017).
@inproceedings{pramanick2017ju,
title = {{JU CSE NLP @ SemEval 2017 Task 7: Employing Rules to Detect and Interpret English Puns}},
author = {Aniket Pramanick and Dipankar Das},
booktitle = {Proceedings of the 11th International Workshop on Semantic Evaluation (SemEval-2017)},
year = {2017},
doi = {10.18653/v1/s17-2073},
url = {https://doi.org/10.18653/v1/s17-2073}
}References
- Zoubin Ghahramani. 2001. An introduction to hidden Markov models and Bayesian networks. International Journal of Pattern Recognition and Artificial Intelligence 15(1):9–42. https://doi.org/10.1142/S0218001401000836. ↗
- Christian F. Hempelmann. 2003. Paronomasic Puns: Target Recoverability Towards Automatic Generation. Ph.D. thesis, Purdue University, West Lafayette, IN. find
- Tristan Miller and Iryna Gurevych. 2015. Automatic disambiguation of English puns. In The 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing of the Asian Federation of Natural Language Processing: Proceedings of the Conference. volume 1, pages 719–729.
- Tristan Miller, Christian F. Hempelmann, and Iryna Gurevych. 2017. SemEval-2017 Task 7:Detection and interpretation of English puns. In Proceedings of the 11th International Workshop on Semantic Evaluation (SemEval-2017).
- Kristina Toutanova, Dan Klein, Christopher D. Manning, and Yoram Singer. 2003. Feature-rich part-of-speech tagging with a cyclic dependency network. In Proceedings of the 2003 Conference of the North American Chapter of the Association for Computational Linguistics on Human Language Technology. volume 1, pages 173–180. https://doi.org/10.3115/1073445.1073478. ↗
Updated
This page in Markdown → https://md.research.elamur.ai/free/en/papers/pramanick-2017-ju-cse-nlp-semeval-2017/