These are defined in MORPHGEN.LSP
:
EA-CatAndSkeletonToWords (cat skeleton)
: This is the main
routine. It returns a list of words, each element corresponding to one
of the possible inflectional forms for the feature-set cat
.
skeleton
is a list of strings giving the root morphemes. In
general, you will not construct a skeleton yourself, but will get it by
calling EA-ParseTreeToSkeleton
or
EA-LexicalEntryToSkeleton
.
Most calls of this routine will only return a one-element list. However, in a few cases there will be several alternative forms. At present, these are (as far as I know) only hyphenation variants: see section 3.4.
EA-ParseTreeToSkeleton (tree)
:
tree
must be a word-structure parse-tree, as returned by
D-LookUp
in 'D-WORDSTRUCTURE
format. This function returns
the corresponding word skeleton.
EA-LexicalEntryToSkeleton (entry)
:
Returns a skeleton, given a lexical entry. This is so that if a function
wants to look up a lexical entry directly, it doesn't have to know how
to convert the entry into a skeleton.
EA-ParseTreeToCat (tree)
:
Returns the top-level feature-set from tree
. This is just a
utility so that if a function which needs the skeleton also needs the
feature-set, it doesn't have to know the format of the parse tree.
EA-LoadIFI (filename)
:
The IFI is a special index which is used to locate irregular forms such
as the past tense of strong verbs. This function reads and returns the
IFI stored in the file named <filename>-ifi.ma
.
These functions may be changed in future versions. The comments at the
head of MORPHGEN.LSP
will always give an up-to-date
specification. To use the functions, you need various other things:
GENINFL +
feature added to inflectional suffixes in the
lexicon, and a GENINFL -
feature for derivational suffixes. You
also need a feature declaration for GENINFL
.
D-MakeLexicon
.
The comments heading MORPHGEN.LSP
describe how to do all this,
and are where you should look if you are going to use the functions. I
also describe how to do these things below, but since this report is a
more general account of the problems encountered and solutions chosen,
it is less suitable as a programmer's reference.