Skip links
Main content

Semantic representation

woensdag 26 december 2012 11:27

Attaching semantics to parsed sentence is quite a task, but the real challange is to choose the right type of semantic representation. A representation that can be used in all types of sentences.

John laughed nervously

A simple sentence consists of a noun and a verb:

John laughed.

This sentence describes an action.

The semantics of this sentence can be expressed like this:

laugh(john)

This is a correct representation of the sentence, but it's not complete, because it doesn't express the fact that the event occurred in the past. Let's fix that:

laughed(john)

This is better, but it's also worse. Since everything you would want to do with the laugh predications would need to take into account that there are multple representations of laugh

laugh(john), laughed(john), used_to_be_laughing(john), will_laugh(john)

And what if you want to say something about the way John laughed? Maybe he laughed nervously?

laughed_nervously(john)

This obviously won't do. What's wrong with it? Well, the event of laughing is not expressed explicitly. Let's make that change [Alshawi-1992]:

∃e1 laugh(e1, john) ∧ past(e1) ∧ nervous(e1)

There is also another possible representation [Jurafsky and Martin-2000]:

∃e1 isa(e1, Laugh) ∧ laugher(e1, john) ∧ past(e1) ∧ nervous(e1)

For my own application I used a modification of the second representation that looks like this:

∃e1 isa(e1, Laugh) ∧ subject(e1, john) ∧ tense(e1, Past) ∧ isa(e1, Nervous)

I don't use laugh(e1, john) because it contains two pieces of information: laugh and john, and this makes semantic attachment more complicated. For the same reason I don't use laugher(e1, john). Using my representation, each semantic attachment contains only a single piece of information. This means that I will not need to access other nodes in the syntax tree to make an attachment. You'll notice that the predicates in my representation are all very generic.

It's very important to make events first-order objects in your representation. Even though it seems awkward at first, sooner or later you get into trouble if you don't. I end this part with the following sentence:

John laughed nervously when he heard the news.
∃e1,e2,o1 isa(e1, Laugh) ∧ subject(e1, john) ∧ tense(e1, Past) ∧ isa(e1, Nervous) 
∧ at(e1, e2) ∧ isa(e2, Hear) ∧ subject(e2, john)
∧ object(e2, o1) ∧ isa(o1, News) ∧ determiner(o1, The)

The sentence contains a relative clause that itself descibes an event (he heard the news). To link both events of laugh and heard, the events need to be represented as events explicitly.

How old is John?

Other sentences don't describe events, they describe states.

How old is John?

A first quess would be

old(john)

But where so we leave how? What about this representation?

∃o1,m1 be(john, o1) ∧ old(o1) ∧ manner(o1, m1)

In this representation be is used a verb, just like laugh in the example above. We introduce the predicate manner to represent how.

The representation may be very tempting, because it allows you to use be like any other verb. It also allows you to use old as a noun.

There are two things about this representation. The first is that it will horrify both linguists and logicians, because you use a copula (is) like a main verb. But if that doesn't bother you, you may try and have a go at this sentence:

How old was John when he heard the news?

You run into deep trouble. The relative clause cannot be linked to the main clause.

In order to fix this, let's make the state a first-order object [Alshawi-1992]:

∃s1 old(s1, john)

and we can add how by adding manner:

∃s1,m1 old(s1, john) ∧ manner(s1, m1)

Now this sentence says: There is a state in which John is old and what we ask is the manner of this state. And the relative clause when he heard the news may be represented easily in the way we did it in the John laughed example.

States and events can be treated in the same way when linking predications. I myself just call them both events. My own representation is

∃e1,m1 isa(e1, Old) ∧ subject(e1, john) ∧ manner(e1, m1)

References

[Jurafsky and Martin-2000] Speech and Language Processing - Daniel Jurafsky and James H. Martin
[Alshawi-1992] The Core Language Engine - Hiyan Alshawi, ed.

Labels
nlp

« Terug

Reacties op 'Semantic representation'

cheap oakley sunglasses
Geplaatst op: 26-06-2013 15:42 Quote
These are in fact enormous ideas in regarding blogging. You have touched some pleasant things here. Any way keep up wrinting.<a href="http://www.ideavelopers.com/tomsshoes.php">toms shoes</a>| cheap oakley sunglasses http://www.razzlewood.com/oakleysunglasses.html
toms shoes
Geplaatst op: 02-07-2013 06:32 Quote
It's perfect time to make a few plans for the long run and it is time to be happy. I have learn this put up and if I could I want to recommend you some attention-grabbing issues or suggestions. Perhaps you can write next articles regarding this article. I wish to read more things about it!| toms shoes
louboutin
Geplaatst op: 02-07-2013 12:43 Quote
Greetings! Very helpful advice within this article! It is the little changes which will make the biggest changes. Thanks a lot for sharing!| louboutin
Laura
Geplaatst op: 09-07-2013 15:57 Quote
y3 shoes - Generally I do not post on blogs, but I would like to say that this post really forecd me to do so! I found your blog on google and read a few of your other posts. I just added you to my Google News Reader. Keep up the good work. Look forward to reading more from you in the future.2009/09/17 10:29 am
Laura
Geplaatst op: 09-07-2013 15:57 Quote
y3 shoes - Generally I do not post on blogs, but I would like to say that this post really forecd me to do so! I found your blog on google and read a few of your other posts. I just added you to my Google News Reader. Keep up the good work. Look forward to reading more from you in the future.2009/09/17 10:29 am
Laura
Geplaatst op: 09-07-2013 15:57 Quote
y3 shoes - Generally I do not post on blogs, but I would like to say that this post really forecd me to do so! I found your blog on google and read a few of your other posts. I just added you to my Google News Reader. Keep up the good work. Look forward to reading more from you in the future.2009/09/17 10:29 am
Serhat
Geplaatst op: 11-07-2013 07:28 Quote
make sure to buy their vegan version not their suede insloe ones since a friend just got TOMs confirmation on pig's skin use [] Reply:September 25th, 2011 at 9:30 pmhmmm i don't think it matters if its pig skin or not correct me if I'm wrong but 7aram to eat Pigs not wear them []omarker Reply:September 26th, 2011 at 6:34 amthanks For the Tip 360dewan =DFHD ,, just why u have to wear it ?dont wear w 5alaa9 ;p[]
Serhat
Geplaatst op: 11-07-2013 07:28 Quote
make sure to buy their vegan version not their suede insloe ones since a friend just got TOMs confirmation on pig's skin use [] Reply:September 25th, 2011 at 9:30 pmhmmm i don't think it matters if its pig skin or not correct me if I'm wrong but 7aram to eat Pigs not wear them []omarker Reply:September 26th, 2011 at 6:34 amthanks For the Tip 360dewan =DFHD ,, just why u have to wear it ?dont wear w 5alaa9 ;p[]
Serhat
Geplaatst op: 11-07-2013 07:28 Quote
make sure to buy their vegan version not their suede insloe ones since a friend just got TOMs confirmation on pig's skin use [] Reply:September 25th, 2011 at 9:30 pmhmmm i don't think it matters if its pig skin or not correct me if I'm wrong but 7aram to eat Pigs not wear them []omarker Reply:September 26th, 2011 at 6:34 amthanks For the Tip 360dewan =DFHD ,, just why u have to wear it ?dont wear w 5alaa9 ;p[]
babyliss pro perfect curl
Geplaatst op: 17-09-2013 19:50 Quote
999 Try to remember Maks Erin and Maks Brandy and Maks Everyone Else?. The new York Moments has thrown us one additional curve this 7 days.
babyliss pro perfect curl
Discount Lululemon
Geplaatst op: 24-09-2013 12:49 Quote
Ders as distinct cited by his brethrr <a href="http://www.itreliance.info/itr/crm/lululemon2.html">Lululemon Yoga Pants</a> wanton fancy please nought the things that ar, <a href="http://www.primasezona.cz/files/lululemonsale.html">Lululemon Sale</a> withdrawn from and finding that the <a href="http://nileis.nilebasin.org/nileis/basketballshoes.html">Basketball Shoes For Men</a> girl remained obs.
louis vuitton outlet usa
Geplaatst op: 28-09-2013 19:36 Quote
999 During the earlier couple of decades, mobile phone components became increasingly elegant. This can be not about toss it with the wall and watch it adhere.
louis vuitton outlet usa
louis vuitton black friday 2013
Geplaatst op: 16-10-2013 16:11 Quote
333 Set the cost of a $100 enjoy as much as $150 and potential consumers will change away. When you are it a fact that the straight forward gladness of the
louis vuitton black friday 2013
wholesale cheap bills jersey
Geplaatst op: 16-10-2013 19:51 Quote
333 Put the cost of a $100 observe approximately $150 and potential customers will switch absent. While you are it valid the simple gladness of the
wholesale cheap bills jersey
black Friday ugg boots
Geplaatst op: 17-10-2013 16:49 Quote
333 Set the price of a $100 watch nearly $150 and patrons will transform absent. While you are it valid the common gladness of a
black Friday ugg boots
authentic louis vuitton outlet online
Geplaatst op: 18-10-2013 16:09 Quote
999 The invention of this new antitheft not only spectacular but also convenient. She would not discuss carats or selling price tags even though demonstrating me a hoop equivalent on the one Ponder purchased which was constructed by Precision Set.
authentic louis vuitton outlet online
ugg boots outlet store
Geplaatst op: 19-10-2013 12:53 Quote
888 If tips on how to use saree is difficult issue to suit your needs then in this article you would locate the relatively easy remedy to this query.. She was attractive in her 20s, she's attractive now and she'll be lovely twenty years from now.
ugg boots outlet store
christian louboutin factory outlet store
Geplaatst op: 21-10-2013 13:16 Quote
888 If methods to wear saree is difficult question in your case then right here you'd discover the quick remedy to this problem.. She was wonderful in her 20s, she's gorgeous now and she'll be beautiful twenty years from now.
christian louboutin factory outlet store
buy cheap ugg boots uk
Geplaatst op: 21-10-2013 16:02 Quote
888 If the best ways to wear saree is tricky concern for yourself then in this article you'd probably locate the painless respond to to this issue.. She was amazing in her 20s, she's attractive now and she'll be amazing 20 years from now.
buy cheap ugg boots uk
cheap nfl nike jerseys
Geplaatst op: 22-10-2013 15:04 Quote
888 If find out how to use saree is complex query for you personally then here you would probably find the straightforward remedy to this issue.. She was lovely in her 20s, she's magnificent now and she'll be attractive 20 years from now.
cheap nfl nike jerseys
mens ugg boots cheap
Geplaatst op: 23-10-2013 08:56 Quote
9999 The tissue while in the creases helps to reduce the emotional stress however it cannot do away with it. My cruisemate hadn't been, but feels he doesn't have got to return..
mens ugg boots cheap
cheap louis vuitton purses
Geplaatst op: 24-10-2013 14:00 Quote
999 "I hope my daughter does not study this!" states the mother of Lily.. The Damier Canvas Speedy thirty is a extremely popuar bag in Ny .
cheap louis vuitton purses
??? bl0838
Geplaatst op: 08-11-2013 22:27 Quote
Nevertheless lined up perfectly for the center. Products and solutions got errors then is actually usually definitely a fake. This leads me to second on defining a Prada bag. Isn't there always a new handbag that you require?
[url=http://www.kelownaatnight.com/prada345.html]??? bl0838[/url]
genuine bailey button ugg boots uk
Geplaatst op: 22-11-2013 05:31 Quote
999 It's really a cologne produced for guys between the ages of 35 and 53, and will be worn through the daytime. I'd move forward to invest providing practical chopping it up by using a fellow geek, every one of the while you are not advertising everything.
<a href="http://www.celticsoul.co.uk/bailey-button-ugg-boots-uk-c-2.html" >genuine bailey button ugg boots uk</a>
genuine bailey button ugg boots uk
Nieuw bericht