SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Semantics and Pragmatics of NLP Klein Lambda Terms, Quantifiers, Satisfaction Outline Typed Lambda Calculus First Order Alex Lascarides & Ewan Klein Logic Truth and Satisfaction School of Informatics University of Edinburgh 10 January 2008 SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein 1 Typed Lambda Calculus Outline Typed Lambda Calculus 2 First Order Logic First Order Logic Truth and Satisfaction 3 Truth and Satisfaction Transitive Verbs as Functions SPNLP: Lambda Terms, Quantifiers, Satisfaction We looked at replacing n-ary relations with functions. How Lascarides & does this work with transitive verbs? Klein Outline Version 1: chase of type <IND, IND >→ BOOL Typed Lambda Version 2: chase of type IND → (IND → BOOL) Calculus First Order Logic Advantages of Version 2 (called a curryed function): Truth and Satisfaction Makes the syntax more uniform. Fits better with compositional semantics (discussed later) Transitive Verbs as Functions SPNLP: Lambda Terms, Quantifiers, Satisfaction We looked at replacing n-ary relations with functions. How Lascarides & does this work with transitive verbs? Klein Outline Version 1: chase of type <IND, IND >→ BOOL Typed Lambda Version 2: chase of type IND → (IND → BOOL) Calculus First Order Logic Advantages of Version 2 (called a curryed function): Truth and Satisfaction Makes the syntax more uniform. Fits better with compositional semantics (discussed later) Transitive Verbs as Functions SPNLP: Lambda Terms, Quantifiers, Satisfaction We looked at replacing n-ary relations with functions. How Lascarides & does this work with transitive verbs? Klein Outline Version 1: chase of type <IND, IND >→ BOOL Typed Lambda Version 2: chase of type IND → (IND → BOOL) Calculus First Order Logic Advantages of Version 2 (called a curryed function): Truth and Satisfaction Makes the syntax more uniform. Fits better with compositional semantics (discussed later) Transitive Verbs as Functions SPNLP: Lambda Terms, Quantifiers, Satisfaction We looked at replacing n-ary relations with functions. How Lascarides & does this work with transitive verbs? Klein Outline Version 1: chase of type <IND, IND >→ BOOL Typed Lambda Version 2: chase of type IND → (IND → BOOL) Calculus First Order Logic Advantages of Version 2 (called a curryed function): Truth and Satisfaction Makes the syntax more uniform. Fits better with compositional semantics (discussed later) Transitive Verbs as Functions SPNLP: Lambda Terms, Quantifiers, Satisfaction We looked at replacing n-ary relations with functions. How Lascarides & does this work with transitive verbs? Klein Outline Version 1: chase of type <IND, IND >→ BOOL Typed Lambda Version 2: chase of type IND → (IND → BOOL) Calculus First Order Logic Advantages of Version 2 (called a curryed function): Truth and Satisfaction Makes the syntax more uniform. Fits better with compositional semantics (discussed later) Lambda SPNLP: Lambda Terms, Quantifiers, Lambdas talk about missing information, and where it is. Satisfaction Lascarides & The λ binds a variable. Klein The positions of a λ-bound variable in the formula mark Outline where information is ‘missing’. Typed Lambda Calculus Replacing these variables with values fills in the First Order missing information. Logic Truth and Example: Satisfaction λx.(man x) λ-abstract (λx.(man x) john) application (man john) β-reduction/function application. Types SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein IND and BOOL are basic types. Outline If σ, τ are types, then so is (σ → τ). Brackets are Typed Lambda omitted if no ambiguity. Calculus For types τ, we have variables Var(τ), constants First Order Logic Con(τ). Truth and Satisfaction Since we are doing first order logic, we will later restrict variables to Var(IND), but allow constants of any type. Types SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein IND and BOOL are basic types. Outline If σ, τ are types, then so is (σ → τ). Brackets are Typed Lambda omitted if no ambiguity. Calculus For types τ, we have variables Var(τ), constants First Order Logic Con(τ). Truth and Satisfaction Since we are doing first order logic, we will later restrict variables to Var(IND), but allow constants of any type. Types SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein IND and BOOL are basic types. Outline If σ, τ are types, then so is (σ → τ). Brackets are Typed Lambda omitted if no ambiguity. Calculus For types τ, we have variables Var(τ), constants First Order Logic Con(τ). Truth and Satisfaction Since we are doing first order logic, we will later restrict variables to Var(IND), but allow constants of any type. Types SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein IND and BOOL are basic types. Outline If σ, τ are types, then so is (σ → τ). Brackets are Typed Lambda omitted if no ambiguity. Calculus For types τ, we have variables Var(τ), constants First Order Logic Con(τ). Truth and Satisfaction Since we are doing first order logic, we will later restrict variables to Var(IND), but allow constants of any type. Terms in Typed Lambda Calculus SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein We define terms Term(τ) of type τ: Outline Var(τ) ⊆ Term(τ). Typed Lambda Con(τ) ⊆ Term(τ). Calculus First Order If α ∈ Term(σ → τ) and β ∈ Term(σ) then Logic (α β) ∈ Term(τ) (function application). Truth and Satisfaction If x ∈ Var(σ) and α ∈ Term(ρ), then λx.α ∈ Term(τ), where τ = (σ → ρ) Terms in Typed Lambda Calculus SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein We define terms Term(τ) of type τ: Outline Var(τ) ⊆ Term(τ). Typed Lambda Con(τ) ⊆ Term(τ). Calculus First Order If α ∈ Term(σ → τ) and β ∈ Term(σ) then Logic (α β) ∈ Term(τ) (function application). Truth and Satisfaction If x ∈ Var(σ) and α ∈ Term(ρ), then λx.α ∈ Term(τ), where τ = (σ → ρ) Terms in Typed Lambda Calculus SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein We define terms Term(τ) of type τ: Outline Var(τ) ⊆ Term(τ). Typed Lambda Con(τ) ⊆ Term(τ). Calculus First Order If α ∈ Term(σ → τ) and β ∈ Term(σ) then Logic (α β) ∈ Term(τ) (function application). Truth and Satisfaction If x ∈ Var(σ) and α ∈ Term(ρ), then λx.α ∈ Term(τ), where τ = (σ → ρ) Terms in Typed Lambda Calculus SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein We define terms Term(τ) of type τ: Outline Var(τ) ⊆ Term(τ). Typed Lambda Con(τ) ⊆ Term(τ). Calculus First Order If α ∈ Term(σ → τ) and β ∈ Term(σ) then Logic (α β) ∈ Term(τ) (function application). Truth and Satisfaction If x ∈ Var(σ) and α ∈ Term(ρ), then λx.α ∈ Term(τ), where τ = (σ → ρ) Extending to a First Order Language SPNLP: Lambda Terms, Quantifiers, Satisfaction 1 Variables i.e., Var(IND): x, y, z,..., x0, x1, x2,... Lascarides & Klein 2 Boolean connectives: ¬ BOOL → BOOL (negation) Outline ∧ BOOL → (BOOL → BOOL) (and) Typed Lambda ∨ BOOL → (BOOL → BOOL) (or) Calculus → BOOL → (BOOL → BOOL) (if. then) First Order Logic 3 Quantifiers: ∀ (all) Truth and Satisfaction ∃ (some) 4 Equality: = τ → (τ → BOOL) 5 Punctuation: brackets and period Quantifier Syntax SPNLP: Lambda Terms, Quantifiers, If φ ∈ Term(BOOL), and x ∈ Var(IND), then ∀x.φ and Satisfaction Lascarides & ∃x.φ ∈ Term(BOOL). Klein x ∈ Var(IND) is called an individual variable. Outline Typed Lambda Syntactic conventions: Calculus First Order Logic Instead of writing ((= α)β), ((∧φ)ψ), etc., we write Truth and (= α = β), (φ ∧ ψ), etc. Satisfaction Instead of writing e.g., ((chase fido) john), we sometimes write (chase fido john). NB this is equivalent to chase(john, fido) on a relational approach. Quantifier Syntax SPNLP: Lambda Terms, Quantifiers, If φ ∈ Term(BOOL), and x ∈ Var(IND), then ∀x.φ and Satisfaction Lascarides & ∃x.φ ∈ Term(BOOL). Klein x ∈ Var(IND) is called an individual variable. Outline Typed Lambda Syntactic conventions: Calculus First Order Logic Instead of writing ((= α)β), ((∧φ)ψ), etc., we write Truth and (= α = β), (φ ∧ ψ), etc. Satisfaction Instead of writing e.g., ((chase fido) john), we sometimes write (chase fido john). NB this is equivalent to chase(john, fido) on a relational approach. Quantifier Syntax SPNLP: Lambda Terms, Quantifiers, If φ ∈ Term(BOOL), and x ∈ Var(IND), then ∀x.φ and Satisfaction Lascarides & ∃x.φ ∈ Term(BOOL). Klein x ∈ Var(IND) is called an individual variable. Outline Typed Lambda Syntactic conventions: Calculus First Order Logic Instead of writing ((= α)β), ((∧φ)ψ), etc., we write Truth and (= α = β), (φ ∧ ψ), etc. Satisfaction Instead of writing e.g., ((chase fido) john), we sometimes write (chase fido john). NB this is equivalent to chase(john, fido) on a relational approach. Quantifier Syntax SPNLP: Lambda Terms, Quantifiers, If φ ∈ Term(BOOL), and x ∈ Var(IND), then ∀x.φ and Satisfaction Lascarides & ∃x.φ ∈ Term(BOOL). Klein x ∈ Var(IND) is called an individual variable. Outline Typed Lambda Syntactic conventions: Calculus First Order Logic Instead of writing ((= α)β), ((∧φ)ψ), etc., we write Truth and (= α = β), (φ ∧ ψ), etc. Satisfaction Instead of writing e.g., ((chase fido) john), we sometimes write (chase fido john). NB this is equivalent to chase(john, fido) on a relational approach. Some Examples SPNLP: Lambda Terms, Quantifiers, Satisfaction Lascarides & Klein 1 ∃x.(love x kim) Kim loves someone Outline Typed 2 (¬∃x.(love x kim)) Lambda Calculus Kim doesn’t love anyone First Order 3 ∀x.((robber x) → ∃y.((customer y) ∧ (love y x))) Logic Truth and All robbers love a (perhaps different) customer Satisfaction 4 ∃y.((customer y) ∧ ∀x.((robber
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages36 Page
-
File Size-