Inflectional rules

  • associate an ending and an inflectional class with a morphological form
  • in managing rules from delimited-text files, different types of morphological forms are represented by appropriate property values
  • rules can be read from delimited-text source with readrulerow

Example

Read a rule from delimited text:

using Kanones
delimited = "adjinfl.osaon1|os_a_on|ος|masculine|nominative|singular|positive|"
adjio = Kanones.AdjectiveIO("adjectives")
rule = Kanones.readrulerow(adjio, delimited)
AdjectiveRule(adjinfl.osaon1, "os_a_on", "ος", GMPGender(1), GMPCase(1), GMPNumber(1), GMPDegree(1))

Find its RuleUrn:

ruleurn(rule)
adjinfl.osaon1

Find its inflectional type and inflectional ending:

inflectionclass(rule)
"os_a_on"
ending(rule)
"ος"

morphological data

formabbr = formurn(rule) expectedabbr = FormUrn("forms.7010001110") @test formabbr == expectedabbr

formcode = code(rule) expectedcode = "7010001110" @test formcode == expectedcode