mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-20 16:42:51 -06:00
documented Paradigms for Swe, Ger, Fre
This commit is contained in:
@@ -45,21 +45,21 @@ oper
|
|||||||
|
|
||||||
-- To abstract over number names, we define the following.
|
-- To abstract over number names, we define the following.
|
||||||
|
|
||||||
Number : Type ;
|
Number : Type ; --%
|
||||||
|
|
||||||
singular : Number ;
|
singular : Number ; --%
|
||||||
plural : Number ;
|
plural : Number ; --%
|
||||||
|
|
||||||
-- Prepositions used in many-argument functions are either strings
|
-- Prepositions used in many-argument functions are either strings
|
||||||
-- (including the 'accusative' empty string) or strings that
|
-- (including the 'accusative' empty string) or strings that
|
||||||
-- amalgamate with the following word (the 'genitive' "de" and the
|
-- amalgamate with the following word (the 'genitive' "de" and the
|
||||||
-- 'dative' "à").
|
-- 'dative' "à").
|
||||||
|
|
||||||
accusative : Prep ;
|
accusative : Prep ; -- direct object case
|
||||||
genitive : Prep ;
|
genitive : Prep ; -- genitive, constructed with "de"
|
||||||
dative : Prep ;
|
dative : Prep ; -- dative, usually constructed with "à"
|
||||||
|
|
||||||
mkPrep : Str -> Prep ;
|
mkPrep : Str -> Prep ; -- preposition (other than "de" and "à")
|
||||||
|
|
||||||
|
|
||||||
--2 Nouns
|
--2 Nouns
|
||||||
@@ -74,15 +74,15 @@ oper
|
|||||||
-- The gender heuristic is less reliable: it treats as feminine all
|
-- The gender heuristic is less reliable: it treats as feminine all
|
||||||
-- nouns ending with "e" and "ion", all others as masculine.
|
-- nouns ending with "e" and "ion", all others as masculine.
|
||||||
|
|
||||||
mkN : (cheval : Str) -> N ;
|
mkN : (cheval : Str) -> N ; -- predictable, with variations like cheval-chevaux
|
||||||
|
|
||||||
-- Adding gender information widens the scope of the regular pattern.
|
-- Adding gender information widens the scope of the regular pattern.
|
||||||
|
|
||||||
mkN : (foie : Str) -> Gender -> N ;
|
mkN : (foie : Str) -> Gender -> N ; --%
|
||||||
|
|
||||||
-- In the worst case, both singular and plural forms and the gender are needed.
|
-- In the worst case, both singular and plural forms and the gender are needed.
|
||||||
|
|
||||||
mkN : (oeil,yeux : Str) -> Gender -> N ;
|
mkN : (oeil,yeux : Str) -> Gender -> N ; -- worst-case noun
|
||||||
|
|
||||||
--3 Compound nouns
|
--3 Compound nouns
|
||||||
--
|
--
|
||||||
@@ -91,7 +91,7 @@ oper
|
|||||||
-- They could be formed in syntax, but we give a shortcut here since
|
-- They could be formed in syntax, but we give a shortcut here since
|
||||||
-- they are frequent in lexica.
|
-- they are frequent in lexica.
|
||||||
|
|
||||||
mkN : N -> Str -> N
|
mkN : N -> Str -> N -- compound noun, e.g. numéro + de téléphone
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -101,17 +101,17 @@ oper
|
|||||||
--
|
--
|
||||||
-- Relational nouns ("fille de x") need a case and a preposition.
|
-- Relational nouns ("fille de x") need a case and a preposition.
|
||||||
|
|
||||||
mkN2 : N -> Prep -> N2 ;
|
mkN2 : N -> Prep -> N2 ; -- e.g. fille + genitive
|
||||||
|
|
||||||
-- The most common cases are the genitive "de" and the dative "à",
|
-- The most common cases are the genitive "de" and the dative "à",
|
||||||
-- with the empty preposition.
|
-- with the empty preposition.
|
||||||
|
|
||||||
deN2 : N -> N2 ;
|
deN2 : N -> N2 ; --%
|
||||||
aN2 : N -> N2 ;
|
aN2 : N -> N2 ; --%
|
||||||
|
|
||||||
-- Three-place relational nouns ("la connection de x à y") need two prepositions.
|
-- Three-place relational nouns ("la connection de x à y") need two prepositions.
|
||||||
|
|
||||||
mkN3 : N -> Prep -> Prep -> N3 ;
|
mkN3 : N -> Prep -> Prep -> N3 ; -- e.g. connection + genitive + dative
|
||||||
|
|
||||||
|
|
||||||
--3 Relational common noun phrases
|
--3 Relational common noun phrases
|
||||||
@@ -128,8 +128,8 @@ oper
|
|||||||
-- feminine is used for strings ending with "e", the masculine for other strings.
|
-- feminine is used for strings ending with "e", the masculine for other strings.
|
||||||
|
|
||||||
mkPN : overload {
|
mkPN : overload {
|
||||||
mkPN : Str -> PN ;
|
mkPN : Str -> PN ; -- feminine if ends with "e", otherwise masculine
|
||||||
mkPN : Str -> Gender -> PN
|
mkPN : Str -> Gender -> PN -- gender deviant from the simple rule
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -144,21 +144,21 @@ oper
|
|||||||
-- "heureux-heureuse-heureux", "italien-italienne", "jeune-jeune",
|
-- "heureux-heureuse-heureux", "italien-italienne", "jeune-jeune",
|
||||||
-- "amer-amère", "carré- - -carrément", "joli- - -joliment".
|
-- "amer-amère", "carré- - -carrément", "joli- - -joliment".
|
||||||
|
|
||||||
mkA : (cher : Str) -> A ;
|
mkA : (cher : Str) -> A ; -- predictable, e.g. cher-chère
|
||||||
|
|
||||||
-- Often just the feminine singular is deviant.
|
-- Often just the feminine singular is deviant.
|
||||||
|
|
||||||
mkA : (sec,seche : Str) -> A ;
|
mkA : (sec,seche : Str) -> A ; -- unpredictable feminine
|
||||||
|
|
||||||
-- This is the worst-case paradigm for the positive forms.
|
-- This is the worst-case paradigm for the positive forms.
|
||||||
|
|
||||||
mkA : (banal,banale,banaux,banalement : Str) -> A ;
|
mkA : (banal,banale,banaux,banalement : Str) -> A ; -- worst-case adjective
|
||||||
|
|
||||||
-- If comparison forms are irregular (i.e. not formed by "plus", e.g.
|
-- If comparison forms are irregular (i.e. not formed by "plus", e.g.
|
||||||
-- "bon-meilleur"), the positive and comparative can be given as separate
|
-- "bon-meilleur"), the positive and comparative can be given as separate
|
||||||
-- adjectives.
|
-- adjectives.
|
||||||
|
|
||||||
mkA : A -> A -> A
|
mkA : A -> A -> A -- irregular comparison, e.g. bon-meilleur
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- The functions create by default postfix adjectives. To switch
|
-- The functions create by default postfix adjectives. To switch
|
||||||
@@ -166,14 +166,14 @@ oper
|
|||||||
-- modification, as in "petite maison"), the following function is
|
-- modification, as in "petite maison"), the following function is
|
||||||
-- provided.
|
-- provided.
|
||||||
|
|
||||||
prefixA : A -> A ;
|
prefixA : A -> A ; -- adjective that comes before noun, e.g. petit
|
||||||
|
|
||||||
|
|
||||||
--3 Two-place adjectives
|
--3 Two-place adjectives
|
||||||
--
|
--
|
||||||
-- Two-place adjectives need a preposition for their second argument.
|
-- Two-place adjectives need a preposition for their second argument.
|
||||||
|
|
||||||
mkA2 : A -> Prep -> A2 ;
|
mkA2 : A -> Prep -> A2 ; -- e.g. supérieur + dative
|
||||||
|
|
||||||
|
|
||||||
--2 Adverbs
|
--2 Adverbs
|
||||||
@@ -181,15 +181,15 @@ oper
|
|||||||
-- Adverbs are not inflected. Most lexical ones have position
|
-- Adverbs are not inflected. Most lexical ones have position
|
||||||
-- after the verb.
|
-- after the verb.
|
||||||
|
|
||||||
mkAdv : Str -> Adv ;
|
mkAdv : Str -> Adv ; -- ordinary adverb
|
||||||
|
|
||||||
-- Some appear next to the verb (e.g. "toujours").
|
-- Some appear next to the verb (e.g. "toujours").
|
||||||
|
|
||||||
mkAdV : Str -> AdV ;
|
mkAdV : Str -> AdV ; -- sentential adverb, e.g. toujours
|
||||||
|
|
||||||
-- Adverbs modifying adjectives and sentences can also be formed.
|
-- Adverbs modifying adjectives and sentences can also be formed.
|
||||||
|
|
||||||
mkAdA : Str -> AdA ;
|
mkAdA : Str -> AdA ; -- modify adjective, e.g. très
|
||||||
|
|
||||||
|
|
||||||
--2 Verbs
|
--2 Verbs
|
||||||
@@ -210,23 +210,23 @@ oper
|
|||||||
-- (("il") "jette", "jettera") as second argument.
|
-- (("il") "jette", "jettera") as second argument.
|
||||||
|
|
||||||
mkV : overload {
|
mkV : overload {
|
||||||
mkV : (finir : Str) -> V ;
|
mkV : (finir : Str) -> V ; -- regular 1/2/3 conjugation
|
||||||
mkV : (jeter,jette,jettera : Str) -> V ;
|
mkV : (jeter,jette,jettera : Str) -> V ; -- 1st conjugation variations
|
||||||
|
|
||||||
-- The $IrregFre$ list gives some verbs as two-place. These verbs can be
|
-- The $IrregFre$ list gives some verbs as two-place. These verbs can be
|
||||||
-- reused as one-place verbs.
|
-- reused as one-place verbs.
|
||||||
|
|
||||||
mkV : V2 -> V
|
mkV : V2 -> V ; -- make 2-place to 1-place (e.g. from IrregFre)
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- The function $mkV$ gives the default compound auxiliary "avoir".
|
-- The function $mkV$ gives the default compound auxiliary "avoir".
|
||||||
-- To change it to "être", use the following function.
|
-- To change it to "être", use the following function.
|
||||||
|
|
||||||
etreV : V -> V ;
|
etreV : V -> V ; -- force auxiliary to be être (default avoir)
|
||||||
|
|
||||||
-- This function turns a verb into reflexive, which implies the auxiliary "être".
|
-- This function turns a verb into reflexive, which implies the auxiliary "être".
|
||||||
|
|
||||||
reflV : V -> V ;
|
reflV : V -> V ; -- reflexive, implies auxiliary être, e.g. se demander
|
||||||
|
|
||||||
|
|
||||||
--3 Two-place verbs
|
--3 Two-place verbs
|
||||||
@@ -235,11 +235,11 @@ oper
|
|||||||
-- (transitive verbs).
|
-- (transitive verbs).
|
||||||
|
|
||||||
mkV2 = overload {
|
mkV2 = overload {
|
||||||
mkV2 : Str -> V2
|
mkV2 : Str -> V2 --%
|
||||||
= \s -> dirV2 (regV s) ;
|
= \s -> dirV2 (regV s) ;
|
||||||
mkV2 : V -> V2
|
mkV2 : V -> V2 -- direct transitive
|
||||||
= dirV2 ;
|
= dirV2 ;
|
||||||
mkV2 : V -> Prep -> V2
|
mkV2 : V -> Prep -> V2 -- e.g. se fier + genitive
|
||||||
= mmkV2
|
= mmkV2
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
@@ -250,9 +250,9 @@ oper
|
|||||||
-- the first one or both can be absent.
|
-- the first one or both can be absent.
|
||||||
|
|
||||||
mkV3 : overload {
|
mkV3 : overload {
|
||||||
mkV3 : V -> V3 ; -- donner,_,_
|
mkV3 : V -> V3 ; -- donner (+ accusative + dative)
|
||||||
mkV3 : V -> Prep -> V3 ; -- placer,_,dans
|
mkV3 : V -> Prep -> V3 ; -- placer (+ accusative) + dans
|
||||||
mkV3 : V -> Prep -> Prep -> V3 -- parler, à, de
|
mkV3 : V -> Prep -> Prep -> V3 -- parler + dative + genitive
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
--3 Other complement patterns
|
--3 Other complement patterns
|
||||||
@@ -260,7 +260,7 @@ oper
|
|||||||
-- Verbs and adjectives can take complements such as sentences,
|
-- Verbs and adjectives can take complements such as sentences,
|
||||||
-- questions, verb phrases, and adjectives.
|
-- questions, verb phrases, and adjectives.
|
||||||
|
|
||||||
mkV0 : V -> V0 ;
|
mkV0 : V -> V0 ; --%
|
||||||
mkVS : V -> VS ;
|
mkVS : V -> VS ;
|
||||||
mkV2S : V -> Prep -> V2S ;
|
mkV2S : V -> Prep -> V2S ;
|
||||||
mkVV : V -> VV ; -- plain infinitive: "je veux parler"
|
mkVV : V -> VV ; -- plain infinitive: "je veux parler"
|
||||||
@@ -272,17 +272,17 @@ oper
|
|||||||
mkVQ : V -> VQ ;
|
mkVQ : V -> VQ ;
|
||||||
mkV2Q : V -> Prep -> V2Q ;
|
mkV2Q : V -> Prep -> V2Q ;
|
||||||
|
|
||||||
mkAS : A -> AS ;
|
mkAS : A -> AS ; --%
|
||||||
mkA2S : A -> Prep -> A2S ;
|
mkA2S : A -> Prep -> A2S ; --%
|
||||||
mkAV : A -> Prep -> AV ;
|
mkAV : A -> Prep -> AV ; --%
|
||||||
mkA2V : A -> Prep -> Prep -> A2V ;
|
mkA2V : A -> Prep -> Prep -> A2V ; --%
|
||||||
|
|
||||||
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$,
|
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$,
|
||||||
-- and the second argument is given as an adverb. Likewise
|
-- and the second argument is given as an adverb. Likewise
|
||||||
-- $V0$ is just $V$.
|
-- $V0$ is just $V$.
|
||||||
|
|
||||||
V0 : Type ;
|
V0 : Type ; --%
|
||||||
AS, A2S, AV, A2V : Type ;
|
AS, A2S, AV, A2V : Type ; --%
|
||||||
|
|
||||||
--.
|
--.
|
||||||
--2 Definitions of the paradigms
|
--2 Definitions of the paradigms
|
||||||
|
|||||||
@@ -47,10 +47,10 @@ oper
|
|||||||
dative : Case ;
|
dative : Case ;
|
||||||
genitive : Case ;
|
genitive : Case ;
|
||||||
|
|
||||||
anDat_Case : Case ;
|
anDat_Case : Case ; -- preposition "an" accusative with contraction "am" --%
|
||||||
inAcc_Case : Case ;
|
inAcc_Case : Case ; -- preposition "in" accusative with contraction "ins" --%
|
||||||
inDat_Case : Case ;
|
inDat_Case : Case ; -- preposition "in" dative with contraction "am" --%
|
||||||
zuDat_Case : Case ;
|
zuDat_Case : Case ; -- preposition "zu" dative with contractions "zum", "zur" --%
|
||||||
|
|
||||||
-- To abstract over number names, we define the following.
|
-- To abstract over number names, we define the following.
|
||||||
|
|
||||||
@@ -69,19 +69,18 @@ mkN : overload {
|
|||||||
-- feminine with plural ending "-n, -en", and the rest are masculines
|
-- feminine with plural ending "-n, -en", and the rest are masculines
|
||||||
-- with the plural "-e" (without Umlaut).
|
-- with the plural "-e" (without Umlaut).
|
||||||
|
|
||||||
mkN : (Stufe : Str) -> N ;
|
mkN : (Stufe : Str) -> N ; -- die Stufe-Stufen, der Tisch-Tische
|
||||||
|
|
||||||
-- The 'almost regular' case is much like the information given in an ordinary
|
-- The 'almost regular' case is much like the information given in an ordinary
|
||||||
-- dictionary. It takes the singular and plural nominative and the
|
-- dictionary. It takes the singular and plural nominative and the
|
||||||
-- gender, and infers the other forms from these.
|
-- gender, and infers the other forms from these.
|
||||||
|
|
||||||
mkN : (Bild,Bilder : Str) -> Gender -> N ;
|
mkN : (Bild,Bilder : Str) -> Gender -> N ; -- sg and pl nom, and gender
|
||||||
|
|
||||||
-- Worst case: give all four singular forms, two plural forms (others + dative),
|
-- Worst case: give all four singular forms, two plural forms (others + dative),
|
||||||
-- and the gender.
|
-- and the gender.
|
||||||
|
|
||||||
mkN : (x1,_,_,_,_,x6 : Str) -> Gender -> N
|
mkN : (x1,_,_,_,_,x6 : Str) -> Gender -> N -- worst case: mann, mann, manne, mannes, männer, männern
|
||||||
-- mann, mann, manne, mannes, männer, männern
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -89,9 +88,9 @@ mkN : overload {
|
|||||||
-- the dative, and there is a special case for regular nouns.
|
-- the dative, and there is a special case for regular nouns.
|
||||||
|
|
||||||
mkN2 : overload {
|
mkN2 : overload {
|
||||||
mkN2 : Str -> N2 ;
|
mkN2 : Str -> N2 ; --%
|
||||||
mkN2 : N -> N2 ;
|
mkN2 : N -> N2 ; -- noun + von
|
||||||
mkN2 : N -> Prep -> N2
|
mkN2 : N -> Prep -> N2 -- noun + other preposition
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- Use the function $mkPrep$ or see the section on prepositions below to
|
-- Use the function $mkPrep$ or see the section on prepositions below to
|
||||||
@@ -100,7 +99,7 @@ mkN : overload {
|
|||||||
--
|
--
|
||||||
-- Three-place relational nouns ("die Verbindung von x nach y") need two prepositions.
|
-- Three-place relational nouns ("die Verbindung von x nach y") need two prepositions.
|
||||||
|
|
||||||
mkN3 : N -> Prep -> Prep -> N3 ;
|
mkN3 : N -> Prep -> Prep -> N3 ; -- noun + two prepositions
|
||||||
|
|
||||||
|
|
||||||
--3 Proper names and noun phrases
|
--3 Proper names and noun phrases
|
||||||
@@ -110,15 +109,15 @@ mkN : overload {
|
|||||||
-- taken into account.
|
-- taken into account.
|
||||||
|
|
||||||
mkPN : overload {
|
mkPN : overload {
|
||||||
mkPN : Str -> PN ;
|
mkPN : Str -> PN ; -- regular name with genitive in "s"
|
||||||
|
|
||||||
-- If only the genitive differs, two strings are needed.
|
-- If only the genitive differs, two strings are needed.
|
||||||
|
|
||||||
mkPN : (nom,gen : Str) -> PN ;
|
mkPN : (nom,gen : Str) -> PN ; -- name with other genitive
|
||||||
|
|
||||||
-- In the worst case, all four forms are needed.
|
-- In the worst case, all four forms are needed.
|
||||||
|
|
||||||
mkPN : (nom,acc,dat,gen : Str) -> PN
|
mkPN : (nom,acc,dat,gen : Str) -> PN -- name with all case forms
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -130,52 +129,52 @@ mkN : overload {
|
|||||||
-- The regular adjective formation works for most cases, and includes
|
-- The regular adjective formation works for most cases, and includes
|
||||||
-- variations such as "teuer - teurer", "böse - böser".
|
-- variations such as "teuer - teurer", "böse - böser".
|
||||||
|
|
||||||
mkA : Str -> A ;
|
mkA : Str -> A ; -- regular adjective, works for most cases
|
||||||
|
|
||||||
-- Irregular adjectives need three forms - one for each degree.
|
-- Irregular adjectives need three forms - one for each degree.
|
||||||
|
|
||||||
mkA : (gut,besser,beste : Str) -> A ;
|
mkA : (gut,besser,beste : Str) -> A ; -- irregular comparison
|
||||||
|
|
||||||
-- Sometimes an extra form is needed for positive forms.
|
-- Sometimes an extra form is needed for positive forms.
|
||||||
|
|
||||||
mkA : (gut,gute,besser,beste : Str) -> A
|
mkA : (gut,gute,besser,beste : Str) -> A -- irregular positive if ending added
|
||||||
|
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- Invariable adjective are a special case.
|
-- Invariable adjective are a special case.
|
||||||
|
|
||||||
invarA : Str -> A ; -- prima
|
invarA : Str -> A ; -- invariable, e.g. prima
|
||||||
|
|
||||||
-- Two-place adjectives are formed by adding a preposition to an adjective.
|
-- Two-place adjectives are formed by adding a preposition to an adjective.
|
||||||
|
|
||||||
mkA2 : A -> Prep -> A2 ;
|
mkA2 : A -> Prep -> A2 ; -- e.g. teilbar + durch
|
||||||
|
|
||||||
--2 Adverbs
|
--2 Adverbs
|
||||||
|
|
||||||
-- Adverbs are formed from strings.
|
-- Adverbs are formed from strings.
|
||||||
|
|
||||||
mkAdv : Str -> Adv ;
|
mkAdv : Str -> Adv ; -- adverbs have just one form anyway
|
||||||
|
|
||||||
|
|
||||||
--2 Prepositions
|
--2 Prepositions
|
||||||
|
|
||||||
-- A preposition is formed from a string and a case.
|
-- A preposition is formed from a string and a case.
|
||||||
|
|
||||||
mkPrep : Str -> PCase -> Prep ;
|
mkPrep : Str -> Case -> Prep ; -- e.g. "durch" + accusative
|
||||||
|
|
||||||
-- Often just a case with the empty string is enough.
|
-- Often just a case with the empty string is enough.
|
||||||
|
|
||||||
accPrep : Prep ;
|
accPrep : Prep ; -- no string, just accusative case
|
||||||
datPrep : Prep ;
|
datPrep : Prep ; -- no string, just dative case
|
||||||
genPrep : Prep ;
|
genPrep : Prep ; -- no string, just genitive case
|
||||||
|
|
||||||
-- A couple of common prepositions (the first two always with the dative).
|
-- A couple of common prepositions (the first two always with the dative).
|
||||||
|
|
||||||
von_Prep : Prep ;
|
von_Prep : Prep ; -- von + dative
|
||||||
zu_Prep : Prep ;
|
zu_Prep : Prep ; -- zu + dative, with contractions zum, zur
|
||||||
anDat_Prep : Prep ;
|
anDat_Prep : Prep ; -- an + dative, with contraction am
|
||||||
inDat_Prep : Prep ;
|
inDat_Prep : Prep ; -- in + dative, with contraction ins
|
||||||
inAcc_Prep : Prep ;
|
inAcc_Prep : Prep ; -- in + accusative, with contraction im
|
||||||
|
|
||||||
--2 Verbs
|
--2 Verbs
|
||||||
|
|
||||||
@@ -183,11 +182,11 @@ mkV : overload {
|
|||||||
|
|
||||||
-- Regular verbs ("weak verbs") need just the infinitive form.
|
-- Regular verbs ("weak verbs") need just the infinitive form.
|
||||||
|
|
||||||
mkV : (führen : Str) -> V ;
|
mkV : (führen : Str) -> V ; -- regular verb
|
||||||
|
|
||||||
-- Irregular verbs use Ablaut and, in the worst cases, also Umlaut.
|
-- Irregular verbs use Ablaut and, in the worst cases, also Umlaut.
|
||||||
|
|
||||||
mkV : (sehen,sieht,sah,sähe,gesehen : Str) -> V ;
|
mkV : (sehen,sieht,sah,sähe,gesehen : Str) -> V ; -- irregular verb theme
|
||||||
|
|
||||||
-- The worst-case constructor needs six forms:
|
-- The worst-case constructor needs six forms:
|
||||||
-- - Infinitive,
|
-- - Infinitive,
|
||||||
@@ -199,32 +198,32 @@ mkV : overload {
|
|||||||
--
|
--
|
||||||
--
|
--
|
||||||
|
|
||||||
mkV : (geben, gibt, gib, gab, gäbe, gegeben : Str) -> V ;
|
mkV : (geben, gibt, gib, gab, gäbe, gegeben : Str) -> V ; -- worst-case verb
|
||||||
|
|
||||||
-- To add a movable prefix e.g. "auf(fassen)".
|
-- To add a movable prefix e.g. "auf(fassen)".
|
||||||
|
|
||||||
mkV : Str -> V -> V
|
mkV : Str -> V -> V -- movable prefix, e.g. auf+fassen
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
-- To remove the past participle prefix "ge", e.g. for the verbs
|
-- To remove the past participle prefix "ge", e.g. for the verbs
|
||||||
-- prefixed by "be-, ver-".
|
-- prefixed by "be-, ver-".
|
||||||
|
|
||||||
no_geV : V -> V ;
|
no_geV : V -> V ; -- no participle "ge", e.g. "bedeuten"
|
||||||
|
|
||||||
-- To add a fixed prefix such as "be-, ver-"; this implies $no_geV$.
|
-- To add a fixed prefix such as "be-, ver-"; this implies $no_geV$.
|
||||||
|
|
||||||
fixprefixV : Str -> V -> V ;
|
fixprefixV : Str -> V -> V ; -- add prefix such as "be"; implies no_ge
|
||||||
|
|
||||||
-- To change the auxiliary from "haben" (default) to "sein" and
|
-- To change the auxiliary from "haben" (default) to "sein" and
|
||||||
-- vice-versa.
|
-- vice-versa.
|
||||||
|
|
||||||
seinV : V -> V ;
|
seinV : V -> V ; -- force "sein" as auxiliary
|
||||||
habenV : V -> V ;
|
habenV : V -> V ; -- force "haben" as auxiliary
|
||||||
|
|
||||||
-- Reflexive verbs can take reflexive pronouns of different cases.
|
-- Reflexive verbs can take reflexive pronouns of different cases.
|
||||||
|
|
||||||
reflV : V -> Case -> V ;
|
reflV : V -> Case -> V ; -- reflexive, with case
|
||||||
|
|
||||||
|
|
||||||
--3 Two-place verbs
|
--3 Two-place verbs
|
||||||
@@ -233,19 +232,19 @@ mkV2 : overload {
|
|||||||
|
|
||||||
-- Two-place regular verbs with direct object (accusative, transitive verbs).
|
-- Two-place regular verbs with direct object (accusative, transitive verbs).
|
||||||
|
|
||||||
mkV2 : Str -> V2 ;
|
mkV2 : Str -> V2 ; --%
|
||||||
|
|
||||||
-- Two-place verbs with direct object.
|
-- Two-place verbs with direct object.
|
||||||
|
|
||||||
mkV2 : V -> V2 ;
|
mkV2 : V -> V2 ; -- direct object
|
||||||
|
|
||||||
-- Two-place verbs with a preposition.
|
-- Two-place verbs with a preposition.
|
||||||
|
|
||||||
mkV2 : V -> Prep -> V2 ;
|
mkV2 : V -> Prep -> V2 ; -- preposition for complement
|
||||||
|
|
||||||
-- Two-place verbs with object in the given case.
|
-- Two-place verbs with object in the given case.
|
||||||
|
|
||||||
mkV2 : V -> Case -> V2
|
mkV2 : V -> Case -> V2 ; -- just case for complement
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -254,16 +253,17 @@ mkV2 : overload {
|
|||||||
-- Three-place (ditransitive) verbs need two prepositions, of which
|
-- Three-place (ditransitive) verbs need two prepositions, of which
|
||||||
-- the first one or both can be absent.
|
-- the first one or both can be absent.
|
||||||
|
|
||||||
mkV3 : V -> Prep -> Prep -> V3 ; -- sprechen, mit, über
|
accdatV3 : V -> V3 ; -- geben + acc + dat
|
||||||
dirV3 : V -> Prep -> V3 ; -- senden,(accusative),nach
|
dirV3 : V -> Prep -> V3 ; -- senden + acc + nach
|
||||||
accdatV3 : V -> V3 ; -- give,accusative,dative
|
mkV3 : V -> Prep -> Prep -> V3 ; -- sprechen + mit + über
|
||||||
|
|
||||||
|
|
||||||
--3 Other complement patterns
|
--3 Other complement patterns
|
||||||
--
|
--
|
||||||
-- Verbs and adjectives can take complements such as sentences,
|
-- Verbs and adjectives can take complements such as sentences,
|
||||||
-- questions, verb phrases, and adjectives.
|
-- questions, verb phrases, and adjectives.
|
||||||
|
|
||||||
mkV0 : V -> V0 ;
|
mkV0 : V -> V0 ; --%
|
||||||
mkVS : V -> VS ;
|
mkVS : V -> VS ;
|
||||||
mkV2S : V -> Prep -> V2S ;
|
mkV2S : V -> Prep -> V2S ;
|
||||||
mkVV : V -> VV ;
|
mkVV : V -> VV ;
|
||||||
@@ -273,17 +273,17 @@ mkV2 : overload {
|
|||||||
mkVQ : V -> VQ ;
|
mkVQ : V -> VQ ;
|
||||||
mkV2Q : V -> Prep -> V2Q ;
|
mkV2Q : V -> Prep -> V2Q ;
|
||||||
|
|
||||||
mkAS : A -> AS ;
|
mkAS : A -> AS ; --%
|
||||||
mkA2S : A -> Prep -> A2S ;
|
mkA2S : A -> Prep -> A2S ; --%
|
||||||
mkAV : A -> AV ;
|
mkAV : A -> AV ; --%
|
||||||
mkA2V : A -> Prep -> A2V ;
|
mkA2V : A -> Prep -> A2V ; --%
|
||||||
|
|
||||||
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$,
|
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$,
|
||||||
-- and the second argument is given as an adverb. Likewise
|
-- and the second argument is given as an adverb. Likewise
|
||||||
-- $V0$ is just $V$.
|
-- $V0$ is just $V$.
|
||||||
|
|
||||||
V0 : Type ;
|
V0 : Type ; --%
|
||||||
AS, A2S, AV, A2V : Type ;
|
AS, A2S, AV, A2V : Type ; --%
|
||||||
|
|
||||||
|
|
||||||
--.
|
--.
|
||||||
|
|||||||
@@ -41,8 +41,8 @@ resource ParadigmsSwe =
|
|||||||
oper
|
oper
|
||||||
Gender : Type ;
|
Gender : Type ;
|
||||||
|
|
||||||
utrum : Gender ;
|
utrum : Gender ; -- the "en" gender
|
||||||
neutrum : Gender ;
|
neutrum : Gender ; -- the "ett" gender
|
||||||
|
|
||||||
-- To abstract over number names, we define the following.
|
-- To abstract over number names, we define the following.
|
||||||
|
|
||||||
@@ -53,14 +53,14 @@ oper
|
|||||||
|
|
||||||
-- To abstract over case names, we define the following.
|
-- To abstract over case names, we define the following.
|
||||||
|
|
||||||
Case : Type ;
|
Case : Type ; --%
|
||||||
|
|
||||||
nominative : Case ;
|
nominative : Case ; --%
|
||||||
genitive : Case ;
|
genitive : Case ; --%
|
||||||
|
|
||||||
-- Prepositions used in many-argument functions can be constructed from strings.
|
-- Prepositions used in many-argument functions can be constructed from strings.
|
||||||
|
|
||||||
mkPrep : Str -> Prep ;
|
mkPrep : Str -> Prep ; -- e.g. "till"
|
||||||
noPrep : Prep ; -- empty string
|
noPrep : Prep ; -- empty string
|
||||||
|
|
||||||
|
|
||||||
@@ -75,22 +75,22 @@ oper
|
|||||||
-- to treat all words ending with "a" like "apa-apor", with "e" like "rike-riken",
|
-- to treat all words ending with "a" like "apa-apor", with "e" like "rike-riken",
|
||||||
-- and otherwise like "bil-bilar".
|
-- and otherwise like "bil-bilar".
|
||||||
|
|
||||||
mkN : (apa : Str) -> N ;
|
mkN : (apa : Str) -> N ; -- predictable nouns: apa-apor, rike-riken, or bil-bilar
|
||||||
|
|
||||||
-- The case with a string and gender makes it possible to treat
|
-- The case with a string and gender makes it possible to treat
|
||||||
-- "lik" (neutrum) and "pojke" (utrum).
|
-- "lik" (neutrum) and "pojke" (utrum).
|
||||||
|
|
||||||
mkN : (lik : Str) -> Gender -> N ;
|
mkN : (lik : Str) -> Gender -> N ; --%
|
||||||
|
|
||||||
-- Giving two forms - the singular and plural indefinite - is sufficient for
|
-- Giving two forms - the singular and plural indefinite - is sufficient for
|
||||||
-- most nouns. The paradigm deals correctly with the vowel contractions in
|
-- most nouns. The paradigm deals correctly with the vowel contractions in
|
||||||
-- "nyckel - nycklar" such as "pojke - pojkar".
|
-- "nyckel - nycklar" such as "pojke - pojkar".
|
||||||
|
|
||||||
mkN : (nyckel,nycklar : Str) -> N ;
|
mkN : (nyckel,nycklar : Str) -> N ; -- singular and plural suffice for most nouns
|
||||||
|
|
||||||
-- In the worst case, four forms are needed.
|
-- In the worst case, four forms are needed.
|
||||||
|
|
||||||
mkN : (museum,museet,museer,museerna : Str) -> N
|
mkN : (museum,museet,museer,museerna : Str) -> N -- worst case for nouns
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- All the functions above work quite as well to form *compound nouns*,
|
-- All the functions above work quite as well to form *compound nouns*,
|
||||||
@@ -105,14 +105,14 @@ oper
|
|||||||
-- with the preposition "av".
|
-- with the preposition "av".
|
||||||
|
|
||||||
mkN2 : overload {
|
mkN2 : overload {
|
||||||
mkN2 : Str -> N2 ;
|
-- mkN2 : Str -> N2 ;
|
||||||
mkN2 : N -> Prep -> N2
|
mkN2 : N -> Prep -> N2 -- e.g. syster - till
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- Three-place relational nouns ("förbindelse från x till y")
|
-- Three-place relational nouns ("förbindelse från x till y")
|
||||||
-- need two prepositions.
|
-- need two prepositions.
|
||||||
|
|
||||||
mkN3 : N -> Prep -> Prep -> N3 ;
|
mkN3 : N -> Prep -> Prep -> N3 ; -- e.g. flyg - från - till
|
||||||
|
|
||||||
|
|
||||||
--3 Relational common noun phrases
|
--3 Relational common noun phrases
|
||||||
@@ -129,12 +129,12 @@ oper
|
|||||||
-- have the default gender utrum.
|
-- have the default gender utrum.
|
||||||
|
|
||||||
mkPN : overload {
|
mkPN : overload {
|
||||||
mkPN : Str -> PN ;
|
mkPN : Str -> PN ; -- default gender utrum
|
||||||
mkPN : Str -> Gender -> PN ;
|
mkPN : Str -> Gender -> PN ; -- set other gender
|
||||||
|
|
||||||
-- In the worst case, the genitive form is irregular.
|
-- In the worst case, the genitive form is irregular.
|
||||||
|
|
||||||
mkPN : (jesus,jesu : Str) -> Gender -> PN
|
mkPN : (jesus,jesu : Str) -> Gender -> PN -- irregular genitive
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -152,24 +152,24 @@ oper
|
|||||||
-- also recognizes the neuter formation "galen-galet" and forms the
|
-- also recognizes the neuter formation "galen-galet" and forms the
|
||||||
-- proper plural and comparison forms "galna-galnare-galnast".
|
-- proper plural and comparison forms "galna-galnare-galnast".
|
||||||
|
|
||||||
mkA : (bred,brett : Str) -> A ;
|
mkA : (bred,brett : Str) -> A ; -- predictable adjective
|
||||||
|
|
||||||
-- Umlaut in comparison forms is
|
-- Umlaut in comparison forms is
|
||||||
|
|
||||||
mkA : (tung,tyngre,tyngst : Str) -> A ;
|
mkA : (tung,tyngre,tyngst : Str) -> A ; -- irregular comparison
|
||||||
|
|
||||||
-- A few adjectives need 5 forms.
|
-- A few adjectives need 5 forms.
|
||||||
mkA : (god,gott,goda,battre,bast : Str) -> A ;
|
mkA : (god,gott,goda,battre,bast : Str) -> A ; -- very irregular
|
||||||
|
|
||||||
-- Hardly any other adjective than "liten" needs the full 7 forms.
|
-- Hardly any other adjective than "liten" needs the full 7 forms.
|
||||||
|
|
||||||
mkA : (liten,litet,lilla,sma,mindre,minst,minsta : Str) -> A
|
mkA : (liten,litet,lilla,sma,mindre,minst,minsta : Str) -> A -- worst case
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
-- Comparison forms may be compound ("mera svensk" - "mest svensk");
|
-- Comparison forms may be compound ("mera svensk" - "mest svensk");
|
||||||
-- this behaviour can be forced on any adjective.
|
-- this behaviour can be forced on any adjective.
|
||||||
|
|
||||||
compoundA : A -> A ;
|
compoundA : A -> A ; -- force comparison by mera - mest
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -178,7 +178,7 @@ oper
|
|||||||
--
|
--
|
||||||
-- Two-place adjectives need a preposition for their second argument.
|
-- Two-place adjectives need a preposition for their second argument.
|
||||||
|
|
||||||
mkA2 : A -> Prep -> A2 ;
|
mkA2 : A -> Prep -> A2 ; -- e.g. delbar - med
|
||||||
|
|
||||||
|
|
||||||
--2 Adverbs
|
--2 Adverbs
|
||||||
@@ -187,12 +187,12 @@ oper
|
|||||||
-- after the verb. Some can be preverbal in subordinate position
|
-- after the verb. Some can be preverbal in subordinate position
|
||||||
-- (e.g. "alltid").
|
-- (e.g. "alltid").
|
||||||
|
|
||||||
mkAdv : Str -> Adv ; -- här
|
mkAdv : Str -> Adv ; -- postverbal, e.g. här
|
||||||
mkAdV : Str -> AdV ; -- alltid
|
mkAdV : Str -> AdV ; -- preverbal, e.g. alltid
|
||||||
|
|
||||||
-- Adverbs modifying adjectives and sentences can also be formed.
|
-- Adverbs modifying adjectives and sentences can also be formed.
|
||||||
|
|
||||||
mkAdA : Str -> AdA ;
|
mkAdA : Str -> AdA ; -- modify adjective, e.g. tämligen
|
||||||
|
|
||||||
--2 Verbs
|
--2 Verbs
|
||||||
--
|
--
|
||||||
@@ -210,19 +210,19 @@ oper
|
|||||||
-- as if they were implicitly suffixed by "r". Moreover, deponent verbs
|
-- as if they were implicitly suffixed by "r". Moreover, deponent verbs
|
||||||
-- are recognized from the final "s" ("hoppas").
|
-- are recognized from the final "s" ("hoppas").
|
||||||
|
|
||||||
mkV : (stämmer : Str) -> V ;
|
mkV : (stämmer : Str) -> V ; -- predictable verb: use present indicative
|
||||||
|
|
||||||
-- Most irregular verbs need just the conventional three forms.
|
-- Most irregular verbs need just the conventional three forms.
|
||||||
|
|
||||||
mkV : (dricka,drack,druckit : Str) -> V ;
|
mkV : (dricka,drack,druckit : Str) -> V ; -- the theme of an irregular verb
|
||||||
|
|
||||||
-- In the worst case, six forms are given.
|
-- In the worst case, six forms are given.
|
||||||
|
|
||||||
mkV : (gå,går,gå,gick,gått,gången : Str) -> V ;
|
mkV : (gå,går,gå,gick,gått,gången : Str) -> V ; -- worst case
|
||||||
|
|
||||||
-- Particle verbs, such as "passa på", are formed by adding a string to a verb.
|
-- Particle verbs, such as "passa på", are formed by adding a string to a verb.
|
||||||
|
|
||||||
mkV : V -> Str -> V
|
mkV : V -> Str -> V -- particle verb, e.g. passa - på
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -232,8 +232,8 @@ oper
|
|||||||
-- reflexive e.g. "ångra sig". Regular deponent verbs are also
|
-- reflexive e.g. "ångra sig". Regular deponent verbs are also
|
||||||
-- handled by $mkV$ and recognized from the ending "s".
|
-- handled by $mkV$ and recognized from the ending "s".
|
||||||
|
|
||||||
depV : V -> V ;
|
depV : V -> V ; -- deponent verb, e.g. andas
|
||||||
reflV : V -> V ;
|
reflV : V -> V ; -- reflexive verb, e.g. ångra sig
|
||||||
|
|
||||||
|
|
||||||
--3 Two-place verbs
|
--3 Two-place verbs
|
||||||
@@ -244,10 +244,10 @@ oper
|
|||||||
-- Notice that, if a particle is needed, it comes from the $V$.
|
-- Notice that, if a particle is needed, it comes from the $V$.
|
||||||
|
|
||||||
mkV2 : overload {
|
mkV2 : overload {
|
||||||
mkV2 : Str -> V2 ;
|
mkV2 : Str -> V2 ; --%
|
||||||
mkV2 : V -> V2 ;
|
mkV2 : V -> V2 ; -- direct transitive
|
||||||
mkV2 : Str -> Prep -> V2 ;
|
mkV2 : Str -> Prep -> V2 ; --%
|
||||||
mkV2 : V -> Prep -> V2
|
mkV2 : V -> Prep -> V2 ; -- preposition for complement
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
|
||||||
@@ -258,10 +258,10 @@ oper
|
|||||||
-- verb (as in $mkV$) with no prepositions.
|
-- verb (as in $mkV$) with no prepositions.
|
||||||
|
|
||||||
mkV3 : overload {
|
mkV3 : overload {
|
||||||
mkV3 : Str -> V3 ;
|
mkV3 : Str -> V3 ; --%
|
||||||
mkV3 : V -> V3 ;
|
mkV3 : V -> V3 ; -- direct ditransitive
|
||||||
mkV3 : V -> Prep -> V3 ;
|
mkV3 : V -> Prep -> V3 ; -- preposition for last argument
|
||||||
mkV3 : V -> Prep -> Prep -> V3
|
mkV3 : V -> Prep -> Prep -> V3 -- prepositions for both complements
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
--3 Other complement patterns
|
--3 Other complement patterns
|
||||||
@@ -269,7 +269,7 @@ oper
|
|||||||
-- Verbs and adjectives can take complements such as sentences,
|
-- Verbs and adjectives can take complements such as sentences,
|
||||||
-- questions, verb phrases, and adjectives.
|
-- questions, verb phrases, and adjectives.
|
||||||
|
|
||||||
mkV0 : V -> V0 ;
|
mkV0 : V -> V0 ; --%
|
||||||
mkVS : V -> VS ;
|
mkVS : V -> VS ;
|
||||||
mkV2S : V -> Prep -> V2S ;
|
mkV2S : V -> Prep -> V2S ;
|
||||||
mkVV : V -> VV ;
|
mkVV : V -> VV ;
|
||||||
@@ -279,16 +279,16 @@ oper
|
|||||||
mkVQ : V -> VQ ;
|
mkVQ : V -> VQ ;
|
||||||
mkV2Q : V -> Prep -> V2Q ;
|
mkV2Q : V -> Prep -> V2Q ;
|
||||||
|
|
||||||
mkAS : A -> AS ;
|
mkAS : A -> AS ; --%
|
||||||
mkA2S : A -> Prep -> A2S ;
|
mkA2S : A -> Prep -> A2S ; --%
|
||||||
mkAV : A -> AV ;
|
mkAV : A -> AV ; --%
|
||||||
mkA2V : A -> Prep -> A2V ;
|
mkA2V : A -> Prep -> A2V ; --%
|
||||||
|
|
||||||
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$.
|
-- Notice: categories $AS, A2S, AV, A2V$ are just $A$.
|
||||||
-- $V0$ is just $V$.
|
-- $V0$ is just $V$.
|
||||||
|
|
||||||
V0 : Type ;
|
V0 : Type ; --%
|
||||||
AS, A2S, AV, A2V : Type ;
|
AS, A2S, AV, A2V : Type ; --%
|
||||||
|
|
||||||
--.
|
--.
|
||||||
--2 Definitions of the paradigms
|
--2 Definitions of the paradigms
|
||||||
|
|||||||
Reference in New Issue
Block a user