1
0
forked from GitHub/gf-rgl

(Kor) Add ConjS + new form in S and Cl inflection table

This commit is contained in:
Inari Listenmaa
2020-03-27 11:42:05 +01:00
parent ec0173c587
commit 8a151c684a
5 changed files with 33 additions and 17 deletions

View File

@@ -48,17 +48,29 @@ lin
BaseRS = twoTable3 … ; BaseRS = twoTable3 … ;
ConsRS = consrTable3 … comma ; ConsRS = consrTable3 … comma ;
ConjRS = conjunctRSTable ; ConjRS = conjunctRSTable ;
-}
lincat lincat
[S] = {} ; [S] = ResKor.Sentence ** {firstS : ConjType => Str} ;
lin lin
BaseS x y = y ** { } ; BaseS s1 s2 = s2 ** {
ConsS x xs = firstS = mkFirstS s1
xs ** { } ; } ;
ConjS co xs = {} ;
-} ConsS s ss = ss ** {
firstS = \\conj =>
mkFirstS s ! conj ++ ss.firstS ! conj ;
} ;
ConjS co ss = ss ** {
s = \\st => co.s1 ++ ss.firstS ! co.c ++ ss.s ! st
} ;
oper
mkFirstS : ResKor.Sentence -> ConjType => Str = \s ->
\\conj => glue (s.s ! Subord) (conjTable ! NStar ! conj) ;
lincat lincat
[AP] = ResKor.AdjPhrase ** {firstAP : AForm => ConjType => Str} ; [AP] = ResKor.AdjPhrase ** {firstAP : AForm => ConjType => Str} ;

Binary file not shown.

View File

@@ -3,7 +3,7 @@ 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 ; UttS s = {s = s.s ! Statement} ;
UttQS qs = qs ; UttQS qs = qs ;
UttIAdv iadv = iadv ; UttIAdv iadv = iadv ;
{- {-

View File

@@ -294,7 +294,7 @@ oper
-------------------------------------------------------------------------------- --------------------------------------------------------------------------------
-- Cl, S -- Cl, S
Clause : Type = {s : Tense => Anteriority => Polarity => Str} ; Clause : Type = {s : Tense => Anteriority => Polarity => ClType => Str} ;
{- After PredVP, we might still want to add more adverbs (QuestIAdv), {- After PredVP, we might still want to add more adverbs (QuestIAdv),
but we're done with verb inflection. but we're done with verb inflection.
@@ -305,13 +305,17 @@ oper
RClause : Type = {s : NForm => Tense => Anteriority => Polarity => Str} ; RClause : Type = {s : NForm => Tense => Anteriority => Polarity => Str} ;
Sentence : Type = {s : Str} ; Sentence : Type = {s : ClType => Str} ;
predVP : NounPhrase -> VerbPhrase -> ClSlash = \np,vp -> vp ** { predVP : NounPhrase -> VerbPhrase -> ClSlash = \np,vp -> vp ** {
s = \\t,a,p => np.s ! vp.sc s = \\t,a,p,cltyp =>
++ vp.nObj -- an object, not copula complement let vf = case cltyp of {
++ vp.adv Subord => VStem ;
++ vp.s ! VF Polite p -- TODO: more tenses, choose politeness _ => VF Polite p } -- TODO: more tenses, politeness
in np.s ! vp.sc
++ vp.nObj -- an object, not copula complement
++ vp.adv
++ vp.s ! vf
} ; } ;
-------------------------------------------------------------------------------- --------------------------------------------------------------------------------

View File

@@ -49,11 +49,11 @@ lin
-- : Temp -> Pol -> Cl -> S ; -- : Temp -> Pol -> Cl -> S ;
UseCl t p cl = { UseCl t p cl = {
s = t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p s = \\c => t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! c
} ; } ;
-- : 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} ; UseQCl t p cl = {s = t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! Statement} ;
-- : Temp -> Pol -> RCl -> RS ; -- : Temp -> Pol -> RCl -> RS ;
-- UseRCl t p cl = {s = } ; -- UseRCl t p cl = {s = } ;
@@ -73,7 +73,7 @@ lin
oper oper
advS : (comma : Str) -> Adverb -> S -> S = \comma,a,sent -> sent ** { advS : (comma : Str) -> Adverb -> S -> S = \comma,a,sent -> sent ** {
s = a.s ++ comma ++ sent.s s = \\c => a.s ++ comma ++ sent.s ! c
} ; } ;
} }