From 6f89da4591c97a97096be957fae3eaedbaf195b6 Mon Sep 17 00:00:00 2001 From: aarne Date: Fri, 20 Jan 2006 21:57:33 +0000 Subject: [PATCH] French structural words and VV --- lib/resource-1.0/french/DiffFre.gf | 2 ++ lib/resource-1.0/french/StructuralFre.gf | 35 +++++++++++++++-------- lib/resource-1.0/french/VerbsFre.gf | 2 +- lib/resource-1.0/romance/CommonRomance.gf | 8 +++++- lib/resource-1.0/romance/DiffRomance.gf | 2 ++ lib/resource-1.0/romance/ResRomance.gf | 8 ++++++ lib/resource-1.0/romance/VerbRomance.gf | 3 +- 7 files changed, 45 insertions(+), 15 deletions(-) diff --git a/lib/resource-1.0/french/DiffFre.gf b/lib/resource-1.0/french/DiffFre.gf index 2846d62e8..324729ef4 100644 --- a/lib/resource-1.0/french/DiffFre.gf +++ b/lib/resource-1.0/french/DiffFre.gf @@ -58,6 +58,8 @@ instance DiffFre of DiffRomance = open CommonRomance, PhonoFre, Prelude in { conjThan = elisQue ; + clitInf cli inf = cli ++ inf ; + copula : Verb = {s = table VF ["être";"suis";"es";"est";"sommes";"êtes";"sont";"sois";"sois";"soit";"soyons";"soyez";"soient";"étais";"étais";"était";"étions";"étiez";"étaient";"fusse";"fusses";"fût";"fussions";"fussiez";"fussent";"fus";"fus";"fut";"fûmes";"fûtes";"furent";"serai";"seras";"sera";"serons";"serez";"seront";"serais";"serais";"serait";"serions";"seriez";"seraient";"sois";"soyons";"soyez";"été";"étés";"étée";"étées";"étant"]; vtyp=VHabere} ; avoir_V : Verb = {s=table VF ["avoir";"ai";"as";"a";"avons";"avez";"ont";"aie";"aies";"ait";"ayons";"ayez";"aient";"avais";"avais";"avait";"avions";"aviez";"avaient";"eusse";"eusses";"eût";"eussions";"eussiez";"eussent";"eus";"eus";"eut";"eûmes";"eûtes";"eurent";"aurai";"auras";"aura";"aurons";"aurez";"auront";"aurais";"aurais";"aurait";"aurions";"auriez";"auraient";"aie";"ayons";"ayez";"eu";"eus";"eue";"eues";"ayant"];vtyp=VHabere}; diff --git a/lib/resource-1.0/french/StructuralFre.gf b/lib/resource-1.0/french/StructuralFre.gf index a134e0068..0d4c418dc 100644 --- a/lib/resource-1.0/french/StructuralFre.gf +++ b/lib/resource-1.0/french/StructuralFre.gf @@ -1,5 +1,5 @@ concrete StructuralFre of Structural = CatFre ** - open PhonoFre, MorphoFre, ParadigmsFre, Prelude in { + open PhonoFre, MorphoFre, ParadigmsFre, VerbsFre, Prelude in { flags optimize=all ; @@ -7,8 +7,9 @@ lin above_Prep = {s = ["au dessus"] ; c = genitive ; isDir = False} ; after_Prep = mkPreposition "après" ; --- all_Predet = toutDet ; + all_Predet = {s = aagrForms "tout" "toute" "tous" "toutes"} ; almost_AdA, almost_AdN = ss "presque" ; + always_AdV = ss "toujours" ; although_Subj = ss ("bien" ++ elisQue) ** {m = Conjunct} ; and_Conj = ss "et" ** {n = Pl} ; because_Subj = ss ("parce" ++ elisQue) ** {m = Indic} ; @@ -16,21 +17,26 @@ lin behind_Prep = mkPreposition "derrière" ; between_Prep = mkPreposition "entre" ; both7and_DConj = {s1,s2 = "et" ; n = Pl} ; + but_PConj = ss "mais" ; by8agent_Prep = mkPreposition "par" ; by8means_Prep = mkPreposition "par" ; --- can8know_VV = mkVerbVerbDir (verbPres (conj3savoir "savoir") AHabere) ; --- can_VV = mkVerbVerbDir (verbPres (conj3pouvoir "pouvoir") AHabere) ; + can8know_VV = mkVV (savoir_V2 ** {lock_V = <>}) ; + can_VV = mkVV pouvoir_V ; during_Prep = mkPreposition "pendant" ; either7or_DConj = {s1,s2 = "ou" ; n = Pl} ; -- everybody_NP = mkNameNounPhrase ["tout le monde"] Masc ; every_Det = {s = \\_,_ => "chaque" ; n = Sg} ; -- everything_NP = mkNameNounPhrase ["tout"] Masc ; everywhere_Adv = ss "partout" ; + first_Ord = {s = \\ag => (regA "premier").s ! Posit ! AF ag.g ag.n} ; from_Prep = complGen ; --- he_Pron = mkPronoun "il" (elision "l") "lui" "lui" "son" (elisPoss "s") "ses" Masc Sg P3 Clit2 ; + here7from_Adv = ss "d'ici" ; + here7to_Adv = ss "ici" ; + here_Adv = ss "ici" ; how_IAdv = ss "comment" ; how8many_IDet = {s = \\_ => "combien" ++ elisDe ; n = Pl} ; if_Subj = ss elisSi ** {m = Indic} ; @@ -44,13 +50,16 @@ lin mkPronoun "il" (elision "l") "lui" "lui" "son" (elisPoss "s") "ses" Masc Sg P3 Clit2 ; + less_CAdv = ss "moins" ; -- many_Det = mkDeterminer1 plural "plusieurs" ; -- most8many_Det = plupartDet ; -- most_Det = mkDeterminer1 singular (["la plupart"] ++ elisDe) ; --- de -- much_Det = mkDeterminer1 singular ("beaucoup" ++ elisDe) ; --- de --- must_VV = mkVerbVerbDir (verbPres (conj3devoir "devoir") AHabere) ; + must_VV = mkVV (devoir_V2 ** {lock_V = <>}) ; no_Phr = ss "non" ; --- and also Si! on_Prep = mkPreposition "sur" ; + one_Quant = {s = \\g,c => prepCase c ++ genForms "un" "une" ! g} ; + only_Predet = {s = \\_ => "seulement"} ; --- seul(e)(s) or_Conj = {s = "ou" ; n = Sg} ; otherwise_PConj = ss "autrement" ; part_Prep = complGen ; @@ -69,6 +78,9 @@ lin somewhere_Adv = ss ["quelque part"] ; --- ne - pas -- that_Det = mkDeterminer singular (pre {"ce" ; "cet" / voyelle}) "cette" ; --- là -- that_NP = mkNameNounPhrase ["ça"] Masc ; + there7from_Adv = ss "de là" ; + there7to_Adv = ss "là" ; --- y + there_Adv = ss "là" ; therefore_PConj = ss "donc" ; -- these_NDet = mkDeterminerNum "ces" "ces" ; --- ci -- they_Pron = pronNounPhrase pronIls ; @@ -84,28 +96,27 @@ lin to_Prep = complDat ; under_Prep = mkPreposition "sous" ; very_AdA = ss "très" ; --- want_VV = mkVerbVerbDir (verbPres (conj3vouloir "vouloir") AHabere) ; + want_VV = mkVV (vouloir_V2 ** {lock_V = <>}) ; we_Pron = mkPronoun "nous" "nous" "nous" "nous" "notre" "notre" "nos" Fem Pl P1 Clit3 ; - whatSg_IP = {s = \\_ => "quoi" ; a = aagr Fem Sg} ; --- what8many_IP = intPronWhat plural ; + whatSg_IP = {s = \\c => prepCase c ++ "quoi" ; a = aagr Fem Sg} ; + whatPl_IP = {s = \\c => prepCase c ++ "quoi" ; a = aagr Fem Pl} ; when_IAdv = ss "quand" ; when_Subj = ss "quand" ** {m = Indic} ; where_IAdv = ss "où" ; -- which8many_IDet = mkDeterminerNum "quels" "quelles" ** {n = Pl} ; -- which8one_IDet = quelDet ; - whoSg_IP = {s = \\_ => "qui" ; a = aagr Fem Sg} ; --- who8many_IP = intPronWho plural ; + whoSg_IP = {s = \\c => prepCase c ++ "qui" ; a = aagr Fem Sg} ; + whoPl_IP = {s = \\c => prepCase c ++ "qui" ; a = aagr Fem Pl} ; why_IAdv = ss "pourquoi" ; without_Prep = mkPreposition "sans" ; with_Prep = mkPreposition "avec" ; - ye_Pron = + ye_Pron, you_Pron = mkPronoun "vous" "vous" "vous" "vous" "votre" "votre" "vos" Fem Pl P2 Clit3 ; yes_Phr = ss "oui" ; --- si --- you_Pron = pronNounPhrase pronVous ; } diff --git a/lib/resource-1.0/french/VerbsFre.gf b/lib/resource-1.0/french/VerbsFre.gf index 6f5c12ba2..db75815c0 100644 --- a/lib/resource-1.0/french/VerbsFre.gf +++ b/lib/resource-1.0/french/VerbsFre.gf @@ -390,6 +390,6 @@ lin vêtir_V2 = v_besch26 "vêtir" ** {vtyp = VHabere ; lock_V2 = <> ; c2 = complAcc} ; vivre_V2 = v_besch76 "vivre" ** {vtyp = VHabere ; lock_V2 = <> ; c2 = complAcc} ; voir_V2 = v_besch39 "voir" ** {vtyp = VHabere ; lock_V2 = <> ; c2 = complAcc} ; - vouloir_V2 = v_besch48 "vouloir" ** {vtyp = VHabere ; lock_V2 = <> ; c2 = complGen} ; + vouloir_V2 = v_besch48 "vouloir" ** {vtyp = VHabere ; lock_V2 = <> ; c2 = complAcc} ; } diff --git a/lib/resource-1.0/romance/CommonRomance.gf b/lib/resource-1.0/romance/CommonRomance.gf index bc6dfeda0..1b997ad08 100644 --- a/lib/resource-1.0/romance/CommonRomance.gf +++ b/lib/resource-1.0/romance/CommonRomance.gf @@ -17,6 +17,12 @@ resource CommonRomance = ParamRomance ** open Prelude in { Fem => bonne } ; + aagrForms : (x1,_,_,x4 : Str) -> (AAgr => Str) = \tout,toute,tous,toutes -> + table { + {g = g ; n = Sg} => genForms tout toute ! g ; + {g = g ; n = Pl} => genForms tous toutes ! g + } ; + Noun = {s : Number => Str ; g : Gender} ; VP : Type = { @@ -44,7 +50,7 @@ resource CommonRomance = ParamRomance ** open Prelude in { VPAgrNone -- elle a dormi | VPAgrSubj -- elle est partie, elle s'est vue | VPAgrClit -- elle les a vues - {g : Gender ; n : Number} ; + {g : Gender ; n : Number} ; } diff --git a/lib/resource-1.0/romance/DiffRomance.gf b/lib/resource-1.0/romance/DiffRomance.gf index dfc3875ae..f50f900c0 100644 --- a/lib/resource-1.0/romance/DiffRomance.gf +++ b/lib/resource-1.0/romance/DiffRomance.gf @@ -32,6 +32,8 @@ oper conjThan : Str ; + clitInf : Str -> Str -> Str ; + -- These needed above. param diff --git a/lib/resource-1.0/romance/ResRomance.gf b/lib/resource-1.0/romance/ResRomance.gf index 6c04c4966..d7dce7b65 100644 --- a/lib/resource-1.0/romance/ResRomance.gf +++ b/lib/resource-1.0/romance/ResRomance.gf @@ -145,6 +145,14 @@ oper subj ++ neg.p1 ++ clit ++ verb ++ neg.p2 ++ inf ++ compl } ; + infVP : VP -> Agr -> Str = \vp,agr -> + let + inf = (vp.s ! VPInfinit Simul).inf ! (aagr agr.g agr.n) ; + neg = vp.neg ! Pos ; --- Neg not in API + cli = vp.clit1 ! agr ++ vp.clit2 ; + obj = vp.comp ! agr + in + clitInf cli inf ++ obj ; } diff --git a/lib/resource-1.0/romance/VerbRomance.gf b/lib/resource-1.0/romance/VerbRomance.gf index dd0a0f604..e03ca9682 100644 --- a/lib/resource-1.0/romance/VerbRomance.gf +++ b/lib/resource-1.0/romance/VerbRomance.gf @@ -10,8 +10,9 @@ incomplete concrete VerbRomance of Verb = ComplV3 v np np2 = insertObject v.c3 np2 (insertObject v.c2 np (predV v)) ; + ComplVV v vp = insertComplement (\\a => prepCase v.c2.c ++ infVP vp a) (predV v) ; + {- - ComplVV v vp = insertObj (\\a => v.c2 ++ infVP vp a) (predV v) ; ComplVS v s = insertObj (\\_ => conjThat ++ s.s ! Sub) (predV v) ; ComplVQ v q = insertObj (\\_ => q.s ! QIndir) (predV v) ;