1
0
forked from GitHub/gf-core

little fixes to make lib/src 'make Parse8' work again and produce a better than ever 'open text' translator

This commit is contained in:
aarne
2013-12-08 20:36:14 +00:00
parent a91add2bbb
commit e5caac511f
4 changed files with 30 additions and 18 deletions

View File

@@ -57,7 +57,16 @@ concrete VerbFin of Verb = CatFin ** open Prelude, ResFin, StemFin in {
UseCopula = predV vpVerbOlla ;
SlashVV v vp =
SlashVV v vp = {
s = v ;
s2 = \\_,b,a => infVP v.sc b a vp v.vi ;
adv = \\_ => v.p ;
vptyp = vp.vptyp ;
ext = [] ;
c2 = vp.c2
} ;
{-
insertObj
(\\_,b,a => infVP v.sc b a vp v.vi)
(predSV {s = v.s ;
@@ -68,6 +77,7 @@ concrete VerbFin of Verb = CatFin ** open Prelude, ResFin, StemFin in {
h = v.h ; p = v.p
}
) ** {c2 = vp.c2} ; ---- correct ??
-}
SlashV2VNP = StemFin.slashV2VNP ; ---- compilation to pgf takes too long 6/8/2013 hence a simplified version in stemmed/

View File

@@ -507,17 +507,17 @@ oper
---- and in a simplified way for ParseFin (here)
slashV2VNP : (SVerb1 ** {c2 : Compl ; vi : InfForm}) -> (NP ** {isNeg : Bool}) ->
(VP ** {c2 : Compl}) -> (VP ** {c2 : Compl})
= \v, np, vp0 -> let vp = vp2old_vp vp0 ** {c2 = vp0.c2} in
insertObjPre False ---- ignoring np.isNeg
(\fin,b,a -> np.s ! v.c2.c ++ vp.c2.s ++
---- appCompl fin b v.c2 np ++ -- ignoring Acc variation and pre/postposition
(let verb = vp.s ! VIInf v.vi ! Simul ! Pos ! a
in verb.fin ++ verb.inf ++ vp.s2 ! fin ! b ! a ++ vp.adv ! b ++ vp.ext)
---- infVP v.sc b a vp v.vi -- ignoring neg vp's and possessive suffix of inf
)
(predSV v) ** {c2 = vp.c2} ;
(VP ** {c2 : Compl}) -> (VP ** {c2 : Compl}) =
\v, np, vp -> {
s = v ;
s2 = \\fin,b,a => np.s ! v.c2.c ++ vp.c2.s ++ v.s ! SVInf ;
---- infVP v.sc b a vp v.vi ;
-- ignoring Acc variation and pre/postposition and proper inf form
ext = [] ;
adv = \\_ => v.p ;
vptyp = vp.vptyp ; -- ignoring np.isNeg
c2 = vp.c2
} ;
--------------------------------

View File

@@ -5,8 +5,8 @@ concrete ConstructionFre of Construction = CatFre **
lin
hungry_VP = mkVP have_V2 (mkNP (ParadigmsFre.mkN "faim" feminine)) ;
thirsty_VP = mkVP have_V2 (mkNP (ParadigmsFre.mkN "soif" feminine)) ;
hungry_VP = E.ComplCN have_V2 (mkCN (mkN "faim")) ;
thirsty_VP = E.ComplCN have_V2 (mkCN (mkN "soif")) ;
has_age_VP card = mkVP have_V2 (mkNP <lin Card card : Card> L.year_N) ;
have_name_Cl x y = mkCl x (mkV2 (reflV (mkV "appeler"))) y ;
@@ -19,8 +19,8 @@ lin
-- some more things
weather_adjCl ap = mkCl (mkVP (mkVA (mkV I.faire_V2)) (lin AP ap)) ;
is_right_VP = mkVP have_V2 (mkNP (mkN "raison")) ;
is_wrong_VP = mkVP have_V2 (mkNP (mkN "tort")) ;
is_right_VP = E.ComplCN have_V2 (mkCN (mkN "raison")) ;
is_wrong_VP = E.ComplCN have_V2 (mkCN (mkN "tort")) ;
n_units_AP card cn a = mkAP (lin AdA (mkUtt (mkNP <lin Card card : Card> (lin CN cn)))) (lin A a) ;

View File

@@ -10,10 +10,12 @@ lin
has_age_VP card = mkVP (lin AP (mkAP (lin AdA (mkUtt (mkNP <lin Card card : Card> L.year_N))) L.old_A)) ;
have_name_Cl x y = mkCl (lin NP x) (mkV2 I.heißen_V) (lin NP y) ;
married_Cl x y = mkCl (lin NP x) L.married_A2 (lin NP y) | mkCl (mkNP and_Conj (lin NP x) (lin NP y)) (mkA "verheiratet") ;
married_Cl x y = ----mkCl (lin NP x) L.married_A2 (lin NP y) |
mkCl (mkNP and_Conj (lin NP x) (lin NP y)) (mkA "verheiratet") ;
what_name_QCl x = mkQCl how_IAdv (mkCl (lin NP x) I.heißen_V) ;
how_old_QCl x = mkQCl (E.ICompAP (mkAP L.old_A)) (lin NP x) ;
---- how_old_QCl x = mkQCl (E.ICompAP (mkAP L.old_A)) (lin NP x) ; ---- compilation slow
how_old_QCl x = mkQCl (E.IAdvAdv (ParadigmsGer.mkAdv "alt")) (mkCl (lin NP x) G.UseCopula) ; ----
how_far_QCl x = mkQCl (E.IAdvAdv L.far_Adv) (mkCl (mkVP (SyntaxGer.mkAdv to_Prep (lin NP x)))) ;
-- some more things