mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-26 13:02:50 -06:00
rearranging Rules
This commit is contained in:
@@ -5,27 +5,7 @@ incomplete concrete RulesScand of Rules = CategoriesScand **
|
||||
|
||||
lin
|
||||
UseN = noun2CommNounPhrase ;
|
||||
ModAP = modCommNounPhrase ;
|
||||
ModGenOne = npGenDet singular noNum ;
|
||||
ModGenNum = npGenDet plural ;
|
||||
UsePN = nameNounPhrase ;
|
||||
UseN2 = funAsCommNounPhrase ;
|
||||
AppN2 = appFunComm ;
|
||||
AppN3 = appFun2 ;
|
||||
UseA = adj2adjPhrase ;
|
||||
ComplA2 = complAdj ;
|
||||
PositADeg = positAdjPhrase ;
|
||||
ComparADeg = comparAdjPhrase ;
|
||||
SuperlNP = superlNounPhrase ;
|
||||
|
||||
DetNP = detNounPhrase ;
|
||||
IndefOneNP = indefNounPhrase singular ;
|
||||
IndefNumNP = indefNounPhraseNum plural ;
|
||||
DefOneNP = defNounPhrase singular ;
|
||||
DefNumNP = defNounPhraseNum plural ;
|
||||
MassNP = detNounPhrase (mkDeterminerSg (detSgInvar []) IndefP) ;
|
||||
UseInt i = {s = table {Nom => i.s ; Gen => i.s ++ "s"}} ; ---
|
||||
NoNum = noNum ;
|
||||
|
||||
SymbPN i = {s = \\_ => i.s ; g = NNeutr} ;
|
||||
SymbCN cn s =
|
||||
@@ -39,17 +19,70 @@ lin
|
||||
p = cn.p
|
||||
} ;
|
||||
|
||||
IndefOneNP = indefNounPhrase singular ;
|
||||
IndefNumNP = indefNounPhraseNum plural ;
|
||||
DefOneNP = defNounPhrase singular ;
|
||||
DefNumNP = defNounPhraseNum plural ;
|
||||
|
||||
DetNP = detNounPhrase ;
|
||||
MassNP = detNounPhrase (mkDeterminerSg (detSgInvar []) IndefP) ;
|
||||
|
||||
AppN2 = appFunComm ;
|
||||
AppN3 = appFun2 ;
|
||||
UseN2 = funAsCommNounPhrase ;
|
||||
|
||||
ModAP = modCommNounPhrase ;
|
||||
CNthatS = nounThatSentence ;
|
||||
|
||||
PredVV2 = transVerbVerb ;
|
||||
AdjPart = adjPastPart ;
|
||||
ModGenOne = npGenDet singular noNum ;
|
||||
ModGenNum = npGenDet plural ;
|
||||
|
||||
PredV2A = complDitransAdjVerb ;
|
||||
PredSubjV2V = complDitransVerbVerb False ;
|
||||
PredObjV2V = complDitransVerbVerb True ;
|
||||
PredV2S = complDitransSentVerb ;
|
||||
PredV2Q = complDitransQuestVerb ;
|
||||
PredVA = complAdjVerb ;
|
||||
UseInt i = {s = table {Nom => i.s ; Gen => i.s ++ "s"}} ; ---
|
||||
NoNum = noNum ;
|
||||
|
||||
UseA = adj2adjPhrase ;
|
||||
ComplA2 = complAdj ;
|
||||
|
||||
PositADeg = positAdjPhrase ;
|
||||
ComparADeg = comparAdjPhrase ;
|
||||
SuperlNP = superlNounPhrase ;
|
||||
|
||||
-- verbs and verb phrases
|
||||
|
||||
UseV = predVerb ;
|
||||
UsePassV = passVerb ;
|
||||
ComplV2 = complTransVerb ;
|
||||
ComplReflV2 = reflTransVerb ;
|
||||
ComplVS = complSentVerb ;
|
||||
ComplVV = complVerbVerb ;
|
||||
ComplVQ = complQuestVerb ;
|
||||
ComplVA = complAdjVerb ;
|
||||
ComplV2A = complDitransAdjVerb ;
|
||||
ComplSubjV2V = complDitransVerbVerb False ;
|
||||
ComplObjV2V = complDitransVerbVerb True ;
|
||||
ComplV2S = complDitransSentVerb ;
|
||||
ComplV2Q = complDitransQuestVerb ;
|
||||
|
||||
PredAP = predAdjective ;
|
||||
PredSuperl a = predAdjective (superlAdjPhrase a) ;
|
||||
PredCN = predCommNoun ;
|
||||
PredNP = predNounPhrase ;
|
||||
PredPP = predAdverb ;
|
||||
PredAV = complVerbAdj ;
|
||||
PredObjA2V = complVerbAdj2 True ;
|
||||
|
||||
PredAS = predAdjSent ;
|
||||
PredV0 = predVerb0 ;
|
||||
|
||||
-- Partial saturation.
|
||||
|
||||
UseV2 = transAsVerb ;
|
||||
ComplV3 = complDitransVerb ;
|
||||
|
||||
ComplA2S = predAdjSent2 ;
|
||||
|
||||
TransVV2 = transVerbVerb ;
|
||||
AdjPart = adjPastPart ;
|
||||
|
||||
UseV2V x = x ;
|
||||
UseV2S x = x ;
|
||||
@@ -57,60 +90,43 @@ lin
|
||||
UseA2S x = x ;
|
||||
UseA2V x = x ;
|
||||
|
||||
UseCl tp cl = {s = \\o => tp.s ++ cl.s ! tp.b ! ClFinite tp.t tp.a o} ;
|
||||
|
||||
-- Formation of infinitival phrases.
|
||||
|
||||
PosVP tp = predVerbGroup True tp.a ;
|
||||
NegVP tp = predVerbGroup False tp.a ;
|
||||
|
||||
ProgVG = progressiveVerbPhrase ;
|
||||
|
||||
UseCl tp cl = {s = \\o => tp.s ++ cl.s ! tp.b ! ClFinite tp.t tp.a o} ;
|
||||
UseRCl tp cl =
|
||||
{s = \\gn,p => tp.s ++ cl.s ! tp.b ! VFinite tp.t tp.a ! gn ! p} ;
|
||||
UseQCl tp cl = {s = \\q => tp.s ++ cl.s ! tp.b ! VFinite tp.t tp.a ! q} ;
|
||||
|
||||
PosTP t a = {s = t.s ++ a.s ; b = True ; t = t.t ; a = a.a} ;
|
||||
NegTP t a = {s = t.s ++ a.s ; b = False ; t = t.t ; a = a.a} ;
|
||||
|
||||
TPresent = {s = [] ; t = Present} ;
|
||||
TPast = {s = [] ; t = Past} ;
|
||||
TFuture = {s = [] ; t = Future} ;
|
||||
TConditional = {s = [] ; t = Condit} ;
|
||||
|
||||
ASimul = {s = [] ; a = Simul} ;
|
||||
AAnter = {s = [] ; a = Anter} ;
|
||||
|
||||
PredVP = predVerbGroupClause ;
|
||||
|
||||
PredV = predVerb ;
|
||||
PredAP = predAdjective ;
|
||||
PredSuperl a = predAdjective (superlAdjPhrase a) ;
|
||||
PredCN = predCommNoun ;
|
||||
PredV2 = complTransVerb ;
|
||||
PredV3 = complDitransVerb ;
|
||||
PredPassV = passVerb ;
|
||||
ReflV2 = reflTransVerb ;
|
||||
|
||||
PredNP = predNounPhrase ;
|
||||
PredPP = predAdverb ;
|
||||
PredVS = complSentVerb ;
|
||||
PredVQ = complQuestVerb ;
|
||||
PredVV = complVerbVerb ;
|
||||
VTrans = transAsVerb ;
|
||||
PredV0 = predVerb0 ;
|
||||
|
||||
PredAS = predAdjSent ;
|
||||
PredA2S = predAdjSent2 ;
|
||||
PredAV = complVerbAdj ;
|
||||
PredSubjA2V = complVerbAdj2 False ;
|
||||
PredObjA2V = complVerbAdj2 True ;
|
||||
-- Adverbs.
|
||||
|
||||
AdjAdv a = advPost (a.s ! adverbForm ! Nom) ;
|
||||
AdvPP p = p ;
|
||||
PrepNP p = prepPhrase p.s ; ---
|
||||
|
||||
AdvVP = adVerbPhrase ;
|
||||
AdvCN = advCommNounPhrase ;
|
||||
AdvAP = advAdjPhrase ;
|
||||
|
||||
ExistCN A = predVerbGroupClause npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhrase singular A)) ;
|
||||
ExistNumCN nu A = predVerbGroupClause npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhraseNum plural nu A)) ;
|
||||
--3 Sentences and relative clauses
|
||||
--
|
||||
|
||||
PredVP = predVerbGroupClause ;
|
||||
|
||||
SlashV2 = slashTransVerb ;
|
||||
OneVP = predVerbGroupClause npMan ;
|
||||
@@ -122,8 +138,10 @@ lin
|
||||
ModRS = modRelClause ;
|
||||
RelCl = relSuch ;
|
||||
|
||||
UseRCl tp cl =
|
||||
{s = \\gn,p => tp.s ++ cl.s ! tp.b ! VFinite tp.t tp.a ! gn ! p} ;
|
||||
|
||||
--!
|
||||
--3 Questions and imperatives
|
||||
--
|
||||
|
||||
WhoOne = intPronWho singular ;
|
||||
WhoMany = intPronWho plural ;
|
||||
@@ -138,16 +156,6 @@ lin
|
||||
IntSlash = intSlash ;
|
||||
QuestAdv = questAdverbial ;
|
||||
|
||||
ExistQCl A = questVerbPhrase npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhrase singular A)) ;
|
||||
ExistNumQCl nu A = questVerbPhrase npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhraseNum plural nu A)) ;
|
||||
|
||||
|
||||
UseQCl tp cl = {s = \\q => tp.s ++ cl.s ! tp.b ! VFinite tp.t tp.a ! q} ;
|
||||
|
||||
PosImperVP = imperVerbPhrase True ;
|
||||
NegImperVP = imperVerbPhrase False ;
|
||||
|
||||
@@ -159,6 +167,11 @@ lin
|
||||
PrepS p = ss (p.s ++ ",") ;
|
||||
AdvS = advSentence ;
|
||||
|
||||
|
||||
--!
|
||||
--3 Coordination
|
||||
--
|
||||
|
||||
TwoS = twoSentence ;
|
||||
ConsS = consSentence ;
|
||||
ConjS = conjunctSentence ;
|
||||
@@ -188,4 +201,24 @@ lin
|
||||
OnePhr p = p ;
|
||||
ConsPhr = cc2 ;
|
||||
|
||||
-----------------------
|
||||
-- special constructions
|
||||
|
||||
OneVP = predVerbGroupClause npMan ;
|
||||
|
||||
ExistCN A = predVerbGroupClause npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhrase singular A)) ;
|
||||
ExistNumCN nu A = predVerbGroupClause npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhraseNum plural nu A)) ;
|
||||
|
||||
ExistQCl A = questVerbPhrase npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhrase singular A)) ;
|
||||
ExistNumQCl nu A = questVerbPhrase npDet
|
||||
(complTransVerb (mkDirectVerb (deponentVerb verbFinnas))
|
||||
(indefNounPhraseNum plural nu A)) ;
|
||||
|
||||
|
||||
} ;
|
||||
|
||||
Reference in New Issue
Block a user