mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 17:08:54 -06:00
monosyllable prefix
This commit is contained in:
@@ -6,7 +6,7 @@ concrete AdjectiveMay of Adjective = CatMay ** open ResMay, Prelude in {
|
|||||||
|
|
||||||
-- : A -> AP ;
|
-- : A -> AP ;
|
||||||
PositA a = a ** {
|
PositA a = a ** {
|
||||||
compar = [] ;
|
compar = a.s ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- : A -> NP -> AP ;
|
-- : A -> NP -> AP ;
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ lin beautiful_A = mkA "cantik" ;
|
|||||||
-- lin bike_N = mkN "" ;
|
-- lin bike_N = mkN "" ;
|
||||||
-- lin bird_N = mkN "" ;
|
-- lin bird_N = mkN "" ;
|
||||||
-- lin bite_V2 = mkV2 "" ;
|
-- lin bite_V2 = mkV2 "" ;
|
||||||
-- lin black_A = mkA "" ;
|
lin black_A = mkA "hitam" ;
|
||||||
-- lin blood_N = mkN "" ;
|
-- lin blood_N = mkN "" ;
|
||||||
-- lin blow_V = mkV "" ;
|
-- lin blow_V = mkV "" ;
|
||||||
-- lin blue_A = mkA "" ;
|
-- lin blue_A = mkA "" ;
|
||||||
@@ -230,7 +230,7 @@ lin man_N = mkN "lelaki" ;
|
|||||||
-- lin meat_N = mkN "" ;
|
-- lin meat_N = mkN "" ;
|
||||||
lin milk_N = mkN "susu" ;
|
lin milk_N = mkN "susu" ;
|
||||||
-- lin moon_N = mkN "" ;
|
-- lin moon_N = mkN "" ;
|
||||||
-- lin mother_N2 = mkN2 "" ;
|
lin mother_N2 = mkN2 "ibu" ;
|
||||||
-- lin mountain_N = mkN "" ;
|
-- lin mountain_N = mkN "" ;
|
||||||
-- lin mouth_N = mkN "" ;
|
-- lin mouth_N = mkN "" ;
|
||||||
-- lin music_N = mkN "" ;
|
-- lin music_N = mkN "" ;
|
||||||
@@ -256,7 +256,7 @@ lin now_Adv = mkAdv "sekarang" ;
|
|||||||
-- lin oil_N = mkN "" ;
|
-- lin oil_N = mkN "" ;
|
||||||
lin old_A = mkA "tua" ;
|
lin old_A = mkA "tua" ;
|
||||||
-- lin open_V2 = mkV2 "" ;
|
-- lin open_V2 = mkV2 "" ;
|
||||||
-- lin paint_V2A = mkV2A "" ;
|
lin paint_V2A = mkV2 "cat" ;
|
||||||
-- lin paper_N = mkN "" ;
|
-- lin paper_N = mkN "" ;
|
||||||
-- lin paris_PN = mkPN "Paris" ;
|
-- lin paris_PN = mkPN "Paris" ;
|
||||||
-- lin peace_N = mkN "" ;
|
-- lin peace_N = mkN "" ;
|
||||||
|
|||||||
@@ -31,6 +31,8 @@ oper
|
|||||||
} ;
|
} ;
|
||||||
|
|
||||||
prefixMeng : Str -> Str = \makan -> case makan of {
|
prefixMeng : Str -> Str = \makan -> case makan of {
|
||||||
|
? + ? + c => "menge" + makan ;
|
||||||
|
|
||||||
(#v|"g"|"h") + _
|
(#v|"g"|"h") + _
|
||||||
=> "meng" + makan ; -- prefix meng: e.g. meng+atur
|
=> "meng" + makan ; -- prefix meng: e.g. meng+atur
|
||||||
"k" + enal
|
"k" + enal
|
||||||
@@ -49,6 +51,8 @@ oper
|
|||||||
"s" + alak
|
"s" + alak
|
||||||
=> "meny" + alak ; -- replace s with meny
|
=> "meny" + alak ; -- replace s with meny
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
("r"|"l"|"w"|"y"|"m"|"n"|"ny"|"ng") + _
|
("r"|"l"|"w"|"y"|"m"|"n"|"ny"|"ng") + _
|
||||||
=> "me" + makan ; -- prefix me
|
=> "me" + makan ; -- prefix me
|
||||||
|
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ lin
|
|||||||
True => iadv.s ++ cls.subj ; False => cls.subj
|
True => iadv.s ++ cls.subj ; False => cls.subj
|
||||||
} ;
|
} ;
|
||||||
pred = \\vf,pol => case iadv.isPre of {
|
pred = \\vf,pol => case iadv.isPre of {
|
||||||
True => cls.pred ! Root ! pol ;
|
True => cls.pred ! iadv.vf ! pol ;
|
||||||
False => cls.pred ! Root ! pol ++ iadv.s
|
False => cls.pred ! iadv.vf ! pol ++ iadv.s
|
||||||
} ;
|
} ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|||||||
@@ -67,6 +67,7 @@ oper
|
|||||||
sp = \\_ => str ;
|
sp = \\_ => str ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
-- Det, Quant, Card, Ord
|
-- Det, Quant, Card, Ord
|
||||||
|
|
||||||
@@ -235,6 +236,7 @@ oper
|
|||||||
|
|
||||||
IAdv : Type = Adverb ** {
|
IAdv : Type = Adverb ** {
|
||||||
isPre : Bool ;
|
isPre : Bool ;
|
||||||
|
vf : VForm ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
------------------
|
------------------
|
||||||
@@ -256,6 +258,7 @@ oper
|
|||||||
s = \\vf,pol => nounneg pol ++ s ;
|
s = \\vf,pol => nounneg pol ++ s ;
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
verbneg : Polarity -> Str = \pol -> case pol of {
|
verbneg : Polarity -> Str = \pol -> case pol of {
|
||||||
Neg => "tidak" ; -- or "tak"?
|
Neg => "tidak" ; -- or "tak"?
|
||||||
Pos => []
|
Pos => []
|
||||||
|
|||||||
@@ -15,13 +15,13 @@ lin very_AdA = mkAdA "" ;
|
|||||||
lin as_CAdv = { s = "" ; p = [] } ;
|
lin as_CAdv = { s = "" ; p = [] } ;
|
||||||
lin less_CAdv = { s = "" ; p = [] } ;
|
lin less_CAdv = { s = "" ; p = [] } ;
|
||||||
lin more_CAdv = { s = "" ; p = [] } ;
|
lin more_CAdv = { s = "" ; p = [] } ;
|
||||||
lin how_IAdv = ss "" :
|
|
||||||
|
|
||||||
lin how8much_IAdv = ss "" ;
|
lin how8much_IAdv = ss "" ;
|
||||||
lin when_IAdv = ss "" ;
|
lin when_IAdv = ss "" ;
|
||||||
-}
|
-}
|
||||||
lin where_IAdv = { s = "mana"; isPre = False } ;
|
lin how_IAdv = { s = "bagaimana"; isPre = True ; vf = Active } ;
|
||||||
lin why_IAdv = {s = "mengapa"; isPre = True } ;
|
lin where_IAdv = { s = "mana"; isPre = False ; vf = Root } ;
|
||||||
|
lin why_IAdv = {s = "mengapa"; isPre = True ; vf = Root } ;
|
||||||
{-
|
{-
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -55,6 +55,15 @@ lin
|
|||||||
c2 = v3.c2 -- Now the VPSlash is missing only the direct object
|
c2 = v3.c2 -- Now the VPSlash is missing only the direct object
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
-- insertObjc : (Agr => Str) -> SlashVP -> SlashVP = \obj,vp ->
|
||||||
|
-- insertObj obj vp ** {c2 = vp.c2 ; gapInMiddle = vp.gapInMiddle ; missingAdv = vp.missingAdv } ;
|
||||||
|
|
||||||
|
SlashV2A v2 adj = useV {
|
||||||
|
s = \\vf => v2.s ! vf ++ adj.s;
|
||||||
|
} ** {
|
||||||
|
c2 = v2.c2
|
||||||
|
} ;
|
||||||
|
|
||||||
{-
|
{-
|
||||||
-- : V2S -> S -> VPSlash ; -- answer (to him) that it is good
|
-- : V2S -> S -> VPSlash ; -- answer (to him) that it is good
|
||||||
SlashV2S v2s s =
|
SlashV2S v2s s =
|
||||||
@@ -70,7 +79,10 @@ lin
|
|||||||
-}
|
-}
|
||||||
-- : VPSlash -> NP -> VP
|
-- : VPSlash -> NP -> VP
|
||||||
ComplSlash vps np = vps ** {
|
ComplSlash vps np = vps ** {
|
||||||
s = \\vf,pol => vps.s ! vf ! pol ++ applyPrep vps.c2 np
|
s = \\vf,pol =>
|
||||||
|
vps.s ! vf ! pol
|
||||||
|
++ applyPrep vps.c2 np
|
||||||
|
-- s = \\vf,pol => vps.s ! vf ! pol ++ applyPrep vps.c2 np
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- : VV -> VPSlash -> VPSlash ;
|
-- : VV -> VPSlash -> VPSlash ;
|
||||||
|
|||||||
@@ -54,3 +54,7 @@ LangMay: siapa mahu pergi
|
|||||||
Lang: UseQCl (TTAnt TPres ASimul) PPos (QuestIComp (CompIP whoSg_IP) (DetCN (DetQuant DefArt NumSg) (UseN cat_N)))
|
Lang: UseQCl (TTAnt TPres ASimul) PPos (QuestIComp (CompIP whoSg_IP) (DetCN (DetQuant DefArt NumSg) (UseN cat_N)))
|
||||||
LangEng: who is the cat
|
LangEng: who is the cat
|
||||||
LangMay: siapa kucing
|
LangMay: siapa kucing
|
||||||
|
|
||||||
|
Lang: UseQCl (TTAnt TPres ASimul) PPos (QuestIAdv how_IAdv (PredVP (DetCN (DetQuant (PossPron youSg_Pron) NumSg) (UseN2 mother_N2)) (ComplSlash (SlashV2A paint_V2A (PositA black_A)) (DetCN (DetQuant DefArt NumSg) (UseN house_N)))))
|
||||||
|
LangEng: how does your mother paint the house black
|
||||||
|
LangMay: bagaimana ibu awak mengecat rumah hitam
|
||||||
Reference in New Issue
Block a user