Long-distance dependencies in UD enhanced graphs #
Implements the gap-filling step of Universal Dependencies' enhanced dependency graphs ([dMN19]): the basic tree obeys a unique-heads constraint that loses the predicate–argument relation across a filler–gap configuration, and the enhanced graph recovers it by adding an explicit edge from the gap-host word to the filler.
Main declarations #
GapType— the four core UD argument positions a missing element may fill (subject, object, indirect object, oblique).gapToDepRel— the UDDepRelcorresponding to aGapType.fillGap— enhanced-edge construction: produce aDepGraphfrom a basicDepTreeby appending an edge that records gap-filling.extractionLabel— recover the gap-type label at a node by diffing the basic tree against the enhanced graph.checkNoIslandViolation— coarse modifier/conjunct heuristic over a list of gap sites; not a full Ross-1967 inventory.isLDWellFormed— structural well-formedness plus the coarse island heuristic plus filler-licensing.
Implementation notes #
- The
Bool-valued predicates followDepGrammar.isWellFormed's substrate convention; converting them toProp+Decidableis a substrate-wide refactor not done here. hasGapInModifierOrConjunctis deliberately coarse: it flags any gap whose direct head isnmodorconj. It does not recognise CNPC, CSC, adjunct, or subject islands. Richer island handling lives inSyntax/DependencyGrammar/Formal/Islands.lean.- Word Grammar ([Hud10]) handles the same data with a structurally analogous hopping mechanism; GPSG ([Gaz81]) uses SLASH-feature percolation. Neither is implemented here.
Todo #
- Consume the Ross-1967
ConstraintTypeenum (Studies/Ross1967.lean) here and inFormal/Islands.leanso the two files share a single inventory. - Build a cross-framework
FillerGapabstraction so the RSRLGAP(Syntax/HPSG/Construction),LongDistance.GapType, and Minimalist movement labels all specialise a shared interface.
Gap types and the UD relation map #
Equations
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- DepGrammar.LongDistance.instDecidableEqGapType x✝ y✝ = if h : x✝.ctorIdx = y✝.ctorIdx then isTrue ⋯ else isFalse ⋯
The UD DepRel corresponding to a GapType.
Equations
- DepGrammar.LongDistance.gapToDepRel DepGrammar.LongDistance.GapType.subjGap = UD.DepRel.nsubj
- DepGrammar.LongDistance.gapToDepRel DepGrammar.LongDistance.GapType.objGap = UD.DepRel.obj
- DepGrammar.LongDistance.gapToDepRel DepGrammar.LongDistance.GapType.iobjGap = UD.DepRel.iobj
- DepGrammar.LongDistance.gapToDepRel DepGrammar.LongDistance.GapType.oblGap = UD.DepRel.obl
Instances For
Enhanced-edge construction #
Add a single enhanced edge to t: the filler becomes a dependent of the
gap host with the UD relation corresponding to gapType.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Recover the gap-type label at nodeIdx by diffing basic against
enhanced: returns the first enhanced-only argument-shaped edge's GapType,
or none.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Island heuristic and well-formedness #
Coarse check: does the word at gapIdx head an nmod or conj relation.
This does not recognise any of the four classical Ross-1967 islands.
Equations
- DepGrammar.LongDistance.hasGapInModifierOrConjunct t gapIdx = t.deps.any fun (d : DepGrammar.Dependency) => (d.depType == UD.DepRel.nmod || d.depType == UD.DepRel.conj) && d.depIdx == gapIdx
Instances For
No gap is reported inside the coarse modifier/conjunct heuristic.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Combined well-formedness for trees with long-distance gaps: substrate
tree-level checks (minus checkVerbSubcat, since LD trees inherently have
argument gaps), the coarse island heuristic, and filler-licensing (wh-word,
leftward topicalization, or relative-clause head).
Equations
- One or more equations did not get rendered due to their size.