66
Introduction to Semantics

Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

  • Upload
    others

  • View
    6

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

IntroductiontoSemantics

Page 2: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Announcements• PartofnextTuesday’sclasswillfocusonques6onsaboutthemidterm.Pleasesendtopicsthatyouwouldliketohavere-explained.

• Othermidtermnews:Sampleques6onsprovidedbyWedofthisweek;in-classreviewin2ndhalfofnextTuesday’sclass

• Homework1sta6s6cs:• Mean:90.5• Median:94•  High:100•  Low(nonzero):45

Page 3: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Today• Reading:

•  Today:C17,SpeechandLanguage• Next6me:C19,C20.1-20.8SpeechandLanguage

• Introduc6ontoseman6cs• Whatisit?• Meaningrepresenta6ons•  Lexicalseman6cs

Page 4: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 5: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 6: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

SIRI: One shot Question and answer What’s required?

Page 7: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WatsonandjeopardyBangBang"his"Silverhammercamedownuponherhead"

Page 8: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Question-Answering/Dialog• “Match”

Page 9: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Wheredoestheinformationforanswerscomefrom?

• Databases• h\p://newyork.citysearch.com

• Theweb

• Textualresources:encyclopedias,journals,etc.

• Dic6onaries

• Inference

Page 10: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

OneViewofNLArchitecture

Syntax Semantics Morphology

Knowledge Representation/

Meaning Representation

Application output

Page 11: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

OneViewofNLArchitecture

Syntax

Semantics

Morphology

Knowledge Representation/

Meaning Representation

Application output

Page 12: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

AnotherView:UnderstandinginWatson• Massiveparallelism

•  Exploitmassiveparallelismintheconsidera6onofmul6pleinterpreta6onsandhypotheses.

• Manyexperts•  Facilitatetheintegra6on,applica6on,andcontextualevalua6onofawiderangeoflooselycoupledprobabilis6cques6onandcontentanaly6cs.

•  Pervasiveconfidenceintegra6on•  Nocomponentcommitstoananswer;allcomponentsproducefeaturesandassociatedconfidences,scoringdifferentques6onandcontentinterpreta6ons.

•  Integrateshallowanddeepknowledge•  Balancetheuseofstrictseman6csandshallowseman6cs,leveragingmanylooselyformedontologies.

Page 13: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WhatisSemantics?• MeaningRepresenta6on

• Seman6cParsingorSeman6cInterpreta6on

• Wordmeaningdisambigua6on

• Entailmentandinference

• Informa6onextrac6on

Page 14: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

MeaningRepresentation• Torepresentques6ons

• Torepresentknowledgedrawnfromtext

Page 15: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WhatCanServeasaMeaningRepresentation?

• Anythingthatallowsusto• Answerques6ons(WhatisthebestFrenchrestaurantintheEastVillage?)

• Determinetruth(IsColumbiaUnivinNYC?)• Drawinferences(IfOneDineRestaurantisonthetopfloorofoneWorldTradeCenterandoneWorldTradeCenteristhetallestbuildinginNewYorkCity,thenOneDineisthetopmostrestaurantinNewYorkCity.)

Page 16: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Whatkindsofmeaningdowewanttocapture?

•  Categories/en66es•  Gustav,Shaan,Diana,Asiancuisine,vegetarian

•  Events•  takingataxi,destruc6onofbuildingsintheBahamas

•  Time•  Oct30,nextweek,in2months

•  Aspect•  Kathyknowshowtorun.Kathyisrunning.Kathyrantotherestaurantin5min.

•  Beliefs,DesiresandInten6ons(BDI)

Page 17: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

MeaningRepresentations

• Allrepresent‘linguis6cmeaning’of Ihaveacar

andstateofaffairsinsomeworld• Allconsistofstructures,composedofsymbolsrepresen6ngobjectsandrela6onsamongthem•  FOPC:

)}(),(),()({, yCarxyHadThingxSHaverxHavingyx ∧∧∧∃

Page 18: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

AStandardRepresentation:Predicate-ArgumentStructure

•  Representsconceptsandrela6onshipsamongthem•  Nounsasconceptsorarguments(red(ball))•  Adjec6ves,adverbs,verbsaspredicates(red(ball))

•  Subcategoriza6on(or,argument)framesspecifynumber,posi6on,andsyntac6ccategoryofarguments•  NPlikesNP•  NPlikesInf-VP•  NPlikesNPInf-VP

Page 19: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Semantic(Thematic)Roles• Subcatframeslinkargumentsinsurfacestructurewiththeirseman6croles• Agent:GeorgehitBill.BillwashitbyGeorge.• Pa6ent:GeorgehitBill.BillwashitbyGeorge.

• Theclaimofatheoryofseman6crolesisthattheseargumentsofpredicatescanbeusefullyclassifiedintoasmallsetofseman6callycontenmulclasses• Andthattheseclassesareusefulforexplaininglotsofthings

Page 20: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Commonsemanticroles•  Agent:ini6atorordoerintheevent•  Pa(ent:affecteden6tyintheevent;undergoestheac6on•  Suesentthele\er.

•  Theme:objectintheeventundergoingachangeofstateorloca6on,orofwhichloca6onispredicated•  Theicemelted

•  Experiencer:feelsorperceivetheevent• Billlikespizza.

•  S(mulus:thethingthatisfeltorperceived

Page 21: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Commonsemanticroles•  Goal:

•  BillrantoCopleySquare.•  Recipient(mayormaynotbedis6nguishedfromGoal):

•  BillgavethebooktoMary.

•  Benefac(ve(maybegroupedwithRecipient):•  BillcookeddinnerforMary.

•  Source:•  Billtookapencilfromthepile.

•  Instrument:•  Billatetheburritowithaplas6cspork.

•  Loca(on:•  BillsitsunderthetreeonWednesdays

Page 22: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

CommonsemanticrolesTryforyourself!1.  Thesubmarinesankatroopship.2.  Dorishidthemoneyintheflowerpot.3.  Emmano6cedthestain.4.  Wecrossedthestreet.5.  Theboysclimbedthewall.6.  Thechefcookedagreatmeal.7.  Thecomputerpinpointedtheerror.8.  AmadbulldamagedthefenceonJack’sfarm.9.  Thecompanywrotemeale\er.10. Jackopenedthelockwithapaperclip.

Page 23: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 24: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 25: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 26: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Linkingofthematicrolestosyntacticpositions• Johnopenedthedoor• AGENTTHEME• ThedoorwasopenedbyJohn• THEMEAGENT• Thedooropened• THEME• Johnopenedthedoorwiththekey• AGENTTHEMEINSTRUMENT

Page 27: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

DeeperSemantics• FromtheWSJ…

• Hemeltedherreservewithahusky-voicedpaeantohereyes.

•  Ifwelabelthecons6tuentsHeandherreserveastheMelterandMelted,thenthoselabelsloseanymeaningtheymighthavehad.

•  IfwemakethemAgentandThemethenwecandomoreinference.

Page 28: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

SelectionalRestrictions• Selec6onalRestric6ons:constraintsonthetypesofargumentsverbstakeGeorgeassassinatedthesenator.*Thespiderassassinatedthefly.assassinate:inten5onal(poli5cal?)killing

• Theastronautmarriedthestar.

Page 29: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Problems• Whatexactlyisarole?• What’stherightsetofroles?• Aresuchrolesuniversals?• Aretheserolesatomic?

•  I.e.Agents•  Animate,Voli6onal,Directcausers,etc

• Canweautoma6callylabelsyntac6ccons6tuentswiththema6croles?

Page 30: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

FirstOrderPredicateCalculus• Notidealasameaningrepresenta6onanddoesn'tdoeverythingwewant--butbe\erthanmany…•  Supportsthedetermina6onoftruth•  Supportscomposi6onalityofmeaning•  Supportsques6on-answering(viavariables)•  Supportsinference

Page 31: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

AbstractMeaningRepresentation(AMR)• Aimingtocaptureadeeplevelofseman6cs

• Originalgoal:asinterlinguaformachinetransla6on

• Alsonowsee:AMRparsers,genera6onfromAMR,summariza6onusingAMR

Knight, AMR Release 1.0, 2014

Page 32: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

ExampleAMR• Rolesaregiventheory-neutralnames(d/describe-01•  :arg0(m/man)•  :arg1(m2/mission)•  :arg2(d/disaster))

•  :arg0thedescriber,:arg1thethingdescribed,:arg2whatitisdescribing

• Themandescribedthemissionasadisaster.Asthemandescribedit,themissionwasadisaster

Page 33: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

TemporalRepresentations• Howdowerepresent6meandtemporalrela6onshipsbetweenevents?ItseemsonlyyesterdaythatMarthaStewartwasinprisonbutnowshehasapopularTVshow.Thereisnojus6ce.

• Wheredowegettemporalinforma6on?• Verbtense•  Temporalexpressions•  Sequenceofpresenta6on

• Linearrepresenta6ons:Reichenbach‘47

Page 34: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

RepresentingTime

Example from Russell and Norvig

Page 35: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

RepresentingTime

Example from Jurafsky and Martin

Utterance time (U): when the utterance occurs Reference time (R): the temporal point-of-view of the utterance Event time (E): when events described in the utterance occur

Page 36: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

VerbsandEventTypes:Aspect•  Sta6ves:statesorproper6esofobjectsatapar6cularpointin6me

Iamhungry.• Ac6vi6es:eventswithnoclearendpoint

Iamea-ng.• Accomplishments:eventswithdura6onsandendpointsthatresultinsomechangeofstate

Iatedinner.• Achievements:eventsthatchangestatebuthavenopar6culardura6on–theyoccurinaninstant

Igotthebill.

Page 37: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Beliefs,DesiresandIntentions• Veryhardtorepresentinternalspeakerstateslikebelieving,knowing,wan6ng,assuming,imagining•  NotwellmodeledbyasimpleDBlookupapproachso..

•  Truthintheworldvs.truthinsomepossibleworldGeorgeimaginedthathecoulddance.Georgebelievedthathecoulddance.

• AugmentFOPCwithspecialmodaloperatorsthattakelogicalformulaeasarguments,e.g.believe,know

Page 38: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Believes(George,dance(George))Knows(Bill,Believes(George,dance(George)))

• Mutualbelief:IbelieveyoubelieveIbelieve….• Prac6calimportance:modelingbeliefindialogue

• Clark’sgrounding

Page 39: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

TakeAway• Seman6csmeansmanythings

• Meaningrepresenta6ons•  Seman6cparsingorseman6crolelabeling•  Determiningwordmeaning•  Useofseman6cinforma6onforanendapplica6on

•  Inference•  Temporalrela6ons:tense,aspect•  Informa6onextrac6on•  Belief,desireandintent

• Workinseman6cscanfallintoanyoftheseareas

Page 40: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

LexicalSemantics• Groundingforrepresenta6onofwordmeaning• Usedforworddisambigua6on•  Seman6cinterpreta6on

• Pre-cursortorepresenta6onsusedindistribu6onalseman6cs,vectorrepresenta6onsandneuralnets

• Topics• Homonymy,Polysemy,Synonymy• Onlineresources:WordNet

Page 41: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Preliminaries• What’saword?

• Defini6onswe’veusedovertheclass:Types,tokens,stems,roots,inflectedforms,etc...

•  Lexeme:Anentryinalexiconconsis6ngofapairingofaformwithasinglemeaningrepresenta6on

•  Lexicon:Acollec6onoflexemes

Page 42: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Relationshipsbetweenwordmeanings• Homonymy• Polysemy• Synonymy• Antonymy• Hypernomy• Hyponomy• Meronomy

Page 43: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Homonymy• Homonymy:

•  Lexemesthatshareaform•  Phonological,orthographicorboth

• Buthaveunrelated,dis6nctmeanings• Clearexamples:

•  Bat(woodens6ck-likething)vs•  Bat(flyingscarymammalthing)•  Orbank(financialins6tu6on)versusbank(riverside)

• Canbehomophones,homographs,orboth:•  Homophones:

•  Writeandright•  Pieceandpeace

Page 44: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

HomonymycausesproblemsforNLPapplications• Text-to-Speech

•  Sameorthographicformbutdifferentphonologicalform•  bassvsbass

• Informa6onretrieval• Differentmeaningssameorthographicform

•  QUERY:batcare• MachineTransla6on• Speechrecogni6on

• Why?

Page 45: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Polysemy• ThebankisconstructedfromredbrickIwithdrewthemoneyfromthebank

• Arethosethesamesense?• OrconsiderthefollowingWSJexample

• Whilesomebanksfurnishspermonlytomarriedwomen,othersarelessrestric6ve

• Whichsenseofbankisthis?•  Isitdis6nctfrom(homonymouswith)theriverbanksense?

•  Howaboutthesavingsbanksense?

Page 46: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Polysemy• Asinglelexemewithmul6plerelatedmeanings(bankthebuilding,bankthefinancialins6tu6on)

• Mostnon-rarewordshavemul6plemeanings•  Thenumberofmeaningsisrelatedtoitsfrequency

• Verbstendmoretopolysemy• Dis6nguishingpolysemyfromhomonymyisn’talwayseasy(ornecessary)

Page 47: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

MetaphorandMetonymy• Specifictypesofpolysemy• Metaphor:

• GermanywillpullSloveniaoutofitseconomicslump.

•  Ispent2hoursonthathomework.• Metonymy

•  TheWhiteHouseannouncedyesterday.•  Thischaptertalksaboutpart-of-speechtagging

• Bank(building)andbank(financialins6tu6on)

Page 48: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Howdoweknowwhenawordhasmorethanonesense?• ATISexamples

• Whichflightsservebreakfast?• DoesAmericaWestservePhiladelphia?

• The“zeugma”test:

•  ?DoesUnitedservebreakfastandSanJose?

Page 49: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Synonyms• Wordthathavethesamemeaninginsomeorallcontexts.•  filbert/hazelnut•  couch/sofa•  big/large•  automobile/car•  vomit/throwup•  Water/H20

• Twolexemesaresynonymsiftheycanbesuccessfullysubs6tutedforeachotherinallsitua6ons•  Ifsotheyhavethesameproposi(onalmeaning

Page 50: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Synonyms• Buttherearefew(orno)examplesofperfectsynonymy.• Whyshouldthatbe?•  Evenifmanyaspectsofmeaningareiden6cal•  S6llmaynotpreservetheacceptabilitybasedonno6onsofpoliteness,slang,register,genre,etc.

• Example:• WaterandH20

Page 51: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Somemoreterminology•  Lemmasandwordforms

•  Alexemeisanabstractpairingofmeaningandform•  Alemmaorcita(onformisthegramma6calformthatisusedtorepresentalexeme.

•  Carpetisthelemmaforcarpets•  Dormiristhelemmaforduermes.

•  Specificsurfaceformscarpets,sung,duermesarecalledwordforms

•  Thelemmabankhastwosenses:•  Instead,abankcanholdtheinvestmentsinacustodialaccountintheclient’sname

•  Butasagricultureburgeonsontheeastbank,theriverwillshrinkevenmore.

• Asenseisadiscreterepresenta6onofoneaspectofthemeaningofaword

Page 52: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Synonymyisarelationbetweensensesratherthanwords

• Considerthewordsbigandlarge• Aretheysynonyms?

•  Howbigisthatplane?• WouldIbeflyingonalargeorsmallplane?

• Howabouthere:•  MissNelson,forinstance,becameakindofbigsistertoBenjamin.

•  ?MissNelson,forinstance,becameakindoflargesistertoBenjamin.

• Why?•  bighasasensethatmeansbeingolder,orgrownup•  largelacksthissense

Page 53: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Antonyms• Sensesthatareoppositeswithrespecttoonefeatureoftheirmeaning

• Otherwise,theyareverysimilar!•  dark/light•  short/long•  hot/cold•  up/down•  in/out

• Moreformally:antonymscan•  defineabinaryopposi6onoratoppositeendsofascale(long/short,fast/slow)

•  Bereversives:rise/fall,up/down

Page 54: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Hyponymy• Onesenseisahyponymofanotherifthefirstsenseismorespecific,deno6ngasubclassoftheother•  carisahyponymofvehicle•  dogisahyponymofanimal•  mangoisahyponymoffruit

•  Conversely•  vehicleisahypernym/superordinateofcar•  animalisahypernymofdog•  fruitisahypernymofmango

superordinate vehicle fruit furniture mammal

hyponym car mango chair dog

Page 55: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Hypernymymoreformally• Extensional:

•  Theclassdenotedbythesuperordinate•  extensionallyincludestheclassdenotedbythehyponym

• Entailment:• AsenseAisahyponymofsenseBifbeinganAentailsbeingaB

• Hyponymyisusuallytransi6ve•  (AhypoBandBhypoCentailsAhypoC)

Page 56: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

• Whywouldhypernyms/hyponymsbeimportanttoconstruc6ngameaningrepresenta6on?

Page 57: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm
Page 58: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

II.WordNet• Ahierarchicallyorganizedlexicaldatabase• On-linethesaurus+aspectsofadic6onary

•  Versionsforotherlanguagesareunderdevelopment

Category Unique Forms

Noun 117,097

Verb 11,488

Adjective 22,141

Adverb 4,601

Page 59: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WordNet

•  Whereitis:•  h\ps://wordnet.princeton.edu/

Page 60: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

FormatofWordnetEntries

Page 61: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WordNetNounRelations

Page 62: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WordNetVerbRelations

Page 63: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

WordNetHierarchies

Page 64: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Howis“sense”deYinedinWordNet?• Thesetofnear-synonymsforaWordNetsenseiscalledasynset(synonymset);it’stheirversionofasenseoraconcept

• Example:chumpasanountomean•  ‘apersonwhoisgullibleandeasytotakeadvantageof’

•  Eachofthesesensessharethissamegloss•  ThusforWordNet,themeaningofthissenseofchumpisthislist.

Page 65: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Wordnetexample

Page 66: Introduction to Semanticskathy/NLP/2019/ClassSlides/Class12-Semantics/... · • Are those the same sense? • Or consider the following WSJ example • While some banks furnish sperm

Questions?