From ff0a5c418c1c99a8923db0a4a246d4e8b1900e8f Mon Sep 17 00:00:00 2001 From: aarne Date: Tue, 13 Sep 2005 10:56:44 +0000 Subject: [PATCH] finnish rel --- lib/resource/finnish/BasicFin.gf | 2 +- lib/resource/finnish/ClauseFin.gf | 24 +++++++++++++++++++++++- lib/resource/finnish/SyntaxFin.gf | 23 +++++++++++++++++++++++ 3 files changed, 47 insertions(+), 2 deletions(-) diff --git a/lib/resource/finnish/BasicFin.gf b/lib/resource/finnish/BasicFin.gf index f4d4a798a..41a4bea98 100644 --- a/lib/resource/finnish/BasicFin.gf +++ b/lib/resource/finnish/BasicFin.gf @@ -94,7 +94,7 @@ lin harbour_N = nKukko "satama" "sataman" "satamia" ; hate_V2 = dirV2 (regV "vihata") ; hat_N = nLukko "hattu" ; - have_V2 = dirV2 (caseV adessive vOlla) ; + have_V2 = caseV2 (caseV adessive vOlla) nominative ; hear_V2 = dirV2 (regV "kuulla") ; hill_N = nLukko "kukkula" ; hope_VS = mkVS (regV "toivoa") ; diff --git a/lib/resource/finnish/ClauseFin.gf b/lib/resource/finnish/ClauseFin.gf index f4c5fb81c..b04777209 100644 --- a/lib/resource/finnish/ClauseFin.gf +++ b/lib/resource/finnish/ClauseFin.gf @@ -77,6 +77,12 @@ concrete ClauseFin of Clause = CategoriesFin ** SPredAdv subj adv = sats2clause (mkSatsCopula subj adv.s) ; + + QPredV np v = + sats2quest (mkSats (intNounPhrase np) v) ; + QPredV2 np v y = + sats2quest (mkSatsObject (intNounPhrase np) v y) ; + -------- {- QPredV np v = @@ -153,10 +159,24 @@ concrete ClauseFin of Clause = CategoriesFin ** sats2quest (mkSatsCopula (intNounPhrase subj) adv.s) ; QPredProgVP np vp = sats2quest (progressiveSats (intNounPhrase np) vp) ; +-} ------ gender and number of Adj + RPredV np v = + sats2rel (mkSatsRel np v) ; + RPredV2 np v y = + sats2rel (mkSatsObjectRel np v y) ; + RPredAP subj adj = + sats2rel (\num -> mkSatsCopulaRel subj (complAdjPhrase num adj) num) ; + RPredCN subj cn = + sats2rel (\num -> mkSatsCopulaRel subj (complCommNoun num cn) num) ; + RPredNP subj np = + sats2rel (mkSatsCopulaRel subj (np.s ! NPCase Nom)) ; + RPredAdv subj adv = + sats2rel (mkSatsCopulaRel subj adv.s) ; + +{- IPredV a v = sats2verbPhrase a (mkSats pronImpers v) ; IPredV2 a v y = @@ -235,6 +255,8 @@ concrete ClauseFin of Clause = CategoriesFin ** -} + + {- -- Use VPs diff --git a/lib/resource/finnish/SyntaxFin.gf b/lib/resource/finnish/SyntaxFin.gf index d87bc5623..9f2a436d0 100644 --- a/lib/resource/finnish/SyntaxFin.gf +++ b/lib/resource/finnish/SyntaxFin.gf @@ -595,6 +595,20 @@ oper -} ---- + +-- This is for questions with $IP$, thus with normal word order and no "ko". + + sats2quest : Sats -> QuestClause = \sats -> + {s = \\bsf => sats.s ! } ; + +-- This is a nice and natural hack with higher-order functions, for $ClauseFin$. + + sats2rel : (Number -> Sats) -> RelClause = \fsats -> + {s = \\b,sf,n => (fsats n).s ! } ; + + mkSatsRel : RelPron -> Verb1 -> Number -> Sats = \rel,verb,n -> + mkSats (relNounPhrase n rel) verb ; + mkSats : NounPhrase -> Verb1 -> Sats = \subj,verb -> {s = \\stbsf => let @@ -679,9 +693,14 @@ oper -} mkSatsObject : NounPhrase -> TransVerb -> NounPhrase -> Sats = \subj,verb,obj -> insertObject (mkSats subj verb) verb.c verb.s3 verb.p obj ; + mkSatsObjectRel : RelPron -> TransVerb -> NounPhrase -> Number -> Sats = + \subj,verb,obj,n -> + insertObject (mkSatsRel subj verb n) verb.c verb.s3 verb.p obj ; mkSatsCopula : NounPhrase -> Str -> Sats = \subj,comp -> insertComplement (mkSats subj (vNom verbOlla)) comp ; + mkSatsCopulaRel : RelPron -> Str -> Number -> Sats = \subj,comp,n -> + insertComplement (mkSatsRel subj (vNom verbOlla) n) comp ; insertObject : Sats -> ComplCase -> Str -> Bool -> NounPhrase -> Sats = \sats, c, prep, pos, obj -> {s = @@ -1206,6 +1225,10 @@ oper IntPron : Type = {s : NPForm => Str ; n : Number} ; +-- Thus it is simple to make $IP $ into $NP$ (used as auxiliary in predication). + + intNounPhrase : IntPron -> NounPhrase = \ip -> ip ** {p = NP3} ; + -- In analogy with relative pronouns, we have a rule for applying a function -- to a relative pronoun to create a new one.