mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 17:08:54 -06:00
(Kor) Add Style as a variable up to S. Utt chooses Polite.
If different politeness levels are wanted in applications, UttS can be overriden.
This commit is contained in:
@@ -8,7 +8,7 @@ concrete CatKor of Cat = CommonX ** open ResKor, Prelude in {
|
|||||||
-- Constructed in SentenceKor, and also in IdiomKor
|
-- Constructed in SentenceKor, and also in IdiomKor
|
||||||
|
|
||||||
S = ResKor.Sentence ;
|
S = ResKor.Sentence ;
|
||||||
QS = SS ; -- Questions not implemented yet
|
QS = {s : Style => Str}; -- Questions not implemented yet
|
||||||
RS = ResKor.Sentence ;
|
RS = ResKor.Sentence ;
|
||||||
-- relative sentence. Tense and polarity fixed,
|
-- relative sentence. Tense and polarity fixed,
|
||||||
-- but agreement may depend on the CN/NP it modifies.
|
-- but agreement may depend on the CN/NP it modifies.
|
||||||
|
|||||||
Binary file not shown.
@@ -3,8 +3,8 @@ concrete PhraseKor of Phrase = CatKor ** open Prelude, ResKor in {
|
|||||||
lin
|
lin
|
||||||
PhrUtt pconj utt voc = {s = pconj.s ++ utt.s ++ voc.s} ;
|
PhrUtt pconj utt voc = {s = pconj.s ++ utt.s ++ voc.s} ;
|
||||||
|
|
||||||
UttS s = {s = s.s ! Statement} ;
|
UttS s = {s = s.s ! Statement linStyle} ;
|
||||||
UttQS qs = qs ;
|
UttQS qs = {s = qs.s ! linStyle} ;
|
||||||
UttIAdv iadv = iadv ;
|
UttIAdv iadv = iadv ;
|
||||||
UttAdv adv = adv ;
|
UttAdv adv = adv ;
|
||||||
UttInterj i = i ;
|
UttInterj i = i ;
|
||||||
@@ -19,7 +19,7 @@ concrete PhraseKor of Phrase = CatKor ** open Prelude, ResKor in {
|
|||||||
UttVP vp = {s = linVP linVF vp} ;
|
UttVP vp = {s = linVP linVF vp} ;
|
||||||
UttCN cn = {s = cn.rs ++ cn.s ! Bare} ;
|
UttCN cn = {s = cn.rs ++ cn.s ! Bare} ;
|
||||||
UttCard n = {s = n.s ! NK ! Indep} ;
|
UttCard n = {s = n.s ! NK ! Indep} ;
|
||||||
UttAP ap = { s = ap.compar ++ ap.s ! VF Plain Pos} ;
|
UttAP ap = {s = ap.compar ++ ap.s ! VF Plain Pos} ;
|
||||||
|
|
||||||
NoPConj = {s = []} ;
|
NoPConj = {s = []} ;
|
||||||
-- PConjConj conj = {s = conj.s1 ++ conj.s2 ! …} ;
|
-- PConjConj conj = {s = conj.s1 ++ conj.s2 ! …} ;
|
||||||
|
|||||||
@@ -361,7 +361,7 @@ oper
|
|||||||
let vf = case cltyp of {
|
let vf = case cltyp of {
|
||||||
Subord => VAttr p ;
|
Subord => VAttr p ;
|
||||||
WithConj => VStem p ;
|
WithConj => VStem p ;
|
||||||
_ => VF Polite p } -- TODO: more tenses, politeness
|
Statement st => VF st p } -- TODO: more tenses
|
||||||
in np
|
in np
|
||||||
++ vp.nObj -- an object, not copula complement
|
++ vp.nObj -- an object, not copula complement
|
||||||
++ vp.adv
|
++ vp.adv
|
||||||
|
|||||||
@@ -53,10 +53,13 @@ lin
|
|||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- : Temp -> Pol -> QCl -> QS ;
|
-- : Temp -> Pol -> QCl -> QS ;
|
||||||
UseQCl t p cl = {s = t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! Statement} ;
|
UseQCl t p cl = {
|
||||||
|
s = \\st => t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! Statement st} ;
|
||||||
|
|
||||||
-- : Temp -> Pol -> RCl -> RS ;
|
-- : Temp -> Pol -> RCl -> RS ;
|
||||||
UseRCl t p rcl = {s = \\c => t.s ++ p.s ++ rcl.s ! t.t ! t.a ! p.p ! c} ;
|
UseRCl t p rcl = {
|
||||||
|
s = \\c => t.s ++ p.s ++ rcl.s ! t.t ! t.a ! p.p ! c
|
||||||
|
} ;
|
||||||
|
|
||||||
-- AdvS : Adv -> S -> S ; -- then I will go home
|
-- AdvS : Adv -> S -> S ; -- then I will go home
|
||||||
AdvS = advS "" ;
|
AdvS = advS "" ;
|
||||||
|
|||||||
Reference in New Issue
Block a user