forked from GitHub/gf-rgl
=Modified UseComp to correctly apply Adverbs, Adjectives and Nouns as proper complements when forming a VP based on the verb to be. However in Rukiga, sometimes the verb ba or ri are used. I have left the application of the right form to post-processing
This commit is contained in:
@@ -6,7 +6,7 @@ concrete CatCgg of Cat = CommonX -[Adv,IAdv, AdA]**
|
||||
lincat
|
||||
|
||||
|
||||
Imp = {s : Res. ImpPol=> Str} ;
|
||||
Imp = {s : Res.ImpPol=> Str} ;
|
||||
QS = {s : Str} ;
|
||||
|
||||
-- Note: SS is a shorthand for {s:Str}, defined in Prelude.gf
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
--# -path=.:../prelude:../abstract:../common
|
||||
|
||||
concrete IdiomCgg of Idiom = CatCgg **
|
||||
open Prelude, ResCgg in {
|
||||
open Prelude,Predef, ResCgg in {
|
||||
|
||||
|
||||
lin
|
||||
ImpPl1 vp = {s="tu" ++ BIND ++ vp.s ++ BIND ++ vp.pres ++ BIND ++ "6e"}; -- let's go
|
||||
{-
|
||||
--1 Idiom: Idiomatic Expressions
|
||||
|
||||
|
||||
@@ -1622,7 +1622,7 @@ mkSubjPrefix : Agreement -> Str =\a ->case a of {
|
||||
param
|
||||
CompSource = NounP | ADverb | AdjP | CommonNoun;
|
||||
oper
|
||||
Comp : Type = {s:Str; source : CompSource };
|
||||
Comp : Type = {s:Str; source : CompSource};
|
||||
|
||||
|
||||
--Conjunctions
|
||||
|
||||
@@ -281,8 +281,8 @@ lin
|
||||
|
||||
|
||||
|
||||
PredVP np vp = case <vp.isCompApStem, vp.containsAdV,vp.containsComp, vp.containsComp2> of {
|
||||
<False,True,False,False> => {
|
||||
PredVP np vp = case <vp.isCompApStem,vp.containsAdv, vp.containsAdV,vp.containsComp, vp.containsComp2> of {
|
||||
<False,False,True,False,False> => {
|
||||
s = np.s ! Nom; --: NP -> VP -> Cl ; -- John walks / John does not walk
|
||||
subjAgr = np.agr;
|
||||
pres = vp.pres;
|
||||
@@ -301,8 +301,27 @@ lin
|
||||
--root = vp.root ;
|
||||
compl = vp.adV
|
||||
};
|
||||
<False,True,False,False,False> => {
|
||||
s = np.s ! Nom; --: NP -> VP -> Cl ; -- John walks / John does not walk
|
||||
subjAgr = np.agr;
|
||||
pres = vp.pres;
|
||||
perf = vp.perf;
|
||||
root = vp.s;
|
||||
--morphs = vp.morphs;
|
||||
isPresBlank = vp.isPresBlank;
|
||||
isPerfBlank = vp.isPerfBlank;
|
||||
{-
|
||||
inf = mkVerbInrf vp.root;
|
||||
pres = mkVerbPres vp.root;
|
||||
past = mkVerbPast vp.root;
|
||||
presPart = mkVerbPresPart vp.root;
|
||||
pastPart = mkVerbPastPart vp.root; -- subject
|
||||
-}
|
||||
--root = vp.root ;
|
||||
compl = vp.adv
|
||||
};
|
||||
|
||||
<_, _,True,False> => {
|
||||
<_, _,_,True,False> => {
|
||||
s = np.s ! Nom; --: NP -> VP -> Cl ; -- John walks / John does not walk
|
||||
subjAgr = np.agr;
|
||||
pres = vp.pres;
|
||||
@@ -321,7 +340,7 @@ lin
|
||||
--root = vp.root ;
|
||||
compl = mkSubjClitic np.agr ++ vp.comp --mkSubjClitic np.agr ++ Predef.BIND ++ vp.comp
|
||||
};
|
||||
<_, _,True, True> => {
|
||||
<_, _,_,True, True> => {
|
||||
s = np.s ! Nom; --: NP -> VP -> Cl ; -- John walks / John does not walk
|
||||
subjAgr = np.agr;
|
||||
pres = vp.pres;
|
||||
@@ -340,7 +359,7 @@ lin
|
||||
--root = vp.root ;
|
||||
compl = mkSubjClitic np.agr ++ vp.comp ++ vp.comp2 --mkSubjClitic np.agr ++ Predef.BIND ++ vp.comp
|
||||
};
|
||||
<_, _,_, _> => {
|
||||
<_, _,_,_, _> => {
|
||||
s = np.s ! Nom; --: NP -> VP -> Cl ; -- John walks / John does not walk
|
||||
subjAgr = np.agr;
|
||||
pres = vp.pres;
|
||||
|
||||
@@ -32,7 +32,7 @@ lin
|
||||
--in
|
||||
case comp.source of{
|
||||
AdjP => {
|
||||
s = mkBecome.s ++ BIND ++ mkBecome.pres; --Assuming there is no AP which is prepositional
|
||||
s = mkBecome.s ; --Assuming there is no AP which is prepositional
|
||||
pres =[];
|
||||
perf = [];
|
||||
isPresBlank = True;
|
||||
@@ -51,8 +51,8 @@ lin
|
||||
containsComp = True;
|
||||
containsComp2 = False
|
||||
};
|
||||
_ => {
|
||||
s = mkBecome.s ++ BIND ++mkBecome.pres++ comp.s; --Assuming there is no AP which is prepositional
|
||||
ADverb => {
|
||||
s = mkBecome.s ; --Assuming there is no AP which is prepositional
|
||||
pres =[];
|
||||
perf = [];
|
||||
--morphs=\\form,morphs=>[];
|
||||
@@ -64,6 +64,46 @@ lin
|
||||
isCompApStem = False;
|
||||
agr = AgrNo;
|
||||
isRegular = False;
|
||||
adv = comp.s;
|
||||
containsAdv =True;
|
||||
adV =[];
|
||||
containsAdV = False;
|
||||
containsComp = False;
|
||||
containsComp2 = False
|
||||
};
|
||||
NounP => {
|
||||
s = mkBecome.s ; --Assuming there is no AP which is prepositional
|
||||
pres =[];
|
||||
perf = [];
|
||||
--morphs=\\form,morphs=>[];
|
||||
isPresBlank = True;
|
||||
isPerfBlank = True;
|
||||
comp = comp.s;
|
||||
comp2 = [];
|
||||
ap = [];
|
||||
isCompApStem = False;
|
||||
agr = AgrNo;
|
||||
isRegular = False;
|
||||
adv = [];
|
||||
containsAdv =False;
|
||||
adV =[];
|
||||
containsAdV = False;
|
||||
containsComp = True;
|
||||
containsComp2 = False
|
||||
};
|
||||
_ => {
|
||||
s = mkBecome.s ; --Assuming there is no AP which is prepositional
|
||||
pres =[];
|
||||
perf = [];
|
||||
--morphs=\\form,morphs=>[];
|
||||
isPresBlank = True;
|
||||
isPerfBlank = True;
|
||||
comp = comp.s;
|
||||
comp2 = [];
|
||||
ap = [];
|
||||
isCompApStem = False;
|
||||
agr = AgrNo;
|
||||
isRegular = False;
|
||||
adv = [];
|
||||
containsAdv =False;
|
||||
adV =[];
|
||||
|
||||
Reference in New Issue
Block a user