predicate logic torbjörn lager department of linguistics stockholm university
TRANSCRIPT
Predicate Logic
Torbjörn LagerDepartment of LinguisticsStockholm University
NLP1 - Torbjörn Lager 2
Why Logic in NLP?
Account for ambiguity "Every man loves a woman"
Allow evaluation (in e.g. a database) Allow logical inference
Every man who whistles is happy John is a man John whistles Therefore: John is happy
NLP1 - Torbjörn Lager 3
A Semantic Puzzle
What's wrong with the following argument: "Nothing is better than a long and prosperous life. A ham sandwich is better than nothing. Therefore: A ham sandwich is better than a long and
prosperous life."
NLP1 - Torbjörn Lager 4
Translation Natural Language <-> Predicate Logic
John laughed <-> laughed'(j)
Nobody laughed <-> x[laughed'(x)]
NLP1 - Torbjörn Lager 5
Translate
Kalle sover Kalle är en katt Alla sover Någon sover Varje katt sover Någon katt sover Ingen sover Ingen katt sover Alla gillar någon
NLP1 - Torbjörn Lager 6
An Important Tradition
We use language to talk about the world
Semantics is something that relates sentences (or utterances) of language and the outside world
There are other ideas about meaning, but in this tradition we don't believe in them!
Language
The outside world
NLP1 - Torbjörn Lager 7
Model Theoretic Semantics
We don't know what the world is really like, so let's talk about a model of the world instead
Such a model does (usually) consists of individuals, sets of individuals, functions and relations. i.e the sort of things set theory talks about
Truth becomes truth relative to a model
Language
Model
The outside world
NLP1 - Torbjörn Lager 8
An Example Model
A simple model M: Domain:
{Socrates, Aristotle, Plato, Mozart, Beethoven, Tolstoy} Interpretation:
F(s) = Socrates F(m) = Mozart F(a) = Aristotle F(b) = Beethoven F(p) = Plato F(t) = Tolstoy F(H) = {Socrates, Aristotle, Plato} F(M) = {Socrates, Aristotle, Plato, Mozart, Beethoven, Tolstoy} F(L) = {<Socrates,Socrates>, <Socrates,Aristotle>,
<Mozart,Beethoven>, <Beethoven,Mozart>, <Tolstoy,Plato>, <Plato,Mozart>, <Aristotle,Tolstoy>}
NLP1 - Torbjörn Lager 9
NLP1 - Torbjörn Lager 10
NLP1 - Torbjörn Lager 11
NLP1 - Torbjörn Lager 12
A Semantic Puzzle
What's wrong with the following argument: "Nothing is better than a long and prosperous life. A ham sandwich is better than nothing. Therefore, a ham sandwich is better than a long and prosperous life."