mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-28 04:08:55 -06:00
added QuestIComp to Pred
This commit is contained in:
@@ -58,7 +58,7 @@ fun
|
|||||||
QuestSlash : (a : Arg) -> IP -> PrQCl (aNP a) -> PrQCl a ;
|
QuestSlash : (a : Arg) -> IP -> PrQCl (aNP a) -> PrQCl a ;
|
||||||
QuestCl : (a : Arg) -> PrCl a -> PrQCl a ;
|
QuestCl : (a : Arg) -> PrCl a -> PrQCl a ;
|
||||||
QuestIAdv : (a : Arg) -> IAdv -> PrCl a -> PrQCl a ;
|
QuestIAdv : (a : Arg) -> IAdv -> PrCl a -> PrQCl a ;
|
||||||
QuestIComp : IComp -> NP -> PrQCl aNone ;
|
QuestIComp : Ant -> Tense -> Pol -> IComp -> NP -> PrQCl aNone ; -- where is she
|
||||||
|
|
||||||
UseCl : PrCl aNone -> PrS ;
|
UseCl : PrCl aNone -> PrS ;
|
||||||
UseQCl : PrQCl aNone -> PrS ; -- deprecate QS
|
UseQCl : PrQCl aNone -> PrS ; -- deprecate QS
|
||||||
|
|||||||
@@ -1,4 +1,20 @@
|
|||||||
concrete PredEng of Pred =
|
concrete PredEng of Pred =
|
||||||
CatEng [Ant,NP,Utt,IP,IAdv,Conj,RP,RS,Imp] **
|
CatEng [Ant,NP,Utt,IP,IAdv,IComp,Conj,RP,RS] **
|
||||||
PredFunctor with
|
PredFunctor - [QuestIComp] ---- IComp has no parameters in Eng
|
||||||
(PredInterface = PredInstanceEng) ;
|
with
|
||||||
|
(PredInterface = PredInstanceEng)
|
||||||
|
|
||||||
|
** open PredInstanceEng in {
|
||||||
|
|
||||||
|
lin
|
||||||
|
QuestIComp a t p icomp np =
|
||||||
|
let vagr = (agr2vagr np.a) in
|
||||||
|
initPrClause ** {
|
||||||
|
v = tenseCopula (a.s ++ t.s ++ p.s) t.t a.a p.p vagr ;
|
||||||
|
subj = np.s ! subjCase ;
|
||||||
|
foc = icomp.s ;
|
||||||
|
focType = FocObj ;
|
||||||
|
qforms = qformsCopula (a.s ++ t.s ++ p.s) t.t a.a p.p vagr ;
|
||||||
|
} ;
|
||||||
|
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
incomplete concrete PredFunctor of Pred = Cat [Ant,NP,Utt,IP,IAdv,Conj,RP,RS] **
|
incomplete concrete PredFunctor of Pred = Cat [Ant,NP,Utt,IP,IAdv,IComp,Conj,RP,RS] **
|
||||||
open
|
open
|
||||||
PredInterface,
|
PredInterface,
|
||||||
ParamX,
|
ParamX,
|
||||||
@@ -221,6 +221,17 @@ lin
|
|||||||
} ;
|
} ;
|
||||||
-}
|
-}
|
||||||
|
|
||||||
|
QuestIComp a t p icomp np =
|
||||||
|
let vagr = (agr2vagr np.a) in
|
||||||
|
initPrClause ** {
|
||||||
|
v = tenseCopula (a.s ++ t.s ++ p.s) t.t a.a p.p vagr ;
|
||||||
|
subj = np.s ! subjCase ;
|
||||||
|
adV = negAdV p ;
|
||||||
|
foc = icomp.s ! agr2icagr np.a ;
|
||||||
|
focType = FocObj ;
|
||||||
|
qforms = qformsCopula (a.s ++ t.s ++ p.s) t.t a.a p.p vagr ;
|
||||||
|
} ;
|
||||||
|
|
||||||
RelVP rp vp =
|
RelVP rp vp =
|
||||||
let
|
let
|
||||||
cl : Agr -> PrClause = \a ->
|
cl : Agr -> PrClause = \a ->
|
||||||
|
|||||||
@@ -47,6 +47,7 @@ oper
|
|||||||
NAgr = Number ;
|
NAgr = Number ;
|
||||||
IPAgr = Number ;
|
IPAgr = Number ;
|
||||||
RPAgr = ResEng.RAgr ;
|
RPAgr = ResEng.RAgr ;
|
||||||
|
ICAgr = Unit ;
|
||||||
|
|
||||||
defaultAgr : Agr = AgP3Sg Neutr ;
|
defaultAgr : Agr = AgP3Sg Neutr ;
|
||||||
|
|
||||||
@@ -66,6 +67,8 @@ oper
|
|||||||
AgP3Pl => Pl
|
AgP3Pl => Pl
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
agr2icagr : Agr -> ICAgr = \a -> UUnit ;
|
||||||
|
|
||||||
-- restoring full Agr
|
-- restoring full Agr
|
||||||
ipagr2agr : IPAgr -> Agr = \n -> case n of {
|
ipagr2agr : IPAgr -> Agr = \n -> case n of {
|
||||||
Sg => AgP3Sg Neutr ; ---- gender
|
Sg => AgP3Sg Neutr ; ---- gender
|
||||||
|
|||||||
@@ -42,6 +42,7 @@ oper
|
|||||||
NAgr = Number ; --- only Indef Nom forms are needed here
|
NAgr = Number ; --- only Indef Nom forms are needed here
|
||||||
IPAgr = Number ; ----{g : Gender ; n : Number} ; --- two separate fields in RGL
|
IPAgr = Number ; ----{g : Gender ; n : Number} ; --- two separate fields in RGL
|
||||||
RPAgr = RAgr ;
|
RPAgr = RAgr ;
|
||||||
|
ICAgr = AFormPos ;
|
||||||
|
|
||||||
defaultAgr : Agr = {g = Utr ; n = Sg ; p = P3} ;
|
defaultAgr : Agr = {g = Utr ; n = Sg ; p = P3} ;
|
||||||
|
|
||||||
@@ -50,6 +51,8 @@ oper
|
|||||||
|
|
||||||
agr2aagr : Agr -> AAgr = \a -> a ;
|
agr2aagr : Agr -> AAgr = \a -> a ;
|
||||||
|
|
||||||
|
agr2icagr : Agr -> ICAgr = agr2aformpos ;
|
||||||
|
|
||||||
--- could use this?
|
--- could use this?
|
||||||
agr2aformpos : Agr -> AFormPos = \a ->
|
agr2aformpos : Agr -> AFormPos = \a ->
|
||||||
case a.n of {
|
case a.n of {
|
||||||
|
|||||||
@@ -66,14 +66,16 @@ oper
|
|||||||
AAgr = Agr ; -- because of reflexives: "happy with itself"
|
AAgr = Agr ; -- because of reflexives: "happy with itself"
|
||||||
IPAgr : PType ; -- agreement of IP
|
IPAgr : PType ; -- agreement of IP
|
||||||
RPAgr : PType ; -- agreement of RP
|
RPAgr : PType ; -- agreement of RP
|
||||||
|
ICAgr : PType ; -- agreement to IComp
|
||||||
|
|
||||||
defaultAgr : Agr ;
|
defaultAgr : Agr ;
|
||||||
|
|
||||||
-- omitting parts of Agr information
|
-- omitting parts of Agr information
|
||||||
|
|
||||||
agr2vagr : Agr -> VAgr ;
|
agr2vagr : Agr -> VAgr ;
|
||||||
agr2aagr : Agr -> AAgr ;
|
agr2aagr : Agr -> AAgr ;
|
||||||
agr2nagr : Agr -> NAgr ;
|
agr2nagr : Agr -> NAgr ;
|
||||||
|
agr2icagr : Agr -> ICAgr ;
|
||||||
|
|
||||||
-- restoring full Agr
|
-- restoring full Agr
|
||||||
ipagr2agr : IPAgr -> Agr ;
|
ipagr2agr : IPAgr -> Agr ;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
concrete PredSwe of Pred =
|
concrete PredSwe of Pred =
|
||||||
CatSwe [Ant,NP,Utt,IP,IAdv,Conj,RP,RS,Imp] **
|
CatSwe [Ant,NP,Utt,IP,IAdv,IComp,Conj,RP,RS,Imp] **
|
||||||
PredFunctor - [RelVP,RelSlash] ---- incompatible arity: to be fixed in RGL
|
PredFunctor - [RelVP,RelSlash] ---- incompatible arity: to be fixed in RGL
|
||||||
with
|
with
|
||||||
(PredInterface = PredInstanceSwe)
|
(PredInterface = PredInstanceSwe)
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ abstract RGLBase =
|
|||||||
Adverb,
|
Adverb,
|
||||||
Phrase,
|
Phrase,
|
||||||
---- Sentence,
|
---- Sentence,
|
||||||
---- Question,
|
Question - [QuestCl,QuestVP,QuestSlash,QuestIAdv,QuestIComp],
|
||||||
Relative - [RelCl,RelVP,RelSlash],
|
Relative - [RelCl,RelVP,RelSlash],
|
||||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||||
|
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ concrete RGLBaseEng of RGLBase =
|
|||||||
AdverbEng,
|
AdverbEng,
|
||||||
PhraseEng,
|
PhraseEng,
|
||||||
---- Sentence,
|
---- Sentence,
|
||||||
---- Question,
|
QuestionEng - [QuestCl,QuestVP,QuestSlash,QuestIAdv,QuestIComp],
|
||||||
RelativeEng - [RelCl,RelVP,RelSlash],
|
RelativeEng - [RelCl,RelVP,RelSlash],
|
||||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||||
|
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ concrete RGLBaseSwe of RGLBase =
|
|||||||
AdverbSwe,
|
AdverbSwe,
|
||||||
PhraseSwe,
|
PhraseSwe,
|
||||||
---- Sentence,
|
---- Sentence,
|
||||||
---- Question,
|
QuestionSwe - [QuestCl,QuestVP,QuestSlash,QuestIAdv,QuestIComp],
|
||||||
RelativeSwe - [RelCl,RelVP,RelSlash],
|
RelativeSwe - [RelCl,RelVP,RelSlash],
|
||||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user