Documentation

Linglib.Syntax.DependencyGrammar.Formal.NonProjective

Mildly non-projective dependency structures #

Formalizes the structural theory of [KN06], [Kuh13], [Mul13]: planarity, well-nestedness, and the hierarchy

projective ⊂ planar ⊂ well-nested ⊂ unrestricted.

The cross-serial / nested verb-cluster pair ([Kuh13] Figure 1) witnesses the gap between projectivity and well-nestedness in attested language data.

Main declarations #

Implementation notes #

Arc-crossing detection #

def DepGrammar.depsCross (d1 d2 : Dependency) :
Bool

Two dependencies cross iff their spans overlap without containment. ([KN06], implicit in Definition 4)

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

    All non-projective (crossing) dependencies in a tree.

    Equations
    Instances For

      Whether a tree has any non-projective dependencies.

      Equations
      Instances For

        Planarity ([KN06], Definition 4) #

        def DepGrammar.linked (deps : List Dependency) (a b : ) :
        Bool

        Whether two positions are linked by an edge (in either direction).

        Equations
        Instances For

          A dependency tree is planar iff its edges can be drawn above the sentence without crossing: no nodes a < b < c < d with linked a c and linked b d. ([KN06], Definition 4)

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

            Well-nestedness ([KN06], Definition 8) #

            def DepGrammar.projectionsInterleave (p1 p2 : List ) :
            Bool

            Two projections interleave if there exist l₁, r₁ ∈ p1 and l₂, r₂ ∈ p2 with l₁ < l₂ < r₁ < r₂.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              def DepGrammar.disjoint (deps : List Dependency) (u v : ) :
              Bool

              Two nodes are disjoint if neither dominates the other.

              Equations
              Instances For

                A dependency tree is well-nested if no two disjoint nodes have interleaving projections. ([KN06], Definition 8)

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

                  Example trees #

                  Cross-serial Dutch and nested German from [Kuh13] Figure 1 — the canonical pair witnessing that mild non-projectivity (well-nested, gap degree 1) covers attested data.

                  Minimal crossing tree: arcs 0 → 2 and 1 → 3 cross.

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

                    Dutch cross-serial: "dat Jan Piet Marie zag helpen lezen". Dependencies zag→Jan, helpen→Piet, lezen→Marie cross.

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

                      German nested: "dass Jan Piet Marie lesen helfen sah". Same dependencies as dutchCrossSerial but verbs in reverse order → projective.

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

                        Verified properties of the example trees #

                        Hierarchy theorems #

                        Projective ⟺ gap degree 0: a tree is projective iff no node's projection has any gaps. ([KN06], Definition 3 + Definition 7)

                        theorem DepGrammar.projective_iff_blockDegree_one (t : DepTree) (hne_tree : t.words.length > 0) :
                        isProjective t = true t.blockDegree = 1

                        Projective ⟺ block-degree 1 for non-empty trees.

                        theorem DepGrammar.blockDegree_eq_gapDegree_succ (deps : List Dependency) (root : ) :
                        blockDegreeAt deps root = gapDegreeAt deps root + 1

                        Block-degree = gap degree + 1 for non-empty projections. ([Kuh13], §7.1 footnote 2)

                        Projective ⊂ planar #

                        The forward direction of the hierarchy. The proof goes by contrapositive: if planarity fails, the four witness nodes generate a dominance cycle via dominates_to_parent, contradicting acyclicity. The hasUniqueHeads precondition is essential — a multi-headed node can be projective yet non-planar.

                        theorem DepGrammar.projective_implies_planar (t : DepTree) (hwf : t.WF) (hacyc : isAcyclic t = true) (hproj : isProjective t = true) :
                        t.isPlanar = true

                        Projective ⊂ planar for well-formed trees. ([KN06], §3.5)

                        Planar ⊂ well-nested #

                        By contrapositive: an interleaving witness produces a spanning-edge crossing that breaks planarity. The infrastructure below — dominance comparability under unique heads, parent-chain extraction, the discrete IVT-style exit/entry steps — feeds the core interleaving_not_planar lemma.

                        theorem DepGrammar.planar_implies_wellNested (t : DepTree) (hwf : t.WF) (hplanar : t.isPlanar = true) :
                        t.isWellNested = true

                        Planar ⊂ well-nested for well-formed trees. ([KN06], Theorem 1)

                        Bridge to gapDegree #

                        Non-projective ⇒ gap degree ≥ 1. Contrapositive of projective_iff_gapDegree_zero.