1
0
forked from GitHub/gf-rgl

support but as a conjunction

This commit is contained in:
Krasimir Angelov
2018-06-14 08:13:02 +02:00
parent cb53630c60
commit b993704225
7 changed files with 37 additions and 24 deletions

View File

@@ -68,7 +68,7 @@ concrete CatBul of Cat = CommonX - [IAdv,CAdv,AdV,SC] ** open ResBul, Prelude, P
-- Structural -- Structural
Conj = {s : Str; distr : Bool; conj : Ints 2; n : Number} ; Conj = {s : Str; distr : Bool; conj : Ints 3; n : Number} ;
Subj = {s : Str} ; Subj = {s : Str} ;
Prep = {s : Str; c : Case} ; Prep = {s : Str; c : Case} ;

View File

@@ -87,13 +87,13 @@ concrete ConjunctionBul of Conjunction =
g = x.g} ; g = x.g} ;
lincat lincat
[S] = {s : Bool => Ints 2 => Str} ; [S] = {s : Bool => Ints 3 => Str} ;
[Adv] = {s : Bool => Ints 2 => Str} ; [Adv] = {s : Bool => Ints 3 => Str} ;
[AdV] = {s : Bool => Ints 2 => Str} ; [AdV] = {s : Bool => Ints 3 => Str} ;
[IAdv] = {s : Bool => Ints 2 => QForm => Str} ; [IAdv] = {s : Bool => Ints 3 => QForm => Str} ;
[NP] = {s : Bool => Ints 2 => Role => Str; a : Agr} ; [NP] = {s : Bool => Ints 3 => Role => Str; a : Agr} ;
[AP] = {s : Bool => Ints 2 => AForm => Person => Str; adv : Bool => Ints 2 => Str; isPre : Bool} ; [AP] = {s : Bool => Ints 3 => AForm => Person => Str; adv : Bool => Ints 3 => Str; isPre : Bool} ;
[RS] = {s : Bool => Ints 2 => Agr => Str} ; [RS] = {s : Bool => Ints 3 => Agr => Str} ;
[CN] = {s : Bool => Ints 2 => NForm => Str; g : AGender} ; [CN] = {s : Bool => Ints 3 => NForm => Str; g : AGender} ;
} }

View File

@@ -19,7 +19,7 @@ lin
}) Indef }) Indef
in { in {
s = \\nf => case n1.relPost of { s = \\nf => case n1.relPost of {
True => n2.s ! (indefNForm nf) ++ n1.rel ! nform2aform nf n2.g ; True => n2.s ! nf ++ n1.rel ! nform2aform nf n2.g ;
False => n1.rel ! nform2aform nf n2.g ++ n2.s ! indefNForm nf False => n1.rel ! nform2aform nf n2.g ++ n2.s ! indefNForm nf
} ; } ;
rel = \\af => n1.rel ! aform ++ n2.s ! NF Sg Indef ; relPost = n1.relPost ; rel = \\af => n1.rel ! aform ++ n2.s ! NF Sg Indef ; relPost = n1.relPost ;
@@ -94,7 +94,7 @@ lin
lincat lincat
VPS = {s : Agr => Str} ; VPS = {s : Agr => Str} ;
[VPS] = {s : Bool => Ints 2 => Agr => Str} ; [VPS] = {s : Bool => Ints 3 => Agr => Str} ;
lin lin
BaseVPS x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ; BaseVPS x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ;

View File

@@ -58,7 +58,7 @@ concrete ExtraBul of ExtraBulAbs = CatBul **
lincat lincat
VPI = {s : Agr => Str} ; VPI = {s : Agr => Str} ;
[VPI] = {s : Bool => Ints 2 => Agr => Str} ; [VPI] = {s : Bool => Ints 3 => Agr => Str} ;
lin lin
BaseVPI x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ; BaseVPI x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ;
@@ -73,7 +73,7 @@ concrete ExtraBul of ExtraBulAbs = CatBul **
lincat lincat
VPS = {s : Agr => Str} ; VPS = {s : Agr => Str} ;
[VPS] = {s : Bool => Ints 2 => Agr => Str} ; [VPS] = {s : Bool => Ints 3 => Agr => Str} ;
lin lin
BaseVPS x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ; BaseVPS x y = {s = \\d,t,a=>x.s!a++linCoord!t++y.s!a} ;

View File

@@ -222,7 +222,14 @@ oper
dualN : N -> Prep -> N dualN : N -> Prep -> N
= \n,p -> lin N { s = n.s; = \n,p -> lin N { s = n.s;
rel = \\_ => p.s ++ n.s ! NF Sg Def ; relPost = True; rel = \\_ => p.s ++
case p.c of {
Acc => "" ;
Dat => "íà" ;
WithPrep => with_Word
} ++
n.s ! NF Sg Def ;
relPost = True;
g = n.g g = n.g
} }
} ; } ;

View File

@@ -46,8 +46,9 @@ concrete NounBul of Noun = CatBul ** open ResBul, Prelude in {
} ; } ;
UsePN pn = { s = table { UsePN pn = { s = table {
RObj Dat => "íà" ++ pn.s; RObj Dat => "íà" ++ pn.s;
_ => pn.s RObj WithPron => with_Word ++ pn.s;
_ => pn.s
} ; } ;
a = {gn = GSg pn.g; p = P3} ; a = {gn = GSg pn.g; p = P3} ;
p = Pos p = Pos
@@ -55,7 +56,12 @@ concrete NounBul of Noun = CatBul ** open ResBul, Prelude in {
UsePron p = {s = p.s; a=p.a; p=Pos} ; UsePron p = {s = p.s; a=p.a; p=Pos} ;
PredetNP pred np = { PredetNP pred np = {
s = \\c => pred.s ! np.a.gn ++ np.s ! c ; s = \\c => case c of {
RObj Dat => "íà";
RObj WithPrep => with_Word;
_ => ""
} ++
pred.s ! np.a.gn ++ np.s ! RObj Acc ;
a = np.a ; a = np.a ;
p = np.p p = np.p
} ; } ;

View File

@@ -330,7 +330,7 @@ resource ResBul = ParamX ** open Prelude, Predef in {
VPresPart aform => regAdjective "áúäåù" ! aform ; VPresPart aform => regAdjective "áúäåù" ! aform ;
VImperative Sg => "áúäè" ; VImperative Sg => "áúäè" ;
VImperative Pl => "áúäåòå" ; VImperative Pl => "áúäåòå" ;
VNoun _ => ""; VNoun _ => "áúäåíå";
VGerund => "áèäåéêè" VGerund => "áèäåéêè"
} ; } ;
@@ -358,7 +358,7 @@ resource ResBul = ParamX ** open Prelude, Predef in {
VPresPart aform => regAdjective "áúäåù" ! aform ; VPresPart aform => regAdjective "áúäåù" ! aform ;
VImperative Sg => "áúäè" ; VImperative Sg => "áúäè" ;
VImperative Pl => "áúäåòå" ; VImperative Pl => "áúäåòå" ;
VNoun _ => ""; VNoun _ => "áúäåíå";
VGerund => "áúäåéêè" VGerund => "áúäåéêè"
} ; } ;
@@ -786,12 +786,12 @@ resource ResBul = ParamX ** open Prelude, Predef in {
GPl => "òåçè" GPl => "òåçè"
} ; } ;
linCoord : Ints 2 => Str ; linCoord : Ints 3 => Str ;
linCoord = table {0 => "è"; 1=>"èëè"; 2=>"íèòî"} ; linCoord = table {0 => "è"; 1=>"èëè"; 2=>"íèòî"; 3=>"íî"} ;
linCoordSep : Str -> Bool => Ints 2 => Str ; linCoordSep : Str -> Bool => Ints 3 => Str ;
linCoordSep s = table {True => linCoord; False=> \\_ => s} ; linCoordSep s = table {True => linCoord; False=> \\_ => s} ;
comma : Str = SOFT_BIND ++ "," ; comma : Str = SOFT_BIND ++ "," ;
hyphen : Str = SOFT_BIND ++ "-" ++ SOFT_BIND ; hyphen : Str = SOFT_BIND ++ "-" ++ SOFT_BIND ;