mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
Romance negative polarity of NP, Det. Quant: the positive form (and direct translation) of "he loves no woman" is "il n'aime aucune femme", "lui non ama nessuna donna", etc.
This commit is contained in:
@@ -316,7 +316,7 @@ oper
|
||||
}
|
||||
} ;
|
||||
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False} ** {lock_NP = <>} ;
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False ; isNeg = False} ** {lock_NP = <>} ;
|
||||
|
||||
mk5A a b c d e =
|
||||
compADeg {s = \\_ => (mkAdj a b c d e).s ; isPre = False ; lock_A = <>} ;
|
||||
|
||||
@@ -30,11 +30,11 @@ lin
|
||||
during_Prep = mkPrep "durant" ; ----
|
||||
either7or_DConj = {s1,s2 = "o" ; n = Sg} ;
|
||||
everybody_NP = makeNP ["tothom"] Masc Sg ;
|
||||
every_Det = {s,sp = \\_,_ => "cada" ; n = Sg ; s2 = []} ;
|
||||
every_Det = {s,sp = \\_,_ => "cada" ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
everything_NP = pn2np (mkPN "tot" Masc) ;
|
||||
everywhere_Adv = ss ["a tot arreu"] ;
|
||||
few_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "pocs" "poques" ! g ; n = Pl ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "pocs" "poques" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
--- first_Ord = {s = \\ag => (regA "primer").s ! Posit ! AF ag.g ag.n} ;
|
||||
for_Prep = mkPrep ["per a"] ;
|
||||
from_Prep = complGen ; ---
|
||||
@@ -64,12 +64,12 @@ lin
|
||||
|
||||
less_CAdv = X.mkCAdv "menys" conjThan ; ----
|
||||
many_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "molts" "moltes" ! g ; n = Pl ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "molts" "moltes" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
more_CAdv = X.mkCAdv "més" conjThan ;
|
||||
most_Predet = {s = \\_,c => prepCase c ++ ["la majoria"] ; c = CPrep P_de ;
|
||||
a = PNoAg} ;
|
||||
much_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "molt" "molta" ! g ; n = Sg ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "molt" "molta" ! g ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
must_VV = mkVV (verbV (haver_59 "haver" True)) ; -- + of_Prep
|
||||
no_Utt = ss "no" ;
|
||||
on_Prep = mkPrep "sobre" ;
|
||||
@@ -90,9 +90,9 @@ lin
|
||||
so_AdA = ss "tan" ;
|
||||
somebody_NP = pn2np (mkPN ["alg˙"] Masc) ;
|
||||
somePl_Det = {s,sp =
|
||||
\\g,c => prepCase c ++ genForms "alguns" "algunes" ! g ; n = Pl ; s2 = []} ;
|
||||
\\g,c => prepCase c ++ genForms "alguns" "algunes" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
someSg_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algun" "alguna" ! g ; n = Sg ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algun" "alguna" ! g ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
something_NP = pn2np (mkPN ["quelcom"] Masc) ;
|
||||
somewhere_Adv = ss ["a algun lloc"] ;
|
||||
that_Quant =
|
||||
@@ -103,7 +103,7 @@ lin
|
||||
in {
|
||||
s = \\_ => aquell ;
|
||||
sp = aquell ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
there_Adv = mkAdv "allà" ; -- all·
|
||||
there7to_Adv = mkAdv ["cap a allà"] ;
|
||||
@@ -122,7 +122,7 @@ lin
|
||||
in {
|
||||
s = \\_ => aquest ;
|
||||
sp = aquest ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
through_Prep = mkPrep "mitjançant" ;
|
||||
too_AdA = ss "massa" ;
|
||||
@@ -184,10 +184,10 @@ lin
|
||||
in {
|
||||
s = \\_ => cap ;
|
||||
sp = cap ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = True
|
||||
} ;
|
||||
nobody_NP = pn2np (mkPN "ningú") ;
|
||||
nothing_NP = pn2np (mkPN "res") ;
|
||||
nobody_NP = pn2npNeg (mkPN "ningú") ;
|
||||
nothing_NP = pn2npNeg (mkPN "res") ;
|
||||
at_least_AdN = X.mkAdN "almenys" ;
|
||||
at_most_AdN = X.mkAdN "com a màxim" ;
|
||||
except_Prep = mkPrep "excepte" ;
|
||||
|
||||
@@ -222,4 +222,7 @@ instance DiffFre of DiffRomance = open CommonRomance, PhonoFre, Prelude in {
|
||||
"aurais";"aurais";"aurait";"aurions";"auriez";"auraient";--# notpresent
|
||||
"aie";"ayons";"ayez";"eu";"eus";"eue";"eues";"ayant"];vtyp=VHabere};
|
||||
|
||||
datClit = "y" ;
|
||||
genClit = "en" ;
|
||||
|
||||
}
|
||||
|
||||
@@ -43,11 +43,14 @@ concrete ExtraFre of ExtraFreAbs = ExtraRomanceFre **
|
||||
youPl8fem_Pron =
|
||||
let vous = mkPronoun "vous" "vous" "vous" "vous" "votre" "votre" "vos" Fem Pl P2
|
||||
in
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = False} ;
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = False ; isNeg = False} ;
|
||||
youPol8fem_Pron =
|
||||
let vous = mkPronoun "vous" "vous" "vous" "vous" "votre" "votre" "vos" Fem Pl P2
|
||||
in
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = True} ;
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = True ; isNeg = False} ;
|
||||
|
||||
AdvDatVP = insertClit3 datClit ;
|
||||
AdvGenVP = insertClit3 genClit ;
|
||||
|
||||
oper
|
||||
prepQue : Case -> Str = \c -> case c of {
|
||||
@@ -64,7 +67,8 @@ concrete ExtraFre of ExtraFreAbs = ExtraRomanceFre **
|
||||
s = \\g,c => prepCase c ++ genForms "tout" "toute" ! g ;
|
||||
sp = \\g,c => prepCase c ++ genForms "tout" "toute" ! g ;
|
||||
n = Sg ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
PNegNe = {s = [] ; p = RNeg True} ;
|
||||
|
||||
@@ -31,6 +31,12 @@ abstract ExtraFreAbs = ExtraRomanceAbs - [ProDrop] ** {
|
||||
youPl8fem_Pron : Pron ;
|
||||
youPol8fem_Pron : Pron ;
|
||||
|
||||
-- clitic adverbs
|
||||
|
||||
AdvDatVP : VP -> VP ; -- j'y vais
|
||||
AdvGenVP : VP -> VP ; -- j'en vais
|
||||
|
||||
|
||||
-- The determiner "tout" in the special use "tout nombre"
|
||||
|
||||
tout_Det : Det ;
|
||||
|
||||
@@ -179,7 +179,8 @@ oper
|
||||
} ;
|
||||
a = Ag g n p ;
|
||||
hasClit = True ;
|
||||
isPol = False
|
||||
isPol = False ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
elisPoss : Str -> Str = \s ->
|
||||
|
||||
@@ -421,7 +421,7 @@ oper
|
||||
--------------------------- obsolete
|
||||
|
||||
makeNP : Str -> Gender -> Number -> NP ;
|
||||
makeNP x g n = {s = (pn2np {s=x;g= g}).s; a = agrP3 g n ; hasClit = False ; isPol = False ; lock_NP = <>} ;
|
||||
makeNP x g n = {s = (pn2np {s=x;g= g}).s; a = agrP3 g n ; hasClit = False ; isPol = False ; isNeg = False ; lock_NP = <>} ;
|
||||
regPN : Str -> PN ;
|
||||
mk2PN : Str -> Gender -> PN = \x,g -> {s = x ; g = g} ** {lock_PN = <>} ;
|
||||
|
||||
|
||||
@@ -37,11 +37,12 @@ lin
|
||||
s = \\_,c => prepCase c ++ "chaque" ;
|
||||
sp = \\g,c => prepCase c ++ genForms "chacun" "chacune" ! g ;
|
||||
n = Sg ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
everything_NP = pn2np (mkPN ["tout"] Masc) ;
|
||||
everywhere_Adv = ss "partout" ;
|
||||
few_Det = {s,sp = \\g,c => prepCase c ++ "peu" ++ elisDe ; n = Pl ; s2 = []} ;
|
||||
few_Det = {s,sp = \\g,c => prepCase c ++ "peu" ++ elisDe ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
--- DEPREC first_Ord = {s = \\ag => (regA "premier").s ! Posit ! AF ag.g ag.n} ;
|
||||
for_Prep = mkPreposition "pour" ;
|
||||
from_Prep = complGen ; ---
|
||||
@@ -67,10 +68,10 @@ lin
|
||||
"il" (elision "l") "lui" "lui" "son" (elisPoss "s") "ses"
|
||||
Masc Sg P3 ;
|
||||
less_CAdv = X.mkCAdv "moins" conjThan ;
|
||||
many_Det = {s,sp = \\_,c => prepCase c ++ "plusieurs" ; n = Pl ; s2 = []} ;
|
||||
many_Det = {s,sp = \\_,c => prepCase c ++ "plusieurs" ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
more_CAdv = X.mkCAdv "plus" conjThan ;
|
||||
most_Predet = {s = \\_,c => prepCase c ++ ["la plupart"] ; c = CPrep P_de ; a = PNoAg} ;
|
||||
much_Det = {s,sp = \\_,c => prepCase c ++ "beaucoup" ++ elisDe ; n = Pl ; s2 = []} ;
|
||||
much_Det = {s,sp = \\_,c => prepCase c ++ "beaucoup" ++ elisDe ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
must_VV = mkVV (devoir_V2 ** {lock_V = <>}) ;
|
||||
---b no_Phr = ss "non" ;
|
||||
no_Utt = ss "non" ;
|
||||
@@ -90,8 +91,8 @@ lin
|
||||
|
||||
so_AdA = ss "si" ;
|
||||
somebody_NP = pn2np (mkPN ["quelqu'un"] Masc) ;
|
||||
somePl_Det = {s,sp = \\_,c => prepCase c ++ "quelques" ; n = Pl ; s2 = []} ; ---- sp
|
||||
someSg_Det = {s,sp = \\_,c => prepCase c ++ "quelque" ; n = Sg ; s2 = []} ; ----sp
|
||||
somePl_Det = {s,sp = \\_,c => prepCase c ++ "quelques" ; n = Pl ; s2 = [] ; isNeg = False} ; ---- sp
|
||||
someSg_Det = {s,sp = \\_,c => prepCase c ++ "quelque" ; n = Sg ; s2 = [] ; isNeg = False} ; ----sp
|
||||
something_NP = pn2np (mkPN ["quelque chose"] Masc) ;
|
||||
somewhere_Adv = ss ["quelque part"] ; --- ne - pas
|
||||
|
||||
@@ -105,7 +106,8 @@ lin
|
||||
Sg => \\g,c => prepCase c ++ genForms "celui-là" "celle-là" ! g ;
|
||||
Pl => \\g,c => prepCase c ++ genForms "ceux-là" "celles-là" ! g
|
||||
} ;
|
||||
s2 = [] ---- "-là"
|
||||
s2 = [] ; ---- "-là" ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
---b that_NP = makeNP ["cela"] Masc Sg ;
|
||||
@@ -128,7 +130,8 @@ lin
|
||||
Sg => \\g,c => prepCase c ++ genForms "celui-ci" "celle-ci" ! g ;
|
||||
Pl => \\g,c => prepCase c ++ genForms "ceux-ci" "celles-ci" ! g
|
||||
} ;
|
||||
s2 = [] ---- "-ci"
|
||||
s2 = [] ; ---- "-ci"
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
---b this_NP = pn2np (mkPN ["ceci"] Masc) ;
|
||||
@@ -173,7 +176,7 @@ lin
|
||||
youPol_Pron =
|
||||
let vous = mkPronoun "vous" "vous" "vous" "vous" "votre" "votre" "vos" Masc Pl P2
|
||||
in
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = True} ;
|
||||
{s = vous.s ; hasClit = vous.hasClit ; poss = vous.poss ; a = vous.a ; isPol = True ; isNeg = False} ;
|
||||
|
||||
not_Predet = {s = \\a,c => prepCase c ++ "pas" ; c = Nom ; a = PNoAg} ;
|
||||
|
||||
@@ -185,12 +188,13 @@ lin
|
||||
in {
|
||||
s = \\_ => aucun ;
|
||||
sp = aucun ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = True
|
||||
} ;
|
||||
if_then_Conj = {s1 = "si" ; s2 = "alors" ; n = Sg ; lock_Conj = <>} ;
|
||||
nobody_NP = pn2np (mkPN ["personne"] Fem) ;
|
||||
nobody_NP = pn2npNeg (mkPN ["personne"] Fem) ;
|
||||
|
||||
nothing_NP = pn2np (mkPN "rien" Masc) ;
|
||||
nothing_NP = pn2npNeg (mkPN "rien" Masc) ;
|
||||
at_least_AdN = ss "au moins" ;
|
||||
at_most_AdN = ss "au plus" ;
|
||||
|
||||
|
||||
@@ -199,4 +199,9 @@ instance DiffIta of DiffRomance = open CommonRomance, PhonoIta, BeschIta, Prelud
|
||||
copula = verbBesch (essere_1 "essere") ** {vtyp = VEsse} ;
|
||||
avere_V = verbBesch (avere_2 "avere") ** {vtyp = VHabere} ;
|
||||
venire_V = verbBesch (venire_110 "venire") ** {vtyp = VEsse} ;
|
||||
|
||||
datClit = "ci" ;
|
||||
genClit = "ne" ;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
concrete ExtraIta of ExtraItaAbs = ExtraRomanceIta **
|
||||
open CommonRomance, ParadigmsIta, PhonoIta, MorphoIta, ParamX, ResIta in {
|
||||
open CommonRomance, ParadigmsIta, PhonoIta, MorphoIta, ParamX, ResIta, Prelude in {
|
||||
|
||||
lin
|
||||
i8fem_Pron = mkPronoun
|
||||
@@ -39,6 +39,10 @@ concrete ExtraIta of ExtraItaAbs = ExtraRomanceIta **
|
||||
PossFamQuant p = {
|
||||
s = \\_,n,g,c => case n of {Sg => prepCase c ; _ => possCase g n c} ++ p.poss ! n ! g ;
|
||||
sp = \\ n,g,c => case n of {Sg => prepCase c ; _ => possCase g n c} ++ p.poss ! n ! g ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
|
||||
AdvDatVP = insertClit3 datClit ;
|
||||
AdvGenVP = insertClit3 genClit ;
|
||||
|
||||
}
|
||||
|
||||
@@ -28,4 +28,10 @@ abstract ExtraItaAbs = ExtraRomanceAbs ** {
|
||||
-- Possessive without definite article, like "mio figlio".
|
||||
|
||||
PossFamQuant : Pron -> Quant ;
|
||||
|
||||
-- clitic adverbs
|
||||
|
||||
AdvDatVP : VP -> VP ; -- ci vado
|
||||
AdvGenVP : VP -> VP ; -- ne arrivo
|
||||
|
||||
}
|
||||
|
||||
@@ -328,7 +328,7 @@ oper
|
||||
}
|
||||
} ;
|
||||
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False} ** {lock_NP = <>} ;
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False ; isNeg = False} ** {lock_NP = <>} ;
|
||||
|
||||
mk5A a b c d e =
|
||||
compADeg {s = \\_ => (mkAdj a b c d e).s ; isPre = False ; lock_A = <>} ;
|
||||
|
||||
@@ -31,10 +31,10 @@ lin
|
||||
during_Prep = mkPrep "durante" ;
|
||||
either7or_DConj = {s1,s2 = "o" ; n = Sg} ;
|
||||
everybody_NP = makeNP ["tutti"] Masc Pl ;
|
||||
every_Det = {s,sp = \\_,_ => "ogni" ; n = Sg ; s2 = []} ;
|
||||
every_Det = {s,sp = \\_,_ => "ogni" ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
everything_NP = pn2np (mkPN ["tutto"] Masc) ;
|
||||
everywhere_Adv = ss "dappertutto" ;
|
||||
few_Det = {s,sp = \\g,c => prepCase c ++ genForms "pochi" "poche" ! g ; n = Pl ; s2 = []} ;
|
||||
few_Det = {s,sp = \\g,c => prepCase c ++ genForms "pochi" "poche" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
---- first_Ord = {s = \\ag => (regA "primo").s ! Posit ! AF ag.g ag.n} ;
|
||||
for_Prep = mkPrep "per" ;
|
||||
from_Prep = da_Prep ;
|
||||
@@ -60,11 +60,11 @@ lin
|
||||
"lui" "lo" "gli" "glie" "lui" "suo" "sua" "suoi" "sue"
|
||||
Masc Sg P3 ;
|
||||
less_CAdv = X.mkCAdv "meno" conjThan ;
|
||||
many_Det = {s,sp = \\g,c => prepCase c ++ genForms "molti" "molte" ! g ; n = Pl ; s2 = []} ;
|
||||
many_Det = {s,sp = \\g,c => prepCase c ++ genForms "molti" "molte" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
more_CAdv = X.mkCAdv "più" conjThan ;
|
||||
most_Predet = {s = \\_,c => prepCase c ++ ["la maggior parte"] ; c = CPrep P_di ;
|
||||
a = PNoAg} ;
|
||||
much_Det = {s,sp = \\g,c => prepCase c ++ genForms "molto" "molta" ! g ; n = Sg ; s2 = []} ;
|
||||
much_Det = {s,sp = \\g,c => prepCase c ++ genForms "molto" "molta" ! g ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
must_VV = mkVV (verboV (dovere_47 "dovere")) ;
|
||||
no_Utt = ss "no" ;
|
||||
on_Prep = {s = [] ; c = CPrep P_su ; isDir = False} ;
|
||||
@@ -83,8 +83,8 @@ lin
|
||||
Fem Sg P3 ;
|
||||
so_AdA = ss "così" ;
|
||||
somebody_NP = pn2np (mkPN ["qualcuno"] Masc) ;
|
||||
somePl_Det = {s,sp = \\_,c => prepCase c ++ "qualche" ; n = Pl ; s2 = []} ;
|
||||
someSg_Det = {s,sp = \\_,c => prepCase c ++ "qualche" ; n = Sg ; s2 = []} ;
|
||||
somePl_Det = {s,sp = \\_,c => prepCase c ++ "qualche" ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
someSg_Det = {s,sp = \\_,c => prepCase c ++ "qualche" ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
something_NP = pn2np (mkPN ["qualche cosa"] Masc) ;
|
||||
somewhere_Adv = ss ["qualche parte"] ;
|
||||
that_Quant = let
|
||||
@@ -98,7 +98,8 @@ lin
|
||||
quello (elision "quel" "quell'" "quello")
|
||||
(elision "quei" "quegli" "quegli") ;
|
||||
sp = quello "quello" "quelli" ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
there7from_Adv = ss ["di là"] ;
|
||||
@@ -117,7 +118,8 @@ lin
|
||||
in {
|
||||
s = \\_ => questo ;
|
||||
sp = questo ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
through_Prep = mkPrep "per" ;
|
||||
@@ -167,12 +169,13 @@ lin
|
||||
in {
|
||||
s = \\_ => aucun ;
|
||||
sp = aucun ;
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = True
|
||||
} ;
|
||||
if_then_Conj = {s1 = "si" ; s2 = "allora" ; n = Sg ; lock_Conj = <>} ;
|
||||
nobody_NP = pn2np (mkPN ["nessuno"] Masc) ;
|
||||
nobody_NP = pn2npNeg (mkPN ["nessuno"] Masc) ;
|
||||
|
||||
nothing_NP = pn2np (mkPN "niente" Masc) ;
|
||||
nothing_NP = pn2npNeg (mkPN "niente" Masc) ;
|
||||
at_least_AdN = ss "almeno" ;
|
||||
at_most_AdN = ss "al massimo" ;
|
||||
|
||||
|
||||
@@ -65,12 +65,14 @@ incomplete concrete CatRomance of Cat = CommonX - [SC,Pol]
|
||||
s : Gender => Case => Str ;
|
||||
n : Number ;
|
||||
s2 : Str ; -- -ci
|
||||
sp : Gender => Case => Str -- substantival: mien, mienne
|
||||
sp : Gender => Case => Str ; -- substantival: mien, mienne
|
||||
isNeg : Bool -- negative element, e.g. aucun
|
||||
} ;
|
||||
Quant = {
|
||||
s : Bool => Number => Gender => Case => Str ;
|
||||
s2 : Str ;
|
||||
sp : Number => Gender => Case => Str
|
||||
sp : Number => Gender => Case => Str ;
|
||||
isNeg : Bool -- negative element, e.g. aucun
|
||||
} ;
|
||||
Predet = {
|
||||
s : AAgr => Case => Str ;
|
||||
|
||||
@@ -241,6 +241,7 @@ oper
|
||||
clit1 : Str ; -- le/se
|
||||
clit2 : Str ; -- lui
|
||||
clit3 : Str ; -- y en
|
||||
isNeg : Bool ; -- includes a negative element, such as "rien"
|
||||
comp : Agr => Str ; -- content(e) ; à ma mère ; hier
|
||||
ext : RPolarity => Str ; -- que je dors / que je dorme
|
||||
} ;
|
||||
|
||||
@@ -111,6 +111,7 @@ oper
|
||||
clit1 : Str ; -- le/se
|
||||
clit2 : Str ; -- lui
|
||||
clit3 : Str ; -- y en
|
||||
isNeg : Bool ; -- includes a negative element, such as "rien"
|
||||
comp : Agr => Str ; -- content(e) ; à ma mère ; hier
|
||||
ext : RPolarity => Str ; -- que je dors / que je dorme
|
||||
} ;
|
||||
|
||||
@@ -2,7 +2,8 @@ incomplete concrete ExtraRomance of ExtraRomanceAbs = CatRomance **
|
||||
open
|
||||
CommonRomance,
|
||||
Coordination,
|
||||
ResRomance in {
|
||||
ResRomance,
|
||||
Prelude in {
|
||||
|
||||
lin TPasseSimple = {s = []} ** {t = RPasse} ; --# notpresent
|
||||
|
||||
@@ -28,7 +29,8 @@ incomplete concrete ExtraRomance of ExtraRomanceAbs = CatRomance **
|
||||
a = p.a ;
|
||||
poss = p.poss ;
|
||||
hasClit = p.hasClit ;
|
||||
isPol = p.isPol
|
||||
isPol = p.isPol ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
CompIQuant iq = {s = \\aa => iq.s ! aa.n ! aa.g ! Nom} ;
|
||||
|
||||
@@ -5,4 +5,6 @@ abstract ExtraRomanceAbs = Cat, Extra[
|
||||
fun
|
||||
TPasseSimple : Tense ; --# notpresent
|
||||
ComplCN : V2 -> CN -> VP ; -- j'ai soif
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@ incomplete concrete NounRomance of Noun =
|
||||
let
|
||||
g = cn.g ;
|
||||
n = det.n
|
||||
in heavyNP {
|
||||
in heavyNPpol det.isNeg {
|
||||
s = \\c => det.s ! g ! c ++ cn.s ! n ++ det.s2 ;
|
||||
a = agrP3 g n ;
|
||||
hasClit = False
|
||||
@@ -16,11 +16,11 @@ incomplete concrete NounRomance of Noun =
|
||||
|
||||
UsePN = pn2np ;
|
||||
|
||||
UsePron p = p ;
|
||||
UsePron p = p ** {isNeg = False} ;
|
||||
|
||||
PredetNP pred np =
|
||||
let agr = complAgr np.a in
|
||||
heavyNP {
|
||||
heavyNPpol np.isNeg {
|
||||
s = \\c => pred.s ! agr ! c ++ (np.s ! pred.c).ton ;
|
||||
a = case pred.a of {PAg n => agrP3 agr.g n ; _ => np.a} ;
|
||||
hasClit = False
|
||||
@@ -28,19 +28,19 @@ incomplete concrete NounRomance of Noun =
|
||||
|
||||
PPartNP np v2 =
|
||||
let agr = complAgr np.a in
|
||||
heavyNP {
|
||||
heavyNPpol np.isNeg {
|
||||
s = \\c => (np.s ! c).ton ++ v2.s ! VPart agr.g agr.n ;
|
||||
a = np.a ;
|
||||
hasClit = False
|
||||
} ;
|
||||
|
||||
RelNP np rs = heavyNP {
|
||||
RelNP np rs = heavyNPpol np.isNeg {
|
||||
s = \\c => (np.s ! c).ton ++ rs.s ! Indic ! np.a ;
|
||||
a = np.a ;
|
||||
hasClit = False
|
||||
} ;
|
||||
|
||||
AdvNP np adv = heavyNP {
|
||||
AdvNP np adv = heavyNPpol np.isNeg {
|
||||
s = \\c => (np.s ! c).ton ++ adv.s ;
|
||||
a = np.a ;
|
||||
hasClit = False
|
||||
@@ -50,7 +50,8 @@ incomplete concrete NounRomance of Noun =
|
||||
s,sp = \\g,c => quant.s ! num.isNum ! num.n ! g ! c ++ num.s ! g ++
|
||||
ord.s ! aagr g num.n ;
|
||||
s2 = quant.s2 ;
|
||||
n = num.n
|
||||
n = num.n ;
|
||||
isNeg = quant.isNeg
|
||||
} ;
|
||||
|
||||
DetQuant quant num = {
|
||||
@@ -60,14 +61,15 @@ incomplete concrete NounRomance of Noun =
|
||||
False => quant.sp ! num.n ! g ! c ++ num.s ! g
|
||||
} ;
|
||||
s2 = quant.s2 ;
|
||||
n = num.n
|
||||
n = num.n ;
|
||||
isNeg = quant.isNeg
|
||||
} ;
|
||||
|
||||
DetNP det =
|
||||
let
|
||||
g = Masc ; ---- Fem in Extra
|
||||
n = det.n
|
||||
in heavyNP {
|
||||
in heavyNPpol det.isNeg {
|
||||
s = det.sp ! g ;
|
||||
a = agrP3 g n ;
|
||||
hasClit = False
|
||||
@@ -76,7 +78,8 @@ incomplete concrete NounRomance of Noun =
|
||||
PossPron p = {
|
||||
s = \\_,n,g,c => possCase g n c ++ p.poss ! n ! g ; ---- il mio!
|
||||
sp = \\ n,g,c => possCase g n c ++ p.poss ! n ! g ; ---- not for Fre
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
NumSg = {s = \\_ => [] ; isNum = False ; n = Sg} ;
|
||||
@@ -97,13 +100,15 @@ incomplete concrete NounRomance of Noun =
|
||||
DefArt = {
|
||||
s = \\_,n,g,c => artDef g n c ;
|
||||
sp = \\n,g,c => artDef g n c ; ---- not for Fre
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
IndefArt = {
|
||||
s = \\b,n,g,c => if_then_Str b (prepCase c) (artIndef g n c) ;
|
||||
sp = \\n,g,c => artIndef g n c ; ---- not for Fre
|
||||
s2 = []
|
||||
s2 = [] ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
MassNP cn = let
|
||||
@@ -112,7 +117,8 @@ incomplete concrete NounRomance of Noun =
|
||||
in heavyNP {
|
||||
s = \\c => partitive g c ++ cn.s ! n ;
|
||||
a = agrP3 g n ;
|
||||
hasClit = False
|
||||
hasClit = False ;
|
||||
isNeg = False
|
||||
} ;
|
||||
|
||||
-- This is based on record subtyping.
|
||||
|
||||
@@ -16,17 +16,25 @@ oper
|
||||
s : Case => {c1,c2,comp,ton : Str} ;
|
||||
a : Agr ;
|
||||
hasClit : Bool ;
|
||||
isPol : Bool --- only needed for French complement agr
|
||||
isPol : Bool ; --- only needed for French complement agr
|
||||
isNeg : Bool --- needed for negative NP's such as "personne"
|
||||
} ;
|
||||
Pronoun : Type = NounPhrase ** {
|
||||
Pronoun : Type = {
|
||||
s : Case => {c1,c2,comp,ton : Str} ;
|
||||
a : Agr ;
|
||||
hasClit : Bool ;
|
||||
isPol : Bool ; --- only needed for French complement agr
|
||||
poss : Number => Gender => Str ---- also: substantival
|
||||
} ;
|
||||
|
||||
heavyNP : {s : Case => Str ; a : Agr} -> NounPhrase = \np -> {
|
||||
heavyNP : {s : Case => Str ; a : Agr} -> NounPhrase = heavyNPpol False ;
|
||||
|
||||
heavyNPpol : Bool -> {s : Case => Str ; a : Agr} -> NounPhrase = \isNeg,np -> {
|
||||
s = \\c => {comp,ton = np.s ! c ; c1,c2 = []} ;
|
||||
a = np.a ;
|
||||
hasClit = False ;
|
||||
isPol = False
|
||||
isPol = False ;
|
||||
isNeg = isNeg
|
||||
} ;
|
||||
|
||||
Compl : Type = {s : Str ; c : Case ; isDir : Bool} ;
|
||||
@@ -35,7 +43,10 @@ oper
|
||||
complGen : Compl = {s = [] ; c = genitive ; isDir = False} ;
|
||||
complDat : Compl = {s = [] ; c = dative ; isDir = True} ;
|
||||
|
||||
pn2np : {s : Str ; g : Gender} -> NounPhrase = \pn -> heavyNP {
|
||||
pn2np : {s : Str ; g : Gender} -> NounPhrase = pn2npPol False ;
|
||||
pn2npNeg : {s : Str ; g : Gender} -> NounPhrase = pn2npPol True ;
|
||||
|
||||
pn2npPol : Bool -> {s : Str ; g : Gender} -> NounPhrase = \isNeg, pn -> heavyNPpol isNeg {
|
||||
s = \\c => prepCase c ++ pn.s ;
|
||||
a = agrP3 pn.g Sg
|
||||
} ;
|
||||
@@ -75,6 +86,7 @@ oper
|
||||
clit1 = [] ;
|
||||
clit2 = [] ;
|
||||
clit3 = [] ;
|
||||
isNeg = False ;
|
||||
comp = \\a => [] ;
|
||||
ext = \\p => []
|
||||
} ;
|
||||
@@ -91,6 +103,7 @@ oper
|
||||
clit1 = vp.clit1 ++ obj.c1 ;
|
||||
clit2 = vp.clit2 ++ obj.c2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = orB vp.isNeg np.isNeg ;
|
||||
comp = \\a => c.s ++ obj.comp ++ vp.comp ! a ;
|
||||
neg = vp.neg ;
|
||||
ext = vp.ext ;
|
||||
@@ -102,6 +115,7 @@ oper
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ; --- can be in compl as well
|
||||
neg = vp.neg ;
|
||||
comp = \\a => vp.comp ! a ++ co ! a ;
|
||||
ext = vp.ext ;
|
||||
@@ -116,7 +130,8 @@ oper
|
||||
agr = vpAgrClit (agrP3 ag.g ag.n) ;
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ;
|
||||
neg = vp.neg ;
|
||||
comp = vp.comp ;
|
||||
ext = vp.ext ;
|
||||
@@ -128,6 +143,7 @@ oper
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ;
|
||||
neg = vp.neg ;
|
||||
comp = vp.comp ;
|
||||
ext = vp.ext ;
|
||||
@@ -138,7 +154,8 @@ oper
|
||||
agr = vp.agr ;
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ; --- adv could be neg
|
||||
neg = vp.neg ;
|
||||
comp = \\a => vp.comp ! a ++ co ;
|
||||
ext = vp.ext ;
|
||||
@@ -149,7 +166,8 @@ oper
|
||||
agr = vp.agr ;
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ;
|
||||
neg = \\b => let vpn = vp.neg ! b in {p1 = vpn.p1 ; p2 = vpn.p2 ++ co} ;
|
||||
comp = vp.comp ;
|
||||
ext = vp.ext ;
|
||||
@@ -160,7 +178,8 @@ oper
|
||||
agr = vp.agr ;
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ++ co ;
|
||||
clit3 = vp.clit3 ++ co ;
|
||||
isNeg = vp.isNeg ;
|
||||
neg = vp.neg ;
|
||||
comp = vp.comp ;
|
||||
ext = vp.ext ;
|
||||
@@ -171,7 +190,8 @@ oper
|
||||
agr = vp.agr ;
|
||||
clit1 = vp.clit1 ;
|
||||
clit2 = vp.clit2 ;
|
||||
clit3 = vp.clit3 ;
|
||||
clit3 = vp.clit3 ;
|
||||
isNeg = vp.isNeg ;
|
||||
neg = vp.neg ;
|
||||
comp = vp.comp ;
|
||||
ext = \\p => vp.ext ! p ++ co ! p ;
|
||||
@@ -181,10 +201,21 @@ oper
|
||||
|
||||
mkClause : Str -> Bool -> Bool -> Agr -> VP ->
|
||||
{s : Direct => RTense => Anteriority => RPolarity => Mood => Str} =
|
||||
\subj, hasClit, isPol, agr, vp -> {
|
||||
mkClausePol False ;
|
||||
|
||||
-- isNeg = True if subject NP is a negative element, e.g. "personne"
|
||||
mkClausePol : Bool -> Str -> Bool -> Bool -> Agr -> VP ->
|
||||
{s : Direct => RTense => Anteriority => RPolarity => Mood => Str} =
|
||||
\isNeg, subj, hasClit, isPol, agr, vp -> {
|
||||
s = \\d,te,a,b,m =>
|
||||
let
|
||||
neg = vp.neg ! b ;
|
||||
isAnyNeg = orB isNeg vp.isNeg ;
|
||||
pol = case <isAnyNeg,b> of {
|
||||
<True,RPos> => RNeg True ;
|
||||
_ => b
|
||||
} ;
|
||||
|
||||
neg = vp.neg ! pol ;
|
||||
|
||||
gen = agr.g ;
|
||||
num = agr.n ;
|
||||
@@ -193,7 +224,7 @@ oper
|
||||
compl = case isPol of {
|
||||
True => vp.comp ! {g = gen ; n = Sg ; p = per} ;
|
||||
_ => vp.comp ! agr
|
||||
} ++ vp.ext ! b ;
|
||||
} ++ vp.ext ! pol ;
|
||||
|
||||
vtyp = vp.s.vtyp ;
|
||||
refl = case vtyp of {
|
||||
|
||||
@@ -4,7 +4,7 @@ incomplete concrete SentenceRomance of Sentence =
|
||||
flags optimize=all_subs ;
|
||||
|
||||
lin
|
||||
PredVP np vp = mkClause (np.s ! Nom).comp np.hasClit np.isPol np.a vp ;
|
||||
PredVP np vp = mkClausePol np.isNeg (np.s ! Nom).comp np.hasClit np.isPol np.a vp ;
|
||||
|
||||
PredSCVP sc vp = mkClause (sc.s ! Nom) False False (agrP3 Masc Sg) vp ;
|
||||
|
||||
@@ -23,7 +23,7 @@ incomplete concrete SentenceRomance of Sentence =
|
||||
---- <Acc,True> => insertAgr ag v2 ;
|
||||
---- _ => v2
|
||||
----e }
|
||||
in (mkClause (np.s ! Nom).comp np.hasClit np.isPol np.a vp).s ;
|
||||
in (mkClausePol np.isNeg (np.s ! Nom).comp np.hasClit np.isPol np.a vp).s ;
|
||||
c2 = v2.c2
|
||||
} ;
|
||||
|
||||
@@ -39,7 +39,7 @@ incomplete concrete SentenceRomance of Sentence =
|
||||
|
||||
SlashVS np vs slash =
|
||||
{s = \\ag =>
|
||||
(mkClause
|
||||
(mkClausePol np.isNeg
|
||||
(np.s ! Nom).comp np.hasClit np.isPol np.a
|
||||
(insertExtrapos (\\b => conjThat ++ slash.s ! ag ! (vs.m ! b))
|
||||
(predV vs))
|
||||
|
||||
@@ -328,7 +328,7 @@ oper
|
||||
}
|
||||
} ;
|
||||
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False} ** {lock_NP = <>} ;
|
||||
makeNP x g n = {s = (pn2np (mk2PN x g)).s; a = agrP3 g n ; hasClit = False ; isPol = False ; isNeg = False} ** {lock_NP = <>} ;
|
||||
|
||||
mk5A a b c d e =
|
||||
compADeg {s = \\_ => (mkAdj a b c d e).s ; isPre = False ; lock_A = <>} ;
|
||||
@@ -376,14 +376,14 @@ oper
|
||||
in lin Quant {
|
||||
s = \\_ => attrforms ;
|
||||
s2 = [] ;
|
||||
sp = npforms
|
||||
sp = npforms ; isNeg = False
|
||||
} ;
|
||||
|
||||
mkDet mucho mucha number =
|
||||
lin Det {
|
||||
s,sp = \\g,c => prepCase c ++ genForms mucho mucha ! g ;
|
||||
n = number;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
|
||||
regV x = -- cortar actuar cazar guiar pagar sacar
|
||||
|
||||
@@ -26,11 +26,11 @@ lin
|
||||
in {
|
||||
s = \\_ => cap ;
|
||||
sp = cap ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = True
|
||||
} ;
|
||||
not_Predet = {s = \\a,c => prepCase c ++ "no" ; c = Nom ; a = PNoAg} ;
|
||||
nobody_NP = pn2np (mkPN "nadie") ;
|
||||
nothing_NP = pn2np (mkPN "nada") ;
|
||||
nobody_NP = pn2npNeg (mkPN "nadie") ;
|
||||
nothing_NP = pn2npNeg (mkPN "nada") ;
|
||||
--
|
||||
|
||||
above_Prep = mkPrep "sobre" ;
|
||||
@@ -57,11 +57,11 @@ lin
|
||||
during_Prep = mkPrep "durante" ; ----
|
||||
either7or_DConj = {s1,s2 = "o" ; n = Sg} ;
|
||||
everybody_NP = makeNP ["todos"] Masc Pl ;
|
||||
every_Det = {s,sp = \\_,_ => "cada" ; n = Sg ; s2 = []} ;
|
||||
every_Det = {s,sp = \\_,_ => "cada" ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
everything_NP = pn2np (mkPN ["todo"] Masc) ;
|
||||
everywhere_Adv = ss ["en todas partes"] ;
|
||||
few_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "pocos" "pocas" ! g ; n = Pl ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "pocos" "pocas" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
--- first_Ord = {s = \\ag => (regA "primero").s ! Posit ! AF ag.g ag.n} ;
|
||||
for_Prep = mkPrep "para" ;
|
||||
from_Prep = complGen ; ---
|
||||
@@ -91,12 +91,12 @@ lin
|
||||
Masc Sg P3 ;
|
||||
less_CAdv = X.mkCAdv "menos" conjThan ; ----
|
||||
many_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "muchos" "muchas" ! g ; n = Pl ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "muchos" "muchas" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
more_CAdv = X.mkCAdv "más" conjThan ;
|
||||
most_Predet = {s = \\_,c => prepCase c ++ ["la mayor parte"] ; c = CPrep P_de ;
|
||||
a = PNoAg} ;
|
||||
much_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "mucho" "mucha" ! g ; n = Sg ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "mucho" "mucha" ! g ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
must_VV = mkVV (verboV (deber_6 "deber")) ;
|
||||
no_Utt = ss "no" ;
|
||||
on_Prep = mkPrep "sobre" ;
|
||||
@@ -117,9 +117,9 @@ lin
|
||||
so_AdA = ss "tanto" ;
|
||||
somebody_NP = pn2np (mkPN ["algún"] Masc) ;
|
||||
somePl_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algunos" "algunas" ! g ; n = Pl ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algunos" "algunas" ! g ; n = Pl ; s2 = [] ; isNeg = False} ;
|
||||
someSg_Det = {
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algun" "alguna" ! g ; n = Sg ; s2 = []} ;
|
||||
s,sp = \\g,c => prepCase c ++ genForms "algun" "alguna" ! g ; n = Sg ; s2 = [] ; isNeg = False} ;
|
||||
something_NP = pn2np (mkPN ["algo"] Masc) ;
|
||||
somewhere_Adv = ss ["en ninguna parte"] ;
|
||||
that_Quant =
|
||||
@@ -130,7 +130,7 @@ lin
|
||||
in {
|
||||
s = \\_ => ese ;
|
||||
sp = ese ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
there_Adv = mkAdv "allí" ; -- allá
|
||||
there7to_Adv = mkAdv ["para allá"] ;
|
||||
@@ -148,7 +148,7 @@ lin
|
||||
in {
|
||||
s = \\_ => este ;
|
||||
sp = este ;
|
||||
s2 = []
|
||||
s2 = [] ; isNeg = False
|
||||
} ;
|
||||
|
||||
through_Prep = mkPrep "por" ;
|
||||
|
||||
Reference in New Issue
Block a user