timarkh / uniparser-morph

Rule-based, linguist-friendly (and rather slow) morphological analysis
MIT License
5 stars 2 forks source link

Show underlying form in glossing? #1

Closed fmatter closed 2 years ago

fmatter commented 2 years ago

Just wondering: how difficult would it be to implement a functionality where the "underlying" or "full" form of a morpheme is shown in interlinear glossing? So one could get something like this:

wonse womï-se enter-PST 'entered'

(Yawarana womï undergoes the regular process of syllable reduction, yielding won in certain forms).

timarkh commented 2 years ago

Good idea! I'm working on it.

timarkh commented 2 years ago

I guess I implemented what you wanted, see details here: https://uniparser-morph.readthedocs.io/en/latest/format.html#standardized-underlying-form-of-morphemes . Could you maybe test if it works as intended before I release a new version?

fmatter commented 2 years ago

Will try tomorrow!

fmatter commented 2 years ago

Put together a MWE: uniparser-mwe.zip; the idea being that wonse is underlyingly womï-che (disclaimer: not actually true).

The analyzed wordform has womï as its std value; -che is nowhere to be seen. From what I can glean from the documentation, I would expect this:

wf: wonse wfGlossed: won-se wfGlossedStd: womï-che gloss: enter-PST

timarkh commented 2 years ago

The problem in your example is that you did not put a dot at the end of the stem, so the analyzer cannot build a valid word out of your stem and affix.

fmatter commented 2 years ago

I've just tried it again and it is in fact working even without the period. I think I may have been using the wrong version when I built the MWE 🤦. This does exactly what I was thinking of, thanks for the incredibly quick work!

timarkh commented 2 years ago

Perfect!