-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathzhong-lextypes.tdl
3187 lines (2579 loc) · 113 KB
/
zhong-lextypes.tdl
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
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
;;; -*- Mode: TDL; Coding: utf-8 -*-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Lexical Types of the Chinese Languages
;;; created at:
;;; Fri Oct 31 2014
;;; created by Sanghoun Song (SSH) and
;;; Zhenzhen Fan (ZZF)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
animate-lex-item := lex-item &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.PNG.ANIMACY animate ].
human-lex-item := lex-item &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.PNG.ANIMACY human ].
non-human-lex-item := lex-item &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.PNG.ANIMACY non-human ].
inanimate-lex-item := lex-item &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.PNG.ANIMACY inanimate ].
loc-lex-item := lex-item &
[ SYNSEM.LOCAL.CAT.HEAD.LOC + ].
non-loc-lex-item := lex-item &
[ SYNSEM.LOCAL.CAT.HEAD.LOC na-or-- ].
speaker-lex-item := basic-icons-lex-item &
[ SYNSEM.LOCAL.CONT.HOOK [ INDEX #index,
SPEAKER-KEY #index ] ].
non-honorific-hearer-lex-item := basic-icons-lex-item &
"""
[FIXME] This was blocking perfectly nice sentence such as:
你 喜欢 你们 的 外语系 吗 ?
As such I have disabled the honorific/non-honorific system from pronouns.
"""
[ SYNSEM.LOCAL.CONT.HOOK [ INDEX #index,
HEARER-KEY #index ] ].
honorific-hearer-lex-item := one-icons-lex-item &
[ SYNSEM.LOCAL.CONT [ HOOK [ INDEX #index,
SPEAKER-KEY #skey,
HEARER-KEY #index ],
ICONS <! higher & [ IARG1 #index,
IARG2 #skey ] !> ] ].
no-spr-no-spec-lex-item := lex-item &
[ SYNSEM.LOCAL.CAT.VAL [ SPR <>, SPEC <> ] ].
redup-lex-item := lex-item &
[ SYNSEM [ LOCAL [ CONT [ HOOK [ LTOP #ltop,
INDEX #index ],
RELS <! #keyrel, #altkeyrel !>,
HCONS <! !>,
ICONS <! !> ] ],
LKEYS [ KEYREL arg1-relation & event-relation & #keyrel &
[ LBL #ltop,
ARG0 #index ],
ALTKEYREL #altkeyrel & arg1-relation & event-relation &
[ LBL #ltop,
PRED redup_x_rel,
ARG1 #index ] ] ] ].
;;ZZF 20161116, to indicate question words. QUE doesn't work yet, conflicting with basic-head-mod-phrase-simple (non-head QUE 0-dlist) for scopal modifier.
question-item := lex-item &
[ SYNSEM [ LOCAL.CONT.HOOK.INDEX #ind,
NON-LOCAL.QUE <! #ind !> ] ].
;;ZZF 20161128 to indicate non-question words. Matrix has an existing type "zero-arg-nonque", but the name suggests "zero-arg", which may lead to confusion in our usage. Therefore creating a similartype called "nonque-item".
nonque-item := lex-item &
[ SYNSEM.NON-LOCAL.QUE 0-dlist ].
bound-lex-item := lex-item &
[ SYNSEM.BOUND + ].
;;; Lexical types
normal-lex := lex-item &
"""
All normal lex are not selected by the head.
Currently being contrasted with KEYS.KEY = selected_rel.
"""
[SYNSEM.LOCAL.CAT.HEAD.KEYS.KEY norm_rel].
selected-lex := lex-item &
[ SYNSEM [ LOCAL [CAT.HEAD.KEYS.KEY #key,
CONT [ RELS <! !>, HCONS <! !> ] ],
LKEYS.KEYREL.PRED selected_rel & #key,
NON-LOCAL.SLASH 0-dlist ] ].
; selected-lex := lex-item & no-rels-hcons-icons-lex-item &
; """
; Trying to use the no-rels-hcons-icons-lex-item type to check if this solves the problem with FFTB.
; """
; [ SYNSEM [ LOCAL [CAT.HEAD.KEYS.KEY #key,
; CONT [ RELS <! !>, HCONS <! !> ] ],
; LKEYS.KEYREL.PRED selected_rel & #key,
; NON-LOCAL.SLASH 0-dlist ] ].
; [FCB] Do we need to set the ICONs???
; no-hcons-lex-item := lex-item &
; [ SYNSEM.LOCAL.CONT.HCONS <! !> ].
; no-rels-hcons-icons-lex-item := no-hcons-lex-item &
; [ SYNSEM.LOCAL.CONT [ RELS <! !>, ICONS <! !> ] ].
norm-comps1-lex := lex-item &
"""
This type is to ensure that 1st COMPS of normal verbs have normal (non-empty) semantics.
This is necessary to ensure the contrast with separable verbs like 吃饭. Special
lexical entries for verbs like 吃 expect COMPS with the semantic type selected_rel,
such as the special 饭_n_selected_rel.
But in order to prevent normal verbs to also take these selected complements as
their own complements, we must ensure all complements of normal verbs are of
norm_rel.
"""
[ SYNSEM.LOCAL.CAT.VAL.COMPS < [LOCAL.CAT.HEAD.KEYS.KEY norm_rel] > ].
;;; Nouns
arg1-noun-lex := norm-sem-lex-item & basic-icons-lex-item &
[ SYNSEM [ LOCAL.CAT.HEAD noun,
LKEYS.KEYREL noun-arg1-relation ]].
noun-lex := basic-noun-lex & basic-one-arg & no-hcons-lex-item & normal-lex &
"""
This inherits from 'normal-lex' which essentially says that these nouns can't be selected for (e.g. separable verbs);
noun-lex basically says that nouns will only have a specifier as ARG,
and that this specifier's head value is 'det' and it will, itself, be satisfied
concerning any specifier requirements.
[SYNSEM.CLASSIF -] is a new attempt at removing from being a head feature. All nouns will be marked as [CLASSIF -] by default, and this will only be changed to [CLASSIF +] by the mod-head-int rule for classifiers.
"""
[ ARG-ST < #spr >,
SYNSEM [ PAREN -,
PUNCTUATED -,
CLASSIF -,
LOCAL.CAT.VAL [ COMPS < >,
SUBJ < >,
SPR < #spr & synsem &
[ LOCAL.CAT [ HEAD det,
VAL.SPR < > ] ] > ],
NON-LOCAL.SLASH 0-dlist ] ].
; relational-noun-lex := arg1-noun-lex &
; basic-one-arg & ; one arg assumes no SPR but one COMP
; no-hcons-lex-item &
; normal-lex &
; """
; it should introce its own quantifier (check another thing that does this)
; Should be further split into a bound one for 里 and nonbound for 里边
; Maybe not bound COMP optional or not.
; (look into quant-nom-lex for the quant relation, probably an exists_q_rel)
; """
; [ ARG-ST < #comp >,
; SYNSEM [ PAREN -,
; POSTCOMP +,
; PUNCTUATED -,
; LOCAL.CAT.VAL [ COMPS < #comp & synsem &
; [ LOCAL [ CAT [ HEAD noun,
; VAL.SPR < > ],
; CONT.HOOK.INDEX ref-ind & #ind ] ] >,
; SUBJ < >,
; SPR < > ] ,
; NON-LOCAL.SLASH 0-dlist,
; LKEYS.KEYREL.ARG1 #ind ] ].
relational-noun-lex := norm-hook-lex-item &
basic-one-arg & ; one arg assumes no SPR but one COMP
normal-lex & ; i.e. not a selected lexicon
"""
General type for nouns that take a complement (i.e. relational nouns).
The current assumption is that these nouns DO NOT take a specifier (however this is heavily influenced by the fact that only locative relational nouns have been tought about). Another related consequence of this is that it introces its own quantifier. (This could be changed if other types of relational nouns are introduced)
This does not constraint the optionality of the COMP (needs to added further down the hierarchy).
========================
'arg1-noun-lex' inherits from 'norm-sem-lex-item'>>'single-rel-lex-item' that introduces a constraint where there is only a single thing on the RELS list. This is causing problem when we want to add the quantifier directly on the RELS list. The solution for this, is to inherit directly from 'norm-hook-lex-item', which does not put this constraint.
These nouns (and phrases build by them) will get a head feature [LOC +]. This head feature was originally in the grammar but was never used. This feature, however, should be used to create a mal-rule that can create 'prepositional locative phrases' without 在. In written Mandarin, 在 is expected in propositions (with some expections in imperatives/suggestions). Not using 在 makes the sentence overly casual, and should be marked for correction.
The restriction [SORT common-s] on the complement prevents both proper nouns and pronouns to be taken as complements -- which is the desired behavior.
The restriction [COMPS < >] for the relational noun's complement is to future proof: in case there are other relational nouns in the future, we would want them to have their COMPS satisfied (or dropped) before being picked up by another relational noun.
"""
[ ARG-ST < #comp >,
SYNSEM [ PAREN -,
POSTCOMP +,
PUNCTUATED -,
LOCAL [ CAT [ HEAD noun,
VAL [ COMPS < #comp & synsem &
[ LOCAL [ CAT [ HEAD noun,
VAL [ SPR < >,
COMPS < > ] ],
CONT.HOOK.INDEX ref-ind &
#compind ] ] >,
SUBJ < >,
SPR < > ] ],
CONT [ HOOK.INDEX #index,
RELS <! #rel &
[ LBL #larg ],
quant-relation &
[ PRED exist_q_rel,
ARG0 #index,
RSTR #harg ] !>,
HCONS <! qeq &
[ HARG #harg,
LARG #larg ] !> ] ] ,
NON-LOCAL.SLASH 0-dlist,
LKEYS [ KEYREL #rel & [ARG1 #compind] ] ] ].
relational-opt-comp-noun-lex := relational-noun-lex &
[ SYNSEM [ LOCAL [ CAT [ VAL [ COMPS < synsem & [ OPT + ] > ] ],
CONT.HOOK.INDEX.SORT common-s ] ] ].
relational-obl-comp-noun-lex := relational-noun-lex &
[ SYNSEM [ LOCAL [ CAT [ VAL [ COMPS < synsem & [ OPT - ] > ] ],
CONT.HOOK.INDEX.SORT common-s ] ] ].
relational-opt-comp-loc-noun-lex := relational-opt-comp-noun-lex &
"""
This is specifically for locative relational nouns with optional complements.
It introduces the head feature [LOC +], which allows it to go through a pumping rule to become an adjuct.
And it also introduces some contraints on the kind of complements it can take. Currently we want to say that these relational nouns cannot take pronouns or proper nouns (i.e. SORT common-s). And also that it cannot take other nouns that are marked for [LOC +], which would stop sentences like:
<nex> 她 在 网上 上 学习 汉语 。
The problem with the sentence above is that there will be some (few) nouns that are itself marked for [LOC +], and these would not be able to be picked up by other locative relational nouns.
However this would also block certain nonsensical senteces such as:
<nex> 她 在 上边 上边 学习 汉语 。
[FIXME] This is, in principle, not a bit problem, but not necessarily impossible (???)
"""
[ SYNSEM.LOCAL.CAT [ HEAD noun & [LOC +],
VAL [ COMPS < [ LOCAL [ CAT.HEAD noun & [LOC -],
CONT.HOOK.INDEX.SORT common-s ] ] > ] ] ].
relational-obl-comp-loc-noun-lex := relational-obl-comp-noun-lex &
"""
E.g. this is for locative relational nouns with obligatory complements (e.g. 里, 上, 右), that need to take a complement and can't be used by themselves.
It introduces the head feature [LOC +], which allows it to go through a pumping rule to become an adjuct.
And it also introduces some contraints on the kind of complements it can take. Currently we want to say that these relational nouns cannot take pronouns or proper nouns (i.e. SORT common-s). And also that it cannot take other nouns that are marked for [LOC +], which would stop sentences like:
<nex> 她 在 网上 上 学习 汉语 。
The problem with the sentence above is that there will be some (few) nouns that are itself marked for [LOC +], and these would not be able to be picked up by other locative relational nouns.
However this would also block certain nonsensical senteces such as:
<nex> 她 在 上边 上边 学习 汉语 。
[FIXME] This is, in principle, not a bit problem, but not necessarily impossible (???)
"""
[ SYNSEM.LOCAL.CAT [ HEAD noun & [LOC +],
VAL [ COMPS < [ LOCAL [ CAT.HEAD noun & [LOC -],
CONT.HOOK.INDEX.SORT common-s ] ] > ] ] ].
common-noun-lex := noun-lex &
"""
"""
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.SORT common-s ].
nonloc-common-noun-lex := common-noun-lex &
non-loc-lex-item
"""
Inheriting from 'non-loc-lex-item' (i.e. [LOC na-or--]) ensures that a NP headed by 'common-noun-lex' can't be pumped into a locative adjunct.
""".
count-noun-lex := nonloc-common-noun-lex &
[ SYNSEM [ BARE -,
LOCAL.CONT.HOOK.INDEX.SPECI + ] ].
mass-noun-lex := nonloc-common-noun-lex &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.SPECI - ].
basic-time-noun-lex := basic-one-arg &
basic-icons-lex-item &
non-loc-lex-item &
"""
This NONSUBJ feature is used to block certain classes of nouns from becoming subjects.
The 'SORT time-s' should allow these nouns to be selected for some constructions.
FCB: we can change NONSUBJ to bool and check if the ambiguity shoot up, if it's too bad we might want to say instead that most (99%) of the verbs don't accept a time-s subject. but ADJ-predicates do, and 是 also does.
Testing removing NONSUBJ as a restriction. This was blocking sentences like:
<ex> 一月 是 我 最 喜欢 的 月份 。
Or
<ex> 昨天 很 热 。
from parsing or from parsing with adequate semantics.
This does not rule out the possibility of blocking certain types of subjects
in major classes of verbs (due to semantic oddity). this can use SORT on SUBJ.
Inheriting from 'non-loc-lex-item' (i.e. [LOC na-or--]) ensures that a NP headed by 'common-noun-lex' can't be pumped into a locative adjunct.
"""
[ SYNSEM [ PAREN -,
PUNCTUATED -,
LOCAL [ CAT [ HEAD noun,
VAL.SUBJ < > ],
; VAL.SUBJ < >,
; NONSUBJ + ],
CONT [ HOOK.INDEX.SORT time-s,
RELS.LIST.FIRST #keyrel ] ],
NON-LOCAL.SLASH 0-dlist,
LKEYS.KEYREL #keyrel ] ].
norm-time-noun-lex := basic-time-noun-lex & norm-sem-lex-item & no-hcons-lex-item
"""
This level exists to differentiate between time-noun-lex and bound-time-noun-lex.
So there must be a reason for norm-sem-lex-item & no-hcons-lex-item [FIXME] find
out what that is.
""".
time-noun-lex := norm-time-noun-lex &
"""
For example, for entries like: 'day'
"""
[ ARG-ST < #spr >,
SYNSEM [ LOCAL.CAT.VAL [ SPR < #spr &
synsem &
[ LOCAL.CAT [ HEAD det,
VAL.SPR < > ] ] >,
COMPS < > ] ] ].
bound-time-noun-lex := basic-time-noun-lex &
"""
Maybe only for: 'o'clock' and 'minute'
"""
[ SYNSEM.LOCAL [ CAT.VAL [ SPR < anti-synsem & [ OPT - ] >,
COMPS < > ],
CONT [ HOOK [ LTOP #ltop,
INDEX #index ],
RELS <! [ LBL #ltop,
ARG0 #index ] !>,
HCONS <! !> ] ] ].
proper-name-lex := quant-pronproper-lex & zero-arg-nonque &
"""
This type introduces named_rel and proper_q_rel in named entities.
<ex> 张三 哭 了
One could select this by saying it's a named relation;
"""
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.SORT pronproper-s,
SYNSEM.LKEYS.KEYREL named-relation,
SYNSEM.LKEYS.ALTKEYREL.PRED proper_q_rel].
loc-name-lex := proper-name-lex & loc-lex-item & non-human-lex-item
"""
SSH 2014-09-11: Locative Proper Names (e.g. 北京).
我 要 去 北京: I would like to go to Beijing.
*我 要 去 李四 / 我 要 去 李四 的 家
""".
nonloc-name-lex := proper-name-lex & non-loc-lex-item.
human-name-lex := nonloc-name-lex & human-lex-item.
surname-lex := human-name-lex
"""
For Surnames. Usually one character long.
""".
quant-nom-lex := norm-hook-lex-item & zero-arg-nonslash & zero-arg-nonrel &
"""
SSH 2014-11-13: pronouns introduce a quant-relation.
Pronouns don't have NON-LOCAL.SLASH and REL.
Pronouns are not of SORT 'pronproper-s' (pronoun or proper name).
"""
[ SYNSEM [ PAREN -,
PUNCTUATED -,
LOCAL [ CAT [ HEAD noun,
VAL [ COMPS < >,
SUBJ < >,
SPR < > ] ],
CONT [ HOOK.INDEX #index,
RELS <! #rel &
[ LBL #larg ],
#quant &
[ ARG0 #index,
RSTR #harg ] !>,
HCONS <! qeq &
[ HARG #harg,
LARG #larg ] !> ] ],
LKEYS.KEYREL noun-relation & #rel,
LKEYS.ALTKEYREL quant-relation & #quant ] ].
quant-pronproper-lex := quant-nom-lex &
"""
things ther are eitehr pronouns or proper nouns inhertit from this
and get the right SORT
"""
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.SORT pronproper-s ].
;; SSH 2014-11-13: pronouns introduce a quant-relation.
basic-pronoun-lex := quant-pronproper-lex &
"""
Pronouns don't have NON-LOCAL.SLASH and REL
"""
[ SYNSEM.LKEYS.KEYREL.PRED pron_rel ].
personal-pronoun-lex := basic-pronoun-lex & zero-arg-nonque & non-loc-lex-item &
[ SYNSEM.LKEYS.ALTKEYREL.PRED pronoun_q_rel ].
super-wh-pronoun := quant-pronproper-lex &
"""
This type is the super-type of many different interrogative pronouns.
One important distinction is that some of these should not be able to be pumped into place adjucts (but some should, e.g. 哪儿, 哪里).
It is very likely that, in the future, 什么_n_q would be removed from this cat (to become an adjectival question word), but the problem will remain with 谁, 哪, etc.
"""
[SYNSEM [ LOCAL.CONT [ HOOK [ INDEX #index & [ PNG.PERNUM 3rd ],
ICONS-KEY #icons,
CLAUSE-KEY #clause ],
ICONS <! semantic-focus & #icons &
[ IARG1 #clause,
IARG2 #index ] !> ],
NON-LOCAL.QUE <! #index !>,
LKEYS.ALTKEYREL.PRED which_q_rel ] ].
wh-pronoun := quant-pronproper-lex &
"""
This is the subtype for generic, it is assumed that it CANNOT be pumped to a place adjunct.
[LOC -] blocking these from being pumped into place locatives, without the use of a preposition or locative noun.
"""
[ SYNSEM.LOCAL.CAT.HEAD.LOC - ].
loc-wh-pronoun := super-wh-pronoun &
"""
This type is for locative interrogative pronouns, such as 哪里 and 哪儿.
[LOC +] allowing these to be pumped into place locatives, without the use of a preposition or locative noun.
"""
[ SYNSEM.LOCAL.CAT.HEAD.LOC + ].
loc-pronoun-lex := basic-pronoun-lex & zero-arg-nonque & loc-lex-item.
; [ SYNSEM.LKEYS.ALTKEYREL.PRED pronoun_q_rel ].
quant-noun-lex := quant-nom-lex & basic-icons-lex-item &
"""
SSH 2014-11-13: 大家 (everyone), etc.
generic_n_rel can be further specified as one of these in the lexical entry:
zhong.tdl:146:thing_n_rel := generic_n_rel.
zhong.tdl:147:place_n_rel := generic_n_rel.
zhong.tdl:148:person_n_rel := generic_n_rel.
zhong.tdl:149:time_n_rel := generic_n_rel
"""
[ SYNSEM [ LOCAL.CONT.RELS <! relation,
#altkeyrel !>,
LKEYS [ KEYREL.PRED generic_n_rel,
ALTKEYREL #altkeyrel ] ] ].
quant-common-noun-lex := quant-noun-lex &
[ SYNSEM.LOCAL.CONT.HOOK.INDEX.SORT common-s ].
nominalizer-lex := lex-item &
[ ARG-ST < #spr >,
SYNSEM [ PAREN -,
PUNCTUATED -,
LOCAL [ CAT [ HEAD noun,
VAL [ COMPS < >,
SUBJ < >,
SPR < #spr &
[ LOCAL [ CAT [ HEAD +vjp & [ MOD < > ],
VAL [ SUBJ olist,
SPR olist,
COMPS < > ] ],
CONT.HOOK [ LTOP #spltop,
INDEX.SF prop ] ] ],
anti-synsem > ] ],
CONT [ HOOK [ LTOP #ltop,
INDEX #index & [ SORT nontime-s ] ],
RELS <! relation & #keyrel &
[ LBL #ltop,
ARG0 #index ] !>,
HCONS <! !>,
ICONS <! !> ] ],
NON-LOCAL [ SLASH 0-dlist,
REL 0-dlist,
QUE 0-dlist ],
LKEYS.KEYREL #keyrel &
[ ARG0.PNG.PERNUM 3rd,
ARG1 #spltop ] ] ].
; Partitive determiner
partitive-lex := basic-one-arg & no-icons-lex-item &
[ ARG-ST < #comp >,
SYNSEM [ PAREN -,
PUNCTUATED -,
LOCAL
[ CAT [ HEAD noun,
VAL [ COMPS < #comp &
[ LOCAL [ CAT [ HEAD adj &
[ MOD < [ LOCAL.CONT.HOOK.INDEX
#index ] > ],
VAL [ SUBJ < [ ] >,
COMPS < > ] ],
CONT.HOOK.LTOP #larg ],
NON-LOCAL.SLASH 0-dlist ] >,
SUBJ < >,
SPR < > ] ],
CONT [ HOOK.INDEX #index & [ SORT nontime-s ],
RELS <! quant-relation & #keyrel &
[ ARG0 #index,
RSTR #harg ],
#altkeyrel & relation &
[ LBL #larg,
PRED generic_n_rel,
ARG0 #index ] !>,
HCONS <! qeq &
[ HARG #harg,
LARG #larg ] !> ] ],
NON-LOCAL.SLASH 0-dlist,
LKEYS.KEYREL #keyrel,
LKEYS.ALTKEYREL #altkeyrel] ].
;;; Verbs
; head :+
+vj :+
"""
Even though the features that are defined here seem best only used by verbs (i.e. head :+ ), doing this eliminates many parses (although many were problem incorrect to start with).
One weird example seems to be the use of 的.
厚厚 的 地毯
"""
[ AUX bool,
COP bool,
FORM form ].
;; SSH 2014-12-09 adj -> +vj
;; SSH 2014-12-19 +vj -> +vjr
+vjr :+
[ PRD bool ].
verb-lex := lex-item &
"""
VAL.SPR is not set to empty < > to allow some verbs to take degree specifiers
"""
[ SYNSEM [ PAREN -,
PUNCTUATED -,
LOCAL.CAT.HEAD verb & [ PRED-KEY #pred ],
LKEYS.KEYREL.PRED #pred ] ].
main-verb-lex := verb-lex & basic-verb-lex & tentative-lex-dtr &
[ SYNSEM.LOCAL [ CAT [ HEAD.AUX -,
VAL.SUBJ < #subj > ],
CONT.HOOK.XARG #xarg ],
ARG-ST.FIRST #subj &
[ LOCAL [ CAT.VAL [ SPR < >,
COMPS < > ],
CONT.HOOK.INDEX #xarg ] ] ].
verb-spr-item := lex-item &
"""
These are verbs that can take degree specifiers (mental activities and states).
<ex>他 很 喜欢 狗 。
FIXME: Why isn't this inheriting from verb-lex instead of lex-item?
"""
[ SYNSEM.LOCAL.CAT.VAL.SPR < [ LOCAL.CAT [ HEAD adv,
VAL.SPEC < [ LOCAL.CAT.HEAD verb ] > ] ] > ].
verb-no-spr-item := lex-item &
"""
These are verbs that can't take degree specifiers (i.e., most of the verbs).
<nex>他 很 买 狗 。
FIXME: Why isn't this inheriting from verb-lex instead of lex-item?
"""
[ SYNSEM.LOCAL.CAT.VAL.SPR < > ].
aux-lex := verb-lex &
[ SYNSEM.LOCAL.CAT.HEAD.AUX + ].
;; SSH 2014-09-03: ICONS in 谁 的 狗 叫 了
;; Because Chinese employs classifiers, and sometimes the classifiers
;; convey focus, CLAUSE-KEY should be used, instead of merely
;; ICONS-KEY.CLAUSE.
intransitive-lex-item :+
[ ARG-ST < [ LOCAL.CONT.HOOK.CLAUSE-KEY #clause ] >,
SYNSEM.LOCAL.CONT.HOOK.CLAUSE-KEY #clause ].
intransitive-verb-lex := main-verb-lex & intransitive-lex-item & aspect-rule-dtr &
[ SYNSEM.LOCAL.CAT.VAL.COMPS < >,
ARG-ST.FIRST.LOCAL.CAT.HEAD noun ].
transitive-super-lex-item := basic-two-arg-no-hcons & basic-icons-lex-item &
"""
This is the parent of both normal transitive lex items and separable transive lex item.
This is to allow sep-verbs not to have an ARG 2 while taking a complement.
It says: they as all in the same clause. (clause-key is the same).
"""
[ ARG-ST < [ LOCAL.CONT.HOOK.CLAUSE-KEY #clause ],
[ LOCAL.CONT.HOOK.CLAUSE-KEY #clause ] >,
SYNSEM [ LOCAL.CONT.HOOK.CLAUSE-KEY #clause ] ].
transitive-lex-item := transitive-super-lex-item &
"""
This was redefined from the original Matrix type to allow sentential subjects.
In normal transitive lexical items (verbs) the ARG2 is coindexed with the second
thing of the Argument Structure.
This split (from 'transitive-sep-lex-item'), also allows us to make another distinction: normal transitive-lex-items will require a COMP that is [BOUND -], and transitive-sep-lex-items will require a COMP that is [BOUND +]. This restriction will no longer be included as part of head-comp rule.
"""
[ ARG-ST < synsem, [ BOUND -,
LOCAL.CONT.HOOK [ INDEX ref-ind & #ind2 ] ] >,
SYNSEM [ LKEYS.KEYREL.ARG2 #ind2 ] ].
transitive-sep-lex-item := transitive-super-lex-item &
"""
In the case of separable transitive lexical items (i.e. sep-verbs), there won't be a ARG2 in the semantics, even though it will be linked by a head-comp rule.
This split (from 'transitive-lex-item'), also allows us to make another distinction: normal transitive-lex-items will require a COMP that is [BOUND -], and transitive-sep-lex-items will require a COMP that is [BOUND +]. This restriction will no longer be included as part of head-comp rule.
"""
[ ARG-ST < synsem, [ BOUND +,
LOCAL.CONT.HOOK [ INDEX event ] ] > ].
transitive-verb-lex := main-verb-lex & transitive-lex-item & aspect-rule-dtr &
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp >,
LKEYS.KEYREL.ARG1 #index ],
ARG-ST < [ LOCAL [ CAT.HEAD noun,
CONT.HOOK.INDEX #index ] ],
#comp &
[ LOCAL.CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ] ] > ].
cp-subj-verb-lex := main-verb-lex & transitive-lex-item & aspect-rule-dtr & verb-no-spr-item &
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp >,
LKEYS.KEYREL.ARG1 #ltop ],
ARG-ST < [ LOCAL [ CAT [ HEAD +vjp,
VAL [ SUBJ < >,
COMPS < > ] ],
CONT.HOOK.LTOP #ltop ] ],
#comp &
[ LOCAL.CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ] ] > ].
;; SSH 2014-09-08: added [MC +] to block overgeneration
;; 张三 知道 下 过 雨
;; ZZF FB LMC 2016-2-24 expand to adj predicate, and SPR of comp to be olist instead of < >
;; FIXME: we need to put in HCON later
s-comp-verb-lex := main-verb-lex & basic-two-arg-no-hcons & basic-icons-lex-item & aspect-rule-dtr &
[ SYNSEM [ LOCAL [ CAT.VAL.COMPS < #comp >],
LKEYS.KEYREL[ARG1 #ind,
ARG2 #ltop]],
ARG-ST < [ LOCAL [ CAT.HEAD noun,
CONT.HOOK.INDEX #ind]],
#comp &
[ LOCAL [ CAT [ MC +,
VAL [ SUBJ <>,
SPR olist,
COMPS < > ],
HEAD +vj ],
CONT.HOOK.LTOP #ltop],
OPT -]> ].
v_s-comp-lex := s-comp-verb-lex & verb-no-spr-item.
v_s-comp-spr-lex := s-comp-verb-lex & verb-spr-item.
;vp-comp-verb-lex := main-verb-lex & basic-two-arg-no-hcons & basic-icons-lex-item & aspect-rule-dtr &
vp-comp-verb-lex := main-verb-lex & basic-two-arg & basic-icons-lex-item & aspect-rule-dtr &
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp >,
LKEYS.KEYREL [ ARG1 #ind ] ],
ARG-ST < [ LOCAL[ CAT.HEAD noun,
CONT.HOOK.INDEX #ind ] ],
#comp &
[ LOCAL[ CAT [ VAL [ SUBJ < [] >,
SPR < >,
COMPS < > ],
HEAD verb ] ],
OPT - ] > ].
vp-comp-verb-seq-lex := vp-comp-verb-lex &
[ SYNSEM.LOCAL [ CAT.VAL.COMPS < [ LOCAL [ CAT.MC na-or--,
CONT.HOOK.XARG #xarg ] ] >,
CONT.HOOK.XARG #xarg ] ].
np-xp-comp-verb-lex := main-verb-lex & basic-three-arg & basic-icons-lex-item & verb-no-spr-item &
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp1, #comp2 >,
LKEYS.KEYREL [ ARG1 #ind,
ARG2 #ind2 ] ],
ARG-ST < [ LOCAL [ CAT [ HEAD noun,
VAL.SPR < > ],
CONT.HOOK.INDEX #ind ] ],
#comp1 &
[ LOCAL [ CAT [ HEAD noun,
VAL.SPR < > ],
CONT.HOOK.INDEX #ind2 ] ],
#comp2 &
[ LOCAL [ CAT [ VAL [ SUBJ < unexpressed >,
COMPS < > ],
HEAD +vj ] ],
OPT - ]> ].
np-vp-comp-verb-lex := np-xp-comp-verb-lex &
"""
The [OPT -] for the first complement predicts that these verbs can never drop
this first complement (although the second one is acceptable).
"""
[ SYNSEM.LOCAL.CAT.VAL.COMPS < [ OPT - ], [ LOCAL.CAT.HEAD verb ] > ].
; `wipe the table clean'
np-ap-comp-ba-verb-lex := np-xp-comp-verb-lex &
[ SYNSEM.LOCAL.CAT.VAL.COMPS < gap, [ LOCAL.CAT.HEAD adj ] > ].
np-ap-comp-verb-lex := np-xp-comp-verb-lex &
"""
Verb with two complements. The first is headed by a noun, and the second is headed by an adjective.
e.g. 'I consider him old'
"""
[ SYNSEM.LOCAL.CAT.VAL.COMPS < [ ], [ LOCAL.CAT.HEAD adj ] > ].
np-vp-comp-verb-oeq-lex := np-vp-comp-verb-lex &
[ SYNSEM.LOCAL.CAT.VAL.COMPS < [ LOCAL.CONT.HOOK.INDEX #xarg ],
[ LOCAL [ CAT.MC na-or--,
CONT.HOOK.XARG #xarg ] ] > ].
;; SSH 2014-12-08: na-or-- is added
;; 张三 答应 李四 去 北京 。
;; ZZF 2016-12-5: renamed it to be "seq" instead of "anomeq"
np-vp-comp-verb-seq-lex := np-vp-comp-verb-lex &
[ SYNSEM.LOCAL.CAT.VAL [ SUBJ < [ LOCAL.CONT.HOOK.INDEX #xarg ] >,
COMPS < [ ],
[ LOCAL [ CAT.MC na-or--,
CONT.HOOK.XARG #xarg ] ] > ] ].
;; ZZF 2017-08-01 我 问 他 你 在 忙 吗 ?
v_np-s_lex := main-verb-lex & basic-three-arg & basic-icons-lex-item & verb-no-spr-item &
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp1, #comp2 >,
LKEYS.KEYREL [ ARG1 #ind,
ARG2 #ind2 ] ],
ARG-ST < [ LOCAL [ CAT [ HEAD noun,
VAL.SPR < > ],
CONT.HOOK.INDEX #ind ] ],
#comp1 &
[ LOCAL [ CAT [ HEAD noun,
VAL.SPR < > ],
CONT.HOOK.INDEX #ind2 ] ],
#comp2 &
[ LOCAL [ CAT [ VAL [ SUBJ < >,
COMPS < > ],
HEAD +vj ] ],
OPT - ]> ].
;; SSH 2014-09-08: The following sentence should be analyzed as being
;; [ASPECT perfective].
;; 张三 把 香烟 递 给 了 李四
np-vp-comp-verb-light-lex := np-vp-comp-verb-lex & basic-three-arg-no-hcons &
"""
"""
[ SYNSEM.LOCAL [ CAT.VAL.COMPS < [ ],
[ LOCAL.CONT.HOOK [ XARG #event,
INDEX.E.ASPECT #aspect ] ] >,
CONT.HOOK.INDEX #event & [ E.ASPECT #aspect ] ] ].
pp-s-comp-verb-lex := main-verb-lex & basic-three-arg-no-hcons & basic-icons-lex-item &
aspect-rule-dtr & verb-no-spr-item &
"""
These verbs take two COMPs: a PP (optional?) + and a non-optional S.
There is currently only 1 verb under this type: 保证
I assume this was to be able to deal withsentences like:
<ex> 我 向 你 保证 学习 。
(I promise you to study)
But this is still not parsing as predicted. [向 你] cannot be a COMP.
[FIXME][FCB] Maybe this has to do with being a pre-head COMP?
"""
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp1, #comp2 >,
LKEYS.KEYREL [ ARG1 #ind,
ARG2 #ind2,
ARG3 #ltop ] ],
ARG-ST < [ LOCAL [ CAT.HEAD noun,
CONT.HOOK.INDEX #ind ] ],
#comp1 &
[ LOCAL [ CAT.HEAD adp,
CONT.HOOK.INDEX #ind2 ] ],
#comp2 &
[ LOCAL [ CAT [ VAL [SUBJ < >,
SPR < >,
COMPS < > ],
HEAD verb ],
CONT.HOOK.LTOP #ltop],
OPT -]> ].
;;2016-2-16 ZZF OPT + to allow objects to be optional ::testing
super-ditrans-verb-lex := main-verb-lex & aspect-rule-dtr & verb-no-spr-item &
"""
Currently all ditransitive verbs are [BOUND -], blocking the complements of separable verbs from unifying.
"""
[ SYNSEM.LOCAL.CAT.VAL.COMPS < #comp1, #comp2>,
ARG-ST < [ LOCAL.CAT.HEAD noun ],
#comp1 &
[ BOUND -,
LOCAL.CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ],
OPT +] ,
#comp2 &
[ BOUND -,
LOCAL.CAT [ VAL [ SPR < >,
COMPS < > ] ],
OPT +] >].
ditrans-verb-lex := ditransitive-lex-item & super-ditrans-verb-lex
"""
"""
.
ditransitive-lex-item-2 := basic-three-arg & basic-icons-lex-item &
"""
This seems to be an alternative for ditransitive verbs where the second complement is QEQ'ed with the verb's ltop. It was exclusively used for 'ditrans-pp-verb-lex', which specifies the
[FIXME] I believe this is generating some weird parses.
"""
[ ARG-ST < [ LOCAL.CONT.HOOK [ INDEX ref-ind & #ind1,
ICONS-KEY.IARG1 #clause ] ],
[ LOCAL.CONT.HOOK [ INDEX ref-ind & #ind2,
ICONS-KEY.IARG1 #clause ] ],
[ LOCAL.CONT.HOOK [ INDEX event,
LTOP #ltop,
XARG #ind2,
ICONS-KEY.IARG1 #clause ] ] >,
SYNSEM [ LKEYS.KEYREL [ ARG1 #ind1,
ARG2 #ind2,
ARG3 #ind3 ],
LOCAL.CONT [ HOOK.CLAUSE-KEY #clause,
HCONS <! qeq & [ HARG #ind3,
LARG #ltop ] !> ] ] ].
ditrans-pp-verb-lex := ditransitive-lex-item-2 & super-ditrans-verb-lex &
"""
"""
[ ARG-ST < [], [], [ LOCAL.CAT.HEAD adp & [ PFORM gei-or-xiang ] ] > ].
ditrans-preverbal-pp-verb-lex := ditrans-pp-verb-lex &
"""
"""
[ ARG-ST < [], [], [ LOCAL.CAT [ HEAD [ PFORM xiang ] ] ] > ].
trans-loc-verb-lex := basic-three-arg-no-hcons & main-verb-lex & basic-icons-lex-item &
aspect-rule-dtr & verb-no-spr-item &
"""
This type is for ditransitive verbs where the second complement is a PP (unconstrained).
The original name was 'trans-loc-verb-lex' but this seems a bit
"""
[ SYNSEM [ LOCAL.CAT.VAL.COMPS < #comp1,#comp2>,
LKEYS.KEYREL [ ARG1 #arg1,
ARG2 #arg2,
ARG3 #arg3 ] ],
ARG-ST < [ LOCAL [ CAT.HEAD noun,
CONT.HOOK.INDEX #arg1 ] ],
#comp1 &
[ LOCAL [ CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ],
CONT.HOOK.INDEX #arg2 ],
OPT - ],
#comp2 &
[ LOCAL [ CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD prep],
CONT.HOOK.INDEX #arg3 ],
OPT -] > ].
v_intrans-verb-lex := intransitive-verb-lex & verb-no-spr-item
"""
""".
v_intrans-verb-spr-lex := intransitive-verb-lex & verb-spr-item
"""
""".
v_trans-verb-lex := transitive-verb-lex & verb-no-spr-item
"""
""".
v_trans-verb-spr-lex := transitive-verb-lex & verb-spr-item
"""
""".
;; WWJ 2015-02-08: Changed HEAD of #subj to be noun and postp (instead of just postp)
;; to account for cases like 学校 有 狗 or 盒子 有 蛋糕, where the PP might be omitted
;; EXISTV has been added as a property to block 不 有
v_exist-lex := basic-three-arg &
verb-lex &
basic-verb-lex &
basic-icons-lex-item &
verb-no-spr-item &
"""
Currently this is being used for sentences like: 学校 里 有 狗 叫
[FIXME] It's not clear whether this is absolutely necessary, or why is it not picking up examples such as 有 一 个 人 来 我 的 家 。
The subject is now requesting for [ HEAD noun & [LOC +] ] to account for the new way relational locative nouns are being handled.
[FIXME] Should double check if 在 phrases are not equally acceptable. However, it is also plausible to assume that in the presence of a 在 phrase, it should be handled as an adjunct. This option (which would require discharging the subject), however, is being blocked by [EXISTV +] -- which is being blocked by 'opt-subj-declarative-phrase'.
"""
[ SYNSEM [ POSTCOMP -,
LOCAL [ CAT.VAL [ SUBJ < #subj >,
COMPS < #comp1, #comp2 > ],
CAT.HEAD [ EXISTV +,
AUX -,
COP - ],
CONT [ HOOK [ LTOP #lbl,
INDEX #event ],
RELS <! #keyrel !>,
HCONS <! qeq & [ HARG #arg2,
LARG #vltop ] !> ] ],
LKEYS.KEYREL #keyrel &
[ LBL #lbl,
ARG0 #event,
ARG1 #arg1,
ARG2 #arg2,
ARG3 #arg3 ] ],
ARG-ST
< #subj &
[ OPT +, ; allowing optional but not slashed subjects
LOCAL [ CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun & [LOC +] ],
CONT.HOOK.INDEX #arg3 ],
NON-LOCAL.SLASH 0-dlist ],
#comp1 &
[ LOCAL [ CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ],
CONT.HOOK.INDEX #arg1 ] ],
#comp2 &
[ LOCAL [ CAT [ VAL [ SUBJ < [ ] >,
SPR < >,
COMPS < > ],
HEAD verb ],
CONT.HOOK [ LTOP #vltop,
XARG #arg1 ] ] ] > ].
v_light-verb-lexeme := main-verb-lex & basic-two-arg-no-hcons &
basic-icons-lex-item & verb-no-spr-item &
[ SYNSEM [ LOCAL [ CAT.VAL.COMPS < #comp >,
CONT.HOOK.XARG #arg1 ],
LKEYS.KEYREL [ ARG1 #arg1,
ARG2 #ind2 ] ],
ARG-ST < unexpressed & [ LOCAL.CAT.HEAD noun ],
#comp &
[ LOCAL [ CAT [ VAL [ SPR < >,
COMPS < > ],
HEAD noun ],
CONT.HOOK.INDEX ref-ind & #ind2 ] ] > ].