forked from GitHub/gf-rgl
add more time expressions to ConstructionJpn, and fill SymbolJpn (might be wrong though) functions.
This commit is contained in:
+37
-38
@@ -1,39 +1,40 @@
|
||||
--# -path=.:../abstract:../prelude
|
||||
|
||||
concrete SymbolJpn of Symbol = CatJpn ** open Prelude, ResJpn in {
|
||||
concrete SymbolJpn of Symbol = CatJpn ** open Prelude, ResJpn, NounJpn in {
|
||||
|
||||
flags coding = utf8;
|
||||
{-
|
||||
lin
|
||||
SymbPN i = {s = addGenitiveS i.s ; g = Masc ; t = NonLiving ; h = Pers3_L } ;
|
||||
|
||||
IntPN i = {s = addGenitiveS i.s ; g = Masc ; t = NonLiving ; h = Pers3_L } ;
|
||||
|
||||
FloatPN i = {s = addGenitiveS i.s ; g = Masc ; t = NonLiving ; h = Pers3_L } ;
|
||||
|
||||
NumPN i = {s = \\_ =>i.s ; g = Masc ; t = NonLiving ; h = Pers3_L } ;
|
||||
|
||||
CNIntNP cn i = {
|
||||
s = \\c => cn.s ! Sg ! Nom ++ i.s ;
|
||||
a = agrP3 cn.g Sg ;
|
||||
t = NonLiving
|
||||
} ;
|
||||
|
||||
CNSymbNP det cn xs = {
|
||||
s = \\c => det.s!Sg!Masc ++ cn.s ! det.n ! Nom ++ xs.s ;
|
||||
a = agrP3 cn.g det.n ;
|
||||
t = NonLiving
|
||||
} ;
|
||||
|
||||
CNNumNP cn i = {
|
||||
s = \\c => cn.s ! Sg ! Nom ++ i.s ;
|
||||
a = agrP3 cn.g Sg ;
|
||||
t = NonLiving
|
||||
} ;
|
||||
|
||||
SymbS sy = sy ;
|
||||
SymbNum sy = { s = sy.s ; n = Pl } ;
|
||||
SymbOrd sy = { s = sy.s ++ "ौँ" ; n = Pl} ;
|
||||
lin
|
||||
--PN = {s : Style => Str ; anim : Animateness} ;
|
||||
SymbPN i = {s = \\style => i.s ; anim = Inanim } ;
|
||||
|
||||
IntPN i = {s = \\style => i.s ; anim = Inanim } ;
|
||||
|
||||
FloatPN i = {s = \\style => i.s ; anim = Inanim } ;
|
||||
|
||||
NumPN i = {s = \\style => i.s ; anim = Inanim } ;
|
||||
|
||||
|
||||
-- : Det -> CN -> [Symb] -> NP ; -- (the) (2) numbers x and y
|
||||
CNSymbNP det cn xs =
|
||||
let np = DetCN det cn ;
|
||||
in np ** { s = \\st => xs.s ++ "の" ++ np.s ! st } ;
|
||||
|
||||
-- : CN -> Card -> NP ; -- level five ; level 5
|
||||
-- This is pure guessing /IL 2017-07
|
||||
CNNumNP cn i =
|
||||
let np = MassNP cn ;
|
||||
in np ** { s = \\st => i.s ++ "の" ++ np.s ! st } ;
|
||||
|
||||
-- S = {s, te, ba, subj : Particle => Style => Str ; pred, pred_te, pred_ba : Style => Str} ;
|
||||
SymbS sy = { s = \\p,st => sy.s ;
|
||||
te = \\_,_ => [] ; ba = \\_,_ => [] ; subj = \\_,_ => [] ;
|
||||
pred = \\st => [] ; pred_te = \\st => [] ; pred_ba = \\st => [] } ;
|
||||
|
||||
SymbNum sy = mkNum sy.s Pl ;
|
||||
|
||||
SymbOrd = mkOrd ;
|
||||
|
||||
|
||||
lincat
|
||||
|
||||
@@ -42,13 +43,11 @@ lincat
|
||||
lin
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS "र" ;
|
||||
BaseSymb = infixSS "と" ;
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
oper
|
||||
-- Note: this results in a space before 's, but there's
|
||||
-- not mauch we can do about that.
|
||||
addGenitiveS : Str -> Case => Str = \s ->
|
||||
table {_ => Prelude.glue s "दा" } ;
|
||||
-}
|
||||
-- level 53 (covered by CNNumNP)
|
||||
--CNIntNP cn i = {} ;
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user