forked from GitHub/gf-core
directories of precompiled libraries under lib
This commit is contained in:
@@ -14,6 +14,12 @@ Changes in functionality since May 17, 2005, release of GF Version 2.2
|
||||
|
||||
<p>
|
||||
|
||||
25/2 (AR) The flag <tt>preproc</tt> of the <tt>i</tt> command (and thereby
|
||||
to <tt>gf</tt> itself) causes GF to apply a preprocessor to each sourcefile
|
||||
it reads.
|
||||
|
||||
<p>
|
||||
|
||||
8/2 (AR) The command <tt>tb = tree_bank</tt> for creating and testing against
|
||||
multilingual treebanks. Example uses:
|
||||
<pre>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageEng of Bronzeage = CatEng, SwadeshEng ** BronzeageI with
|
||||
(Lang = LangEng),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageFin of Bronzeage = CatFin, SwadeshFin ** BronzeageI with
|
||||
(Lang = LangFin),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageFre of Bronzeage = CatFre, SwadeshFre ** BronzeageI with
|
||||
(Lang = LangFre),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageGer of Bronzeage = CatGer, SwadeshGer ** BronzeageI with
|
||||
(Lang = LangGer),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageIta of Bronzeage = CatIta, SwadeshIta ** BronzeageI with
|
||||
(Lang = LangIta),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageNor of Bronzeage = CatNor, SwadeshNor ** BronzeageI with
|
||||
(Lang = LangNor),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageSpa of Bronzeage = CatSpa, SwadeshSpa ** BronzeageI with
|
||||
(Lang = LangSpa),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:resource-1.0/present:prelude:compiled
|
||||
--# -path=.:present:prelude
|
||||
|
||||
concrete BronzeageSwe of Bronzeage = CatSwe, SwadeshSwe ** BronzeageI with
|
||||
(Lang = LangSwe),
|
||||
|
||||
@@ -14,7 +14,7 @@ To build the run-time grammar:
|
||||
Before this, you have to have compiled the libraries:
|
||||
|
||||
cd <whatever you need>GF/lib/resource-1.0
|
||||
make langs
|
||||
make present
|
||||
make install
|
||||
|
||||
To work with the grammar
|
||||
@@ -25,6 +25,10 @@ Once in GF, you can do translation,
|
||||
|
||||
p -mcfg -lang=BronzeageEng "Don't eat that thick snake!" | tb
|
||||
|
||||
spoken-language translation (requires ATK),
|
||||
|
||||
si -lang=BronzeageEng -tr | p -mcfg -lang=BronzeageEng | tb
|
||||
|
||||
random generation,
|
||||
|
||||
gr | tb
|
||||
|
||||
@@ -240,4 +240,4 @@ abstract Swadesh = Cat ** {
|
||||
wash_V : V2 ;
|
||||
wipe_V : V2 ;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -242,4 +242,4 @@ concrete SwadeshEng of Swadesh = CatEng
|
||||
wash_V = dirV2 (regV "wash") ;
|
||||
wipe_V = dirV2 (regV "wipe") ;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,10 +16,12 @@ This works in eight languages.
|
||||
Notice that the compilation of the grammars uses precompiled
|
||||
resources, located in
|
||||
|
||||
GF/lib/compiled
|
||||
GF/lib/
|
||||
|
||||
To produce them, use 'make' and 'make install' in GF/lib/resource-1.0.
|
||||
|
||||
AR 7/11/2005 -- 23/2/2006
|
||||
You moreover have to set your GF_LIB_PATH to point to your GF/lib/.
|
||||
|
||||
|
||||
AR 7/11/2005 -- 25/2/2006
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramEng of Tram = TramI with
|
||||
(Multimodal = MultimodalEng),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramFin of Tram = TramI with
|
||||
(Multimodal = MultimodalFin),
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
|
||||
-- --# -path=.:resource-1.0/abstract:resource-1.0/french:resource-1.0/common:resource-1.0/multimodal:resource-1.0/romance:prelude:resource-1.0/mathematical
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramFre of Tram = TramI with
|
||||
(Multimodal = MultimodalFre),
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
-- --# -path=.:resource-1.0/abstract:resource-1.0/common:resource-1.0/mathematical:resource-1.0/multimodal:resource-1.0/german:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramGer of Tram = TramI with
|
||||
(Multimodal = MultimodalGer),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramIta of Tram = TramI with
|
||||
(Multimodal = MultimodalIta),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramNor of Tram = TramI with
|
||||
(Multimodal = MultimodalNor),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramSpa of Tram = TramI with
|
||||
(Multimodal = MultimodalSpa),
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
--# -path=.:compiled:prelude
|
||||
|
||||
-- --# -path=.:resource-1.0/abstract:resource-1.0/swedish:resource-1.0/common:resource-1.0/multimodal:resource-1.0/scandinavian:prelude:resource-1.0/mathematical
|
||||
--# -path=.:present:multimodal:mathematical:prelude
|
||||
|
||||
concrete TramSwe of Tram = TramI with
|
||||
(Multimodal = MultimodalSwe),
|
||||
|
||||
@@ -1,41 +0,0 @@
|
||||
abstract Dialogue = {
|
||||
|
||||
cat
|
||||
Phrase ;
|
||||
Sentence ;
|
||||
Command ;
|
||||
|
||||
NP ; V ; V2 ; VV ; A ; PP ; IP ;
|
||||
|
||||
fun
|
||||
PhrasePos : Sentence -> Phrase ;
|
||||
PhraseNeg : Sentence -> Phrase ;
|
||||
PhraseQuest : Sentence -> Phrase ;
|
||||
|
||||
SentV : V -> NP -> Sentence ;
|
||||
SentV2 : V2 -> NP -> NP -> Sentence ;
|
||||
SentA : A -> NP -> Sentence ;
|
||||
SentPP : PP -> NP -> Sentence ;
|
||||
|
||||
ModSentV : VV -> V -> NP -> Sentence ;
|
||||
ModSentV2 : VV -> V2 -> NP -> NP -> Sentence ;
|
||||
ModSentA : VV -> A -> NP -> Sentence ;
|
||||
ModSentPP : VV -> PP -> NP -> Sentence ;
|
||||
|
||||
WhQuestV : V -> IP -> Phrase ;
|
||||
WhQuestSubjV2 : V2 -> IP -> NP -> Phrase ;
|
||||
WhQuestObjV2 : V2 -> NP -> IP -> Phrase ;
|
||||
WhQuestA : A -> IP -> Phrase ;
|
||||
WhQuestPP : PP -> IP -> Phrase ;
|
||||
|
||||
CommV : V -> Phrase ;
|
||||
CommV2 : V2 -> NP -> Phrase ;
|
||||
CommA : A -> Phrase ;
|
||||
CommPP : PP -> Phrase ;
|
||||
|
||||
-- to test
|
||||
|
||||
testNP : NP ; testV : V ; testV2 : V2 ; testVV : VV ; testA : A ;
|
||||
testPP : PP ; testIP : IP ;
|
||||
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
--# -path=dialogue:resource/*:prelude
|
||||
|
||||
concrete DialogueEng of Dialogue = DialogueI with
|
||||
(Resource = ResourceEng),
|
||||
(Basic = BasicEng),
|
||||
(DialogueParam = DialogueParamEng) ;
|
||||
@@ -1,42 +0,0 @@
|
||||
incomplete concrete DialogueI of Dialogue = open Prelude, Resource, Basic, DialogueParam in {
|
||||
|
||||
lincat
|
||||
Phrase = {s : Str} ;
|
||||
Sentence = {s : PhraseForm => Str} ;
|
||||
Command = {s : Str} ;
|
||||
|
||||
NP = NP ; V = V ; V2 = V2 ; VV = VV ; A = A ; PP = PP ; IP = IP ;
|
||||
|
||||
lin
|
||||
PhrasePos s = ss (s.s ! PPos) ;
|
||||
PhraseNeg s = ss (s.s ! PNeg) ;
|
||||
PhraseQuest s = ss (s.s ! PQuest) ;
|
||||
|
||||
SentV v np = mkPhrase (SPredV np v) ;
|
||||
SentV2 v np obj = mkPhrase (SPredV2 np v obj) ;
|
||||
SentA v np = mkPhrase (SPredAP np (UseA v)) ;
|
||||
SentPP pp np = mkPhrase (SPredAdv np (AdvPP pp)) ;
|
||||
|
||||
ModSentV m v np = mkPhrase (SPredVV np m (IPredV ASimul v)) ;
|
||||
ModSentV2 m v np obj = mkPhrase (SPredVV np m (IPredV2 ASimul v obj)) ;
|
||||
|
||||
CommV v = ImperOne (PosImpVP (IPredV ASimul v)) ;
|
||||
CommV2 v obj = ImperOne (PosImpVP (IPredV2 ASimul v obj)) ;
|
||||
|
||||
WhQuestV v ip = mkQuestion (QPredV ip v) ;
|
||||
WhQuestSubjV2 v ip np = mkQuestion (QPredV2 ip v np) ;
|
||||
WhQuestObjV2 v np ip = mkQuestion (IntSlash ip (SlashV2 np v)) ;
|
||||
WhQuestA v ip = mkQuestion (QPredAP ip (UseA v)) ;
|
||||
WhQuestPP pp ip = mkQuestion (QPredAdv ip (AdvPP pp)) ;
|
||||
|
||||
|
||||
-- test
|
||||
|
||||
testNP = she_NP ; testV = walk_V ; testV2 = love_V2 ; testVV =
|
||||
want_VV ;
|
||||
--- testA = PositADeg blue_A ;
|
||||
testPP = PrepNP in_Prep (DefOneNP (UseN city_N)) ;
|
||||
testIP = who8one_IP ;
|
||||
|
||||
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
interface DialogueParam = open Resource, Predef, Prelude in {
|
||||
|
||||
param
|
||||
PhraseForm = PPos | PNeg | PQuest ;
|
||||
|
||||
oper
|
||||
mkPhraseStr : (p,n,q : Str) -> {s : PhraseForm => Str} = \p,n,q ->
|
||||
{s = table {
|
||||
PPos => p ;
|
||||
PNeg => n ;
|
||||
PQuest => q
|
||||
}
|
||||
} ;
|
||||
|
||||
mkPhrase : Cl -> {s : PhraseForm => Str} = \p ->
|
||||
mkPhraseStr
|
||||
((IndicPhrase (UseCl (PosTP TPresent ASimul) p)).s)
|
||||
((IndicPhrase (UseCl (NegTP TPresent ASimul) p)).s)
|
||||
((QuestPhrase (UseQCl (PosTP TPresent ASimul) (QuestCl p))).s) ;
|
||||
|
||||
mkQuestion : QCl -> {s : Str} = \q ->
|
||||
(QuestPhrase (UseQCl (PosTP TPresent ASimul) q)) ;
|
||||
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
instance DialogueParamEng of DialogueParam = open ResourceEng, Predef, Prelude in {
|
||||
|
||||
} ;
|
||||
@@ -1,4 +1,4 @@
|
||||
all: langs mathematical multimodal
|
||||
all: present mathematical multimodal langs
|
||||
|
||||
test: langs
|
||||
echo "gr -cat=Text -number=11 -prob | tb" | gf -nocf -probs=lang.gfprob langs.gfcm
|
||||
@@ -7,17 +7,19 @@ langs:
|
||||
echo "s ;; pm | wf langs.gfcm" | gf -nocf */Lang??*.gf english/LangEng.gf +RTS -M500M -K100M
|
||||
|
||||
present:
|
||||
gf -batch -nocf -preproc=./mkPresent */Lang??*.gf
|
||||
cp -p */*.gfc */*.gfr present
|
||||
gf -nocf -preproc=./mkPresent */Lang??*.gf
|
||||
mv */*.gfc */*.gfr ../present
|
||||
|
||||
mathematical: present
|
||||
gf -batch -nocf -preproc=./mkPresent mathematical/Mathematical???.gf
|
||||
mv mathematical/*.gf ../mathematical
|
||||
|
||||
multimodal: present
|
||||
gf -batch -nocf -preproc=./mkPresent multimodal/Multimodal???.gf
|
||||
mv multimodal/*.gf ../multimodal
|
||||
|
||||
install:
|
||||
cp -p */*.gfc */*.gfr langs
|
||||
cp -p */*.gfc */*.gfr ../alltenses
|
||||
|
||||
stat:
|
||||
wc */*.gfc
|
||||
@@ -30,11 +32,13 @@ gfdoc:
|
||||
gfdoc -txthtml mathematical/Predication.gf
|
||||
gfdoc -txthtml multimodal/Demonstrative.gf
|
||||
gfdoc -txthtml multimodal/Multimodal.gf
|
||||
gfdoc -txthtml ../prelude/*.gf
|
||||
mv abstract/*.html doc/gfdoc
|
||||
mv mathematical/*.html doc/gfdoc
|
||||
mv multimodal/*.html doc/gfdoc
|
||||
mv */Paradigms*.html doc/gfdoc
|
||||
cp */Irreg???.gf doc/gfdoc
|
||||
mv ../prelude/*.html doc/gfdoc
|
||||
|
||||
clean:
|
||||
rm */*.gfc */*.gfr */*.gf~
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:prelude
|
||||
|
||||
concrete LexiconEng of Lexicon = CatEng ** open ParadigmsEng in {
|
||||
concrete LexiconEng of Lexicon = CatEng ** open ParadigmsEng, IrregEng in {
|
||||
|
||||
flags
|
||||
optimize=values ;
|
||||
|
||||
@@ -1,181 +1,7 @@
|
||||
----# -path=.:prelude:../abstract:../common
|
||||
--
|
||||
--concrete IrregGer of IrregGerAbs = CatGer ** open ParadigmsGer in {
|
||||
--
|
||||
--flags optimize=values ;
|
||||
--
|
||||
-- lin
|
||||
-- awake_V = irregV "awake" "awoke" "awoken" ;
|
||||
-- bear_V = irregV "bear" "bore" "born" ;
|
||||
-- beat_V = irregV "beat" "beat" "beat" ;
|
||||
-- become_V = irregV "become" "became" "become" ;
|
||||
-- begin_V = irregV "begin" "began" "begun" ;
|
||||
-- bend_V = irregV "bend" "bent" "bent" ;
|
||||
-- beset_V = irregV "beset" "beset" "beset" ;
|
||||
-- bet_V = irregDuplV "bet" "bet" "bet" ;
|
||||
-- bid_V = irregDuplV "bid" (variants {"bid" ; "bade"}) (variants {"bid" ; "bidden"}) ;
|
||||
-- bind_V = irregV "bind" "bound" "bound" ;
|
||||
-- bite_V = irregV "bite" "bit" "bitten" ;
|
||||
-- bleed_V = irregV "bleed" "bled" "bled" ;
|
||||
-- blow_V = irregV "blow" "blew" "blown" ;
|
||||
-- break_V = irregV "break" "broke" "broken" ;
|
||||
-- breed_V = irregV "breed" "bred" "bred" ;
|
||||
-- bring_V = irregV "bring" "brought" "brought" ;
|
||||
-- broadcast_V = irregV "broadcast" "broadcast" "broadcast" ;
|
||||
-- build_V = irregV "build" "built" "built" ;
|
||||
-- burn_V = irregV "burn" (variants {"burned" ; "burnt"}) (variants {"burned" ; "burnt"}) ;
|
||||
-- burst_V = irregV "burst" "burst" "burst" ;
|
||||
-- buy_V = irregV "buy" "bought" "bought" ;
|
||||
-- cast_V = irregV "cast" "cast" "cast" ;
|
||||
-- catch_V = irregV "catch" "caught" "caught" ;
|
||||
-- choose_V = irregV "choose" "chose" "chosen" ;
|
||||
-- cling_V = irregV "cling" "clung" "clung" ;
|
||||
-- come_V = irregV "come" "came" "come" ;
|
||||
-- cost_V = irregV "cost" "cost" "cost" ;
|
||||
-- creep_V = irregV "creep" "crept" "crept" ;
|
||||
-- cut_V = irregDuplV "cut" "cut" "cut" ;
|
||||
-- deal_V = irregV "deal" "dealt" "dealt" ;
|
||||
-- dig_V = irregDuplV "dig" "dug" "dug" ;
|
||||
-- dive_V = irregV "dive" (variants {"dived" ; "dove"}) "dived" ;
|
||||
-- do_V = mkV "do" "does" "did" "done" "doing" ;
|
||||
-- draw_V = irregV "draw" "drew" "drawn" ;
|
||||
-- dream_V = irregV "dream" (variants {"dreamed" ; "dreamt"}) (variants {"dreamed" ; "dreamt"}) ;
|
||||
-- drive_V = irregV "drive" "drove" "driven" ;
|
||||
-- drink_V = irregV "drink" "drank" "drunk" ;
|
||||
-- eat_V = irregV "eat" "ate" "eaten" ;
|
||||
-- fall_V = irregV "fall" "fell" "fallen" ;
|
||||
-- feed_V = irregV "feed" "fed" "fed" ;
|
||||
-- feel_V = irregV "feel" "felt" "felt" ;
|
||||
-- fight_V = irregV "fight" "fought" "fought" ;
|
||||
-- find_V = irregV "find" "found" "found" ;
|
||||
-- fit_V = irregDuplV "fit" "fit" "fit" ;
|
||||
-- flee_V = irregV "flee" "fled" "fled" ;
|
||||
-- fling_V = irregV "fling" "flung" "flung" ;
|
||||
-- fly_V = irregV "fly" "flew" "flown" ;
|
||||
-- forbid_V = irregDuplV "forbid" "forbade" "forbidden" ;
|
||||
-- forget_V = irregDuplV "forget" "forgot" "forgotten" ;
|
||||
-- forgive_V = irregV "forgive" "forgave" "forgiven" ;
|
||||
-- forsake_V = irregV "forsake" "forsook" "forsaken" ;
|
||||
-- freeze_V = irregV "freeze" "froze" "frozen" ;
|
||||
-- get_V = irregDuplV "get" "got" "gotten" ;
|
||||
-- give_V = irregV "give" "gave" "given" ;
|
||||
-- go_V = irregV "go" "went" "gone" ;
|
||||
-- grind_V = irregV "grind" "ground" "ground" ;
|
||||
-- grow_V = irregV "grow" "grew" "grown" ;
|
||||
-- hang_V = irregV "hang" "hung" "hung" ;
|
||||
-- have_V = mkV "have" "has" "had" "had" "having" ;
|
||||
-- hear_V = irregV "hear" "heard" "heard" ;
|
||||
-- hide_V = irregV "hide" "hid" "hidden" ;
|
||||
-- hit_V = irregDuplV "hit" "hit" "hit" ;
|
||||
-- hold_V = irregV "hold" "held" "held" ;
|
||||
-- hurt_V = irregV "hurt" "hurt" "hurt" ;
|
||||
-- keep_V = irregV "keep" "kept" "kept" ;
|
||||
-- kneel_V = irregV "kneel" "knelt" "knelt" ;
|
||||
-- knit_V = irregDuplV "knit" "knit" "knit" ;
|
||||
-- know_V = irregV "know" "knew" "know" ;
|
||||
-- lay_V = irregV "lay" "laid" "laid" ;
|
||||
-- lead_V = irregV "lead" "led" "led" ;
|
||||
-- leap_V = irregV "leap" (variants {"leaped" ; "lept"}) (variants {"leaped" ; "lept"}) ;
|
||||
-- learn_V = irregV "learn" (variants {"learned" ; "learnt"}) (variants {"learned" ; "learnt"}) ;
|
||||
-- leave_V = irregV "leave" "left" "left" ;
|
||||
-- lend_V = irregV "lend" "lent" "lent" ;
|
||||
-- let_V = irregDuplV "let" "let" "let" ;
|
||||
-- lie_V = irregV "lie" "lay" "lain" ;
|
||||
-- light_V = irregV "light" (variants {"lighted" ; "lit"}) "lighted" ;
|
||||
-- lose_V = irregV "lose" "lost" "lost" ;
|
||||
-- make_V = irregV "make" "made" "made" ;
|
||||
-- mean_V = irregV "mean" "meant" "meant" ;
|
||||
-- meet_V = irregV "meet" "met" "met" ;
|
||||
-- misspell_V = irregV "misspell" (variants {"misspelled" ; "misspelt"}) (variants {"misspelled" ; "misspelt"}) ;
|
||||
-- mistake_V = irregV "mistake" "mistook" "mistaken" ;
|
||||
-- mow_V = irregV "mow" "mowed" (variants {"mowed" ; "mown"}) ;
|
||||
-- overcome_V = irregV "overcome" "overcame" "overcome" ;
|
||||
-- overdo_V = mkV "overdo" "overdoes" "overdid" "overdone" "overdoing" ;
|
||||
-- overtake_V = irregV "overtake" "overtook" "overtaken" ;
|
||||
-- overthrow_V = irregV "overthrow" "overthrew" "overthrown" ;
|
||||
-- pay_V = irregV "pay" "paid" "paid" ;
|
||||
-- plead_V = irregV "plead" "pled" "pled" ;
|
||||
-- prove_V = irregV "prove" "proved" (variants {"proved" ; "proven"}) ;
|
||||
-- put_V = irregDuplV "put" "put" "put" ;
|
||||
-- quit_V = irregDuplV "quit" "quit" "quit" ;
|
||||
-- read_V = irregV "read" "read" "read" ;
|
||||
-- rid_V = irregDuplV "rid" "rid" "rid" ;
|
||||
-- ride_V = irregV "ride" "rode" "ridden" ;
|
||||
-- ring_V = irregV "ring" "rang" "rung" ;
|
||||
-- rise_V = irregV "rise" "rose" "risen" ;
|
||||
-- run_V = irregDuplV "run" "ran" "run" ;
|
||||
-- saw_V = irregV "saw" "sawed" (variants {"sawed" ; "sawn"}) ;
|
||||
-- say_V = irregV "say" "said" "said" ;
|
||||
-- see_V = irregV "see" "saw" "seen" ;
|
||||
-- seek_V = irregV "seek" "sought" "sought" ;
|
||||
-- sell_V = irregV "sell" "sold" "sold" ;
|
||||
-- send_V = irregV "send" "sent" "sent" ;
|
||||
-- set_V = irregDuplV "set" "set" "set" ;
|
||||
-- sew_V = irregV "sew" "sewed" (variants {"sewed" ; "sewn"}) ;
|
||||
-- shake_V = irregV "shake" "shook" "shaken" ;
|
||||
-- shave_V = irregV "shave" "shaved" (variants {"shaved" ; "shaven"}) ;
|
||||
-- shear_V = irregV "shear" "shore" "shorn" ;
|
||||
-- shed_V = irregDuplV "shed" "shed" "shed" ;
|
||||
-- shine_V = irregV "shine" "shone" "shone" ;
|
||||
-- shoe_V = irregV "shoe" "shoed" (variants {"shoed" ; "shod"}) ;
|
||||
-- shoot_V = irregV "shoot" "shot" "shot" ;
|
||||
-- show_V = irregV "show" "showed" (variants {"showed" ; "shown"}) ;
|
||||
-- shrink_V = irregV "shrink" "shrank" "shrunk" ;
|
||||
-- shut_V = irregDuplV "shut" "shut" "shut" ;
|
||||
-- sing_V = irregV "sing" "sang" "sung" ;
|
||||
-- sink_V = irregV "sink" "sank" "sunk" ;
|
||||
-- sit_V = irregDuplV "sit" "sat" "sat" ;
|
||||
-- sleep_V = irregV "sleep" "slept" "slept" ;
|
||||
-- slay_V = irregV "slay" "slew" "slain" ;
|
||||
-- slide_V = irregV "slide" "slid" "slid" ;
|
||||
-- sling_V = irregV "sling" "slung" "slung" ;
|
||||
-- slit_V = irregDuplV "slit" "slit" "slit" ;
|
||||
-- smite_V = irregV "smite" "smote" "smitten" ;
|
||||
-- sow_V = irregV "sow" "sowed" (variants {"sowed" ; "sown"}) ;
|
||||
-- speak_V = irregV "speak" "spoke" "spoken" ;
|
||||
-- speed_V = irregV "speed" "sped" "sped" ;
|
||||
-- spend_V = irregV "spend" "spent" "spent" ;
|
||||
-- spill_V = irregV "spill" (variants {"spilled" ; "spilt"}) (variants {"spilled" ; "spilt"}) ;
|
||||
-- spin_V = irregDuplV "spin" "spun" "spun" ;
|
||||
-- spit_V = irregDuplV "spit" (variants {"spit" ; "spat"}) "spit" ;
|
||||
-- split_V = irregDuplV "split" "split" "split" ;
|
||||
-- spread_V = irregV "spread" "spread" "spread" ;
|
||||
-- spring_V = irregV "spring" (variants {"sprang" ; "sprung"}) "sprung" ;
|
||||
-- stand_V = irregV "stand" "stood" "stood" ;
|
||||
-- steal_V = irregV "steal" "stole" "stolen" ;
|
||||
-- stick_V = irregV "stick" "stuck" "stuck" ;
|
||||
-- sting_V = irregV "sting" "stung" "stung" ;
|
||||
-- stink_V = irregV "stink" "stank" "stunk" ;
|
||||
-- stride_V = irregV "stride" "strod" "stridden" ;
|
||||
-- strike_V = irregV "strike" "struck" "struck" ;
|
||||
-- string_V = irregV "string" "strung" "strung" ;
|
||||
-- strive_V = irregV "strive" "strove" "striven" ;
|
||||
-- swear_V = irregV "swear" "swore" "sworn" ;
|
||||
-- sweep_V = irregV "sweep" "swept" "swept" ;
|
||||
-- swell_V = irregV "swell" "swelled" (variants {"swelled" ; "swollen"}) ;
|
||||
-- swim_V = irregDuplV "swim" "swam" "swum" ;
|
||||
-- swing_V = irregV "swing" "swung" "swung" ;
|
||||
-- take_V = irregV "take" "took" "taken" ;
|
||||
-- teach_V = irregV "teach" "taught" "taught" ;
|
||||
-- tear_V = irregV "tear" "tore" "torn" ;
|
||||
-- tell_V = irregV "tell" "told" "told" ;
|
||||
-- think_V = irregV "think" "thought" "thought" ;
|
||||
-- thrive_V = irregV "thrive" (variants {"thrived" ; "throve"}) "thrived" ;
|
||||
-- throw_V = irregV "throw" "threw" "thrown" ;
|
||||
-- thrust_V = irregV "thrust" "thrust" "thrust" ;
|
||||
-- tread_V = irregV "tread" "trod" "trodden" ;
|
||||
-- understand_V = irregV "understand" "understood" "understood" ;
|
||||
-- uphold_V = irregV "uphold" "upheld" "upheld" ;
|
||||
-- upset_V = irregDuplV "upset" "upset" "upset" ;
|
||||
-- wake_V = irregV "wake" "woke" "woken" ;
|
||||
-- wear_V = irregV "wear" "wore" "worn" ;
|
||||
-- weave_V = irregV "weave" (variants {"weaved" ; "wove"}) (variants {"weaved" ; "woven"}) ;
|
||||
-- wed_V = irregDuplV "wed" "wed" "wed" ;
|
||||
-- weep_V = irregV "weep" "wept" "wept" ;
|
||||
-- wind_V = irregV "wind" "wound" "wound" ;
|
||||
-- win_V = irregDuplV "win" "won" "won" ;
|
||||
-- withhold_V = irregV "withhold" "withheld" "withheld" ;
|
||||
-- withstand_V = irregV "withstand" "withstood" "withstood" ;
|
||||
-- wring_V = irregV "wring" "wrung" "wrung" ;
|
||||
-- write_V = irregV "write" "wrote" "written" ;
|
||||
--}
|
||||
--# -path=.:prelude:../abstract:../common
|
||||
|
||||
concrete IrregGer of IrregGerAbs = CatGer ** open ParadigmsGer in {
|
||||
|
||||
flags optimize=values ;
|
||||
|
||||
}
|
||||
|
||||
3
lib/resource-1.0/german/IrregGerAbs.gf
Normal file
3
lib/resource-1.0/german/IrregGerAbs.gf
Normal file
@@ -0,0 +1,3 @@
|
||||
abstract IrregGerAbs = Cat ** {
|
||||
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:../common:../abstract:../../prelude
|
||||
|
||||
concrete LexiconGer of Lexicon = CatGer ** open Prelude, ParadigmsGer in {
|
||||
concrete LexiconGer of Lexicon = CatGer ** open Prelude, ParadigmsGer, IrregGer in {
|
||||
|
||||
flags
|
||||
optimize=all_subs ;
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
--1 The Mathematics API to the Resource Grammar
|
||||
|
||||
-- This grammar is a collection of the different modules.
|
||||
-- It differs from $Lang$ in two main ways:
|
||||
-- - the combinations in Noun, Verb, Adjective, Adverb, Sentence are not included
|
||||
-- - instead, Symbol and Predication are used
|
||||
--
|
||||
--
|
||||
-- In practice, the most important difference is that only present-tense sentences
|
||||
-- are included, and that symbolic expressions are recognized as NPs.
|
||||
|
||||
abstract Mathematical =
|
||||
Noun - [ComplN2], --- to avoid ambiguity
|
||||
-- Verb,
|
||||
Adjective,
|
||||
Adverb,
|
||||
Numeral,
|
||||
-- Sentence,
|
||||
Question,
|
||||
Relative,
|
||||
Conjunction,
|
||||
Phrase,
|
||||
Text,
|
||||
Idiom,
|
||||
Structural,
|
||||
|
||||
Symbol,
|
||||
Predication,
|
||||
|
||||
Lexicon
|
||||
** {} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalEng of Mathematical =
|
||||
NounEng - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbEng,
|
||||
AdjectiveEng,
|
||||
AdverbEng,
|
||||
NumeralEng,
|
||||
-- SentenceEng,
|
||||
QuestionEng,
|
||||
RelativeEng,
|
||||
ConjunctionEng,
|
||||
PhraseEng,
|
||||
StructuralEng,
|
||||
TextX,
|
||||
IdiomEng,
|
||||
|
||||
SymbolEng,
|
||||
PredicationEng,
|
||||
|
||||
LexiconEng
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalFin of Mathematical =
|
||||
NounFin - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbFin,
|
||||
AdjectiveFin,
|
||||
AdverbFin,
|
||||
NumeralFin,
|
||||
-- SentenceFin,
|
||||
QuestionFin,
|
||||
RelativeFin,
|
||||
ConjunctionFin,
|
||||
PhraseFin,
|
||||
TextX,
|
||||
IdiomFin,
|
||||
StructuralFin,
|
||||
|
||||
SymbolFin,
|
||||
PredicationFin,
|
||||
|
||||
LexiconFin
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalFre of Mathematical =
|
||||
NounFre - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbFre,
|
||||
AdjectiveFre,
|
||||
AdverbFre,
|
||||
NumeralFre,
|
||||
-- SentenceFre,
|
||||
QuestionFre,
|
||||
RelativeFre,
|
||||
ConjunctionFre,
|
||||
PhraseFre,
|
||||
TextX,
|
||||
IdiomFre,
|
||||
StructuralFre,
|
||||
|
||||
SymbolFre,
|
||||
PredicationFre - [predV3], ---- gf bug
|
||||
|
||||
LexiconFre
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalGer of Mathematical =
|
||||
NounGer - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbGer,
|
||||
AdjectiveGer,
|
||||
AdverbGer,
|
||||
NumeralGer,
|
||||
-- SentenceGer,
|
||||
QuestionGer,
|
||||
RelativeGer,
|
||||
ConjunctionGer,
|
||||
PhraseGer,
|
||||
TextX,
|
||||
IdiomGer,
|
||||
StructuralGer,
|
||||
|
||||
SymbolGer,
|
||||
PredicationGer,
|
||||
|
||||
LexiconGer
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalIta of Mathematical =
|
||||
NounIta - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbIta,
|
||||
AdjectiveIta,
|
||||
AdverbIta,
|
||||
NumeralIta,
|
||||
-- SentenceIta,
|
||||
QuestionIta,
|
||||
RelativeIta,
|
||||
ConjunctionIta,
|
||||
PhraseIta,
|
||||
TextX,
|
||||
IdiomIta,
|
||||
StructuralIta,
|
||||
|
||||
SymbolIta,
|
||||
PredicationIta, -- - [predV3,predV2], --- gf bug
|
||||
|
||||
LexiconIta
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,27 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalNor of Mathematical =
|
||||
NounNor - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbNor,
|
||||
AdjectiveNor,
|
||||
AdverbNor,
|
||||
NumeralNor,
|
||||
-- SentenceNor,
|
||||
QuestionNor,
|
||||
RelativeNor,
|
||||
ConjunctionNor,
|
||||
PhraseNor,
|
||||
TextX,
|
||||
IdiomNor,
|
||||
|
||||
StructuralNor,
|
||||
|
||||
SymbolNor,
|
||||
PredicationNor,
|
||||
|
||||
LexiconNor
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,26 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalSpa of Mathematical =
|
||||
NounSpa - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbSpa,
|
||||
AdjectiveSpa,
|
||||
AdverbSpa,
|
||||
NumeralSpa,
|
||||
-- SentenceSpa,
|
||||
QuestionSpa,
|
||||
RelativeSpa,
|
||||
ConjunctionSpa,
|
||||
PhraseSpa,
|
||||
TextSpa,
|
||||
IdiomSpa,
|
||||
StructuralSpa,
|
||||
|
||||
SymbolSpa,
|
||||
PredicationSpa, -- - [predV3,predV2], --- gf bug
|
||||
|
||||
LexiconSpa
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,27 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MathematicalSwe of Mathematical =
|
||||
NounSwe - [ComplN2], --- to avoid ambiguity
|
||||
-- VerbSwe,
|
||||
AdjectiveSwe,
|
||||
AdverbSwe,
|
||||
NumeralSwe,
|
||||
-- SentenceSwe,
|
||||
QuestionSwe,
|
||||
RelativeSwe,
|
||||
ConjunctionSwe,
|
||||
PhraseSwe,
|
||||
TextX,
|
||||
IdiomSwe,
|
||||
|
||||
StructuralSwe,
|
||||
|
||||
SymbolSwe,
|
||||
PredicationSwe,
|
||||
|
||||
LexiconSwe
|
||||
** {
|
||||
|
||||
flags startcat = Phr ;
|
||||
|
||||
} ;
|
||||
@@ -1,55 +0,0 @@
|
||||
--1 A Small Predication Library
|
||||
--
|
||||
-- (c) Aarne Ranta 2003-2006 under Gnu GPL.
|
||||
--
|
||||
-- This library is a derived library built on the language-independent Ground
|
||||
-- API of resource grammars.
|
||||
|
||||
abstract Predication = Cat ** {
|
||||
|
||||
--2 The category of atomic sentences
|
||||
|
||||
-- We want to use sentences in positive and negative forms but do not care about
|
||||
-- tenses.
|
||||
|
||||
fun
|
||||
PosCl : Cl -> S ; -- positive sentence: "x intersects y"
|
||||
NegCl : Cl -> S ; -- negative sentence: "x doesn't intersect y"
|
||||
|
||||
--2 Predication patterns.
|
||||
|
||||
predV : V -> NP -> Cl ; -- one-place verb: "x converges"
|
||||
predV2 : V2 -> NP -> NP -> Cl ; -- two-place verb: "x intersects y"
|
||||
predV3 : V3 -> NP->NP-> NP -> Cl; -- three-place verb: "x intersects y at z"
|
||||
predVColl : V -> NP -> NP -> Cl ; -- collective verb: "x and y intersect"
|
||||
predA : A -> NP -> Cl ; -- one-place adjective: "x is even"
|
||||
predA2 : A2 -> NP -> NP -> Cl ; -- two-place adj: "x is divisible by y"
|
||||
predAComp : A -> NP -> NP -> Cl; -- comparative adj: "x is greater than y"
|
||||
predAColl : A -> NP -> NP -> Cl ; -- collective adj: "x and y are parallel"
|
||||
predN : N -> NP -> Cl ; -- one-place noun: "x is a point"
|
||||
predN2 : N2 -> NP -> NP -> Cl ; -- two-place noun: "x is a divisor of y"
|
||||
predNColl : N -> NP -> NP -> Cl ; -- collective noun: "x and y are duals"
|
||||
predAdv : Adv -> NP -> Cl ; -- adverb: "x is inside"
|
||||
predPrep : Prep -> NP -> NP -> Cl ; -- preposition: "x is outside y"
|
||||
|
||||
--2 Individual-valued function applications
|
||||
|
||||
appN2 : N2 -> NP -> NP ; -- one-place function: "the successor of x"
|
||||
appN3 : N3 -> NP -> NP -> NP ; -- two-place function: "the distance from x to y"
|
||||
appColl : N2 -> NP -> NP -> NP ; -- collective function: "the sum of x and y"
|
||||
|
||||
--2 Families of types
|
||||
|
||||
-- These are expressed by relational nouns applied to arguments.
|
||||
|
||||
famN2 : N2 -> NP -> CN ; -- one-place family: "divisor of x"
|
||||
famN3 : N3 -> NP -> NP -> CN ; -- two-place family: "path from x to y"
|
||||
famColl : N2 -> NP -> NP -> CN ; -- collective family: "path between x and y"
|
||||
|
||||
--2 Type constructor
|
||||
|
||||
-- This is similar to a family except that the argument is a type.
|
||||
|
||||
typN2 : N2 -> CN -> CN ; -- constructed type: "list of integers"
|
||||
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationEng of Predication = CatEng ** PredicationI with
|
||||
(Lang = LangEng) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationFin of Predication = CatFin ** PredicationI with
|
||||
(Lang = LangFin) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationFre of Predication = CatFre ** PredicationI with
|
||||
(Lang = LangFre) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationGer of Predication = CatGer ** PredicationI with
|
||||
(Lang = LangGer) ;
|
||||
|
||||
@@ -1,50 +0,0 @@
|
||||
incomplete concrete PredicationI of Predication = Cat ** open ParamX, Lang in {
|
||||
|
||||
flags optimize = all_subs ;
|
||||
|
||||
lin
|
||||
PosCl cl = UseCl TPres ASimul PPos cl ;
|
||||
NegCl cl = UseCl TPres ASimul PNeg cl ;
|
||||
|
||||
--2 Predication patterns.
|
||||
|
||||
predV v x = PredVP x (UseV v) ;
|
||||
predV2 v x y = PredVP x (ComplV2 v y) ;
|
||||
predV3 v x y z = PredVP x (ComplV3 v y z) ;
|
||||
predVColl v x y = PredVP (ConjNP and_Conj (BaseNP x y)) (UseV v) ;
|
||||
predA a x = PredVP x (UseComp (CompAP (PositA a))) ;
|
||||
predA2 a x y = PredVP x (UseComp (CompAP (ComplA2 a y))) ;
|
||||
predAComp a x y = PredVP x (UseComp (CompAP (ComparA a y))) ;
|
||||
predAColl a x y =
|
||||
PredVP (ConjNP and_Conj (BaseNP x y)) (UseComp (CompAP (PositA a))) ;
|
||||
predN n x =
|
||||
PredVP x (UseComp (CompNP (DetCN (DetSg (SgQuant IndefArt) NoOrd) (UseN n)))) ;
|
||||
predN2 n x y =
|
||||
PredVP x (UseComp (CompNP (DetCN (DetSg (SgQuant IndefArt) NoOrd) (ComplN2 n y)))) ;
|
||||
predNColl n x y = PredVP (ConjNP and_Conj (BaseNP x y))
|
||||
(UseComp (CompNP (DetCN (DetPl (PlQuant IndefArt) NoNum NoOrd) (UseN n)))) ;
|
||||
predAdv a x = PredVP x (UseComp (CompAdv a)) ;
|
||||
predPrep p x y = PredVP x (UseComp (CompAdv (PrepNP p y))) ;
|
||||
|
||||
--2 Individual-valued function applications
|
||||
|
||||
appN2 n x = DetCN (DetSg (SgQuant DefArt) NoOrd) (ComplN2 n x) ;
|
||||
appN3 n x y = DetCN (DetSg (SgQuant DefArt) NoOrd) (ComplN2 (ComplN3 n x) y) ;
|
||||
appColl n x y =
|
||||
DetCN (DetSg (SgQuant DefArt) NoOrd) (ComplN2 n (ConjNP and_Conj (BaseNP x y))) ;
|
||||
|
||||
--2 Families of types
|
||||
|
||||
-- These are expressed by relational nouns applied to arguments.
|
||||
|
||||
famN2 n x = ComplN2 n x ;
|
||||
famN3 n x y = ComplN2 (ComplN3 n x) y ;
|
||||
famColl n x y = ComplN2 n (ConjNP and_Conj (BaseNP x y)) ;
|
||||
|
||||
--2 Type constructor
|
||||
|
||||
-- This is similar to a family except that the argument is a type.
|
||||
|
||||
typN2 f n = ComplN2 f (DetCN (DetPl (PlQuant IndefArt) NoNum NoOrd) n) ;
|
||||
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationIta of Predication = CatIta ** PredicationI with
|
||||
(Lang = LangIta) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationNor of Predication = CatNor ** PredicationI with
|
||||
(Lang = LangNor) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationSpa of Predication = CatSpa ** PredicationI with
|
||||
(Lang = LangSpa) ;
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
concrete PredicationSwe of Predication = CatSwe ** PredicationI with
|
||||
(Lang = LangSwe) ;
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
--1 Symbolic expressions
|
||||
|
||||
-- *Note*. This module is not automatically included in the main
|
||||
-- grammar [Lang Lang.html].
|
||||
|
||||
abstract Symbol = Cat, PredefAbs ** {
|
||||
|
||||
--2 Noun phrases with symbols and numbers
|
||||
|
||||
fun
|
||||
|
||||
SymbPN : Symb -> PN ; -- x
|
||||
IntPN : Int -> PN ; -- 27
|
||||
FloatPN : Float -> PN ; -- 3.14159
|
||||
CNIntNP : CN -> Int -> NP ; -- level 53
|
||||
CNSymbNP : Det -> CN -> [Symb] -> NP ; -- (the) (2) numbers x and y
|
||||
|
||||
--2 Symbol lists
|
||||
|
||||
-- A symbol list has at least two elements. The last two are separated
|
||||
-- by a conjunction ("and" in English), the others by commas.
|
||||
-- This produces "x, y and z", in English.
|
||||
|
||||
cat
|
||||
Symb ;
|
||||
[Symb]{2} ;
|
||||
|
||||
fun
|
||||
MkSymb : String -> Symb ;
|
||||
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
concrete SymbolEng of Symbol = CatEng ** open Prelude, ResEng in {
|
||||
|
||||
lin
|
||||
SymbPN i = {s = \\c => i.s ; a = agrP3 Sg} ; --- c
|
||||
IntPN i = {s = \\c => i.s ; a = agrP3 Sg} ; --- c
|
||||
FloatPN i = {s = \\c => i.s ; a = agrP3 Sg} ; --- c
|
||||
CNIntNP cn i = {
|
||||
s = \\c => (cn.s ! Sg ! Nom ++ i.s) ;
|
||||
a = agrP3 Sg
|
||||
} ;
|
||||
CNSymbNP det cn xs = {
|
||||
s = \\c => det.s ++ cn.s ! det.n ! c ++ xs.s ;
|
||||
a = agrP3 det.n
|
||||
} ;
|
||||
|
||||
lincat
|
||||
|
||||
Symb, [Symb] = SS ;
|
||||
|
||||
lin
|
||||
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS "and" ;
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
}
|
||||
@@ -1,31 +0,0 @@
|
||||
concrete SymbolFin of Symbol = CatFin ** open Prelude, NounFin, ResFin in {
|
||||
|
||||
lin
|
||||
SymbPN i = {s = \\c => i.s} ; --- c
|
||||
IntPN i = {s = \\c => i.s} ; --- c
|
||||
FloatPN i = {s = \\c => i.s} ; --- c
|
||||
|
||||
CNIntNP cn i = {
|
||||
s = \\c => cn.s ! NCase Sg (npform2case c) ++ i.s ;
|
||||
a = agrP3 Sg ;
|
||||
isPron = False
|
||||
} ;
|
||||
CNSymbNP det cn xs = let detcn = NounFin.DetCN det cn in {
|
||||
s = \\c => detcn.s ! c ++ xs.s ;
|
||||
a = detcn.a ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
lincat
|
||||
|
||||
Symb, [Symb] = SS ;
|
||||
|
||||
lin
|
||||
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS "ja" ;
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete SymbolFre of Symbol = CatFre ** SymbolRomance with
|
||||
(ResRomance = ResFre) ;
|
||||
@@ -1,31 +0,0 @@
|
||||
concrete SymbolGer of Symbol = CatGer ** open Prelude, ResGer in {
|
||||
|
||||
lin
|
||||
SymbPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
IntPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
FloatPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
|
||||
CNIntNP cn i = {
|
||||
s = \\c => cn.s ! Weak ! Sg ! Nom ++ i.s ;
|
||||
a = agrP3 Sg ;
|
||||
isPron = False
|
||||
} ;
|
||||
CNSymbNP det cn xs = let g = cn.g in {
|
||||
s = \\c => det.s ! g ! c ++ cn.s ! adjfCase det.a c ! det.n ! c ++ xs.s ;
|
||||
a = agrP3 det.n ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
lincat
|
||||
|
||||
Symb, [Symb] = SS ;
|
||||
|
||||
lin
|
||||
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS "und" ;
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete SymbolIta of Symbol = CatIta ** SymbolRomance with
|
||||
(ResRomance = ResIta) ;
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete SymbolNor of Symbol = CatNor ** SymbolScand with
|
||||
(ResScand = ResNor) ;
|
||||
@@ -1,31 +0,0 @@
|
||||
incomplete concrete SymbolRomance of Symbol =
|
||||
CatRomance ** open Prelude, CommonRomance, ResRomance in {
|
||||
|
||||
lin
|
||||
SymbPN i = {s = i.s ; g = Masc} ;
|
||||
IntPN i = {s = i.s ; g = Masc} ;
|
||||
FloatPN i = {s = i.s ; g = Masc} ;
|
||||
|
||||
CNIntNP cn i = {
|
||||
s = \\c => cn.s ! Sg ++ i.s ;
|
||||
a = agrP3 cn.g Sg ;
|
||||
hasClit = False
|
||||
} ;
|
||||
CNSymbNP det cn xs = let g = cn.g in {
|
||||
s = \\c => det.s ! g ! npform2case c ++ cn.s ! det.n ++ xs.s ;
|
||||
a = agrP3 g det.n ;
|
||||
hasClit = False
|
||||
} ;
|
||||
|
||||
lincat
|
||||
|
||||
Symb, [Symb] = SS ;
|
||||
|
||||
lin
|
||||
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS "et" ; ----
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
incomplete concrete SymbolScand of Symbol =
|
||||
CatScand ** open Prelude, ResScand, CommonScand in {
|
||||
|
||||
lin
|
||||
SymbPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
IntPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
FloatPN i = {s = \\c => i.s ; g = Neutr} ; --- c
|
||||
CNIntNP cn i = {
|
||||
s = \\c => (cn.s ! Sg ! DIndef ! Nom ++ i.s) ;
|
||||
a = agrP3 cn.g Sg
|
||||
} ;
|
||||
CNSymbNP det cn xs = let g = cn.g in {
|
||||
s = \\c => det.s ! cn.isMod ! g ++ cn.s ! det.n ! det.det ! caseNP c ++ xs.s ;
|
||||
a = agrP3 g det.n
|
||||
} ;
|
||||
|
||||
lincat
|
||||
|
||||
Symb, [Symb] = SS ;
|
||||
|
||||
lin
|
||||
|
||||
MkSymb s = s ;
|
||||
|
||||
BaseSymb = infixSS conjAnd ;
|
||||
ConsSymb = infixSS "," ;
|
||||
|
||||
}
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete SymbolSpa of Symbol = CatSpa ** SymbolRomance with
|
||||
(ResRomance = ResSpa) ;
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete SymbolSwe of Symbol = CatSwe ** SymbolScand with
|
||||
(ResScand = ResSwe) ;
|
||||
@@ -1,31 +0,0 @@
|
||||
resource DemRes = open Prelude in {
|
||||
|
||||
oper
|
||||
|
||||
Point : Type =
|
||||
{point : Str} ;
|
||||
|
||||
point : Point -> Str = \p ->
|
||||
p.point ;
|
||||
|
||||
mkPoint : Str -> Point = \s ->
|
||||
{point = s} ;
|
||||
|
||||
noPoint : Point =
|
||||
mkPoint [] ;
|
||||
|
||||
concatPoint : (x,y : Point) -> Point = \x,y ->
|
||||
mkPoint (point x ++ point y) ;
|
||||
|
||||
-- A type is made demonstrative by adding $Point$.
|
||||
|
||||
Dem : Type -> Type = \t -> t ** Point ;
|
||||
|
||||
mkDem : (t : Type) -> t -> Point -> Dem t = \_,x,s ->
|
||||
x ** s ;
|
||||
|
||||
nonDem : (t : Type) -> t -> Dem t = \t,x ->
|
||||
mkDem t x noPoint ;
|
||||
|
||||
|
||||
}
|
||||
@@ -1,88 +0,0 @@
|
||||
abstract Demonstrative = Cat, PredefAbs ** {
|
||||
|
||||
-- Naming convention: $M$ prepended to 'unimodal' names.
|
||||
-- Exceptions: lexical units, those without unimodal counterparts.
|
||||
|
||||
cat
|
||||
|
||||
MS ; -- multimodal sentence or question
|
||||
MQS ; -- multimodal wh question
|
||||
MImp ; -- multimodal imperative
|
||||
MVP ; -- multimodal verb phrase
|
||||
MComp ; -- multimodal complement to copula (MAP, MNP, MAdv)
|
||||
MAP ; -- multimodal adjectival phrase
|
||||
MNP ; -- multimodal (demonstrative) noun phrase
|
||||
MAdv ; -- multimodal (demonstrative) adverbial
|
||||
|
||||
Point ; -- pointing gesture
|
||||
|
||||
fun
|
||||
|
||||
-- A pointing gesture is constructed from a string.
|
||||
|
||||
MkPoint : String -> Point ;
|
||||
|
||||
-- Construction of sentences, questions, and imperatives.
|
||||
|
||||
MPredVP : MNP -> MVP -> MS ; -- he flies here
|
||||
MQPredVP : MNP -> MVP -> MQS ; -- does he fly here
|
||||
|
||||
MQuestVP : IP -> MVP -> MQS ; -- who flies here
|
||||
|
||||
MImpVP : MVP -> MImp ; -- fly here!
|
||||
|
||||
-- Construction of verb phrases from verb + complements.
|
||||
|
||||
MUseV : V -> MVP ; -- flies (here)
|
||||
MComplV2 : V2 -> MNP -> MVP ; -- takes this (here)
|
||||
MComplVV : VV -> MVP -> MVP ; -- wants to fly (here)
|
||||
|
||||
MUseComp : MComp -> MVP ; -- is here ; is bigger than this
|
||||
|
||||
MCompAP : MAP -> MComp ; -- bigger than this
|
||||
MCompNP : MNP -> MComp ; -- the price of this
|
||||
MCompAdv : MAdv -> MComp ; -- here
|
||||
|
||||
MPositA : A -> MAP ; -- big
|
||||
MComparA : A -> MNP -> MAP ; -- bigger than this
|
||||
|
||||
-- Adverbial modification of a verb phrase.
|
||||
|
||||
MAdvVP : MVP -> MAdv -> MVP ; -- fly here
|
||||
|
||||
-- Demonstrative pronouns as NPs and determiners.
|
||||
|
||||
this_MNP : Point -> MNP ; -- this
|
||||
that_MNP : Point -> MNP ; -- that
|
||||
thisDet_MNP : CN -> Point -> MNP ; -- this car
|
||||
thatDet_MNP : CN -> Point -> MNP ; -- that car
|
||||
|
||||
-- Demonstrative adverbs.
|
||||
|
||||
here_MAdv : Point -> MAdv ; -- here
|
||||
here7from_MAdv : Point -> MAdv ; -- from here
|
||||
here7to_MAdv : Point -> MAdv ; -- to here
|
||||
|
||||
-- Building an adverb as prepositional phrase.
|
||||
|
||||
MPrepNP : Prep -> MNP -> MAdv ; -- in this car
|
||||
|
||||
-- Using ordinary categories.
|
||||
|
||||
-- Mounting nondemonstrative expressions.
|
||||
|
||||
DemNP : NP -> MNP ;
|
||||
DemAdv : Adv -> MAdv ;
|
||||
|
||||
-- Top-level phrases.
|
||||
|
||||
PhrMS : Pol -> MS -> Phr ;
|
||||
PhrMS : Pol -> MS -> Phr ;
|
||||
PhrMQS : Pol -> MQS -> Phr ;
|
||||
PhrMImp : Pol -> MImp -> Phr ;
|
||||
|
||||
-- For testing and example-based grammar writing.
|
||||
|
||||
point1, point2 : Point ;
|
||||
|
||||
}
|
||||
@@ -1,4 +0,0 @@
|
||||
--# -path=.:../english/:../abstract:../common:prelude
|
||||
|
||||
concrete DemonstrativeEng of Demonstrative = CatEng ** DemonstrativeI with
|
||||
(Lang = LangEng) ;
|
||||
@@ -1,4 +0,0 @@
|
||||
--# -path=.:../finnish/:../abstract:../common:prelude
|
||||
|
||||
concrete DemonstrativeFin of Demonstrative = CatFin ** DemonstrativeI with
|
||||
(Lang = LangFin) ;
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete DemonstrativeFre of Demonstrative = CatFre ** DemonstrativeI with
|
||||
(Lang = LangFre) ;
|
||||
@@ -1,4 +0,0 @@
|
||||
--# -path=.:../german/:../abstract:../common:prelude
|
||||
|
||||
concrete DemonstrativeGer of Demonstrative = CatGer ** DemonstrativeI with
|
||||
(Lang = LangGer) ;
|
||||
@@ -1,106 +0,0 @@
|
||||
incomplete concrete DemonstrativeI of Demonstrative = Cat **
|
||||
open Prelude, Lang, ParamX, DemRes in {
|
||||
|
||||
flags optimize = all_subs ;
|
||||
|
||||
lincat
|
||||
|
||||
MS = Dem {s : Polarity => Str} ;
|
||||
MQS = Dem {s : Polarity => Str} ;
|
||||
MImp = Dem {s : Polarity => Str} ;
|
||||
MVP = Dem VP ;
|
||||
MComp = Dem Comp ;
|
||||
MAP = Dem AP ;
|
||||
MNP = Dem NP ;
|
||||
MAdv = Dem Adv ;
|
||||
|
||||
Point = DemRes.Point ;
|
||||
|
||||
lin
|
||||
|
||||
MkPoint s = mkPoint s.s ;
|
||||
|
||||
MPredVP np vp =
|
||||
let cl = PredVP np vp
|
||||
in
|
||||
mkDem
|
||||
{s : Polarity => Str}
|
||||
(polCases
|
||||
(UttS (UseCl TPres ASimul PPos cl))
|
||||
(UttS (UseCl TPres ASimul PNeg cl)))
|
||||
(concatPoint np vp) ;
|
||||
|
||||
MQPredVP np vp =
|
||||
let cl = QuestCl (PredVP np vp)
|
||||
in
|
||||
mkDem
|
||||
{s : Polarity => Str}
|
||||
(polCases
|
||||
(UttQS (UseQCl TPres ASimul PPos cl))
|
||||
(UttQS (UseQCl TPres ASimul PNeg cl)))
|
||||
(concatPoint np vp) ;
|
||||
|
||||
MQuestVP np vp =
|
||||
let cl = QuestVP np vp
|
||||
in
|
||||
mkDem
|
||||
{s : Polarity => Str}
|
||||
(polCases
|
||||
(UttQS (UseQCl TPres ASimul PPos cl))
|
||||
(UttQS (UseQCl TPres ASimul PNeg cl)))
|
||||
vp ;
|
||||
|
||||
MImpVP vp =
|
||||
let imp = ImpVP vp
|
||||
in
|
||||
mkDem
|
||||
{s : Polarity => Str}
|
||||
(polCases
|
||||
((UttImpSg PPos imp))
|
||||
((UttImpSg PNeg imp)))
|
||||
vp ;
|
||||
|
||||
|
||||
MUseV verb = mkDem VP (UseV verb) noPoint ;
|
||||
MComplV2 verb obj = mkDem VP (ComplV2 verb obj) obj ;
|
||||
MComplVV vv vp = mkDem VP (ComplVV vv vp) vp ;
|
||||
|
||||
MUseComp comp = mkDem VP (UseComp comp) comp ;
|
||||
|
||||
MCompAP ap = mkDem Comp (CompAP ap) ap ;
|
||||
MCompAdv adv = mkDem Comp (CompAdv adv) adv ;
|
||||
MCompNP np = mkDem Comp (CompNP np) np ;
|
||||
|
||||
MPositA a = mkDem AP (PositA a) noPoint ;
|
||||
MComparA a np = mkDem AP (ComparA a np) np ;
|
||||
|
||||
|
||||
MAdvVP vp adv =
|
||||
mkDem VP (AdvVP vp adv) (concatPoint vp adv) ;
|
||||
|
||||
this_MNP = mkDem NP this_NP ;
|
||||
that_MNP = mkDem NP that_NP ;
|
||||
|
||||
thisDet_MNP cn =
|
||||
mkDem NP (DetCN (DetSg (SgQuant this_Quant) NoOrd) cn) ;
|
||||
thatDet_MNP cn =
|
||||
mkDem NP (DetCN (DetSg (SgQuant that_Quant) NoOrd) cn) ;
|
||||
|
||||
here_MAdv = mkDem Adv here_Adv ;
|
||||
here7from_MAdv = mkDem Adv here7from_Adv ;
|
||||
here7to_MAdv = mkDem Adv here7to_Adv ;
|
||||
|
||||
MPrepNP p np = mkDem Adv (PrepNP p np) np ;
|
||||
|
||||
DemNP np = nonDem NP (np ** {lock_NP = <>}) ;
|
||||
DemAdv adv = nonDem Adv (adv ** {lock_Adv = <>}) ;
|
||||
|
||||
PhrMS pol ms = {s = pol.s ++ ms.s ! pol.p ++ ";" ++ ms.point} ;
|
||||
PhrMQS pol ms = {s = pol.s ++ ms.s ! pol.p ++ ";" ++ ms.point} ;
|
||||
PhrMImp pol ms = {s = pol.s ++ ms.s ! pol.p ++ ";" ++ ms.point} ;
|
||||
|
||||
point1 = mkPoint "p1" ;
|
||||
point2 = mkPoint "p2" ;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete DemonstrativeIta of Demonstrative = CatIta ** DemonstrativeI with
|
||||
(Lang = LangIta) ;
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete DemonstrativeNor of Demonstrative = CatNor ** DemonstrativeI with
|
||||
(Lang = LangNor) ;
|
||||
@@ -1,2 +0,0 @@
|
||||
concrete DemonstrativeSpa of Demonstrative = CatSpa ** DemonstrativeI with
|
||||
(Lang = LangSpa) ;
|
||||
@@ -1,4 +0,0 @@
|
||||
concrete DemonstrativeSwe of Demonstrative = CatSwe ** DemonstrativeI with
|
||||
(Lang = LangSwe) ;
|
||||
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
abstract Multimodal =
|
||||
Noun,
|
||||
-- Verb,
|
||||
Adjective,
|
||||
Adverb,
|
||||
Numeral,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
Structural,
|
||||
Demonstrative,
|
||||
Lexicon
|
||||
** {} ;
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalEng of Multimodal =
|
||||
NounEng,
|
||||
-- Verb,
|
||||
AdjectiveEng,
|
||||
AdverbEng,
|
||||
NumeralEng,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralEng,
|
||||
DemonstrativeEng,
|
||||
LexiconEng
|
||||
** {} ;
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalFin of Multimodal =
|
||||
NounFin,
|
||||
-- Verb,
|
||||
AdjectiveFin,
|
||||
AdverbFin,
|
||||
NumeralFin,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralFin,
|
||||
DemonstrativeFin,
|
||||
LexiconFin
|
||||
** {} ;
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalFre of Multimodal =
|
||||
NounFre,
|
||||
-- Verb,
|
||||
AdjectiveFre,
|
||||
AdverbFre,
|
||||
-- NumeralFre,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralFre,
|
||||
DemonstrativeFre,
|
||||
LexiconFre
|
||||
** {} ;
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalGer of Multimodal =
|
||||
NounGer,
|
||||
-- Verb,
|
||||
AdjectiveGer,
|
||||
AdverbGer,
|
||||
NumeralGer,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralGer,
|
||||
DemonstrativeGer,
|
||||
LexiconGer
|
||||
** {} ;
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalIta of Multimodal =
|
||||
NounIta,
|
||||
-- Verb,
|
||||
AdjectiveIta,
|
||||
AdverbIta,
|
||||
-- NumeralIta,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralIta,
|
||||
DemonstrativeIta,
|
||||
LexiconIta
|
||||
** {} ;
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalNor of Multimodal =
|
||||
NounNor,
|
||||
-- Verb,
|
||||
AdjectiveNor,
|
||||
AdverbNor,
|
||||
NumeralNor,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralNor,
|
||||
DemonstrativeNor,
|
||||
LexiconNor
|
||||
** {} ;
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalSpa of Multimodal =
|
||||
NounSpa,
|
||||
-- Verb,
|
||||
AdjectiveSpa,
|
||||
AdverbSpa,
|
||||
-- NumeralSpa,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralSpa,
|
||||
DemonstrativeSpa,
|
||||
LexiconSpa
|
||||
** {} ;
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
--# -path=.:../present:prelude
|
||||
|
||||
concrete MultimodalSwe of Multimodal =
|
||||
NounSwe,
|
||||
-- Verb,
|
||||
AdjectiveSwe,
|
||||
AdverbSwe,
|
||||
NumeralSwe,
|
||||
-- Sentence,
|
||||
-- Question,
|
||||
-- Relative,
|
||||
-- Conjunction,
|
||||
-- Phrase,
|
||||
-- Tensed,
|
||||
StructuralSwe,
|
||||
DemonstrativeSwe,
|
||||
LexiconSwe
|
||||
** {} ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:../scandinavian:../common:../abstract:../../prelude
|
||||
|
||||
concrete LexiconSwe of Lexicon = CatSwe ** open ParadigmsSwe in {
|
||||
concrete LexiconSwe of Lexicon = CatSwe ** open ParadigmsSwe, IrregSwe in {
|
||||
|
||||
flags
|
||||
optimize=values ;
|
||||
|
||||
Reference in New Issue
Block a user