forked from GitHub/gf-core
Pred: proper forms of Eng auxiliaries; variants for Swe negation and future aux
This commit is contained in:
@@ -16,7 +16,8 @@ lin
|
||||
LiftVQ v = liftV v ;
|
||||
LiftVA v = liftV v ; ---- c1?
|
||||
LiftVN v = liftV v ; ---- c1?
|
||||
LiftVV v = {s = \\f => v.s ! VVF f ; p = v.p ; c1,c2 = [] ; isSubjectControl = False ; vtype = VTAct ; vvtype = VVInf} ; ---- c1? ---- VVF
|
||||
LiftVV v = {s = \\f => v.s ! VVF f ; p = v.p ; c1,c2 = [] ; isSubjectControl = False ;
|
||||
vtype = case v.typ of {VAux => VTAux ; _ => VTAct} ; vvtype = v.typ} ; ---- c1? ---- VVF
|
||||
|
||||
LiftV3 v = liftV v ** {c1 = v.c2 ; c2 = v.c3} ;
|
||||
LiftV2S v = liftV v ** {c1 = v.c2} ;
|
||||
|
||||
@@ -188,7 +188,7 @@ fun
|
||||
--< UseAdvCl : PrAdv aNone -> PrCl aNone -> PrS ; -- lift adv to front
|
||||
UseAdvCl_none : PrAdv_none -> PrCl_none -> PrS ;
|
||||
|
||||
UttS : PrS -> Utt ;
|
||||
UttPrS : PrS -> Utt ;
|
||||
|
||||
--< AdvCl : (a : Arg) -> PrAdv a -> PrCl aNone -> PrCl a ;
|
||||
AdvCl_none : PrAdv_none -> PrCl_none -> PrCl_none ;
|
||||
|
||||
@@ -145,8 +145,8 @@ lin
|
||||
UseAdvCl_none
|
||||
= Pred.UseAdvCl ;
|
||||
|
||||
UttS
|
||||
= Pred.UttS ;
|
||||
UttPrS
|
||||
= Pred.UttPrS ;
|
||||
|
||||
AdvCl_none, AdvCl_np
|
||||
= Pred.AdvCl Pred.aNone ;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
abstract Pred = Cat [Ant,NP,Utt,IP,IAdv,Conj] ** {
|
||||
abstract Pred = Cat [Ant,NP,Utt,IP,IAdv,Conj,RS,Imp,IComp] ** {
|
||||
|
||||
cat
|
||||
Arg ;
|
||||
@@ -58,18 +58,29 @@ fun
|
||||
QuestSlash : (a : Arg) -> IP -> PrQCl (aNP a) -> PrQCl a ;
|
||||
QuestCl : (a : Arg) -> PrCl a -> PrQCl a ;
|
||||
QuestIAdv : (a : Arg) -> IAdv -> PrCl a -> PrQCl a ;
|
||||
QuestIComp : IComp -> NP -> PrQCl aNone ;
|
||||
|
||||
UseCl : PrCl aNone -> PrS ;
|
||||
UseQCl : PrQCl aNone -> PrS ; -- deprecate QS
|
||||
|
||||
UseAdvCl : PrAdv aNone -> PrCl aNone -> PrS ; -- lift adv to front
|
||||
|
||||
UttS : PrS -> Utt ;
|
||||
UttPrS : PrS -> Utt ;
|
||||
|
||||
AdvCl : (a : Arg) -> PrAdv a -> PrCl aNone -> PrCl a ;
|
||||
|
||||
AdvQCl : (a : Arg) -> PrAdv a -> PrQCl aNone -> PrQCl a ;
|
||||
|
||||
-- relatives
|
||||
RelCl : PrCl aNone -> RS ;
|
||||
RelVP : RP -> PrVP aNone -> RS ;
|
||||
RelSlash : RP -> PrCl (aNP aNone) -> RS ;
|
||||
|
||||
-- imperatives
|
||||
|
||||
ImpVP : PrVP aNone -> Imp ;
|
||||
|
||||
|
||||
-- participles as adjectives
|
||||
|
||||
PresPartAP : (a : Arg) -> PrV a -> PrAP a ;
|
||||
|
||||
@@ -226,7 +226,7 @@ lin
|
||||
|
||||
UseAdvCl adv cl = {s = adv.s ++ declInvCl cl} ;
|
||||
|
||||
UttS s = s ;
|
||||
UttPrS s = s ;
|
||||
|
||||
|
||||
AdvCl x a cl = case a.isAdV of {
|
||||
|
||||
@@ -9,8 +9,8 @@ oper
|
||||
Agr = ResEng.Agr ;
|
||||
Case = ResEng.Case ;
|
||||
NPCase = ResEng.NPCase ;
|
||||
VForm = ResEng.VForm ;
|
||||
VVType = ResEng.VVType ;
|
||||
VForm = ResEng.VForm ; ---- VVForm to get contracted aux verbs
|
||||
VVType = ResEng.VVType ;
|
||||
SVoice = Voice ;
|
||||
|
||||
VAgr = EVAgr ;
|
||||
@@ -146,7 +146,10 @@ oper
|
||||
case <t,a> of {
|
||||
<Pres|Past, Simul> =>
|
||||
case v.vtype of {
|
||||
VTAux => <sta ++ v.s ! vt, [], []> ;
|
||||
VTAux => case t of {
|
||||
Pres => <sta ++ v.s ! VPres, [], []> ; -- can I/she/we
|
||||
_ => <sta ++ v.s ! vt, [], []> -- could ...
|
||||
} ;
|
||||
_ => case p of {
|
||||
Pos => <[], sta ++ v.s ! vt, []> ; -- this is the deviating case
|
||||
Neg => <do_Aux vt Pos, not_Str p, sta ++ v.s ! VInf>
|
||||
|
||||
@@ -109,7 +109,7 @@ oper
|
||||
-- this part is usually the same in all reconfigurations
|
||||
restCl : PrClause -> Str = \cl -> cl.v.p3 ++ cl.adj ++ cl.obj1 ++ cl.obj2 ++ cl.adv ++ cl.ext ++ cl.c3 ;
|
||||
|
||||
negAdV : {s : Str ; p : Polarity} -> Str = \p -> p.s ++ case p.p of {Pos => [] ; Neg => "inte"} ;
|
||||
negAdV : {s : Str ; p : Polarity} -> Str = \p -> p.s ++ case p.p of {Pos => [] ; Neg => inte_Str} ;
|
||||
|
||||
tenseV : Str -> STense -> Anteriority -> Polarity -> SVoice -> VAgr -> PrVerb -> Str * Str * Str = --- Polarity, VAgr not needed in Swe
|
||||
\sta,t,a,_,o,_,v ->
|
||||
@@ -138,7 +138,7 @@ oper
|
||||
|
||||
hava_V : Verb = P.mkV "ha" "har" "ha" "hade" "haft" "havd" ; -- havd not used
|
||||
be_V : Verb = P.mkV "vara" "är" "var" "var" "varit" "varen" ; -- varen not used
|
||||
skola_V : Verb = P.mkV "skola" "ska" "ska" "skulle" "skolat" "skolad" ; ---- not used but ska and skulle
|
||||
skola_V : Verb = P.mkV "skola" ("ska" | "skall") "ska" "skulle" "skolat" "skolad" ; ---- not used but ska and skulle
|
||||
|
||||
noObj : Agr => Str = \\_ => [] ;
|
||||
|
||||
@@ -150,7 +150,9 @@ oper
|
||||
ext = ext ;
|
||||
} ;
|
||||
|
||||
not_Str : Polarity -> Str = \p -> case p of {Pos => [] ; Neg => "inte"} ;
|
||||
not_Str : Polarity -> Str = \p -> case p of {Pos => [] ; Neg => inte_Str} ;
|
||||
|
||||
inte_Str = "inte" | "icke" | "ej" ;
|
||||
|
||||
liftV : Verb -> PrVerb = \v ->
|
||||
{s = v.s ; p = v.part ; c1,c2 = [] ; isSubjectControl = False ; vtype = v.vtype ; vvtype = vvInfinitive} ; ---- vvtype
|
||||
|
||||
@@ -7,10 +7,10 @@ abstract RGLBase =
|
||||
Numeral,
|
||||
Conjunction,
|
||||
Adverb,
|
||||
Phrase - [UttS],
|
||||
Phrase,
|
||||
---- Sentence,
|
||||
---- Question,
|
||||
Relative,
|
||||
Relative - [RelCl,RelVP,RelSlash],
|
||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||
|
||||
Symbol [PN, Symb, String, CN, Card, NP, MkSymb, SymbPN, CNNumNP] ; ---- why only these?
|
||||
|
||||
@@ -7,10 +7,10 @@ concrete RGLBaseEng of RGLBase =
|
||||
NumeralEng,
|
||||
ConjunctionEng,
|
||||
AdverbEng,
|
||||
PhraseEng - [UttS],
|
||||
PhraseEng,
|
||||
---- Sentence,
|
||||
---- Question,
|
||||
RelativeEng,
|
||||
RelativeEng - [RelCl,RelVP,RelSlash],
|
||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||
|
||||
SymbolEng [PN, Symb, String, CN, Card, NP, MkSymb, SymbPN, CNNumNP] ; ---- why only these?
|
||||
|
||||
@@ -7,10 +7,10 @@ concrete RGLBaseFin of RGLBase =
|
||||
NumeralFin,
|
||||
ConjunctionFin,
|
||||
AdverbFin,
|
||||
PhraseFin - [UttS],
|
||||
PhraseFin,
|
||||
---- Sentence,
|
||||
---- Question,
|
||||
RelativeFin,
|
||||
RelativeFin - [RelCl,RelVP,RelSlash],
|
||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||
|
||||
SymbolFin [PN, Symb, String, CN, Card, NP, MkSymb, SymbPN, CNNumNP] ; ---- why only these?
|
||||
|
||||
@@ -7,10 +7,10 @@ concrete RGLBaseSwe of RGLBase =
|
||||
NumeralSwe,
|
||||
ConjunctionSwe,
|
||||
AdverbSwe,
|
||||
PhraseSwe - [UttS],
|
||||
PhraseSwe,
|
||||
---- Sentence,
|
||||
---- Question,
|
||||
RelativeSwe,
|
||||
RelativeSwe - [RelCl,RelVP,RelSlash],
|
||||
---- Idiom [NP, VP, Cl, Tense, ProgrVP, ExistNP, SelfAdvVP, SelfAdVVP, SelfNP], ---- why only these?
|
||||
|
||||
SymbolSwe [PN, Symb, String, CN, Card, NP, MkSymb, SymbPN, CNNumNP] ; ---- why only these?
|
||||
|
||||
Reference in New Issue
Block a user