From ac4797f854f24247ab1fe14e5a905fdc2789d265 Mon Sep 17 00:00:00 2001 From: Inari Listenmaa Date: Mon, 21 Aug 2017 10:26:00 +0300 Subject: [PATCH 1/2] Add oper 'shortPronoun' for creating the short forms of the personal pronouns --- src/estonian/MorphoEst.gf | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/estonian/MorphoEst.gf b/src/estonian/MorphoEst.gf index dc839eb5c..9e1cd9275 100644 --- a/src/estonian/MorphoEst.gf +++ b/src/estonian/MorphoEst.gf @@ -543,6 +543,26 @@ caseTable : Number -> CommonNoun -> Case => Str = \n,cn -> _ => x } ; + shortPronoun : (_,_,_,_ : Str) -> Number -> Person -> + {s : NPForm => Str ; a : Agr} = + \ma, mu, mind, minu, n, p -> + let shortMa = mkPronoun ma mu mind n p ; + mulle : Str = case mu of { + "mu" => "mulle" ; + "su" => "sulle" ; + _ => shortMa.s ! NPCase Allat + } ; + + in shortMa ** { s = table { + NPCase Allat => mulle ; + NPCase Transl => minu + "ks" ; + NPCase Ess => minu + "na" ; + NPCase Abess => minu + "ta" ; + NPCase Comit => minu + "ga" ; + NPCase Termin => minu + "ni" ; + x => shortMa.s ! x } } ; + + -- TODO: this does not seem to be called from anyway mkDemPronoun : (_,_,_,_,_ : Str) -> Number -> {s : NPForm => Str ; a : Agr} = From 57242a05ba7f33b519789e3fc56d0fd95dcb34d0 Mon Sep 17 00:00:00 2001 From: Inari Listenmaa Date: Mon, 21 Aug 2017 10:26:50 +0300 Subject: [PATCH 2/2] =?UTF-8?q?Add=20short=20forms=20of=20personal=20prono?= =?UTF-8?q?uns=20;=20add=20v=C3=B5ib-olla=20for=20maybe=5FAdv=20;=20fix=20?= =?UTF-8?q?some=20nationality=20adjectives=20to=20use=20invA=20instead=20o?= =?UTF-8?q?f=20mkA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/translator/DictionaryEst.gf | 59 ++++++++++++++++++++++----------- 1 file changed, 39 insertions(+), 20 deletions(-) diff --git a/src/translator/DictionaryEst.gf b/src/translator/DictionaryEst.gf index da3c3c686..0316b5709 100644 --- a/src/translator/DictionaryEst.gf +++ b/src/translator/DictionaryEst.gf @@ -4,10 +4,29 @@ concrete DictionaryEst of Dictionary = CatEst ** open ParadigmsEst, (S = StructuralEst), (L = LexiconEst), (R = ResEst), -MorphoEst, SyntaxEst, (E = ExtraEst), Prelude in { +(M = MorphoEst), SyntaxEst, (E = ExtraEst), Prelude in { flags coding=utf8 ; +oper +-- Short forms of pronouns. No gender difference in any of them. +sgP1Pron = S.i_Pron | lin Pron (M.shortPronoun "ma" "mu" "mind" "minu" R.Sg R.P1) ; +sgP2Pron = S.youSg_Pron | lin Pron (M.shortPronoun "sa" "su" "sind" "sinu" R.Sg R.P2) ; +sgP3Pron = S.he_Pron | lin Pron (M.shortPronoun "ta" "ta" "teda" "tema" R.Sg R.P3) ; +plP1Pron = S.we_Pron | lin Pron (M.shortPronoun "me" "meie" "meid" "meie" R.Pl R.P1) ; +plP2Pron = S.youPl_Pron | lin Pron (M.shortPronoun "te" "teie" "teid" "teie" R.Pl R.P2) ; +plP3Pron = S.they_Pron | lin Pron nad_Pron + where { + shortNad =M.shortPronoun "nad" + "neie" -- only to use the "nei" stem in the cases based on genitive! + "neid" "nende" + R.Pl R.P3 ; + nad_Pron = shortNad ** + { s = table { + R.NPCase R.Gen => "nende" ; -- use "nende" in the actual genitive! + x => shortNad.s ! x } } + } ; + -- TODO: check lin a_priori_A = D.aprioorne_A ; @@ -4265,7 +4284,7 @@ lin builder_N = D.ehitaja_N ; lin building_N = D.ehitis_N ; lin buildup_N = D.kogumine_N ; lin bulb_N = D.elektripirn_N ; -lin bulgarian_A = mkA (mkN "bulgaaria") Invariable ; +lin bulgarian_A = invA "bulgaaria" ; lin bulge_N = mkN "kummuma" ; lin bulge_V = D.kummuma_V ; lin bulge_V2 = mkV2 "kummuma" ; @@ -5055,7 +5074,7 @@ lin cataclysmic_A = mkA "kataklüsmiline" ; lin catacomb_N = D.katakomb_N ; lin catadromous_A = mkA "katadroomne" ; lin catafalque_N = D.katafalk_N ; -lin catalan_A = mkA (mkN "katalaani") Invariable ; +lin catalan_A = invA "katalaani" ; lin catalase_N = mkN "katalaas" ; lin catalectic_A = mkA "katalektiline" ; lin catalectic_N = mkN "katalektiline" ; @@ -12363,7 +12382,7 @@ lin finisher_N = D.viimistleja_N ; lin finite_A = D.finiitne_A ; lin finiteness_N = D.'lõplikkus_N' ; lin fink_N = D.vasikas_N ; -lin finnish_A = mkA "soome" ; +lin finnish_A = invA "soome" ; lin fiord_N = D.fjord_N ; lin fir_N = D.kuusk_N ; lin fir_cone_N = mkN "kuusekäbi" ; @@ -15089,7 +15108,7 @@ lin hazelnut_N = D.'pähkel_N' ; lin haziness_N = mkN "hägusus" ; lin hazy_A = D.'ähmane_A' ; lin he_N = mkN "ta" ; -lin he_Pron = S.he_Pron ; +lin he_Pron = sgP3Pron ; lin head_A = mkA "juht" ; lin head_N = L.head_N ; lin head_V = mkV "juhtima" ; @@ -16143,8 +16162,8 @@ lin hysteric_A = mkA "hüsteerik" ; lin hysteric_N = D.'hüsteerik_N' ; lin hysterical_A = D.'hüsteeriline_A' ; lin hysterics_N = D.'hüsteeriahoog_N' ; -lin iFem_Pron = S.i_Pron ; ---- to check -lin i_Pron = S.i_Pron ; +lin iFem_Pron = sgP1Pron ; +lin i_Pron = sgP1Pron ; lin iamb_N = D.jamb_N ; lin iambic_A = mkA "jambiline" ; lin iambic_N = mkN "jambiline" ; @@ -19272,7 +19291,7 @@ lin maxim_N = D.maksiim_N ; lin maximal_A = D.maksimaalne_A ; lin maximum_A = mkA "maksimum" ; lin maximum_N = D.maksimum_N ; -lin maybe_Adv = ParadigmsEst.mkAdv "ehk" ; +lin maybe_Adv = ParadigmsEst.mkAdv "võib-olla" | ParadigmsEst.mkAdv "ehk" ; lin mayday_N = mkN "hädasignaal" ; lin mayfly_N = D.'ühepäevaliblikas_N' ; lin mayonnaise_N = D.majonees_N ; @@ -26381,7 +26400,7 @@ lin shatterproof_A = mkA "purunemiskindel" ; lin shaver_N = D.pardel_N ; lin shaving_brush_N = D.vahupintsel_N ; lin shawl_N = D.'rätik_N' ; -lin she_Pron = S.she_Pron ; +lin she_Pron = sgP3Pron ; lin sheaf_N = D.vihk_N ; lin shear_N = mkN "lõikama" ; lin shear_V2 = D.'lõikama_V2' ; @@ -28649,7 +28668,7 @@ lin sweat_V2 = mkV2 "higistama" ; lin sweater_N = D.sviiter_N ; lin sweatshirt_N = mkN "dressipluus" ; lin sweaty_A = mkA "higistamapanev" ; -lin swedish_A = mkA "rootsi" ; +lin swedish_A = invA "rootsi" ; lin sweep_N = D.piirjoon_N ; lin sweep_V = mkV "pühkima" ; lin sweep_V2 = D.'pühkima_V2' ; @@ -29380,8 +29399,8 @@ lin thermostatic_A = mkA "termostaatiline" ; lin thesaurus_N = D.tesaurus_N ; lin thesis_N = D.teema_N ; lin theta_N = mkN "teeta" ; -lin theyFem_Pron = S.they_Pron ; ---- to check -lin they_Pron = S.they_Pron ; +lin theyFem_Pron = plP3Pron ; +lin they_Pron = plP3Pron ; lin thick_A = L.thick_A ; lin thick_Adv = ParadigmsEst.mkAdv "paks" ; lin thick_N = mkN "paks" ; @@ -31804,8 +31823,8 @@ lin waxwing_N = D.siidisaba_N ; lin way_Adv = ParadigmsEst.mkAdv "liigagi" ; lin way_N = mkN "liigagi" ; lin wayward_A = D.'tõrges_A' ; -lin weFem_Pron = S.we_Pron ; ---- to check -lin we_Pron = S.we_Pron ; +lin weFem_Pron = plP1Pron ; +lin we_Pron = plP1Pron ; lin weak_A = D.'nõrk_A' ; lin weaken_V = mkV "nõrgendama" ; lin weaken_V2 = mkV2 "nõrgendama" ; @@ -32414,12 +32433,12 @@ lin yoke_V2 = mkV2 "ikestama" ; lin yokel_N = mkN "maakas" ; lin yolk_N = D.munakollane_N ; lin yonder_A = mkA "seal" ; -lin youPlFem_Pron = S.youPl_Pron ; ---- to check -lin youPl_Pron = S.youPl_Pron ; -lin youPolFem_Pron = S.youPol_Pron ; ---- to check -lin youPol_Pron = S.youPol_Pron ; -lin youSgFem_Pron = S.youSg_Pron ; ---- to check -lin youSg_Pron = S.youSg_Pron ; +lin youPlFem_Pron = plP2Pron ; +lin youPl_Pron = plP2Pron ; +lin youPolFem_Pron = plP2Pron ; +lin youPol_Pron = plP2Pron ; +lin youSgFem_Pron = sgP2Pron ; +lin youSg_Pron = sgP2Pron ; lin young_A = L.young_A ; lin young_N = D.noor_N ; lin younger_A = D.noorem_A ;