fixed SentAP and AdvAP for AdjPlace in ResChi

This commit is contained in:
1Regina
2021-12-17 14:50:20 +08:00
committed by Inari Listenmaa
parent b26e6e1c9f
commit 565cd8fa61
2 changed files with 60 additions and 46 deletions

View File

@@ -18,12 +18,20 @@ concrete AdjectiveChi of Adjective = CatChi ** open ResChi, Prelude in {
ReflA2 a = complexAP (a.s ++ appPrep a.c2 reflPron) ;
SentAP ap sc = complexAP (ap.s ++ sc.s) ;
-- SentAP ap sc = complexAP (ap.s ++ sc.s) ;
SentAP ap sc = ap ** {
s = table { adjPlace => ap.s ! adjPlace ++ sc.s }
} ;
AdAP ada ap = {s = ada.s ++ ap.s ; monoSyl = False ; hasAdA = True} ;
UseA2 a = a ** {hasAdA = False} ;
AdvAP ap adv = complexAP (adv.s ++ ap.s) ; ----
-- AdvAP ap adv = complexAP (adv.s ++ ap.s) ;
AdvAP ap adv = ap ** {
s = table { adjPlace => adv.s ++ ap.s ! adjPlace }
};
}

View File

@@ -96,6 +96,8 @@ param
AdvType = ATPlace Bool | ATTime | ATManner | ATPoss ; -- ATPlace True = has zai_s already
AdjPlace = Attr | Pred ; -- a green cat / the cat is green colour
-- parts of speech
oper
@@ -113,15 +115,19 @@ oper
-- for morphology
Noun : Type = {s : Str ; c : Str} ;
Adj : Type = {s : Str ; monoSyl: Bool} ;
Adj : Type = {s : AdjPlace => Str ; monoSyl: Bool} ;
Verb : Type = {s,sn : Str ; pp,ds,dp,ep : Str ; neg : Str} ; --- sn=[] needed for "hen" as copula
regNoun : Str -> Str -> Noun = \s,c -> {s = word s ; c = word c};
mkAdj : Str -> Bool -> Adj = \s,b -> {s = word s ; monoSyl = b};
mkAdj : Str -> Bool -> Adj = \s,b -> {s =
table {
_ => word s
};
monoSyl = b};
complexAP : Str -> Adj ** {hasAdA : Bool} =
\s -> {s = s ; monoSyl = False ; hasAdA = False} ; --- not used for adding AdA
\s -> mkAdj s False ** {hasAdA = False} ; --- not used for adding AdA
simpleAdj : Str -> Adj = \s -> case s of {
? => mkAdj s True ; -- monosyllabic