mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-26 19:28:54 -06:00
Changed some function names, added derived libraries.
This commit is contained in:
@@ -172,11 +172,11 @@ fun
|
|||||||
DetNP : Det -> CN -> NP ; -- "every car"
|
DetNP : Det -> CN -> NP ; -- "every car"
|
||||||
MassNP : CN -> NP ; -- "wine"
|
MassNP : CN -> NP ; -- "wine"
|
||||||
IndefOneNP : CN -> NP ; -- "a car", "cars"
|
IndefOneNP : CN -> NP ; -- "a car", "cars"
|
||||||
IndefManyNP : Num -> CN -> NP ; -- "houses", "86 houses"
|
IndefNumNP : Num -> CN -> NP ; -- "houses", "86 houses"
|
||||||
DefOneNP : CN -> NP ; -- "the car"
|
DefOneNP : CN -> NP ; -- "the car"
|
||||||
DefManyNP : Num -> CN -> NP ; -- "the cars", "the 86 cars"
|
DefNumNP : Num -> CN -> NP ; -- "the cars", "the 86 cars"
|
||||||
ModGenOne : NP -> CN -> NP ; -- "John's car"
|
ModGenOne : NP -> CN -> NP ; -- "John's car"
|
||||||
ModGenMany : Num -> NP -> CN -> NP ; -- "John's cars", "John's 86 cars"
|
ModGenNum : Num -> NP -> CN -> NP ; -- "John's cars", "John's 86 cars"
|
||||||
AppFun : Fun -> NP -> CN ; -- "successor of zero"
|
AppFun : Fun -> NP -> CN ; -- "successor of zero"
|
||||||
AppFun2 : Fun2 -> NP -> Fun ; -- "flight from Paris"
|
AppFun2 : Fun2 -> NP -> Fun ; -- "flight from Paris"
|
||||||
CNthatS : CN -> S -> CN ; -- "idea that the Earth is flat"
|
CNthatS : CN -> S -> CN ; -- "idea that the Earth is flat"
|
||||||
|
|||||||
82
lib/resource-0.6/abstract/Predication.gf
Normal file
82
lib/resource-0.6/abstract/Predication.gf
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
|
||||||
|
--1 A Small Predication Library
|
||||||
|
--
|
||||||
|
-- (c) Aarne Ranta 2003 under Gnu GPL.
|
||||||
|
--
|
||||||
|
-- This library is built on a language-independent API of
|
||||||
|
-- resource grammars. It has a common part, the type signatures
|
||||||
|
-- (defined here), and language-dependent parts. The user of
|
||||||
|
-- the library should only have to look at the type signatures.
|
||||||
|
|
||||||
|
incomplete resource Predication = open Resource, ResourceExt in {
|
||||||
|
|
||||||
|
-- We first define a set of predication patterns.
|
||||||
|
|
||||||
|
oper
|
||||||
|
predV1 : V -> NP -> S ; -- one-place verb: "John walks"
|
||||||
|
predV2 : TV -> NP -> NP -> S ; -- two-place verb: "John loves Mary"
|
||||||
|
predVColl : V -> NP -> NP -> S ; -- collective verb: "John and Mary fight"
|
||||||
|
predA1 : Adj1 -> NP -> S ; -- one-place adjective: "John is old"
|
||||||
|
predA2 : Adj2 -> NP -> NP -> S ; -- two-place adj: "John is married to Mary"
|
||||||
|
predAComp : AdjDeg -> NP -> NP -> S ; -- compar adj: "John is older than Mary"
|
||||||
|
predAColl : Adj1 -> NP -> NP -> S ; -- collective adj: "John and Mary are married"
|
||||||
|
predN1 : N -> NP -> S ; -- one-place noun: "John is a man"
|
||||||
|
predN2 : Fun -> NP -> NP -> S ; -- two-place noun: "John is a lover of Mary"
|
||||||
|
predNColl : N -> NP -> NP -> S ; -- collective noun: "John and Mary are lovers"
|
||||||
|
|
||||||
|
-- Individual-valued function applications.
|
||||||
|
|
||||||
|
appFun1 : Fun -> NP -> NP ; -- one-place function: "the successor of x"
|
||||||
|
appFunColl : Fun -> NP -> NP -> NP ; -- collective function: "the sum of x and y"
|
||||||
|
|
||||||
|
-- Families of types, expressed by common nouns depending on arguments.
|
||||||
|
|
||||||
|
appFam1 : Fun -> NP -> CN ; -- one-place family: "divisor of x"
|
||||||
|
appFamColl : Fun -> NP -> NP -> CN ; -- collective family: "path between x and y"
|
||||||
|
|
||||||
|
-- Type constructor, similar to a family except that the argument is a type.
|
||||||
|
|
||||||
|
constrTyp1 : Fun -> CN -> CN ;
|
||||||
|
|
||||||
|
-- Logical connectives on two sentences.
|
||||||
|
|
||||||
|
conjS : S -> S -> S ;
|
||||||
|
disjS : S -> S -> S ;
|
||||||
|
implS : S -> S -> S ;
|
||||||
|
|
||||||
|
-- As an auxiliary, we need two-place conjunction of names ("John and Mary"),
|
||||||
|
-- used in collective predication.
|
||||||
|
|
||||||
|
conjNP : NP -> NP -> NP ;
|
||||||
|
|
||||||
|
-----------------------------
|
||||||
|
|
||||||
|
---- what follows should be an implementation of the preceding
|
||||||
|
|
||||||
|
oper
|
||||||
|
predV1 = \F, x -> PredVP x (PosV F) ;
|
||||||
|
predV2 = \F, x, y -> PredVP x (PosTV F y) ;
|
||||||
|
predVColl = \F, x, y -> PredVP (conjNP x y) (PosV F) ;
|
||||||
|
predA1 = \F, x -> PredVP x (PosA (AdjP1 F)) ;
|
||||||
|
predA2 = \F, x, y -> PredVP x (PosA (ComplAdj F y)) ;
|
||||||
|
predAComp = \F, x, y -> PredVP x (PosA (ComparAdjP F y)) ;
|
||||||
|
predAColl = \F, x, y -> PredVP (conjNP x y) (PosA (AdjP1 F)) ;
|
||||||
|
predN1 = \F, x -> PredVP x (PosCN (UseN F)) ;
|
||||||
|
predN2 = \F, x, y -> PredVP x (PosCN (AppFun F y)) ;
|
||||||
|
predNColl = \F, x, y -> PredVP (conjNP x y) (PosCN (UseN F)) ;
|
||||||
|
|
||||||
|
appFun1 = \f, x -> DefOneNP (AppFun f x) ;
|
||||||
|
appFunColl = \f, x, y -> DefOneNP (AppFun f (conjNP x y)) ;
|
||||||
|
|
||||||
|
appFam1 = \F, x -> AppFun F x ;
|
||||||
|
appFamColl = \F, x, y -> AppFun F (conjNP x y) ;
|
||||||
|
|
||||||
|
conjS = \A, B -> ConjS AndConj (TwoS A B) ;
|
||||||
|
disjS = \A, B -> ConjS OrConj (TwoS A B) ;
|
||||||
|
implS = \A, B -> SubjS IfSubj A B ;
|
||||||
|
|
||||||
|
constrTyp1 = \F, A -> AppFun F (IndefManyNP A) ;
|
||||||
|
|
||||||
|
conjNP = \x, y -> ConjNP AndConj (TwoNP x y) ;
|
||||||
|
|
||||||
|
} ;
|
||||||
36
lib/resource-0.6/abstract/ResourceExt.gf
Normal file
36
lib/resource-0.6/abstract/ResourceExt.gf
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
incomplete resource ResourceExt = open Resource in {
|
||||||
|
|
||||||
|
-- Mostly for compatibility with old API (v 0.4). Also for
|
||||||
|
-- special cases of plural determiners without numerals.
|
||||||
|
-- AR 12/1/2004
|
||||||
|
|
||||||
|
oper
|
||||||
|
|
||||||
|
PosV : V -> VP = \x -> PosVG (PredV x) ;
|
||||||
|
NegV : V -> VP = \x -> NegVG (PredV x) ;
|
||||||
|
PosTV : TV -> NP -> VP = \x,y -> PosVG (PredTV x y) ;
|
||||||
|
NegTV : TV -> NP -> VP = \x,y -> NegVG (PredTV x y) ;
|
||||||
|
PosA : AP -> VP = \x -> PosVG (PredAP x) ;
|
||||||
|
NegA : AP -> VP = \x -> NegVG (PredAP x) ;
|
||||||
|
PosCN : CN -> VP = \x -> PosVG (PredCN x) ;
|
||||||
|
NegCN : CN -> VP = \x -> NegVG (PredCN x) ;
|
||||||
|
|
||||||
|
IndefManyNP : CN -> NP = IndefNumNP NoNum ;
|
||||||
|
DefManyNP : CN -> NP = DefNumNP NoNum ;
|
||||||
|
ModGenMany : NP -> CN -> NP = ModGenNum NoNum ;
|
||||||
|
|
||||||
|
WeNP : NP = WeNumNP NoNum ;
|
||||||
|
YeNP : NP = YeNumNP NoNum ;
|
||||||
|
|
||||||
|
TheseNP : NP = TheseNumNP NoNum ;
|
||||||
|
ThoseNP : NP = ThoseNumNP NoNum ;
|
||||||
|
|
||||||
|
AllDet : Det = AllNumDet NoNum ;
|
||||||
|
WhichsDet : Det = WhichNumDet NoNum ;
|
||||||
|
SomesDet : Det = SomeNumDet NoNum ;
|
||||||
|
AnysDet : Det = AnyNumDet NoNum ;
|
||||||
|
NosDet : Det = NoNumDet NoNum ;
|
||||||
|
TheseDet : Det = TheseNumDet NoNum ;
|
||||||
|
ThoseDet : Det = ThoseNumDet NoNum ;
|
||||||
|
|
||||||
|
} ;
|
||||||
@@ -17,19 +17,19 @@ fun
|
|||||||
-- Many plural determiners can take a numeral modifier. So can the plural
|
-- Many plural determiners can take a numeral modifier. So can the plural
|
||||||
-- pronouns "we" and "you".
|
-- pronouns "we" and "you".
|
||||||
|
|
||||||
EveryDet, WhichDet, AllDet, -- every, sg which, sg all
|
EveryDet, WhichDet, AllMassDet, -- every, sg which, sg all
|
||||||
SomeDet, AnyDet, NoDet, -- sg some, any, no
|
SomeDet, AnyDet, NoDet, -- sg some, any, no
|
||||||
MostDet, MostsDet, ManyDet, MuchDet : Det ; -- sg most, pl most, many, much
|
MostDet, MostsDet, ManyDet, MuchDet : Det ; -- sg most, pl most, many, much
|
||||||
ThisDet, ThatDet : Det ; -- this, that
|
ThisDet, ThatDet : Det ; -- this, that
|
||||||
|
|
||||||
AllsDet, WhichsDet, -- pl all, which (86)
|
AllNumDet, WhichNumDet, -- pl all, which (86)
|
||||||
SomesDet, AnysDet, NosDet, -- pl some, any, no
|
SomeNumDet, AnyNumDet, NoNumDet, -- pl some, any, no
|
||||||
TheseDet, ThoseDet : Num -> Det ; -- these, those (86)
|
TheseNumDet, ThoseNumDet : Num -> Det ; -- these, those (86)
|
||||||
|
|
||||||
ThisNP, ThatNP : NP ; -- this, that
|
ThisNP, ThatNP : NP ; -- this, that
|
||||||
TheseNP, ThoseNP : Num -> NP ; -- these, those (86)
|
TheseNumNP, ThoseNumNP : Num -> NP ; -- these, those (86)
|
||||||
INP, ThouNP, HeNP, SheNP, ItNP : NP ; -- personal pronouns in singular
|
INP, ThouNP, HeNP, SheNP, ItNP : NP ; -- personal pronouns in singular
|
||||||
WeNP, YeNP : Num -> NP ; -- these pronouns can take numeral
|
WeNumNP, YeNumNP : Num -> NP ; -- these pronouns can take numeral
|
||||||
TheyNP : NP ; YouNP : NP ; -- they, the polite you
|
TheyNP : NP ; YouNP : NP ; -- they, the polite you
|
||||||
|
|
||||||
EverybodyNP, SomebodyNP, NobodyNP, -- everybody, somebody, nobody
|
EverybodyNP, SomebodyNP, NobodyNP, -- everybody, somebody, nobody
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ lin
|
|||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModAdj = modCommNounPhrase ;
|
ModAdj = modCommNounPhrase ;
|
||||||
ModGenOne = npGenDet singular noNum ;
|
ModGenOne = npGenDet singular noNum ;
|
||||||
ModGenMany = npGenDet plural ;
|
ModGenNum = npGenDet plural ;
|
||||||
UsePN = nameNounPhrase ;
|
UsePN = nameNounPhrase ;
|
||||||
UseFun = funAsCommNounPhrase ;
|
UseFun = funAsCommNounPhrase ;
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
@@ -95,9 +95,9 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase singular ;
|
IndefOneNP = indefNounPhrase singular ;
|
||||||
IndefManyNP = indefNounPhraseNum plural ;
|
IndefNumNP = indefNounPhraseNum plural ;
|
||||||
DefOneNP = defNounPhrase singular ;
|
DefOneNP = defNounPhrase singular ;
|
||||||
DefManyNP = defNounPhraseNum plural ;
|
DefNumNP = defNounPhraseNum plural ;
|
||||||
MassNP = detNounPhrase (mkDeterminer Sg []) ;
|
MassNP = detNounPhrase (mkDeterminer Sg []) ;
|
||||||
|
|
||||||
CNthatS = nounThatSentence ;
|
CNthatS = nounThatSentence ;
|
||||||
|
|||||||
6
lib/resource-0.6/english/PredicationEng.gf
Normal file
6
lib/resource-0.6/english/PredicationEng.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource PredicationEng = Predication with
|
||||||
|
(Resource = ResourceEng), (ResourceExt = ResourceExtEng) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/english/ResourceExtEng.gf
Normal file
4
lib/resource-0.6/english/ResourceExtEng.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtEng = ResourceExt with (Resource = ResourceEng) ;
|
||||||
|
|
||||||
@@ -12,35 +12,35 @@ concrete StructuralEng of Structural =
|
|||||||
HeNP = pronHe ;
|
HeNP = pronHe ;
|
||||||
SheNP = pronShe ;
|
SheNP = pronShe ;
|
||||||
ItNP = pronIt ;
|
ItNP = pronIt ;
|
||||||
WeNP = pronWithNum pronWe ;
|
WeNumNP = pronWithNum pronWe ;
|
||||||
YeNP = pronWithNum pronYouPl ;
|
YeNumNP = pronWithNum pronYouPl ;
|
||||||
YouNP = pronYouSg ;
|
YouNP = pronYouSg ;
|
||||||
TheyNP = pronThey ;
|
TheyNP = pronThey ;
|
||||||
|
|
||||||
EveryDet = everyDet ;
|
EveryDet = everyDet ;
|
||||||
AllDet = mkDeterminer Sg "all" ; --- all the missing
|
AllMassDet = mkDeterminer Sg "all" ; --- all the missing
|
||||||
AllsDet = mkDeterminerNum Pl "all" ;
|
AllNumDet = mkDeterminerNum Pl "all" ;
|
||||||
WhichDet = whichDet ;
|
WhichDet = whichDet ;
|
||||||
WhichsDet = mkDeterminerNum Pl "which" ;
|
WhichNumDet = mkDeterminerNum Pl "which" ;
|
||||||
MostsDet = mostDet ;
|
MostsDet = mostDet ;
|
||||||
MostDet = mkDeterminer Sg "most" ;
|
MostDet = mkDeterminer Sg "most" ;
|
||||||
SomeDet = mkDeterminer Sg "some" ;
|
SomeDet = mkDeterminer Sg "some" ;
|
||||||
SomesDet = mkDeterminerNum Pl "some" ;
|
SomeNumDet = mkDeterminerNum Pl "some" ;
|
||||||
AnyDet = mkDeterminer Sg "any" ;
|
AnyDet = mkDeterminer Sg "any" ;
|
||||||
AnysDet = mkDeterminerNum Pl "any" ;
|
AnyNumDet = mkDeterminerNum Pl "any" ;
|
||||||
NoDet = mkDeterminer Sg "no" ;
|
NoDet = mkDeterminer Sg "no" ;
|
||||||
NosDet = mkDeterminerNum Pl "no" ;
|
NoNumDet = mkDeterminerNum Pl "no" ;
|
||||||
ManyDet = mkDeterminer Pl "many" ;
|
ManyDet = mkDeterminer Pl "many" ;
|
||||||
MuchDet = mkDeterminer Sg ["a lot of"] ; ---
|
MuchDet = mkDeterminer Sg ["a lot of"] ; ---
|
||||||
ThisDet = mkDeterminer Sg "this" ;
|
ThisDet = mkDeterminer Sg "this" ;
|
||||||
TheseDet = mkDeterminerNum Pl "these" ;
|
TheseNumDet = mkDeterminerNum Pl "these" ;
|
||||||
ThatDet = mkDeterminer Sg "that" ;
|
ThatDet = mkDeterminer Sg "that" ;
|
||||||
ThoseDet = mkDeterminerNum Pl "those" ;
|
ThoseNumDet = mkDeterminerNum Pl "those" ;
|
||||||
|
|
||||||
ThisNP = nameNounPhrase (nameReg "this") ;
|
ThisNP = nameNounPhrase (nameReg "this") ;
|
||||||
ThatNP = nameNounPhrase (nameReg "that") ;
|
ThatNP = nameNounPhrase (nameReg "that") ;
|
||||||
TheseNP n = nameNounPhrase {s = \\c => "these" ++ n.s ! c} ; --- Pl; Gen!
|
TheseNumNP n = nameNounPhrase {s = \\c => "these" ++ n.s ! c} ; --- Pl; Gen!
|
||||||
ThoseNP n = nameNounPhrase {s = \\c => "those" ++ n.s ! c} ; --- Pl; Gen!
|
ThoseNumNP n = nameNounPhrase {s = \\c => "those" ++ n.s ! c} ; --- Pl; Gen!
|
||||||
|
|
||||||
EverybodyNP = nameNounPhrase (nameReg "everybody") ;
|
EverybodyNP = nameNounPhrase (nameReg "everybody") ;
|
||||||
SomebodyNP = nameNounPhrase (nameReg "somebody") ;
|
SomebodyNP = nameNounPhrase (nameReg "somebody") ;
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ lin
|
|||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModAdj = modCommNounPhrase ;
|
ModAdj = modCommNounPhrase ;
|
||||||
ModGenOne = npGenDet singular ;
|
ModGenOne = npGenDet singular ;
|
||||||
ModGenMany = npGenDetNum ;
|
ModGenNum = npGenDetNum ;
|
||||||
UsePN = nameNounPhrase ;
|
UsePN = nameNounPhrase ;
|
||||||
UseFun = funAsCommNounPhrase ;
|
UseFun = funAsCommNounPhrase ;
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
@@ -94,9 +94,9 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase singular ;
|
IndefOneNP = indefNounPhrase singular ;
|
||||||
IndefManyNP = nounPhraseNum False ;
|
IndefNumNP = nounPhraseNum False ;
|
||||||
DefOneNP = defNounPhrase singular ;
|
DefOneNP = defNounPhrase singular ;
|
||||||
DefManyNP = nounPhraseNum True ;
|
DefNumNP = nounPhraseNum True ;
|
||||||
MassNP = partNounPhrase singular ;
|
MassNP = partNounPhrase singular ;
|
||||||
NoNum = noNum ;
|
NoNum = noNum ;
|
||||||
UseInt i = {s = \\_ => i.s ; isNum = True} ; --- case endings sometimes needed
|
UseInt i = {s = \\_ => i.s ; isNum = True} ; --- case endings sometimes needed
|
||||||
|
|||||||
6
lib/resource-0.6/finnish/PredicationFin.gf
Normal file
6
lib/resource-0.6/finnish/PredicationFin.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource PredicationFin = Predication with
|
||||||
|
(Resource = ResourceFin), (ResourceExt = ResourceExtFin) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/finnish/ResourceExtFin.gf
Normal file
4
lib/resource-0.6/finnish/ResourceExtFin.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtFin = ResourceExt with (Resource = ResourceFin) ;
|
||||||
|
|
||||||
@@ -12,16 +12,16 @@ concrete StructuralFin of Structural =
|
|||||||
ThouNP = pronNounPhrase pronSina ;
|
ThouNP = pronNounPhrase pronSina ;
|
||||||
HeNP = pronNounPhrase pronHan ;
|
HeNP = pronNounPhrase pronHan ;
|
||||||
SheNP = pronNounPhrase pronHan ;
|
SheNP = pronNounPhrase pronHan ;
|
||||||
WeNP = pronWithNum pronMe ;
|
WeNumNP = pronWithNum pronMe ;
|
||||||
YeNP = pronWithNum pronTe ;
|
YeNumNP = pronWithNum pronTe ;
|
||||||
YouNP = pronNounPhrase pronTe ;
|
YouNP = pronNounPhrase pronTe ;
|
||||||
TheyNP = pronNounPhrase pronHe ; --- ne
|
TheyNP = pronNounPhrase pronHe ; --- ne
|
||||||
|
|
||||||
ItNP = nameNounPhrase pronSe ;
|
ItNP = nameNounPhrase pronSe ;
|
||||||
ThisNP = pronNounPhraseNP pronTama ;
|
ThisNP = pronNounPhraseNP pronTama ;
|
||||||
ThatNP = pronNounPhraseNP pronTuo ;
|
ThatNP = pronNounPhraseNP pronTuo ;
|
||||||
TheseNP = pronWithNum pronNama ;
|
TheseNumNP = pronWithNum pronNama ;
|
||||||
ThoseNP = pronWithNum pronNuo ;
|
ThoseNumNP = pronWithNum pronNuo ;
|
||||||
|
|
||||||
EverybodyNP = {
|
EverybodyNP = {
|
||||||
s = \\f => kaikkiPron Pl ! (npForm2Case Pl f) ; -- näin kaikki
|
s = \\f => kaikkiPron Pl ! (npForm2Case Pl f) ; -- näin kaikki
|
||||||
@@ -60,10 +60,10 @@ concrete StructuralFin of Structural =
|
|||||||
} ;
|
} ;
|
||||||
|
|
||||||
EveryDet = jokainenDet ;
|
EveryDet = jokainenDet ;
|
||||||
AllDet = mkDeterminer singular (kaikkiPron Sg) ;
|
AllMassDet = mkDeterminer singular (kaikkiPron Sg) ;
|
||||||
AllsDet = kaikkiDet ;
|
AllNumDet = kaikkiDet ;
|
||||||
WhichDet = mikaDet ;
|
WhichDet = mikaDet ;
|
||||||
WhichsDet n = mkDeterminerGenNum n (mikaInt ! Pl) (kukaInt ! Pl) ;
|
WhichNumDet n = mkDeterminerGenNum n (mikaInt ! Pl) (kukaInt ! Pl) ;
|
||||||
MostDet = mkDeterminer singular (caseTable singular (sSuurin "enintä")) ;
|
MostDet = mkDeterminer singular (caseTable singular (sSuurin "enintä")) ;
|
||||||
MostsDet = useimmatDet ;
|
MostsDet = useimmatDet ;
|
||||||
ManyDet = mkDeterminer singular moniPron ;
|
ManyDet = mkDeterminer singular moniPron ;
|
||||||
@@ -73,24 +73,21 @@ concrete StructuralFin of Structural =
|
|||||||
--- with a verb.
|
--- with a verb.
|
||||||
|
|
||||||
AnyDet = mkDeterminerGen Sg (mikaanPron ! Sg) (kukaanPron ! Sg) ;
|
AnyDet = mkDeterminerGen Sg (mikaanPron ! Sg) (kukaanPron ! Sg) ;
|
||||||
AnysDet n = mkDeterminerGenNum n (mikaanPron ! Pl) (kukaanPron ! Pl) ;
|
AnyNumDet n = mkDeterminerGenNum n (mikaanPron ! Pl) (kukaanPron ! Pl) ;
|
||||||
NoDet = mkDeterminerGen Sg
|
NoDet = mkDeterminerGen Sg
|
||||||
(\\c => "ei" ++ mikaanPron ! Sg ! c)
|
(\\c => "ei" ++ mikaanPron ! Sg ! c)
|
||||||
(\\c => "ei" ++ kukaanPron ! Sg ! c) ;
|
(\\c => "ei" ++ kukaanPron ! Sg ! c) ;
|
||||||
NosDet n = mkDeterminerGenNum n
|
NoNumDet n = mkDeterminerGenNum n
|
||||||
(\\c => "ei" ++ mikaanPron ! Pl ! c)
|
(\\c => "ei" ++ mikaanPron ! Pl ! c)
|
||||||
(\\c => "ei" ++ kukaanPron ! Pl ! c) ;
|
(\\c => "ei" ++ kukaanPron ! Pl ! c) ;
|
||||||
|
|
||||||
ThisDet = mkDeterminer Sg (\\c => pronTama.s ! PCase c) ;
|
ThisDet = mkDeterminer Sg (\\c => pronTama.s ! PCase c) ;
|
||||||
ThatDet = mkDeterminer Sg (\\c => pronTuo.s ! PCase c) ;
|
ThatDet = mkDeterminer Sg (\\c => pronTuo.s ! PCase c) ;
|
||||||
TheseDet n = mkDeterminerNum n (\\c => pronNama.s ! PCase c) ;
|
TheseNumDet n = mkDeterminerNum n (\\c => pronNama.s ! PCase c) ;
|
||||||
ThoseDet n = mkDeterminerNum n (\\c => pronNuo.s ! PCase c) ;
|
ThoseNumDet n = mkDeterminerNum n (\\c => pronNuo.s ! PCase c) ;
|
||||||
|
|
||||||
SomeDet = mkDeterminerGen Sg (jokinPron ! Sg) (jokuPron ! Sg) ;
|
SomeDet = mkDeterminerGen Sg (jokinPron ! Sg) (jokuPron ! Sg) ;
|
||||||
SomesDet n = mkDeterminerGenNum n (jokinPron ! Pl) (jokuPron ! Pl) ;
|
SomeNumDet n = mkDeterminerGenNum n (jokinPron ! Pl) (jokuPron ! Pl) ;
|
||||||
|
|
||||||
--- These two don't work in Finnish sentences.
|
|
||||||
|
|
||||||
|
|
||||||
HowIAdv = ss "kuinka" ;
|
HowIAdv = ss "kuinka" ;
|
||||||
WhenIAdv = ss "koska" ;
|
WhenIAdv = ss "koska" ;
|
||||||
|
|||||||
6
lib/resource-0.6/french/PredicationFre.gf
Normal file
6
lib/resource-0.6/french/PredicationFre.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../romance:../../prelude
|
||||||
|
|
||||||
|
resource PredicationFre = Predication with
|
||||||
|
(Resource = ResourceFre), (ResourceExt = ResourceExtFre) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/french/ResourceExtFre.gf
Normal file
4
lib/resource-0.6/french/ResourceExtFre.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../romance:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtFre = ResourceExt with (Resource = ResourceFre) ;
|
||||||
|
|
||||||
@@ -8,8 +8,8 @@ lin
|
|||||||
ThouNP = pronNounPhrase pronTu ;
|
ThouNP = pronNounPhrase pronTu ;
|
||||||
HeNP = pronNounPhrase pronIl ;
|
HeNP = pronNounPhrase pronIl ;
|
||||||
SheNP = pronNounPhrase pronElle ;
|
SheNP = pronNounPhrase pronElle ;
|
||||||
WeNP n = pronNounPhrase (pronWithNum pronNous n) ;
|
WeNumNP n = pronNounPhrase (pronWithNum pronNous n) ;
|
||||||
YeNP n = pronNounPhrase (pronWithNum pronVous n) ;
|
YeNumNP n = pronNounPhrase (pronWithNum pronVous n) ;
|
||||||
YouNP = pronNounPhrase pronVous ;
|
YouNP = pronNounPhrase pronVous ;
|
||||||
TheyNP = pronNounPhrase pronIls ;
|
TheyNP = pronNounPhrase pronIls ;
|
||||||
|
|
||||||
@@ -21,30 +21,30 @@ lin
|
|||||||
|
|
||||||
ThisNP = mkNameNounPhrase ["ceci"] Masc ;
|
ThisNP = mkNameNounPhrase ["ceci"] Masc ;
|
||||||
ThatNP = mkNameNounPhrase ["ça"] Masc ;
|
ThatNP = mkNameNounPhrase ["ça"] Masc ;
|
||||||
TheseNP n = mkNameNounPhrase ("ceux" ++ n.s ! Masc ++ "ci") Masc ;
|
TheseNumNP n = mkNameNounPhrase ("ceux" ++ n.s ! Masc ++ "ci") Masc ;
|
||||||
ThoseNP n = mkNameNounPhrase ("ceux" ++ n.s ! Masc ++ "là") Masc ;
|
ThoseNumNP n = mkNameNounPhrase ("ceux" ++ n.s ! Masc ++ "là") Masc ;
|
||||||
|
|
||||||
ItNP = pronNounPhrase pronIl ;
|
ItNP = pronNounPhrase pronIl ;
|
||||||
|
|
||||||
EveryDet = chaqueDet ;
|
EveryDet = chaqueDet ;
|
||||||
AllDet = toutDet ;
|
AllMassDet = toutDet ;
|
||||||
AllsDet = tousDet ;
|
AllNumDet = tousDet ;
|
||||||
WhichDet = quelDet ;
|
WhichDet = quelDet ;
|
||||||
WhichsDet = mkDeterminerNum plural "quels" "quelles" ;
|
WhichNumDet = mkDeterminerNum plural "quels" "quelles" ;
|
||||||
MostsDet = plupartDet ;
|
MostsDet = plupartDet ;
|
||||||
MostDet = mkDeterminer1 singular (["la plupart"] ++ elisDe) ; --- de
|
MostDet = mkDeterminer1 singular (["la plupart"] ++ elisDe) ; --- de
|
||||||
SomeDet = mkDeterminer1 singular "quelque" ;
|
SomeDet = mkDeterminer1 singular "quelque" ;
|
||||||
SomesDet = mkDeterminerNum plural "quelques" "quelques" ;
|
SomeNumDet = mkDeterminerNum plural "quelques" "quelques" ;
|
||||||
NoDet = mkDeterminer singular "aucun" "aucune" ; --- ne
|
NoDet = mkDeterminer singular "aucun" "aucune" ; --- ne
|
||||||
NosDet = mkDeterminerNum plural ("aucun" ++ "des") ("aucune" ++ "des") ; --- ne
|
NoNumDet = mkDeterminerNum plural ("aucun" ++ "des") ("aucune" ++ "des") ; --- ne
|
||||||
AnyDet = mkDeterminer1 singular "quelque" ; ---
|
AnyDet = mkDeterminer1 singular "quelque" ; ---
|
||||||
AnysDet = mkDeterminerNum plural "quelques" "quelques" ; ---
|
AnyNumDet = mkDeterminerNum plural "quelques" "quelques" ; ---
|
||||||
ManyDet = mkDeterminer1 plural "plusieurs" ;
|
ManyDet = mkDeterminer1 plural "plusieurs" ;
|
||||||
MuchDet = mkDeterminer1 singular ("beaucoup" ++ elisDe) ; --- de
|
MuchDet = mkDeterminer1 singular ("beaucoup" ++ elisDe) ; --- de
|
||||||
ThisDet = mkDeterminer singular (pre {"ce" ; "cet" / voyelle}) "cette" ; --- ci
|
ThisDet = mkDeterminer singular (pre {"ce" ; "cet" / voyelle}) "cette" ; --- ci
|
||||||
ThatDet = mkDeterminer singular (pre {"ce" ; "cet" / voyelle}) "cette" ; --- là
|
ThatDet = mkDeterminer singular (pre {"ce" ; "cet" / voyelle}) "cette" ; --- là
|
||||||
TheseDet = mkDeterminerNum plural "ces" "ces" ; --- ci
|
TheseNumDet = mkDeterminerNum plural "ces" "ces" ; --- ci
|
||||||
ThoseDet = mkDeterminerNum plural "ces" "ces" ; --- là
|
ThoseNumDet = mkDeterminerNum plural "ces" "ces" ; --- là
|
||||||
|
|
||||||
HowIAdv = commentAdv ;
|
HowIAdv = commentAdv ;
|
||||||
WhenIAdv = quandAdv ;
|
WhenIAdv = quandAdv ;
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ lin
|
|||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModAdj = modCommNounPhrase ;
|
ModAdj = modCommNounPhrase ;
|
||||||
ModGenOne = npGenDet singular noNum ;
|
ModGenOne = npGenDet singular noNum ;
|
||||||
ModGenMany = npGenDet plural ;
|
ModGenNum = npGenDet plural ;
|
||||||
UsePN = nameNounPhrase ;
|
UsePN = nameNounPhrase ;
|
||||||
UseFun = funAsCommNounPhrase ;
|
UseFun = funAsCommNounPhrase ;
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
@@ -97,9 +97,9 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase singular ;
|
IndefOneNP = indefNounPhrase singular ;
|
||||||
IndefManyNP = plurDetNum ;
|
IndefNumNP = plurDetNum ;
|
||||||
DefOneNP = defNounPhrase singular ;
|
DefOneNP = defNounPhrase singular ;
|
||||||
DefManyNP nu = defNounPhraseNum nu plural ;
|
DefNumNP nu = defNounPhraseNum nu plural ;
|
||||||
MassNP = massNounPhrase ;
|
MassNP = massNounPhrase ;
|
||||||
UseInt i = i ;
|
UseInt i = i ;
|
||||||
NoNum = noNum ;
|
NoNum = noNum ;
|
||||||
|
|||||||
6
lib/resource-0.6/german/PredicationGer.gf
Normal file
6
lib/resource-0.6/german/PredicationGer.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource PredicationGer = Predication with
|
||||||
|
(Resource = ResourceGer), (ResourceExt = ResourceExtGer) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/german/ResourceExtGer.gf
Normal file
4
lib/resource-0.6/german/ResourceExtGer.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtGer = ResourceExt with (Resource = ResourceGer) ;
|
||||||
|
|
||||||
@@ -24,8 +24,8 @@ lin
|
|||||||
ThouNP = pronNounPhrase pronDu ;
|
ThouNP = pronNounPhrase pronDu ;
|
||||||
HeNP = pronNounPhrase pronEr ;
|
HeNP = pronNounPhrase pronEr ;
|
||||||
SheNP = pronNounPhrase pronSie ;
|
SheNP = pronNounPhrase pronSie ;
|
||||||
WeNP n = pronNounPhrase (pronWithNum pronWir n) ;
|
WeNumNP n = pronNounPhrase (pronWithNum pronWir n) ;
|
||||||
YeNP n = pronNounPhrase (pronWithNum pronIhr n) ;
|
YeNumNP n = pronNounPhrase (pronWithNum pronIhr n) ;
|
||||||
TheyNP = pronNounPhrase pronSiePl ;
|
TheyNP = pronNounPhrase pronSiePl ;
|
||||||
|
|
||||||
YouNP = pronNounPhrase pronSSie ;
|
YouNP = pronNounPhrase pronSSie ;
|
||||||
@@ -33,30 +33,30 @@ lin
|
|||||||
ItNP = pronNounPhrase pronEs ;
|
ItNP = pronNounPhrase pronEs ;
|
||||||
ThisNP = nameNounPhrase {s = dieserDet.s ! Neut} ; ---
|
ThisNP = nameNounPhrase {s = dieserDet.s ! Neut} ; ---
|
||||||
ThatNP = nameNounPhrase {s = jenerDet.s ! Neut} ; ---
|
ThatNP = nameNounPhrase {s = jenerDet.s ! Neut} ; ---
|
||||||
TheseNP nu = let diese = caselist "diese" "diese" "diesen" "diesen" in
|
TheseNumNP nu = let diese = caselist "diese" "diese" "diesen" "diesen" in
|
||||||
normalNounPhrase (\\c => diese ! c ++ nu.s) plural ;
|
normalNounPhrase (\\c => diese ! c ++ nu.s) plural ;
|
||||||
ThoseNP nu = let jene = caselist "jene" "jene" "jenen" "jenen" in
|
ThoseNumNP nu = let jene = caselist "jene" "jene" "jenen" "jenen" in
|
||||||
normalNounPhrase (\\c => jene ! c ++ nu.s) plural ;
|
normalNounPhrase (\\c => jene ! c ++ nu.s) plural ;
|
||||||
|
|
||||||
AnyDet = detLikeAdj "irgendwelch" ;
|
AnyDet = detLikeAdj "irgendwelch" ;
|
||||||
AnysDet nu = mkDeterminerNumReg nu "irgendwelche" Weak ;
|
AnyNumDet nu = mkDeterminerNumReg nu "irgendwelche" Weak ;
|
||||||
EveryDet = jederDet ;
|
EveryDet = jederDet ;
|
||||||
AllDet = allesDet ;
|
AllMassDet = allesDet ;
|
||||||
AllsDet = alleDet ;
|
AllNumDet = alleDet ;
|
||||||
WhichDet = welcherDet ;
|
WhichDet = welcherDet ;
|
||||||
WhichsDet = welcheDet ;
|
WhichNumDet = welcheDet ;
|
||||||
MostDet = meistDet ;
|
MostDet = meistDet ;
|
||||||
MostsDet = meisteDet ;
|
MostsDet = meisteDet ;
|
||||||
ManyDet = mkDeterminerPl (caselist "viele" "viele" "vielen" "vieler") Strong ;
|
ManyDet = mkDeterminerPl (caselist "viele" "viele" "vielen" "vieler") Strong ;
|
||||||
MuchDet = detLikeAdj "viel" ;
|
MuchDet = detLikeAdj "viel" ;
|
||||||
NoDet = keinDet ;
|
NoDet = keinDet ;
|
||||||
NosDet nu = mkDeterminerNumReg nu "keine" Strong ;
|
NoNumDet nu = mkDeterminerNumReg nu "keine" Strong ;
|
||||||
SomeDet = einDet ; ---
|
SomeDet = einDet ; ---
|
||||||
SomesDet nu = mkDeterminerNumReg nu "einige" Strong ;
|
SomeNumDet nu = mkDeterminerNumReg nu "einige" Strong ;
|
||||||
ThatDet = detLikeAdj "jen" ;
|
ThatDet = detLikeAdj "jen" ;
|
||||||
ThisDet = detLikeAdj "dies" ;
|
ThisDet = detLikeAdj "dies" ;
|
||||||
TheseDet nu = mkDeterminerNumReg nu "diese" Strong ;
|
TheseNumDet nu = mkDeterminerNumReg nu "diese" Strong ;
|
||||||
ThoseDet nu = mkDeterminerNumReg nu "jene" Strong ;
|
ThoseNumDet nu = mkDeterminerNumReg nu "jene" Strong ;
|
||||||
|
|
||||||
HowIAdv = ss "wie" ;
|
HowIAdv = ss "wie" ;
|
||||||
WhenIAdv = ss "wann" ;
|
WhenIAdv = ss "wann" ;
|
||||||
|
|||||||
6
lib/resource-0.6/italian/PredicationIta.gf
Normal file
6
lib/resource-0.6/italian/PredicationIta.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../romance:../../prelude
|
||||||
|
|
||||||
|
resource PredicationIta = Predication with
|
||||||
|
(Resource = ResourceIta), (ResourceExt = ResourceExtIta) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/italian/ResourceExtIta.gf
Normal file
4
lib/resource-0.6/italian/ResourceExtIta.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../romance:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtIta = ResourceExt with (Resource = ResourceIta) ;
|
||||||
|
|
||||||
@@ -8,8 +8,8 @@ lin
|
|||||||
ThouNP = pronNounPhrase pronTu ;
|
ThouNP = pronNounPhrase pronTu ;
|
||||||
HeNP = pronNounPhrase pronIl ;
|
HeNP = pronNounPhrase pronIl ;
|
||||||
SheNP = pronNounPhrase pronElle ;
|
SheNP = pronNounPhrase pronElle ;
|
||||||
WeNP n = pronNounPhrase (pronWithNum pronNous n) ;
|
WeNumNP n = pronNounPhrase (pronWithNum pronNous n) ;
|
||||||
YeNP n = pronNounPhrase (pronWithNum pronVous n) ;
|
YeNumNP n = pronNounPhrase (pronWithNum pronVous n) ;
|
||||||
YouNP = pronNounPhrase pronVous ;
|
YouNP = pronNounPhrase pronVous ;
|
||||||
TheyNP = pronNounPhrase pronIls ;
|
TheyNP = pronNounPhrase pronIls ;
|
||||||
|
|
||||||
@@ -21,30 +21,30 @@ lin
|
|||||||
|
|
||||||
ThisNP = mkNameNounPhrase ["questo"] Masc ;
|
ThisNP = mkNameNounPhrase ["questo"] Masc ;
|
||||||
ThatNP = mkNameNounPhrase ["quello"] Masc ;
|
ThatNP = mkNameNounPhrase ["quello"] Masc ;
|
||||||
TheseNP n = mkNameNounPhrase ("questi" ++ n.s ! Masc) Masc ;
|
TheseNumNP n = mkNameNounPhrase ("questi" ++ n.s ! Masc) Masc ;
|
||||||
ThoseNP n = mkNameNounPhrase ("quelli" ++ n.s ! Masc) Masc ;
|
ThoseNumNP n = mkNameNounPhrase ("quelli" ++ n.s ! Masc) Masc ;
|
||||||
|
|
||||||
ItNP = pronNounPhrase pronIl ;
|
ItNP = pronNounPhrase pronIl ;
|
||||||
|
|
||||||
EveryDet = chaqueDet ;
|
EveryDet = chaqueDet ;
|
||||||
AllDet = mkDeterminer singular "tutto" "tutta" ;
|
AllMassDet = mkDeterminer singular "tutto" "tutta" ;
|
||||||
AllsDet = mkDeterminerNum plural ["tutti i"] ["tutte le"] ; --- gli
|
AllNumDet = mkDeterminerNum plural ["tutti i"] ["tutte le"] ; --- gli
|
||||||
WhichDet = quelDet ;
|
WhichDet = quelDet ;
|
||||||
WhichsDet = mkDeterminerNum plural "quali" "quali" ;
|
WhichNumDet = mkDeterminerNum plural "quali" "quali" ;
|
||||||
MostsDet = plupartDet ;
|
MostsDet = plupartDet ;
|
||||||
MostDet = mkDeterminer1 singular (["la maggior parte"] ++ elisDe) ; --- de
|
MostDet = mkDeterminer1 singular (["la maggior parte"] ++ elisDe) ; --- de
|
||||||
SomeDet = mkDeterminer1 singular "qualche" ;
|
SomeDet = mkDeterminer1 singular "qualche" ;
|
||||||
SomesDet = mkDeterminerNum plural "alcuni" "alcune" ;
|
SomeNumDet = mkDeterminerNum plural "alcuni" "alcune" ;
|
||||||
NoDet = mkDeterminer singular "nessuno" "nessuna" ; --- non
|
NoDet = mkDeterminer singular "nessuno" "nessuna" ; --- non
|
||||||
NosDet = mkDeterminerNum plural "nessuni" "nessune" ; ---- ??
|
NoNumDet = mkDeterminerNum plural "nessuni" "nessune" ; ---- ??
|
||||||
AnyDet = mkDeterminer1 singular "qualche" ; ---
|
AnyDet = mkDeterminer1 singular "qualche" ; ---
|
||||||
AnysDet = mkDeterminerNum plural "alcuni" "alcune" ; ---
|
AnyNumDet = mkDeterminerNum plural "alcuni" "alcune" ; ---
|
||||||
ManyDet = mkDeterminer plural "molti" "molte" ;
|
ManyDet = mkDeterminer plural "molti" "molte" ;
|
||||||
MuchDet = mkDeterminer1 singular "molto" ;
|
MuchDet = mkDeterminer1 singular "molto" ;
|
||||||
ThisDet = mkDeterminer singular "questo" "questa" ;
|
ThisDet = mkDeterminer singular "questo" "questa" ;
|
||||||
ThatDet = mkDeterminer singular "quello" "quella" ;
|
ThatDet = mkDeterminer singular "quello" "quella" ;
|
||||||
TheseDet = mkDeterminerNum plural "questi" "queste" ; --- ci
|
TheseNumDet = mkDeterminerNum plural "questi" "queste" ; --- ci
|
||||||
ThoseDet = mkDeterminerNum plural "quelli" "quelle" ; --- quegli
|
ThoseNumDet = mkDeterminerNum plural "quelli" "quelle" ; --- quegli
|
||||||
|
|
||||||
HowIAdv = commentAdv ;
|
HowIAdv = commentAdv ;
|
||||||
WhenIAdv = quandAdv ;
|
WhenIAdv = quandAdv ;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ lin
|
|||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModAdj = modCommNounPhrase ;
|
ModAdj = modCommNounPhrase ;
|
||||||
ModGenOne = npGenDet singular ;
|
ModGenOne = npGenDet singular ;
|
||||||
ModGenMany = npGenDetNum ;
|
ModGenNum = npGenDetNum ;
|
||||||
UsePN = nameNounPhrase ;
|
UsePN = nameNounPhrase ;
|
||||||
UseFun = funAsCommNounPhrase ; -- [SyntaxFra.noun2CommNounPhrase]
|
UseFun = funAsCommNounPhrase ; -- [SyntaxFra.noun2CommNounPhrase]
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
@@ -96,9 +96,9 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase singular ;
|
IndefOneNP = indefNounPhrase singular ;
|
||||||
IndefManyNP = indefNounPhraseNum ;
|
IndefNumNP = indefNounPhraseNum ;
|
||||||
DefOneNP = defNounPhrase singular ;
|
DefOneNP = defNounPhrase singular ;
|
||||||
DefManyNP = defNounPhraseNum ;
|
DefNumNP = defNounPhraseNum ;
|
||||||
MassNP = partitiveNounPhrase singular ;
|
MassNP = partitiveNounPhrase singular ;
|
||||||
UseInt i = {s = \\_ => i.s} ;
|
UseInt i = {s = \\_ => i.s} ;
|
||||||
NoNum = noNum ;
|
NoNum = noNum ;
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ lin
|
|||||||
|
|
||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModGenOne = npGenDet Sg noNum ;
|
ModGenOne = npGenDet Sg noNum ;
|
||||||
ModGenMany = npGenDet Pl ;
|
ModGenNum = npGenDet Pl ;
|
||||||
UseFun = funAsCommNounPhrase ;
|
UseFun = funAsCommNounPhrase ;
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
AppFun2 = appFun2 ;
|
AppFun2 = appFun2 ;
|
||||||
@@ -135,20 +135,11 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase Sg ;
|
IndefOneNP = indefNounPhrase Sg ;
|
||||||
IndefManyNP = indefNounPhraseNum Pl ;
|
IndefNumNP = indefNounPhraseNum Pl ;
|
||||||
DefOneNP = indefNounPhrase Sg ;
|
DefOneNP = indefNounPhrase Sg ;
|
||||||
DefManyNP = indefNounPhraseNum Pl ;
|
DefNumNP = indefNounPhraseNum Pl ;
|
||||||
MassNP = indefNounPhrase Sg;
|
MassNP = indefNounPhrase Sg;
|
||||||
|
|
||||||
--PosV = predVerb True ;
|
|
||||||
--NegV = predVerb False ;
|
|
||||||
--PosCN = predCommNoun True ;
|
|
||||||
--NegCN = predCommNoun False ;
|
|
||||||
--PosNP = predNounPhrase True ;
|
|
||||||
--NegNP = predNounPhrase False ;
|
|
||||||
--PosVS = complSentVerb True ;
|
|
||||||
--NegVS = complSentVerb False ;
|
|
||||||
|
|
||||||
PosVG = predVerbGroup True ;
|
PosVG = predVerbGroup True ;
|
||||||
NegVG = predVerbGroup False ;
|
NegVG = predVerbGroup False ;
|
||||||
|
|
||||||
|
|||||||
@@ -1,76 +1,6 @@
|
|||||||
-- predication library, built on resource grammar. AR 2002--2003
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
-- Users of the library should *not* look into this file, but only into
|
resource PredicationRus = Predication with
|
||||||
-- $predication.Types.gf$.
|
(Resource = ResourceRus), (ResourceExt = ResourceExtRus) ;
|
||||||
|
|
||||||
resource PredicationRus = open ResourceRus in {
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
|
|
||||||
-- We first define a set of predication patterns.
|
|
||||||
|
|
||||||
oper
|
|
||||||
predV1 : V -> NP -> S ; -- one-place verb: "John walks"
|
|
||||||
predV2 : TV -> NP -> NP -> S ; -- two-place verb: "John loves Mary"
|
|
||||||
predVColl : V -> NP -> NP -> S ; -- collective verb: "John and Mary fight"
|
|
||||||
predA1 : Adj1 -> NP -> S ; -- one-place adjective: "John is old"
|
|
||||||
predA2 : Adj2 -> NP -> NP -> S ; -- two-place adj: "John is married to Mary"
|
|
||||||
predAComp : AdjDeg -> NP -> NP -> S ; -- compar adj: "John is older than Mary"
|
|
||||||
predAColl : Adj1 -> NP -> NP -> S ; -- collective adj: "John and Mary are married"
|
|
||||||
predN1 : N -> NP -> S ; -- one-place noun: "John is a man"
|
|
||||||
predN2 : Fun -> NP -> NP -> S ; -- two-place noun: "John is a lover of Mary"
|
|
||||||
predNColl : N -> NP -> NP -> S ; -- collective noun: "John and Mary are lovers"
|
|
||||||
|
|
||||||
-- Individual-valued function applications.
|
|
||||||
|
|
||||||
appFun1 : Fun -> NP -> NP ; -- one-place function: "the successor of x"
|
|
||||||
appFunColl : Fun -> NP -> NP -> NP ; -- collective function: "the sum of x and y"
|
|
||||||
|
|
||||||
-- Families of types, expressed by common nouns depending on arguments.
|
|
||||||
|
|
||||||
appFam1 : Fun -> NP -> CN ; -- one-place family: "divisor of x"
|
|
||||||
appFamColl : Fun -> NP -> NP -> CN ; -- collective family: "path between x and y"
|
|
||||||
|
|
||||||
-- Type constructor, similar to a family except that the argument is a type.
|
|
||||||
|
|
||||||
constrTyp1 : Fun -> CN -> CN ;
|
|
||||||
|
|
||||||
-- Logical connectives on two sentences.
|
|
||||||
|
|
||||||
conjS : S -> S -> S ;
|
|
||||||
disjS : S -> S -> S ;
|
|
||||||
implS : S -> S -> S ;
|
|
||||||
|
|
||||||
-- As an auxiliary, we need two-place conjunction of names ("John and Mary"),
|
|
||||||
-- used in collective predication.
|
|
||||||
|
|
||||||
conjNP : NP -> NP -> NP ;
|
|
||||||
|
|
||||||
|
|
||||||
-----------------------------
|
|
||||||
oper
|
|
||||||
|
|
||||||
predV1 = \F, x -> PredVP x (PosVG (PredV F)) ;
|
|
||||||
predV2 = \F, x, y -> PredVP x (PosVG (PredTV F y)) ;
|
|
||||||
predVColl = \F, x, y -> PredVP (conjNP x y) (PosVG (PredV F)) ;
|
|
||||||
predA1 = \F, x -> PredVP x (PosVG (PredAP (AdjP1 F))) ;
|
|
||||||
predA2 = \F, x, y -> PredVP x (PosVG (PredAP (ComplAdj F y))) ;
|
|
||||||
predAComp = \F, x, y -> PredVP x (PosVG (PredAP (ComparAdjP F y))) ;
|
|
||||||
predAColl = \F, x, y -> PredVP (conjNP x y) (PosVG (PredAP (AdjP1 F))) ;
|
|
||||||
predN1 = \F, x -> PredVP x (PosVG (PredCN (UseN F))) ;
|
|
||||||
predN2 = \F, x, y -> PredVP x (PosVG (PredCN (AppFun F y))) ;
|
|
||||||
predNColl = \F, x, y -> PredVP (conjNP x y) (PosVG (PredCN (UseN F))) ;
|
|
||||||
|
|
||||||
appFun1 = \f, x -> DefOneNP (AppFun f x) ;
|
|
||||||
appFunColl = \f, x, y -> DefOneNP (AppFun f (conjNP x y)) ;
|
|
||||||
|
|
||||||
appFam1 = \F, x -> AppFun F x ;
|
|
||||||
appFamColl = \F, x, y -> AppFun F (conjNP x y) ;
|
|
||||||
|
|
||||||
conjS = \A, B -> ConjS AndConj (TwoS A B) ;
|
|
||||||
disjS = \A, B -> ConjS OrConj (TwoS A B) ;
|
|
||||||
implS = \A, B -> SubjS IfSubj A B ;
|
|
||||||
|
|
||||||
constrTyp1 = \F, A -> AppFun F (IndefOneNP A) ;
|
|
||||||
|
|
||||||
conjNP = \x, y -> ConjNP AndConj (TwoNP x y) ;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|||||||
4
lib/resource-0.6/russian/ResourceExtRus.gf
Normal file
4
lib/resource-0.6/russian/ResourceExtRus.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtRus = ResourceExt with (Resource = ResourceRus) ;
|
||||||
|
|
||||||
@@ -29,17 +29,17 @@ lin
|
|||||||
ThouNP = pron2NounPhrase pronTu Animate;
|
ThouNP = pron2NounPhrase pronTu Animate;
|
||||||
HeNP = pron2NounPhrase pronOn Animate;
|
HeNP = pron2NounPhrase pronOn Animate;
|
||||||
SheNP = pron2NounPhrase pronOna Animate;
|
SheNP = pron2NounPhrase pronOna Animate;
|
||||||
ItNP= pron2NounPhrase pronOno Inanimate;
|
ItNP = pron2NounPhrase pronOno Inanimate;
|
||||||
WeNP = pronWithNum (pron2NounPhrase pronMu Animate);
|
WeNumNP = pronWithNum (pron2NounPhrase pronMu Animate);
|
||||||
YeNP = pronWithNum (pron2NounPhrase pronVu Animate);
|
YeNumNP = pronWithNum (pron2NounPhrase pronVu Animate);
|
||||||
YouNP = pron2NounPhrase pronVu Animate;
|
YouNP = pron2NounPhrase pronVu Animate;
|
||||||
TheyNP = pron2NounPhrase pronOni Animate;
|
TheyNP = pron2NounPhrase pronOni Animate;
|
||||||
|
|
||||||
EveryDet = kazhdujDet ** {n = Sg ; g = PNoGen; c= Nom} ;
|
EveryDet = kazhdujDet ** {n = Sg ; g = PNoGen; c= Nom} ;
|
||||||
AllDet = vesDet ** {n = Sg; g = PNoGen; c = Nom} ;
|
AllMassDet = vesDet ** {n = Sg; g = PNoGen; c = Nom} ;
|
||||||
AllsDet = mkDeterminerNum (vseDetPl ** {n = Pl; g = PNoGen; c = Nom} );
|
AllNumDet = mkDeterminerNum (vseDetPl ** {n = Pl; g = PNoGen; c = Nom} );
|
||||||
WhichDet = kotorujDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
WhichDet = kotorujDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
WhichsDet = mkDeterminerNum (kotorujDet ** {n = Pl; g = PNoGen; c= Nom} );
|
WhichNumDet = mkDeterminerNum (kotorujDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
MostDet = bolshinstvoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ;
|
MostDet = bolshinstvoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ;
|
||||||
-- inanimate, Sg: "большинство телефонов безмолству-ет"
|
-- inanimate, Sg: "большинство телефонов безмолству-ет"
|
||||||
MostsDet = bolshinstvoPlDet ** {n = Pl; g = (PGen Neut); c= Gen} ;
|
MostsDet = bolshinstvoPlDet ** {n = Pl; g = (PGen Neut); c= Gen} ;
|
||||||
@@ -47,21 +47,21 @@ lin
|
|||||||
ManyDet = mnogoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ;
|
ManyDet = mnogoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ;
|
||||||
MuchDet = mnogoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ; -- same as previous
|
MuchDet = mnogoSgDet ** {n = Sg; g = (PGen Neut); c= Gen} ; -- same as previous
|
||||||
SomeDet = nekotorujDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
SomeDet = nekotorujDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
SomesDet = mkDeterminerNum (nekotorujDet ** {n = Pl; g = PNoGen; c= Nom} );
|
SomeNumDet = mkDeterminerNum (nekotorujDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
AnyDet = lubojDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
AnyDet = lubojDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
AnysDet = mkDeterminerNum (lubojDet ** {n = Pl; g = PNoGen; c= Nom} );
|
AnyNumDet = mkDeterminerNum (lubojDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
NoDet = nikakojDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
NoDet = nikakojDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
NosDet = mkDeterminerNum (nikakojDet ** {n = Pl; g = PNoGen; c= Nom} );
|
NoNumDet = mkDeterminerNum (nikakojDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
ThisDet = etotDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
ThisDet = etotDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
TheseDet = mkDeterminerNum (etotDet ** {n = Pl; g = PNoGen; c= Nom} );
|
TheseNumDet = mkDeterminerNum (etotDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
ThatDet = totDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
ThatDet = totDet ** {n = Sg; g = PNoGen; c= Nom} ;
|
||||||
ThoseDet = mkDeterminerNum (totDet ** {n = Pl; g = PNoGen; c= Nom} );
|
ThoseNumDet = mkDeterminerNum (totDet ** {n = Pl; g = PNoGen; c= Nom} );
|
||||||
|
|
||||||
ThisNP = det2NounPhrase etotDet ; -- inanimate form only
|
ThisNP = det2NounPhrase etotDet ; -- inanimate form only
|
||||||
ThatNP = det2NounPhrase totDet ; -- inanimate form only
|
ThatNP = det2NounPhrase totDet ; -- inanimate form only
|
||||||
TheseNP n = { s =\\_ => [] ; n = Pl; p = P3; g= PGen Fem ; anim = Animate ; pron = True} ;
|
TheseNumNP n = { s =\\_ => [] ; n = Pl; p = P3; g= PGen Fem ; anim = Animate ; pron = True} ;
|
||||||
-- missing in Russian
|
-- missing in Russian
|
||||||
ThoseNP n = { s =\\_ => [] ; n = Pl; p = P3; g=PGen Fem ; anim = Animate ; pron = True} ;
|
ThoseNumNP n = { s =\\_ => [] ; n = Pl; p = P3; g=PGen Fem ; anim = Animate ; pron = True} ;
|
||||||
-- missing in Russian
|
-- missing in Russian
|
||||||
|
|
||||||
EverybodyNP = mkNounPhrase Pl (noun2CommNounPhrase (eEnd_Decl "вс")) ;
|
EverybodyNP = mkNounPhrase Pl (noun2CommNounPhrase (eEnd_Decl "вс")) ;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ lin
|
|||||||
UseN = noun2CommNounPhrase ;
|
UseN = noun2CommNounPhrase ;
|
||||||
ModAdj = modCommNounPhrase ;
|
ModAdj = modCommNounPhrase ;
|
||||||
ModGenOne = npGenDet singular noNum ;
|
ModGenOne = npGenDet singular noNum ;
|
||||||
ModGenMany = npGenDet plural ;
|
ModGenNum = npGenDet plural ;
|
||||||
UsePN = nameNounPhrase ;
|
UsePN = nameNounPhrase ;
|
||||||
UseFun = funAsCommNounPhrase ;
|
UseFun = funAsCommNounPhrase ;
|
||||||
AppFun = appFunComm ;
|
AppFun = appFunComm ;
|
||||||
@@ -96,9 +96,9 @@ lin
|
|||||||
|
|
||||||
DetNP = detNounPhrase ;
|
DetNP = detNounPhrase ;
|
||||||
IndefOneNP = indefNounPhrase singular ;
|
IndefOneNP = indefNounPhrase singular ;
|
||||||
IndefManyNP = indefNounPhraseNum plural ;
|
IndefNumNP = indefNounPhraseNum plural ;
|
||||||
DefOneNP = defNounPhrase singular ;
|
DefOneNP = defNounPhrase singular ;
|
||||||
DefManyNP = defNounPhraseNum plural ;
|
DefNumNP = defNounPhraseNum plural ;
|
||||||
MassNP = detNounPhrase (mkDeterminerSg (detSgInvar []) IndefP) ;
|
MassNP = detNounPhrase (mkDeterminerSg (detSgInvar []) IndefP) ;
|
||||||
UseInt i = {s = table {Nom => i.s ; Gen => i.s ++ "s"}} ; ---
|
UseInt i = {s = table {Nom => i.s ; Gen => i.s ++ "s"}} ; ---
|
||||||
NoNum = noNum ;
|
NoNum = noNum ;
|
||||||
|
|||||||
6
lib/resource-0.6/swedish/PredicationSwe.gf
Normal file
6
lib/resource-0.6/swedish/PredicationSwe.gf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource PredicationSwe = Predication with
|
||||||
|
(Resource = ResourceSwe), (ResourceExt = ResourceExtSwe) ;
|
||||||
|
|
||||||
|
-- this is the standard form of a derived resource. AR 12/1/2004
|
||||||
4
lib/resource-0.6/swedish/ResourceExtSwe.gf
Normal file
4
lib/resource-0.6/swedish/ResourceExtSwe.gf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
--# -path=.:../abstract:../../prelude
|
||||||
|
|
||||||
|
resource ResourceExtSwe = ResourceExt with (Resource = ResourceSwe) ;
|
||||||
|
|
||||||
@@ -12,8 +12,8 @@ concrete StructuralSwe of Structural =
|
|||||||
ThouNP = pronNounPhrase du_33 ;
|
ThouNP = pronNounPhrase du_33 ;
|
||||||
HeNP = pronNounPhrase han_34 ;
|
HeNP = pronNounPhrase han_34 ;
|
||||||
SheNP = pronNounPhrase hon_35 ;
|
SheNP = pronNounPhrase hon_35 ;
|
||||||
WeNP n = pronNounPhrase (pronWithNum vi_36 n) ;
|
WeNumNP n = pronNounPhrase (pronWithNum vi_36 n) ;
|
||||||
YeNP n = pronNounPhrase (pronWithNum ni_37 n) ;
|
YeNumNP n = pronNounPhrase (pronWithNum ni_37 n) ;
|
||||||
TheyNP = pronNounPhrase de_38 ;
|
TheyNP = pronNounPhrase de_38 ;
|
||||||
|
|
||||||
YouNP = let {ni = pronNounPhrase ni_37 } in {s = ni.s ; g = ni.g ; n = Sg} ;
|
YouNP = let {ni = pronNounPhrase ni_37 } in {s = ni.s ; g = ni.g ; n = Sg} ;
|
||||||
@@ -21,20 +21,22 @@ concrete StructuralSwe of Structural =
|
|||||||
ItNP = pronNounPhrase det_40 ; ----
|
ItNP = pronNounPhrase det_40 ; ----
|
||||||
ThisNP = regNameNounPhrase ["det här"] Neutr NoMasc ;
|
ThisNP = regNameNounPhrase ["det här"] Neutr NoMasc ;
|
||||||
ThatNP = regNameNounPhrase ["det där"] Neutr NoMasc ;
|
ThatNP = regNameNounPhrase ["det där"] Neutr NoMasc ;
|
||||||
TheseNP n = {s = \\c => ["det här"] ++ n.s ! npCase c ; g = Neutr ; n = Pl} ;
|
TheseNumNP n =
|
||||||
ThoseNP n = {s = \\c => ["det där"] ++ n.s ! npCase c ; g = Neutr ; n = Pl} ;
|
{s = \\c => ["det här"] ++ n.s ! npCase c ; g = Neutr ; n = Pl} ;
|
||||||
|
ThoseNumNP n =
|
||||||
|
{s = \\c => ["det där"] ++ n.s ! npCase c ; g = Neutr ; n = Pl} ;
|
||||||
|
|
||||||
EveryDet = varjeDet ;
|
EveryDet = varjeDet ;
|
||||||
AllDet = mkDeterminerSgGender2 "all" "allt" IndefP ;
|
AllMassDet = mkDeterminerSgGender2 "all" "allt" IndefP ;
|
||||||
AllsDet = mkDeterminerPlNum "alla" IndefP ;
|
AllNumDet = mkDeterminerPlNum "alla" IndefP ;
|
||||||
AnyDet = mkDeterminerSgGender2 "någon" "något" IndefP ;
|
AnyDet = mkDeterminerSgGender2 "någon" "något" IndefP ;
|
||||||
AnysDet = mkDeterminerPlNum "några" IndefP ;
|
AnyNumDet = mkDeterminerPlNum "några" IndefP ;
|
||||||
SomeDet = mkDeterminerSgGender2 "någon" "något" IndefP ;
|
SomeDet = mkDeterminerSgGender2 "någon" "något" IndefP ;
|
||||||
SomesDet = mkDeterminerPlNum "några" IndefP ;
|
SomeNumDet = mkDeterminerPlNum "några" IndefP ;
|
||||||
ManyDet = mkDeterminerPl "många" IndefP ;
|
ManyDet = mkDeterminerPl "många" IndefP ;
|
||||||
NoDet = mkDeterminerSgGender2 "ingen" "inget" IndefP ;
|
NoDet = mkDeterminerSgGender2 "ingen" "inget" IndefP ;
|
||||||
NosDet = mkDeterminerPlNum "inga" IndefP ;
|
NoNumDet = mkDeterminerPlNum "inga" IndefP ;
|
||||||
WhichsDet = mkDeterminerPlNum "vilka" IndefP ;
|
WhichNumDet = mkDeterminerPlNum "vilka" IndefP ;
|
||||||
|
|
||||||
WhichDet = vilkenDet ;
|
WhichDet = vilkenDet ;
|
||||||
MostDet = mkDeterminerSgGender2 ["den mesta"] ["det mesta"] (DefP Def) ;
|
MostDet = mkDeterminerSgGender2 ["den mesta"] ["det mesta"] (DefP Def) ;
|
||||||
@@ -43,8 +45,8 @@ concrete StructuralSwe of Structural =
|
|||||||
|
|
||||||
ThisDet = mkDeterminerSgGender2 ["den här"] ["det här"] (DefP Def) ;
|
ThisDet = mkDeterminerSgGender2 ["den här"] ["det här"] (DefP Def) ;
|
||||||
ThatDet = mkDeterminerSgGender2 ["den där"] ["det där"] (DefP Def) ;
|
ThatDet = mkDeterminerSgGender2 ["den där"] ["det där"] (DefP Def) ;
|
||||||
TheseDet = mkDeterminerPlNum ["de här"] (DefP Def) ;
|
TheseNumDet = mkDeterminerPlNum ["de här"] (DefP Def) ;
|
||||||
ThoseDet = mkDeterminerPlNum ["de där"] (DefP Def) ;
|
ThoseNumDet = mkDeterminerPlNum ["de där"] (DefP Def) ;
|
||||||
|
|
||||||
HowIAdv = ss "hur" ;
|
HowIAdv = ss "hur" ;
|
||||||
WhenIAdv = ss "när" ;
|
WhenIAdv = ss "när" ;
|
||||||
|
|||||||
Reference in New Issue
Block a user