SlideShare ist ein Scribd-Unternehmen logo
휴먼인터페이스 연구실
Human Interface Lab.
Detecting Oxymoron in a
Single Statement
Won Ik Cho
Nov. 01, 2017
Contents
• Introduction
 Word vector representation
 Word analogy test
• Proposed methods
 Oxymoron detection
 Overall scheme and flow chart
• Experiment and discussion
• Conclusion
2
Introduction
3
Introduction
• Word meaning for computers
 Use a taxonomy like WordNet that has hypernyms (is-a)
relationships and synonym sets
 Problems with discreteness
Missing nuances
Missing new words
Subjective
Requires human labor
Hard to compute
accurate word similarity
4
ex) One-hot representation
hotel = [0 0 0 … 1 0 0 … 0 0 0]
motel = [0 0 0 … 0 1 0 … 0 0 0]
≈ ?
⊥ ?
Introduction
• In statistical NLP…
5
“You shall know a word by the company it keeps” (J. R. Firth 1957:11)
1) Capture co-occurrence counts directly (count-based)
2) Go through each word of the whole corpus and
predict surrounding words of each word (direct prediction)
Introduction
• Count based vs Direct prediction
6
Word vector representation
• Basic idea
 Define a model that assigns prediction between a center
word 𝑤𝑤𝑡𝑡 and 𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐 : 𝑃𝑃(𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐|𝑤𝑤𝑡𝑡)
 Loss function 𝐽𝐽 = 1 − 𝑃𝑃(𝑤𝑤−𝑡𝑡|𝑤𝑤𝑡𝑡)
 Keep adjusting the vector representation of words to
minimize the loss
7
Feedforward neural network based LM
By Y. Bengio and H. Schwenk (2003)
Main idea of word2vec
• Mikolov et al., 2013
• Two algorithms
 Skip-grams (SG)
Predict context words given target (position independent)
 Continuous bag of words (CBOW)
Predict target word from BOW context
• Two (moderately efficient) training methods
 Hierarchical softmax
 Negative sampling
8
Main idea of GloVe
• Pennington et al., 2014
• Count-based :
 Primarily used to capture word similarities
 Do poorly on word analogy tasks
(sub-optimal vector space structure)
• Direct prediction :
 Learn word embeddings by making predictions in local
context windows
 Demonstrate the capacity to capture complex linguistic
patterns
 Fail to make use of the global co-occurrence statistics
9
How about converging advantages of each approach?
Word analogy test
• Performed to test how properly the representation
describes the relation between words
 Pennington et al.(2014)
10
Proposed methods
11
Oxymoron detection
• Detecting contradiction caused by semantic
discrepancy between a pair of words
• Includes word analogy of :
antonym/synonym(with negation) or
words with an entailment error
• Differs from detecting paradox
 “There’s a pattern of unpredictability.” (oxymoron)
 “I am a compulsive liar.” (paradox)
12
Oxymoron detection
• Basic idea
 People recognize oxymoron in a text by existence of
incongruity between words
Antonym (ex) Sugar-free/Sweet
Words with entailment error (ex) Legalized/Robbery
Synonym with negation (ex) Much/not Enough
 Finding these relations (with some structural options) in
a single statement may imply the existence of oxymoron
(especially for short sentences)
 Let’s find the relation by comparing word vector offset!
13
Proposed scheme
• Offset vector set construction
 Offset vector of word 𝑎𝑎, 𝑏𝑏 :
For word embedding function 𝐹𝐹, offset vector 𝑟𝑟𝑟𝑟𝑟𝑟𝑎𝑎,𝑏𝑏 is defined :
𝑟𝑟𝑟𝑟𝑟𝑟𝑎𝑎,𝑏𝑏 = 𝐹𝐹 𝑎𝑎 − 𝐹𝐹 𝑏𝑏
 Offset vector set for antonyms :
For antonym word pairs 𝐴𝐴𝐴𝐴𝐴𝐴, 𝑖𝑖𝑡𝑡𝑡
antonym offset vector 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖
for 𝑖𝑖𝑡𝑡𝑡
antonym pair (𝑎𝑎𝑖𝑖, 𝑏𝑏𝑖𝑖) is defined :
𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖 = 𝐹𝐹 𝑎𝑎𝑖𝑖 − 𝐹𝐹 𝑏𝑏𝑖𝑖
 𝐴𝐴𝐴𝐴𝐴𝐴 includes words with entailment error as well
 This process repeats for synonym pairs 𝑆𝑆𝑆𝑆𝑆𝑆
14
Proposed scheme
• Antonym/synonym checking
 For input word pair (𝑥𝑥, 𝑦𝑦), 𝑎𝑎𝑎𝑎𝑎𝑎(𝑥𝑥, 𝑦𝑦) is defined to check
antonymy/synonymy
 Define 𝑑𝑑𝑎𝑎𝑎𝑎𝑎𝑎,𝑖𝑖 = 𝐶𝐶𝐶𝐶𝐶𝐶(𝑟𝑟𝑟𝑟𝑟𝑟𝑥𝑥,𝑦𝑦, 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖) for cosine distance
𝐶𝐶𝐶𝐶𝐶𝐶 = 1 −
𝑢𝑢∙𝑣𝑣
𝑢𝑢 |𝑣𝑣|
 (𝑥𝑥, 𝑦𝑦) is considered as antonym if 𝑑𝑑 = 𝑚𝑚𝑚𝑚𝑚𝑚𝑖𝑖 𝑑𝑑𝑖𝑖 < 𝐷𝐷 for
threshold value 𝐷𝐷
 𝐷𝐷 is varied in an implementation
15
Proposed scheme
• Checking invalid cases
 Assumption :
(1) Only lexical words can have antonym/synonym relationship
(not grammatical)
(2) Contradict occurs if antonym indicate the same
object/situation simultaneously
 For (1), only [verbs, nouns, adjectives, adverbs] are
analyzed, with lemmatization
 For (2), dependency parsing could be applied (not in
current implementation)
16
Proposed scheme
• Negation counting
 Usually negation terms come few words before
(ex) no, not, never, n’t
 Define indicator 𝑛𝑛𝑛𝑛𝑛𝑛 as:
• For every word pair 𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 :
If 𝑎𝑎𝑎𝑎𝑎𝑎(𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗) = 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖𝑖𝑖 ≥ 0 and both 𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 are valid,
𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 are decided to be contradictory if
𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖𝑖𝑖 + 𝑛𝑛𝑛𝑛𝑛𝑛 𝑤𝑤𝑖𝑖 + 𝑛𝑛𝑛𝑛𝑛𝑛 𝑤𝑤𝑗𝑗 ≡ 1 (𝑚𝑚𝑚𝑚𝑚𝑚 2)
If any word pair is decided to be contradictory, then the
statement contains oxymoron
17
Flow chart
18
Experiment and discussion
19
Experiment
• Python coding with NLTK library (for tokenizing,
POS tagging, lemmatization)
• Pre-trained word vector based on GloVe
 Glove.6B.50d
50 dim, trained with Wikipedia 2014 and Gigaword 5
• Dataset : constructed based on manual search
 For antonym/synonym pairs
Michigan Proficiency Exams (http://www.michigan-
proficiencyexams.com/)
 For test sentences
Oxymoron List (http://www.oxymoronlist.com/)
1001 Truisms! (http://1001truisms.webs.com/truisms.htm)
20
Experiment
21
Result
• Relatively low result
 Word vector was not trained on purpose of catching
antonym/synonym relations
 Dependency parsing not applied
 Determination of proper 𝐷𝐷 value necessary
Just high 𝐷𝐷 can improperly heighten the recall, thus
F-measure or accuracy should be used as an evaluation
measure
22
Discussion
• Advantages
 Easy to construct dataset (many open sources,
manageable amount of words/phrases)
 Does not need any additional training on sentences
(depends largely on the word vector)
 Checks how the word vector captures semantic relations
• To enhance the accuracy
 Setup suboptimal 𝐷𝐷 value based on optimization such as
bisection methods (Boyd and Vandenberghe, 2004)
 Use dependency parsers (Chen, 2014; Andor, 2016) to
check if the contradictory words really indicate same
object/situation
 Use word embedding regarding antonymy
23
Future work
• Applying dependency parsing
 Calculating the distance from the root with regard to the
lexical words (e.g. Nouns)
 Checking if two words are directly dependent
24
Future work
• Using word embeddings regarding antonymy
 M. Ono, M. Miwa, and Y. Sasaki, “Word Embedding-
based Antonym Detection using Thesauri and
Distributional Information,” In Proceedings of the
Human Language Technologies: The 2015 Annual
Conference of the North American Chapter of the ACL,
2015, pp. 984–989.
 J. Kim, M. De Marneffe, and E. Fosler-Lussier, “Adjusting
Word Embeddings with Semantic Intensity Orders,” In
Proceedings of the 1st Workshop on Representation
Learning for NLP, 2016, pp. 62–69.
25
Conclusion
• Deterministic scheme to check the oxymoron and
evaluate the word vector representation
• Suitable for word vectors that capture
antonym/synonym relations
• Several advantages over other contradict detection
 Produces stable result if a few options fixed
 Does not need training
 Also tells how the other word relations are not close to
the target relations
26
Thank you!
27

Weitere ähnliche Inhalte

Ähnlich wie DETECTING OXYMORON IN A SINGLE STATEMENT

Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection TasksSneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
MLconf
 
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
csandit
 
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
cscpconf
 
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
dannyijwest
 
Noun Paraphrasing Based on a Variety of Contexts
Noun Paraphrasing Based on a Variety of ContextsNoun Paraphrasing Based on a Variety of Contexts
Noun Paraphrasing Based on a Variety of Contexts
Tomoyuki Kajiwara
 
Natural Language Processing
Natural Language ProcessingNatural Language Processing
Natural Language Processing
Toine Bogers
 
Combining Vocabulary Alignment Techniques
Combining Vocabulary Alignment TechniquesCombining Vocabulary Alignment Techniques
Combining Vocabulary Alignment Techniques
pancsurka
 
Introduction to Natural Language Processing
Introduction to Natural Language ProcessingIntroduction to Natural Language Processing
Introduction to Natural Language Processing
Pranav Gupta
 
Analyzing Arguments during a Debate using Natural Language Processing in Python
Analyzing Arguments during a Debate using Natural Language Processing in PythonAnalyzing Arguments during a Debate using Natural Language Processing in Python
Analyzing Arguments during a Debate using Natural Language Processing in Python
Abhinav Gupta
 
601-CriticalEssay-2-Portfolio Edition
601-CriticalEssay-2-Portfolio Edition601-CriticalEssay-2-Portfolio Edition
601-CriticalEssay-2-Portfolio Edition
Jordan Chapman
 
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffnL6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
RwanEnan
 
Sentiment+Analysis.ppt
Sentiment+Analysis.pptSentiment+Analysis.ppt
Sentiment+Analysis.ppt
visheshs4
 
Interactive Analysis of Word Vector Embeddings
Interactive Analysis of Word Vector EmbeddingsInteractive Analysis of Word Vector Embeddings
Interactive Analysis of Word Vector Embeddings
gleicher
 
Class14
Class14Class14
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
ijnlc
 
Fyp ca2
Fyp ca2Fyp ca2
Fyp ca2
Haha Teh
 
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIESTHE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
kevig
 
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIESTHE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
kevig
 
Sentence Processing by Muhammad Saleem.pptx
Sentence Processing by Muhammad Saleem.pptxSentence Processing by Muhammad Saleem.pptx
Sentence Processing by Muhammad Saleem.pptx
E&S Education Department, KP
 
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
Daisuke BEKKI
 

Ähnlich wie DETECTING OXYMORON IN A SINGLE STATEMENT (20)

Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection TasksSneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
Sneha Rajana - Deep Learning Architectures for Semantic Relation Detection Tasks
 
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
Analysis of lexico syntactic patterns for antonym pair extraction from a turk...
 
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
ANALYSIS OF LEXICO-SYNTACTIC PATTERNS FOR ANTONYM PAIR EXTRACTION FROM A TURK...
 
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
Ontology Matching Based on hypernym, hyponym, holonym, and meronym Sets in Wo...
 
Noun Paraphrasing Based on a Variety of Contexts
Noun Paraphrasing Based on a Variety of ContextsNoun Paraphrasing Based on a Variety of Contexts
Noun Paraphrasing Based on a Variety of Contexts
 
Natural Language Processing
Natural Language ProcessingNatural Language Processing
Natural Language Processing
 
Combining Vocabulary Alignment Techniques
Combining Vocabulary Alignment TechniquesCombining Vocabulary Alignment Techniques
Combining Vocabulary Alignment Techniques
 
Introduction to Natural Language Processing
Introduction to Natural Language ProcessingIntroduction to Natural Language Processing
Introduction to Natural Language Processing
 
Analyzing Arguments during a Debate using Natural Language Processing in Python
Analyzing Arguments during a Debate using Natural Language Processing in PythonAnalyzing Arguments during a Debate using Natural Language Processing in Python
Analyzing Arguments during a Debate using Natural Language Processing in Python
 
601-CriticalEssay-2-Portfolio Edition
601-CriticalEssay-2-Portfolio Edition601-CriticalEssay-2-Portfolio Edition
601-CriticalEssay-2-Portfolio Edition
 
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffnL6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
L6.pptxsdv dfbdfjftj hgjythgfvfhjyggunghb fghtffn
 
Sentiment+Analysis.ppt
Sentiment+Analysis.pptSentiment+Analysis.ppt
Sentiment+Analysis.ppt
 
Interactive Analysis of Word Vector Embeddings
Interactive Analysis of Word Vector EmbeddingsInteractive Analysis of Word Vector Embeddings
Interactive Analysis of Word Vector Embeddings
 
Class14
Class14Class14
Class14
 
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
A COMPUTATIONAL APPROACH FOR ANALYZING INTER-SENTENTIAL ANAPHORIC PRONOUNS IN...
 
Fyp ca2
Fyp ca2Fyp ca2
Fyp ca2
 
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIESTHE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
 
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIESTHE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
THE ABILITY OF WORD EMBEDDINGS TO CAPTURE WORD SIMILARITIES
 
Sentence Processing by Muhammad Saleem.pptx
Sentence Processing by Muhammad Saleem.pptxSentence Processing by Muhammad Saleem.pptx
Sentence Processing by Muhammad Saleem.pptx
 
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
A hybrid approach toward Natural Language Understanding (by Daisuke Bekki)
 

Mehr von WarNik Chow

2312 PACLIC
2312 PACLIC2312 PACLIC
2312 PACLIC
WarNik Chow
 
2311 EAAMO
2311 EAAMO2311 EAAMO
2311 EAAMO
WarNik Chow
 
2211 HCOMP
2211 HCOMP2211 HCOMP
2211 HCOMP
WarNik Chow
 
2211 APSIPA
2211 APSIPA2211 APSIPA
2211 APSIPA
WarNik Chow
 
2211 AACL
2211 AACL2211 AACL
2211 AACL
WarNik Chow
 
2210 CODI
2210 CODI2210 CODI
2210 CODI
WarNik Chow
 
2206 FAccT_inperson
2206 FAccT_inperson2206 FAccT_inperson
2206 FAccT_inperson
WarNik Chow
 
2206 Modupop!
2206 Modupop!2206 Modupop!
2206 Modupop!
WarNik Chow
 
2204 Kakao talk on Hate speech dataset
2204 Kakao talk on Hate speech dataset2204 Kakao talk on Hate speech dataset
2204 Kakao talk on Hate speech dataset
WarNik Chow
 
2108 [LangCon2021] kosp2e
2108 [LangCon2021] kosp2e2108 [LangCon2021] kosp2e
2108 [LangCon2021] kosp2e
WarNik Chow
 
2106 PRSLLS
2106 PRSLLS2106 PRSLLS
2106 PRSLLS
WarNik Chow
 
2106 JWLLP
2106 JWLLP2106 JWLLP
2106 JWLLP
WarNik Chow
 
2106 ACM DIS
2106 ACM DIS2106 ACM DIS
2106 ACM DIS
WarNik Chow
 
2104 Talk @SSU
2104 Talk @SSU2104 Talk @SSU
2104 Talk @SSU
WarNik Chow
 
2103 ACM FAccT
2103 ACM FAccT2103 ACM FAccT
2103 ACM FAccT
WarNik Chow
 
2102 Redone seminar
2102 Redone seminar2102 Redone seminar
2102 Redone seminar
WarNik Chow
 
2011 NLP-OSS
2011 NLP-OSS2011 NLP-OSS
2011 NLP-OSS
WarNik Chow
 
2010 INTERSPEECH
2010 INTERSPEECH 2010 INTERSPEECH
2010 INTERSPEECH
WarNik Chow
 
2010 PACLIC - pay attention to categories
2010 PACLIC - pay attention to categories2010 PACLIC - pay attention to categories
2010 PACLIC - pay attention to categories
WarNik Chow
 
2010 HCLT Hate Speech
2010 HCLT Hate Speech2010 HCLT Hate Speech
2010 HCLT Hate Speech
WarNik Chow
 

Mehr von WarNik Chow (20)

2312 PACLIC
2312 PACLIC2312 PACLIC
2312 PACLIC
 
2311 EAAMO
2311 EAAMO2311 EAAMO
2311 EAAMO
 
2211 HCOMP
2211 HCOMP2211 HCOMP
2211 HCOMP
 
2211 APSIPA
2211 APSIPA2211 APSIPA
2211 APSIPA
 
2211 AACL
2211 AACL2211 AACL
2211 AACL
 
2210 CODI
2210 CODI2210 CODI
2210 CODI
 
2206 FAccT_inperson
2206 FAccT_inperson2206 FAccT_inperson
2206 FAccT_inperson
 
2206 Modupop!
2206 Modupop!2206 Modupop!
2206 Modupop!
 
2204 Kakao talk on Hate speech dataset
2204 Kakao talk on Hate speech dataset2204 Kakao talk on Hate speech dataset
2204 Kakao talk on Hate speech dataset
 
2108 [LangCon2021] kosp2e
2108 [LangCon2021] kosp2e2108 [LangCon2021] kosp2e
2108 [LangCon2021] kosp2e
 
2106 PRSLLS
2106 PRSLLS2106 PRSLLS
2106 PRSLLS
 
2106 JWLLP
2106 JWLLP2106 JWLLP
2106 JWLLP
 
2106 ACM DIS
2106 ACM DIS2106 ACM DIS
2106 ACM DIS
 
2104 Talk @SSU
2104 Talk @SSU2104 Talk @SSU
2104 Talk @SSU
 
2103 ACM FAccT
2103 ACM FAccT2103 ACM FAccT
2103 ACM FAccT
 
2102 Redone seminar
2102 Redone seminar2102 Redone seminar
2102 Redone seminar
 
2011 NLP-OSS
2011 NLP-OSS2011 NLP-OSS
2011 NLP-OSS
 
2010 INTERSPEECH
2010 INTERSPEECH 2010 INTERSPEECH
2010 INTERSPEECH
 
2010 PACLIC - pay attention to categories
2010 PACLIC - pay attention to categories2010 PACLIC - pay attention to categories
2010 PACLIC - pay attention to categories
 
2010 HCLT Hate Speech
2010 HCLT Hate Speech2010 HCLT Hate Speech
2010 HCLT Hate Speech
 

Kürzlich hochgeladen

International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...
gerogepatton
 
22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt
KrishnaveniKrishnara1
 
The Python for beginners. This is an advance computer language.
The Python for beginners. This is an advance computer language.The Python for beginners. This is an advance computer language.
The Python for beginners. This is an advance computer language.
sachin chaurasia
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
171ticu
 
Data Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason WebinarData Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason Webinar
UReason
 
artificial intelligence and data science contents.pptx
artificial intelligence and data science contents.pptxartificial intelligence and data science contents.pptx
artificial intelligence and data science contents.pptx
GauravCar
 
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
Sinan KOZAK
 
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by AnantLLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
Anant Corporation
 
Embedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoringEmbedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoring
IJECEIAES
 
Software Quality Assurance-se412-v11.ppt
Software Quality Assurance-se412-v11.pptSoftware Quality Assurance-se412-v11.ppt
Software Quality Assurance-se412-v11.ppt
TaghreedAltamimi
 
Seminar on Distillation study-mafia.pptx
Seminar on Distillation study-mafia.pptxSeminar on Distillation study-mafia.pptx
Seminar on Distillation study-mafia.pptx
Madan Karki
 
Transformers design and coooling methods
Transformers design and coooling methodsTransformers design and coooling methods
Transformers design and coooling methods
Roger Rozario
 
Hematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood CountHematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood Count
shahdabdulbaset
 
Introduction to AI Safety (public presentation).pptx
Introduction to AI Safety (public presentation).pptxIntroduction to AI Safety (public presentation).pptx
Introduction to AI Safety (public presentation).pptx
MiscAnnoy1
 
Welding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdfWelding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdf
AjmalKhan50578
 
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURSCompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
RamonNovais6
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
Las Vegas Warehouse
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
insn4465
 
Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...
bijceesjournal
 
Mechanical Engineering on AAI Summer Training Report-003.pdf
Mechanical Engineering on AAI Summer Training Report-003.pdfMechanical Engineering on AAI Summer Training Report-003.pdf
Mechanical Engineering on AAI Summer Training Report-003.pdf
21UME003TUSHARDEB
 

Kürzlich hochgeladen (20)

International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...
 
22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt
 
The Python for beginners. This is an advance computer language.
The Python for beginners. This is an advance computer language.The Python for beginners. This is an advance computer language.
The Python for beginners. This is an advance computer language.
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
 
Data Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason WebinarData Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason Webinar
 
artificial intelligence and data science contents.pptx
artificial intelligence and data science contents.pptxartificial intelligence and data science contents.pptx
artificial intelligence and data science contents.pptx
 
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
Optimizing Gradle Builds - Gradle DPE Tour Berlin 2024
 
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by AnantLLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
 
Embedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoringEmbedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoring
 
Software Quality Assurance-se412-v11.ppt
Software Quality Assurance-se412-v11.pptSoftware Quality Assurance-se412-v11.ppt
Software Quality Assurance-se412-v11.ppt
 
Seminar on Distillation study-mafia.pptx
Seminar on Distillation study-mafia.pptxSeminar on Distillation study-mafia.pptx
Seminar on Distillation study-mafia.pptx
 
Transformers design and coooling methods
Transformers design and coooling methodsTransformers design and coooling methods
Transformers design and coooling methods
 
Hematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood CountHematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood Count
 
Introduction to AI Safety (public presentation).pptx
Introduction to AI Safety (public presentation).pptxIntroduction to AI Safety (public presentation).pptx
Introduction to AI Safety (public presentation).pptx
 
Welding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdfWelding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdf
 
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURSCompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
CompEx~Manual~1210 (2).pdf COMPEX GAS AND VAPOURS
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
 
Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...
 
Mechanical Engineering on AAI Summer Training Report-003.pdf
Mechanical Engineering on AAI Summer Training Report-003.pdfMechanical Engineering on AAI Summer Training Report-003.pdf
Mechanical Engineering on AAI Summer Training Report-003.pdf
 

DETECTING OXYMORON IN A SINGLE STATEMENT

  • 1. 휴먼인터페이스 연구실 Human Interface Lab. Detecting Oxymoron in a Single Statement Won Ik Cho Nov. 01, 2017
  • 2. Contents • Introduction  Word vector representation  Word analogy test • Proposed methods  Oxymoron detection  Overall scheme and flow chart • Experiment and discussion • Conclusion 2
  • 4. Introduction • Word meaning for computers  Use a taxonomy like WordNet that has hypernyms (is-a) relationships and synonym sets  Problems with discreteness Missing nuances Missing new words Subjective Requires human labor Hard to compute accurate word similarity 4 ex) One-hot representation hotel = [0 0 0 … 1 0 0 … 0 0 0] motel = [0 0 0 … 0 1 0 … 0 0 0] ≈ ? ⊥ ?
  • 5. Introduction • In statistical NLP… 5 “You shall know a word by the company it keeps” (J. R. Firth 1957:11) 1) Capture co-occurrence counts directly (count-based) 2) Go through each word of the whole corpus and predict surrounding words of each word (direct prediction)
  • 6. Introduction • Count based vs Direct prediction 6
  • 7. Word vector representation • Basic idea  Define a model that assigns prediction between a center word 𝑤𝑤𝑡𝑡 and 𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐 : 𝑃𝑃(𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐𝑐|𝑤𝑤𝑡𝑡)  Loss function 𝐽𝐽 = 1 − 𝑃𝑃(𝑤𝑤−𝑡𝑡|𝑤𝑤𝑡𝑡)  Keep adjusting the vector representation of words to minimize the loss 7 Feedforward neural network based LM By Y. Bengio and H. Schwenk (2003)
  • 8. Main idea of word2vec • Mikolov et al., 2013 • Two algorithms  Skip-grams (SG) Predict context words given target (position independent)  Continuous bag of words (CBOW) Predict target word from BOW context • Two (moderately efficient) training methods  Hierarchical softmax  Negative sampling 8
  • 9. Main idea of GloVe • Pennington et al., 2014 • Count-based :  Primarily used to capture word similarities  Do poorly on word analogy tasks (sub-optimal vector space structure) • Direct prediction :  Learn word embeddings by making predictions in local context windows  Demonstrate the capacity to capture complex linguistic patterns  Fail to make use of the global co-occurrence statistics 9 How about converging advantages of each approach?
  • 10. Word analogy test • Performed to test how properly the representation describes the relation between words  Pennington et al.(2014) 10
  • 12. Oxymoron detection • Detecting contradiction caused by semantic discrepancy between a pair of words • Includes word analogy of : antonym/synonym(with negation) or words with an entailment error • Differs from detecting paradox  “There’s a pattern of unpredictability.” (oxymoron)  “I am a compulsive liar.” (paradox) 12
  • 13. Oxymoron detection • Basic idea  People recognize oxymoron in a text by existence of incongruity between words Antonym (ex) Sugar-free/Sweet Words with entailment error (ex) Legalized/Robbery Synonym with negation (ex) Much/not Enough  Finding these relations (with some structural options) in a single statement may imply the existence of oxymoron (especially for short sentences)  Let’s find the relation by comparing word vector offset! 13
  • 14. Proposed scheme • Offset vector set construction  Offset vector of word 𝑎𝑎, 𝑏𝑏 : For word embedding function 𝐹𝐹, offset vector 𝑟𝑟𝑟𝑟𝑟𝑟𝑎𝑎,𝑏𝑏 is defined : 𝑟𝑟𝑟𝑟𝑟𝑟𝑎𝑎,𝑏𝑏 = 𝐹𝐹 𝑎𝑎 − 𝐹𝐹 𝑏𝑏  Offset vector set for antonyms : For antonym word pairs 𝐴𝐴𝐴𝐴𝐴𝐴, 𝑖𝑖𝑡𝑡𝑡 antonym offset vector 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖 for 𝑖𝑖𝑡𝑡𝑡 antonym pair (𝑎𝑎𝑖𝑖, 𝑏𝑏𝑖𝑖) is defined : 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖 = 𝐹𝐹 𝑎𝑎𝑖𝑖 − 𝐹𝐹 𝑏𝑏𝑖𝑖  𝐴𝐴𝐴𝐴𝐴𝐴 includes words with entailment error as well  This process repeats for synonym pairs 𝑆𝑆𝑆𝑆𝑆𝑆 14
  • 15. Proposed scheme • Antonym/synonym checking  For input word pair (𝑥𝑥, 𝑦𝑦), 𝑎𝑎𝑎𝑎𝑎𝑎(𝑥𝑥, 𝑦𝑦) is defined to check antonymy/synonymy  Define 𝑑𝑑𝑎𝑎𝑎𝑎𝑎𝑎,𝑖𝑖 = 𝐶𝐶𝐶𝐶𝐶𝐶(𝑟𝑟𝑟𝑟𝑟𝑟𝑥𝑥,𝑦𝑦, 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖) for cosine distance 𝐶𝐶𝐶𝐶𝐶𝐶 = 1 − 𝑢𝑢∙𝑣𝑣 𝑢𝑢 |𝑣𝑣|  (𝑥𝑥, 𝑦𝑦) is considered as antonym if 𝑑𝑑 = 𝑚𝑚𝑚𝑚𝑚𝑚𝑖𝑖 𝑑𝑑𝑖𝑖 < 𝐷𝐷 for threshold value 𝐷𝐷  𝐷𝐷 is varied in an implementation 15
  • 16. Proposed scheme • Checking invalid cases  Assumption : (1) Only lexical words can have antonym/synonym relationship (not grammatical) (2) Contradict occurs if antonym indicate the same object/situation simultaneously  For (1), only [verbs, nouns, adjectives, adverbs] are analyzed, with lemmatization  For (2), dependency parsing could be applied (not in current implementation) 16
  • 17. Proposed scheme • Negation counting  Usually negation terms come few words before (ex) no, not, never, n’t  Define indicator 𝑛𝑛𝑛𝑛𝑛𝑛 as: • For every word pair 𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 : If 𝑎𝑎𝑎𝑎𝑎𝑎(𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗) = 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖𝑖𝑖 ≥ 0 and both 𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 are valid, 𝑤𝑤𝑖𝑖, 𝑤𝑤𝑗𝑗 are decided to be contradictory if 𝑎𝑎𝑎𝑎𝑎𝑎𝑖𝑖𝑖𝑖 + 𝑛𝑛𝑛𝑛𝑛𝑛 𝑤𝑤𝑖𝑖 + 𝑛𝑛𝑛𝑛𝑛𝑛 𝑤𝑤𝑗𝑗 ≡ 1 (𝑚𝑚𝑚𝑚𝑚𝑚 2) If any word pair is decided to be contradictory, then the statement contains oxymoron 17
  • 20. Experiment • Python coding with NLTK library (for tokenizing, POS tagging, lemmatization) • Pre-trained word vector based on GloVe  Glove.6B.50d 50 dim, trained with Wikipedia 2014 and Gigaword 5 • Dataset : constructed based on manual search  For antonym/synonym pairs Michigan Proficiency Exams (http://www.michigan- proficiencyexams.com/)  For test sentences Oxymoron List (http://www.oxymoronlist.com/) 1001 Truisms! (http://1001truisms.webs.com/truisms.htm) 20
  • 22. Result • Relatively low result  Word vector was not trained on purpose of catching antonym/synonym relations  Dependency parsing not applied  Determination of proper 𝐷𝐷 value necessary Just high 𝐷𝐷 can improperly heighten the recall, thus F-measure or accuracy should be used as an evaluation measure 22
  • 23. Discussion • Advantages  Easy to construct dataset (many open sources, manageable amount of words/phrases)  Does not need any additional training on sentences (depends largely on the word vector)  Checks how the word vector captures semantic relations • To enhance the accuracy  Setup suboptimal 𝐷𝐷 value based on optimization such as bisection methods (Boyd and Vandenberghe, 2004)  Use dependency parsers (Chen, 2014; Andor, 2016) to check if the contradictory words really indicate same object/situation  Use word embedding regarding antonymy 23
  • 24. Future work • Applying dependency parsing  Calculating the distance from the root with regard to the lexical words (e.g. Nouns)  Checking if two words are directly dependent 24
  • 25. Future work • Using word embeddings regarding antonymy  M. Ono, M. Miwa, and Y. Sasaki, “Word Embedding- based Antonym Detection using Thesauri and Distributional Information,” In Proceedings of the Human Language Technologies: The 2015 Annual Conference of the North American Chapter of the ACL, 2015, pp. 984–989.  J. Kim, M. De Marneffe, and E. Fosler-Lussier, “Adjusting Word Embeddings with Semantic Intensity Orders,” In Proceedings of the 1st Workshop on Representation Learning for NLP, 2016, pp. 62–69. 25
  • 26. Conclusion • Deterministic scheme to check the oxymoron and evaluate the word vector representation • Suitable for word vectors that capture antonym/synonym relations • Several advantages over other contradict detection  Produces stable result if a few options fixed  Does not need training  Also tells how the other word relations are not close to the target relations 26