Documentation

Linglib.Semantics.Reference.Context.Tower

Context towers #

A depth-indexed stack of context shifts over an origin, the one carrier for the context-manipulation mechanisms of [abusch-1997], [anand-nevins-2004], [cumming-2026] and [schlenker-2003]: Kaplanian indexicals read the origin, shifted indexicals the innermost context, De Bruijn temporal indexing a relative depth. A shift is an endomorphism of the context type, an element of the monoid Function.End C acting on contexts, and a tower is an origin, Kaplan's speech-act context, with its shifts from outermost to innermost (ContextTower). The context at depth k is the product of the first k shifts acting on the origin (ContextTower.contextAt), saturating at the innermost context (ContextTower.innermost), and pushing a shift multiplies it in (ContextTower.push, push_innermost). An access pattern reads a coordinate of the context at a depth given relative to the tower (AccessPattern, DepthSpec); AccessPattern.origin reads the speech-act context and AccessPattern.innermost the innermost one, and a pattern is stable under a shift when pushing it changes nothing (AccessPattern.Stable), which every origin pattern is (AccessPattern.stable_origin).

References #

structure Reference.ContextTower (C : Type u_1) :
Type u_1

A context tower: an origin with a stack of shifts, from outermost to innermost.

  • origin : C

    The root context, the speech-act context.

  • shifts : List (Function.End C)

    The shifts, the first being the outermost embedding.

Instances For

    The embedding depth: the number of shifts.

    Equations
    Instances For
      def Reference.ContextTower.contextAt {C : Type u_1} (t : ContextTower C) (k : ) :
      C

      The context at depth k: the first k shifts acting on the origin, saturating at the innermost context.

      Equations
      Instances For

        The innermost context: every shift acting on the origin.

        Equations
        Instances For

          The trivial tower over a context.

          Equations
          Instances For
            def Reference.ContextTower.push {C : Type u_1} (t : ContextTower C) (σ : Function.End C) :

            Embed one level deeper.

            Equations
            Instances For
              @[simp]
              theorem Reference.ContextTower.root_origin {C : Type u_1} (c : C) :
              (root c).origin = c
              @[simp]
              theorem Reference.ContextTower.root_innermost {C : Type u_1} (c : C) :
              (root c).innermost = c
              @[simp]
              theorem Reference.ContextTower.root_depth {C : Type u_1} (c : C) :
              (root c).depth = 0
              @[simp]
              theorem Reference.ContextTower.root_contextAt {C : Type u_1} (c : C) {k : } :
              (root c).contextAt k = c
              @[simp]
              theorem Reference.ContextTower.push_origin {C : Type u_1} (t : ContextTower C) (σ : Function.End C) :
              (t.push σ).origin = t.origin
              @[simp]
              theorem Reference.ContextTower.push_depth {C : Type u_1} (t : ContextTower C) (σ : Function.End C) :
              (t.push σ).depth = t.depth + 1
              theorem Reference.ContextTower.contextAt_saturates {C : Type u_1} (t : ContextTower C) {k : } (hk : t.depth k) :

              Past the tower depth, contextAt saturates at the innermost context.

              @[simp]
              theorem Reference.ContextTower.push_innermost {C : Type u_1} (t : ContextTower C) (σ : Function.End C) :
              (t.push σ).innermost = σ t.innermost

              Pushing a shift lets it act on the innermost context.

              theorem Reference.ContextTower.push_contextAt_of_le {C : Type u_1} (t : ContextTower C) (σ : Function.End C) {k : } (hk : k t.depth) :
              (t.push σ).contextAt k = t.contextAt k

              Below the tower depth, a push leaves the context at each depth unchanged.

              theorem Reference.ContextTower.push_contextAt_of_lt {C : Type u_1} (t : ContextTower C) (σ : Function.End C) {k : } (hk : t.depth < k) :
              (t.push σ).contextAt k = σ t.innermost

              Beyond the tower depth, a push saturates at the shifted innermost context.

              @[simp]
              theorem Reference.ContextTower.push_contextAt_succ_depth {C : Type u_1} (t : ContextTower C) (σ : Function.End C) :
              (t.push σ).contextAt (t.depth + 1) = σ t.innermost

              Which depth of a tower an expression reads: the origin, the innermost context, or a fixed depth.

              Instances For
                def Reference.instReprDepthSpec.repr :
                DepthSpecStd.Format
                Equations
                Instances For
                  def Reference.DepthSpec.resolve (d : DepthSpec) (towerDepth : ) :

                  The depth read at a tower of the given depth.

                  Equations
                  Instances For
                    @[simp]
                    structure Reference.AccessPattern (C : Type u_1) (R : Type u_2) :
                    Type (max u_1 u_2)

                    An access pattern: a depth specification and a projection, what a context-dependent expression reads. English I is origin Context.agent; Amharic I is innermost Context.agent.

                    • depth : DepthSpec

                      Which depth to read from.

                    • project : CR

                      Which coordinate to extract.

                    Instances For
                      def Reference.AccessPattern.resolve {C : Type u_1} {R : Type u_2} (ap : AccessPattern C R) (t : ContextTower C) :
                      R

                      Resolve an access pattern against a tower.

                      Equations
                      Instances For
                        @[instance_reducible]
                        Equations
                        @[simp]
                        theorem Reference.AccessPattern.map_depth {C : Type u_1} {R S : Type u} (ap : AccessPattern C R) (g : RS) :
                        (g <$> ap).depth = ap.depth
                        @[simp]
                        theorem Reference.AccessPattern.map_project {C : Type u_1} {R S : Type u} (ap : AccessPattern C R) (g : RS) :
                        (g <$> ap).project = g ap.project
                        @[simp]
                        theorem Reference.AccessPattern.resolve_map {C : Type u_1} (t : ContextTower C) {R S : Type u} (ap : AccessPattern C R) (g : RS) :
                        (g <$> ap).resolve t = g (ap.resolve t)
                        def Reference.AccessPattern.origin {C : Type u_1} {R : Type u_2} (f : CR) :

                        Read the coordinate f of the speech-act context: a Kaplanian pure indexical.

                        Equations
                        Instances For
                          def Reference.AccessPattern.innermost {C : Type u_1} {R : Type u_2} (f : CR) :

                          Read the coordinate f of the innermost context: a shifted indexical.

                          Equations
                          Instances For
                            @[simp]
                            theorem Reference.AccessPattern.origin_resolve {C : Type u_1} {R : Type u_2} (t : ContextTower C) (f : CR) :
                            (origin f).resolve t = f t.origin
                            @[simp]
                            theorem Reference.AccessPattern.innermost_resolve {C : Type u_1} {R : Type u_2} (t : ContextTower C) (f : CR) :
                            def Reference.AccessPattern.Stable {C : Type u_1} {R : Type u_2} (ap : AccessPattern C R) (σ : Function.End C) :

                            An access pattern is stable under a shift when pushing the shift onto any tower leaves its resolution unchanged. Kaplan-compliance is stability under every shift and monsterhood instability of some pattern (Reference/Kaplan.lean).

                            Equations
                            Instances For
                              theorem Reference.AccessPattern.origin_stable {C : Type u_1} {R : Type u_2} (ap : AccessPattern C R) (hd : ap.depth = DepthSpec.origin) (t : ContextTower C) (σ : Function.End C) :
                              ap.resolve (t.push σ) = ap.resolve t

                              Origin access is invariant under push: Kaplan's thesis for expressions reading the speech-act context.

                              theorem Reference.AccessPattern.stable_of_depth_origin {C : Type u_1} {R : Type u_2} (ap : AccessPattern C R) (hd : ap.depth = DepthSpec.origin) (σ : Function.End C) :
                              ap.Stable σ
                              theorem Reference.AccessPattern.stable_origin {C : Type u_1} {R : Type u_2} (f : CR) (σ : Function.End C) :
                              (origin f).Stable σ
                              theorem Reference.AccessPattern.local_updates {C : Type u_1} {R : Type u_2} (ap : AccessPattern C R) (hd : ap.depth = DepthSpec.local) (t : ContextTower C) (σ : Function.End C) :
                              ap.resolve (t.push σ) = ap.project (σ t.innermost)

                              Innermost access tracks the pushed shift.