1
0
forked from GitHub/gf-rgl
Files
gf-rgl/tests/german/object-order.gfs
Hans Leiss d9928919e3 (Ger) Readjusting accdatV3 in ParadigmsGer and modifying V3-examples in LexiconGer instead
ParadigmsGer had two constructions of verbs v:V3 with dat- and acc-object nps,

(1)      mkV3 : V -> V3 = \v -> mkV3 v accPrep datPrep ;
(2)  accdatV3 : V -> V3 = \v -> mkV3 v datPrep accPrep ;  -- (no prepositions)

In a previous patch, I had replaced (accdatV3 v) to (mkV3 v accPrep datPrep), as the
name suggested. (This actually was the meaning of accdatV3 in gf-3.2, which had only
a non-overloaded mkV3 : V -> Prep -> Prep -> V3.)

The reason for having two constructions for dat+acc-verbs in Ger seems to be *Eng*:
for English, ditransitive V3-verbs are defined by

(2')     mkV3 : V -> V3 = \v -> mkV3 v noPrep noPrep ;

like "to give sb sth", where the indirect argument comes first (c2=indir), the direct
second (c3=dir), corresponding to c2=datPrep, c3=accPrep in Ger; apparently, this was
meant by the comment (no prepositions) in (2). Other V3-verbs in Eng are defined by

(1')    mkV3 : V -> Prep -> V3 = \v,p -> mkV3 v noPrep p ;

like "to give sth to sb", so that (c2=dir), (c3=indir-with preposition),
corresponding to c2=acc,c3=dat in Ger, i.e. (1).

In order to get trees with equal meaning in Ger and Eng, the direct and indirect
arguments of corresponding verbs must match. Therefore, some V3-verbs in Ger have to
be defined using (1), others using (2), although they syntactically behave similar.

This patch therefore reinstalls (1) and (2), and changes the V3 in LexiconGer to:

  give_V3 = accdatV3 Irreg.geben_V ; -- c2=datPrep, c3=accPrep, to fit
             -- to Eng ditransitive: give sb(indir) sth(dir) (no preposition)

  sell_V3 = mkV3 (no_geV (regV "verkaufen")) ;    -- Eng: mkV3 v noPrep toPrep
  send_V3 = mkV3 (regV "schicken") ; -- Ger mkV3 v = Ger: mkV3 v accPrep datPrep
2019-07-08 16:09:17 +02:00

31 lines
2.0 KiB
Plaintext

--# Use gf --run < obj-order.gfs or gf> eh object-order.gfs
? echo "loading TestLangGer.gf and TestLangEng.gf ..."
i TestLangGer.gf TestLangEng.gf
-- Remark: examples in examples.eng.txt need only LangEng,LangGer
? echo "parsing from examples.eng and writing trees to examples.eng.new:"
rf -file=examples.eng.txt -lines | p -lang=Eng | l -lang="Eng,Ger" -treebank | wf -file=examples.eng.new
? echo "diff examples.eng.out examples.eng.new"
? diff examples.eng.out examples.eng.new
? echo "parsing from examples.eng and writing source and translation to examples.eng2ger.new:"
rf -file=examples.eng.txt -lines | p -lang=Eng | l -lang="Eng,Ger" | wf -file=examples.eng2ger.new
? echo "diff examples.eng2ger.out examples.eng2ger.new"
? diff examples.eng2ger.out examples.eng2ger.new
? echo "extracting positive, negative and dubious examples from examples.txt ..."
? grep accept examples.txt | sed s/\ --\ [\*a-zA-Z\(\)\ \.\:\,\;\<\>\\_0-4\\+\\?\\-]*// | cpif examples.pos.txt
? grep reject examples.txt | sed s/\ --\ [\*a-zA-Z\(\)\ \.\:\,\;\<\>\\_0-4\\+\\?\\-]*// | cpif examples.neg.txt
? grep dubious examples.txt | sed s/\ --\ [\*a-zA-Z\(\)\ \.\:\,\;\<\>\\_0-4\\+\\?\\-]*// | cpif examples.dub.txt
? echo "parsing negative examples ...; storing trees in examples.neg.new ..."
rf -lines -file="examples.neg.txt" | p -lang=Ger | l -treebank -lang="Ger,Eng" | wf -file="examples.neg.new"
? echo "diff examples.neg.out examples.neg.new:"
? diff examples.neg.out examples.neg.new
? echo "parsing dubious examples ...; storing trees in examples.dub.new ..."
rf -lines -file="examples.dub.txt" | p -lang=Ger | l -treebank -lang="Ger,Eng" | wf -file="examples.dub.new"
? echo "diff examples.dub.out examples.dub.new:"
? diff examples.dub.out examples.dub.new
? echo "parsing positive examples ...; storing trees in examples.pos.new ..."
rf -lines -file="examples.pos.txt" | p -lang=Ger | l -treebank -lang="Ger,Eng" | wf -file="examples.pos.new"
? echo "diff examples.pos.out examples.pos.new:"
? diff examples.pos.out examples.pos.new