Functions to analyse and manipulate dependency trees, as well as conversions between GF and dependency trees. The main use case is UD (Universal Dependencies), but the code is designed to be completely generic as for annotation scheme. This repository replaces the old gf-contrib/ud2gf code. It is also meant to be used in the 'vd' command of GF and replace the supporting code in gf-core in the future.
Other
7
stars
15
forks
source link
ud2gf: Fallback to morphoanalyze if parse fails + use Str functions for lexical backups #30
If a lemma fails to parse with gf in the expected category, check if morphoanalyze gives a result.
If neither succeeds, instead of inventing new imaginary lexical functions, look for functions of the shape
Str[ExpectedCat] : Str -> ExpectedCat
This is a somewhat breaking change if someone relied of the old way of inventing functions, but on the other hand, it didn't produce valid GF expressions in those cases, so it's unlikely that anything would break in practice.
One option is to put this behaviour behind a flag, so the new behaviour is opt-in, as is suggested in #24?
This is a somewhat breaking change if someone relied of the old way of inventing functions, but on the other hand, it didn't produce valid GF expressions in those cases, so it's unlikely that anything would break in practice.
One option is to put this behaviour behind a flag, so the new behaviour is opt-in, as is suggested in #24?