-
Notifications
You must be signed in to change notification settings - Fork 0
/
formgram-psg.tex
665 lines (531 loc) · 16.2 KB
/
formgram-psg.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
%% -*- coding:utf-8 -*-
\section{Phrase structure grammars and \xbar Theory}
\subtitle{Phrase structure grammars}
\huberlintitlepage[22pt]
\outline{
\begin{itemize}
\item Introduction and basic terms
\item \alert{Phrase structure grammar and \xbar Theory}
\item Government \& Binding (GB)
\item {Generalized Phrase Structure Grammar (GPSG)}
\item {Feature descriptions, feature structures and models}
\item Lexical Functional Grammar (LFG)
%\item PATR
\item Categorial Grammar (CG)
\item Head-Driven Phrase Structure Grammar (HPSG)
%\item Konstruktionsgrammatik (CxG)
\item Tree Adjoning Grammar (TAG)
\end{itemize}
%\tableofcontents
}
\subsection{Symbols and rewrite rules}
\frame{
\frametitle{Reading material}
Please read \citew[Section~2.1--2.2]{MuellerGT-Eng}.
}
\frame[shrink=2]{
\frametitle{Phrase structure}
\smallframe
\hfill%
\begin{tabular}{@{}l@{\hspace{1cm}}l@{}}
\scalebox{.85}{%
\begin{forest}
sm edges
[S
[NP [er;he] ]
[NP
[Det [das;the] ]
[N [Buch;book] ]
]
[NP
[Det [dem;the] ]
[N [Mann;mann] ]
]
[V [gibt;gives] ]
]
\end{forest}} &
\scalebox{.85}{%
\begin{forest}
sm edges
[V
[NP [er;he] ]
[V
[NP
[Det [das;the] ]
[N [Buch;book] ] ]
[V
[NP
[Det [dem;the] ]
[N [Mann;man] ] ]
[V [gibt;gives] ] ] ] ]
\end{forest}}
\\
\\[-0.4ex]
\begin{tabular}{@{~}l@{ }l@{}}
NP & $\to$ Det, N \\
S & $\to$ NP, NP, NP, V \\
\end{tabular} & \begin{tabular}{@{~}l@{ }l@{}}
NP & $\to$ Det, N \\
V & $\to$ NP, V\\
\end{tabular}\\
\end{tabular}
\hfill\mbox{}
\medskip
What we are after is phrase structure rules! Trees are just their visualization.\\
%
\pause%
%
Sometimes bracketed strings are used to safe space:\\
{}[\sub{S} [\sub{NP} er] [\sub{NP} [\sub{Det} das] [\sub{N} Buch]] [\sub{NP} [\sub{Det} dem] [\sub{N} Mann]] [\sub{V} gibt]]
\handoutspace
}
\subsubsection{Terminology}
\frame{
\frametitle{Node}
\vfill
\psset{xunit=5mm,yunit=5mm,nodesep=8pt}
\hfill
\begin{pspicture}(0,0)(14,7.4)
\rput(3,7){\rnode{xp}{A}}
\rput(1,4){\rnode{up}{B}}\rput(5,4){\rnode{xs1}{C}}
\rput(5,1){\rnode{vp}{D}}
\psset{angleA=-90,angleB=90,arm=0pt}
\ncdiag{xp}{up}\ncdiag{xp}{xs1}%
\ncdiag{xs1}{vp}\ncdiag{xs1}{xs2}%
\ncdiag{xs2}{wp}\ncdiag{xs2}{x}%
\ncdiag{wp}{yp}\ncdiag{wp}{ws}%
\pause
%\mode<beamer>{
\psset{linecolor=red}%radius=1em}
%}
%\pscircle(3,7){2ex}
\cnode[linewidth=1.5pt](3,7){1.7ex}{nodeA}
\pscircle[linewidth=1.5pt](1,4){1.7ex}\cnode[linewidth=1.5pt](5,4){1.7ex}{nodeC}
\cnode[linewidth=1.5pt](5,1){1.7ex}{nodeD}
\pause
\rput[l](8,7){\rnode{verz}{branching}}
\rput[l](8,6){\rnode{nverz}{n}on-branching}
%\psset{angleA=180,angleB=0,arm=0pt,arrows=->}
\only<3>{
\ncline{->}{verz}{nodeA}
}
\pause
\only<4>{
\ncline{->}{nverz}{nodeC}
}
%\psgrid
\end{pspicture}
\hfill\hfill\mbox{}
\vfill
}
\frame{
\frametitle{Mother, daughter and sister}
\vfill
\psset{xunit=5mm,yunit=5mm,nodesep=8pt}
\hspace{1cm}%
%\begin{tabular}{@{}l@{\hspace{1cm}}l@{}}
\begin{pspicture}(0,0)(7.4,7.4)
\rput(3,7){\rnode{xp}{A}}
\rput(1,4){\rnode{up}{B}}\rput(5,4){\rnode{xs1}{C}}
\rput(5,1){\rnode{vp}{D}}
\psset{angleA=-90,angleB=90,arm=0pt}
\ncdiag{xp}{up}\ncdiag{xp}{xs1}%
\ncdiag{xs1}{vp}\ncdiag{xs1}{xs2}%
\ncdiag{xs2}{wp}\ncdiag{xs2}{x}%
\ncdiag{wp}{yp}\ncdiag{wp}{ws}%
%\psgrid
\end{pspicture}
\hspace{1cm}\raisebox{3cm}{\begin{tabular}[t]{@{}l@{}}
A is mother of B and C\\
C is mother of D\\
B is sister of C\\
\end{tabular}}
Relationships like in family trees
\vfill
}
\frame{
\frametitle{Dominance}
\vfill
\psset{xunit=5mm,yunit=5mm,nodesep=8pt}
\hspace{1cm}
\begin{pspicture}(0,0)(7.4,7.4)
\rput(3,7){\rnode{a}{A}}
\rput(1,4){\rnode{b}{B}}\rput(5,4){\rnode{c}{C}}
\rput(5,1){\rnode{d}{D}}
\psset{angleA=-90,angleB=90,arm=0pt}
\alt<2>{
\mode<beamer>{
\psset{linecolor=red}
}
\ncdiag{->}{a}{b}\ncdiag{->}{a}{c}
}{
\ncdiag{a}{b}\ncdiag{a}{c}%
}
\alt<2,4>{
\mode<beamer>{
\psset{linecolor=red}
}
\ncdiag{->}{c}{d}
}{
\ncdiag{c}{d}
}
%\psgrid
\end{pspicture}
\hspace{1cm}\raisebox{3cm}{\begin{tabular}[t]{@{}l@{}}
A dominates \only<2->{B, C and D}\\
\only<3->{C dominates} \only<4->{D} \\
\end{tabular}}
\bigskip
A \alert{dominates} B if and only if A is higher in the tree and \\
if there is a line from A to B that exclusively goes downwards.
\pause\pause\pause
\vfill
}
\frame{
\frametitle{Immediate dominance}
\psset{xunit=5mm,yunit=5mm,nodesep=8pt}
\hspace{1cm}
\begin{pspicture}(0,0)(7.4,7.4)
\rput(3,7){\rnode{a}{A}}
\rput(1,4){\rnode{b}{B}}\rput(5,4){\rnode{c}{C}}
\rput(5,1){\rnode{d}{D}}
\psset{angleA=-90,angleB=90,arm=0pt}
\alt<2>{
{\mode<beamer>{
\psset{linecolor=red}
}
\ncdiag{->}{a}{b}\ncdiag{->}{a}{c}}
}{\ncdiag{a}{b}\ncdiag{a}{c}}
\alt<4>{
\mode<beamer>{
\psset{linecolor=red}
}
\ncdiag{->}{c}{d}
}{\ncdiag{c}{d}}
%\psgrid
\end{pspicture}
\hspace{1cm}\raisebox{3cm}{\begin{tabular}[t]{@{}l@{}}
A immedeately dominates \only<2->{B and C}\\
\only<3->{C immedeately domminates} \only<4->{D} \\
\end{tabular}}
\bigskip
A immedeately dominates B if and only if \\
A dominates B and there is no node C between A and B.
\pause\pause\pause
}
\frame{
\frametitle{Precedence}
\begin{description}[<+->]
\item[Precedence]~\\ A precedes B, if A is located to the left of B in a tree and\\
none of these nodes dominates the other one.
\item[Immediate precedence]~\\ A precedes B and there is no element C between A and B.
\end{description}
}
\subsubsection{A sample grammar}
\frame[shrink=8]{
\frametitle{Example derivation assuming flat structures}
\vfill
\bigskip
\parskip0pt
\begin{tabular}[t]{@{}l@{ }l}
\highlight{NP}<5,8> & \highlight{$\to$ Det N}<5,8>\\
\highlight{S}<10> & \highlight{$\to$ NP NP NP V}<10>
\end{tabular}\hspace{2cm}%
\begin{tabular}[t]{@{}l@{ }l}
\highlight{NP}<2> & \highlight{$\to$ er}<2>\\
\highlight{Det}<3> & \highlight{$\to$ das}<3>\\
\highlight{Det}<6> & \highlight{$\to$ dem}<6>\\
\end{tabular}\hspace{8mm}
\begin{tabular}[t]{@{}l@{ }l}
\highlight{N}<4> & \highlight{$\to$ Buch}<4>\\
\highlight{N}<7> & \highlight{$\to$ Kind}<7>\\
\highlight{V}<9> & \highlight{$\to$ gibt}<9>\\
\end{tabular}
\vfill
\begin{tabular}{@{}llllll@{\hspace{2.5cm}}l}
er & das & Buch & dem & Kind & gibt \pause\\
\highlight{NP}<2> & das & Buch & dem & Kind & gibt & \only<handout>{NP $\to$ er} \pause\\
NP & \highlight{Det}<3> & Buch & dem & Kind & gibt & \only<handout>{Det $\to$ das} \pause\\
NP & Det & \highlight{N}<4> & dem & Kind & gibt & \only<handout>{N $\to$ Buch} \pause\\
NP & & \highlight{NP}<5> & dem & Kind & gibt & \only<handout>{NP $\to$ Det N}\pause\\
NP & & NP & \highlight{Det}<6> & Kind & gibt & \only<handout>{Det $\to$ dem} \pause\\
NP & & NP & Det & \highlight{N}<7> & gibt & \only<handout>{N $\to$ Kind} \pause\\
NP & & NP & & \highlight{NP}<8> & gibt & \only<handout>{NP $\to$ Det N}\pause\\
NP & & NP & & NP & \highlight{V}<9> & \only<handout>{V $\to$ gibt} \pause\\
& & & & & \highlight{S}<10> & \only<handout>{S $\to$ NP NP NP V}\\
\end{tabular}
\vfill
}
\begin{frame}[fragile]
\frametitle{Do try this at home!}
You can actually play with such grammars.
\begin{itemize}
\item Go to \url{https://swish.swi-prolog.org/}.
\item Click ``Program''.
\item Enter:
\begin{verbatim}
s --> np, v, np, np.
np --> det, n.
np --> [er].
det --> [das].
det --> [dem].
n --> [buch].
n --> [kind].
v --> [gibt].
\end{verbatim}
\item Type in the following into the right lower box: \texttt{s([er,gibt,das,buch,dem,kind],[]).}
\item If there appears a ``true'' in the box above this box, celebrate.
\end{itemize}
\end{frame}
\frame{
\frametitle{A generative grammar}
\begin{itemize}
\item The grammar you just entered can generate sentences.
\pause
\item You may test which sentences it generates by typing in:
\texttt{s([X],[]),print(X),nl,fail.}
\pause
\item \texttt{s([X],[])} asks Prolog to come up with an X that is an ``s''.
\pause
\item \texttt{print(X),nl} prints the X and a newline and
\pause
\item \texttt{fail} tells Prolog that we are not happy and that it should try again.
\pause
\item It keeps trying till there are no further solutions and then fails.
\pause
\item Some grammars generate infinitely many Xes. So this process would never end (unless the
computer runs out of memory \ldots).
\end{itemize}
}
\frame{
\frametitle{Sentences described by the grammar}
\begin{itemize}
\item The grammar is not precise enough (it \emph{overgenerates}):\\
\begin{tabular}{@{}l@{ }l}
NP & $\to$ Det N\\
S & $\to$ NP NP NP V\\
\end{tabular}
\eal
\ex[]{
\gll er das Buch dem Kind gibt\\
he the book the child gives\\
}
\ex[*]{
\gll ich das Buch dem Kind gibt\\
I the book the child give\\
\pause\\
(Subject verb agreement \emph{ich}, \emph{gibt})}
\pause
\ex[*]{
\gll er das Buch das Kind gibt\\
he the book the child gives\\\pause\\
(case requirement of the verb, \emph{gibt} requires dative)
}
\pause
\ex[*]{
\gll er den Buch dem Kind gibt\\
he the book the child gives\\
\pause\\
(determinator noun agreement \emph{den}, \emph{Buch})
}
\zl
\end{itemize}
}
% geht hier nicht, weil das von anderen eingebunden wird
%\exewidth{\exnrfont(12)}
\frame{
\frametitle{Subject verb agreement (I)}
\begin{itemize}
\item Agreement in person (1, 2, 3) and number (sg, pl)
\eal
\ex Ich schlafe. (1, sg)
\ex Du schläfst. (2, sg)
\ex Er schläft. (3, sg)
\ex Wir schlafen. (1, pl)
\ex Ihr schlaft. (2, pl)
\ex Sie schlafen. (3,pl)
\zl
\item How can we express this in rules?
\end{itemize}
}
\frame{
\frametitle{Subject verb agreement (II)}
\begin{itemize}
\item We make the symbols more informative.\\
Instead of S $\to$ NP NP NP V we use:\\[2ex]
\begin{tabular}{@{}l@{ }l}
S & $\to$ NP\_1\_sg NP NP V\_1\_sg\\
S & $\to$ NP\_2\_sg NP NP V\_2\_sg\\
S & $\to$ NP\_3\_sg NP NP V\_3\_sg\\
S & $\to$ NP\_1\_pl NP NP V\_1\_pl\\
S & $\to$ NP\_2\_pl NP NP V\_2\_pl\\
S & $\to$ NP\_3\_pl NP NP V\_3\_pl\\
\end{tabular}
\item six symbols for nominal phrases, six for verbs
\item six rules instead of one
\end{itemize}
}
\frame{
\frametitle{Case assignment by the verb}
\begin{itemize}
\item Case must be part of the symbols used in the rules:
\begin{tabular}{@{}l@{ }l}
S & $\to$ NP\_1\_sg\_nom NP\_dat NP\_acc V\_1\_sg\_ditransitiv\\
S & $\to$ NP\_2\_sg\_nom NP\_dat NP\_acc V\_2\_sg\_ditransitiv\\
S & $\to$ NP\_3\_sg\_nom NP\_dat NP\_acc V\_3\_sg\_ditransitiv\\
S & $\to$ NP\_1\_pl\_nom NP\_dat NP\_acc V\_1\_pl\_ditransitiv\\
S & $\to$ NP\_2\_pl\_nom NP\_dat NP\_acc V\_2\_pl\_ditransitiv\\
S & $\to$ NP\_3\_pl\_nom NP\_dat NP\_acc V\_3\_pl\_ditransitiv\\
\end{tabular}
\item 3 * 2 * 4 = 24 new categories for NPs in total
\item 3 * 2 * x categories for V (x = number of attested valence patterns)
\end{itemize}
}
\frame[shrink=15]{
\frametitle{Determinator noun agreement}
\begin{itemize}
\item There is agreement in gender (fem, mas, neu), number (sg, pl) and\\
case (nom, gen, dat, acc)
\eal
\ex der Mann `the man', die Frau `the woman', das Kind `the child' (gender)
\ex das Buch `the book', die Bücher `the books' (number)
\ex des Buches `the.\GEN book.\GEN', dem Buch `the.\DAT book' (case)
\zl
\pause
\item instead of NP $\to$ Det N we have\\[2ex]
\resizebox{\linewidth}{!}{
\begin{tabular}{@{}l@{ }l@{\hspace{4mm}}l@{ }l}
NP\_3\_sg\_nom & $\to$ Det\_fem\_sg\_nom N\_fem\_sg\_nom & NP\_gen & $\to$ Det\_fem\_sg\_gen N\_fem\_sg\_gen\\
NP\_3\_sg\_nom & $\to$ Det\_mas\_sg\_nom N\_mas\_sg\_nom & NP\_gen & $\to$ Det\_mas\_sg\_gen N\_mas\_sg\_gen\\
NP\_3\_sg\_nom & $\to$ Det\_neu\_sg\_nom N\_neu\_sg\_nom & NP\_gen & $\to$ Det\_neu\_sg\_gen N\_neu\_sg\_gen\\
NP\_3\_pl\_nom & $\to$ Det\_fem\_pl\_nom N\_fem\_pl\_nom & NP\_gen & $\to$ Det\_fem\_pl\_gen N\_fem\_pl\_gen\\
NP\_3\_pl\_nom & $\to$ Det\_mas\_pl\_nom N\_mas\_pl\_nom & NP\_gen & $\to$ Det\_mas\_pl\_gen N\_mas\_pl\_gen\\
NP\_3\_pl\_nom & $\to$ Det\_neu\_pl\_nom N\_neu\_pl\_nom & NP\_gen & $\to$ Det\_neu\_pl\_gen N\_neu\_pl\_gen\\[2mm]
\ldots & \hspaceThis{$\to$} dative & \ldots & \hspaceThis{$\to$} accusative\\[2mm]
\end{tabular}
}
\item 24 symbols for determiners, 24 symbols for nouns
\item 24 rules instead of one
\end{itemize}
}
\subsection{Expanding PSG with features}
\frame{
\frametitle{Problems of simple phrase structure grammars}
\begin{itemize}
\item Gernalisations are not captured.
\item neither in rules nor in category symbols
\begin{itemize}
\item Where can an NP or an NP\_nom be placed?\\
The only question we can ask is: Where can I put an NP\_3\_sg\_nom?
\item Commonalities between rules are not obvous.
\end{itemize}
\pause
\item Solution: features with values and identity of values\\
Category symbol: NP feature: Per, Num, Cas, \ldots\\
We get rules like the following:\\
\begin{tabular}{@{}l@{ }l}
NP(3,sg,nom) & $\to$ Det(fem,sg,nom) N(fem,sg,nom)\\
NP(3,sg,nom) & $\to$ Det(mas,sg,nom) N(mas,sg,nom)\\
\end{tabular}
\end{itemize}
}
\frame{
\frametitle{Features and rule schemata (I)}
\begin{itemize}
\item Rules with specific values can be generalized to rule schemata:
\medskip
\begin{tabular}{@{}l@{ }l@{ }l}
NP(\blau<3>{3},\blau<2>{Num},\blau<2>{Cas}) & $\to$ & Det(\gruen<2>{Gen},\blau<2>{Num},\blau<2>{Cas}) N(\gruen<2>{Gen},\blau<2>{Num},\blau<2>{Cas})\\
\end{tabular}
\pause
\item Actual Gen, Num and Cas values do not matter\\
as long as they are identical.
\pause
\item The value of the person feature (first slot in NP(3,Num,Cas))\\
is fixed by the rule: 3.
\end{itemize}
}
\frame{
\frametitle{Features and rule schemata (II)}
\begin{itemize}
\item Rules with specific values can be generalized into rule schemata:
\medskip
\begin{tabular}{@{}l@{ }l@{ }l}
NP({3},{Num},{Cas}) & $\to$ & Det(Gen,{Num},{Cas}) N(Gen,{Num},{Cas})\\
S & $\to$ & NP(\blau<1>{Per1},\blau<1>{Num1},\blau<3>{nom})\\
& & NP(Per2,Num2,\blau<3>{dat})\\
& & NP(Per3,Num3,\blau<3>{acc})\\
& & V(\blau<1>{Per1},\blau<1>{Num1})\\\\
\end{tabular}
\item Per1 and Num1 value of verb and subject are identical.
\pause
\item The values of other NPs do not matter.\\
(Notation for irrelevant values: `\_')
\pause
\item Case values of the NPs are fixed in the second rule.
\end{itemize}
}
%% Kommt dann in Theorie anders, deshalb hier raus
%% \frame{
%% \small
%% \frametitle{Bündelung von Merkmalen}
%% \begin{itemize}
%% \item Kann es Regeln geben, in denen nur der Per-Wert oder nur der Num-Wert identisch sein muß?\\[2ex]
%% \begin{tabular}{@{}l@{ }l@{ }l}
%% S & $\to$ & NP(Per1,Num1,nom)\\
%% & & NP(Per2,Num2,dat)\\
%% & & NP(Per3,Num3,akk)\\
%% & & V(Per1,Num1)\\\\
%% \end{tabular}
%% \pause
%% \item Gruppierung von Information $\to$ stärkere Generalisierung, stärkere Aussage\\[2ex]
%% \begin{tabular}{@{}l@{ }l@{ }l}
%% S & $\to$ & NP(Agr1,nom)\\
%% & & NP(Agr2,dat)\\
%% & & NP(Agr3,akk)\\
%% & & V(Agr1)\\\\
%% \end{tabular}
%% wobei Agr ein Merkmal mit komplexen Wert ist: \zb agr(1,sg)
%% \end{itemize}
%% }
\subsubsection{Homework}
\frame[shrink=15]{
\frametitle{Homework}
\begin{enumerate}
\item Write a phrase structure grammar that can analyze at least the sentences in (\mex{1})
but excludes the sequences in (\mex{2}).
\eal
\ex[]{
\gll Der Mann hilft dem Kind.\\
the man helps the child\\
}
\ex[]{
\gll Er gibt ihr das Buch.\\
he gives her the book\\
}
\ex[]{
\gll Er wartet auf ein Wunder.\\
he waits for a miracle\\
}
% \ex[]{
% Er wartet neben dem Bushäuschen auf ein Wunder.
% }
\zl
\eal
\ex[*]{
\gll Der Mann hilft er.\\
the man helps he\\
}
\ex[*]{
\gll Er gibt ihr den Buch.\\
he gives her the book\\
}
\zl
The result should be one grammar for all grammatical sentences, not one for each sentence.
You may use Prolog to make sure your grammar actually works:
\url{https://swish.swi-prolog.org}
See \url{https://en.wikipedia.org/wiki/Definite_clause_grammar} for the syntax of Definite
Clause Grammars.
\end{enumerate}
}
% <!-- Local IspellDict: en_US-w_accents -->