Valency frames #
This file defines valency frames over dependency graphs: slot data,
standard frame schemas for the basic valences, the valency of a verb's
lexical ArgumentFrame, read off the argument roles of its core
arguments, and satisfaction of a frame by a position's dependents.
Main definitions #
Valencyis a word's valency as a list of slots, each a relation, a head direction and an optionality.Valency.ofFrameis the valency of an argument frame, a slot for each core argument by its argument role.Frames nis the per-position valency table.Graph.SatisfiesFramesis frame satisfaction: every filler on its slot's side of the head, required slots filled, and no unlicensed core arguments.
Implementation notes #
Frames are a side table (Frames n), not part of the graph carrier: the
frame is framework apparatus (like HPSG's ARG-ST), supplied alongside the
graph by the consumers that reason about valency and populated from the
lexical carrier (Valency.ofFrame of a verb's basic frame).
References #
Slot data #
A single valency slot, recording which relation fills it, the direction of the head with respect to the filler, and whether it must be filled.
- depType : UD.DepRel
The UD relation of the filler.
- direction : HeadDirection
The direction of the head with respect to the filler.
- required : Bool
Whether the slot must be filled.
Instances For
Equations
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
The valency of a word is the list of dependent slots it requires or allows.
Equations
Instances For
The per-position frame table supplied alongside a Graph n.
Equations
- DependencyGrammar.Frames n = (Fin n → Option DependencyGrammar.Valency)
Instances For
A sparse frame table, in which positions not listed carry no frame.
Equations
- DependencyGrammar.Frames.ofList l i = Option.map (fun (x : Fin n × DependencyGrammar.Valency) => x.2) (List.find? (fun (x : Fin n × DependencyGrammar.Valency) => x.1 == i) l)
Instances For
Standard schemas #
An intransitive verb takes its subject to the left.
Equations
- DependencyGrammar.Valency.intransitive = [{ depType := UD.DepRel.nsubj, direction := HeadDirection.headFinal }]
Instances For
A transitive verb takes its subject to the left and its object to the right.
Equations
- DependencyGrammar.Valency.transitive = [{ depType := UD.DepRel.nsubj, direction := HeadDirection.headFinal }, { depType := UD.DepRel.obj, direction := HeadDirection.headInitial }]
Instances For
A ditransitive verb takes its subject to the left and its indirect object and object to the right.
Equations
- One or more equations did not get rendered due to their size.
Instances For
A passive transitive verb takes its subject, the patient, to the left and an optional by-phrase to the right.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Valency of an argument frame #
The required slot of a core argument by its argument role. S and A are the subject, to the left of the head; P and T the object and R the indirect object, to its right.
Equations
- DependencyGrammar.Valency.Slot.ofRole ArgumentRole.S = { depType := UD.DepRel.nsubj, direction := HeadDirection.headFinal }
- DependencyGrammar.Valency.Slot.ofRole ArgumentRole.A = { depType := UD.DepRel.nsubj, direction := HeadDirection.headFinal }
- DependencyGrammar.Valency.Slot.ofRole ArgumentRole.P = { depType := UD.DepRel.obj, direction := HeadDirection.headInitial }
- DependencyGrammar.Valency.Slot.ofRole ArgumentRole.T = { depType := UD.DepRel.obj, direction := HeadDirection.headInitial }
- DependencyGrammar.Valency.Slot.ofRole ArgumentRole.R = { depType := UD.DepRel.iobj, direction := HeadDirection.headInitial }
Instances For
The valency of an argument frame has a slot for each core argument, by its argument role.
Clausal and adpositional complements have none, since UD's clausal relations and obliques are
not core arguments and Graph.SatisfiesFrames leaves them unconstrained.
Equations
- DependencyGrammar.Valency.ofFrame fr = List.filterMap (fun (s : ArgumentFrame.Slot) => Option.map DependencyGrammar.Valency.Slot.ofRole (fr.argumentRole s)) fr.coreSlots
Instances For
Argument-frame satisfaction #
The graph satisfies a valency at head v when the head has the slot's direction with
respect to every filler of every slot, and required slots are filled.
Equations
Instances For
Equations
- One or more equations did not get rendered due to their size.
Core argument relations governed by lexical frames. Deliberately the
nominal core only — UD's clausal core relations (csubj, ccomp, xcomp)
are licensed by clause-embedding frames, which Valency.ofFrame
does not schematize.
Equations
Instances For
Every core-argument dependent of v is licensed by a slot of val —
the closed-world half of valency checking (SatisfiesValency only
checks that required slots are filled).
Equations
- DependencyGrammar.CoreArgsLicensed g v val = ∀ w ∈ g.children v, ∀ r ∈ g.label v w, r ∈ DependencyGrammar.coreArgRels → ∃ slot ∈ val, slot.depType = r
Instances For
Equations
- DependencyGrammar.instDecidableCoreArgsLicensed g v val = Finset.decidableDforallFinset
Each verb's dependents satisfy its frame, with required slots filled in the
right direction (SatisfiesValency) and no unlicensed core arguments
(CoreArgsLicensed). Verbs without a frame are unconstrained.
Equations
- g.SatisfiesFrames frames = ∀ (v : Fin n), (g.words v).cat = UD.UPOS.VERB → ∀ val ∈ frames v, DependencyGrammar.SatisfiesValency g v val ∧ DependencyGrammar.CoreArgsLicensed g v val
Instances For
Equations
- One or more equations did not get rendered due to their size.