kowey / GenI

Surface realiser (part of a Natural Language Generation system) using Tree Adjoining Grammar
GNU General Public License v2.0
21 stars 2 forks source link

percolate features during morphological realisation #7

Open kowey opened 11 years ago

kowey commented 11 years ago

The morphological realisation (built-in) is dumb in that it unifies each pre-terminal node of the derived tree independently with the morphological lexicon.

This is not good, because it does not allow for mutually exclusive realisations: he holds the apple vs you hold the apple

Right now, the workaround is to supply the necessary features via the input semantics (morphinfo file), but ideally you should be able to just make it work automatically.

kowey commented 11 years ago

Imported from trac issue 7. Created by kowey on 1970-01-01T01:20:38, last modified: 1970-01-01T01:20:54

kowey commented 11 years ago

Trac comment by kowey on 1970-01-01 01:20:52:

Alexandre has entry in his lexicon which looks like this:

"chambre" n(?P ! gender:Fem) semantics:[participant(?P) objType(?P "chambre")]

This represents as alternative workaround to the lack of percolation during morph realisation, which is to supply the morph features through the lexicon.

According to Alex, this is not desirable. The information is redundant with that which is already present in the morphological lexicon.

If we had feature percolation, then this would just work.

kowey commented 11 years ago

Trac comment by kowey on 1970-01-01 01:20:54:

This is actually quite easy to fix. It's a bug in the new standalone sillymorph package, which unifies each word independtly of the other. The right thing to do is not to mapM on the list monad (we use the list monad for prolog-style non-determinism because each word may have more than one realisation), but to foldM instead, passing in the unification variable substitutions along the way.