[libvoikko] Proposed interface for hyphenator components
Harri Pitkänen
hatapitk at iki.fi
Mon Dec 7 20:01:15 EET 2009
On Monday 07 December 2009 02:55:46 Krister Lindén wrote:
> Other effects on the spelling could also be modeled with this, but the
> consolidated output assumes that the effects of hyphenation are always
> local, i.e. there are no discontinuous side-effects further away in the
> string for hyphenating at one point and that any changes in the input
> string surrounding the introduced hyphen relate to this hyphen, i.e. the
> first non-changing character on either side of a hyphen breaks the need
> to modify the input string.
If I understood correctly, array
q q 0
w w 1
e é 1
a a 0
would result in hyphenations "qw-éa" and "qwé-a". First I thought that it is
not possible to represent case where the word should be hyphenated as
{"qw-ea", "qwé-a"} or {"qw-éa", "qwe-a"} meaning that changes in one letter
syllables cannot be forced to appear only on one side of the hyphenation
point. But perhaps if we want to hyphenate "qwea" as {"qw-ea", "qwé-a"} we
could use a zero length insertion like this:
q q 0
w w 1
0
e é 1
a a 0
It seems like this format could be enough for our needs.
Harri
More information about the Libvoikko
mailing list