mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 17:08:54 -06:00
Some fixes and backwards compatibility
This commit is contained in:
@@ -22,7 +22,7 @@ lin
|
|||||||
|
|
||||||
-- : A -> NP -> AP ; -- warmer than I - теплее меня
|
-- : A -> NP -> AP ; -- warmer than I - теплее меня
|
||||||
ComparA a np = {
|
ComparA a np = {
|
||||||
s = \\gn,anim,cas => a.comp ++ (applyPrep {s="" ; c=Gen ; hasPrep=True} np) ;
|
s = \\gn,anim,cas => a.comp ++ (applyPrep {s="" ; c=Gen ; hasPrep=False} np) ; -- True?
|
||||||
short = \\ag=>a.comp ++ (applyPrep {s="" ; c=Gen ; hasPrep=True} np) ;
|
short = \\ag=>a.comp ++ (applyPrep {s="" ; c=Gen ; hasPrep=True} np) ;
|
||||||
isPost = False ;
|
isPost = False ;
|
||||||
preferShort = PrefShort
|
preferShort = PrefShort
|
||||||
|
|||||||
@@ -6,11 +6,11 @@ concrete ExtraRus of ExtraRusAbs = CatRus **
|
|||||||
|
|
||||||
lin
|
lin
|
||||||
obj_no_Prep = {s="" ; c=Acc ; hasPrep=False} ;
|
obj_no_Prep = {s="" ; c=Acc ; hasPrep=False} ;
|
||||||
to2_Prep = {s="в" ; c=Acc ; hasPrep=True};
|
to2_Prep = P.mkPrep "в" Acc ;
|
||||||
on_to_Prep = {s="до"; c=Gen; hasPrep=True} ;
|
on_to_Prep = P.mkPrep "до" Gen ;
|
||||||
along_Prep = {s="по"; c=Loc; hasPrep=True} ;
|
along_Prep = P.mkPrep "по" Loc ;
|
||||||
from2_Prep = from2 ;
|
from2_Prep = from2 ;
|
||||||
about_Prep = {s="о" ; c=Pre; hasPrep=True} ;
|
about_Prep = P.mkPrep "о" Pre ;
|
||||||
|
|
||||||
have_V3 = P.mkV3 est_ell_V nom_Prep u_Prep;
|
have_V3 = P.mkV3 est_ell_V nom_Prep u_Prep;
|
||||||
have2_V3 = P.mkV3 est_V nom_Prep u_Prep;
|
have2_V3 = P.mkV3 est_V nom_Prep u_Prep;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ lin
|
|||||||
doctor_N = mkN "доктор" masculine animate ;
|
doctor_N = mkN "доктор" masculine animate ;
|
||||||
dog_N = mkN "собака" feminine animate ;
|
dog_N = mkN "собака" feminine animate ;
|
||||||
door_N = mkN "дверь" ;
|
door_N = mkN "дверь" ;
|
||||||
drink_V2 = mkV2 (mkV imperfective "пить" "пиью" "пьёт");
|
drink_V2 = mkV2 (mkV imperfective "пить" "пью" "пьёт");
|
||||||
dry_A = mkA "сухой" "" "3b/c'";
|
dry_A = mkA "сухой" "" "3b/c'";
|
||||||
dull_A = mkA "скучный" ;
|
dull_A = mkA "скучный" ;
|
||||||
dust_N = mkN "пыль" ;
|
dust_N = mkN "пыль" ;
|
||||||
|
|||||||
@@ -69,14 +69,16 @@ oper
|
|||||||
-- Nouns
|
-- Nouns
|
||||||
|
|
||||||
mkN = overload {
|
mkN = overload {
|
||||||
mkN : (nom : Str) -> N
|
mkN : Str -> N
|
||||||
= \nom -> lin N (guessNounForms nom) ;
|
= \nom -> lin N (guessNounForms nom) ;
|
||||||
|
mkN : Str -> Animacy -> N
|
||||||
|
= \nom,anim -> lin N ((guessNounForms nom) ** {anim=anim}) ;
|
||||||
mkN : Str -> Gender -> Animacy -> N
|
mkN : Str -> Gender -> Animacy -> N
|
||||||
= \nom, g, a -> lin N (guessLessNounForms nom g a) ;
|
= \nom, g, anim -> lin N (guessLessNounForms nom g anim) ;
|
||||||
mkN : Str -> Gender -> Animacy -> Z.ZNIndex -> N
|
mkN : Str -> Gender -> Animacy -> Z.ZNIndex -> N
|
||||||
= \word, g, a, z -> lin N (noMinorCases (Z.makeNoun word g a z)) ;
|
= \word, g, anim, z -> lin N (noMinorCases (Z.makeNoun word g anim z)) ;
|
||||||
mkN : Str -> Gender -> Animacy -> Str -> N
|
mkN : Str -> Gender -> Animacy -> Str -> N
|
||||||
= \word, g, a, zi -> lin N (noMinorCases (Z.makeNoun word g a (Z.parseIndex zi))) ;
|
= \word, g, anim, zi -> lin N (noMinorCases (Z.makeNoun word g anim (Z.parseIndex zi))) ;
|
||||||
mkN : A -> Gender -> Animacy -> N
|
mkN : A -> Gender -> Animacy -> N
|
||||||
= \a, g, anim -> lin N (makeNFFromAF a g anim) ;
|
= \a, g, anim -> lin N (makeNFFromAF a g anim) ;
|
||||||
} ;
|
} ;
|
||||||
@@ -87,7 +89,7 @@ oper
|
|||||||
mkN2 : N -> Prep -> N2
|
mkN2 : N -> Prep -> N2
|
||||||
= \n, p -> lin N2 (mkFun n p) ;
|
= \n, p -> lin N2 (mkFun n p) ;
|
||||||
mkN2 : Str -> Gender -> Animacy -> Str -> Prep -> N2
|
mkN2 : Str -> Gender -> Animacy -> Str -> Prep -> N2
|
||||||
= \word, g, a, zi, p -> lin N2 (mkFun (noMinorCases (Z.makeNoun word g a (Z.parseIndex zi))) p) ;
|
= \word, g, anim, zi, p -> lin N2 (mkFun (noMinorCases (Z.makeNoun word g anim (Z.parseIndex zi))) p) ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
nullPrep : Prep = lin Prep {s=[]; c=Gen; hasPrep=False} ;
|
nullPrep : Prep = lin Prep {s=[]; c=Gen; hasPrep=False} ;
|
||||||
@@ -96,20 +98,22 @@ oper
|
|||||||
mkN3 : N -> Prep -> Prep -> N3
|
mkN3 : N -> Prep -> Prep -> N3
|
||||||
= \n, p2, p3 -> lin N3 (mkFun2 n p2 p3) ;
|
= \n, p2, p3 -> lin N3 (mkFun2 n p2 p3) ;
|
||||||
mkN3 : Str -> Gender -> Animacy -> Str -> Prep -> Prep -> N3
|
mkN3 : Str -> Gender -> Animacy -> Str -> Prep -> Prep -> N3
|
||||||
= \word, g, a, zi, p2, p3 -> lin N3 (mkFun2 (noMinorCases (Z.makeNoun word g a (Z.parseIndex zi))) p2 p3) ;
|
= \word, g, anim, zi, p2, p3 -> lin N3 (mkFun2 (noMinorCases (Z.makeNoun word g anim (Z.parseIndex zi))) p2 p3) ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
mkPN = overload {
|
mkPN = overload {
|
||||||
mkPN : N -> PN
|
mkPN : N -> PN
|
||||||
= \n -> lin PN n ;
|
= \n -> lin PN n ;
|
||||||
mkPN : (nom : Str) -> PN
|
mkPN : Str -> PN
|
||||||
= \nom -> lin PN (guessNounForms nom) ;
|
= \nom -> lin PN (guessNounForms nom) ;
|
||||||
mkPN : Str -> Gender -> Animacy -> PN
|
mkPN : Str -> Gender -> Animacy -> PN
|
||||||
= \nom, g, a -> lin PN (guessLessNounForms nom g a) ;
|
= \nom, g, anim -> lin PN (guessLessNounForms nom g anim) ;
|
||||||
|
mkPN : Str -> Gender -> Number -> Animacy -> PN
|
||||||
|
= \nom, g, n, anim -> lin PN (guessLessNounForms nom g anim) ;
|
||||||
mkPN : Str -> Gender -> Animacy -> Z.ZNIndex -> PN
|
mkPN : Str -> Gender -> Animacy -> Z.ZNIndex -> PN
|
||||||
= \word, g, a, z -> lin PN (noMinorCases (Z.makeNoun word g a z)) ;
|
= \word, g, anim, z -> lin PN (noMinorCases (Z.makeNoun word g anim z)) ;
|
||||||
mkPN : Str -> Gender -> Animacy -> Str -> PN
|
mkPN : Str -> Gender -> Animacy -> Str -> PN
|
||||||
= \word, g, a, zi -> lin PN (noMinorCases (Z.makeNoun word g a (Z.parseIndex zi))) ;
|
= \word, g, anim, zi -> lin PN (noMinorCases (Z.makeNoun word g anim (Z.parseIndex zi))) ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
---------------------
|
---------------------
|
||||||
@@ -197,4 +201,6 @@ oper
|
|||||||
mkInterj : Str -> Interj
|
mkInterj : Str -> Interj
|
||||||
= \s -> lin Interj {s = s} ;
|
= \s -> lin Interj {s = s} ;
|
||||||
|
|
||||||
|
mkPrep : Str -> Case -> Prep
|
||||||
|
= \s,c -> lin Prep {s = s ; c = c ; hasPrep = True} ;
|
||||||
}
|
}
|
||||||
@@ -38,26 +38,26 @@ lin
|
|||||||
c=Nom
|
c=Nom
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
above_Prep = {s="над" ; c=Ins; hasPrep=True} ;
|
above_Prep = mkPrep "над" Ins ;
|
||||||
after_Prep = {s="после" ; c=Gen; hasPrep=True };
|
after_Prep = mkPrep "после" Gen ;
|
||||||
before_Prep = {s="перед" ; c=Ins; hasPrep=True};
|
before_Prep = mkPrep "перед" Ins ;
|
||||||
behind_Prep = {s="за" ; c=Ins; hasPrep=True };
|
behind_Prep = mkPrep "за" Ins ;
|
||||||
between_Prep = {s="между" ; c=Ins; hasPrep=True};
|
between_Prep = mkPrep "между" Ins ;
|
||||||
by8agent_Prep = {s=["с помощью"] ; c=Gen; hasPrep=True};
|
by8agent_Prep = mkPrep ["с помощью"] Gen ;
|
||||||
by8means_Prep = {s=["с помощью"] ; c=Gen; hasPrep=True};
|
by8means_Prep = mkPrep ["с помощью"] Gen ;
|
||||||
during_Prep = {s=["в течение"] ; c=Gen; hasPrep=True};
|
during_Prep = mkPrep "в течение" Gen ;
|
||||||
except_Prep = {s=["за исключением"] ; c=Gen; hasPrep=True};
|
except_Prep = mkPrep ["за исключением"] Gen ;
|
||||||
for_Prep = {s="для" ; c=Gen ; hasPrep=True};
|
for_Prep = mkPrep "для" Gen ;
|
||||||
from_Prep = {s="от" ; c=Gen ; hasPrep=True} ;
|
from_Prep = mkPrep "от" Gen ;
|
||||||
in8front_Prep = {s="перед" ; c=Ins; hasPrep=True};
|
in8front_Prep = mkPrep "перед" Ins ;
|
||||||
in_Prep = {s="в" ; c=Loc ; hasPrep=True} ;
|
in_Prep = mkPrep "в" Loc ;
|
||||||
on_Prep = {s="на" ; c=Loc ; hasPrep=True};
|
on_Prep = mkPrep "на" Loc ;
|
||||||
part_Prep = {s="" ; c=Nom ; hasPrep=False }; -- missing in Russian???
|
part_Prep = {s="" ; c=Nom ; hasPrep=False }; -- missing in Russian???
|
||||||
possess_Prep = {s="" ; c=Gen ; hasPrep=False};
|
possess_Prep = {s="" ; c=Gen ; hasPrep=False};
|
||||||
through_Prep = {s="через" ; c=Acc ; hasPrep=True};
|
through_Prep = mkPrep "через" Acc ;
|
||||||
to_Prep = {s="к" ; c=Dat ; hasPrep=True} ;
|
to_Prep = mkPrep "к" Dat ;
|
||||||
under_Prep = {s="под" ; c=Ins ; hasPrep=True};
|
under_Prep = mkPrep "под" Ins ;
|
||||||
without_Prep = {s="без" ; c=Gen; hasPrep=True };
|
without_Prep = mkPrep "без" Gen ;
|
||||||
|
|
||||||
or_Conj = mkConj "или" Sg ;
|
or_Conj = mkConj "или" Sg ;
|
||||||
and_Conj = mkConj "и" Pl ;
|
and_Conj = mkConj "и" Pl ;
|
||||||
@@ -65,7 +65,7 @@ lin
|
|||||||
either7or_DConj = mkConj "либо" (comma ++ "либо") Sg ;
|
either7or_DConj = mkConj "либо" (comma ++ "либо") Sg ;
|
||||||
if_then_Conj = mkConj "если" (comma ++ "то") Sg ;
|
if_then_Conj = mkConj "если" (comma ++ "то") Sg ;
|
||||||
|
|
||||||
with_Prep = {s="с" ; c=Ins; hasPrep=True};
|
with_Prep = mkPrep "с" Ins ;
|
||||||
|
|
||||||
please_Voc = ss "пожалуйста" ;
|
please_Voc = ss "пожалуйста" ;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user