The ArcInverter takes a PolytreeParse and inverts arcs whose labels are in the argument set
inverseArcLabels. Note that this operation should only affect the children field of a
PolytreeParse, since the other fields only care about the underlying undirected tree.
The purpose of this class is to convert standard dependency parses into polytree
dependency parses. For instance, we may wish to invert all arcs x ---> y for which
the arc label is 'det (effectively this would invert the relationship between a determiner
and its noun to say that the determiner "requires" the noun, rather than vice-versa).
The ArcInverter takes a PolytreeParse and inverts arcs whose labels are in the argument set
inverseArcLabels
. Note that this operation should only affect thechildren
field of a PolytreeParse, since the other fields only care about the underlying undirected tree.The purpose of this class is to convert standard dependency parses into polytree dependency parses. For instance, we may wish to invert all arcs x ---> y for which the arc label is 'det (effectively this would invert the relationship between a determiner and its noun to say that the determiner "requires" the noun, rather than vice-versa).