Documentation

Linglib.Theories.Syntax.CCG.Core.Combinators

def CCG.Combinators.B {α β γ : Type} (f : βγ) (g : αβ) :
αγ

B combinator (composition): B f g x = f (g x).

Equations
Instances For
    def CCG.Combinators.T {α β : Type} (x : α) :
    (αβ)β

    T combinator (type-raising): T x f = f x.

    Equations
    Instances For
      def CCG.Combinators.S {α β γ : Type} (f : αβγ) (g : αβ) :
      αγ

      S combinator (substitution): S f g x = f x (g x).

      Equations
      Instances For
        def CCG.Combinators.I {α : Type} :
        αα

        I combinator (identity): I x = x.

        Equations
        Instances For
          def CCG.Combinators.K {α β : Type} (x : α) :
          βα

          K combinator (constant): K x y = x.

          Equations
          Instances For
            def CCG.Combinators.C {α β γ : Type} (f : αβγ) (x : β) (y : α) :
            γ

            C combinator (commutation): C f x y = f y x.

            Equations
            Instances For
              theorem CCG.Combinators.T_eq_CI {α β : Type} (x : α) :
              T x = C I x

              T = CI: type-raising equals C applied to I (Steedman p. 206-207).

              theorem CCG.Combinators.CI_is_T {α β : Type} :
              (fun (x : α) => C I x) = T

              CI is T.

              theorem CCG.Combinators.C_eq_B_T {α β γ : Type} (f : αβγ) (x : β) (y : α) :
              C f x y = B (T x) f y

              C = B(T_) pointwise: C f x y = B (T x) f y (Church's result via Steedman p. 207).

              theorem CCG.Combinators.C_from_B_T {α β γ : Type} (f : αβγ) (x : β) (y : α) :
              have Tx := T x; have fy := f y; C f x y = Tx fy

              C from B and T pointwise.

              theorem CCG.Combinators.B_comp {α β γ : Type} (f : βγ) (g : αβ) :
              B f g = f g

              B is function composition.

              theorem CCG.Combinators.B_apply {α β γ : Type} (f : βγ) (g : αβ) (x : α) :
              B f g x = f (g x)

              B f g x = f (g x).

              theorem CCG.Combinators.T_apply {α β : Type} (x : α) (f : αβ) :
              T x f = f x

              T x f = f x.

              theorem CCG.Combinators.S_apply {α β γ : Type} (f : αβγ) (g : αβ) (x : α) :
              S f g x = f x (g x)

              S f g x = f x (g x).

              theorem CCG.Combinators.I_apply {α : Type} (x : α) :
              I x = x

              I x = x.

              theorem CCG.Combinators.K_apply {α β : Type} (x : α) (y : β) :
              K x y = x

              K x y = x.

              theorem CCG.Combinators.I_eq_SKK {α : Type} :
              I = S K K

              I = SKK.

              theorem CCG.Combinators.B_eq_S_KS_K {α β γ : Type} (f : βγ) (g : αβ) :
              B f g = S (K f) g

              B f g = S (K f) g.

              theorem CCG.Combinators.fcomp_is_B {m : Semantics.Montague.Model} {x y z : Cat} (f_sem : m.interpTy (catToTy (x.rslash y))) (g_sem : m.interpTy (catToTy (y.rslash z))) :
              (fun (arg : m.interpTy (catToTy z)) => f_sem (g_sem arg)) = B f_sem g_sem

              Forward composition = B: fcomp semantics is B f g.

              catToTy (X/Z) = catToTy Z => catToTy X.

              theorem CCG.Combinators.bcomp_is_B {m : Semantics.Montague.Model} {x y z : Cat} (g_sem : m.interpTy (catToTy (y.lslash z))) (f_sem : m.interpTy (catToTy (x.lslash y))) :
              (fun (arg : m.interpTy (catToTy z)) => f_sem (g_sem arg)) = B f_sem g_sem

              Backward composition = B: bcomp semantics is B f g.

              theorem CCG.Combinators.type_raise_is_T {m : Semantics.Montague.Model} {x t : Cat} (a_sem : m.interpTy (catToTy x)) :
              (fun (f : m.interpTy (catToTy (t.lslash x))) => f a_sem) = T a_sem

              Forward type-raising = T: semantics of ftr is T a.

              catToTy (T/(T\X)) = (catToTy X => catToTy T) => catToTy T.

              Backward type-raising type = forward type-raising type.

              theorem CCG.Combinators.crossed_comp_is_S {m : Semantics.Montague.Model} {x y z : Cat} (f_sem : m.interpTy (catToTy ((x.rslash y).rslash z))) (g_sem : m.interpTy (catToTy (y.rslash z))) :
              (fun (arg : m.interpTy (catToTy z)) => f_sem arg (g_sem arg)) = S f_sem g_sem

              Crossed composition = S: (X/Y)/Z + Y/Z => X/Z with S f g x = f x (g x).

              theorem CCG.Combinators.fapp_via_T {m : Semantics.Montague.Model} {x y : Cat} (f_sem : m.interpTy (catToTy (x.rslash y))) (a_sem : m.interpTy (catToTy y)) :
              f_sem a_sem = T a_sem f_sem

              Forward application via T: f a = T a f.

              def CCG.Combinators.apply' {α β : Type} (f : αβ) (a : α) :
              β

              Direct function application.

              Equations
              Instances For
                theorem CCG.Combinators.fapp_is_apply {m : Semantics.Montague.Model} {x y : Cat} (f_sem : m.interpTy (catToTy (x.rslash y))) (a_sem : m.interpTy (catToTy y)) :
                f_sem a_sem = apply' f_sem a_sem
                theorem CCG.Combinators.subject_verb_composition {m : Semantics.Montague.Model} (subj_sem : m.interpTy (catToTy NP)) (verb_sem : m.interpTy (catToTy TV)) (obj : m.interpTy (catToTy NP)) :
                B (T subj_sem) verb_sem obj = verb_sem obj subj_sem

                Type-raised subject composed with transitive verb gives a function from objects to truth values.

                The computation is:

                • subj_raised = T subj_sem = λf. f subj_sem
                • result = B subj_raised verb_sem = λy. subj_raised (verb_sem y) = λy. verb_sem y subj_sem

                The combinator correspondence as a record

                • fapp_apply {α β : Type} (f : αβ) (a : α) : f a = f a

                  Forward application is function application

                • fcomp_B {α β γ : Type} (f : βγ) (g : αβ) (x : α) : (fun (z : α) => f (g z)) x = B f g x

                  Forward composition is B

                • ftr_T {α β : Type} (a : α) (f : αβ) : T a f = f a

                  Type-raising is T

                • xcomp_S {α β γ : Type} (f : αβγ) (g : αβ) (x : α) : (fun (z : α) => f z (g z)) x = S f g x

                  Crossed composition is S

                Instances For
                  def CCG.Combinators.steedmanForwardApp {α β : Type} (f : αβ) (a : α) :
                  β

                  Forward application: functor on left, argument on right

                  Equations
                  Instances For
                    def CCG.Combinators.steedmanBackwardApp {α β : Type} (a : α) (f : αβ) :
                    β

                    Backward application: argument on left, functor on right

                    Equations
                    Instances For

                      Both application rules have the same semantic effect: function application

                      theorem CCG.Combinators.steedman_B_def {α β γ : Type} (f : βγ) (g : αβ) (x : α) :
                      B f g x = f (g x)

                      Steedman's definition of B (p. 24): Bfgx ≡ f(gx)

                      theorem CCG.Combinators.forward_comp_semantics {α β γ : Type} (f : βγ) (g : αβ) :
                      B f g = fun (x : α) => f (g x)

                      Forward composition produces B-combined semantics

                      theorem CCG.Combinators.backward_comp_semantics {α β γ : Type} (g : αβ) (f : βγ) :
                      B f g = fun (x : α) => f (g x)

                      Backward composition also uses B, just with reversed linear order

                      def CCG.Combinators.B2 {α β γ δ : Type} (f : γδ) (g : αβγ) :
                      αβδ

                      B² combinator: composition into a binary function

                      Equations
                      Instances For
                        def CCG.Combinators.B3 {α β γ δ ε : Type} (f : δε) (g : αβγδ) :
                        αβγε

                        B³ combinator: composition into a ternary function

                        Equations
                        Instances For
                          theorem CCG.Combinators.B2_is_B_B {α β γ δ : Type} (f : γδ) (g : αβγ) :
                          B2 f g = fun (x : α) => B f (g x)

                          B² is B composed with B

                          theorem CCG.Combinators.steedman_T_def {α β : Type} (x : α) (f : αβ) :
                          T x f = f x

                          Steedman's definition of T (p. 33): Txf ≡ fx

                          theorem CCG.Combinators.type_raise_to_gq {α β : Type} (a : α) :
                          T a = fun (f : αβ) => f a

                          Type-raising turns an entity into a generalized quantifier

                          theorem CCG.Combinators.steedman_S_def {α β γ : Type} (f : αβγ) (g : αβ) (x : α) :
                          S f g x = f x (g x)

                          Steedman's definition of S (p. 57): Sfgx ≡ fx(gx)

                          theorem CCG.Combinators.S_distributes {α β γ : Type} (f : αβγ) (g : αβ) :
                          S f g = fun (x : α) => f x (g x)

                          S distributes the argument to both functions

                          The CCG combinatory rules as a sum type

                          Instances For
                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For

                              The type mapping T from Steedman (13) - this is our catToTy

                              The Constituent Condition: derivations yield interpretable constituents. In CCG, this is automatic because categories encode semantic types.

                              Equations
                              Instances For

                                CCG satisfies the Constituent Condition by construction

                                Combinatory grammars build meaning without bound variables. Every semantic operation is a combinator application.

                                • app_direct {α β : Type} (f : αβ) (x : α) : f x = f x

                                  All function application is direct (no variable binding)

                                • comp_is_B {α β γ : Type} (f : βγ) (g : αβ) : (fun (x : α) => f (g x)) = B f g

                                  Composition uses B, not λ-abstraction

                                • raise_is_T {α β : Type} (x : α) : (fun (f : αβ) => f x) = T x

                                  Type-raising uses T, not λ-abstraction

                                Instances For

                                  CCG provides variable-free semantics

                                  Equations
                                  Instances For

                                    Dependency pattern in a construction

                                    Instances For
                                      Equations
                                      • One or more equations did not get rendered due to their size.
                                      Instances For

                                        Basic word order types

                                        Instances For
                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          Instances For

                                            Which conjunct has the gap in gapping constructions

                                            Instances For
                                              Equations
                                              • One or more equations did not get rendered due to their size.
                                              Instances For

                                                A fragment satisfies the Sense Unit Condition if it's semantically coherent

                                                Equations
                                                Instances For

                                                  The Principle of Adjacency: rules apply only to adjacent elements

                                                  • adjacent : Bool

                                                    Rules apply to string-adjacent entities

                                                  • finite : Bool

                                                    Rules apply to finitely many entities

                                                  Instances For

                                                    Direction a functor seeks its argument

                                                    Instances For
                                                      Equations
                                                      • One or more equations did not get rendered due to their size.
                                                      Instances For
                                                        def CCG.Combinators.principleOfInheritance (inputSlash outputSlash : SlashDir) :

                                                        The Principle of Inheritance: output slashes inherit from inputs

                                                        Equations
                                                        Instances For

                                                          Classification of combinatory rules by order-preservation

                                                          Instances For
                                                            Equations
                                                            • One or more equations did not get rendered due to their size.
                                                            Instances For

                                                              The complete catalog of composition rules

                                                              Instances For
                                                                Equations
                                                                • One or more equations did not get rendered due to their size.
                                                                Instances For

                                                                  The complete catalog of substitution rules

                                                                  Instances For
                                                                    Equations
                                                                    • One or more equations did not get rendered due to their size.
                                                                    Instances For

                                                                      Non-order-preserving (crossed) rules can permute arguments

                                                                      Equations
                                                                      Instances For

                                                                        Extraction type

                                                                        Instances For
                                                                          Equations
                                                                          • One or more equations did not get rendered due to their size.
                                                                          Instances For

                                                                            In SVO languages, subject extraction from that-complements is blocked

                                                                            Equations
                                                                            Instances For

                                                                              The asymmetry follows from directionality, not from ECP

                                                                              Feature controlling whether an argument can shift

                                                                              Instances For
                                                                                Equations
                                                                                • One or more equations did not get rendered due to their size.
                                                                                Instances For

                                                                                  Types of nominal interpretations

                                                                                  Instances For
                                                                                    Equations
                                                                                    • One or more equations did not get rendered due to their size.
                                                                                    Instances For

                                                                                      Geach's constraint: coordinated elements must have parallel scope

                                                                                      Equations
                                                                                      Instances For

                                                                                        The c-command condition on distribution parallels binding

                                                                                        Equations
                                                                                        Instances For

                                                                                          CCG is monotonic: structures are never revised

                                                                                          Equations
                                                                                          Instances For

                                                                                            CCG is monostratal: only Logical Form is a true level

                                                                                            Equations
                                                                                            Instances For

                                                                                              Different derivations can yield the same Logical Form

                                                                                              Equations
                                                                                              Instances For