Module lex
source code
Ewan Klein, March 2007
Experimental module to provide support for implementing English
morphology by feature unification.
Main challenge is to find way of encoding morphosyntactic rules.
Current idea is to let a concatenated form such as 'walk + s' be encoded
as a dictionary 'stem': 'walk', 'affix': 's'
. This allows
the morpho-phonological representation to undergo unification in the
normal way.
|
Phon
A Phon object is just a stem and an affix.
|
|
phon_representer(dumper,
data)
Output 'phon' values in 'stem + affix' notation. |
source code
|
|
|
|
|
phon_constructor(loader,
node)
Recognize 'stem + affix' as Phon objects in YAML. |
source code
|
|
|
|
Turn input into non-Unicode strings without spaces. Return a Variable
if input is of the form '?name'.
|