User:Wshi2/Final project
Apertium based Automatic Interlinear Gloss Generator
Get it here: [1]
To use the autoglosser, enter the following:
echo "your sentence here" | python3 autoglosser.py --igtdef <igt file> --inputlang <ISO code> --glosslang <ISO code> --biltrans <bilingual transducer directory>
The igt file should have 5 columns, which are, from left to right: lemma, part of speech, morphological tags, prefixes, and suffixes. The first three columns describe the context, and the last two columns describe how it should be glossed.
For example:
lemma POS tags pref suff - n pl - -PL sheep n pl - [PL] - - perf - .PFV - - p3.sg 3SG- -
The first line says that when we have a plural noun, it should be glossed with a “-PL” suffix. The second line is more specific, and says that if we have “sheep<n><pl>”, then it should be glossed with a “[PL]” instead. The autoglosser should prefer using the more specific glossing rules if they exist. The third line says that perfective words should be tagged with “.PFV”, the standard interlinear gloss abbreviation. Finally, the fourth line says that words tagged with both third person and singular should get a “3SG” prefix.