Fifth Workshop on Lambda Calculus and Formal Grammar
1
1 Fifth Workshop on Lambda Calculus and Formal Grammar 2 Fifth - - PowerPoint PPT Presentation
1 Fifth Workshop on Lambda Calculus and Formal Grammar 2 Fifth Workshop on Lambda Calculus and Formal Grammar A Type-Theoretic View of Dynamic Logic Philippe de Groote LORIA & Inria-Lorraine 3 Fifth Workshop on Lambda Calculus and
Fifth Workshop on Lambda Calculus and Formal Grammar
1
Fifth Workshop on Lambda Calculus and Formal Grammar
2
Philippe de Groote LORIA & Inria-Lorraine
Fifth Workshop on Lambda Calculus and Formal Grammar
3
Fifth Workshop on Lambda Calculus and Formal Grammar
3
Motivation:
which will allow DRT and Montague semantics to rest on the same logical foundations.
Fifth Workshop on Lambda Calculus and Formal Grammar
3
Motivation:
which will allow DRT and Montague semantics to rest on the same logical foundations. Challenge:
assignment” problem, wich necessitates a LISP-like gensym operator).
Fifth Workshop on Lambda Calculus and Formal Grammar
3
Motivation:
which will allow DRT and Montague semantics to rest on the same logical foundations. Challenge:
assignment” problem, wich necessitates a LISP-like gensym operator). Proposed solution:
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts.
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
left context
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
left context
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
left context
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
left context
Fifth Workshop on Lambda Calculus and Formal Grammar
4 Typing the left and the right contexts Montague semantics is based on Church’s simple type theory, which provides a full hierarchy
We add a third atomic type, γ, which stands for the type of the left contexts. What about the type of the right contexts?
left context
Fifth Workshop on Lambda Calculus and Formal Grammar
5 Semantic interpretation of the sentences
Fifth Workshop on Lambda Calculus and Formal Grammar
5 Semantic interpretation of the sentences Let s be the syntactic category of sentences. Remember that we intend to abstract our notions of left and right contexts over the meaning of the sentences.
Fifth Workshop on Lambda Calculus and Formal Grammar
5 Semantic interpretation of the sentences Let s be the syntactic category of sentences. Remember that we intend to abstract our notions of left and right contexts over the meaning of the sentences.
Fifth Workshop on Lambda Calculus and Formal Grammar
5 Semantic interpretation of the sentences Let s be the syntactic category of sentences. Remember that we intend to abstract our notions of left and right contexts over the meaning of the sentences.
Composition of two sentence interpretations
Fifth Workshop on Lambda Calculus and Formal Grammar
5 Semantic interpretation of the sentences Let s be the syntactic category of sentences. Remember that we intend to abstract our notions of left and right contexts over the meaning of the sentences.
Composition of two sentence interpretations
Fifth Workshop on Lambda Calculus and Formal Grammar
6 Semantic interpretation of the syntactic categories
Fifth Workshop on Lambda Calculus and Formal Grammar
6 Semantic interpretation of the syntactic categories Montague’s interpretation s =
= ι → o np = (ι → o) → o
Fifth Workshop on Lambda Calculus and Formal Grammar
6 Semantic interpretation of the syntactic categories Montague’s interpretation s =
= ι → o np = (ι → o) → o may be rephrased as follows: s =
n = ι →s (2) np = (ι →s) →s (3)
Fifth Workshop on Lambda Calculus and Formal Grammar
6 Semantic interpretation of the syntactic categories Montague’s interpretation s =
= ι → o np = (ι → o) → o may be rephrased as follows: s =
n = ι →s (2) np = (ι →s) →s (3) Replacing (1) with: s = γ → (γ → o) → o
Fifth Workshop on Lambda Calculus and Formal Grammar
6 Semantic interpretation of the syntactic categories Montague’s interpretation s =
= ι → o np = (ι → o) → o may be rephrased as follows: s =
n = ι →s (2) np = (ι →s) →s (3) Replacing (1) with: s = γ → (γ → o) → o we obtain: n = ι → γ → (γ → o) → o np = (ι → γ → (γ → o) → o) → γ → (γ → o) → o
Fifth Workshop on Lambda Calculus and Formal Grammar
7 This interpretation results in handcrafted lexical semantics such as the following:
Fifth Workshop on Lambda Calculus and Formal Grammar
7 This interpretation results in handcrafted lexical semantics such as the following: farmer = λxeφ. farmer x ∧ φ e donkey = λxeφ. donkey x ∧ φ e
beats = λos. s (λx. o (λyeφ. beat x y ∧ φ e)) who = λrnxeφ. n x e (λe. r (λψ. ψ x) e φ) a = λnψeφ. ∃x. n x e (λe. ψ x (x::e) φ) every = λnψeφ. (∀x. ¬(n x e (λe. ¬(ψ x (x::e) (λe. ⊤))))) ∧ φ e it = λψeφ. ψ (sel e) e φ
Fifth Workshop on Lambda Calculus and Formal Grammar
7 This interpretation results in handcrafted lexical semantics such as the following: farmer = λxeφ. farmer x ∧ φ e donkey = λxeφ. donkey x ∧ φ e
beats = λos. s (λx. o (λyeφ. beat x y ∧ φ e)) who = λrnxeφ. n x e (λe. r (λψ. ψ x) e φ) a = λnψeφ. ∃x. n x e (λe. ψ x (x::e) φ) every = λnψeφ. (∀x. ¬(n x e (λe. ¬(ψ x (x::e) (λe. ⊤))))) ∧ φ e it = λψeφ. ψ (sel e) e φ ...which might seem a little bit involved.
Fifth Workshop on Lambda Calculus and Formal Grammar
8 Questions:
Fifth Workshop on Lambda Calculus and Formal Grammar
8 Questions:
Fifth Workshop on Lambda Calculus and Formal Grammar
8 Questions:
Fifth Workshop on Lambda Calculus and Formal Grammar
8 Questions:
Fifth Workshop on Lambda Calculus and Formal Grammar
9
Fifth Workshop on Lambda Calculus and Formal Grammar
9
Let Ω γ → (γ → o) → o. We intend to design a logic acting on propositions of type Ω
Fifth Workshop on Lambda Calculus and Formal Grammar
9
Let Ω γ → (γ → o) → o. We intend to design a logic acting on propositions of type Ω We share with DRT the two following assumptions:
in the conjunction of its sentences);
Fifth Workshop on Lambda Calculus and Formal Grammar
9
Let Ω γ → (γ → o) → o. We intend to design a logic acting on propositions of type Ω We share with DRT the two following assumptions:
in the conjunction of its sentences);
Consequently, our logic will be based on conjunction and existential quantification (defined as primitives). The other connectives will be obtained using negation (a third primitive) and de Morgan’s laws.
Fifth Workshop on Lambda Calculus and Formal Grammar
10 Formal Framework We consider a simply-typed λ-calculus, the terms of which are built upon asignature in- cluding the following constants:
Fifth Workshop on Lambda Calculus and Formal Grammar
10 Formal Framework We consider a simply-typed λ-calculus, the terms of which are built upon asignature in- cluding the following constants: FIRST-ORDER LOGIC ⊤ :
¬ :
(negation) ∧ :
(conjunction) ∃ : (ι → o) → o (existential quantification)
Fifth Workshop on Lambda Calculus and Formal Grammar
10 Formal Framework We consider a simply-typed λ-calculus, the terms of which are built upon asignature in- cluding the following constants: FIRST-ORDER LOGIC ⊤ :
¬ :
(negation) ∧ :
(conjunction) ∃ : (ι → o) → o (existential quantification) DYNAMIC PRIMITIVES :: : ι → γ → γ (context updating) sel : γ → ι (choice operator)
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction Conjunction is nothing but sentence composition. We therefore define: A ⊓ B λeφ. A e (λe. B e φ)
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction Conjunction is nothing but sentence composition. We therefore define: A ⊓ B λeφ. A e (λe. B e φ) Existential quantification
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction Conjunction is nothing but sentence composition. We therefore define: A ⊓ B λeφ. A e (λe. B e φ) Existential quantification Existential quantification introduces “reference markers”. It is therefore responsible for context updating: Σx. P x λeφ. ∃x. P x (x::e) φ
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction Conjunction is nothing but sentence composition. We therefore define: A ⊓ B λeφ. A e (λe. B e φ) Existential quantification Existential quantification introduces “reference markers”. It is therefore responsible for context updating: Σx. P x λeφ. ∃x. P x (x::e) φ Negation
Fifth Workshop on Lambda Calculus and Formal Grammar
11 Conjunction Conjunction is nothing but sentence composition. We therefore define: A ⊓ B λeφ. A e (λe. B e φ) Existential quantification Existential quantification introduces “reference markers”. It is therefore responsible for context updating: Σx. P x λeφ. ∃x. P x (x::e) φ Negation We do not want the continuation of the discourse to fall into the scope of the negation. Consequently, negation must be defined as follows:
Fifth Workshop on Lambda Calculus and Formal Grammar
12 ∼ A λeφ. ¬ (A e (λe. ⊤)) ∧ φ e
Fifth Workshop on Lambda Calculus and Formal Grammar
13 Implication and Universal Quantification
Fifth Workshop on Lambda Calculus and Formal Grammar
13 Implication and Universal Quantification These are defined using de Morgan’s laws: A ⊐ B ∼(A ⊓ ∼B) Πx. P x ∼Σx. ∼(P x)
Fifth Workshop on Lambda Calculus and Formal Grammar
13 Implication and Universal Quantification These are defined using de Morgan’s laws: A ⊐ B ∼(A ⊓ ∼B) Πx. P x ∼Σx. ∼(P x) Embedding of first-order logic into dynamic logic
Fifth Workshop on Lambda Calculus and Formal Grammar
13 Implication and Universal Quantification These are defined using de Morgan’s laws: A ⊐ B ∼(A ⊓ ∼B) Πx. P x ∼Σx. ∼(P x) Embedding of first-order logic into dynamic logic R t1 . . . tn = λeφ. R t1 . . . tn ∧ φ e ¬A = ∼A A ∧ B = A ⊓ B ∃x. A = Σx. A
Fifth Workshop on Lambda Calculus and Formal Grammar
13 Implication and Universal Quantification These are defined using de Morgan’s laws: A ⊐ B ∼(A ⊓ ∼B) Πx. P x ∼Σx. ∼(P x) Embedding of first-order logic into dynamic logic R t1 . . . tn = λeφ. R t1 . . . tn ∧ φ e ¬A = ∼A A ∧ B = A ⊓ B ∃x. A = Σx. A This embedding is such that, for every term e of type γ: A ≡ A e (λe. ⊤)
Fifth Workshop on Lambda Calculus and Formal Grammar
14
Fifth Workshop on Lambda Calculus and Formal Grammar
14
Montague-like semantic interpretation: farmer = farmer donkey = donkey
beats = λOS. S (λx. O (λy. beat x y)) who = λRQx. Q x ∧ R (λP. P x) a = λPQ. ∃x. P x ∧ Q x every = λPQ. ∀x. P x ⊃ Q x it = ???
Fifth Workshop on Lambda Calculus and Formal Grammar
14
Montague-like semantic interpretation: farmer = farmer donkey = donkey
beats = λOS. S (λx. O (λy. beat x y)) who = λRQx. Q x ∧ R (λP. P x) a = λPQ. ∃x. P x ∧ Q x every = λPQ. ∀x. P x ⊃ Q x it = ???
Fifth Workshop on Lambda Calculus and Formal Grammar
15 Dynamic interpretation: farmer = farmer donkey = donkey
beats = λOS. S (λx. O (λy. beat x y)) who = λRQx. Q x ⊓ R (λP. P x) a = λPQ. Σx. P x ⊓ Q x every = λPQ. Πx. P x ⊐ Q x it = λPeφ. P (sel e) e φ
Fifth Workshop on Lambda Calculus and Formal Grammar
16 With the dynamic interpretation we have that: beats it (every (who (owns (a donkey)) farmer))
Fifth Workshop on Lambda Calculus and Formal Grammar
16 With the dynamic interpretation we have that: beats it (every (who (owns (a donkey)) farmer)) β-reduces to the following term (modulo de Morgan’s laws): λeφ. (∀x. farmer x ⊃ (∀y. donkey y ⊃ (own x y ⊃ beat x (sel (x::y::e))))) ∧ φ e
Fifth Workshop on Lambda Calculus and Formal Grammar
16 With the dynamic interpretation we have that: beats it (every (who (owns (a donkey)) farmer)) β-reduces to the following term (modulo de Morgan’s laws): λeφ. (∀x. farmer x ⊃ (∀y. donkey y ⊃ (own x y ⊃ beat x (sel (x::y::e))))) ∧ φ e that is, assuming that sel is a “perfect” anaphora resolution operator: λeφ. (∀x. farmer x ⊃ (∀y. donkey y ⊃ (own x y ⊃ beat x y))) ∧ φ e
Fifth Workshop on Lambda Calculus and Formal Grammar
17
Fifth Workshop on Lambda Calculus and Formal Grammar
17
Define type “dynamization” as follows: Dι = ι Do = Ω D(α → β) = Dα → Dβ
Fifth Workshop on Lambda Calculus and Formal Grammar
17
Define type “dynamization” as follows: Dι = ι Do = Ω D(α → β) = Dα → Dβ Then, define term “dynamization” as follows: Dt = λx1 . . . xn. t (Rnilx1) . . . (Rnilxn) at type α1 → . . . αn → ι Dt = λx1 . . . xneφ. t (Rex1) . . . (Rexn) ∧ (φ e) at type α1 → . . . αn → o Ret = λx1 . . . xn. t (Dx1) . . . (Dxn) at type D(α1 → . . . αn → ι) Ret = λx1 . . . xn. t (Dx1) . . . (Dxn) e (λe. ⊤) at type D(α1 → . . . αn → o)
Fifth Workshop on Lambda Calculus and Formal Grammar
18 Finally, define λ-term translation as follows: x = x ∧ = ⊓ ∃ = Σ ¬ = ∼ k = Dk for the other constants λx. t = λx. t t u = t u
Fifth Workshop on Lambda Calculus and Formal Grammar
18 Finally, define λ-term translation as follows: x = x ∧ = ⊓ ∃ = Σ ¬ = ∼ k = Dk for the other constants λx. t = λx. t t u = t u Then, for every closed term t of type o, and every context e, we have that: t e (λe. ⊤) ≡ t
Fifth Workshop on Lambda Calculus and Formal Grammar
19 Comparison with existing works
Fifth Workshop on Lambda Calculus and Formal Grammar
19 Comparison with existing works Most existing works on dynamics (DRT, Muskens’, Groenendijk & Stokhof’s) interpret dynamic propositions as binary relations on states (a.k.a., assignments or environments).
Fifth Workshop on Lambda Calculus and Formal Grammar
19 Comparison with existing works Most existing works on dynamics (DRT, Muskens’, Groenendijk & Stokhof’s) interpret dynamic propositions as binary relations on states (a.k.a., assignments or environments). In our setting, these would be terms of type: γ → γ → o,
Fifth Workshop on Lambda Calculus and Formal Grammar
19 Comparison with existing works Most existing works on dynamics (DRT, Muskens’, Groenendijk & Stokhof’s) interpret dynamic propositions as binary relations on states (a.k.a., assignments or environments). In our setting, these would be terms of type: γ → γ → o, and the semantics of Groenendijk & Stokhof’s DPL would be rephrased as follows: Ad λgh. h=g ∧ A (atomic proposition) (¬P)d λgh. h=g ∧ ¬(∃k. Pd h k) (negation) (P ∧ Q)d λgh. ∃k. Pd g k ∧ Qd k h (conjunction) (∃x. P)d λgh. ∃k. k[x]g ∧ Pd k h (existential)
Fifth Workshop on Lambda Calculus and Formal Grammar
20
Fifth Workshop on Lambda Calculus and Formal Grammar
20 There exists a canonical embedding ⌈·⌉ from γ → γ → o into γ → (γ → o) → o: ⌈R⌉ λeφ. ∃e′. φ e′ ∧ R e e′
Fifth Workshop on Lambda Calculus and Formal Grammar
20 There exists a canonical embedding ⌈·⌉ from γ → γ → o into γ → (γ → o) → o: ⌈R⌉ λeφ. ∃e′. φ e′ ∧ R e e′ Then, we have: ⌈Ad⌉ ≡ A ⌈(¬P)d⌉ ≡ ∼ ⌈P d⌉ ⌈(P ∧ Q)d⌉ ≡ ⌈P d⌉⊓⌈Qd⌉
Fifth Workshop on Lambda Calculus and Formal Grammar
20 There exists a canonical embedding ⌈·⌉ from γ → γ → o into γ → (γ → o) → o: ⌈R⌉ λeφ. ∃e′. φ e′ ∧ R e e′ Then, we have: ⌈Ad⌉ ≡ A ⌈(¬P)d⌉ ≡ ∼ ⌈P d⌉ ⌈(P ∧ Q)d⌉ ≡ ⌈P d⌉⊓⌈Qd⌉ As for the existential quantifier: ⌈(∃x. P)d⌉ = λeφ. ∃e′. φ e′ ∧ ∃k. k[x]e ∧ ⌈Pd⌉ k e′ Σx. ⌈Pd⌉ = λeφ. ∃e′. φ e′ ∧ ∃x. ⌈Pd⌉ (x :: e) e′
Fifth Workshop on Lambda Calculus and Formal Grammar
21
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
– generalizes to H.O.L.;
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
– generalizes to H.O.L.; – an intuitionistic version could be worked out.
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
– generalizes to H.O.L.; – an intuitionistic version could be worked out.
Fifth Workshop on Lambda Calculus and Formal Grammar
21
What do we gain?
– generalizes to H.O.L.; – an intuitionistic version could be worked out.