mirror of
https://github.com/GrammaticalFramework/gf-rgl.git
synced 2026-05-27 08:58:55 -06:00
Compare commits
65 Commits
fix-somali
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fe56b729b4 | ||
|
|
cab232a4f6 | ||
|
|
cdeaf5a271 | ||
|
|
60e38122d0 | ||
|
|
800e2b0dda | ||
|
|
84bdce7cc8 | ||
|
|
add5029b7a | ||
|
|
19ba581f0e | ||
|
|
a890a1aad5 | ||
|
|
26a1e55cbe | ||
|
|
992e670c10 | ||
|
|
eea95a6f76 | ||
|
|
f1facac1bf | ||
|
|
c5bb0dacb5 | ||
|
|
44ea945c8c | ||
|
|
9265270a0c | ||
|
|
86e2afcfc0 | ||
|
|
6115d44398 | ||
|
|
cf6a376272 | ||
|
|
3a8527689c | ||
|
|
416d37eee7 | ||
|
|
c4d578cac3 | ||
|
|
a7341d9be1 | ||
|
|
57ef377e6d | ||
|
|
3a133d035d | ||
|
|
912ddd521f | ||
|
|
945bc086f2 | ||
|
|
70806027c1 | ||
|
|
88a3759a9e | ||
|
|
1910010e70 | ||
|
|
0cd851aa10 | ||
|
|
2b07314680 | ||
|
|
a3e19ed673 | ||
|
|
b571d86b7c | ||
|
|
6064e69d8e | ||
|
|
510abc0364 | ||
|
|
331a07bd35 | ||
|
|
34ba4cf564 | ||
|
|
5a9ab2cbdf | ||
|
|
97b8cb72aa | ||
|
|
09087c1944 | ||
|
|
f497b4a63a | ||
|
|
56e97ebfff | ||
|
|
16c19eb4b0 | ||
|
|
35f5d9a68b | ||
|
|
0f78e35bed | ||
|
|
bff00560d5 | ||
|
|
ba922b5daa | ||
|
|
f261b2f45b | ||
|
|
939e96fb6c | ||
|
|
3da5f0d318 | ||
|
|
37d915c879 | ||
|
|
b69c3518a7 | ||
|
|
0896a77049 | ||
|
|
7225033a03 | ||
|
|
ed27aa97fc | ||
|
|
de3d59c7e8 | ||
|
|
03024d7b72 | ||
|
|
f6187834c4 | ||
|
|
842747b407 | ||
|
|
fe2dde5a2c | ||
|
|
2adce20f76 | ||
|
|
b8a0e7adfe | ||
|
|
e4cf12ee1a | ||
|
|
943f387a23 |
@@ -15,7 +15,7 @@ concrete CatSqi of Cat = CommonX ** open ParamX,Prelude,ResSqi in {
|
||||
lincat Conj = {s : Str} ;
|
||||
lincat DAP = {s : Str} ;
|
||||
lincat Decimal = {s : Str; n : Number; hasDot : Bool} ;
|
||||
lincat Det = {s : Case => Gender => Str; spec : Species; n : Number} ;
|
||||
lincat Det = {s : Case => Gender => Str; sp : Species; n : Number} ;
|
||||
lincat Digits = {s : Str; n : Number; tail : DTail} ;
|
||||
lincat GN = {s : Str} ;
|
||||
lincat IComp = {s : Str} ;
|
||||
@@ -38,7 +38,7 @@ concrete CatSqi of Cat = CommonX ** open ParamX,Prelude,ResSqi in {
|
||||
lincat Pron = {s: Case => Str; acc_clit, dat_clit : Str; a : Agr} ;
|
||||
lincat QCl = {s : Str} ;
|
||||
lincat QS = {s : Str} ;
|
||||
lincat Quant = {s : Case => Gender => Number => Str; spec : Species} ;
|
||||
lincat Quant = {s : Case => Gender => Number => Str; sp : Species} ;
|
||||
lincat RCl = {s : Str} ;
|
||||
lincat RP = {s : Str} ;
|
||||
lincat RS = {s : Str} ;
|
||||
|
||||
@@ -4,7 +4,7 @@ concrete NounSqi of Noun = CatSqi ** open MorphoSqi, ResSqi in {
|
||||
|
||||
lin
|
||||
DetCN det cn = {
|
||||
s = \\c => det.s ! c ! cn.g ++ cn.s ! det.spec ! c ! det.n ;
|
||||
s = \\c => det.s ! c ! cn.g ++ cn.s ! det.sp ! c ! det.n ;
|
||||
a = agrgP3 cn.g det.n
|
||||
} ;
|
||||
|
||||
@@ -13,7 +13,7 @@ concrete NounSqi of Noun = CatSqi ** open MorphoSqi, ResSqi in {
|
||||
DetQuant quant num = {
|
||||
s = \\c,g => quant.s ! c ! g ! num.n ++ num.s ;
|
||||
n = num.n ;
|
||||
spec = quant.spec
|
||||
sp = quant.sp
|
||||
} ;
|
||||
|
||||
NumSg = {s = []; n = Sg} ;
|
||||
@@ -21,12 +21,12 @@ concrete NounSqi of Noun = CatSqi ** open MorphoSqi, ResSqi in {
|
||||
|
||||
DefArt = {
|
||||
s = \\c,g,n => [] ;
|
||||
spec = Def
|
||||
sp = Def
|
||||
} ;
|
||||
|
||||
IndefArt = {
|
||||
s = \\c,g => table Number ["një"; []] ;
|
||||
spec = Indef
|
||||
sp = Indef
|
||||
} ;
|
||||
|
||||
UseN n = n ;
|
||||
|
||||
@@ -1327,7 +1327,7 @@ oper mkQuant : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Quant =
|
||||
}
|
||||
}
|
||||
} ;
|
||||
spec = Indef
|
||||
sp = Indef
|
||||
} ;
|
||||
|
||||
oper mkDet : (_,_,_,_,_,_,_,_ : Str) -> Number -> Det =
|
||||
@@ -1350,7 +1350,7 @@ oper mkDet : (_,_,_,_,_,_,_,_ : Str) -> Number -> Det =
|
||||
Fem => f8
|
||||
}
|
||||
} ;
|
||||
spec = Indef ;
|
||||
sp = Indef ;
|
||||
n = n
|
||||
} ;
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
concrete AllBel of AllBelAbs =
|
||||
LangBel
|
||||
LangBel,
|
||||
ExtendBel
|
||||
**
|
||||
{} ;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
abstract AllBelAbs =
|
||||
Lang
|
||||
Lang,
|
||||
Extend
|
||||
** {}
|
||||
@@ -3,12 +3,13 @@ concrete CatBel of Cat = CommonX ** open ResBel in {
|
||||
lincat N = Noun ;
|
||||
lincat N2 = Noun ** {c2 : Compl} ;
|
||||
lincat N3 = Noun ** {c2,c3 : Compl} ;
|
||||
lincat V = V ;
|
||||
lincat VV,VS,VQ,VA = V ;
|
||||
lincat V2 = V ** {c2 : Compl} ;
|
||||
lincat V3,V2A,V2S,V2Q,V2V = V ** {c2,c3 : Compl} ;
|
||||
lincat A = A ;
|
||||
lincat A2 = A ** {c2 : Compl} ;
|
||||
lincat Pron = {s: Case => Str; g: Gender; n : Number; p: Person} ;
|
||||
lincat V = Verb ;
|
||||
lincat VV,VS,VQ,VA = Verb ;
|
||||
lincat V2 = Verb ** {c2 : Compl} ;
|
||||
lincat V3,V2A,V2S,V2Q,V2V = Verb ** {c2,c3 : Compl} ;
|
||||
lincat A = Adj ;
|
||||
lincat A2 = Adj ** {c2 : Compl} ;
|
||||
lincat Prep = Compl ;
|
||||
lincat CN = CommonNoun ;
|
||||
lincat AP = AdjPhrase ;
|
||||
|
||||
@@ -29,12 +29,12 @@ lin
|
||||
paragraph (x.infinitive) ++
|
||||
heading1 "Present" ++
|
||||
frameTable (
|
||||
tr (intagAttr "th" "rowspan=\"6\"" "Pres" ++ intagAttr "th" "rowspan=\"2\"" "P1" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P1 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P1 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P2" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P2 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P2 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P3" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P3 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P3 ! Pl))) ++
|
||||
tr (intagAttr "th" "rowspan=\"6\"" "Pres" ++ intagAttr "th" "rowspan=\"2\"" "P1" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P1 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P1 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P2" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P2 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P2 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P3" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P3 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P3 ! Pl))) ++
|
||||
heading1 "Imperative" ++
|
||||
frameTable (
|
||||
tr (th "Sg" ++ td (x.imperative ! Sg)) ++
|
||||
|
||||
15
src/belarusian/ExtendBel.gf
Normal file
15
src/belarusian/ExtendBel.gf
Normal file
@@ -0,0 +1,15 @@
|
||||
--# -path=.:../abstract:../common:prelude
|
||||
concrete ExtendBel of Extend = CatBel ** open ResBel, ParadigmsBel in {
|
||||
|
||||
lin
|
||||
iFem_Pron = mkPron "я" "мяне" "мне" "мяне" "мне" "мной" Fem Sg P1 ;
|
||||
youFem_Pron = mkPron "ты" "табе" "табе" "табе" "табе" "табой" Fem Sg P2 ;
|
||||
weFem_Pron = mkPron "мы" "нас" "нам" "нас" "наc" "намі" Fem Pl P1 ;
|
||||
youPlFem_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Fem Pl P2 ;
|
||||
theyFem_Pron = mkPron "вони" "їх" "їм" "їх" "них" "ними" Fem Pl P3 ;
|
||||
youPolFem_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Fem Pl P2 ;
|
||||
youPolPl_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Fem Pl P2 ;
|
||||
youPolPlFem_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Fem Pl P2 ;
|
||||
|
||||
}
|
||||
|
||||
@@ -2,5 +2,6 @@ concrete GrammarBel of Grammar =
|
||||
TenseX,
|
||||
PhraseBel,
|
||||
NounBel,
|
||||
AdjectiveBel ** {
|
||||
AdjectiveBel,
|
||||
StructuralBel ** {
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -636,6 +636,44 @@ oper
|
||||
_ => regN form1
|
||||
} ;
|
||||
|
||||
compoundN = overload {
|
||||
compoundN : A -> N -> N = \a,n -> lin N {
|
||||
s = \\c,num => a.s ! c ! genNum n.g num ++ n.s ! c ! num ;
|
||||
voc = a.s ! Nom ! genNum n.g Sg ++ n.voc ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : N -> A -> N = \n,a -> lin N {
|
||||
s = \\c,num => n.s ! c ! num ++ a.s ! c ! genNum n.g num ;
|
||||
voc = n.voc ++ a.s ! Nom ! genNum n.g Sg ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : N -> Str -> N = \n,adv -> lin N {
|
||||
s = \\c,num => n.s ! c ! num ++ adv ;
|
||||
voc = n.voc ++ adv ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : Str -> N -> N = \adv,n -> lin N {
|
||||
s = \\c,num => adv ++ n.s ! c ! num ;
|
||||
voc = adv ++ n.voc ;
|
||||
g = n.g
|
||||
}
|
||||
} ;
|
||||
|
||||
mkPron : (_,_,_,_,_,_ : Str) -> Gender -> Number -> Person -> Pron =
|
||||
\nom,acc,dat,gen,loc,instr,g,n,p -> lin Pron {
|
||||
s = table {
|
||||
Nom => nom ;
|
||||
Acc => acc ;
|
||||
Dat => dat ;
|
||||
Gen => gen ;
|
||||
Loc => loc ;
|
||||
Instr => instr
|
||||
} ;
|
||||
g = g ;
|
||||
n = n ;
|
||||
p = p
|
||||
} ;
|
||||
|
||||
regV : Str -> V -- infinitive
|
||||
= \form -> case form of {
|
||||
_ + "агчы" => mkV021 form;
|
||||
@@ -717,6 +755,16 @@ oper
|
||||
_ => regV form1
|
||||
} ;
|
||||
|
||||
compoundV : V -> Str -> V = \v,adv -> lin V {
|
||||
active = \\a => {past=(v.active ! a).past ++ adv ;
|
||||
pres=\\p,num=>(v.active ! a).pres ! p ! num ++ adv
|
||||
} ;
|
||||
imperative = \\num => v.imperative ! num ++ adv ;
|
||||
infinitive = v.infinitive ++ adv ;
|
||||
participle = \\g,num => v.participle ! g ! num ++ adv ;
|
||||
passive = \\a,t => v.passive ! a ! t ++ adv
|
||||
} ;
|
||||
|
||||
regA : Str -> A -- s;Nom;('GSg', Masc)
|
||||
= \form -> case form of {
|
||||
_ + "які" => mkA006 form;
|
||||
|
||||
@@ -40,12 +40,12 @@ oper mkNoun : (_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Gender -> Noun =
|
||||
param Aspect = Imperf | Perf ;
|
||||
param Person = P1 | P2 | P3 ;
|
||||
param Tense = Pres | Past ;
|
||||
oper V = {active: Aspect => {Past: Str; Pres: Person => Number => Str}; imperative: Number => Str; infinitive: Str; participle: Gender => Number => Str; passive: Aspect => Tense => Str} ; -- 703
|
||||
oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V =
|
||||
oper Verb = {active: Aspect => {past: Str; pres: Person => Number => Str}; imperative: Number => Str; infinitive: Str; participle: Gender => Number => Str; passive: Aspect => Tense => Str} ; -- 703
|
||||
oper mkVerb : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Verb =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14,f15,f16,f17,f18,f19,f20,f21,f22,f23,f24,f25,f26,f27 ->
|
||||
{ active = table {
|
||||
Imperf => { Past = f1 ;
|
||||
Pres = table {
|
||||
Imperf => { past = f1 ;
|
||||
pres = table {
|
||||
P1 => table {
|
||||
Sg => f2 ;
|
||||
Pl => f3
|
||||
@@ -60,8 +60,8 @@ oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V =
|
||||
}
|
||||
}
|
||||
} ;
|
||||
Perf => { Past = f8 ;
|
||||
Pres = table {
|
||||
Perf => { past = f8 ;
|
||||
pres = table {
|
||||
P1 => table {
|
||||
Sg => f9 ;
|
||||
Pl => f10
|
||||
@@ -110,8 +110,14 @@ oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V =
|
||||
|
||||
|
||||
param GenNum = GSg Gender | GPl ;
|
||||
oper A = {s: Case => GenNum => Str} ; -- 704
|
||||
oper mkA : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> A =
|
||||
oper genNum : Gender -> Number -> GenNum = \g,n ->
|
||||
case n of {
|
||||
Sg => GSg g ;
|
||||
Pl => GPl
|
||||
} ;
|
||||
|
||||
oper Adj = {s: Case => GenNum => Str} ; -- 704
|
||||
oper mkAdj : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Adj =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14,f15,f16,f17,f18,f19,f20,f21,f22,f23,f24 ->
|
||||
{ s = table {
|
||||
Nom => table {
|
||||
@@ -158,6 +164,6 @@ oper Compl = {s : Str; c : Case} ;
|
||||
oper noPrep : Compl = {s=""; c=Acc} ;
|
||||
|
||||
oper CommonNoun = Noun ;
|
||||
oper AdjPhrase = A ;
|
||||
oper AdjPhrase = Adj ;
|
||||
|
||||
}
|
||||
|
||||
12
src/belarusian/StructuralBel.gf
Normal file
12
src/belarusian/StructuralBel.gf
Normal file
@@ -0,0 +1,12 @@
|
||||
concrete StructuralBel of Structural = CatBel ** open ResBel, ParadigmsBel in {
|
||||
lin
|
||||
i_Pron = mkPron "я" "мяне" "мне" "мяне" "мне" "мной" Masc Sg P1 ;
|
||||
youSg_Pron = mkPron "ты" "табе" "табе" "табе" "табе" "табой" Masc Sg P2 ;
|
||||
he_Pron = mkPron "ён" "яго" "яму" "яго" "ім" "ім" Masc Sg P3 ;
|
||||
she_Pron = mkPron "яна" "яе" "ёй" "яе" "ёй" "ёю" Fem Sg P3 ;
|
||||
it_Pron = mkPron "яно" "яго" "яму" "яго" "ім" "ім" Neuter Sg P3 ;
|
||||
we_Pron = mkPron "мы" "нас" "нам" "нас" "наc" "намі" Masc Pl P1 ;
|
||||
youPl_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Masc Pl P2 ;
|
||||
youPol_Pron = mkPron "вы" "вас" "вам" "вас" "вас" "вамі" Masc Pl P2 ;
|
||||
they_Pron = mkPron "яны" "іх" "їм" "їх" "іх" "імі" Masc Pl P3 ;
|
||||
}
|
||||
@@ -1,4 +1,7 @@
|
||||
concrete AdjectiveFao of Adjective = CatFao ** {
|
||||
concrete AdjectiveFao of Adjective = CatFao ** open ResFao in {
|
||||
lin
|
||||
PositA a = a ;
|
||||
ComparA a np = {
|
||||
s = \\g,n,c => "meir" ++ a.s ! g ! n ! c ++ "enn" ++ np.s ! Nom
|
||||
} ;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
concrete AllFao of AllFaoAbs =
|
||||
LangFao
|
||||
LangFao,
|
||||
ExtendFao
|
||||
**
|
||||
{} ;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
abstract AllFaoAbs =
|
||||
Lang
|
||||
Lang,
|
||||
Extend
|
||||
** {}
|
||||
@@ -9,9 +9,20 @@ lincat V = Verb ;
|
||||
lincat VV,VS,VQ,VA = Verb ;
|
||||
lincat V2 = Verb ** {c2 : Compl} ;
|
||||
lincat V3,V2A,V2S,V2Q,V2V = Verb ** {c2,c3 : Compl} ;
|
||||
lincat VP = VerbPhrase ;
|
||||
lincat VPSlash = Verb ** {c2 : Compl} ;
|
||||
lincat Comp = {s : Gender => Number => Str} ;
|
||||
lincat Cl = Clause ;
|
||||
lincat Prep = Compl ;
|
||||
lincat CN = CommonNoun ;
|
||||
lincat NP, Pron = {s : Case => Str ; g : Gender ; n : Number ; p : Person} ;
|
||||
lincat RCl = {s : Tense => Polarity => Gender => PersNum => Str} ;
|
||||
lincat RS = {s : Gender => PersNum => Str} ;
|
||||
lincat RP = {s : Str} ;
|
||||
lincat AP = AdjPhrase ;
|
||||
lincat Det = {s : Gender => Case => Str ; n : Number ; sp : Species} ;
|
||||
lincat Quant = {s : Gender => Number => Case => Str ; sp : Species} ;
|
||||
lincat Num = {s : Gender => Case => Str ; n : Number} ;
|
||||
lincat S = {s : Str} ;
|
||||
|
||||
lincat LN,SN,GN,PN = {s : Str} ;
|
||||
|
||||
@@ -55,8 +55,8 @@ lin
|
||||
paragraph x.Converb ++
|
||||
heading2 "Imperative" ++
|
||||
frameTable (
|
||||
tr (th "Sg" ++ td (x.Imperative_Jussive ! Sg)) ++
|
||||
tr (th "Pl" ++ td (x.Imperative_Jussive ! Pl))) ++
|
||||
tr (th "Sg" ++ td (x.imperative ! Sg)) ++
|
||||
tr (th "Pl" ++ td (x.imperative ! Pl))) ++
|
||||
heading2 "Indicative" ++
|
||||
frameTable (
|
||||
tr (intagAttr "th" "rowspan=\"4\"" "Pres" ++ th "Sg P1" ++ td (x.Indicative ! Pres ! PSg P1)) ++
|
||||
|
||||
13
src/faroese/ExtendFao.gf
Normal file
13
src/faroese/ExtendFao.gf
Normal file
@@ -0,0 +1,13 @@
|
||||
concrete ExtendFao of Extend = CatFao **
|
||||
open ParadigmsFao, ResFao in {
|
||||
|
||||
lin
|
||||
iFem_Pron = mkPron "eg" "meg" "mær" "mín" Masc Sg P1 ;
|
||||
youFem_Pron = mkPron "tú" "teg" "tær" "tín" Masc Sg P2 ;
|
||||
weFem_Pron = mkPron "vit" "okkum" "okkum" "okkara" Masc Pl P1 ;
|
||||
youPlFem_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
theyFem_Pron = mkPron "tær" "tær" "teimum" "teirra" Masc Pl P3 ;
|
||||
youPolFem_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
youPolPl_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
youPolPlFem_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
}
|
||||
@@ -2,5 +2,9 @@ concrete GrammarFao of Grammar =
|
||||
TenseX,
|
||||
PhraseFao,
|
||||
NounFao,
|
||||
AdjectiveFao ** {
|
||||
VerbFao,
|
||||
AdjectiveFao,
|
||||
SentenceFao,
|
||||
RelativeFao,
|
||||
StructuralFao ** {
|
||||
}
|
||||
@@ -1,2 +1,9 @@
|
||||
concrete LexiconFao of Lexicon = CatFao ** open ParadigmsFao in {
|
||||
concrete LexiconFao of Lexicon = CatFao ** open ParadigmsFao, ResFao in {
|
||||
lin
|
||||
apple_N = mkN "epli" ;
|
||||
big_A = mkA "stórur" ;
|
||||
child_N = mkN "barn" ;
|
||||
die_V = mkV "doyggja" "doyrt" ;
|
||||
good_A = mkA "góður" ;
|
||||
go_V = mkVerb "farið" "far" "farið" "fari" "fert" "fer" "fara" "fór" "fórt" "fór" "fóru" "fara" "farandi" "farin" ;
|
||||
}
|
||||
@@ -8769,7 +8769,7 @@ mkV001 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a" ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -8802,7 +8802,7 @@ mkV002 base =
|
||||
case base of {
|
||||
"ei"+base_1+"a" => lin V
|
||||
{ Converb = "hi"+base_1+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "ei"+base_1 ;
|
||||
Pl => "ei"+base_1+"ið"
|
||||
} ;
|
||||
@@ -8835,7 +8835,7 @@ mkV003 base =
|
||||
case base of {
|
||||
"a"+base_1+"a" => lin V
|
||||
{ Converb = "i"+base_1+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "a"+base_1 ;
|
||||
Pl => "a"+base_1+"ið"
|
||||
} ;
|
||||
@@ -8868,7 +8868,7 @@ mkV004 base =
|
||||
case base of {
|
||||
"a"+base_1+"a" => lin V
|
||||
{ Converb = "a"+base_1+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "a"+base_1 ;
|
||||
Pl => "a"+base_1+"ið"
|
||||
} ;
|
||||
@@ -8901,7 +8901,7 @@ mkV005 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@(?+?) => lin V
|
||||
{ Converb = base_1+"a"+base_2 ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -8934,7 +8934,7 @@ mkV006 base =
|
||||
case base of {
|
||||
base_1+"ða" => lin V
|
||||
{ Converb = base_1+"tt" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ð" ;
|
||||
Pl => base_1+"ðið"
|
||||
} ;
|
||||
@@ -8967,7 +8967,7 @@ mkV007 base =
|
||||
case base of {
|
||||
"eiga" => lin V
|
||||
{ Converb = "átt" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "eig" ;
|
||||
Pl => "eigið"
|
||||
} ;
|
||||
@@ -9000,7 +9000,7 @@ mkV008 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9033,7 +9033,7 @@ mkV009 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9066,7 +9066,7 @@ mkV010 base =
|
||||
case base of {
|
||||
base_1+"da" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"d" ;
|
||||
Pl => base_1+"dið"
|
||||
} ;
|
||||
@@ -9099,7 +9099,7 @@ mkV011 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"j" ;
|
||||
Pl => base_1+"e"+base_2+"jið"
|
||||
} ;
|
||||
@@ -9132,7 +9132,7 @@ mkV012 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2 ;
|
||||
Pl => base_1+"i"+base_2+"jið"
|
||||
} ;
|
||||
@@ -9165,7 +9165,7 @@ mkV013 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"da" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"dið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2+"d" ;
|
||||
Pl => base_1+"i"+base_2+"dið"
|
||||
} ;
|
||||
@@ -9198,7 +9198,7 @@ mkV014 base =
|
||||
case base of {
|
||||
base_1+"í"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"í"+base_2 ;
|
||||
Pl => base_1+"í"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9231,7 +9231,7 @@ mkV015 base =
|
||||
case base of {
|
||||
base_1+"jó"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"jó"+base_2 ;
|
||||
Pl => base_1+"jó"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9264,7 +9264,7 @@ mkV016 base =
|
||||
case base of {
|
||||
base_1+"gja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"g" ;
|
||||
Pl => base_1+"gið"
|
||||
} ;
|
||||
@@ -9297,7 +9297,7 @@ mkV017 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"na" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"nið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"n" ;
|
||||
Pl => base_1+"e"+base_2+"nið"
|
||||
} ;
|
||||
@@ -9330,7 +9330,7 @@ mkV018 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@("m"|(?+?))+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9363,7 +9363,7 @@ mkV019 base =
|
||||
case base of {
|
||||
base_1+"ó"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ó"+base_2 ;
|
||||
Pl => base_1+"ó"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9396,7 +9396,7 @@ mkV020 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9429,7 +9429,7 @@ mkV021 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a" ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9462,7 +9462,7 @@ mkV022 base =
|
||||
case base of {
|
||||
base_1+"úgva" => lin V
|
||||
{ Converb = base_1+"úð" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"úgv" ;
|
||||
Pl => base_1+"úgvið"
|
||||
} ;
|
||||
@@ -9495,7 +9495,7 @@ mkV023 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9528,7 +9528,7 @@ mkV024 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+base_3@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+base_3+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+base_3 ;
|
||||
Pl => base_1+"e"+base_2+base_3+"ið"
|
||||
} ;
|
||||
@@ -9561,7 +9561,7 @@ mkV025 base =
|
||||
case base of {
|
||||
base_1+"ggja" => lin V
|
||||
{ Converb = base_1+"ð" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ggj" ;
|
||||
Pl => base_1+"ggið"
|
||||
} ;
|
||||
@@ -9594,7 +9594,7 @@ mkV026 base =
|
||||
case base of {
|
||||
base_1+"aga" => lin V
|
||||
{ Converb = base_1+"igið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ag" ;
|
||||
Pl => base_1+"agið"
|
||||
} ;
|
||||
@@ -9627,7 +9627,7 @@ mkV027 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"ka" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"kið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"k" ;
|
||||
Pl => base_1+"e"+base_2+"kið"
|
||||
} ;
|
||||
@@ -9660,7 +9660,7 @@ mkV028 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9693,7 +9693,7 @@ mkV029 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a" ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9726,7 +9726,7 @@ mkV030 base =
|
||||
case base of {
|
||||
"ve"+base_1+"a" => lin V
|
||||
{ Converb = "ve"+base_1+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "ve"+base_1 ;
|
||||
Pl => "ve"+base_1+"ið"
|
||||
} ;
|
||||
@@ -9759,7 +9759,7 @@ mkV031 base =
|
||||
case base of {
|
||||
base_1+"na" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"na" ;
|
||||
Pl => base_1+"nið"
|
||||
} ;
|
||||
@@ -9792,7 +9792,7 @@ mkV032 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@(?+?)+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9825,7 +9825,7 @@ mkV033 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -9858,7 +9858,7 @@ mkV034 base =
|
||||
case base of {
|
||||
base_1+"áa" => lin V
|
||||
{ Converb = base_1+"ingið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"á" ;
|
||||
Pl => base_1+"áið"
|
||||
} ;
|
||||
@@ -9891,7 +9891,7 @@ mkV035 base =
|
||||
case base of {
|
||||
base_1+"la" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"la" ;
|
||||
Pl => base_1+"lið"
|
||||
} ;
|
||||
@@ -9924,7 +9924,7 @@ mkV036 base =
|
||||
case base of {
|
||||
base_1+"ða"+base_2@(?+?) => lin V
|
||||
{ Converb = base_1+"da"+base_2 ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -9957,7 +9957,7 @@ mkV037 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1 ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -9990,7 +9990,7 @@ mkV038 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10023,7 +10023,7 @@ mkV039 base =
|
||||
case base of {
|
||||
base_1+"na" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"n" ;
|
||||
Pl => base_1+"nið"
|
||||
} ;
|
||||
@@ -10056,7 +10056,7 @@ mkV040 base =
|
||||
case base of {
|
||||
base_1+"ú"+base_2@?+"va" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ú"+base_2 ;
|
||||
Pl => base_1+"ú"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10089,7 +10089,7 @@ mkV041 base =
|
||||
case base of {
|
||||
base_1+"y"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"y"+base_2 ;
|
||||
Pl => base_1+"y"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10122,7 +10122,7 @@ mkV042 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"jið"
|
||||
} ;
|
||||
@@ -10155,7 +10155,7 @@ mkV043 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"tt" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -10188,7 +10188,7 @@ mkV044 base =
|
||||
case base of {
|
||||
base_1+"ú"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ú"+base_2 ;
|
||||
Pl => base_1+"ú"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10221,7 +10221,7 @@ mkV045 base =
|
||||
case base of {
|
||||
base_1+"la" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"l" ;
|
||||
Pl => base_1+"lið"
|
||||
} ;
|
||||
@@ -10254,7 +10254,7 @@ mkV046 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10287,7 +10287,7 @@ mkV047 base =
|
||||
case base of {
|
||||
base_1+"anga" => lin V
|
||||
{ Converb = base_1+"ingið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"akk" ;
|
||||
Pl => base_1+"angið"
|
||||
} ;
|
||||
@@ -10320,7 +10320,7 @@ mkV048 base =
|
||||
case base of {
|
||||
base_1+"ja"+base_2@?+"da" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"dið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ja"+base_2+"d" ;
|
||||
Pl => base_1+"ja"+base_2+"dið"
|
||||
} ;
|
||||
@@ -10353,7 +10353,7 @@ mkV049 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"jø"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10386,7 +10386,7 @@ mkV050 base =
|
||||
case base of {
|
||||
base_1+"jó"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"jó"+base_2 ;
|
||||
Pl => base_1+"jó"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10419,7 +10419,7 @@ mkV051 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"pa" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"pið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"p" ;
|
||||
Pl => base_1+"e"+base_2+"pið"
|
||||
} ;
|
||||
@@ -10452,7 +10452,7 @@ mkV052 base =
|
||||
case base of {
|
||||
base_1+"y"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"y"+base_2 ;
|
||||
Pl => base_1+"y"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10485,7 +10485,7 @@ mkV053 base =
|
||||
case base of {
|
||||
base_1+"á"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"á"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"á"+base_2 ;
|
||||
Pl => base_1+"á"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10518,7 +10518,7 @@ mkV054 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10551,7 +10551,7 @@ mkV055 base =
|
||||
case base of {
|
||||
base_1+"ógva" => lin V
|
||||
{ Converb = base_1+"óð" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ógv" ;
|
||||
Pl => base_1+"ógvið"
|
||||
} ;
|
||||
@@ -10584,7 +10584,7 @@ mkV056 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"da" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"dið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2+"d" ;
|
||||
Pl => base_1+"a"+base_2+"dið"
|
||||
} ;
|
||||
@@ -10617,7 +10617,7 @@ mkV057 base =
|
||||
case base of {
|
||||
base_1+"anga" => lin V
|
||||
{ Converb = base_1+"ingið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ang" ;
|
||||
Pl => base_1+"angið"
|
||||
} ;
|
||||
@@ -10650,7 +10650,7 @@ mkV058 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10683,7 +10683,7 @@ mkV059 base =
|
||||
case base of {
|
||||
base_1+"ei"+base_2@(?+?)+"ja" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ei"+base_2+"j" ;
|
||||
Pl => base_1+"ei"+base_2+"jið"
|
||||
} ;
|
||||
@@ -10716,7 +10716,7 @@ mkV060 base =
|
||||
case base of {
|
||||
base_1+"vø"+base_2@(?+?)+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"vø"+base_2 ;
|
||||
Pl => base_1+"vø"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10749,7 +10749,7 @@ mkV061 base =
|
||||
case base of {
|
||||
base_1+"y"+base_2@?+"gja" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"y"+base_2+"g" ;
|
||||
Pl => base_1+"y"+base_2+"gið"
|
||||
} ;
|
||||
@@ -10782,7 +10782,7 @@ mkV062 base =
|
||||
case base of {
|
||||
base_1+"o"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"o"+base_2 ;
|
||||
Pl => base_1+"o"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10815,7 +10815,7 @@ mkV063 base =
|
||||
case base of {
|
||||
base_1+"pa" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"p" ;
|
||||
Pl => base_1+"pið"
|
||||
} ;
|
||||
@@ -10848,7 +10848,7 @@ mkV064 base =
|
||||
case base of {
|
||||
base_1+"úgva" => lin V
|
||||
{ Converb = base_1+"ovið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"úg" ;
|
||||
Pl => base_1+"úgið"
|
||||
} ;
|
||||
@@ -10881,7 +10881,7 @@ mkV065 base =
|
||||
case base of {
|
||||
base_1+"u"+base_2@?+"na" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"nað" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -10914,7 +10914,7 @@ mkV066 base =
|
||||
case base of {
|
||||
base_1+"ø"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"ø"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ø"+base_2 ;
|
||||
Pl => base_1+"ø"+base_2+"ið"
|
||||
} ;
|
||||
@@ -10947,7 +10947,7 @@ mkV067 base =
|
||||
case base of {
|
||||
base_1+"sa" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"s" ;
|
||||
Pl => base_1+"sið"
|
||||
} ;
|
||||
@@ -10980,7 +10980,7 @@ mkV068 base =
|
||||
case base of {
|
||||
base_1+"a" => lin V
|
||||
{ Converb = base_1+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -11013,7 +11013,7 @@ mkV069 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"gja" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"gj" ;
|
||||
Pl => base_1+"e"+base_2+"gjið"
|
||||
} ;
|
||||
@@ -11046,7 +11046,7 @@ mkV070 base =
|
||||
case base of {
|
||||
base_1+"iggja" => lin V
|
||||
{ Converb = base_1+"igið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"igg" ;
|
||||
Pl => base_1+"iggið"
|
||||
} ;
|
||||
@@ -11079,7 +11079,7 @@ mkV071 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11112,7 +11112,7 @@ mkV072 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11145,7 +11145,7 @@ mkV073 base =
|
||||
case base of {
|
||||
base_1+"á"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"á"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"á"+base_2 ;
|
||||
Pl => base_1+"á"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11178,7 +11178,7 @@ mkV074 base =
|
||||
case base of {
|
||||
base_1+"ey"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ey"+base_2 ;
|
||||
Pl => base_1+"ey"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11211,7 +11211,7 @@ mkV075 base =
|
||||
case base of {
|
||||
base_1+"ega" => lin V
|
||||
{ Converb = nonExist ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -11244,7 +11244,7 @@ mkV076 base =
|
||||
case base of {
|
||||
base_1+"u"+base_2@?+"na" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"nað" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -11277,7 +11277,7 @@ mkV077 base =
|
||||
case base of {
|
||||
base_1+"ja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -11310,7 +11310,7 @@ mkV078 base =
|
||||
case base of {
|
||||
base_1+"ja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"jið"
|
||||
} ;
|
||||
@@ -11343,7 +11343,7 @@ mkV079 base =
|
||||
case base of {
|
||||
base_1+"ða" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ð" ;
|
||||
Pl => base_1+"ðið"
|
||||
} ;
|
||||
@@ -11376,7 +11376,7 @@ mkV080 base =
|
||||
case base of {
|
||||
base_1+"áa" => lin V
|
||||
{ Converb = base_1+"átt" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"á" ;
|
||||
Pl => base_1+"áið"
|
||||
} ;
|
||||
@@ -11409,7 +11409,7 @@ mkV081 base =
|
||||
case base of {
|
||||
base_1+"áða" => lin V
|
||||
{ Converb = base_1+"átt" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"áð" ;
|
||||
Pl => base_1+"áðið"
|
||||
} ;
|
||||
@@ -11442,7 +11442,7 @@ mkV082 base =
|
||||
case base of {
|
||||
base_1+"ða"+base_2@(?+?) => lin V
|
||||
{ Converb = base_1+"ð"+base_2 ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -11475,7 +11475,7 @@ mkV083 base =
|
||||
case base of {
|
||||
base_1+"ø"+base_2@?+"ka" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"kið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ø"+base_2+"k" ;
|
||||
Pl => base_1+"ø"+base_2+"kið"
|
||||
} ;
|
||||
@@ -11508,7 +11508,7 @@ mkV084 base =
|
||||
case base of {
|
||||
base_1+"íggja" => lin V
|
||||
{ Converb = base_1+"æð" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"íggj" ;
|
||||
Pl => base_1+"íggið"
|
||||
} ;
|
||||
@@ -11541,7 +11541,7 @@ mkV085 base =
|
||||
case base of {
|
||||
base_1+"kja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"k" ;
|
||||
Pl => base_1+"kið"
|
||||
} ;
|
||||
@@ -11574,7 +11574,7 @@ mkV086 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2 ;
|
||||
Pl => base_1+"i"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11607,7 +11607,7 @@ mkV087 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2 ;
|
||||
Pl => base_1+"i"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11640,7 +11640,7 @@ mkV088 base =
|
||||
case base of {
|
||||
base_1+"u"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -11673,7 +11673,7 @@ mkV089 base =
|
||||
case base of {
|
||||
base_1+"ei"+base_2@(?+?)+"ja" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ei"+base_2+"j" ;
|
||||
Pl => base_1+"ei"+base_2+"jið"
|
||||
} ;
|
||||
@@ -11706,7 +11706,7 @@ mkV090 base =
|
||||
case base of {
|
||||
base_1+"ja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"j" ;
|
||||
Pl => base_1+"jið"
|
||||
} ;
|
||||
@@ -11739,7 +11739,7 @@ mkV091 base =
|
||||
case base of {
|
||||
base_1+"jó"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"jó"+base_2 ;
|
||||
Pl => base_1+"jó"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11772,7 +11772,7 @@ mkV092 base =
|
||||
case base of {
|
||||
base_1+"áa" => lin V
|
||||
{ Converb = base_1+"igið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"á" ;
|
||||
Pl => base_1+"áið"
|
||||
} ;
|
||||
@@ -11805,7 +11805,7 @@ mkV093 base =
|
||||
case base of {
|
||||
base_1+"y"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"y"+base_2 ;
|
||||
Pl => base_1+"y"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11838,7 +11838,7 @@ mkV094 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"na" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"nið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2+"n" ;
|
||||
Pl => base_1+"i"+base_2+"nið"
|
||||
} ;
|
||||
@@ -11871,7 +11871,7 @@ mkV095 base =
|
||||
case base of {
|
||||
base_1+"anda" => lin V
|
||||
{ Converb = base_1+"aðið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"att" ;
|
||||
Pl => base_1+"andið"
|
||||
} ;
|
||||
@@ -11904,7 +11904,7 @@ mkV096 base =
|
||||
case base of {
|
||||
base_1+"ei"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ei"+base_2 ;
|
||||
Pl => base_1+"ei"+base_2+"ið"
|
||||
} ;
|
||||
@@ -11937,7 +11937,7 @@ mkV097 base =
|
||||
case base of {
|
||||
base_1+"inga" => lin V
|
||||
{ Converb = base_1+"ungið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ikk" ;
|
||||
Pl => base_1+"ingið"
|
||||
} ;
|
||||
@@ -11970,7 +11970,7 @@ mkV098 base =
|
||||
case base of {
|
||||
base_1+"ja"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ja"+base_2 ;
|
||||
Pl => base_1+"ja"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12003,7 +12003,7 @@ mkV099 base =
|
||||
case base of {
|
||||
base_1+"o"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"o"+base_2 ;
|
||||
Pl => base_1+"o"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12036,7 +12036,7 @@ mkV100 base =
|
||||
case base of {
|
||||
base_1+"í"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"i"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"í"+base_2+"j" ;
|
||||
Pl => base_1+"í"+base_2+"jið"
|
||||
} ;
|
||||
@@ -12069,7 +12069,7 @@ mkV101 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2 ;
|
||||
Pl => base_1+"i"+base_2+"jið"
|
||||
} ;
|
||||
@@ -12102,7 +12102,7 @@ mkV102 base =
|
||||
case base of {
|
||||
base_1+"ja" => lin V
|
||||
{ Converb = base_1+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1 ;
|
||||
Pl => base_1+"ið"
|
||||
} ;
|
||||
@@ -12135,7 +12135,7 @@ mkV103 base =
|
||||
case base of {
|
||||
base_1+"ø"+base_2@?+"ja" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"ø"+base_2+"j" ;
|
||||
Pl => base_1+"ø"+base_2+"jið"
|
||||
} ;
|
||||
@@ -12168,7 +12168,7 @@ mkV104 base =
|
||||
case base of {
|
||||
base_1+"y"+base_2@(?+?)+"ja" => lin V
|
||||
{ Converb = base_1+"u"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"y"+base_2+"j" ;
|
||||
Pl => base_1+"y"+base_2+"jið"
|
||||
} ;
|
||||
@@ -12201,7 +12201,7 @@ mkV105 base =
|
||||
case base of {
|
||||
base_1+"i"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"t" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"i"+base_2 ;
|
||||
Pl => base_1+"i"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12234,7 +12234,7 @@ mkV106 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"fa" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"fið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2+"f" ;
|
||||
Pl => base_1+"e"+base_2+"fið"
|
||||
} ;
|
||||
@@ -12267,7 +12267,7 @@ mkV107 base =
|
||||
case base of {
|
||||
base_1+"a"+base_2@(?+?)+"a" => lin V
|
||||
{ Converb = base_1+"a"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"a"+base_2 ;
|
||||
Pl => base_1+"a"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12300,7 +12300,7 @@ mkV108 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@(?+?)+"a" => lin V
|
||||
{ Converb = nonExist ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12333,7 +12333,7 @@ mkV109 base =
|
||||
case base of {
|
||||
base_1+base_2@?+base_3@?+"a" => lin V
|
||||
{ Converb = base_1+base_2+base_3+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
@@ -12366,7 +12366,7 @@ mkV110 base =
|
||||
case base of {
|
||||
"d"+base_1+"finite" => lin V
|
||||
{ Converb = "v"+base_1+"rð" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => "v"+base_1+"rðsins" ;
|
||||
Pl => "v"+base_1+"rðanna"
|
||||
} ;
|
||||
@@ -12399,7 +12399,7 @@ mkV111 base =
|
||||
case base of {
|
||||
base_1+"e"+base_2@?+"a" => lin V
|
||||
{ Converb = base_1+"o"+base_2+"ið" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => base_1+"e"+base_2 ;
|
||||
Pl => base_1+"e"+base_2+"ið"
|
||||
} ;
|
||||
@@ -12432,7 +12432,7 @@ mkV112 base =
|
||||
case base of {
|
||||
base_1+"ja" => lin V
|
||||
{ Converb = base_1+"að" ;
|
||||
Imperative_Jussive = table {
|
||||
imperative = table {
|
||||
Sg => nonExist ;
|
||||
Pl => nonExist
|
||||
} ;
|
||||
|
||||
@@ -1,4 +1,51 @@
|
||||
concrete NounFao of Noun = CatFao ** {
|
||||
concrete NounFao of Noun = CatFao ** open ResFao in {
|
||||
lin
|
||||
UseN n = n ;
|
||||
UsePron p = p ;
|
||||
RelNP np rs =
|
||||
np ** {s = \\c => np.s ! c ++ "," ++ rs.s ! np.g ! persNum np.n np.p} ;
|
||||
DetCN det cn = {
|
||||
s = \\c => det.s ! cn.g ! c ++ cn.s ! det.sp ! det.n ! c ;
|
||||
g = cn.g ;
|
||||
n = det.n ;
|
||||
p = P3
|
||||
} ;
|
||||
DefArt = {
|
||||
s = \\_,_,_ => [] ;
|
||||
sp = Def
|
||||
} ;
|
||||
IndefArt = {
|
||||
s = table {
|
||||
Masc => table {
|
||||
Sg => table {Nom => "ein" ; Acc => "ein" ; Dat => "einum" ; Gen => "eins"} ;
|
||||
Pl => \\_ => []
|
||||
} ;
|
||||
Fem => table {
|
||||
Sg => table {Nom => "ein" ; Acc => "eina" ; Dat => "einari" ; Gen => "einar"} ;
|
||||
Pl => \\_ => []
|
||||
} ;
|
||||
Neuter => table {
|
||||
Sg => table {Nom => "eitt" ; Acc => "eitt" ; Dat => "einum" ; Gen => "eins"} ;
|
||||
Pl => \\_ => []
|
||||
}
|
||||
} ;
|
||||
sp = Indef
|
||||
} ;
|
||||
DetQuant quant num = {
|
||||
s = \\g,c => quant.s ! g ! num.n ! c ++ num.s ! g ! c ;
|
||||
n = num.n ;
|
||||
sp = quant.sp
|
||||
} ;
|
||||
NumSg = {
|
||||
s = \\_,_ => [] ;
|
||||
n = Sg
|
||||
} ;
|
||||
NumPl = {
|
||||
s = \\_,_ => [] ;
|
||||
n = Pl
|
||||
} ;
|
||||
AdjCN ap cn = {
|
||||
s = \\sp,n,c => ap.s ! cn.g ! n ! c ++ cn.s ! sp ! n ! c ;
|
||||
g = cn.g
|
||||
} ;
|
||||
}
|
||||
|
||||
@@ -319,6 +319,19 @@ oper
|
||||
_ => regN form1
|
||||
} ;
|
||||
|
||||
mkPron : (_,_,_,_ : Str) -> Gender -> Number -> Person -> Pron =
|
||||
\nom,acc,dat,gen,g,n,p -> lin Pron {
|
||||
s = table {
|
||||
Nom => nom ;
|
||||
Acc => acc ;
|
||||
Dat => dat ;
|
||||
Gen => gen
|
||||
} ;
|
||||
g = g ;
|
||||
n = n ;
|
||||
p = p
|
||||
} ;
|
||||
|
||||
regA : Str -> A -- s;Masc;Sg;Nom
|
||||
= \form -> case form of {
|
||||
_ + "dur" => mkA001 form;
|
||||
@@ -494,6 +507,10 @@ oper
|
||||
mkA : Str -> Str -> A = reg2A -- s;Masc;Sg;Nom s;Masc;Sg;Dat
|
||||
} ;
|
||||
|
||||
invarA : Str -> A = \s -> lin A {
|
||||
s = \\_,_,_ => s
|
||||
} ;
|
||||
|
||||
mkA2 = overload {
|
||||
mkA2 : A -> A2 = \a -> lin A2 (a ** {c2 = noPrep}) ;
|
||||
mkA2 : A -> Prep -> A2 = \a,p -> lin A2 (a ** {c2 = p}) ;
|
||||
@@ -502,7 +519,7 @@ oper
|
||||
mkV = overload {
|
||||
mkV : Str -> V = regV; -- Nonfinite
|
||||
mkV : Str -> Str -> V = reg2V ; -- Nonfinite Indicative;Pres;('PSg', P2)
|
||||
mkV : V -> Str -> V -- particle verb
|
||||
mkV : V -> Str -> V -- particle verb
|
||||
= \v,p -> v ** {particle = p}
|
||||
} ;
|
||||
|
||||
@@ -556,10 +573,11 @@ oper
|
||||
mkIQuant : Str -> IQuant = \s -> lin IQuant {s=s} ;
|
||||
mkIDet : Str -> IDet = \s -> lin IDet {s=s} ;
|
||||
mkSubj : Str -> Subj = \s -> lin Subj {s=s} ;
|
||||
mkQuant : Str -> Quant = \s -> lin Quant {s=s} ;
|
||||
mkQuant : Str -> Quant = \s -> lin Quant {s=\\_,_,_ => s; sp=Indef} ;
|
||||
mkPredet : Str -> Predet = \s -> lin Predet {s=s} ;
|
||||
mkDet : Str -> Det = \s -> lin Det {s=s} ;
|
||||
mkDet : Str -> Det = \s -> lin Det {s=\\_,_ => s; n=Sg; sp=Indef} ;
|
||||
mkCard : Str -> Card = \s -> lin Card {s=s} ;
|
||||
mkACard : Str -> ACard = \s -> lin ACard {s=s} ;
|
||||
mkConj : Str -> Conj = \s -> lin Conj {s=s} ;
|
||||
mkPConj : Str -> PConj = \s -> lin PConj {s=s} ;
|
||||
mkVoc : Str -> Voc = \s -> lin Voc {s=s} ;
|
||||
|
||||
@@ -1,8 +1,13 @@
|
||||
concrete PhraseFao of Phrase = CatFao ** {
|
||||
concrete PhraseFao of Phrase = CatFao ** open ResFao in {
|
||||
lin
|
||||
PhrUtt pconj utt voc = {s = pconj.s ++ utt.s ++ voc.s} ;
|
||||
|
||||
UttS s = s ;
|
||||
UttNP np = {s = np.s ! Nom} ;
|
||||
UttVP vp = {s = vp.Nonfinite} ;
|
||||
UttCN cn = {s = cn.s ! Indef ! Sg ! Nom} ;
|
||||
UttAP ap = {s = ap.s ! Masc ! Sg ! Nom} ;
|
||||
UttAdv adv = adv ;
|
||||
UttInterj i = i ;
|
||||
|
||||
NoPConj = {s = []} ;
|
||||
|
||||
7
src/faroese/RelativeFao.gf
Normal file
7
src/faroese/RelativeFao.gf
Normal file
@@ -0,0 +1,7 @@
|
||||
concrete RelativeFao of Relative = CatFao ** open ResFao in {
|
||||
lin
|
||||
IdRP = {s = "sum"} ;
|
||||
RelVP rp vp = {
|
||||
s = \\t,pol,g,pn => rp.s ++ vp.Indicative ! t ! pol ! g ! pn
|
||||
} ;
|
||||
}
|
||||
@@ -1,7 +1,6 @@
|
||||
resource ResFao = {
|
||||
resource ResFao = ParamX - [Tense,Pres,Past] ** {
|
||||
|
||||
param Species = Indef | Def ;
|
||||
param Number = Sg | Pl ;
|
||||
param Case = Nom | Acc | Dat | Gen ;
|
||||
param Gender = Masc | Fem | Neuter ;
|
||||
oper Noun = {s: Species => Number => Case => Str; g : Gender} ; -- 2135
|
||||
@@ -90,17 +89,28 @@ oper mkAdj : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Adj =
|
||||
}
|
||||
} ;
|
||||
|
||||
param Tense = Past | Pres ;
|
||||
param Tense = Pres | Past ;
|
||||
|
||||
param PersNum = PSg Person | PPl ;
|
||||
param Person = P1 | P3 | P2 ;
|
||||
oper Verb = {Converb: Str; Imperative_Jussive: Number => Str; Indicative: Tense => PersNum => Str; Nonfinite: Str; Participle: Tense => Str ; particle : Str} ; -- 596
|
||||
oper persNum : Number -> Person -> PersNum =
|
||||
\n,p -> case n of {
|
||||
Sg => PSg p ;
|
||||
Pl => PPl
|
||||
} ;
|
||||
oper persNumNumber : PersNum -> Number =
|
||||
\pn -> case pn of {
|
||||
PSg _ => Sg ;
|
||||
PPl => Pl
|
||||
} ;
|
||||
|
||||
oper Verb = {Converb: Str; imperative: Number => Str; Indicative: Tense => PersNum => Str; Nonfinite: Str; Participle: Tense => Str ; particle : Str} ; -- 596
|
||||
oper mkVerb : (_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Verb =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14 ->
|
||||
{ Converb = f1 ;
|
||||
Imperative_Jussive = table {
|
||||
Sg => f2 ;
|
||||
Pl => f3
|
||||
} ;
|
||||
imperative = table {
|
||||
Sg => f2 ;
|
||||
Pl => f3
|
||||
} ;
|
||||
Indicative = table {
|
||||
Pres => table {
|
||||
PSg P1 => f4 ;
|
||||
@@ -129,5 +139,34 @@ oper noPrep : Compl = {s=""; c=Acc} ;
|
||||
|
||||
oper CommonNoun = Noun ;
|
||||
oper AdjPhrase = Adj ;
|
||||
oper VerbPhrase = {
|
||||
Converb : Str ;
|
||||
Indicative : Tense => Polarity => Gender => PersNum => Str ;
|
||||
Nonfinite : Str ;
|
||||
Participle : Tense => Str ;
|
||||
} ;
|
||||
oper Clause = {
|
||||
Converb : Str ;
|
||||
Indicative : Tense => Polarity => Str ;
|
||||
Nonfinite : Str ;
|
||||
Participle : Tense => Str
|
||||
} ;
|
||||
|
||||
oper
|
||||
copula : Tense => PersNum => Str =
|
||||
table {
|
||||
Pres => table {
|
||||
PSg P1 => "eri" ;
|
||||
PSg P2 => "ert" ;
|
||||
PSg P3 => "er" ;
|
||||
PPl => "eru"
|
||||
} ;
|
||||
Past => table {
|
||||
PSg P1 => "var" ;
|
||||
PSg P2 => "vart" ;
|
||||
PSg P3 => "var" ;
|
||||
PPl => "vóru"
|
||||
}
|
||||
} ;
|
||||
|
||||
}
|
||||
|
||||
31
src/faroese/SentenceFao.gf
Normal file
31
src/faroese/SentenceFao.gf
Normal file
@@ -0,0 +1,31 @@
|
||||
concrete SentenceFao of Sentence = CatFao ** open Prelude, ResFao, (P = ParamX) in {
|
||||
lin PredVP np vp = {Converb = np.s ! Nom ++ vp.Converb;
|
||||
Indicative = \\t,pol =>
|
||||
let p = persNum np.n np.p
|
||||
in np.s ! Nom ++ vp.Indicative ! t ! pol ! np.g ! p;
|
||||
Nonfinite = np.s ! Nom ++ vp.Nonfinite;
|
||||
Participle = \\t => np.s ! Nom ++ vp.Participle ! t} ;
|
||||
UseCl temp pol cl =
|
||||
let
|
||||
tense = case temp.t of {
|
||||
P.Pres => Pres ;
|
||||
P.Past => Past ;
|
||||
P.Fut => Pres ;
|
||||
P.Cond => Past
|
||||
} ;
|
||||
in {
|
||||
s = temp.s ++ pol.s ++ cl.Indicative ! tense ! pol.p
|
||||
} ;
|
||||
UseRCl temp pol rcl =
|
||||
let
|
||||
tense = case temp.t of {
|
||||
P.Pres => Pres ;
|
||||
P.Past => Past ;
|
||||
P.Fut => Pres ;
|
||||
P.Cond => Past
|
||||
}
|
||||
in {
|
||||
s = \\g,pn =>
|
||||
temp.s ++ pol.s ++ rcl.s ! tense ! pol.p ! g ! pn
|
||||
} ;
|
||||
}
|
||||
14
src/faroese/StructuralFao.gf
Normal file
14
src/faroese/StructuralFao.gf
Normal file
@@ -0,0 +1,14 @@
|
||||
concrete StructuralFao of Structural = CatFao **
|
||||
open ParadigmsFao, ResFao in {
|
||||
|
||||
lin
|
||||
i_Pron = mkPron "eg" "meg" "mær" "mín" Masc Sg P1 ;
|
||||
youSg_Pron = mkPron "tú" "teg" "tær" "tín" Masc Sg P2 ;
|
||||
he_Pron = mkPron "hann" "hann" "honum" "hansara" Masc Sg P3 ;
|
||||
she_Pron = mkPron "hon" "hana" "henni" "hennara" Fem Sg P3 ;
|
||||
it_Pron = mkPron "tað" "tað" "tí" "tess" Neuter Sg P3 ;
|
||||
we_Pron = mkPron "vit" "okkum" "okkum" "okkara" Masc Pl P1 ;
|
||||
youPl_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
they_Pron = mkPron "teir" "teir" "teimum" "teirra" Masc Pl P3 ;
|
||||
youPol_Pron = mkPron "tit" "tykkum" "tykkum" "tykkara" Masc Pl P2 ;
|
||||
}
|
||||
42
src/faroese/VerbFao.gf
Normal file
42
src/faroese/VerbFao.gf
Normal file
@@ -0,0 +1,42 @@
|
||||
concrete VerbFao of Verb = CatFao ** open Prelude,ResFao in {
|
||||
lin UseV v = {Converb = v.Converb ++ v.particle;
|
||||
Indicative = \\t,pol,g,p => v.Indicative ! t ! p ++ v.particle ++
|
||||
case pol of {
|
||||
Pos => [] ;
|
||||
Neg => "ikki"
|
||||
} ;
|
||||
Nonfinite = v.Nonfinite ++ v.particle;
|
||||
Participle = \\t => v.Participle ! t ++ v.particle} ;
|
||||
lin AdvVP vp adv = {Converb = vp.Converb ++ adv.s;
|
||||
Indicative = \\t,pol,g,p => vp.Indicative ! t ! pol ! g ! p ++ adv.s;
|
||||
Nonfinite = vp.Nonfinite ++ adv.s;
|
||||
Participle = \\t => vp.Participle ! t ++ adv.s} ;
|
||||
lin ComplSlash vps np = {Converb = vps.Converb ++ vps.particle
|
||||
++ vps.c2.s ++ np.s ! vps.c2.c;
|
||||
Indicative = \\t,pol,g,p =>
|
||||
vps.Indicative ! t ! p ++ vps.particle ++
|
||||
case pol of {
|
||||
Pos => [] ;
|
||||
Neg => "ikki"
|
||||
} ++
|
||||
vps.c2.s ++ np.s ! vps.c2.c ;
|
||||
Nonfinite = vps.Nonfinite ++ vps.particle ++ vps.c2.s ++ np.s ! vps.c2.c;
|
||||
Participle = \\t => vps.Participle ! t ++ vps.particle ++ vps.c2.s ++ np.s ! vps.c2.c} ;
|
||||
lin UseComp comp = {
|
||||
Converb = copula ! Pres ! PPl ++ comp.s ! Masc ! Sg ;
|
||||
Indicative = \\t,pol,g,p => copula ! t ! p ++
|
||||
case pol of {
|
||||
Pos => [] ;
|
||||
Neg => "ikki"
|
||||
} ++
|
||||
comp.s ! g ! persNumNumber p ;
|
||||
Nonfinite = "vera" ++ comp.s ! Masc ! Sg ;
|
||||
Participle = \\t => "verið" ++ comp.s ! Masc ! Sg
|
||||
} ;
|
||||
lin CompAP ap = {s = \\g,n => ap.s ! g ! n ! Nom} ;
|
||||
lin CompNP np = {s = \\_,_ => np.s ! Nom} ;
|
||||
lin CompAdv adv = {s = \\_,_ => adv.s} ;
|
||||
lin CompCN cn = {s = \\_,n => cn.s ! Indef ! n ! Nom} ;
|
||||
|
||||
lin SlashV2a v = v ;
|
||||
}
|
||||
@@ -68,6 +68,8 @@ oper
|
||||
mkPN = overload {
|
||||
mkPN : (anna : Str) -> PN
|
||||
= \p -> lin PN (regName p) ;
|
||||
mkPN : (anna : Str) -> Gender -> PN
|
||||
= \p, g -> lin PN (regName p ** {g = g}) ;
|
||||
mkPN : (nm,gm,am,vm,pn,pa : Str) -> Gender -> PN
|
||||
= \ nm,gm,am,vm,pn,pa, g -> lin PN (mkName nm gm am vm pn pa g) ;
|
||||
} ;
|
||||
|
||||
@@ -7,7 +7,7 @@ concrete AdjectiveHun of Adjective = CatHun ** open ResHun, Prelude in {
|
||||
-- : A -> AP ;
|
||||
PositA a = emptyAP ** {
|
||||
s = \\n,c =>
|
||||
let adj : Noun = (a ** {s = a.s ! Posit}) in
|
||||
let adj : Noun = (a ** {s = a.s ! Posit; g = NonHuman}) in
|
||||
caseFromStem glue adj c n ;
|
||||
} ;
|
||||
|
||||
@@ -35,7 +35,7 @@ concrete AdjectiveHun of Adjective = CatHun ** open ResHun, Prelude in {
|
||||
-- : A -> AP ; -- warmer
|
||||
UseComparA a = emptyAP ** {
|
||||
s = \\n,c =>
|
||||
let adj : Noun = (a ** {s = a.s ! Compar}) in
|
||||
let adj : Noun = (a ** {s = a.s ! Compar; g = NonHuman}) in
|
||||
caseFromStem glue adj c n ;
|
||||
} ;
|
||||
|
||||
@@ -54,7 +54,9 @@ concrete AdjectiveHun of Adjective = CatHun ** open ResHun, Prelude in {
|
||||
-- phrases, although the semantics is only clear for some adjectives.
|
||||
|
||||
-- : AP -> SC -> AP ; -- good that she is here
|
||||
-- SentAP ap sc = ap ** {} ;
|
||||
SentAP ap sc = ap ** {
|
||||
compl = \\n => ap.compl ! n ++ sc.s ;
|
||||
} ;
|
||||
|
||||
-- An adjectival phrase can be modified by an *adadjective*, such as "very".
|
||||
|
||||
|
||||
@@ -3,7 +3,11 @@ concrete AdverbHun of Adverb = CatHun ** open ResHun, ParamHun, ParadigmsHun, Pr
|
||||
lin
|
||||
|
||||
-- : A -> Adv ;
|
||||
--PositAdvAdj adj = { } ;
|
||||
PositAdvAdj adj = {
|
||||
s = let a : Str = adj.s ! Posit ! SgNom
|
||||
in a ++ BIND ++ "an" ;
|
||||
isPre = False ;
|
||||
} ;
|
||||
|
||||
-- : CAdv -> A -> NP -> Adv ; -- more warmly than John
|
||||
-- ComparAdvAdj cadv a np = { } ;
|
||||
@@ -19,15 +23,18 @@ lin
|
||||
-- Adverbs can be modified by 'adadjectives', just like adjectives.
|
||||
|
||||
--AdAdv : AdA -> Adv -> Adv ; -- very quickly
|
||||
-- AdAdv ada adv = adv **
|
||||
AdAdv ada adv = adv ** {s = ada.s ++ adv.s} ;
|
||||
-- Like adverbs, adadjectives can be produced by adjectives.
|
||||
|
||||
-- : A -> AdA ; -- extremely
|
||||
-- PositAdAAdj a = { } ;
|
||||
PositAdAAdj a = {s = a.s ! Posit ! SgNom} ;
|
||||
-- Subordinate clauses can function as adverbs.
|
||||
|
||||
-- : Subj -> S -> Adv ;
|
||||
-- SubjS subj s =
|
||||
SubjS subj s = {
|
||||
s = subj.s ++ s.s ;
|
||||
isPre = False ;
|
||||
} ;
|
||||
|
||||
-- Comparison adverbs also work as numeral adverbs.
|
||||
|
||||
|
||||
@@ -2,5 +2,6 @@
|
||||
|
||||
concrete AllHun of AllHunAbs =
|
||||
LangHun,
|
||||
IrregHun,
|
||||
ExtendHun
|
||||
** {} ;
|
||||
|
||||
@@ -2,5 +2,6 @@
|
||||
|
||||
abstract AllHunAbs =
|
||||
Lang,
|
||||
IrregHunAbs,
|
||||
Extend
|
||||
** {} ;
|
||||
|
||||
@@ -76,8 +76,7 @@ concrete CatHun of Cat = CommonX - [Adv] ** open ResHun, Prelude in {
|
||||
|
||||
-- Constructed in NumeralHun.
|
||||
|
||||
Card = ResHun.Numeral ;
|
||||
Numeral = ResHun.Numeral ;
|
||||
Card, ACard, Numeral = ResHun.Numeral ;
|
||||
Digits = {s : CardOrd => Str} ;
|
||||
Decimal = {s : CardOrd => Str; hasDot : Bool} ;
|
||||
|
||||
@@ -126,5 +125,8 @@ linref
|
||||
NP = linNP ;
|
||||
V,VS,VQ,VA = \v -> v.s ! VPres P3 Sg ;
|
||||
V2,V3,V2S,V2Q,V2A = \v -> v.s ! Indef ! VPres P3 Sg ;
|
||||
VP = \vp -> vp.obj ++ vp.adv ++ vp.s ! VInf ;
|
||||
|
||||
lindef
|
||||
VP = \s -> {s = \\_=>s; obj,adv=[]; sc=SCNom; c2=Acc} ;
|
||||
}
|
||||
|
||||
@@ -52,22 +52,37 @@ lin
|
||||
in np ** {s = linTable} ;
|
||||
-- Relative sentences
|
||||
lincat
|
||||
[RS] = {s1,s2 : Number => Case => Str} ;
|
||||
[RS] = {s1,s2 : Gender => Number => Case => Str} ;
|
||||
|
||||
lin
|
||||
BaseRS = twoTable2 Number Case ;
|
||||
ConsRS = consrTable2 Number Case comma ;
|
||||
ConjRS = conjunctDistrTable2 Number Case ;
|
||||
BaseRS = twoTable3 Gender Number Case ;
|
||||
ConsRS = consrTable3 Gender Number Case comma ;
|
||||
ConjRS = conjunctDistrTable3 Gender Number Case ;
|
||||
|
||||
lincat
|
||||
[CN] = {
|
||||
s1,s2 : NumCaseStem => Str ;
|
||||
h : Harm ;
|
||||
g : Gender
|
||||
} ;
|
||||
|
||||
lin
|
||||
BaseCN x y = twoTable NumCaseStem x y ** {
|
||||
h = y.h ;
|
||||
g = y.g
|
||||
} ;
|
||||
ConsCN x xs = consrTable NumCaseStem comma x xs ** {
|
||||
h = xs.h ;
|
||||
g = xs.g
|
||||
} ;
|
||||
ConjCN co cs = conjunctDistrTable NumCaseStem co cs ** {
|
||||
compl = \\_,_ => [] ;
|
||||
postmod = [] ;
|
||||
h = cs.h ;
|
||||
g = cs.g
|
||||
} ;
|
||||
|
||||
{-
|
||||
lincat
|
||||
[CN] = { } ;
|
||||
|
||||
lin
|
||||
BaseCN = {} ;
|
||||
ConsCN = {} ;
|
||||
ConjCN co cs = conjunctDistrTable … co cs ** cs ;
|
||||
|
||||
lincat
|
||||
[DAP] =
|
||||
|
||||
|
||||
@@ -1,11 +1,178 @@
|
||||
concrete ConstructionHun of Construction = CatHun ** open ParadigmsHun in {
|
||||
concrete ConstructionHun of Construction = CatHun ** open
|
||||
ParadigmsHun, ResHun, NounHun, VerbHun, AdjectiveHun, Prelude in {
|
||||
|
||||
lincat
|
||||
Timeunit = N ;
|
||||
Hour = {s : Str} ;
|
||||
Weekday = N ;
|
||||
Monthday = NP ;
|
||||
Month = N ;
|
||||
Year = NP ;
|
||||
Language = N ;
|
||||
|
||||
lin
|
||||
hungry_VP = UseComp (CompAP (PositA (mkA "éhes"))) ;
|
||||
thirsty_VP = UseComp (CompAP (PositA (mkA "szomjas"))) ;
|
||||
tired_VP = UseComp (CompAP (PositA (mkA "fáradt"))) ;
|
||||
scared_VP = UseComp (CompAP (PositA (mkA "ijedt"))) ;
|
||||
ill_VP = UseComp (CompAP (PositA (mkA "beteg"))) ;
|
||||
ready_VP = UseComp (CompAP (PositA (mkA "kész"))) ;
|
||||
|
||||
has_age_VP card = useV (copula ** {
|
||||
s = \\vf => case vf of {
|
||||
VPres P3 _ => [] ;
|
||||
_ => copula.s ! vf
|
||||
}
|
||||
}) ** {
|
||||
adv = card.s ! Indep ++ "éves"
|
||||
} ;
|
||||
|
||||
n_units_AP card cn a =
|
||||
let ap : AP = PositA a in ap ** {
|
||||
s = \\n,c => card.s ! Attrib ++ cn.s ! SgNom ++ ap.s ! n ! c
|
||||
} ;
|
||||
|
||||
n_units_of_NP card cn np = lin NP (indeclNP
|
||||
(card.s ! Attrib ++ cn.s ! SgNom ++ np.s ! NoPoss ! Nom ++ np.postmod)) ;
|
||||
|
||||
n_unit_CN card unit cn = cn ** {
|
||||
s = \\ncs => card.s ! Attrib ++ unit.s ! SgNom ++ cn.s ! ncs
|
||||
} ;
|
||||
|
||||
bottle_of_CN np = (UseN (mkN "palack")) ** {
|
||||
compl = \\_,_ => np.s ! NoPoss ! Nom ++ np.postmod
|
||||
} ;
|
||||
cup_of_CN np = (UseN (mkN "csésze")) ** {
|
||||
compl = \\_,_ => np.s ! NoPoss ! Nom ++ np.postmod
|
||||
} ;
|
||||
glass_of_CN np = (UseN (mkN "pohár")) ** {
|
||||
compl = \\_,_ => np.s ! NoPoss ! Nom ++ np.postmod
|
||||
} ;
|
||||
|
||||
timeunitAdv n time = mkAdv (n.s ! Attrib ++ time.s ! SgNom) ;
|
||||
timeunitRange l u time =
|
||||
mkAdv (l.s ! Attrib ++ BIND ++ "-" ++ BIND ++ u.s ! Attrib ++ time.s ! SgNom) ;
|
||||
|
||||
oneHour = {s = "1"} ;
|
||||
twoHour = {s = "2"} ;
|
||||
threeHour = {s = "3"} ;
|
||||
fourHour = {s = "4"} ;
|
||||
fiveHour = {s = "5"} ;
|
||||
sixHour = {s = "6"} ;
|
||||
sevenHour = {s = "7"} ;
|
||||
eightHour = {s = "8"} ;
|
||||
nineHour = {s = "9"} ;
|
||||
tenHour = {s = "10"} ;
|
||||
elevenHour = {s = "11"} ;
|
||||
twelveHour = {s = "12"} ;
|
||||
thirteenHour = {s = "13"} ;
|
||||
fourteenHour = {s = "14"} ;
|
||||
fifteenHour = {s = "15"} ;
|
||||
sixteenHour = {s = "16"} ;
|
||||
seventeenHour = {s = "17"} ;
|
||||
eighteenHour = {s = "18"} ;
|
||||
nineteenHour = {s = "19"} ;
|
||||
twentyHour = {s = "20"} ;
|
||||
twentyOneHour = {s = "21"} ;
|
||||
twentyTwoHour = {s = "22"} ;
|
||||
twentyThreeHour = {s = "23"} ;
|
||||
twentyFourHour = {s = "24"} ;
|
||||
|
||||
timeHour h = mkAdv (h.s ++ "órakor") ;
|
||||
timeHourMinute h m = mkAdv (h.s ++ BIND ++ ":" ++ BIND ++ m.s ! Attrib) ;
|
||||
|
||||
weekdayPunctualAdv w = mkAdv (caseFromStem glue w Sup Sg) ;
|
||||
weekdayHabitualAdv w = mkAdv (caseFromStem glue w Sup Sg) ;
|
||||
weekdayNextAdv w = mkAdv ("jövő" ++ caseFromStem glue w Sup Sg) ;
|
||||
weekdayLastAdv w = mkAdv ("múlt" ++ caseFromStem glue w Sup Sg) ;
|
||||
|
||||
monthAdv m = mkAdv (caseFromStem glue m Ine Sg) ;
|
||||
yearAdv y = mkAdv (y.s ! NoPoss ! Nom ++ BIND ++ "-ban") ;
|
||||
dayMonthAdv d m =
|
||||
mkAdv (d.s ! NoPoss ! Nom ++ BIND ++ "." ++ m.s ! SgNom) ;
|
||||
monthYearAdv m y =
|
||||
mkAdv (m.s ! SgNom ++ y.s ! NoPoss ! Nom ++ BIND ++ "-ban") ;
|
||||
dayMonthYearAdv d m y =
|
||||
mkAdv (d.s ! NoPoss ! Nom ++ BIND ++ "." ++ m.s ! SgNom ++ y.s ! NoPoss ! Nom ++ BIND ++ "-ban") ;
|
||||
|
||||
intYear i = lin NP (indeclNP i.s) ;
|
||||
intMonthday i = lin NP (indeclNP i.s) ;
|
||||
|
||||
InLanguage l = mkAdv (l.s ! SgNom ++ "nyelven") ;
|
||||
|
||||
weekdayN w = w ;
|
||||
monthN m = m ;
|
||||
|
||||
weekdayPN w = lin PN (MassNP (UseN w)) ;
|
||||
monthPN m = lin PN (MassNP (UseN m)) ;
|
||||
|
||||
languageCN l = UseN l ;
|
||||
languageNP l = lin NP (MassNP (UseN l)) ;
|
||||
|
||||
second_Timeunit = mkN "másodperc" ;
|
||||
minute_Timeunit = mkN "perc" ;
|
||||
hour_Timeunit = mkN "óra" ;
|
||||
day_Timeunit = mkN "nap" ;
|
||||
week_Timeunit = mkN "hét" ;
|
||||
month_Timeunit = mkN "hónap" ;
|
||||
year_Timeunit = mkN "év" ;
|
||||
|
||||
monday_Weekday = mkN "hétfő" ;
|
||||
tuesday_Weekday = mkN "kedd" ;
|
||||
wednesday_Weekday = mkN "szerda" ;
|
||||
thursday_Weekday = mkN "csütörtök" ;
|
||||
friday_Weekday = mkN "péntek" ;
|
||||
saturday_Weekday = mkN "szombat" ;
|
||||
sunday_Weekday = mkN "vasárnap" ;
|
||||
|
||||
january_Month = mkN "január" ;
|
||||
february_Month = mkN "február" ;
|
||||
march_Month = mkN "március" ;
|
||||
april_Month = mkN "április" ;
|
||||
may_Month = mkN "május" ;
|
||||
june_Month = mkN "június" ;
|
||||
july_Month = mkN "július" ;
|
||||
august_Month = mkN "augusztus" ;
|
||||
september_Month = mkN "szeptember" ;
|
||||
october_Month = mkN "október" ;
|
||||
november_Month = mkN "november" ;
|
||||
december_Month = mkN "december" ;
|
||||
|
||||
afrikaans_Language = mkN "afrikaans" ;
|
||||
amharic_Language = mkN "amhara" ;
|
||||
arabic_Language = mkN "arab" ;
|
||||
bulgarian_Language = mkN "bolgár" ;
|
||||
catalan_Language = mkN "katalán" ;
|
||||
chinese_Language = mkN "kínai" ;
|
||||
danish_Language = mkN "dán" ;
|
||||
dutch_Language = mkN "holland" ;
|
||||
english_Language = mkN "angol" ;
|
||||
estonian_Language = mkN "észt" ;
|
||||
finnish_Language = mkN "finn" ;
|
||||
french_Language = mkN "francia" ;
|
||||
german_Language = mkN "német" ;
|
||||
greek_Language = mkN "görög" ;
|
||||
hebrew_Language = mkN "héber" ;
|
||||
hindi_Language = mkN "hindi" ;
|
||||
japanese_Language = mkN "japán" ;
|
||||
italian_Language = mkN "olasz" ;
|
||||
latin_Language = mkN "latin" ;
|
||||
latvian_Language = mkN "lett" ;
|
||||
maltese_Language = mkN "máltai" ;
|
||||
nepali_Language = mkN "nepáli" ;
|
||||
norwegian_Language = mkN "norvég" ;
|
||||
persian_Language = mkN "perzsa" ;
|
||||
polish_Language = mkN "lengyel" ;
|
||||
punjabi_Language = mkN "pandzsábi" ;
|
||||
romanian_Language = mkN "román" ;
|
||||
russian_Language = mkN "orosz" ;
|
||||
sindhi_Language = mkN "szindhi" ;
|
||||
spanish_Language = mkN "spanyol" ;
|
||||
swahili_Language = mkN "szuahéli" ;
|
||||
swedish_Language = mkN "svéd" ;
|
||||
thai_Language = mkN "thai" ;
|
||||
turkish_Language = mkN "török" ;
|
||||
urdu_Language = mkN "urdu" ;
|
||||
{-
|
||||
lin
|
||||
|
||||
|
||||
206
src/hungarian/DocumentationHun.gf
Normal file
206
src/hungarian/DocumentationHun.gf
Normal file
@@ -0,0 +1,206 @@
|
||||
--# -path=.:../abstract:../common:../prelude
|
||||
|
||||
concrete DocumentationHun of Documentation = CatHun ** open
|
||||
ResHun, Prelude, HTML in {
|
||||
|
||||
lincat
|
||||
Inflection = {t : Str; s1,s2 : Str} ;
|
||||
Definition = {s : Str} ;
|
||||
Document = {s : Str} ;
|
||||
Tag = {s : Str} ;
|
||||
|
||||
lin
|
||||
InflectionN = \noun -> nounInflection "n" "Főnév" noun ;
|
||||
InflectionN2 = \noun -> nounInflection "n2" "Kétargumentumú főnév" noun ;
|
||||
InflectionN3 = \noun -> nounInflection "n3" "Háromargumentumú főnév" noun ;
|
||||
|
||||
InflectionPN = \pn -> nameInflection "pn" "Tulajdonnév" pn ;
|
||||
InflectionLN = \ln -> nameInflection "ln" "Helynév" ln ;
|
||||
InflectionGN = \gn -> nameInflection "gn" "Keresztnév" gn ;
|
||||
InflectionSN = \sn -> nameInflection "sn" "Vezetéknév" sn ;
|
||||
|
||||
InflectionA = \adj -> adjectiveInflection "a" "Melléknév" adj ;
|
||||
InflectionA2 = \adj -> adjectiveInflection "a2" "Vonzatos melléknév" adj ;
|
||||
|
||||
InflectionV = \v -> verbInflection "v" "Ige" v ;
|
||||
InflectionVS = \v -> verbInflection "vs" "Mondatvonzatú ige" v ;
|
||||
InflectionVQ = \v -> verbInflection "vq" "Kérdő mondatvonzatú ige" v ;
|
||||
InflectionVA = \v -> verbInflection "va" "Melléknévi vonzatú ige" v ;
|
||||
|
||||
InflectionV2 = \v -> verb2Inflection "v2" "Tárgyas ige" v ;
|
||||
InflectionVV = \v -> verb2Inflection "vv" "Igenévi vonzatú ige" v ;
|
||||
InflectionV3 = \v -> verb2Inflection "v3" "Háromargumentumú ige" v ;
|
||||
InflectionV2V = \v -> verb2Inflection "v2v" "Tárgyas és igenévi vonzatú ige" v ;
|
||||
InflectionV2S = \v -> verb2Inflection "v2s" "Tárgyas és mondatvonzatú ige" v ;
|
||||
InflectionV2Q = \v -> verb2Inflection "v2q" "Tárgyas és kérdő mondatvonzatú ige" v ;
|
||||
InflectionV2A = \v -> verb2Inflection "v2a" "Tárgyas és melléknévi vonzatú ige" v ;
|
||||
|
||||
InflectionAdv = \adv -> adverbInflection "adv" "Határozószó" adv.s ;
|
||||
InflectionAdV = \adv -> adverbInflection "adv" "Igei határozószó" adv.s ;
|
||||
InflectionAdA = \adv -> adverbInflection "adv" "Melléknévi határozószó" adv.s ;
|
||||
InflectionAdN = \adv -> adverbInflection "adv" "Főnévi határozószó" adv.s ;
|
||||
|
||||
InflectionPrep = \prep -> {
|
||||
t = "prep" ;
|
||||
s1 = heading1 "Névutó" ;
|
||||
s2 = frameTable (
|
||||
tr (th "előtag" ++ td prep.pr) ++
|
||||
tr (th "eset" ++ td (caseName prep.c)) ++
|
||||
tr (th "névutó" ++ td prep.s))
|
||||
} ;
|
||||
|
||||
lin
|
||||
NoDefinition t = {s = t.s} ;
|
||||
MkDefinition t d = {s = "<p><b>Meghatározás:</b>" ++ t.s ++ d.s ++ "</p>"} ;
|
||||
MkDefinitionEx t d e =
|
||||
{s = "<p><b>Meghatározás:</b>" ++ t.s ++ d.s ++
|
||||
"</p><p><b>Példa:</b>" ++ e.s ++ "</p>"} ;
|
||||
|
||||
lin
|
||||
MkDocument d i e = {s = i.s1 ++ d.s ++ i.s2 ++ paragraph e.s} ;
|
||||
MkTag i = {s = i.t} ;
|
||||
|
||||
oper
|
||||
nounInflection : Str -> Str -> Noun -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,noun -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = caseTable2 (\n,c -> nounCase noun n c) ++
|
||||
heading2 "Birtokos alakok" ++
|
||||
possTable noun
|
||||
} ;
|
||||
|
||||
nameInflection : Str -> Str -> NounPhrase -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,np -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = frameTable (
|
||||
tr (th "alanyeset" ++ td (np.s ! NoPoss ! Nom)) ++
|
||||
tr (th "tárgyeset" ++ td (np.s ! NoPoss ! Acc)) ++
|
||||
tr (th "részes eset" ++ td (np.s ! NoPoss ! Dat)) ++
|
||||
tr (th "inessivus" ++ td (np.s ! NoPoss ! Ine)) ++
|
||||
tr (th "elativus" ++ td (np.s ! NoPoss ! Ela)) ++
|
||||
tr (th "allativus" ++ td (np.s ! NoPoss ! All)) ++
|
||||
tr (th "adessivus" ++ td (np.s ! NoPoss ! Ade)) ++
|
||||
tr (th "ablativus" ++ td (np.s ! NoPoss ! Abl)) ++
|
||||
tr (th "superessivus" ++ td (np.s ! NoPoss ! Sup)) ++
|
||||
tr (th "instrumentalis" ++ td (np.s ! NoPoss ! Ins)) ++
|
||||
tr (th "translativus" ++ td (np.s ! NoPoss ! Tra)))
|
||||
} ;
|
||||
|
||||
adjectiveInflection : Str -> Str -> Adjective -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,adj -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = heading2 "Alapfok" ++
|
||||
caseTable2 (\n,c -> adjCase adj Posit n c) ++
|
||||
heading2 "Középfok" ++
|
||||
caseTable2 (\n,c -> adjCase adj Compar n c) ++
|
||||
heading2 "Felsőfok" ++
|
||||
caseTable2 (\n,c -> adjCase adj Superl n c)
|
||||
} ;
|
||||
|
||||
adverbInflection : Str -> Str -> Str -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,s -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = paragraph s
|
||||
} ;
|
||||
|
||||
verbInflection : Str -> Str -> Verb -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,v -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = verbTable (\vf -> v.s ! vf)
|
||||
} ;
|
||||
|
||||
verb2Inflection : Str -> Str -> Verb2 -> {t : Str; s1,s2 : Str} =
|
||||
\tag,title,v -> {
|
||||
t = tag ;
|
||||
s1 = heading1 title ;
|
||||
s2 = paragraph ("vonzat esete: " ++ caseName v.c2) ++
|
||||
heading2 "Határozatlan ragozás" ++
|
||||
verbTable (\vf -> v.s ! Indef ! vf) ++
|
||||
heading2 "Határozott ragozás" ++
|
||||
verbTable (\vf -> v.s ! Def ! vf)
|
||||
} ;
|
||||
|
||||
caseTable2 : (Number -> Case -> Str) -> Str =
|
||||
\forms -> frameTable (
|
||||
tr (th "" ++ th "egyes szám" ++ th "többes szám") ++
|
||||
tr (th "alanyeset" ++ td (forms Sg Nom) ++ td (forms Pl Nom)) ++
|
||||
tr (th "tárgyeset" ++ td (forms Sg Acc) ++ td (forms Pl Acc)) ++
|
||||
tr (th "részes eset" ++ td (forms Sg Dat) ++ td (forms Pl Dat)) ++
|
||||
tr (th "inessivus" ++ td (forms Sg Ine) ++ td (forms Pl Ine)) ++
|
||||
tr (th "elativus" ++ td (forms Sg Ela) ++ td (forms Pl Ela)) ++
|
||||
tr (th "allativus" ++ td (forms Sg All) ++ td (forms Pl All)) ++
|
||||
tr (th "adessivus" ++ td (forms Sg Ade) ++ td (forms Pl Ade)) ++
|
||||
tr (th "ablativus" ++ td (forms Sg Abl) ++ td (forms Pl Abl)) ++
|
||||
tr (th "superessivus" ++ td (forms Sg Sup) ++ td (forms Pl Sup)) ++
|
||||
tr (th "instrumentalis" ++ td (forms Sg Ins) ++ td (forms Pl Ins)) ++
|
||||
tr (th "translativus" ++ td (forms Sg Tra) ++ td (forms Pl Tra)))
|
||||
;
|
||||
|
||||
possTable : Noun -> Str =
|
||||
\noun -> frameTable (
|
||||
tr (th "" ++ th "birtok egyes szám" ++ th "birtok többes szám") ++
|
||||
tr (th "1. személy egyes szám" ++ td (possForm noun Sg P1 Sg) ++ td (possForm noun Pl P1 Sg)) ++
|
||||
tr (th "2. személy egyes szám" ++ td (possForm noun Sg P2 Sg) ++ td (possForm noun Pl P2 Sg)) ++
|
||||
tr (th "3. személy egyes szám" ++ td (possForm noun Sg P3 Sg) ++ td (possForm noun Pl P3 Sg)) ++
|
||||
tr (th "1. személy többes szám" ++ td (possForm noun Sg P1 Pl) ++ td (possForm noun Pl P1 Pl)) ++
|
||||
tr (th "2. személy többes szám" ++ td (possForm noun Sg P2 Pl) ++ td (possForm noun Pl P2 Pl)) ++
|
||||
tr (th "3. személy többes szám" ++ td (possForm noun Sg P3 Pl) ++ td (possForm noun Pl P3 Pl)))
|
||||
;
|
||||
|
||||
verbTable : (VForm -> Str) -> Str =
|
||||
\forms ->
|
||||
heading2 "Főnévi igenév" ++
|
||||
paragraph (forms VInf) ++
|
||||
heading2 "Jelen idő" ++
|
||||
personNumberTable (\p,n -> forms (VPres p n)) ++
|
||||
heading2 "Múlt idő" ++
|
||||
personNumberTable (\p,n -> forms (VPast p n)) ;
|
||||
|
||||
personNumberTable : (Person -> Number -> Str) -> Str =
|
||||
\forms -> frameTable (
|
||||
tr (th "" ++ th "egyes szám" ++ th "többes szám") ++
|
||||
tr (th "1. személy" ++ td (forms P1 Sg) ++ td (forms P1 Pl)) ++
|
||||
tr (th "2. személy" ++ td (forms P2 Sg) ++ td (forms P2 Pl)) ++
|
||||
tr (th "3. személy" ++ td (forms P3 Sg) ++ td (forms P3 Pl)))
|
||||
;
|
||||
|
||||
nounCase : Noun -> Number -> Case -> Str =
|
||||
\noun,n,c -> caseFromStem glue noun c n ;
|
||||
|
||||
adjCase : Adjective -> Degree -> Number -> Case -> Str =
|
||||
\adj,d,n,c -> caseFromStem glue {s = adj.s ! d ; h = adj.h ; g = NonHuman} c n ;
|
||||
|
||||
possForm : Noun -> Number -> Person -> Number -> Str =
|
||||
\noun,possd,person,possr ->
|
||||
let det : Determiner = {
|
||||
s = \\_ => [] ;
|
||||
sp = \\_ => [] ;
|
||||
n = possd ;
|
||||
dt = DetPoss (agr2pstem <person,possr>) ;
|
||||
poss = possForms ! <person,possr> ;
|
||||
caseagr = False
|
||||
} ;
|
||||
cn : CNoun = noun ** {compl = \\_,_ => [] ; postmod = []} ;
|
||||
in caseFromPossStem cn det Nom ;
|
||||
|
||||
caseName : Case -> Str = \c ->
|
||||
case c of {
|
||||
Nom => "alanyeset" ;
|
||||
Acc => "tárgyeset" ;
|
||||
Dat => "részes eset" ;
|
||||
Ine => "inessivus" ;
|
||||
Ela => "elativus" ;
|
||||
All => "allativus" ;
|
||||
Ade => "adessivus" ;
|
||||
Abl => "ablativus" ;
|
||||
Sup => "superessivus" ;
|
||||
Ins => "instrumentalis" ;
|
||||
Tra => "translativus" ;
|
||||
_ => case2str c
|
||||
} ;
|
||||
}
|
||||
@@ -3,9 +3,362 @@
|
||||
concrete ExtendHun of Extend = CatHun
|
||||
-- ** ExtendFunctor - []
|
||||
-- with (Grammar=GrammarHun)
|
||||
** open Prelude, ResHun, NounHun in {
|
||||
** open Prelude, ResHun, NounHun, VerbHun, AdjectiveHun in {
|
||||
|
||||
lincat
|
||||
VPS = {s : Person => Number => Str} ;
|
||||
[VPS] = {s1,s2 : Person => Number => Str} ;
|
||||
VPI = SS ;
|
||||
[VPI] = {s1,s2 : Str} ;
|
||||
VPS2 = {s : ObjDef => Person => Number => Str ; c2 : Case} ;
|
||||
[VPS2] = {s1,s2 : ObjDef => Person => Number => Str ; c2 : Case} ;
|
||||
VPI2 = {s : ObjDef => Str ; c2 : Case} ;
|
||||
[VPI2] = {s1,s2 : ObjDef => Str ; c2 : Case} ;
|
||||
[Comp] = {s1,s2 : VForm => Str} ;
|
||||
[Imp] = {s1,s2 : Number => Polarity => Str} ;
|
||||
RNP = NounPhrase ;
|
||||
RNPList = {s1,s2 : Possessor => Case => Str ; agr : Person*Number ; g : Gender ; postmod : Str} ;
|
||||
|
||||
lin
|
||||
TPastSimple = {s = []} ** {t = Past} ; --# notpresent
|
||||
|
||||
CompoundN n1 n2 =
|
||||
n2 ** {s = \\nc => n1.s ! SgNom ++ BIND ++ n2.s ! nc} ;
|
||||
|
||||
GenModNP num np cn =
|
||||
let det : Determiner = DetQuant DefArt num ;
|
||||
pron : Pronoun = pronTable ! np.agr ;
|
||||
in emptyNP ** cn ** det ** {
|
||||
s = \\_,c =>
|
||||
np.s ! NoPoss ! Nom
|
||||
++ np.postmod
|
||||
++ caseFromPossStem cn (DetQuant (PossPron pron) num) c
|
||||
++ cn.compl ! det.n ! c ;
|
||||
agr = <P3,det.n> ;
|
||||
objdef = Def ;
|
||||
} ;
|
||||
|
||||
EmptyRelSlash cls = relSlash {s = \\_,_,_ => []} cls ;
|
||||
|
||||
UseDAP = DetNP ;
|
||||
UseDAPMasc,
|
||||
UseDAPFem = \dap -> DetNP dap ** {g = Human} ;
|
||||
|
||||
MkVPS t pol vp = {
|
||||
s = \\p,n =>
|
||||
t.s ++ pol.s ++ if_then_Pol pol.p [] "nem" ++
|
||||
case t.t of {
|
||||
Past => vp.s ! VPast p n ;
|
||||
Fut => futureAux Indef p n ++ vp.s ! VInf ;
|
||||
_ => vp.s ! VPres p n
|
||||
} ++ vp.obj ++ vp.adv
|
||||
} ;
|
||||
|
||||
BaseVPS x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s
|
||||
} ;
|
||||
|
||||
ConsVPS x xs = {
|
||||
s1 = \\p,n => x.s ! p ! n ++ bindComma ++ xs.s1 ! p ! n ;
|
||||
s2 = xs.s2
|
||||
} ;
|
||||
|
||||
ConjVPS conj xs = {
|
||||
s = \\p,n => xs.s1 ! p ! n ++ conj.s2 ++ xs.s2 ! p ! n
|
||||
} ;
|
||||
|
||||
PredVPS np vps = {
|
||||
s = linNP np ++ vps.s ! np.agr.p1 ! np.agr.p2
|
||||
} ;
|
||||
|
||||
MkVPI vp = {s = infVP vp} ;
|
||||
|
||||
BaseVPI x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s
|
||||
} ;
|
||||
|
||||
ConsVPI x xs = {
|
||||
s1 = x.s ++ bindComma ++ xs.s1 ;
|
||||
s2 = xs.s2
|
||||
} ;
|
||||
|
||||
ConjVPI conj xs = {
|
||||
s = xs.s1 ++ conj.s2 ++ xs.s2
|
||||
} ;
|
||||
|
||||
ComplVPIVV vv vpi =
|
||||
useV (vv ** {s = vv.s ! Indef}) ** {
|
||||
adv = vpi.s
|
||||
} ;
|
||||
|
||||
MkVPS2 t pol vps = {
|
||||
s = \\od,p,n =>
|
||||
t.s ++ pol.s ++ if_then_Pol pol.p [] "nem" ++
|
||||
case t.t of {
|
||||
Past => vps.s ! od ! VPast p n ;
|
||||
Fut => futureAux od p n ++ vps.s ! od ! VInf ;
|
||||
_ => vps.s ! od ! VPres p n
|
||||
} ++ vps.adv ;
|
||||
c2 = vps.c2
|
||||
} ;
|
||||
|
||||
ComplVPS2 vps np = {
|
||||
s = \\p,n => vps.s ! np.objdef ! p ! n ++ np.s ! NoPoss ! vps.c2 ++ np.postmod
|
||||
} ;
|
||||
|
||||
ReflVPS2 vps rnp = {
|
||||
s = \\p,n => vps.s ! rnp.objdef ! p ! n ++ rnp.s ! NoPoss ! vps.c2 ++ rnp.postmod
|
||||
} ;
|
||||
|
||||
BaseVPS2 x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s ;
|
||||
c2 = y.c2
|
||||
} ;
|
||||
|
||||
ConsVPS2 x xs = {
|
||||
s1 = \\od,p,n => x.s ! od ! p ! n ++ bindComma ++ xs.s1 ! od ! p ! n ;
|
||||
s2 = xs.s2 ;
|
||||
c2 = xs.c2
|
||||
} ;
|
||||
|
||||
ConjVPS2 conj xs = {
|
||||
s = \\od,p,n => xs.s1 ! od ! p ! n ++ conj.s2 ++ xs.s2 ! od ! p ! n ;
|
||||
c2 = xs.c2
|
||||
} ;
|
||||
|
||||
MkVPI2 vps = {
|
||||
s = \\_ => infVPSlash vps ;
|
||||
c2 = vps.c2
|
||||
} ;
|
||||
|
||||
ComplVPI2 vpi np = {
|
||||
s = vpi.s ! np.objdef ++ np.s ! NoPoss ! vpi.c2 ++ np.postmod
|
||||
} ;
|
||||
|
||||
BaseVPI2 x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s ;
|
||||
c2 = y.c2
|
||||
} ;
|
||||
|
||||
ConsVPI2 x xs = {
|
||||
s1 = \\od => x.s ! od ++ bindComma ++ xs.s1 ! od ;
|
||||
s2 = xs.s2 ;
|
||||
c2 = xs.c2
|
||||
} ;
|
||||
|
||||
ConjVPI2 conj xs = {
|
||||
s = \\od => xs.s1 ! od ++ conj.s2 ++ xs.s2 ! od ;
|
||||
c2 = xs.c2
|
||||
} ;
|
||||
|
||||
BaseComp x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s
|
||||
} ;
|
||||
|
||||
ConsComp x xs = {
|
||||
s1 = \\vf => x.s ! vf ++ bindComma ++ xs.s1 ! vf ;
|
||||
s2 = xs.s2
|
||||
} ;
|
||||
|
||||
ConjComp conj xs = UseCopula ** {
|
||||
s = \\vf => xs.s1 ! vf ++ conj.s2 ++ xs.s2 ! vf
|
||||
} ;
|
||||
|
||||
BaseImp x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s
|
||||
} ;
|
||||
|
||||
ConsImp x xs = {
|
||||
s1 = \\n,p => x.s ! n ! p ++ bindComma ++ xs.s1 ! n ! p ;
|
||||
s2 = xs.s2
|
||||
} ;
|
||||
|
||||
ConjImp conj xs = {
|
||||
s = \\n,p => xs.s1 ! n ! p ++ conj.s2 ++ xs.s2 ! n ! p
|
||||
} ;
|
||||
|
||||
PresPartAP vp = emptyAP ** {
|
||||
s = \\_,_ => vp.obj ++ vp.adv ++ vp.s ! VPresPart
|
||||
} ;
|
||||
|
||||
EmbedPresPart vp = {s = infVP vp} ;
|
||||
|
||||
PastPartAP vps = emptyAP ** {
|
||||
s = \\_,_ => vps.adv ++ vps.s ! Indef ! VAdvPart
|
||||
} ;
|
||||
|
||||
PastPartAgentAP vps np = emptyAP ** {
|
||||
s = \\_,_ =>
|
||||
vps.adv ++ vps.s ! Indef ! VAdvPart
|
||||
++ applyAdp (caseAdp Nom "által") np
|
||||
} ;
|
||||
|
||||
PassVPSlash vps = passiveVP vps [] ;
|
||||
|
||||
PassAgentVPSlash vps np =
|
||||
passiveVP vps (applyAdp (caseAdp Nom "által") np) ;
|
||||
|
||||
ProgrVPSlash vps = vps ;
|
||||
|
||||
ComplBareVS vs s = useV vs ** {
|
||||
adv = s.s
|
||||
} ;
|
||||
|
||||
ReflRNP vps rnp = insertObj vps rnp ;
|
||||
|
||||
ReflPron = indeclNP "magát" ** {objdef = Def ; g = Human} ;
|
||||
|
||||
ReflPoss num cn = DetCN (DetQuant DefArt num) cn ;
|
||||
|
||||
PredetRNP predet rnp = rnp ** {
|
||||
s = \\p,c => predet.s ++ rnp.s ! p ! c
|
||||
} ;
|
||||
|
||||
AdvRNP np prep rnp = np ** {
|
||||
s = \\p,c => np.s ! p ! c ++ applyAdp prep rnp ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
AdvRVP vp prep rnp = insertAdv vp {
|
||||
s = applyAdp prep rnp
|
||||
} ;
|
||||
|
||||
AdvRAP ap prep rnp = ap ** {
|
||||
compl = \\n => ap.compl ! n ++ applyAdp prep rnp
|
||||
} ;
|
||||
|
||||
ReflA2RNP a2 rnp =
|
||||
let ap : AP = ComplA2 a2 rnp in ap ;
|
||||
|
||||
PossPronRNP pron num cn rnp =
|
||||
let det : Determiner = DetQuant (PossPron pron) num
|
||||
in emptyNP ** cn ** det ** {
|
||||
s = \\_,c =>
|
||||
rnp.s ! NoPoss ! Nom
|
||||
++ caseFromPossStem cn det c
|
||||
++ cn.compl ! det.n ! c ;
|
||||
agr = <P3,det.n> ;
|
||||
objdef = Def ;
|
||||
g = NonHuman
|
||||
} ;
|
||||
|
||||
Base_rr_RNP x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s ;
|
||||
agr = y.agr ;
|
||||
g = y.g ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
Base_nr_RNP x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s ;
|
||||
agr = y.agr ;
|
||||
g = y.g ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
Base_rn_RNP x y = {
|
||||
s1 = x.s ;
|
||||
s2 = y.s ;
|
||||
agr = y.agr ;
|
||||
g = y.g ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
ConjRNP conj xs = emptyNP ** {
|
||||
s = \\p,c => xs.s1 ! p ! c ++ conj.s2 ++ xs.s2 ! p ! c ;
|
||||
agr = <P3,conj.n> ;
|
||||
objdef = Def ;
|
||||
g = xs.g ;
|
||||
postmod = [] ;
|
||||
empty = []
|
||||
} ;
|
||||
|
||||
GerundCN vp =
|
||||
let gn : Str = infVP vp
|
||||
in {
|
||||
s = \\_ => gn ;
|
||||
h = H_a ;
|
||||
g = NonHuman ;
|
||||
compl = \\_,_ => [] ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
GerundNP vp = MassNP (GerundCN vp) ;
|
||||
|
||||
GerundAdv vp = {
|
||||
s = infVP vp ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
CompoundAP n a = emptyAP ** {
|
||||
s = \\_,_ => n.s ! SgNom ++ a.s ! Posit ! SgNom
|
||||
} ;
|
||||
|
||||
WithoutVP vp = {
|
||||
s = infVP vp ++ "nélkül" ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
ByVP vp = {
|
||||
s = infVP vp ++ "által" ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
InOrderToVP vp = {
|
||||
s = infVP vp ++ "céljából" ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
ApposNP np1 np2 = np1 ** {
|
||||
s = \\p,c => np1.s ! p ! c ++ bindComma ++ np2.s ! NoPoss ! Nom ;
|
||||
postmod = []
|
||||
} ;
|
||||
|
||||
AdAdV ada adv = {
|
||||
s = ada.s ++ adv.s
|
||||
} ;
|
||||
|
||||
UttAdV adv = {
|
||||
s = adv.s
|
||||
} ;
|
||||
|
||||
PositAdVAdj adj = {
|
||||
s = adj.s ! Posit ! SgNom
|
||||
} ;
|
||||
|
||||
UttVPShort vp = {
|
||||
s = infVP vp
|
||||
} ;
|
||||
|
||||
ComplSlashPartLast vps np = insertObj vps np ;
|
||||
|
||||
iFem_Pron = pronTable ! <P1,Sg> ** {g = Human} ;
|
||||
theyFem_Pron = pronTable ! <P3,Pl> ** {g = Human} ;
|
||||
theyNeutr_Pron = pronTable ! <P3,Pl> ;
|
||||
weFem_Pron = pronTable ! <P1,Pl> ** {g = Human} ;
|
||||
youFem_Pron = pronTable ! <P2,Sg> ** {g = Human} ;
|
||||
youPlFem_Pron = pronTable ! <P2,Pl> ** {g = Human} ;
|
||||
youPolFem_Pron = pronTable ! <P2,Sg> ** {g = Human} ;
|
||||
youPolPlFem_Pron = pronTable ! <P2,Pl> ** {g = Human} ;
|
||||
youPolPl_Pron = pronTable ! <P2,Pl> ** {g = Human} ;
|
||||
|
||||
oper
|
||||
passiveVP : VPSlash -> Str -> VP = \vps,agent ->
|
||||
lin VP (useV (copula ** {
|
||||
s = \\vf => case vf of {
|
||||
VPres P3 _ => [] ;
|
||||
_ => copula.s ! vf
|
||||
}
|
||||
}) ** {
|
||||
adv = vps.adv ++ vps.s ! Indef ! VAdvPart ++ agent
|
||||
}) ;
|
||||
|
||||
} ;
|
||||
|
||||
@@ -12,7 +12,8 @@ concrete GrammarHun of Grammar =
|
||||
TextX - [Adv],
|
||||
StructuralHun,
|
||||
IdiomHun,
|
||||
TenseX - [Adv]
|
||||
TenseX - [Adv],
|
||||
NamesHun
|
||||
** {
|
||||
|
||||
flags startcat = Phr ; unlexer = text ; lexer = text ;
|
||||
|
||||
@@ -44,4 +44,51 @@ concrete IdiomHun of Idiom = CatHun ** open Prelude, ResHun, VerbHun, NounHun, S
|
||||
SelfNP : NP -> NP ; -- the president himself (is at home)
|
||||
-}
|
||||
|
||||
lin
|
||||
ImpersCl vp = predVP emptyNP vp ;
|
||||
|
||||
ExistNP np = existNP np [] ;
|
||||
|
||||
ExistNPAdv np adv = existNP np adv.s ;
|
||||
|
||||
ExistIP ip = {
|
||||
s = \\t,a,p =>
|
||||
ip.s ! NoPoss ! Nom
|
||||
++ if_then_Pol p [] "nem"
|
||||
++ copula.s ! case t of {
|
||||
Past => VPast P3 ip.agr.p2 ;
|
||||
_ => VPres P3 ip.agr.p2
|
||||
}
|
||||
} ;
|
||||
|
||||
ExistIPAdv ip adv = {
|
||||
s = \\t,a,p =>
|
||||
ip.s ! NoPoss ! Nom
|
||||
++ adv.s
|
||||
++ if_then_Pol p [] "nem"
|
||||
++ copula.s ! case t of {
|
||||
Past => VPast P3 ip.agr.p2 ;
|
||||
_ => VPres P3 ip.agr.p2
|
||||
}
|
||||
} ;
|
||||
|
||||
ProgrVP vp = vp ;
|
||||
|
||||
ImpPl1 vp = {
|
||||
s = "próbáljunk" ++ infVP vp
|
||||
} ;
|
||||
|
||||
oper
|
||||
existNP : NounPhrase -> Str -> ResHun.ClSlash = \np,adv -> {
|
||||
s = \\t,_,p =>
|
||||
if_then_Pol p [] "nem"
|
||||
++ copula.s ! case t of {
|
||||
Past => VPast P3 np.agr.p2 ;
|
||||
_ => VPres P3 np.agr.p2
|
||||
}
|
||||
++ linNP np
|
||||
++ adv ;
|
||||
c2 = Acc
|
||||
} ;
|
||||
|
||||
}
|
||||
|
||||
46
src/hungarian/IrregHun.gf
Normal file
46
src/hungarian/IrregHun.gf
Normal file
@@ -0,0 +1,46 @@
|
||||
--# -path=.:prelude:../abstract:../common
|
||||
concrete IrregHun of IrregHunAbs = CatHun ** open ParadigmsHun in {
|
||||
lin
|
||||
áll_V = mkV "állok" "állsz" "áll" "állunk" "álltok" "állnak"
|
||||
"álltam" "álltál" "állt" "álltunk" "álltatok" "álltak"
|
||||
"állni" "álló" "állva" ;
|
||||
átugrik_V = mkV "átugrom" "átugrasz" "átugrik" "átugrunk" "átugrotok" "átugranak"
|
||||
"átugrottam" "átugrottál" "átugrott" "átugrottunk" "átugrottatok" "átugrottak"
|
||||
"átugrani" "átugrikó" "átugrikva" ;
|
||||
bovelkedik_V = mkV "bővelkedem" "bővelkedsz" "bővelkedik" "bővelkedünk" "bővelkedtek" "bővelkednek"
|
||||
"bővelkedtem" "bővelkedtél" "bővelkedett" "bővelkedtünk" "bővelkedtetek" "bővelkedtek"
|
||||
"bővelkedni" "bővelkedő" "bővelkedve" ;
|
||||
csatlakozik_V = mkV "csatlakozom" "csatlakozol" "csatlakozik" "csatlakozunk" "csatlakoztok" "csatlakoznak"
|
||||
"csatlakoztam" "csatlakoztál" "csatlakozott" "csatlakoztunk" "csatlakoztatok" "csatlakoztak"
|
||||
"csatlakozni" "csatlakozó" "csatlakozva" ;
|
||||
csökken_V = mkV "csökkenek" "csökkensz" "csökken" "csökkenünk" "csökkentek" "csökkennek"
|
||||
"csökkentem" "csökkentél" "csökkent" "csökkentünk" "csökkentetek" "csökkentek"
|
||||
"csökkenni" "csökkenő" "csökkenve" ;
|
||||
dolgozik_V = mkV "dolgozom" "dolgozol" "dolgozik" "dolgozunk" "dolgoztok" "dolgoznak"
|
||||
"dolgoztam" "dolgoztál" "dolgozott" "dolgoztunk" "dolgoztatok" "dolgoztak"
|
||||
"dolgozni" "dolgozó" "dolgozva" ;
|
||||
elvet_V = mkV "elvetek" "elvetsz" "elvet" "elvetünk" "elvettek" "elvetnek"
|
||||
"elvetettem" "elvetettél" "elvetett" "elvetettünk" "elvetettetek" "elvetettek"
|
||||
"elvetni" "elvető" "elvetve" ;
|
||||
eszik_V = mkV "eszem" "eszel" "eszik" "eszünk" "esztek" "esznek"
|
||||
"ettem" "ettél" "evett" "ettünk" "ettetek" "ettek"
|
||||
"enni" "evő" "éve" ;
|
||||
fut_V = mkV "futok" "futsz" "fut" "futunk" "futtok" "futnak"
|
||||
"futottam" "futottál" "futott" "futottunk" "futottatok" "futottak"
|
||||
"futni" "futó" "futva" ;
|
||||
jár_V = mkV "járok" "jársz" "jár" "járunk" "jártok" "járnak"
|
||||
"jártam" "jártál" "járt" "jártunk" "jártatok" "jártak"
|
||||
"járni" "járó" "járva" ;
|
||||
küld_V = mkV "küldök" "küldesz" "küld" "küldünk" "küldötök" "küldenek"
|
||||
"küldtem" "küldtél" "küldött" "küldtünk" "küldtetek" "küldtek"
|
||||
"küldeni" "küldő" "küldve" ;
|
||||
meglátogat_V = mkV "meglátogatok" "meglátogatsz" "meglátogat" "meglátogatunk" "meglátogattok" "meglátogatnak"
|
||||
"meglátogattam" "meglátogattál" "meglátogatott" "meglátogattunk" "meglátogattatok" "meglátogattak"
|
||||
"meglátogatni" "meglátogató" "meglátogatva" ;
|
||||
tud_V = mkV "tudok" "tudsz" "tud" "tudunk" "tudtok" "tudnak"
|
||||
"tudtam" "tudtál" "tudott" "tudtunk" "tudtatok" "tudtak"
|
||||
"tudni" "tudó" "tudva" ;
|
||||
úszik_V = mkV "úszom" "úszol" "úszik" "úszunk" "úsztok" "úsznak"
|
||||
"úsztam" "úsztál" "úszott" "úsztunk" "úsztatok" "úsztak"
|
||||
"úszni" "úszó" "úszva" ;
|
||||
}
|
||||
17
src/hungarian/IrregHunAbs.gf
Normal file
17
src/hungarian/IrregHunAbs.gf
Normal file
@@ -0,0 +1,17 @@
|
||||
abstract IrregHunAbs = Cat ** {
|
||||
fun
|
||||
áll_V : V ;
|
||||
átugrik_V : V ;
|
||||
bovelkedik_V : V ;
|
||||
csatlakozik_V : V ;
|
||||
csökken_V : V ;
|
||||
dolgozik_V : V ;
|
||||
elvet_V : V ;
|
||||
eszik_V : V ;
|
||||
fut_V : V ;
|
||||
jár_V : V ;
|
||||
küld_V : V ;
|
||||
meglátogat_V : V ;
|
||||
tud_V : V ;
|
||||
úszik_V : V ;
|
||||
}
|
||||
@@ -1,4 +1,6 @@
|
||||
concrete LangHun of Lang =
|
||||
GrammarHun,
|
||||
LexiconHun,
|
||||
ConstructionHun ;
|
||||
ConstructionHun,
|
||||
DocumentationHun --# notpresent
|
||||
;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
concrete LexiconHun of Lexicon = CatHun **
|
||||
open ParadigmsHun, ParamHun, Prelude in {
|
||||
open ParadigmsHun, ParamHun, IrregHun, Prelude in {
|
||||
|
||||
----
|
||||
-- A
|
||||
@@ -19,7 +19,7 @@ lin art_N = mkN "művészet" "művészetet" ;
|
||||
----
|
||||
-- B
|
||||
|
||||
lin baby_N = mkN "bébi" "bébit" ;
|
||||
lin baby_N = humanN (mkN "bébi" "bébit") ;
|
||||
-- lin back_N = mkN "" ;
|
||||
lin bad_A = mkA "rossz" ;
|
||||
lin bank_N = mkN "bank" "bankot" ;
|
||||
@@ -65,7 +65,7 @@ lin cat_N = mkN "macska" "macskát";
|
||||
lin ceiling_N = roof_N ;
|
||||
lin chair_N = mkN "szék" "széket";
|
||||
lin cheese_N = mkN "sajt" "sajtot" ;
|
||||
lin child_N = mkN "gyerek" "gyereket" ;
|
||||
lin child_N = humanN (mkN "gyerek" "gyereket") ;
|
||||
lin church_N = mkN "templom" "templomot" ;
|
||||
lin city_N = mkN "város" "várost" ;
|
||||
lin clean_A = mkA "tiszta" ;
|
||||
@@ -92,7 +92,7 @@ lin day_N = mkN "nap" "napot" ;
|
||||
-- lin dirty_A = mkA "" ;
|
||||
-- lin distance_N3 = mkN "" ;
|
||||
-- lin do_V2 = mkV2 do_V ;
|
||||
lin doctor_N = mkN "orvos" "orvost";
|
||||
lin doctor_N = humanN (mkN "orvos" "orvost");
|
||||
lin dog_N = mkN "kutya" "kutyát";
|
||||
lin door_N = mkN "ajtó" "ajtót" ;
|
||||
-- lin drink_V2 = mkV2 "" ;
|
||||
@@ -105,7 +105,7 @@ lin door_N = mkN "ajtó" "ajtót" ;
|
||||
|
||||
lin ear_N = mkN "fül" "fület";
|
||||
lin earth_N = mkN "föld" "földet";
|
||||
-- lin eat_V2 = mkV2 "" ;
|
||||
lin eat_V2 = mkV2 eszik_V ;
|
||||
lin egg_N = mkN "tojás" "tojást" ;
|
||||
lin empty_A = mkA "üres" ;
|
||||
lin enemy_N = mkN "ellenség" "ellenséget" ;
|
||||
@@ -139,7 +139,7 @@ lin forest_N = mkN "erdő" "erdőt" ;
|
||||
-- lin forget_V2 = mkV2 "" ;
|
||||
-- lin freeze_V = mkV "" ;
|
||||
lin fridge_N = mkN "hűtő" "hűtőt" ;
|
||||
lin friend_N = mkN "barát" "barátot" ;
|
||||
lin friend_N = humanN (mkN "barát" "barátot") ;
|
||||
lin fruit_N = mkN "gyümölcs" "gyümölcsöt" "gyümölcsök" "gyümölcse" ; --TODO: plural PossPl2 fails "gyümölcseitek" instead of "gyümölcseitök", wovel harmony changing?
|
||||
lin full_A = mkA "tele" ;
|
||||
-- --lin fun_AV
|
||||
@@ -148,7 +148,7 @@ lin full_A = mkA "tele" ;
|
||||
-- G
|
||||
|
||||
lin garden_N = mkN "kert" "kertet" ;
|
||||
lin girl_N = mkN "lány" "lányt";
|
||||
lin girl_N = humanN (mkN "lány" "lányt");
|
||||
-- lin give_V3 = mkV3 "" ;
|
||||
lin glove_N = mkN "kesztyű" "kesztyűt" ;
|
||||
-- lin go_V = mkV "" ;
|
||||
@@ -179,7 +179,7 @@ lin horse_N = mkN "ló" "lovat";
|
||||
lin hot_A = mkA "forró" ;
|
||||
lin house_N = mkN "ház" "házat" ;
|
||||
-- lin hunt_V2 = mkV2 "" ;
|
||||
lin husband_N = mkN "férj" "férjet";
|
||||
lin husband_N = humanN (mkN "férj" "férjet");
|
||||
|
||||
--------
|
||||
-- I - K
|
||||
@@ -190,7 +190,7 @@ lin iron_N = mkN "vas" "vasat" ;
|
||||
-- lin john_PN = mkPN "" ;
|
||||
-- lin jump_V = mkV "" ;
|
||||
-- lin kill_V2 = mkV2 "" ;
|
||||
lin king_N = mkN "király" "királyt" ;
|
||||
lin king_N = humanN (mkN "király" "királyt") ;
|
||||
lin knee_N = mkN "térd" "térdet";
|
||||
-- lin know_V2 = mkV2 "" ;
|
||||
-- lin know_VQ = mkVQ "" ;
|
||||
@@ -223,12 +223,12 @@ lin love_N = mkN "szerelem" "szerelmet";
|
||||
----
|
||||
-- M
|
||||
|
||||
lin man_N = mkN "férfi" "ak" harmA ; -- force plural allomorph and a-harmony
|
||||
lin man_N = humanN (mkN "férfi" "ak" harmA) ; -- force plural allomorph and a-harmony
|
||||
lin married_A2 = mkA2 "házas" Ins ;
|
||||
lin meat_N = mkN "hús" "húst";
|
||||
lin milk_N = mkN "tej" "tejet" ;
|
||||
lin moon_N = mkN "hold" "holdat" ;
|
||||
lin mother_N2 = mkN2 (mkN "anya" "anyát") ;
|
||||
lin mother_N2 = mkN2 (humanN (mkN "anya" "anyát")) ;
|
||||
lin mountain_N = mkN "hegy" "hegyet";
|
||||
lin mouth_N = mkN "száj" "szájat" ;
|
||||
lin music_N = mkN "zene" "zenét";
|
||||
@@ -259,12 +259,12 @@ lin paper_N = mkN "papír" "papírt" "papírok" "papírja" ;
|
||||
-- lin paris_PN = mkPN "Paris" ;
|
||||
lin peace_N = mkN "béke" "békét";
|
||||
lin pen_N = mkN "toll" "tollat" ;
|
||||
lin person_N = mkN "ember" "embert";
|
||||
lin person_N = humanN (mkN "ember" "embert");
|
||||
lin planet_N = mkN "bolygó" "bolygót" ;
|
||||
lin plastic_N = mkN "műanyag" "műanyagot" "műanyagok" "műanyaga" ;
|
||||
-- lin play_V = mkV "" ;
|
||||
lin policeman_N = mkN "rendőr" "rendőrt"; --the police "rendőrség"
|
||||
lin priest_N = mkN "pap" "papot" "papok" "papja" ;
|
||||
lin policeman_N = humanN (mkN "rendőr" "rendőrt"); --the police "rendőrség"
|
||||
lin priest_N = humanN (mkN "pap" "papot" "papok" "papja") ;
|
||||
-- lin pull_V2 = mkV2 "" ;
|
||||
-- lin push_V2 = mkV2 "" ;
|
||||
-- lin put_V2 = mkV2 "" ;
|
||||
@@ -272,12 +272,12 @@ lin priest_N = mkN "pap" "papot" "papok" "papja" ;
|
||||
-- --------
|
||||
-- -- Q - R
|
||||
--
|
||||
lin queen_N = mkN "kírálynő" "kírálynőt" ;
|
||||
lin queen_N = humanN (mkN "kírálynő" "kírálynőt") ;
|
||||
lin question_N = mkN "kérdés" "kérdést" ;
|
||||
lin radio_N = mkN "rádió" "rádiót" ;
|
||||
lin rain_N = mkN "eső" "esőt" ;
|
||||
-- lin rain_V0 = mkV "" ;
|
||||
-- lin read_V2 = mkV2 "" ;
|
||||
lin read_V2 = mkV2 "olvas" ;
|
||||
lin ready_A = mkA "kész" ;
|
||||
lin reason_N = mkN "ok" "okot" "okok" "oka" ;
|
||||
lin red_A = mkA "piros" ;
|
||||
@@ -363,7 +363,7 @@ lin table_N = mkN "asztal" "asztalt";
|
||||
lin tail_N = mkN "farok" "farkot";
|
||||
lin talk_V3 = mkV3 "beszél" ;
|
||||
-- lin teach_V2 = mkV2 "" ;
|
||||
lin teacher_N = mkN "tanár" "tanárt" ;
|
||||
lin teacher_N = humanN (mkN "tanár" "tanárt") ;
|
||||
lin television_N = mkN "tévé" "tévét" ; --also "televízió" but not used
|
||||
lin thick_A = mkA "vastag" ;
|
||||
lin thin_A = mkA "vekony" ;
|
||||
@@ -401,14 +401,14 @@ lin water_N = mkN "víz" "vizet" ;
|
||||
lin wet_A = mkA "nedves" ;
|
||||
lin white_A = mkA "fehér" ;
|
||||
lin wide_A = mkA "széles" ;
|
||||
lin wife_N = mkN "feleség" "feleséget" ;
|
||||
lin wife_N = humanN (mkN "feleség" "feleséget") ;
|
||||
-- lin win_V2 = mkV2 "" ;
|
||||
lin wind_N = mkN "szél" "szelet" ;
|
||||
lin window_N = mkN "ablak" "ablakot" "ablakok" "ablaka" ;
|
||||
lin wine_N = mkN "bor" "bort";
|
||||
lin wing_N = mkN "szárny" "szárnyat";
|
||||
-- lin wipe_V2 = mkV2 "" ;
|
||||
lin woman_N = mkN "nő" "nőt" ;
|
||||
lin woman_N = humanN (mkN "nő" "nőt") ;
|
||||
-- lin wonder_VQ = mkVQ "" ;
|
||||
lin wood_N = mkN "fa" "fát"; --same as tree
|
||||
lin worm_N = mkN "féreg" "férget"; --also "kukac"
|
||||
|
||||
30
src/hungarian/NamesHun.gf
Normal file
30
src/hungarian/NamesHun.gf
Normal file
@@ -0,0 +1,30 @@
|
||||
concrete NamesHun of Names = CatHun ** open ResHun, Prelude in {
|
||||
|
||||
lin
|
||||
GivenName gn = gn ** {g = Human ; objdef = Def} ;
|
||||
MaleSurname sn = sn ** {g = Human ; objdef = Def} ;
|
||||
FemaleSurname sn = sn ** {g = Human ; objdef = Def} ;
|
||||
PlSurname sn = sn ** {g = Human ; objdef = Def ; agr = <P3,Pl>} ;
|
||||
|
||||
FullName gn sn = emptyNP ** {
|
||||
s = \\p,c => gn.s ! p ! Nom ++ sn.s ! p ! c ;
|
||||
agr = <P3,Sg> ;
|
||||
objdef = Def ;
|
||||
g = Human ;
|
||||
postmod = [] ;
|
||||
empty = []
|
||||
} ;
|
||||
|
||||
UseLN ln = ln ** {objdef = Def} ;
|
||||
PlainLN ln = ln ** {objdef = Def} ;
|
||||
|
||||
InLN ln = {
|
||||
s = ln.s ! NoPoss ! Ine ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
AdjLN ap ln = ln ** {
|
||||
s = \\p,c => ap.s ! Sg ! Nom ++ ln.s ! p ! c
|
||||
} ;
|
||||
|
||||
}
|
||||
@@ -3,6 +3,10 @@ concrete NounHun of Noun = CatHun ** open
|
||||
|
||||
flags optimize=all_subs ;
|
||||
|
||||
oper
|
||||
hunV : pattern Str = #("a"|"e"|"i"|"o"|"u"|"ö"|"ü"|
|
||||
"á"|"é"|"í"|"ó"|"ú"|"ő"|"ű") ;
|
||||
|
||||
lin
|
||||
|
||||
--2 Noun phrases
|
||||
@@ -65,7 +69,7 @@ concrete NounHun of Noun = CatHun ** open
|
||||
|
||||
-- : NP -> RS -> NP ; -- Paris, which is here
|
||||
RelNP np rs = np ** {
|
||||
s = \\p,c => np.s ! p ! c ++ bindComma ++ rs.s ! np.agr.p2 ! c ;
|
||||
s = \\p,c => np.s ! p ! c ++ bindComma ++ rs.s ! np.g ! np.agr.p2 ! c ;
|
||||
} ;
|
||||
|
||||
-- Determiners can form noun phrases directly.
|
||||
@@ -144,22 +148,24 @@ concrete NounHun of Noun = CatHun ** open
|
||||
-- : Numeral -> Card ;
|
||||
NumNumeral num = num ;
|
||||
|
||||
{-
|
||||
-- : AdN -> Card -> Card ;
|
||||
AdNum adn card = card ** { s = adn.s ++ card.s } ;
|
||||
AdNum adn card = card ** { s = \\p => adn.s ++ card.s ! p } ;
|
||||
|
||||
-- : Digits -> Ord ;
|
||||
OrdDigits digs = digs ** { s = digs.s ! NOrd } ;
|
||||
OrdDigits digs = {
|
||||
s = \\_,_ => digs.s ! NOrd ;
|
||||
n = Sg
|
||||
} ;
|
||||
|
||||
-- : Numeral -> Ord ;
|
||||
OrdNumeral num = num ** {
|
||||
s = \\_ => num.ord
|
||||
OrdNumeral num = {
|
||||
s = \\_,_ => num.s ! Attrib ;
|
||||
n = Sg
|
||||
} ;
|
||||
-}
|
||||
-- : A -> Ord ;
|
||||
OrdSuperl a = {
|
||||
s = \\n,c =>
|
||||
let adj : Noun = (a ** {s = a.s ! Superl}) in
|
||||
let adj : Noun = (a ** {s = a.s ! Superl; g=NonHuman}) in
|
||||
caseFromStem glue adj c n ;
|
||||
n = Sg -- ?? is this meaningful?
|
||||
} ;
|
||||
@@ -172,7 +178,7 @@ concrete NounHun of Noun = CatHun ** open
|
||||
-- : Quant
|
||||
DefArt = mkQuant "a" "a" ** {
|
||||
s,
|
||||
sp = \\_,_ => pre {"a" ; "az" / v } ;
|
||||
sp = \\_,_ => pre {"a" ; "az" / hunV } ;
|
||||
dt = DefDet ;
|
||||
} ;
|
||||
|
||||
@@ -185,7 +191,10 @@ concrete NounHun of Noun = CatHun ** open
|
||||
|
||||
-- : Pron -> Quant
|
||||
PossPron pron = pron ** {
|
||||
s,sp = \\_ => pron.s ;
|
||||
s,sp = \\_,_ => case pron.agr of {
|
||||
<P3,_> => "az" ++ pron.s ! Nom ;
|
||||
_ => pre {"a" ; "az" / hunV} ++ pron.s ! Nom
|
||||
} ;
|
||||
dt = DetPoss (agr2pstem pron.agr) ;
|
||||
caseagr = False ;
|
||||
} ;
|
||||
@@ -200,7 +209,9 @@ concrete NounHun of Noun = CatHun ** open
|
||||
} ;
|
||||
|
||||
-- : N2 -> NP -> CN ;
|
||||
-- ComplN2 n2 np =
|
||||
ComplN2 n2 np = (UseN n2) ** {
|
||||
compl = \\n,c => np.s ! NoPoss ! Dat ++ np.postmod
|
||||
} ;
|
||||
|
||||
-- : N3 -> NP -> N2 ; -- distance from this city (to Paris)
|
||||
-- ComplN3 n3 np =
|
||||
@@ -220,7 +231,7 @@ concrete NounHun of Noun = CatHun ** open
|
||||
|
||||
-- : CN -> RS -> CN ;
|
||||
RelCN cn rs = cn ** {
|
||||
compl = \\n,c => cn.compl ! n ! c ++ rs.s ! n ! c
|
||||
compl = \\n,c => cn.compl ! n ! c ++ rs.s ! cn.g ! n ! c
|
||||
} ;
|
||||
|
||||
-- : CN -> Adv -> CN ;
|
||||
@@ -234,7 +245,9 @@ concrete NounHun of Noun = CatHun ** open
|
||||
-- to decide. Sentential complements are defined in VerbHun.
|
||||
|
||||
-- : CN -> SC -> CN ; -- question where she sleeps
|
||||
-- SentCN cn sc = cn ** { } ;
|
||||
SentCN cn sc = cn ** {
|
||||
compl = \\n,c => cn.compl ! n ! c ++ sc.s
|
||||
} ;
|
||||
|
||||
--2 Apposition
|
||||
|
||||
@@ -248,29 +261,37 @@ concrete NounHun of Noun = CatHun ** open
|
||||
--2 Possessive and partitive constructs
|
||||
|
||||
-- : PossNP : CN -> NP -> CN ;
|
||||
-- PossNP cn np = cn ** {
|
||||
-- compl = \\n,c => cn.compl ! n ! c ++ np.s ! Poss P3 n ! c -- TODO check
|
||||
-- } ;
|
||||
PossNP cn np = cn ** {
|
||||
compl = \\n,c => cn.compl ! n ! c ++ np.s ! NoPoss ! Dat ++ np.postmod
|
||||
} ;
|
||||
|
||||
-- : CN -> NP -> CN ; -- glass of wine / two kilos of red apples
|
||||
-- PartNP cn np = cn ** {
|
||||
-- } ;
|
||||
PartNP cn np = cn ** {
|
||||
compl = \\n,c => cn.compl ! n ! c ++ np.s ! NoPoss ! Nom ++ np.postmod
|
||||
} ;
|
||||
|
||||
{-
|
||||
-- : Det -> NP -> NP ; -- three of them, some of the boys
|
||||
CountNP det np = emptyNP ** det ** {
|
||||
s = \\_,c => det.sp ! c ++ np.s ! NoPoss ! Ela ++ np.postmod ;
|
||||
agr = <P3,det.n> ;
|
||||
objdef = dt2objdef det.dt
|
||||
} ;
|
||||
|
||||
-- This is different from the partitive, as shown by many languages.
|
||||
|
||||
-- : Det -> NP -> NP ;
|
||||
CountNP det np = np **
|
||||
{ } ; -- Nonsense for DefArt or IndefArt
|
||||
-- : Decimal -> MU -> NP ;
|
||||
QuantityNP dec mu = indeclNP
|
||||
(case mu.isPre of {
|
||||
True => mu.s ++ dec.s ! NCard ;
|
||||
False => dec.s ! NCard ++ mu.s
|
||||
}) ** {
|
||||
objdef = Def
|
||||
} ;
|
||||
|
||||
--3 Conjoinable determiners and ones with adjectives
|
||||
|
||||
-- : DAP -> AP -> DAP ; -- the large (one)
|
||||
AdjDAP dap ap = dap ** { } ;
|
||||
AdjDAP dap ap = dap ;
|
||||
|
||||
-- : Det -> DAP ; -- this (or that)
|
||||
DetDAP det = det ;
|
||||
-}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
resource NounMorphoHun = ParamHun ** open Prelude, Predef in {
|
||||
|
||||
oper
|
||||
Noun = {s : NumCaseStem => Str ; h : Harm} ;
|
||||
Noun = {s : NumCaseStem => Str ; h : Harm ; g : Gender} ;
|
||||
|
||||
-- Paradigm functions
|
||||
-- http://www.cse.chalmers.se/~aarne/articles/smart-preprint.pdf
|
||||
@@ -275,6 +275,7 @@ oper
|
||||
PossdSg_PossrSg1P2 => init possdSg_PossrSg1P2 ;
|
||||
PossdPl => possdPl } ;
|
||||
h = h ;
|
||||
g = NonHuman
|
||||
} ;
|
||||
|
||||
|
||||
@@ -571,7 +572,7 @@ oper
|
||||
<_,_ + #v> => endCaseVow ;
|
||||
<_,_ + #v + ("sz"|"z"|"s"|"zs"|"j"|"ly"|"l"|"r"|"n"|"ny"|"ssz"
|
||||
|"zz"|"ss"|"ll"|"rr"|"nn"|"ns"|"nsz"|"nz")> => endCaseConsAcc ;
|
||||
<True,_> => endCaseConsAccAt ;
|
||||
<True,_> => endCaseCons ;
|
||||
_ => endCaseCons } ;
|
||||
|
||||
-- Last consonant doubles before instrumental and translative
|
||||
@@ -593,7 +594,7 @@ oper
|
||||
|
||||
-- All other singular forms and stems
|
||||
c => w + endCaseSg c ! h } ;
|
||||
|
||||
g = NonHuman
|
||||
} ;
|
||||
|
||||
|
||||
|
||||
@@ -27,59 +27,77 @@ lin
|
||||
n9 = mkNum3 "kilenc" "kilencven" "kilencedik" ;
|
||||
|
||||
-- : Sub10 ; -- 1
|
||||
pot01 = mkNum3 "egy" "tíz" "első" ** {n=Sg} ;
|
||||
pot01 = mkNum3 "egy" "tíz" "első" ;
|
||||
-- : Digit -> Sub10 ; -- d * 1
|
||||
pot0 d = d ;
|
||||
|
||||
-- : Sub100 ; -- 10
|
||||
pot110 = {s = table {p => "tíz"} ; n = numNumber ; numtype = IsNum} ;
|
||||
pot110 = {s = table {p => "tíz"}} ;
|
||||
-- : Sub100 ; -- 11
|
||||
pot111 = {s = table {p => "tizenegy"} ; n = numNumber ; numtype = IsNum} ;
|
||||
pot111 = {s = table {p => "tizenegy"}} ;
|
||||
-- : Digit -> Sub100 ; -- 10 + d
|
||||
pot1to19 d =
|
||||
{s = table {p => "tizen" ++ d.s ! <Unit,p>} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => "tizen" ++ d.s ! <Unit,p>}} ;
|
||||
-- : Sub10 -> Sub100 ; -- coercion of 1..9
|
||||
pot0as1 n =
|
||||
{s = table {p => n.s ! <Unit,p>} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => n.s ! <Unit,p>}} ;
|
||||
|
||||
-- : Digit -> Sub100 ; -- d * 10
|
||||
pot1 d =
|
||||
{s = table {p => d.s ! <Ten,p>} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => d.s ! <Ten,p>}} ;
|
||||
-- : Digit -> Sub10 -> Sub100 ; -- d * 10 + n
|
||||
pot1plus d e =
|
||||
{s = table {p => (d.s ! <Ten,Attrib>) ++ e.s ! <Unit,p>} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => (d.s ! <Ten,Attrib>) ++ e.s ! <Unit,p>}} ;
|
||||
|
||||
-- : Sub100 -> Sub1000 ; -- coercion of 1..99
|
||||
pot1as2 n = n ;
|
||||
-- : Sub1000 ; -- a hundred
|
||||
pot21 =
|
||||
{s = table {p => "száz"}} ;
|
||||
-- : Sub10 -> Sub1000 ; -- m * 100
|
||||
pot2 d =
|
||||
{s = table {p => (d.s ! <Unit,Attrib>) ++ "száz"} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => (d.s ! <Unit,Attrib>) ++ "száz"}} ;
|
||||
-- : Sub10 -> Sub100 -> Sub1000 ; -- m * 100 + n
|
||||
pot2plus d e =
|
||||
{s = table {p => (d.s ! <Unit,Attrib>) ++ "száz" ++ e.s ! p} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => (d.s ! <Unit,Attrib>) ++ "száz" ++ e.s ! p}} ;
|
||||
|
||||
-- : Sub1000 -> Sub1000000 ; -- coercion of 1..999
|
||||
pot2as3 n = n ;
|
||||
-- : Sub1000000 ; -- a thousand
|
||||
pot31 =
|
||||
{s = table {p => "ezer"}} ;
|
||||
-- : Sub1000 -> Sub1000000 ; -- m * 1000
|
||||
pot3 n =
|
||||
{s = table {p => n.s ! Attrib ++ "ezer"} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => n.s ! Attrib ++ "ezer"}} ;
|
||||
-- : Sub1000 -> Sub1000 -> Sub1000000 ; -- m * 1000 + n
|
||||
pot3plus n m =
|
||||
{s = table {p => n.s ! Attrib ++ "ezer" ++ m.s ! p} ;
|
||||
n = numNumber ; numtype = IsNum} ;
|
||||
{s = table {p => n.s ! Attrib ++ "ezer" ++ m.s ! p}} ;
|
||||
pot3decimal d =
|
||||
{s = table {p => d.s ! NCard ++ "ezer"}} ;
|
||||
|
||||
pot3as4 n = n ;
|
||||
|
||||
pot41 =
|
||||
{s = table {p => "egymillió"}} ;
|
||||
pot4 n =
|
||||
{s = table {p => n.s ! Attrib ++ "millió"}} ;
|
||||
pot4plus n m =
|
||||
{s = table {p => n.s ! Attrib ++ "millió" ++ m.s ! p}} ;
|
||||
pot4as5 n = n ;
|
||||
pot4decimal d =
|
||||
{s = table {p => d.s ! NCard ++ "millió"}} ;
|
||||
|
||||
pot51 =
|
||||
{s = table {p => "egymilliárd"}} ;
|
||||
pot5 n =
|
||||
{s = table {p => n.s ! Attrib ++ "milliárd"}} ;
|
||||
pot5plus n m =
|
||||
{s = table {p => n.s ! Attrib ++ "milliárd" ++ m.s ! p}} ;
|
||||
pot5decimal d =
|
||||
{s = table {p => d.s ! NCard ++ "milliárd"}} ;
|
||||
|
||||
oper
|
||||
LinDigit : Type = {s : DForm*Place => Str ; n : Number} ;
|
||||
LinDigit : Type = {s : DForm*Place => Str} ;
|
||||
|
||||
mkNum3 : (x1,_,x3 : Str) -> LinDigit = \három,harminc,harmadik ->
|
||||
mkNum5 három harminc három harminc harmadik ;
|
||||
@@ -89,13 +107,8 @@ oper
|
||||
<Ten,Indep> => ti ;
|
||||
<Unit,Attrib> => ua ;
|
||||
<Ten, Attrib> => ta } ;
|
||||
-- ord = ord ; -- TODO figure out where to use ordinal
|
||||
n = numNumber ;
|
||||
numType = IsNum ;
|
||||
} ;
|
||||
|
||||
numNumber = Sg ;
|
||||
|
||||
-- numerals as sequences of digits
|
||||
lincat
|
||||
Dig = TDigit ;
|
||||
@@ -106,8 +119,7 @@ oper
|
||||
|
||||
-- : Dig -> Digits -> Digits ; -- 876
|
||||
IIDig d i = {
|
||||
s = \\x => d.s ++ BIND ++ i.s ! x ;
|
||||
n = numNumber
|
||||
s = \\x => d.s ++ BIND ++ i.s ! x
|
||||
} ;
|
||||
|
||||
D_0 = mkDig "0" ;
|
||||
@@ -122,21 +134,26 @@ oper
|
||||
D_9 = mkDig "9" ;
|
||||
|
||||
PosDecimal d = d ** {hasDot=False} ;
|
||||
NegDecinal d = {
|
||||
NegDecimal d = {
|
||||
s = \\x => "-" ++ BIND ++ d.s ! x ;
|
||||
n = numNumber ;
|
||||
hasDot=False
|
||||
} ;
|
||||
IFrac d i = {
|
||||
s = \\x => d.s ! x ++
|
||||
case d.hasDot of {
|
||||
True => BIND ;
|
||||
False => BIND ++ "." ++ BIND
|
||||
} ++ i.s ;
|
||||
hasDot=True
|
||||
} ;
|
||||
|
||||
oper
|
||||
mkDig : Str -> TDigit = \s -> {
|
||||
s = s ;
|
||||
n = numNumber
|
||||
} ;
|
||||
|
||||
TDigit = {
|
||||
s : Str ; -- TODO add ordinals
|
||||
n : Number
|
||||
} ;
|
||||
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@ oper
|
||||
mkN : (unoka : Str) -> (testvér : N) -> N ; -- Compound noun. Use: `mkN "unoka" (mkN "testvér")` (would give wrong harmony with `mkN "unokatestvér"`)
|
||||
} ;
|
||||
|
||||
humanN : N -> N = \n -> n ** {g = Human} ;
|
||||
|
||||
mkPN : overload {
|
||||
mkPN : Str -> PN ; -- Singular PN out of a string
|
||||
mkPN : Str -> Number -> PN -- PN with a given number
|
||||
@@ -58,6 +60,7 @@ oper
|
||||
-- Verbs
|
||||
mkV : overload {
|
||||
mkV : (sg3 : Str) -> V ; -- Predictable verb. Takes singular P3 form in present tense.
|
||||
mkV : (x1,_,_,_,_,_,_,_,_,_,_,_,x13 : Str) -> V ; -- Full present, past, and infinitive forms.
|
||||
-- mkV : (nore : Str) -> (hada : V) -> V ; -- Add a prefix to an existing verb, e.g. 노래+하다
|
||||
} ;
|
||||
|
||||
@@ -227,7 +230,12 @@ oper
|
||||
-- mkV : (nore : Str) -> (hada : V) -> V = \nore,hada -> hada ** {
|
||||
-- s = \\vf => nore + hada.s ! vf} ;
|
||||
mkV : (x1,_,_,_,_,_,x7 : Str) -> V = \sg1,sg2,sg3,pl1,pl2,pl3,inf ->
|
||||
lin V (mkVerbFull sg1 sg2 sg3 pl1 pl2 pl3 inf) ;
|
||||
lin V (mkVerbPres sg1 sg2 sg3 pl1 pl2 pl3 inf) ;
|
||||
mkV : (x1,_,_,_,_,_,_,_,_,_,_,_,_,_,x15 : Str) -> V =
|
||||
\sg1,sg2,sg3,pl1,pl2,pl3,pastSg1,pastSg2,pastSg3,pastPl1,pastPl2,pastPl3,inf,ppart,apart ->
|
||||
lin V (mkVerbFull sg1 sg2 sg3 pl1 pl2 pl3
|
||||
pastSg1 pastSg2 pastSg3 pastPl1 pastPl2 pastPl3
|
||||
inf ppart apart) ;
|
||||
} ;
|
||||
|
||||
copula = lin V ResHun.copula ;
|
||||
@@ -279,6 +287,7 @@ oper
|
||||
|
||||
mkV3 = overload {
|
||||
mkV3 : (plain : Str) -> V3 = \v3 -> lin V3 (mkVerb3 v3) ;
|
||||
mkV3 : V -> V3 = \v -> lin V3 (v2tov3 (vtov2 v)) ;
|
||||
} ;
|
||||
|
||||
mkPrep = overload {
|
||||
@@ -292,6 +301,7 @@ oper
|
||||
= \c -> lin Prep (ResHun.caseAdp c) ;
|
||||
|
||||
mkInterj : Str -> Interj = \s -> lin Interj {s = s} ;
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
mkMU : Str -> MU = \s -> lin MU {s=s; isPre=False} ;
|
||||
|
||||
}
|
||||
|
||||
@@ -56,6 +56,7 @@ oper
|
||||
-- Nouns
|
||||
|
||||
param
|
||||
Gender = Human | NonHuman ;
|
||||
|
||||
NumCaseStem =
|
||||
SgNom | SgAccStem | SgSup -- These may use 2-3 different stems
|
||||
@@ -73,16 +74,16 @@ param
|
||||
|
||||
Case =
|
||||
Nom | Acc | Dat
|
||||
-- | Ill -- Locatives
|
||||
| Ill -- Locatives
|
||||
| Ine
|
||||
| Ela
|
||||
| All
|
||||
| Ade
|
||||
| Abl
|
||||
-- | Sub
|
||||
| Sub
|
||||
| Sup
|
||||
-- | Del
|
||||
-- | Cau -- Causal-final 'for the purpose of, for the reason that'
|
||||
| Del
|
||||
| Cau -- Causal-final 'for the purpose of, for the reason that'
|
||||
| Ins -- Instrumental
|
||||
| Tra -- Translative
|
||||
-- | Ess | Ter | For
|
||||
@@ -198,14 +199,10 @@ param
|
||||
|
||||
VForm =
|
||||
VInf
|
||||
| VPres Person Number ;
|
||||
|
||||
oper
|
||||
|
||||
agr2vf : Person*Number -> VForm = \pn ->
|
||||
case <pn.p1,pn.p2> of {
|
||||
<p,n> => VPres p n
|
||||
} ;
|
||||
| VPres Person Number
|
||||
| VPast Person Number
|
||||
| VPresPart
|
||||
| VAdvPart ;
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Clauses
|
||||
|
||||
@@ -6,11 +6,11 @@ concrete PhraseHun of Phrase = CatHun ** open Prelude, ResHun in {
|
||||
UttS s = s ;
|
||||
UttQS qs = qs ;
|
||||
UttIAdv iadv = iadv ;
|
||||
{-
|
||||
UttImpSg pol imp =
|
||||
{s = pol.s ++ imp.s ! Sg ! pol.p} ;
|
||||
UttImpPl pol imp =
|
||||
UttImpPol = UttImpSg ;
|
||||
-}
|
||||
{s = pol.s ++ imp.s ! Pl ! pol.p} ;
|
||||
UttImpPol = UttImpPl ;
|
||||
UttIP,
|
||||
UttNP = \np -> {s = linNP np} ;
|
||||
UttVP vp = {s = vp.obj ++ vp.adv ++ vp.s ! VInf} ;
|
||||
@@ -24,6 +24,6 @@ concrete PhraseHun of Phrase = CatHun ** open Prelude, ResHun in {
|
||||
-- PConjConj conj = {s = conj.s1 ++ conj.s2 ! …} ;
|
||||
|
||||
NoVoc = {s = []} ;
|
||||
-- VocNP np = { s = "," ++ np.s ! … } ; -}
|
||||
VocNP np = {s = bindComma ++ linNP np} ;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,40 +1,49 @@
|
||||
concrete QuestionHun of Question = CatHun ** open
|
||||
Prelude, ResHun, ParadigmsHun, (NH=NounHun) in {
|
||||
Prelude, ResHun, ParadigmsHun, (NH=NounHun), (VH=VerbHun) in {
|
||||
|
||||
-- A question can be formed from a clause ('yes-no question') or
|
||||
-- with an interrogative.
|
||||
|
||||
{-
|
||||
lincat
|
||||
QVP = VerbPhrase ;
|
||||
|
||||
lin
|
||||
-- : Cl -> QCl ;
|
||||
QuestCl =
|
||||
QuestCl cl = cl ;
|
||||
|
||||
-- : IP -> VP -> QCl ;
|
||||
QuestVP ip vp =
|
||||
QuestVP ip vp = predVP ip vp ;
|
||||
|
||||
-- : IP -> ClSlash -> QCl ; -- whom does John love
|
||||
QuestSlash ip cls =
|
||||
QuestSlash ip cls = {
|
||||
s = \\t,a,p => ip.s ! NoPoss ! cls.c2 ++ cls.s ! t ! a ! p
|
||||
} ;
|
||||
|
||||
-- : IAdv -> Cl -> QCl ; -- why does John walk
|
||||
QuestIAdv iadv cls =
|
||||
QuestIAdv iadv cls = {
|
||||
s = \\t,a,p => iadv.s ++ cls.s ! t ! a ! p
|
||||
} ;
|
||||
|
||||
|
||||
-- : IComp -> NP -> QCl ; -- where is John?
|
||||
QuestIComp icomp np =
|
||||
QuestIComp icomp np = {
|
||||
s = \\_,_,p =>
|
||||
icomp.s ++ if_then_Pol p [] "nem" ++ linNP np
|
||||
} ;
|
||||
|
||||
|
||||
-- Interrogative pronouns can be formed with interrogative
|
||||
-- determiners, with or without a noun.
|
||||
|
||||
-- : IDet -> CN -> IP ; -- which five songs
|
||||
IdetCN idet cn = {…} ** NH.DetCN idet cn ;
|
||||
IdetCN idet cn = NH.DetCN idet cn ;
|
||||
|
||||
-- : IDet -> IP ; -- which five
|
||||
IdetIP idet = {…} ** NH.DetNP idet ;
|
||||
IdetIP idet = NH.DetNP idet ;
|
||||
|
||||
-- They can be modified with adverbs.
|
||||
-- : IP -> Adv -> IP ; -- who in Paris
|
||||
--AdvIP = NH.AdvNP ;
|
||||
AdvIP = NH.AdvNP ;
|
||||
|
||||
-- Interrogative quantifiers have number forms and can take number modifiers.
|
||||
|
||||
@@ -43,12 +52,14 @@ concrete QuestionHun of Question = CatHun ** open
|
||||
|
||||
-- Interrogative adverbs can be formed prepositionally.
|
||||
-- : Prep -> IP -> IAdv ; -- with whom
|
||||
PrepIP prep ip = ;
|
||||
PrepIP prep ip = {s = applyAdp prep ip} ;
|
||||
|
||||
-- They can be modified with other adverbs.
|
||||
|
||||
-- : IAdv -> Adv -> IAdv ; -- where in Paris
|
||||
-- AdvIAdv iadv adv =
|
||||
AdvIAdv iadv adv = {
|
||||
s = iadv.s ++ adv.s
|
||||
} ;
|
||||
|
||||
-- Interrogative complements to copulas can be both adverbs and
|
||||
-- pronouns.
|
||||
@@ -57,21 +68,16 @@ concrete QuestionHun of Question = CatHun ** open
|
||||
CompIAdv iadv = iadv ; -- where (is it)
|
||||
|
||||
-- : IP -> IComp ;
|
||||
CompIP ip = {s = ip.s ! Abs} ; -- who (is it)
|
||||
CompIP ip = {s = ip.s ! NoPoss ! Nom} ; -- who (is it)
|
||||
|
||||
|
||||
-- More $IP$, $IDet$, and $IAdv$ are defined in $Structural$.
|
||||
|
||||
-- Wh questions with two or more question words require a new, special category.
|
||||
|
||||
cat
|
||||
QVP ; -- buy what where
|
||||
fun
|
||||
ComplSlashIP : VPSlash -> IP -> QVP ; -- buys what
|
||||
AdvQVP : VP -> IAdv -> QVP ; -- lives where
|
||||
AddAdvQVP : QVP -> IAdv -> QVP ; -- buys what where
|
||||
|
||||
QuestQVP : IP -> QVP -> QCl ; -- who buys what where
|
||||
-}
|
||||
ComplSlashIP vps ip = VH.insertObj vps ip ;
|
||||
AdvQVP vp iadv = vp ** {adv = vp.adv ++ iadv.s} ;
|
||||
AddAdvQVP qvp iadv = qvp ** {adv = qvp.adv ++ iadv.s} ;
|
||||
QuestQVP ip qvp = predVP ip qvp ;
|
||||
|
||||
}
|
||||
|
||||
@@ -13,16 +13,30 @@ lin
|
||||
|
||||
-- : RP ;
|
||||
IdRP = {s =
|
||||
table {Sg => caseTable "ami" "amit" "aminek" -- nom, acc, dat
|
||||
"amibe" "amiben" "amiből" -- ill, ine, ela
|
||||
"amihez" "aminél" "amitől" -- all, ade, abl
|
||||
"amire" "amin" "amiről" -- sub, sup, del
|
||||
"amiért" "amivel" "amivé" ; -- cau, ins, tra
|
||||
Pl => caseTable "amik" "amiket" "amiknek" -- nom, acc, dat
|
||||
"amikbe" "amikben" "amikből" -- ill, ine, ela
|
||||
"amikhez" "amiknél" "amiktől" -- all, ade, abl
|
||||
"amikre" "amiken" "amikről" -- sub, sup, del
|
||||
"amikért" "amikkel" "amikké"}; -- cau, ins, tra
|
||||
table {
|
||||
Human =>
|
||||
table {Sg => caseTable "aki" "akit" "akinek" -- nom, acc, dat
|
||||
"akibe" "akiben" "akiből" -- ill, ine, ela
|
||||
"akihez" "akinél" "akitől" -- all, ade, abl
|
||||
"akire" "akin" "akiről" -- sub, sup, del
|
||||
"akiért" "akivel" "akivé" ; -- cau, ins, tra
|
||||
Pl => caseTable "akik" "akiket" "akiknek" -- nom, acc, dat
|
||||
"akikbe" "akikben" "akikből" -- ill, ine, ela
|
||||
"akikhez" "akiknél" "akiktől" -- all, ade, abl
|
||||
"akikre" "akiken" "akikről" -- sub, sup, del
|
||||
"akikért" "akikkel" "akikké"} ; -- cau, ins, tra
|
||||
NonHuman =>
|
||||
table {Sg => caseTable "ami" "amit" "aminek" -- nom, acc, dat
|
||||
"amibe" "amiben" "amiből" -- ill, ine, ela
|
||||
"amihez" "aminél" "amitől" -- all, ade, abl
|
||||
"amire" "amin" "amiről" -- sub, sup, del
|
||||
"amiért" "amivel" "amivé" ; -- cau, ins, tra
|
||||
Pl => caseTable "amik" "amiket" "amiknek" -- nom, acc, dat
|
||||
"amikbe" "amikben" "amikből" -- ill, ine, ela
|
||||
"amikhez" "amiknél" "amiktől" -- all, ade, abl
|
||||
"amikre" "amiken" "amikről" -- sub, sup, del
|
||||
"amikért" "amikkel" "amikké"} -- cau, ins, tra
|
||||
} ;
|
||||
} ;
|
||||
|
||||
-- : Prep -> NP -> RP -> RP ; -- the mother of whom
|
||||
|
||||
@@ -15,7 +15,7 @@ resource ResHun = NounMorphoHun ** open Prelude, Predef in {
|
||||
oper
|
||||
CNoun : Type = Noun ** {
|
||||
compl : Number => Case => Str ;
|
||||
postmod : Str ;
|
||||
postmod : Str
|
||||
} ;
|
||||
|
||||
mkCaseNoun : Str -> Number => Case => Str = \s ->
|
||||
@@ -75,6 +75,7 @@ oper
|
||||
agr : Person*Number ;
|
||||
objdef : ObjDef ;
|
||||
empty : Str ; -- standard trick for pro-drop
|
||||
g : Gender ;
|
||||
} ;
|
||||
|
||||
NounPhrase : Type = BaseNP ** {
|
||||
@@ -86,6 +87,7 @@ oper
|
||||
s = \\_,_ => [] ;
|
||||
agr = <P3,Sg> ;
|
||||
objdef = Indef ;
|
||||
g = NonHuman ;
|
||||
postmod, empty = [] ;
|
||||
} ;
|
||||
|
||||
@@ -395,6 +397,24 @@ oper
|
||||
<P3,Pl> => harm "nak" "nek" -- TODO allomorphs -anak, -enek
|
||||
} ;
|
||||
|
||||
endingsPastIndef : VerbEndings = table {
|
||||
<P1,Sg> => harm3 "tam" "tem" "tem" ;
|
||||
<P2,Sg> => harm "tál" "tél" ;
|
||||
<P3,Sg> => harm1 "t" ;
|
||||
<P1,Pl> => harm "tunk" "tünk" ;
|
||||
<P2,Pl> => harm3 "tatok" "tetek" "tötök" ;
|
||||
<P3,Pl> => harm "tak" "tek"
|
||||
} ;
|
||||
|
||||
endingsPastDef : VerbEndings = table {
|
||||
<P1,Sg> => harm3 "tam" "tem" "tem" ;
|
||||
<P2,Sg> => harm "tad" "ted" ;
|
||||
<P3,Sg> => harm "ta" "te" ;
|
||||
<P1,Pl> => harm "tuk" "tük" ;
|
||||
<P2,Pl> => harm "tátok" "tétek" ;
|
||||
<P3,Pl> => harm "ták" "ték"
|
||||
} ;
|
||||
|
||||
BaseVerb : Type = {
|
||||
sc : SubjCase ; -- subject case
|
||||
} ;
|
||||
@@ -406,7 +426,7 @@ oper
|
||||
c2 : Case -- object case
|
||||
} ;
|
||||
Verb3 : Type = Verb2 ** {
|
||||
-- c3 : Case -- indirect object case
|
||||
c3 : Case -- indirect object case
|
||||
} ;
|
||||
|
||||
datV2 : Verb -> Verb2 = \v -> {
|
||||
@@ -418,18 +438,44 @@ oper
|
||||
mkVerb2 : Str -> Verb2 = \sg3 -> vtov2 (mkVerb sg3) ;
|
||||
mkVerb3 : Str -> Verb3 = \sg3 -> v2tov3 (mkVerb2 sg3) ;
|
||||
|
||||
futureAux : ObjDef -> Person -> Number -> Str = \od,p,n ->
|
||||
case <od,p,n> of {
|
||||
<Indef,P1,Sg> => "fogok" ;
|
||||
<Indef,P2,Sg> => "fogsz" ;
|
||||
<Indef,P3,Sg> => "fog" ;
|
||||
<Indef,P1,Pl> => "fogunk" ;
|
||||
<Indef,P2,Pl> => "fogtok" ;
|
||||
<Indef,P3,Pl> => "fognak" ;
|
||||
<Def,P1,Sg> => "fogom" ;
|
||||
<Def,P2,Sg> => "fogod" ;
|
||||
<Def,P3,Sg> => "fogja" ;
|
||||
<Def,P1,Pl> => "fogjuk" ;
|
||||
<Def,P2,Pl> => "fogjátok" ;
|
||||
<Def,P3,Pl> => "fogják"
|
||||
} ;
|
||||
|
||||
vtov2 : Verb -> Verb2 = \v -> v ** {
|
||||
s = table {
|
||||
Def => let vDef : Verb = mkVerbReg endingsDef (v.s ! VInf) (v.s ! VPres P3 Sg)
|
||||
Def => let vDef : Verb = mkVerbRegPast endingsDef endingsPastDef
|
||||
(v.s ! VInf) (v.s ! VPres P3 Sg)
|
||||
in vDef.s ;
|
||||
Indef => v.s } ;
|
||||
c2 = Acc
|
||||
} ;
|
||||
v2tov3 : Verb2 -> Verb3 = \v -> v ** {c3 = Dat} ;
|
||||
|
||||
mkVerb : (sg3 : Str) -> Verb = mkVerbReg endingsIndef "TODO:infinitive" ; -- TODO
|
||||
mkVerb : (sg3 : Str) -> Verb = \sg3 ->
|
||||
let inf : Str
|
||||
= case sg3 of {
|
||||
_ + ("ít" | (#c + #c)) => sg3 + harm3 "ani" "eni" "eni" ! getHarm sg3 ;
|
||||
_ => sg3 + "ni"
|
||||
}
|
||||
in mkVerbReg endingsIndef inf sg3 ;
|
||||
|
||||
mkVerbReg : VerbEndings -> (inf, stem : Str) -> Verb = \hf,inf,stem ->
|
||||
mkVerbReg : VerbEndings -> (inf, stem : Str) -> Verb =
|
||||
\hf,inf,stem -> mkVerbRegPast hf endingsPastIndef inf stem ;
|
||||
|
||||
mkVerbRegPast : VerbEndings -> VerbEndings -> (inf, stem : Str) -> Verb = \hf,pastHf,inf,stem ->
|
||||
let h : Harm = getHarm stem ;
|
||||
sg1 : Str = stem + hf ! <P1,Sg> ! h ;
|
||||
sg2 : Str = stem + hf ! <P2,Sg> ! h ;
|
||||
@@ -437,10 +483,43 @@ oper
|
||||
pl1 : Str = stem + hf ! <P1,Pl> ! h ;
|
||||
pl2 : Str = stem + hf ! <P2,Pl> ! h ;
|
||||
pl3 : Str = stem + hf ! <P3,Pl> ! h ;
|
||||
in mkVerbFull sg1 sg2 sg3 pl1 pl2 pl3 inf ;
|
||||
pastSg1 : Str = stem + pastHf ! <P1,Sg> ! h ;
|
||||
pastSg2 : Str = stem + pastHf ! <P2,Sg> ! h ;
|
||||
pastSg3 : Str = stem + pastHf ! <P3,Sg> ! h ;
|
||||
pastPl1 : Str = stem + pastHf ! <P1,Pl> ! h ;
|
||||
pastPl2 : Str = stem + pastHf ! <P2,Pl> ! h ;
|
||||
pastPl3 : Str = stem + pastHf ! <P3,Pl> ! h ;
|
||||
ppart : Str = case sg3 of {
|
||||
x + "o" + y@("g"|"l") => x+y+"ó" ;
|
||||
_ + ("ér"|"éz"|"ít") => sg3 + "ő" ;
|
||||
_ => sg3 + "ó"
|
||||
} ;
|
||||
apart : Str = sg3 + harm "va" "ve" ! h
|
||||
in mkVerbFull sg1 sg2 sg3 pl1 pl2 pl3
|
||||
pastSg1 pastSg2 pastSg3 pastPl1 pastPl2 pastPl3
|
||||
inf ppart apart ;
|
||||
|
||||
mkVerbFull : (x1,_,_,_,_,_,x7 : Str) -> Verb =
|
||||
\sg1,sg2,sg3,pl1,pl2,pl3,inf -> {
|
||||
mkVerbPres : (x1,_,_,_,_,_,x7 : Str) -> Verb =
|
||||
\sg1,sg2,sg3,pl1,pl2,pl3,inf ->
|
||||
let h : Harm = getHarm sg3 ;
|
||||
pastSg1 : Str = sg3 + endingsPastIndef ! <P1,Sg> ! h ;
|
||||
pastSg2 : Str = sg3 + endingsPastIndef ! <P2,Sg> ! h ;
|
||||
pastSg3 : Str = sg3 + endingsPastIndef ! <P3,Sg> ! h ;
|
||||
pastPl1 : Str = sg3 + endingsPastIndef ! <P1,Pl> ! h ;
|
||||
pastPl2 : Str = sg3 + endingsPastIndef ! <P2,Pl> ! h ;
|
||||
pastPl3 : Str = sg3 + endingsPastIndef ! <P3,Pl> ! h ;
|
||||
ppart : Str = case sg3 of {
|
||||
x + "o" + y@("g"|"l") => x+y+"ó" ;
|
||||
_ + ("ér"|"éz"|"ít") => sg3 + "ő" ;
|
||||
_ => sg3 + "ó"
|
||||
} ;
|
||||
apart : Str = sg3 + harm "va" "ve" ! h
|
||||
in mkVerbFull sg1 sg2 sg3 pl1 pl2 pl3
|
||||
pastSg1 pastSg2 pastSg3 pastPl1 pastPl2 pastPl3
|
||||
inf ppart apart ;
|
||||
|
||||
mkVerbFull : (x1,_,_,_,_,_,_,_,_,_,_,_,_,_,x15 : Str) -> Verb =
|
||||
\sg1,sg2,sg3,pl1,pl2,pl3,pastSg1,pastSg2,pastSg3,pastPl1,pastPl2,pastPl3,inf,ppart,apart -> {
|
||||
s = table {
|
||||
VInf => inf ;
|
||||
VPres P1 Sg => sg1 ;
|
||||
@@ -448,7 +527,15 @@ oper
|
||||
VPres P3 Sg => sg3 ;
|
||||
VPres P1 Pl => pl1 ;
|
||||
VPres P2 Pl => pl2 ;
|
||||
VPres P3 Pl => pl3
|
||||
VPres P3 Pl => pl3 ;
|
||||
VPast P1 Sg => pastSg1 ;
|
||||
VPast P2 Sg => pastSg2 ;
|
||||
VPast P3 Sg => pastSg3 ;
|
||||
VPast P1 Pl => pastPl1 ;
|
||||
VPast P2 Pl => pastPl2 ;
|
||||
VPast P3 Pl => pastPl3 ;
|
||||
VPresPart => ppart ;
|
||||
VAdvPart => apart
|
||||
} ;
|
||||
sc = SCNom
|
||||
} ;
|
||||
@@ -460,7 +547,15 @@ oper
|
||||
"vagyunk"
|
||||
"vagytok"
|
||||
"vannak"
|
||||
"lenni" ;
|
||||
"voltam"
|
||||
"voltál"
|
||||
"volt"
|
||||
"voltunk"
|
||||
"voltatok"
|
||||
"voltak"
|
||||
"lenni"
|
||||
"levő"
|
||||
"léve" ;
|
||||
|
||||
megvan : Verb = copula ** {
|
||||
s = \\vf => "meg" + copula.s ! vf ;
|
||||
@@ -489,8 +584,22 @@ oper
|
||||
adv = [] ;
|
||||
} ;
|
||||
|
||||
insertAdv : VerbPhrase -> SS -> VerbPhrase = \vp,adv -> vp ** {adv = adv.s} ;
|
||||
insertAdvSlash : VPSlash -> SS -> VPSlash = \vps,adv -> vps ** {adv = adv.s} ;
|
||||
insertAdv : VerbPhrase -> SS -> VerbPhrase = \vp,adv -> vp ** {adv = vp.adv ++ adv.s} ;
|
||||
insertAdvSlash : VPSlash -> SS -> VPSlash = \vps,adv -> vps ** {adv = vps.adv ++ adv.s} ;
|
||||
|
||||
infVP : VerbPhrase -> Str = \vp ->
|
||||
vp.obj ++ vp.adv ++ vp.s ! VInf ;
|
||||
|
||||
infVPSlash : VPSlash -> Str = \vps ->
|
||||
vps.adv ++ vps.s ! Indef ! VInf ;
|
||||
|
||||
verbStemFromInf : Str -> Str = \inf ->
|
||||
case inf of {
|
||||
stem + "ani" => stem ;
|
||||
stem + "eni" => stem ;
|
||||
stem + "ni" => stem ;
|
||||
_ => inf
|
||||
} ;
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Cl, S
|
||||
@@ -515,7 +624,11 @@ oper
|
||||
SCDat => Dat }
|
||||
in linNP' NoPoss subjcase np
|
||||
++ if_then_Pol p [] "nem"
|
||||
++ vp.s ! agr2vf np.agr
|
||||
++ case <t,np.agr.p1,np.agr.p2> of {
|
||||
<Past,p,n> => vp.s ! VPast p n ;
|
||||
<Fut,p,n> => futureAux Indef p n ++ vp.s ! VInf ;
|
||||
<_,p,n> => vp.s ! VPres p n
|
||||
}
|
||||
++ vp.obj -- ! np.agr
|
||||
++ vp.adv
|
||||
++ np.empty -- standard trick for prodrop+metavariable problem
|
||||
@@ -523,27 +636,32 @@ oper
|
||||
|
||||
-- Relative
|
||||
|
||||
RP : Type = {s : Number => Case => Str} ;
|
||||
RClause : Type = {s : Tense => Anteriority => Polarity => Number => Case => Str} ;
|
||||
RP : Type = {s : Gender => Number => Case => Str} ;
|
||||
RClause : Type = {s : Tense => Anteriority => Polarity => Gender => Number => Case => Str} ;
|
||||
|
||||
relVP : RP -> VerbPhrase -> RClause = \rp -> relVP' (rp ** {agr=<P3,Sg>}) ;
|
||||
|
||||
relVP' : RP ** {agr : Person*Number} -> VerbPhrase -> RClause = \rp,vp -> {
|
||||
s = \\t,a,p,n,c => let subjcase : Case = case vp.sc of {
|
||||
s = \\t,a,p,g,n,c => let subjcase : Case = case vp.sc of {
|
||||
SCNom => Nom ;
|
||||
SCDat => Dat }
|
||||
in rp.s ! n ! subjcase
|
||||
in rp.s ! g ! n ! subjcase
|
||||
++ if_then_Pol p [] "nem"
|
||||
++ vp.obj -- ! <rp.agr.p1,n>
|
||||
++ vp.adv
|
||||
++ vp.s ! VPres rp.agr.p1 n -- variable by number
|
||||
++ case <t,rp.agr.p1,n> of {
|
||||
<Past,p,n> => vp.s ! VPast p n ;
|
||||
<Fut,p,n> => futureAux Indef p n ++ vp.s ! VInf ;
|
||||
<_,p,n> => vp.s ! VPres p n
|
||||
} -- variable by number
|
||||
} ;
|
||||
|
||||
relSlash : RP -> ClSlash -> RClause = \rp,cls -> {
|
||||
s = \\t,a,p,n,c => let objcase : Case = case cls.c2 of {
|
||||
Acc => c ;
|
||||
_ => cls.c2 }
|
||||
in rp.s ! n ! objcase
|
||||
s = \\t,a,p,g,n,c => let objcase : Case = case cls.c2 of {
|
||||
Acc => c ;
|
||||
_ => cls.c2
|
||||
}
|
||||
in rp.s ! g ! n ! objcase
|
||||
++ cls.s ! t ! a ! p
|
||||
} ;
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
@@ -11,16 +11,24 @@ lin
|
||||
PredVP = predVP ;
|
||||
|
||||
-- : SC -> VP -> Cl ; -- that she goes is good (Saeed p. 94)
|
||||
--PredSCVP sc vp = ;
|
||||
PredSCVP sc vp = predVP (indeclNP sc.s) vp ;
|
||||
|
||||
--2 Clauses missing object noun phrases
|
||||
-- : NP -> VPSlash -> ClSlash ;
|
||||
SlashVP np vps = predVP np (vps ** {s = vps.s ! Indef ; obj = []}) ;
|
||||
{-
|
||||
-- : ClSlash -> Adv -> ClSlash ; -- (whom) he sees today
|
||||
AdvSlash cls adv = cls ** insertAdv adv cls ;
|
||||
|
||||
-- SlashPrep : Cl -> Prep -> ClSlash ; -- (with whom) he walks
|
||||
-- : ClSlash -> Adv -> ClSlash ; -- (whom) he sees today
|
||||
AdvSlash cls adv = cls ** {
|
||||
s = \\t,a,p => cls.s ! t ! a ! p ++ adv.s
|
||||
} ;
|
||||
|
||||
-- : Cl -> Prep -> ClSlash ; -- (with whom) he walks
|
||||
SlashPrep cl prep = cl ** {
|
||||
c2 = prep.c ;
|
||||
s = \\t,a,p => cl.s ! t ! a ! p ++ prep.s
|
||||
} ;
|
||||
|
||||
{-
|
||||
|
||||
-- : NP -> VS -> SSlash -> ClSlash ; -- (whom) she says that he loves
|
||||
-- SlashVS np vs ss = {} ;
|
||||
@@ -31,21 +39,27 @@ lin
|
||||
} ;
|
||||
|
||||
--2 Imperatives
|
||||
-}
|
||||
-- : VP -> Imp ;
|
||||
ImpVP vp = {s = \\num,pol => linVP (VImp num pol) Statement vp} ;
|
||||
ImpVP vp = {
|
||||
s = \\num,pol =>
|
||||
if_then_Pol pol [] "ne"
|
||||
++ vp.s ! VPres P2 num
|
||||
++ vp.obj
|
||||
++ vp.adv
|
||||
} ;
|
||||
|
||||
--2 Embedded sentences
|
||||
-- : Adv -> Imp -> Imp ;
|
||||
AdvImp adv imp = {
|
||||
s = \\num,pol => adv.s ++ imp.s ! num ! pol
|
||||
} ;
|
||||
--2 Sentences
|
||||
|
||||
-- : S -> SC ;
|
||||
EmbedS s = {s = s.s ! True} ; -- choose subordinate
|
||||
EmbedS s = {s = s.s} ;
|
||||
|
||||
-- : QS -> SC ;
|
||||
-- EmbedQS qs = { } ;
|
||||
|
||||
-- : VP -> SC ;
|
||||
EmbedVP vp = {s = infVP vp} ;
|
||||
-}
|
||||
--2 Sentences
|
||||
EmbedQS qs = {s = qs.s} ;
|
||||
|
||||
-- : Temp -> Pol -> Cl -> S ;
|
||||
UseCl t p cl = {
|
||||
@@ -56,7 +70,7 @@ lin
|
||||
UseQCl t p cl = {s = t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p} ;
|
||||
|
||||
-- : Temp -> Pol -> RCl -> RS ;
|
||||
UseRCl t p cl = {s = \\n,c => t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! n ! c} ;
|
||||
UseRCl t p cl = {s = \\g,n,c => t.s ++ p.s ++ cl.s ! t.t ! t.a ! p.p ! g ! n ! c} ;
|
||||
|
||||
-- AdvS : Adv -> S -> S ; -- then I will go home
|
||||
AdvS = advS "" ;
|
||||
@@ -65,7 +79,9 @@ lin
|
||||
ExtAdvS = advS (SOFT_BIND ++ ",");
|
||||
|
||||
-- : S -> Subj -> S -> S ;
|
||||
-- SSubjS s1 subj s2 = AdvS (AK.SubjS subj s2) s1 ;
|
||||
SSubjS s1 subj s2 = {
|
||||
s = s1.s ++ bindComma ++ subj.s ++ s2.s
|
||||
} ;
|
||||
|
||||
-- : S -> RS -> S ; -- she sleeps, which is good
|
||||
-- RelS sent rs = advS {s = rs.s ! Sg3 Masc ++ SOFT_BIND ++ ","} sent ;
|
||||
|
||||
@@ -121,21 +121,54 @@ lin under_Prep = nomAdp "alatt" ;
|
||||
-- Pron
|
||||
|
||||
-- Pronouns are closed class, no constructor in ParadigmsHun.
|
||||
i_Pron = pronTable ! <P1,Sg> ;
|
||||
i_Pron = pronTable ! <P1,Sg> ** {g = Human} ;
|
||||
youPol_Pron,
|
||||
youSg_Pron = pronTable ! <P2,Sg> ;
|
||||
youSg_Pron = pronTable ! <P2,Sg> ** {g = Human} ;
|
||||
he_Pron,
|
||||
she_Pron,
|
||||
she_Pron = pronTable ! <P3,Sg> ** {g = Human} ;
|
||||
it_Pron = pronTable ! <P3,Sg> ;
|
||||
we_Pron = pronTable ! <P1,Pl> ;
|
||||
youPl_Pron = pronTable ! <P2,Pl> ;
|
||||
they_Pron = pronTable ! <P3,Pl> ;
|
||||
|
||||
--lin whatPl_IP = ;
|
||||
--lin whatSg_IP = :
|
||||
--lin whoPl_IP = ;
|
||||
--lin whoSg_IP = ;
|
||||
we_Pron = pronTable ! <P1,Pl> ** {g = Human} ;
|
||||
youPl_Pron = pronTable ! <P2,Pl> ** {g = Human} ;
|
||||
they_Pron = pronTable ! <P3,Pl> ** {g = Human} ;
|
||||
|
||||
lin whatPl_IP = emptyNP ** {
|
||||
s = \\_ => caseTable "mi" "mit" "minek"
|
||||
"mibe" "miben" "miből"
|
||||
"mihez" "minél" "mitől"
|
||||
"mire" "min" "miről"
|
||||
"miért" "mivel" "mivé" ;
|
||||
agr = <P3,Pl> ;
|
||||
objdef = Def
|
||||
} ;
|
||||
lin whatSg_IP = emptyNP ** {
|
||||
s = \\_ => caseTable "mi" "mit" "minek"
|
||||
"mibe" "miben" "miből"
|
||||
"mihez" "minél" "mitől"
|
||||
"mire" "min" "miről"
|
||||
"miért" "mivel" "mivé" ;
|
||||
agr = <P3,Sg> ;
|
||||
objdef = Def
|
||||
} ;
|
||||
lin whoPl_IP = emptyNP ** {
|
||||
s = \\_ => caseTable "ki" "kit" "kinek"
|
||||
"kibe" "kiben" "kiből"
|
||||
"kihez" "kinél" "kitől"
|
||||
"kire" "kin" "kiről"
|
||||
"kiért" "kivel" "kivé" ;
|
||||
agr = <P3,Pl> ;
|
||||
objdef = Def ;
|
||||
g = Human
|
||||
} ;
|
||||
lin whoSg_IP = emptyNP ** {
|
||||
s = \\_ => caseTable "ki" "kit" "kinek"
|
||||
"kibe" "kiben" "kiből"
|
||||
"kihez" "kinél" "kitől"
|
||||
"kire" "kin" "kiről"
|
||||
"kiért" "kivel" "kivé" ;
|
||||
agr = <P3,Pl> ;
|
||||
objdef = Def ;
|
||||
g = Human
|
||||
} ;
|
||||
-------
|
||||
-- Subj
|
||||
|
||||
|
||||
@@ -21,48 +21,59 @@ lin
|
||||
-- } ;
|
||||
|
||||
-- : VS -> S -> VP ;
|
||||
-- ComplVS vs s =
|
||||
-- let vps = useV vs ;
|
||||
-- subord = SubjS {s=""} s ;
|
||||
-- in vps ** {} ;
|
||||
ComplVS vs s = useV vs ** {
|
||||
adv = "hogy" ++ s.s
|
||||
} ;
|
||||
|
||||
{-
|
||||
-- : VQ -> QS -> VP ;
|
||||
ComplVQ vq qs = ;
|
||||
ComplVQ vq qs = useV vq ** {
|
||||
adv = qs.s
|
||||
} ;
|
||||
|
||||
-- : VA -> AP -> VP ; -- they become red
|
||||
ComplVA va ap = ResHun.insertObj (CompAP ap).s (useV va) ;
|
||||
ComplVA va ap = useV va ** {
|
||||
adv = ap.s ! Sg ! Nom ++ ap.compl ! Sg
|
||||
} ;
|
||||
|
||||
--------
|
||||
-- Slash
|
||||
-}
|
||||
|
||||
-- : V2 -> VPSlash
|
||||
SlashV2a = ResHun.useVc ;
|
||||
|
||||
{-
|
||||
-- : V3 -> NP -> VPSlash ; -- give it (to her)
|
||||
Slash2V3 v3 np = v3 ** {
|
||||
adv = np.s ! NoPoss ! v3.c2 ++ np.postmod ;
|
||||
c2 = v3.c3
|
||||
} ;
|
||||
|
||||
-- : V3 -> NP -> VPSlash ; -- give (it) to her
|
||||
Slash2V3,
|
||||
Slash3V3 = \v3 -> insertObj (useVc3 v3) ;
|
||||
Slash3V3 v3 np = v3 ** {
|
||||
adv = np.s ! NoPoss ! v3.c3 ++ np.postmod ;
|
||||
c2 = v3.c2
|
||||
} ;
|
||||
|
||||
-- : V2S -> S -> VPSlash ; -- answer (to him) that it is good
|
||||
SlashV2S v2s s =
|
||||
let vps = useVc v2s ;
|
||||
subord = SubjS {s=""} s ;
|
||||
in vps ** {obj = } ;
|
||||
SlashV2S v2s s = useVc v2s ** {
|
||||
adv = "hogy" ++ s.s
|
||||
} ;
|
||||
|
||||
|
||||
-- : V2V -> VP -> VPSlash ; -- beg (her) to go
|
||||
SlashV2V v2v vp = ;
|
||||
SlashV2V v2v vp = useVc v2v ** {
|
||||
adv = infVP vp
|
||||
} ;
|
||||
|
||||
-- : V2Q -> QS -> VPSlash ; -- ask (him) who came
|
||||
SlashV2Q v2q qs = ;
|
||||
SlashV2Q v2q qs = useVc v2q ** {
|
||||
adv = qs.s
|
||||
} ;
|
||||
|
||||
-- : V2A -> AP -> VPSlash ; -- paint (it) red
|
||||
SlashV2A v2a ap = useVc v2a ** {
|
||||
aComp = \\_ => (CompAP ap).aComp ! Sg3 Masc
|
||||
adv = ap.s ! Sg ! Nom ++ ap.compl ! Sg
|
||||
} ;
|
||||
-}
|
||||
|
||||
-- : VPSlash -> NP -> VP
|
||||
ComplSlash = insertObj ;
|
||||
{-
|
||||
@@ -89,19 +100,27 @@ lin
|
||||
|
||||
-- : VPSlash -> Adv -> VPSlash ; -- use (it) here
|
||||
AdvVPSlash = insertAdvSlash ;
|
||||
{-
|
||||
-- : VP -> Adv -> VP ; -- sleep , even though ...
|
||||
ExtAdvVP vp adv = vp ** { } ;
|
||||
ExtAdvVP vp adv = vp ** {
|
||||
adv = vp.adv ++ bindComma ++ adv.s
|
||||
} ;
|
||||
|
||||
-- : AdV -> VP -> VP ; -- always sleep
|
||||
AdVVP adv vp = vp ** { } ;
|
||||
AdVVP adv vp = vp ** {
|
||||
s = \\vf => adv.s ++ vp.s ! vf
|
||||
} ;
|
||||
|
||||
-- : AdV -> VPSlash -> VPSlash ; -- always use (it)
|
||||
AdVVPSlash adv vps = vps ** { } ;
|
||||
AdVVPSlash adv vps = vps ** {
|
||||
s = \\o,vf => adv.s ++ vps.s ! o ! vf
|
||||
} ;
|
||||
|
||||
-- : VP -> Prep -> VPSlash ; -- live in (it)
|
||||
VPSlashPrep vp prep =
|
||||
-}
|
||||
VPSlashPrep vp prep = vp ** {
|
||||
s = \\_ => vp.s ;
|
||||
adv = vp.obj ++ vp.adv ++ prep.s ;
|
||||
c2 = prep.c
|
||||
} ;
|
||||
|
||||
--2 Complements to copula
|
||||
|
||||
@@ -111,8 +130,10 @@ lin
|
||||
CompAP ap = UseCopula ** {
|
||||
s = \\vf => case vf of {
|
||||
VPres P3 n => ap.s ! n ! Nom ++ ap.compl ! n ;
|
||||
VPres _ n => ap.s ! n ! Nom ++ copula.s ! vf ++ ap.compl ! n ;
|
||||
_ => ap.s ! Sg ! Nom ++ copula.s ! vf ++ ap.compl ! Sg } ;
|
||||
VPres _ n => ap.s ! n ! Nom ++ copula.s ! vf ++ ap.compl ! n ;
|
||||
VPast _ n => ap.s ! n ! Nom ++ copula.s ! vf ++ ap.compl ! n ;
|
||||
_ => ap.s ! Sg ! Nom ++ copula.s ! vf ++ ap.compl ! Sg
|
||||
} ;
|
||||
} ;
|
||||
|
||||
-- : CN -> Comp ;
|
||||
@@ -164,9 +185,13 @@ insertObj : ResHun.VPSlash -> NounPhrase -> VerbPhrase = \vps,np -> vps ** {
|
||||
<SCDat,Nom> =>
|
||||
let agr : Person*Number = case vf of {
|
||||
VPres p n => <p,n> ;
|
||||
VPast p n => <p,n> ;
|
||||
_ => <P3,Sg> } ;
|
||||
objvf : VForm = case vf of {
|
||||
VPast _ _ => VPast np.agr.p1 np.agr.p2 ;
|
||||
_ => VPres np.agr.p1 np.agr.p2 } ;
|
||||
in np.s ! Poss agr.p1 agr.p2 ! vps.c2
|
||||
++ vps.s ! np.objdef ! agr2vf np.agr ;
|
||||
++ vps.s ! np.objdef ! objvf ;
|
||||
|
||||
-- Default case: Verb agrees in person and number with subject
|
||||
_ => vps.s ! np.objdef ! vf } ;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--# -path=.:abstract:common:prelude
|
||||
|
||||
concrete CatLav of Cat = CommonX - [Adv, CAdv] ** open ResLav, Prelude in {
|
||||
concrete CatLav of Cat = CommonX - [Adv, CAdv, Voc] ** open ResLav, Prelude in {
|
||||
|
||||
flags
|
||||
|
||||
@@ -110,6 +110,17 @@ lincat
|
||||
|
||||
N3 = Noun ** {prep1, prep2 : Preposition ; isPre1, isPre2 : Bool} ;
|
||||
|
||||
-- TODO Make most proper nouns more similar to nouns:
|
||||
-- (1) given names GN should have both numbers (to fit with Tēzaurs and to be
|
||||
-- able to express that there are multiple people in the room with the
|
||||
-- same name)
|
||||
-- (2) family names SN being inflected on gender doesn't fit neither with
|
||||
-- Tēzaurs, nor with the fact that for some masc surnames there are
|
||||
-- multiple legaly valid fem variants
|
||||
-- (3) if PN is meant to be generic proper noun, it might also be inflected
|
||||
-- in number
|
||||
-- In general Latvian tends to make every noun inflectable in all cases/numbers,
|
||||
-- the plural-only placenames like "Cēsis" is the one very stable exception.
|
||||
PN,LN = ProperNoun ;
|
||||
GN = {s : Case => Str ; gend : Gender} ;
|
||||
SN = {s : Gender => Case => Str; pl : Case => Str} ;
|
||||
|
||||
@@ -80,7 +80,8 @@ oper
|
||||
mkNounByDeclPal : Str -> Declension -> Bool -> Noun = \lemma,decl,pal ->
|
||||
case decl of {
|
||||
D0|D1|D2|D3 => mkNounByGendDeclPal lemma Masc decl pal ;
|
||||
D4|D5|D6|DR => mkNounByGendDeclPal lemma Fem decl pal
|
||||
D4|D5|D6|DR => mkNounByGendDeclPal lemma Fem decl pal ;
|
||||
DG => mkNounByGendDeclPal nonExist Fem decl pal -- FIX ME REMAKE
|
||||
} ;
|
||||
|
||||
-- Specified gender and declension; default palatalization
|
||||
@@ -97,7 +98,8 @@ oper
|
||||
D4 => mkNoun_D4 lemma gend ;
|
||||
D5 => mkNoun_D5 lemma gend pal ;
|
||||
D6 => mkNoun_D6 lemma gend pal ;
|
||||
DR => mkNoun_DR lemma
|
||||
DR => mkNoun_DR lemma ;
|
||||
DG => mkNoun_DR nonExist -- FIX ME REMAKE
|
||||
} ;
|
||||
|
||||
-- Indeclinable noun
|
||||
|
||||
@@ -43,13 +43,15 @@ oper
|
||||
mkRegVerb : Str -> Conjugation -> Verb_TMP = \lemma,conj ->
|
||||
case conj of {
|
||||
C2 => mkVerb_C2 lemma ;
|
||||
C3 => mkVerb_C3 lemma
|
||||
C3 => mkVerb_C3 lemma ;
|
||||
C1|CI => mkVerb_C3 nonExist -- FIX ME REMAKE
|
||||
} ;
|
||||
|
||||
mkReflVerb : Str -> Conjugation -> Verb_TMP = \lemma,conj ->
|
||||
case conj of {
|
||||
C2 => mkVerb_C2_Refl lemma ;
|
||||
C3 => mkVerb_C3_Refl lemma
|
||||
C3 => mkVerb_C3_Refl lemma ;
|
||||
C1|CI => mkVerb_C3_Refl nonExist -- FIX ME REMAKE
|
||||
} ;
|
||||
|
||||
filter_Neg : Verb_TMP -> Verb_TMP = \full -> {
|
||||
|
||||
574
src/latvian/PortedMorphoParadigmsLav.gf
Normal file
574
src/latvian/PortedMorphoParadigmsLav.gf
Normal file
@@ -0,0 +1,574 @@
|
||||
--# -path=.:abstract:common:prelude
|
||||
|
||||
-- Contents of this file are automatically ported paradigms from
|
||||
-- https://github.com/LUMII-AILab/Morphology/blob/master/src/main/resources/Lexicon_v2.xml
|
||||
-- NB: Do NOT edit this without consulting lauma@ailab.lv or normundsg@ailab.lv
|
||||
-- Otherwise your changes might get accidentally revoked!
|
||||
|
||||
resource PortedMorphoParadigmsLav = open PortedMorphoStemchangesLav, ResLav in {
|
||||
|
||||
flags coding = utf8 ;
|
||||
|
||||
oper
|
||||
|
||||
noun_1a_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "us" ;
|
||||
Dat => stem + "iem" ;
|
||||
Loc => stem + "os" ;
|
||||
Nom => stem + "i" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "am" ;
|
||||
Loc => stem + "ā" ;
|
||||
Nom => stem + "s" ;
|
||||
Voc => variants { stem + "s" ; stem + "" } ;
|
||||
Gen => stem + "a"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_1a_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "s" => noun_1a_fromStems stem ;
|
||||
_ => Predef.error ("noun_1a_fromLemma is only applicable for words that end in -s, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_1a_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_1a_fromStems stem ;
|
||||
_ => Predef.error ("noun_1a_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_1b_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "us" ;
|
||||
Dat => stem + "iem" ;
|
||||
Loc => stem + "os" ;
|
||||
Nom => stem + "i" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "am" ;
|
||||
Loc => stem + "ā" ;
|
||||
Nom => stem + "š" ;
|
||||
Voc => variants { stem + "š" ; stem + "" } ;
|
||||
Gen => stem + "a"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_1b_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "š" => noun_1b_fromStems stem ;
|
||||
_ => Predef.error ("noun_1b_fromLemma is only applicable for words that end in -š, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_1b_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_1b_fromStems stem ;
|
||||
_ => Predef.error ("noun_1b_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2a_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stemchangeSimple 1 stem + "us" ;
|
||||
Dat => stemchangeSimple 1 stem + "iem" ;
|
||||
Loc => stemchangeSimple 1 stem + "os" ;
|
||||
Nom => stemchangeSimple 1 stem + "i" ;
|
||||
Voc => stemchangeSimple 1 stem + "i" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "im" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "is" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stemchangeSimple 1 stem + "a"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_2a_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "is" => noun_2a_fromStems stem ;
|
||||
_ => Predef.error ("noun_2a_fromLemma is only applicable for words that end in -is, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2a_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_2a_fromStems stem ;
|
||||
_ => Predef.error ("noun_2a_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2c_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stemchangeSimple 1 stem + "us" ;
|
||||
Dat => stemchangeSimple 1 stem + "iem" ;
|
||||
Loc => stemchangeSimple 1 stem + "os" ;
|
||||
Nom => stemchangeSimple 1 stem + "i" ;
|
||||
Voc => stemchangeSimple 1 stem + "i" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "im" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "s" ;
|
||||
Voc => variants { stem + "" ; stem + "s" } ;
|
||||
Gen => stem + "s"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_2c_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "s" => noun_2c_fromStems stem ;
|
||||
_ => Predef.error ("noun_2c_fromLemma is only applicable for words that end in -s, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2c_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_2c_fromStems stem ;
|
||||
_ => Predef.error ("noun_2c_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2d_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stemchangeSimple 1 stem + "us" ;
|
||||
Dat => stemchangeSimple 1 stem + "iem" ;
|
||||
Loc => stemchangeSimple 1 stem + "os" ;
|
||||
Nom => stemchangeSimple 1 stem + "i" ;
|
||||
Voc => stemchangeSimple 1 stem + "i" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "im" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "s" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stemchangeSimple 1 stem + "a"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_2d_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "s" => noun_2d_fromStems stem ;
|
||||
_ => Predef.error ("noun_2d_fromLemma is only applicable for words that end in -s, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2d_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_2d_fromStems stem ;
|
||||
_ => Predef.error ("noun_2d_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_3m_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "us" ;
|
||||
Dat => stem + "iem" ;
|
||||
Loc => stem + "os" ;
|
||||
Nom => stem + "i" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "um" ;
|
||||
Loc => stem + "ū" ;
|
||||
Nom => stem + "us" ;
|
||||
Voc => variants { stem + "us" ; stem + "u" } ;
|
||||
Gen => stem + "us"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_3m_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "us" => noun_3m_fromStems stem ;
|
||||
_ => Predef.error ("noun_3m_fromLemma is only applicable for words that end in -us, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_3m_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_3m_fromStems stem ;
|
||||
_ => Predef.error ("noun_3m_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_4f_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "as" ;
|
||||
Dat => stem + "ām" ;
|
||||
Loc => stem + "ās" ;
|
||||
Nom => stem + "as" ;
|
||||
Voc => stem + "as" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "ai" ;
|
||||
Loc => stem + "ā" ;
|
||||
Nom => stem + "a" ;
|
||||
Voc => variants { stem + "a" ; stemchangeSimple 17 stem + "" } ;
|
||||
Gen => stem + "as"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_4f_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "a" => noun_4f_fromStems stem ;
|
||||
_ => Predef.error ("noun_4f_fromLemma is only applicable for words that end in -a, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_4f_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "as" => noun_4f_fromStems stem ;
|
||||
_ => Predef.error ("noun_4f_fromNomPl is only applicable for words that end in -as, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_4m_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "as" ;
|
||||
Dat => stem + "ām" ;
|
||||
Loc => stem + "ās" ;
|
||||
Nom => stem + "as" ;
|
||||
Voc => stem + "as" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "am" ;
|
||||
Loc => stem + "ā" ;
|
||||
Nom => stem + "a" ;
|
||||
Voc => stem + "a" ;
|
||||
Gen => stem + "as"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_4m_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "a" => noun_4m_fromStems stem ;
|
||||
_ => Predef.error ("noun_4m_fromLemma is only applicable for words that end in -a, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_4m_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "as" => noun_4m_fromStems stem ;
|
||||
_ => Predef.error ("noun_4m_fromNomPl is only applicable for words that end in -as, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5fa_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "es" ;
|
||||
Dat => stem + "ēm" ;
|
||||
Loc => stem + "ēs" ;
|
||||
Nom => stem + "es" ;
|
||||
Voc => stem + "es" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "ei" ;
|
||||
Loc => stem + "ē" ;
|
||||
Nom => stem + "e" ;
|
||||
Voc => variants { stem + "e" ; stemchangeSimple 17 stem + "" } ;
|
||||
Gen => stem + "es"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_5fa_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "e" => noun_5fa_fromStems stem ;
|
||||
_ => Predef.error ("noun_5fa_fromLemma is only applicable for words that end in -e, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5fa_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "es" => noun_5fa_fromStems stem ;
|
||||
_ => Predef.error ("noun_5fa_fromNomPl is only applicable for words that end in -es, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5ma_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "es" ;
|
||||
Dat => stem + "ēm" ;
|
||||
Loc => stem + "ēs" ;
|
||||
Nom => stem + "es" ;
|
||||
Voc => stem + "es" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "em" ;
|
||||
Loc => stem + "ē" ;
|
||||
Nom => stem + "e" ;
|
||||
Voc => stem + "e" ;
|
||||
Gen => stem + "es"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_5ma_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "e" => noun_5ma_fromStems stem ;
|
||||
_ => Predef.error ("noun_5ma_fromLemma is only applicable for words that end in -e, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5ma_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "es" => noun_5ma_fromStems stem ;
|
||||
_ => Predef.error ("noun_5ma_fromNomPl is only applicable for words that end in -es, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_6a_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "is" ;
|
||||
Dat => stem + "īm" ;
|
||||
Loc => stem + "īs" ;
|
||||
Nom => stem + "is" ;
|
||||
Voc => stem + "is" ;
|
||||
Gen => stemchangeSimple 1 stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "ij" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "s" ;
|
||||
Voc => stem + "s" ;
|
||||
Gen => stem + "s"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_6a_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "s" => noun_6a_fromStems stem ;
|
||||
_ => Predef.error ("noun_6a_fromLemma is only applicable for words that end in -s, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_6a_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "is" => noun_6a_fromStems stem ;
|
||||
_ => Predef.error ("noun_6a_fromNomPl is only applicable for words that end in -is, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_3f_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "us" ;
|
||||
Dat => stem + "ūm" ;
|
||||
Loc => stem + "ūs" ;
|
||||
Nom => stem + "us" ;
|
||||
Voc => stem + "us" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "u" ;
|
||||
Dat => stem + "ui" ;
|
||||
Loc => stem + "ū" ;
|
||||
Nom => stem + "us" ;
|
||||
Voc => variants { stem + "us" ; stem + "u" } ;
|
||||
Gen => stem + "us"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_3f_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "us" => noun_3f_fromStems stem ;
|
||||
_ => Predef.error ("noun_3f_fromLemma is only applicable for words that end in -us, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_3f_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "us" => noun_3f_fromStems stem ;
|
||||
_ => Predef.error ("noun_3f_fromNomPl is only applicable for words that end in -us, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_6b_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "is" ;
|
||||
Dat => stem + "īm" ;
|
||||
Loc => stem + "īs" ;
|
||||
Nom => stem + "is" ;
|
||||
Voc => stem + "is" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "ij" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "s" ;
|
||||
Voc => stem + "s" ;
|
||||
Gen => stem + "s"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_6b_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "s" => noun_6b_fromStems stem ;
|
||||
_ => Predef.error ("noun_6b_fromLemma is only applicable for words that end in -s, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_6b_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "is" => noun_6b_fromStems stem ;
|
||||
_ => Predef.error ("noun_6b_fromNomPl is only applicable for words that end in -is, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5fb_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "es" ;
|
||||
Dat => stem + "ēm" ;
|
||||
Loc => stem + "ēs" ;
|
||||
Nom => stem + "es" ;
|
||||
Voc => stem + "es" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "ei" ;
|
||||
Loc => stem + "ē" ;
|
||||
Nom => stem + "e" ;
|
||||
Voc => variants { stem + "e" ; stemchangeSimple 17 stem + "" } ;
|
||||
Gen => stem + "es"
|
||||
}
|
||||
} ;
|
||||
gend = Fem
|
||||
} ;
|
||||
|
||||
noun_5fb_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "e" => noun_5fb_fromStems stem ;
|
||||
_ => Predef.error ("noun_5fb_fromLemma is only applicable for words that end in -e, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5fb_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "es" => noun_5fb_fromStems stem ;
|
||||
_ => Predef.error ("noun_5fb_fromNomPl is only applicable for words that end in -es, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5mb_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "es" ;
|
||||
Dat => stem + "ēm" ;
|
||||
Loc => stem + "ēs" ;
|
||||
Nom => stem + "es" ;
|
||||
Voc => stem + "es" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "em" ;
|
||||
Loc => stem + "ē" ;
|
||||
Nom => stem + "e" ;
|
||||
Voc => stem + "e" ;
|
||||
Gen => stem + "es"
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_5mb_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "e" => noun_5mb_fromStems stem ;
|
||||
_ => Predef.error ("noun_5mb_fromLemma is only applicable for words that end in -e, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_5mb_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "es" => noun_5mb_fromStems stem ;
|
||||
_ => Predef.error ("noun_5mb_fromNomPl is only applicable for words that end in -es, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2b_fromStems : Str -> Noun = \stem ->
|
||||
{
|
||||
s = table {
|
||||
Pl => table {
|
||||
Acc => stem + "us" ;
|
||||
Dat => stem + "iem" ;
|
||||
Loc => stem + "os" ;
|
||||
Nom => stem + "i" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => stem + "u"
|
||||
} ;
|
||||
Sg => table {
|
||||
Acc => stem + "i" ;
|
||||
Dat => stem + "im" ;
|
||||
Loc => stem + "ī" ;
|
||||
Nom => stem + "is" ;
|
||||
Voc => stem + "i" ;
|
||||
Gen => variants { stem + "a" ; stemchangeSimple 1 stem + "a" }
|
||||
}
|
||||
} ;
|
||||
gend = Masc
|
||||
} ;
|
||||
|
||||
noun_2b_fromLemma : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "is" => noun_2b_fromStems stem ;
|
||||
_ => Predef.error ("noun_2b_fromLemma is only applicable for words that end in -is, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
|
||||
noun_2b_fromNomPl : Str -> Noun = \lemma ->
|
||||
case lemma of {
|
||||
stem + "i" => noun_2b_fromStems stem ;
|
||||
_ => Predef.error ("noun_2b_fromNomPl is only applicable for words that end in -i, tried to apply to" ++ lemma)
|
||||
} ;
|
||||
}
|
||||
|
||||
105
src/latvian/PortedMorphoStemchangesLav.gf
Normal file
105
src/latvian/PortedMorphoStemchangesLav.gf
Normal file
@@ -0,0 +1,105 @@
|
||||
--# -path=.:abstract:common:prelude
|
||||
|
||||
-- Here goes manually ported stemchanges from
|
||||
-- https://github.com/LUMII-AILab/Morphology/blob/master/src/main/java/lv/semti/morphology/analyzer/Mijas.java
|
||||
|
||||
resource PortedMorphoStemchangesLav = open Prelude, Predef, ResLav in {
|
||||
|
||||
flags coding = utf8 ;
|
||||
|
||||
oper
|
||||
|
||||
stemchangeSimple : Int -> Str -> Str = \parId,stem ->
|
||||
case parId of {
|
||||
0 => stem ;
|
||||
|
||||
-- For nouns we need changes 0, 1, 17
|
||||
1 => case stem of { -- nouns
|
||||
s + ("kst") => s + "kš" ;
|
||||
s + ("nst") => s + "nš" ;
|
||||
s + ("ll") => s + "ļļ" ;
|
||||
s + ("sl") => s + "šļ" ;
|
||||
s + ("zl") => s + "žļ" ;
|
||||
s + ("ln") => s + "ļņ" ;
|
||||
s + ("nn") => s + "ņņ" ;
|
||||
s + ("sn") => s + "šņ" ;
|
||||
s + ("zn") => s + "žņ" ;
|
||||
s + ("īt") => s + "īš" ;
|
||||
s + ("d") => s + "ž" ;
|
||||
s + ("t") => s + "š" ;
|
||||
s + ("n") => s + "ņ" ;
|
||||
s + ("s") => s + "š" ;
|
||||
s + ("z") => s + "ž" ;
|
||||
s + ("b"|"f"|"m"|"p"|"v") => stem + "j" ;
|
||||
|
||||
_ => stem
|
||||
} ;
|
||||
|
||||
17 => case <stem, countSyllables stem > of { -- shortened vocative for fem nouns
|
||||
<s + ("īt"|"iņ"), _ > => stem ;
|
||||
--<_, 0|1> => variants {} ;
|
||||
<_, 0|1> => nonExist ; -- Exception
|
||||
<_, _> => stem
|
||||
} ;
|
||||
|
||||
-- For full adjectives we need changes 0, 3, 34, 13
|
||||
|
||||
_ => error ("Unsupported stemchange")
|
||||
};
|
||||
|
||||
stemchangeForAdjAdv : Int -> Str -> Definiteness -> Degree -> Str = \parId,stem,defi,deg ->
|
||||
case parId of {
|
||||
3 => case stem of {
|
||||
s + "āk" => case deg of {
|
||||
Posit => stem ;
|
||||
_ => nonExist -- TODO what should go there for nonexisting forms?
|
||||
};
|
||||
_ => case deg of {
|
||||
Posit => stem ;
|
||||
Compar => stem + "āk" ;
|
||||
Superl => case defi of {
|
||||
Def => "vis" + stem + "āk" ;
|
||||
Indef => nonExist
|
||||
}
|
||||
}
|
||||
} ;
|
||||
34 => case deg of { -- pēdēj-ais -> pēdē-jam, zaļ-š -> zaļa-jam
|
||||
Posit => case stem of {
|
||||
s + "ēj" => s + "ē" ;
|
||||
_ => stem + "a"
|
||||
} ;
|
||||
Compar => stem + "āka" ;
|
||||
Superl => case defi of {
|
||||
Def => "vis" + stem + "āka" ;
|
||||
Indef => nonExist
|
||||
}
|
||||
} ;
|
||||
|
||||
_ => case deg of { _ => stemchangeSimple parId stem }
|
||||
} ;
|
||||
|
||||
-- Inari's trick for counting syllables https://inariksit.github.io/gf/2018/08/28/gf-gotchas.html#cute-way-to-count-syllables
|
||||
-- pattern macro for vowels
|
||||
v : pattern Str = #("a"|"ā"|"e"|"ē"|"i"|"ī"|"o"|"u"|"ū") ;
|
||||
|
||||
-- type alias for the helper function
|
||||
SylCnt : Type = Bool -> Str -> Ints 10 ;
|
||||
|
||||
countSyllables : Str -> Ints 10 = go count False
|
||||
where { -- synonym of let
|
||||
go : SylCnt -> SylCnt = \f,wasVowel,word -> -- These three arguments come from the fact that SylCnt is the abovedefined 3rd order function.
|
||||
case <word,wasVowel> of {
|
||||
<#v + s, False> => Predef.plus (f True s) 1 ;
|
||||
<#v + s, True> => f True s ;
|
||||
<? + s, _> => f False s ;
|
||||
_ => 0
|
||||
} ;
|
||||
|
||||
-- end of recursion
|
||||
scBase : SylCnt = \_,_ -> 0 ;
|
||||
|
||||
-- the function given to countSyllables
|
||||
count : SylCnt = go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go (go scBase)))))))))))))))))))))))))))))))))))))))
|
||||
} ;
|
||||
|
||||
}
|
||||
53
src/latvian/PortedMorphoUtilsLav.gf
Normal file
53
src/latvian/PortedMorphoUtilsLav.gf
Normal file
@@ -0,0 +1,53 @@
|
||||
--# -path=.:abstract:common:prelude
|
||||
|
||||
-- Here goes manually made utils used for automaticaly exported Tēzaurs lexicon.
|
||||
|
||||
resource PortedMorphoUtilsLav = open Prelude, Predef, ResLav in {
|
||||
|
||||
flags coding = utf8 ;
|
||||
|
||||
oper
|
||||
|
||||
changeNounForm : Number -> Case -> Str -> Noun -> Noun =
|
||||
\N,C,form,noun -> noun ** {
|
||||
s = \\n,c => case <n,N,c,C> of {
|
||||
<Sg, Sg, Nom, Nom> |
|
||||
<Sg, Sg, Gen, Gen> |
|
||||
<Sg, Sg, Dat, Dat> |
|
||||
<Sg, Sg, Voc, Voc> |
|
||||
<Pl, Pl, Nom, Nom> |
|
||||
<Pl, Pl, Gen, Gen> |
|
||||
<Pl, Pl, Dat, Dat> |
|
||||
<Pl, Pl, Voc, Voc> => form ;
|
||||
_ => noun.s ! n ! c }
|
||||
} ;
|
||||
|
||||
addNounForm : Number -> Case -> Str -> Noun -> Noun =
|
||||
\N,C,form,noun -> noun ** {
|
||||
s = \\n,c => case <n,N,c,C> of {
|
||||
<Sg, Sg, Nom, Nom> |
|
||||
<Sg, Sg, Gen, Gen> |
|
||||
<Sg, Sg, Dat, Dat> |
|
||||
<Sg, Sg, Voc, Voc> |
|
||||
<Pl, Pl, Nom, Nom> |
|
||||
<Pl, Pl, Gen, Gen> |
|
||||
<Pl, Pl, Dat, Dat> |
|
||||
<Pl, Pl, Voc, Voc> => variants {form ; noun.s ! n ! c} ;
|
||||
_ => noun.s ! n ! c }
|
||||
} ;
|
||||
|
||||
{- A note about GF restrictions as of 2025-08-27:
|
||||
Following thing does not work, compiler asumes that N an C are free variables.
|
||||
changeForm_ideal : Number -> Case -> Str -> Noun -> Noun ;
|
||||
changeForm_ideal N C str noun = noun ** {NF N C => str} ;
|
||||
Meanwhile this should work
|
||||
changeForm_fixed : Str -> Noun -> Noun ;
|
||||
changeForm_fixed str noun = noun ** {NF Sg Nom => str} ;
|
||||
Related: https://github.com/GrammaticalFramework/gf-core/issues/198
|
||||
Also Inari suggested to avoid using a function and write this thing inline:
|
||||
Noun : Type = {s : NForm => Str} ;
|
||||
myRegularNoun = {- … some noun …- } ;
|
||||
mySpecialNoun = {s = myRegularNoun.s ** {NF Sg Acc => "special form"}} ;
|
||||
-}
|
||||
|
||||
}
|
||||
68316
src/latvian/PortedTezaursDictLav.gf
Normal file
68316
src/latvian/PortedTezaursDictLav.gf
Normal file
File diff suppressed because it is too large
Load Diff
68305
src/latvian/PortedTezaursDictLavAbs.gf
Normal file
68305
src/latvian/PortedTezaursDictLavAbs.gf
Normal file
File diff suppressed because it is too large
Load Diff
16
src/latvian/README.md
Normal file
16
src/latvian/README.md
Normal file
@@ -0,0 +1,16 @@
|
||||
# Latvian GF Resource Grammar
|
||||
|
||||
There is an ongoing work to develop a wide-coverage reimplementation of the Latvian RGL morphology, based on [Tezaurs.lv](https://tezaurs.lv) dictionary data. Currently, the reimplementation covers noun paradigms and lexical entries, which will be followed by other parts of speech, eventually substituting the legacy Latvian RGL morphology.
|
||||
|
||||
The reimplemented morphology and lexicon module consists of the following components:
|
||||
- `PortedMorphoParadigmsLav.gf`: automatically converted paradigm desrciptions from the [Latvian Morphological Toolkit](https://github.com/LUMII-AILab/Morphology/); please, DO NOT EDIT.
|
||||
- `PortedMorphoStemchangesLav.gf`: manually ported stemchange functions for the above mentioned paradigms; must be kept aligned with the [source code](https://github.com/LUMII-AILab/Morphology/blob/master/src/main/java/lv/semti/morphology/analyzer/Mijas.java) of the toolkit.
|
||||
- `PortedTezaursDictLav.gf` and `PortedTezaursDictLavAbs.gf`: automatically exported lexicon data from [Tezaurs.lv](https://tezaurs.lv); please, DO NOT EDIT.
|
||||
- `PortedMorphoUtilsLav.gf`: utility functions.
|
||||
|
||||
For edits and improvements, please, contact us at lauma@ailab.lv!
|
||||
|
||||
|
||||
## Acknowledgements
|
||||
|
||||
The work on porting Tezaurs.lv inflectional paradigms to GF and creating a wide-coverage computational GF lexicon for Latvian was funded by the Latvian Council of Science under the grant agreement lzp-2022/1-0443 ([Advancing Latvian Computational Lexical Resources for Natural Language Understanding and Generation](https://wordnet.ailab.lv/project2)).
|
||||
@@ -13,12 +13,12 @@ param
|
||||
|
||||
Case = Nom | Gen | Dat | Acc | Loc | Voc ;
|
||||
Gender = Masc | Fem ;
|
||||
Declension = D0 | D1 | D2 | D3 | D4 | D5 | D6 | DR ;
|
||||
Declension = D0 | D1 | D2 | D3 | D4 | D5 | D6 | DR | DG; -- ammended for Tēzaurs.
|
||||
|
||||
-- Adjectives
|
||||
|
||||
Definiteness = Indef | Def ;
|
||||
AType = AQual | ARel | AIndecl ;
|
||||
AType = AQual | ARel | AIndecl ; -- Doesn't exactly fit with Tēzaurs system - AIndecl is not needed.
|
||||
|
||||
AForm =
|
||||
AAdj Degree Definiteness Gender Number Case
|
||||
@@ -27,7 +27,7 @@ param
|
||||
-- Verbs
|
||||
|
||||
Voice = Act | Pass ;
|
||||
Conjugation = C2 | C3 ; -- C1 - "irregular" verbs
|
||||
Conjugation = C2 | C3 | C1 | CI ; -- C1 - "irregular" verbs ; ammended for Tēzaurs.
|
||||
|
||||
-- Verb moods:
|
||||
-- Ind - indicative
|
||||
|
||||
@@ -185,15 +185,14 @@ lin
|
||||
ComplSlash vpslash np =
|
||||
let agr : Agreement = np.agr in {
|
||||
v = vpslash.v ;
|
||||
{-
|
||||
compl = \\agr => case vpslash.voice of {
|
||||
Act => vpslash.rightVal.s ++ np.s ! (vpslash.rightVal.c ! (fromAgr agr).num) ;
|
||||
Pass => case vpslash.rightVal.c ! (fromAgr agr).num of {
|
||||
Nom => np.s ! (vpslash.rightVal.c ! Sg) ;
|
||||
_ => vpslash.rightVal.s ++ np.s ! (vpslash.rightVal.c ! (fromAgr agr).num)
|
||||
}
|
||||
} ++ vpslash.compl ! agr ;
|
||||
-}
|
||||
-- compl = \\agr => case vpslash.voice of {
|
||||
-- Act => vpslash.rightVal.s ++ np.s ! (vpslash.rightVal.c ! (fromAgr agr).num) ;
|
||||
-- Pass => case vpslash.rightVal.c ! (fromAgr agr).num of {
|
||||
-- Nom => np.s ! (vpslash.rightVal.c ! Sg) ;
|
||||
-- _ => vpslash.rightVal.s ++ np.s ! (vpslash.rightVal.c ! (fromAgr agr).num)
|
||||
-- }
|
||||
-- } ++ vpslash.compl ! agr ;
|
||||
|
||||
compl = \\agr => vpslash.rightVal.s ++
|
||||
np.s ! (vpslash.rightVal.c ! (fromAgr agr).num) ++
|
||||
vpslash.compl ! agr ;
|
||||
|
||||
@@ -6,7 +6,7 @@ concrete AdverbMkd of Adverb = CatMkd ** open Prelude,ResMkd in {
|
||||
lin ComparAdvAdjS c a s = {s = c.s
|
||||
++ a.s ! Indef ! GSg Masc ++ s.s} ;
|
||||
lin PositAdAAdj a = {s = a.s ! Indef ! GSg Masc} ;
|
||||
lin PositAdvAdj a = {s = a.s ! Indef ! GSg Masc} ;
|
||||
lin PositAdvAdj a = {s = a.adverb} ;
|
||||
lin PrepNP p np = {s = p.s ++ np.s ! RPrep} ;
|
||||
lin SubjS s s2 = {s = s.s ++ s2.s} ;
|
||||
}
|
||||
|
||||
219
src/macedonian/ConstructionMkd.gf
Normal file
219
src/macedonian/ConstructionMkd.gf
Normal file
@@ -0,0 +1,219 @@
|
||||
concrete ConstructionMkd of Construction = CatMkd **
|
||||
open ParadigmsMkd, ResMkd, GrammarMkd, Prelude in {
|
||||
|
||||
lincat
|
||||
Timeunit = N ;
|
||||
Hour = {s : Str} ;
|
||||
Weekday = N ;
|
||||
Monthday = NP ;
|
||||
Month = N ;
|
||||
Year = NP ;
|
||||
Language = N ;
|
||||
|
||||
lin
|
||||
hungry_VP = adjVP (mkA "гладен" "гладна") ;
|
||||
thirsty_VP = adjVP (mkA "жеден" "жедна") ;
|
||||
tired_VP = adjVP (mkA "уморен" "уморна") ;
|
||||
scared_VP = adjVP (mkA "исплашен" "исплашена") ;
|
||||
ill_VP = adjVP (mkA "болен" "болна") ;
|
||||
ready_VP = adjVP (mkA "подготвен" "подготвена") ;
|
||||
|
||||
has_age_VP card = (UseV (mkV "има")) ** {
|
||||
compl = \\_ => card.s ++ "години"
|
||||
} ;
|
||||
|
||||
have_name_Cl p name = PredVP p ((UseV (medialV (mkV "вика") accusative)) ** {
|
||||
compl = \\_ => name.s ! RSubj
|
||||
}) ;
|
||||
|
||||
married_Cl p1 p2 =
|
||||
PredVP p1 (AdvVP (adjVP (mkA "венчан" "венчана")) (PrepNP (mkPrep "со") p2)) ;
|
||||
|
||||
what_name_QCl p = {
|
||||
s = \\_,_,_ => "како" ++ "се" ++ "вика" ++ p.s ! RSubj
|
||||
} ;
|
||||
how_old_QCl p = {
|
||||
s = \\_,_,_ => "колку години има" ++ p.s ! RSubj
|
||||
} ;
|
||||
how_far_QCl p = {
|
||||
s = \\_,_,_ => "колку далеку е" ++ p.s ! RSubj
|
||||
} ;
|
||||
|
||||
weather_adjCl ap = {
|
||||
s = \\_,_,_,_ => "е" ++ ap.s ! Indef ! GSg Neuter
|
||||
} ;
|
||||
|
||||
is_right_VP = adjVP (mkA "прав" "права") ;
|
||||
is_wrong_VP = adjVP (mkA "погрешен" "погрешна") ;
|
||||
|
||||
n_units_AP card cn a = {
|
||||
s = \\sp,gn => a.s ! sp ! gn ++ card.s ++ cn.count_form ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
n_units_of_NP card cn np = {
|
||||
s = \\_ => card.s ++ cn.count_form ++ "од" ++ np.s ! RSubj ;
|
||||
vocative = card.s ++ cn.count_form ++ "од" ++ np.vocative ;
|
||||
a = {g = GPl; p = P3}
|
||||
} ;
|
||||
|
||||
n_unit_CN card unit cn = {
|
||||
s = \\sp,n => card.s ++ unit.count_form ++ cn.s ! sp ! n ;
|
||||
count_form = card.s ++ unit.count_form ++ cn.count_form ;
|
||||
vocative = \\n => card.s ++ unit.count_form ++ cn.vocative ! n ;
|
||||
g = cn.g
|
||||
} ;
|
||||
|
||||
bottle_of_CN np = containerCN (mkN "шише" "шишиња") np ;
|
||||
cup_of_CN np = containerCN (mkN "чаша" "чаши") np ;
|
||||
glass_of_CN np = containerCN (mkN "чаша" "чаши") np ;
|
||||
|
||||
few_X_short_of_Y np x y = {
|
||||
s = np.s ! RSubj ++ "нема доволно" ++ x.count_form ++ "за" ++ y.s ! Indef ! Sg
|
||||
} ;
|
||||
|
||||
timeunitAdv card unit = {
|
||||
s = "за" ++ card.s ++ unit.count_form
|
||||
} ;
|
||||
timeunitRange from to unit = {
|
||||
s = "од" ++ from.s ++ "до" ++ to.s ++ unit.count_form
|
||||
} ;
|
||||
|
||||
oneHour = hour "1" ;
|
||||
twoHour = hour "2" ;
|
||||
threeHour = hour "3" ;
|
||||
fourHour = hour "4" ;
|
||||
fiveHour = hour "5" ;
|
||||
sixHour = hour "6" ;
|
||||
sevenHour = hour "7" ;
|
||||
eightHour = hour "8" ;
|
||||
nineHour = hour "9" ;
|
||||
tenHour = hour "10" ;
|
||||
elevenHour = hour "11" ;
|
||||
twelveHour = hour "12" ;
|
||||
thirteenHour = hour "13" ;
|
||||
fourteenHour = hour "14" ;
|
||||
fifteenHour = hour "15" ;
|
||||
sixteenHour = hour "16" ;
|
||||
seventeenHour = hour "17" ;
|
||||
eighteenHour = hour "18" ;
|
||||
nineteenHour = hour "19" ;
|
||||
twentyHour = hour "20" ;
|
||||
twentyOneHour = hour "21" ;
|
||||
twentyTwoHour = hour "22" ;
|
||||
twentyThreeHour = hour "23" ;
|
||||
twentyFourHour = hour "24" ;
|
||||
|
||||
timeHour h = {s = "во" ++ h.s ++ "часот"} ;
|
||||
timeHourMinute h m = {s = "во" ++ h.s ++ ":" ++ m.s} ;
|
||||
|
||||
weekdayPunctualAdv w = {s = "во" ++ w.s ! Indef ! Sg} ;
|
||||
weekdayHabitualAdv w = {s = "во" ++ w.s ! Indef ! Pl} ;
|
||||
weekdayLastAdv w = {s = "минатиот" ++ w.s ! Indef ! Sg} ;
|
||||
weekdayNextAdv w = {s = "следниот" ++ w.s ! Indef ! Sg} ;
|
||||
|
||||
monthAdv m = {s = "во" ++ m.s ! Indef ! Sg} ;
|
||||
yearAdv y = {s = "во" ++ y.s ! RSubj} ;
|
||||
dayMonthAdv d m = {s = "на" ++ d.s ! RSubj ++ m.s ! Indef ! Sg} ;
|
||||
monthYearAdv m y = {s = "во" ++ m.s ! Indef ! Sg ++ y.s ! RSubj} ;
|
||||
dayMonthYearAdv d m y = {s = "на" ++ d.s ! RSubj ++ m.s ! Indef ! Sg ++ y.s ! RSubj} ;
|
||||
|
||||
intYear n = symbNP n.s ;
|
||||
intMonthday n = symbNP n.s ;
|
||||
|
||||
InLanguage l = {s = "на" ++ l.s ! Indef ! Sg} ;
|
||||
languageCN l = UseN l ;
|
||||
languageNP l = MassNP (UseN l) ;
|
||||
|
||||
weekdayN w = w ;
|
||||
monthN m = m ;
|
||||
|
||||
weekdayPN w = mkPN (w.s ! Indef ! Sg) ;
|
||||
monthPN m = mkPN (m.s ! Indef ! Sg) ;
|
||||
|
||||
second_Timeunit = mkN "секунда" "секунди" ;
|
||||
minute_Timeunit = mkN "минута" "минути" ;
|
||||
hour_Timeunit = mkN "час" "часови" ;
|
||||
day_Timeunit = mkN "ден" "денови" ;
|
||||
week_Timeunit = mkN "недела" "недели" ;
|
||||
month_Timeunit = mkN "месец" "месеци" ;
|
||||
year_Timeunit = mkN "година" "години" ;
|
||||
|
||||
monday_Weekday = mkN "понеделник" "понеделници" ;
|
||||
tuesday_Weekday = mkN "вторник" "вторници" ;
|
||||
wednesday_Weekday = mkN "среда" "среди" ;
|
||||
thursday_Weekday = mkN "четврток" "четвртоци" ;
|
||||
friday_Weekday = mkN "петок" "петоци" ;
|
||||
saturday_Weekday = mkN "сабота" "саботи" ;
|
||||
sunday_Weekday = mkN "недела" "недели" ;
|
||||
|
||||
january_Month = mkMonth "јануари" ;
|
||||
february_Month = mkMonth "февруари" ;
|
||||
march_Month = mkMonth "март" ;
|
||||
april_Month = mkMonth "април" ;
|
||||
may_Month = mkMonth "мај" ;
|
||||
june_Month = mkMonth "јуни" ;
|
||||
july_Month = mkMonth "јули" ;
|
||||
august_Month = mkMonth "август" ;
|
||||
september_Month = mkMonth "септември" ;
|
||||
october_Month = mkMonth "октомври" ;
|
||||
november_Month = mkMonth "ноември" ;
|
||||
december_Month = mkMonth "декември" ;
|
||||
|
||||
afrikaans_Language = mkLanguage "африканс" ;
|
||||
amharic_Language = mkLanguage "амхарски" ;
|
||||
arabic_Language = mkLanguage "арапски" ;
|
||||
bulgarian_Language = mkLanguage "бугарски" ;
|
||||
catalan_Language = mkLanguage "каталонски" ;
|
||||
chinese_Language = mkLanguage "кинески" ;
|
||||
danish_Language = mkLanguage "дански" ;
|
||||
dutch_Language = mkLanguage "холандски" ;
|
||||
english_Language = mkLanguage "англиски" ;
|
||||
estonian_Language = mkLanguage "естонски" ;
|
||||
finnish_Language = mkLanguage "фински" ;
|
||||
french_Language = mkLanguage "француски" ;
|
||||
german_Language = mkLanguage "германски" ;
|
||||
greek_Language = mkLanguage "грчки" ;
|
||||
hebrew_Language = mkLanguage "хебрејски" ;
|
||||
hindi_Language = mkLanguage "хинди" ;
|
||||
japanese_Language = mkLanguage "јапонски" ;
|
||||
italian_Language = mkLanguage "италијански" ;
|
||||
latin_Language = mkLanguage "латински" ;
|
||||
latvian_Language = mkLanguage "латвиски" ;
|
||||
maltese_Language = mkLanguage "малтешки" ;
|
||||
nepali_Language = mkLanguage "непалски" ;
|
||||
norwegian_Language = mkLanguage "норвешки" ;
|
||||
persian_Language = mkLanguage "персиски" ;
|
||||
polish_Language = mkLanguage "полски" ;
|
||||
punjabi_Language = mkLanguage "пенџапски" ;
|
||||
romanian_Language = mkLanguage "романски" ;
|
||||
russian_Language = mkLanguage "руски" ;
|
||||
sindhi_Language = mkLanguage "синди" ;
|
||||
spanish_Language = mkLanguage "шпански" ;
|
||||
swahili_Language = mkLanguage "свахили" ;
|
||||
swedish_Language = mkLanguage "шведски" ;
|
||||
thai_Language = mkLanguage "тајландски" ;
|
||||
turkish_Language = mkLanguage "турски" ;
|
||||
urdu_Language = mkLanguage "урду" ;
|
||||
|
||||
oper
|
||||
adjVP : A -> VP = \a -> UseComp (CompAP (PositA a)) ;
|
||||
|
||||
containerCN : N -> NP -> CN = \n,np -> lin CN {
|
||||
s = \\sp,num => n.s ! sp ! num ++ "од" ++ np.s ! RSubj ;
|
||||
count_form = n.count_form ++ "од" ++ np.s ! RSubj ;
|
||||
vocative = \\num => n.vocative ! num ++ "од" ++ np.vocative ;
|
||||
g = n.g
|
||||
} ;
|
||||
|
||||
hour : Str -> Hour = \s -> lin Hour {s = s} ;
|
||||
|
||||
symbNP : Str -> NP = \s -> lin NP {
|
||||
s = \\_ => s ;
|
||||
vocative = s ;
|
||||
a = {g = GSg Masc; p = P3}
|
||||
} ;
|
||||
|
||||
mkMonth : Str -> N = \s -> mkN s s ;
|
||||
mkLanguage : Str -> N = \s -> mkN s s ;
|
||||
}
|
||||
@@ -1,7 +1,21 @@
|
||||
--# -path=.:../abstract:../common:prelude
|
||||
concrete ExtendMkd of Extend = CatMkd ** open ResMkd, ParadigmsMkd, StructuralMkd in {
|
||||
concrete ExtendMkd of Extend = CatMkd ** open Predef, ResMkd, ParadigmsMkd, StructuralMkd, GrammarMkd, Prelude in {
|
||||
|
||||
lincat
|
||||
VPS = {s : Agr => Str} ;
|
||||
[VPS] = {s : Agr => Ints 4 => Str} ;
|
||||
VPI = {s : Agr => Str} ;
|
||||
[VPI] = {s : Agr => Ints 4 => Str} ;
|
||||
[Comp] = {s : GenNum => Ints 4 => Str} ;
|
||||
[Imp] = {s : Polarity => GenNum => Ints 4 => Str} ;
|
||||
RNP = {s : Agr => Role => Str; a : Agr; isPron : Bool} ;
|
||||
RNPList = {s : Agr => Ints 4 => Role => Str; a : Agr} ;
|
||||
|
||||
lin
|
||||
GenModNP num np cn = DetCN (DetQuant DefArt num) (PossNP cn np) ;
|
||||
|
||||
EmptyRelSlash slash = RelSlash IdRP slash ;
|
||||
|
||||
CompoundN n1 n2 =
|
||||
let comp : Species => Number => Str
|
||||
= \\sp,n => case n1.relType of {
|
||||
@@ -23,6 +37,321 @@ lin
|
||||
g = n2.g
|
||||
} ;
|
||||
|
||||
CompoundAP n a = AdvAP (PositA a) (PrepNP (mkPrep "од") (MassNP (UseN n))) ;
|
||||
|
||||
PositAdVAdj a = {s = a.adverb} ;
|
||||
|
||||
PresPartAP vp = {
|
||||
s = \\_,gn => "што" ++
|
||||
vp.present ! Imperfective ! genNum2num gn ! P3 ++
|
||||
vp.compl ! {g = gn; p = P3} ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
PastPartAP vps = {
|
||||
s = \\_,gn => vps.participle.adjectival ! Perfective ++
|
||||
vps.compl ! {g = gn; p = P3} ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
PastPartAgentAP vps np = {
|
||||
s = \\_,gn => vps.participle.adjectival ! Perfective ++
|
||||
vps.compl ! {g = gn; p = P3} ++
|
||||
"од" ++ np.s ! RPrep ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
PassVPSlash vps = {
|
||||
present = \\_ => auxBe.present ;
|
||||
aorist = auxBe.imperfect ;
|
||||
imperfect = \\_ => auxBe.imperfect ;
|
||||
imperative = \\_ => auxBe.imperative ;
|
||||
participle = {aorist = \\_ => auxBe.participle.aorist ;
|
||||
imperfect = \\_ => auxBe.participle.imperfect ;
|
||||
perfect = \\_ => nonExist ;
|
||||
adjectival = \\_ => nonExist ;
|
||||
adverbial = nonExist} ;
|
||||
noun_from_verb = nonExist ;
|
||||
compl = \\agr => vps.participle.adjectival ! Perfective ++ vps.compl ! agr ;
|
||||
vtype = VNormal
|
||||
} ;
|
||||
|
||||
PassAgentVPSlash vps np = {
|
||||
present = \\_ => auxBe.present ;
|
||||
aorist = auxBe.imperfect ;
|
||||
imperfect = \\_ => auxBe.imperfect ;
|
||||
imperative = \\_ => auxBe.imperative ;
|
||||
participle = {aorist = \\_ => auxBe.participle.aorist ;
|
||||
imperfect = \\_ => auxBe.participle.imperfect ;
|
||||
perfect = \\_ => nonExist ;
|
||||
adjectival = \\_ => nonExist ;
|
||||
adverbial = nonExist} ;
|
||||
noun_from_verb = nonExist ;
|
||||
compl = \\agr => vps.participle.adjectival ! Perfective ++ vps.compl ! agr ++
|
||||
"од" ++ np.s ! RPrep ;
|
||||
vtype = VNormal
|
||||
} ;
|
||||
|
||||
ProgrVPSlash vps = vps ** {
|
||||
present = \\_,n,p => vps.present ! Imperfective ! n ! p ;
|
||||
imperfect = \\_,n,p => vps.imperfect ! Imperfective ! n ! p ;
|
||||
imperative = \\_,n => vps.imperative ! Imperfective ! n
|
||||
} ;
|
||||
|
||||
GerundCN vp =
|
||||
let refl : Str = case vp.vtype of {
|
||||
VNormal => [] ;
|
||||
VMedial Acc => "се" ;
|
||||
VMedial Dat => "си"
|
||||
}
|
||||
in {
|
||||
s = \\sp,num => case <sp,num> of {
|
||||
<Indef,Sg> => vp.noun_from_verb ;
|
||||
<Indef,Pl> => vp.noun_from_verb ++ BIND ++ "а" ;
|
||||
<Def Unspecified,Sg> => vp.noun_from_verb ++ BIND ++ "то" ;
|
||||
<Def Unspecified,Pl> => vp.noun_from_verb ++ BIND ++ "та" ;
|
||||
<Def Proximal,Sg> => vp.noun_from_verb ++ BIND ++ "во" ;
|
||||
<Def Proximal,Pl> => vp.noun_from_verb ++ BIND ++ "ва" ;
|
||||
<Def Distal,Sg> => vp.noun_from_verb ++ BIND ++ "но" ;
|
||||
<Def Distal,Pl> => vp.noun_from_verb ++ BIND ++ "на"
|
||||
} ++ refl ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3} ;
|
||||
count_form = vp.noun_from_verb ++ BIND ++ "а" ++ refl ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3} ;
|
||||
vocative = \\num => vp.noun_from_verb ++ refl ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3} ;
|
||||
g = Neuter
|
||||
} ;
|
||||
|
||||
GerundNP vp = MassNP (GerundCN vp) ;
|
||||
|
||||
GerundAdv vp =
|
||||
let refl : Str = case vp.vtype of {
|
||||
VNormal => [] ;
|
||||
VMedial Acc => "се" ;
|
||||
VMedial Dat => "си"
|
||||
}
|
||||
in {s = vp.participle.adverbial ++ refl ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3}} ;
|
||||
|
||||
ByVP vp = {s = "со" ++ vp.noun_from_verb ++ BIND ++ "то" ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3}} ;
|
||||
WithoutVP vp = {s = "без" ++ vp.noun_from_verb ++ BIND ++ "то" ++
|
||||
vp.compl ! {g = GSg Neuter; p = P3}} ;
|
||||
InOrderToVP vp = {s = "за да" ++ vp.present ! Perfective ! Sg ! P3 ++
|
||||
vp.compl ! {g = GSg Masc; p = P3}} ;
|
||||
|
||||
ComplBareVS vs s = vs ** {compl = \\_ => s.s} ;
|
||||
ComplSlashPartLast = ComplSlash ;
|
||||
|
||||
UttVPShort vp = {
|
||||
s = vp.imperative ! Perfective ! Sg ++ vp.compl ! {g = GSg Masc; p = P2}
|
||||
} ;
|
||||
|
||||
BaseVPS x y = {s = \\a => table {4 => y.s ! a; _ => x.s ! a}} ;
|
||||
ConsVPS x xs = {
|
||||
s = \\a => table {
|
||||
4 => xs.s ! a ! 4 ;
|
||||
i => x.s ! a ++ linCoord "," ! i ++ xs.s ! a ! i
|
||||
}
|
||||
} ;
|
||||
MkVPS t p vp = {
|
||||
s = \\agr => t.s ++ p.s ++ mkClause [] agr vp ! Main ! t.t ! t.a ! p.p
|
||||
} ;
|
||||
ConjVPS conj vps = {
|
||||
s = \\agr => linCoord [] ! conj.sep ++
|
||||
vps.s ! agr ! conj.sep ++ conj.s ++ vps.s ! agr ! 4
|
||||
} ;
|
||||
PredVPS np vps = {s = np.s ! RSubj ++ vps.s ! np.a} ;
|
||||
|
||||
BaseVPI x y = {s = \\a => table {4 => y.s ! a; _ => x.s ! a}} ;
|
||||
ConsVPI x xs = {
|
||||
s = \\a => table {
|
||||
4 => xs.s ! a ! 4 ;
|
||||
i => x.s ! a ++ linCoord "," ! i ++ xs.s ! a ! i
|
||||
}
|
||||
} ;
|
||||
MkVPI vp = {
|
||||
s = \\agr => "да" ++ vp.present ! Perfective ! genNum2num agr.g ! agr.p ++ vp.compl ! agr
|
||||
} ;
|
||||
ConjVPI conj vpi = {
|
||||
s = \\agr => linCoord [] ! conj.sep ++
|
||||
vpi.s ! agr ! conj.sep ++ conj.s ++ vpi.s ! agr ! 4
|
||||
} ;
|
||||
ComplVPIVV vv vpi = vv ** {
|
||||
compl = \\agr => vpi.s ! agr
|
||||
} ;
|
||||
|
||||
BaseComp x y = {
|
||||
s = \\gn => table {4 => y.s ! gn; _ => x.s ! gn}
|
||||
} ;
|
||||
ConsComp x xs = {
|
||||
s = \\gn => table {
|
||||
4 => xs.s ! gn ! 4 ;
|
||||
i => x.s ! gn ++ linCoord "," ! i ++ xs.s ! gn ! i
|
||||
}
|
||||
} ;
|
||||
ConjComp conj comps = {
|
||||
s = \\gn => linCoord [] ! conj.sep ++
|
||||
comps.s ! gn ! conj.sep ++ conj.s ++ comps.s ! gn ! 4
|
||||
} ;
|
||||
|
||||
BaseImp x y = {
|
||||
s = \\p,gn => table {4 => y.s ! p ! gn; _ => x.s ! p ! gn}
|
||||
} ;
|
||||
ConsImp x xs = {
|
||||
s = \\p,gn => table {
|
||||
4 => xs.s ! p ! gn ! 4 ;
|
||||
i => x.s ! p ! gn ++ linCoord "," ! i ++ xs.s ! p ! gn ! i
|
||||
}
|
||||
} ;
|
||||
ConjImp conj imps = {
|
||||
s = \\p,gn => linCoord [] ! conj.sep ++
|
||||
imps.s ! p ! gn ! conj.sep ++ conj.s ++ imps.s ! p ! gn ! 4
|
||||
} ;
|
||||
|
||||
ReflRNP slash rnp =
|
||||
slash ** {
|
||||
compl = \\agr =>
|
||||
slash.compl ! agr ++
|
||||
case <rnp.isPron,slash.c2.c> of {
|
||||
<True,Acc> => [] ;
|
||||
<True,Dat> => [] ;
|
||||
_ => slash.c2.s ++ rnp.s ! agr ! RObj slash.c2.c
|
||||
} ;
|
||||
vtype = case <rnp.isPron,slash.c2.c> of {
|
||||
<True,Acc> => VMedial Acc ;
|
||||
<True,Dat> => VMedial Dat ;
|
||||
_ => slash.vtype
|
||||
}
|
||||
} ;
|
||||
|
||||
ReflPron = {
|
||||
s = \\_,role => case role of {
|
||||
RObj Acc => "себе" ;
|
||||
RObj Dat => "себе" ;
|
||||
_ => "себе"
|
||||
} ;
|
||||
a = {g = GSg Masc; p = P3} ;
|
||||
isPron = True
|
||||
} ;
|
||||
|
||||
ReflPoss num cn =
|
||||
let np : NP = DetCN (DetQuant ReflPossPron num) cn
|
||||
in {
|
||||
s = \\_,role => np.s ! role ;
|
||||
a = np.a ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
PredetRNP pred rnp = rnp ** {
|
||||
s = \\agr,role => pred.s ++ rnp.s ! agr ! role ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
AdvRNP np prep rnp = {
|
||||
s = \\agr,role => np.s ! role ++ prep.s ++ rnp.s ! agr ! RObj prep.c ;
|
||||
a = np.a ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
AdvRVP vp prep rnp = vp ** {
|
||||
compl = \\agr => vp.compl ! agr ++ prep.s ++ rnp.s ! agr ! RObj prep.c
|
||||
} ;
|
||||
|
||||
AdvRAP ap prep rnp = {
|
||||
s = \\sp,gn => ap.s ! sp ! gn ++ prep.s ++
|
||||
rnp.s ! {g = gn; p = P3} ! RObj prep.c ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
ReflA2RNP a2 rnp = {
|
||||
s = \\sp,gn => a2.s ! sp ! gn ++ a2.c2.s ++
|
||||
rnp.s ! {g = gn; p = P3} ! RObj a2.c2.c ;
|
||||
isPre = False
|
||||
} ;
|
||||
|
||||
PossPronRNP pron num cn rnp =
|
||||
let det : Det = DetQuant (PossPron pron) num ;
|
||||
n : Number = nnum2num num.n
|
||||
in {
|
||||
s = \\_ => det.s ! cn.g ++ cn.s ! det.sp ! n ++
|
||||
"на" ++ rnp.s ! pron.a ! RObj Acc ;
|
||||
vocative = det.s ! cn.g ++ cn.vocative ! n ++
|
||||
"на" ++ rnp.s ! pron.a ! RObj Acc ;
|
||||
a = {g = genNum cn.g n; p = P3}
|
||||
} ;
|
||||
|
||||
ApposNP np1 np2 = {
|
||||
s = \\role => np1.s ! role ++ SOFT_BIND ++ "," ++ np2.s ! role ;
|
||||
vocative = np1.vocative ++ SOFT_BIND ++ "," ++ np2.vocative ;
|
||||
a = np1.a
|
||||
} ;
|
||||
|
||||
Base_rr_RNP x y = {
|
||||
s = \\agr => table {4 => y.s ! agr; _ => x.s ! agr} ;
|
||||
a = y.a
|
||||
} ;
|
||||
Base_nr_RNP x y = {
|
||||
s = \\agr => table {4 => y.s ! agr; _ => x.s} ;
|
||||
a = y.a
|
||||
} ;
|
||||
Base_rn_RNP x y = {
|
||||
s = \\agr => table {4 => y.s; _ => x.s ! agr} ;
|
||||
a = y.a
|
||||
} ;
|
||||
Cons_rr_RNP x xs = {
|
||||
s = \\agr => table {
|
||||
4 => xs.s ! agr ! 4 ;
|
||||
i => \\role => x.s ! agr ! role ++ linCoord "," ! i ++ xs.s ! agr ! i ! role
|
||||
} ;
|
||||
a = xs.a
|
||||
} ;
|
||||
Cons_nr_RNP x xs = {
|
||||
s = \\agr => table {
|
||||
4 => xs.s ! agr ! 4 ;
|
||||
i => \\role => x.s ! role ++ linCoord "," ! i ++ xs.s ! agr ! i ! role
|
||||
} ;
|
||||
a = xs.a
|
||||
} ;
|
||||
ConjRNP conj xs = {
|
||||
s = \\agr,role => linCoord [] ! conj.sep ++
|
||||
xs.s ! agr ! conj.sep ! role ++ conj.s ++
|
||||
xs.s ! agr ! 4 ! role ;
|
||||
a = xs.a ;
|
||||
isPron = False
|
||||
} ;
|
||||
|
||||
ReflPossPron = {
|
||||
s = table {
|
||||
GSg Masc => "својот" ;
|
||||
GSg Fem => "својата" ;
|
||||
GSg Neuter => "своето" ;
|
||||
GPl => "своите"
|
||||
} ;
|
||||
sp = Indef
|
||||
} ;
|
||||
|
||||
UseDAP dap = {
|
||||
s = \\_ => dap.s ! Neuter ;
|
||||
vocative = dap.s ! Neuter ;
|
||||
a = {g = genNum Neuter (nnum2num dap.n); p = P3}
|
||||
} ;
|
||||
UseDAPMasc dap = {
|
||||
s = \\_ => dap.s ! Masc ;
|
||||
vocative = dap.s ! Masc ;
|
||||
a = {g = genNum Masc (nnum2num dap.n); p = P3}
|
||||
} ;
|
||||
UseDAPFem dap = {
|
||||
s = \\_ => dap.s ! Fem ;
|
||||
vocative = dap.s ! Fem ;
|
||||
a = {g = genNum Fem (nnum2num dap.n); p = P3}
|
||||
} ;
|
||||
|
||||
UseComp_estar = UseComp ;
|
||||
UseComp_ser = UseComp ;
|
||||
ProDrop pro = pro ;
|
||||
|
||||
iFem_Pron = mkPron "јас" "мене" "ме" "мене" "ми" "мене" "мој" "мојот" "моја" "мојата" "мое" "моето" "мои" "моите" "ми" (GSg Fem) P1 ;
|
||||
youFem_Pron = mkPron "ти" "тебе" "те" "тебе" "ти" "тебе" "твој" "твојот" "твоја" "твојата" "твое" "твоето" "твои" "твоите" "ти" (GSg Fem) P2 ;
|
||||
weFem_Pron = we_Pron ;
|
||||
@@ -35,4 +364,3 @@ lin
|
||||
lin TPastSimple = {s = []} ** {t = VPastSimple} ; --# notpresent
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
concrete LangMkd of Lang =
|
||||
GrammarMkd,
|
||||
LexiconMkd
|
||||
,ConstructionMkd
|
||||
,DocumentationMkd --# notpresent
|
||||
|
||||
** {
|
||||
|
||||
@@ -919,7 +919,7 @@ mkN028 base =
|
||||
} ;
|
||||
rel = \\_,_ => base_1 ;
|
||||
relType = Pref ;
|
||||
g = Masc
|
||||
g = Neuter
|
||||
};
|
||||
_ => error "Can't apply paradigm mkN028"
|
||||
} ;
|
||||
|
||||
@@ -29,6 +29,10 @@ concrete NumeralMkd of Numeral = CatMkd [Numeral,Digits,Decimal] ** open Prelude
|
||||
lin PosDecimal ds = ds ** {hasDot = False} ;
|
||||
lincat Sub10 = {s : Str; hundred : Str; n : Number} ;
|
||||
lincat Sub100 = {s : Str; n : Number} ;
|
||||
lincat Sub1000 = {s : Str; n : Number} ;
|
||||
lincat Sub1000000 = {s : Str; n : Number} ;
|
||||
lincat Sub1000000000 = {s : Str; n : Number} ;
|
||||
lincat Sub1000000000000 = {s : Str; n : Number} ;
|
||||
oper mkDig : Str -> Number -> {s : Str; n : Number}
|
||||
= \s,n -> {s = s; n = n} ;
|
||||
oper mkDigit : Str -> Str -> Str -> Str -> {s : Str; teen : Str;
|
||||
@@ -49,9 +53,30 @@ concrete NumeralMkd of Numeral = CatMkd [Numeral,Digits,Decimal] ** open Prelude
|
||||
lin pot1 n = {s = n.ten; n = Pl} ;
|
||||
lin pot110 = {s = "десет"; n = Pl} ;
|
||||
lin pot111 = {s = "единаесет"; n = Pl} ;
|
||||
lin pot1to19 d = {s = d.teen; n = Pl} ;
|
||||
lin pot1as2 n = n ;
|
||||
lin pot2 n = {s = n.hundred} ;
|
||||
lin pot1plus d n = {s = d.ten ++ "и" ++ n.s; n = Pl} ;
|
||||
lin pot2 n = {s = n.hundred; n = Pl} ;
|
||||
lin pot21 = {s = "сто"; n = Pl} ;
|
||||
lin pot2plus n m = {s = n.hundred ++ "и" ++ m.s; n = Pl} ;
|
||||
lin pot2as3 n = n ;
|
||||
lin pot31 = {s = "илјада"; n = Pl} ;
|
||||
lin pot3 n = {s = n.s ++ thousand ! n.n; n = Pl} ;
|
||||
lin pot3plus n m = {s = n.s ++ thousand ! n.n ++ m.s; n = Pl} ;
|
||||
lin pot3decimal d = {s = d.s ++ "илјади"; n = Pl} ;
|
||||
lin pot3as4 n = n ;
|
||||
lin pot41 = {s = "милион"; n = Sg} ;
|
||||
lin pot4 n = {s = n.s ++ million ! n.n; n = Pl} ;
|
||||
lin pot4plus n m = {s = n.s ++ million ! n.n ++ m.s; n = Pl} ;
|
||||
lin pot4decimal d = {s = d.s ++ "милиони"; n = Pl} ;
|
||||
lin pot4as5 n = n ;
|
||||
lin pot51 = {s = "милијарда"; n = Sg} ;
|
||||
lin pot5 n = {s = n.s ++ billion ! n.n; n = Pl} ;
|
||||
lin pot5plus n m = {s = n.s ++ billion ! n.n ++ m.s; n = Pl} ;
|
||||
lin pot5decimal d = {s = d.s ++ "милијарди"; n = Pl} ;
|
||||
|
||||
oper
|
||||
thousand : Number => Str = table {Sg => "илјада"; Pl => "илјади"} ;
|
||||
million : Number => Str = table {Sg => "милион"; Pl => "милиони"} ;
|
||||
billion : Number => Str = table {Sg => "милијарда"; Pl => "милијарди"} ;
|
||||
}
|
||||
|
||||
@@ -319,9 +319,9 @@ mkClause : Str -> Agr -> Verb ** {compl : Agr => Str} -> Order => Tense => Anter
|
||||
Neg => "не"
|
||||
} ;
|
||||
fut = case <p,o> of {
|
||||
<Pos,Main> => <"ке",[]> ;
|
||||
<Pos,Main> => <"ќе",[]> ;
|
||||
<Neg,Main> => <"нема да",[]> ;
|
||||
<Pos,Quest> => <"ке","ли"> ;
|
||||
<Pos,Quest> => <"ќе","ли"> ;
|
||||
<Neg,Quest> => <"нема ли да",[]>
|
||||
} ;
|
||||
li = case o of {
|
||||
|
||||
@@ -29,8 +29,8 @@ concrete DocumentationSom of Documentation = CatSom ** open ResSom,Prelude,HTML
|
||||
t = "n";
|
||||
s1 = heading1 "Noun";
|
||||
s2 = frameTable (tr (td "" ++ th "Sg" ++ th "Pl") ++
|
||||
tr (th "Def" ++ td (noun.s ! Def Sg) ++ td (noun.s ! Def Pl)) ++
|
||||
tr (th "Indef" ++ td (noun.s ! Indef Sg) ++ td (noun.s ! Indef Pl)) ++
|
||||
tr (th "Def" ++ td (noun.s ! Def Sg) ++ td (noun.s ! Def Pl)) ++
|
||||
tr (th "Nom" ++ td (noun.s ! NomSg) ++ td []) ++
|
||||
tr (th "Numerative" ++ intagAttr "td" "colspan=2" (noun.s ! Numerative)))
|
||||
} ;
|
||||
|
||||
@@ -64,7 +64,10 @@ concrete NounSom of Noun = CatSom ** open ResSom, Prelude in {
|
||||
} ;
|
||||
|
||||
-- : Pron -> NP ;
|
||||
UsePron pron = pron ** {st = Definite} ;
|
||||
UsePron pron = pron ** {
|
||||
s = pron.sp ;
|
||||
st = Definite
|
||||
} ;
|
||||
|
||||
-- : Predet -> NP -> NP ; -- only the man
|
||||
PredetNP predet np =
|
||||
|
||||
@@ -25,7 +25,15 @@ Lang: PhrUtt NoPConj (UttS (UseCl (TTAnt TPres ASimul) PPos (PredVP (DetCN (DetQ
|
||||
|
||||
-- LangEng: house bigger than car
|
||||
LangSom: guri ka weyn baabuur
|
||||
Lang: PhrUtt NoPConj (UttNP (AdjCN (ComparA big_A (MassNP (UseN car_N))) (UseN house_N))) NoVoc
|
||||
Lang: PhrUtt NoPConj (UttCN (AdjCN (ComparA big_A (MassNP (UseN car_N))) (UseN house_N))) NoVoc
|
||||
|
||||
-- LangEng: house bigger than he
|
||||
Lang> l PhrUtt NoPConj (UttCN (AdjCN (ComparA big_A (UsePron he_Pron)) (UseN house_N))) NoVoc
|
||||
guri ka weyn isaga
|
||||
|
||||
-- LangEng: house bigger than I
|
||||
Lang> l PhrUtt NoPConj (UttCN (AdjCN (ComparA big_A (UsePron i_Pron)) (UseN house_N))) NoVoc
|
||||
guri ka weyn aniga
|
||||
|
||||
-- LangEng: that cat is biggest
|
||||
LangSom: bisad BIND daasi waa ugu weyn tahay
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
concrete AllUkr of AllUkrAbs =
|
||||
LangUkr
|
||||
LangUkr,
|
||||
ExtendUkr
|
||||
**
|
||||
{} ;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
abstract AllUkrAbs =
|
||||
Lang
|
||||
Lang,
|
||||
Extend
|
||||
** {}
|
||||
@@ -3,6 +3,7 @@ concrete CatUkr of Cat = CommonX ** open ResUkr in {
|
||||
lincat N = N ;
|
||||
lincat N2 = N ** {c2 : Compl} ;
|
||||
lincat N3 = N ** {c2,c3 : Compl} ;
|
||||
lincat Pron = {s: Case => Str; g: Gender; n : Number; p: Person} ;
|
||||
lincat V = V ;
|
||||
lincat VV,VS,VQ,VA = V ;
|
||||
lincat V2 = V ** {c2 : Compl} ;
|
||||
|
||||
@@ -19,7 +19,7 @@ lin
|
||||
tr (th "Gen" ++ td (x.s ! Gen ! Sg) ++ td (x.s ! Gen ! Pl)) ++
|
||||
tr (th "Loc" ++ td (x.s ! Loc ! Sg) ++ td (x.s ! Loc ! Pl)) ++
|
||||
tr (th "Instr" ++ td (x.s ! Instr ! Sg) ++ td (x.s ! Instr ! Pl)) ++
|
||||
tr (th "Voc" ++ td (x.Voc ! Sg) ++ td (x.Voc ! Pl))) ;
|
||||
tr (th "Voc" ++ td (x.voc ! Sg) ++ td (x.voc ! Pl))) ;
|
||||
s3=[]
|
||||
} ;
|
||||
lin
|
||||
@@ -30,12 +30,12 @@ lin
|
||||
paragraph (x.infinitive) ++
|
||||
heading1 "Present" ++
|
||||
frameTable (
|
||||
tr (intagAttr "th" "rowspan=\"6\"" "Pres" ++ intagAttr "th" "rowspan=\"2\"" "P1" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P1 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P1 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P2" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P2 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P2 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P3" ++ th "Sg" ++ td ((x.active ! Imperf).Pres ! P3 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).Pres ! P3 ! Pl))) ++
|
||||
tr (intagAttr "th" "rowspan=\"6\"" "Pres" ++ intagAttr "th" "rowspan=\"2\"" "P1" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P1 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P1 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P2" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P2 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P2 ! Pl)) ++
|
||||
tr (intagAttr "th" "rowspan=\"2\"" "P3" ++ th "Sg" ++ td ((x.active ! Imperf).pres ! P3 ! Sg)) ++
|
||||
tr (th "Pl" ++ td ((x.active ! Imperf).pres ! P3 ! Pl))) ++
|
||||
heading1 "Imperative" ++
|
||||
paragraph (x.imperative1) ++
|
||||
frameTable (
|
||||
|
||||
15
src/ukrainian/ExtendUkr.gf
Normal file
15
src/ukrainian/ExtendUkr.gf
Normal file
@@ -0,0 +1,15 @@
|
||||
--# -path=.:../abstract:../common:prelude
|
||||
concrete ExtendUkr of Extend = CatUkr ** open ResUkr, ParadigmsUkr in {
|
||||
|
||||
lin
|
||||
iFem_Pron = mkPron "я" "мене" "мені" "мене" "мені" "мною" Fem Sg P1 ;
|
||||
youFem_Pron = mkPron "ти" "тeбе" "тобі" "мене" "тобі" "тобою" Fem Sg P2 ;
|
||||
weFem_Pron = mkPron "ми" "нас" "нам" "нас" "наc" "нами" Fem Pl P1 ;
|
||||
youPlFem_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Fem Pl P2 ;
|
||||
theyFem_Pron = mkPron "вони" "їх" "їм" "їх" "них" "ними" Fem Pl P3 ;
|
||||
youPolFem_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Fem Pl P2 ;
|
||||
youPolPl_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Masc Pl P2 ;
|
||||
youPolPlFem_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Fem Pl P2 ;
|
||||
|
||||
}
|
||||
|
||||
@@ -2,5 +2,6 @@ concrete GrammarUkr of Grammar =
|
||||
TenseX,
|
||||
PhraseUkr,
|
||||
NounUkr,
|
||||
AdjectiveUkr ** {
|
||||
AdjectiveUkr,
|
||||
StructuralUkr ** {
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1148,6 +1148,44 @@ oper
|
||||
_ => regN form1
|
||||
} ;
|
||||
|
||||
compoundN = overload {
|
||||
compoundN : A -> N -> N = \a,n -> {
|
||||
s = \\c,num => a.s ! c ! genNum n.g num ++ n.s ! c ! num ;
|
||||
voc = \\num => a.s ! Nom ! genNum n.g num ++ n.voc ! num ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : N -> A -> N = \n,a -> {
|
||||
s = \\c,num => n.s ! c ! num ++ a.s ! c ! genNum n.g num ;
|
||||
voc = \\num => n.voc ! num ++ a.s ! Nom ! genNum n.g num ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : N -> Str -> N = \n,adv -> {
|
||||
s = \\c,num => n.s ! c ! num ++ adv ;
|
||||
voc = \\num => n.voc ! num ++ adv ;
|
||||
g = n.g
|
||||
} ;
|
||||
compoundN : Str -> N -> N = \adv,n -> {
|
||||
s = \\c,num => adv ++ n.s ! c ! num ;
|
||||
voc = \\num => adv ++ n.voc ! num ;
|
||||
g = n.g
|
||||
}
|
||||
} ;
|
||||
|
||||
mkPron : (_,_,_,_,_,_ : Str) -> Gender -> Number -> Person -> Pron =
|
||||
\nom,acc,dat,gen,loc,instr,g,n,p -> lin Pron {
|
||||
s = table {
|
||||
Nom => nom ;
|
||||
Acc => acc ;
|
||||
Dat => dat ;
|
||||
Gen => gen ;
|
||||
Loc => loc ;
|
||||
Instr => instr
|
||||
} ;
|
||||
g = g ;
|
||||
n = n ;
|
||||
p = p
|
||||
} ;
|
||||
|
||||
regV : Str -> V -- Active;Imperf;Pres;P1;Sg
|
||||
= \form -> case form of {
|
||||
_ + "вати" => mkV036 form;
|
||||
@@ -1213,6 +1251,17 @@ oper
|
||||
_ => regV form1
|
||||
} ;
|
||||
|
||||
compoundV : V -> Str -> V = \v,adv -> {
|
||||
active = \\a => {past=(v.active ! a).past ++ adv ;
|
||||
pres=\\p,num=>(v.active ! a).pres ! p ! num ++ adv
|
||||
} ;
|
||||
imperative1 = v.imperative1 ++ adv ;
|
||||
imperative2 = \\num => v.imperative2 ! num ++ adv ;
|
||||
infinitive = v.infinitive ++ adv ;
|
||||
participle = \\g,num => v.participle ! g ! num ++ adv ;
|
||||
passive = \\a,t => v.passive ! a ! t ++ adv
|
||||
} ;
|
||||
|
||||
regA : Str -> A -- s;Nom;('GSg', Masc)
|
||||
= \form -> case form of {
|
||||
_ + "ій" => mkA003 form;
|
||||
|
||||
@@ -3,7 +3,7 @@ resource ResUkr = {
|
||||
param Case = Nom | Acc | Dat | Gen | Loc | Instr ;
|
||||
param Number = Sg | Pl ;
|
||||
param Gender = Masc | Neuter | Fem ;
|
||||
oper N = {s: Case => Number => Str; Voc: Number => Str; g: Gender} ; -- 11407
|
||||
oper N = {s: Case => Number => Str; voc: Number => Str; g: Gender} ; -- 11407
|
||||
oper mkN : (_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Gender -> N =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14,g ->
|
||||
{ s = table {
|
||||
@@ -32,7 +32,7 @@ oper mkN : (_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Gender -> N =
|
||||
Pl => f12
|
||||
}
|
||||
} ;
|
||||
Voc = table {
|
||||
voc = table {
|
||||
Sg => f13 ;
|
||||
Pl => f14
|
||||
} ;
|
||||
@@ -43,12 +43,12 @@ oper mkN : (_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> Gender -> N =
|
||||
param Aspect = Perf | Imperf ;
|
||||
param Person = P1 | P2 | P3 ;
|
||||
param Tense = Past | Pres ;
|
||||
oper V = {active: Aspect => {Past: Str; Pres: Person => Number => Str}; imperative1: Str; imperative2: Number => Str; infinitive: Str; participle: Gender => Number => Str; passive: Aspect => Tense => Str} ; -- 4822
|
||||
oper V = {active: Aspect => {past: Str; pres: Person => Number => Str}; imperative1: Str; imperative2: Number => Str; infinitive: Str; participle: Gender => Number => Str; passive: Aspect => Tense => Str} ; -- 4822
|
||||
oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14,f15,f16,f17,f18,f19,f20,f21,f22,f23,f24,f25,f26,f27,f28 ->
|
||||
{ active = table {
|
||||
Imperf => { Past = f1 ;
|
||||
Pres = table {
|
||||
Imperf => { past = f1 ;
|
||||
pres = table {
|
||||
P1 => table {
|
||||
Sg => f2 ;
|
||||
Pl => f3
|
||||
@@ -63,8 +63,8 @@ oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V
|
||||
}
|
||||
}
|
||||
} ;
|
||||
Perf => { Past = f8 ;
|
||||
Pres = table {
|
||||
Perf => { past = f8 ;
|
||||
pres = table {
|
||||
P1 => table {
|
||||
Sg => f9 ;
|
||||
Pl => f10
|
||||
@@ -113,6 +113,12 @@ oper mkV : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> V
|
||||
} ;
|
||||
|
||||
param GenNum = GSg Gender | GPl ;
|
||||
oper genNum : Gender -> Number -> GenNum = \g,n ->
|
||||
case n of {
|
||||
Sg => GSg g ;
|
||||
Pl => GPl
|
||||
} ;
|
||||
|
||||
oper A = {s: Case => GenNum => Str} ; -- 4394
|
||||
oper mkA : (_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_ : Str) -> A =
|
||||
\f1,f2,f3,f4,f5,f6,f7,f8,f9,f10,f11,f12,f13,f14,f15,f16,f17,f18,f19,f20,f21,f22,f23,f24 ->
|
||||
|
||||
12
src/ukrainian/StructuralUkr.gf
Normal file
12
src/ukrainian/StructuralUkr.gf
Normal file
@@ -0,0 +1,12 @@
|
||||
concrete StructuralUkr of Structural = CatUkr ** open ResUkr, ParadigmsUkr in {
|
||||
lin
|
||||
i_Pron = mkPron "я" "мене" "мені" "мене" "мені" "мною" Masc Sg P1 ;
|
||||
youSg_Pron = mkPron "ти" "тeбе" "тобі" "мене" "тобі" "тобою" Masc Sg P2 ;
|
||||
he_Pron = mkPron "він" "його" "йому" "його" "ньому" "ним" Masc Sg P3 ;
|
||||
she_Pron = mkPron "вона" "її" "їй" "її" "ній" "нею" Fem Sg P3 ;
|
||||
it_Pron = mkPron "воно" "його" "йому" "його" "ньому" "ним" Neuter Sg P3 ;
|
||||
we_Pron = mkPron "ми" "нас" "нам" "нас" "наc" "нами" Masc Pl P1 ;
|
||||
youPl_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Masc Pl P2 ;
|
||||
youPol_Pron = mkPron "ви" "вас" "вам" "вас" "вас" "вами" Masc Pl P2 ;
|
||||
they_Pron = mkPron "вони" "їх" "їм" "їх" "них" "ними" Masc Pl P3 ;
|
||||
}
|
||||
Reference in New Issue
Block a user