From 7d65067ddbc5bb35bf673c1f447a49073ba53d1c Mon Sep 17 00:00:00 2001 From: "antti.arppe@iki.fi" Date: Mon, 4 Mar 2024 20:00:44 -0700 Subject: [PATCH] Added rule for adding back the prefix boundary markers. --- src/fst/verb_lexicon.xfscript.in | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/fst/verb_lexicon.xfscript.in b/src/fst/verb_lexicon.xfscript.in index 43b743dd..5fb692fb 100644 --- a/src/fst/verb_lexicon.xfscript.in +++ b/src/fst/verb_lexicon.xfscript.in @@ -101,6 +101,13 @@ read regex [Stems PostverbalAffixes] .o. "=" -> "=" OuterAffixes; define WordForms; +# Rewrite rule for resurrecting the prefix boundary markers + +define ShowBoundaries [ "@P.PREFIX.INNER@" -> "." , + "@P.PREFIX.MIDDLE@" -> "_" , + "@P.PREFIX.OUTER@" -> "=" +]; + # Concatenate ObliqueAffixes and the other inflectional FSTs. read regex WordForms .o. [..] -> ObliqueAffixes || .#. _; @@ -125,6 +132,14 @@ set flag-is-epsilon ON # the the morphological component one-by-one for faster compilation. regex [Grammar Tags] .o. MorphoPhonology ; +define VerbModel + +# Make flags visible, so that they can be converted to explicit boundary markers +set flag-is-epsilon ON + +# Output boundary markers based on flags + +regex VerbModel .o. ShowBoundaries ; # regex [Grammar Tags] .o. deletePrefixI .o. hToneSpreading .o. hToneSpreadingCleanup .o. deleteBoundarySymbol .o. uBeforeA .o. aBeforeI .o. lowABeforeI .o. iBeforeA .o. iBeforeO .o. uBeforeO .o. lInitialStemsSbjPl2 .o. lInitialStemsSbjPl2Cleanup .o. slDissimilation .o. zhDevoicing .o. zDevoicing;