-
Notifications
You must be signed in to change notification settings - Fork 3
/
roots-for-pet.tdl
269 lines (217 loc) · 6.18 KB
/
roots-for-pet.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
;;; -*- Mode: tdl; Coding: utf-8; -*-
;;;
;;; Copyright (c) 1994-2018
;;; Dan Flickinger, Rob Malouf, Emily M. Bender
;;; see LICENSE for conditions
;;;
;;; roots.tdl
;;;
; The instances in this file are needed by the parser to know which phrase
; types to accept as successful parses of the full input string.
;; DPF 2016-12-03 - Note that the order of definition is significant for ACE
;; (at least presently), since it checks these root symbols in the order of
;; definition, not based on the order they are listed in the config file.
root_strict := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CAT.HEAD verb_or_conj-s,
PUNCT.RPUNCT basic_clause_punct ],
GENRE edited,
DIALECT us,
ORTH root_orth ].
root_gen := phrase &
[ INFLECTD +,
SYNSEM root_gen_synsem,
GENRE edited,
DIALECT us,
ORTH root_orth ].
root_gen_nofocus := phrase &
[ INFLECTD +,
SYNSEM root_gen_synsem &
[ LOCAL.CONT.ICONS.LIST *nonfocuslist* ],
GENRE edited,
DIALECT us,
ORTH root_orth ].
root_gen_nopass := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL [ CAT.HEAD verb_or_conj-s,
CONT.ICONS 0-dlist ],
PUNCT.RPUNCT basic_clause_punct ],
GENRE edited,
DIALECT us,
ORTH root_orth ].
root_decl := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CONT.HOOK.INDEX.SF prop,
PUNCT.RPUNCT clause_or_pair_or_no_punct ],
GENRE standard,
ORTH root_orth ].
root_question := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CONT.HOOK.INDEX.SF ques,
PUNCT.RPUNCT clause_or_pair_or_no_punct ],
GENRE standard,
DIALECT us,
ORTH root_orth ].
root_command := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CONT.HOOK.INDEX.SF comm,
PUNCT.RPUNCT clause_or_pair_or_no_punct ],
GENRE standard,
DIALECT us,
ORTH root_orth ].
root_informal := phrase &
[ INFLECTD +,
SYNSEM root_synsem,
GENRE standard,
ORTH root_orth ].
root_formal := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CAT.HEAD verb_or_conj-s,
PUNCT.RPUNCT basic_clause_punct ],
GENRE formal,
DIALECT us,
ORTH root_orth ].
root_spoken := phrase &
[ INFLECTD +,
SYNSEM basic_root_synsem &
[ LOCAL [ CAT [ HEAD verb & [ VFORM fin_or_imp,
TAM indic_tam ],
MC + ],
CONJ cnil ],
PUNCT.RPUNCT comma_or_clause_or_pair_or_no_punct ],
GENRE spoken,
ORTH root_orth ].
root_spoken_frag := phrase &
[ INFLECTD +,
SYNSEM basic_root_synsem &
[ LOCAL [ CAT [ HEAD frag & [ TAM indic_tam ],
MC + ],
CONJ cnil_or_lexconj ] ],
GENRE spoken,
ORTH root_orth ].
root_inffrag := sign &
[ SYNSEM root_frag_synsem,
GENRE standard,
ORTH root_orth ].
root_frag := sign &
[ SYNSEM root_frag_synsem &
[ PUNCT.RPUNCT clause_or_no_punct ],
GENRE formal,
DIALECT us,
ORTH root_orth ].
root_robust_frag := sign &
[ SYNSEM root_frag_synsem,
GENRE robust,
ORTH root_orth ].
;; DPF 2016-08-08 - Changed HEAD verb_or_frag to just verb since we also have
;; root_robust_frag. And same for CONJ cnil_or_lexconj => cnil.
root_robust := phrase &
[ INFLECTD +,
SYNSEM root_synsem,
GENRE robust,
ORTH root_orth ].
root_robust_s := phrase &
[ INFLECTD +,
SYNSEM basic_root_synsem &
[ LOCAL [ CAT [ HEAD verb_or_conj-s &
[ MOD *anti_list*,
VFORM fin_or_bse_or_imp ],
VAL.SUBJ *anti_list*,
MC + ],
CONT.HOOK.INDEX.SF #sf,
CONJ cnil ],
PUNCT.RPUNCT comma_or_clause_or_pair_or_no_punct &
[ PSF #sf ] ],
GENRE robust,
ORTH root_orth ].
root_non_idiom := sign &
[ IDIOM - ].
;;; The following four are used for `fragmented' (in the LOGON sense) input
;;; for generator
root_phr := sign &
[ SYNSEM phr_synsem &
[ LOCAL [ CAT [ HEAD [ INV -,
TAM.MOOD indicative,
MINORS.MIN norm_rel ],
VAL [ COMPS < >,
SPR *olist* ] ],
CONJ cnil ],
NONLOC [ SLASH.LIST < >,
REL.LIST < > ],
LEX -,
PUNCT no_punctuation ],
INFLECTD +,
ORTH root_orth ].
root_lex := sign &
[ SYNSEM [ LEX +,
LOCAL [ CAT.HEAD non_frag &
[ AUX na ],
CONJ cnil ],
NONLOC.SLASH.LIST < >,
PUNCT.RPUNCT clause_or_no_punct ],
INFLECTD + ].
; DPF 09-Jan-00 - Removed MSG message from root_conj, to admit eg "or on
; Tuesday"
root_conj := sign &
[ SYNSEM [ LOCAL [ CAT.VAL.COMPS < >,
CONJ lex-conj ],
NONLOC [ SLASH.LIST < >,
REL.LIST < > ],
PUNCT no_punctuation ],
INFLECTD +,
ORTH root_orth ].
root_subord := sign &
[ SYNSEM [ LOCAL [ CAT [ HEAD prep,
VAL.COMPS < > ],
CONJ cnil ],
NONLOC [ SLASH.LIST < >,
REL.LIST < > ],
PUNCT no_punctuation ],
INFLECTD +,
ORTH root_orth ].
#|
root_robust_ques := phrase &
[ INFLECTD +,
SYNSEM basic_root_synsem &
[ LOCAL [ CAT [ HEAD verbal_or_conj-s &
[ VFORM fin,
TAM.MOOD indicative ],
MC + ],
CONT.HOOK.INDEX.SF ques,
CONJ cnil ],
PUNCT.RPUNCT comma_or_clause_or_pair_or_no_punct &
[ PSF prop-or-ques ] ],
GENRE robust,
DIALECT us,
ORTH root_orth ].
|#
root_robust_ques := phrase &
[ INFLECTD +,
SYNSEM basic_root_synsem &
[ LOCAL [ CAT [ HEAD verbal_or_conj-s &
[ VFORM fin,
TAM.MOOD indicative ],
MC + ],
CONT.HOOK.INDEX.SF ques,
CONJ cnil ],
PUNCT.RPUNCT comma_or_pair_or_no_punct &
[ PSF prop-or-ques ] ],
GENRE robust,
DIALECT us,
ORTH root_orth ].
root_bridge := phrase &
[ SYNSEM.LOCAL.CAT.HEAD bridge_head,
INFLECTD - ].
root_paraphrase := phrase &
[ INFLECTD +,
SYNSEM root_synsem &
[ LOCAL.CONT.HOOK.INDEX.SF prop,
PUNCT.RPUNCT clause_or_pair_or_no_punct ],
GENRE paraphrase,
ORTH root_orth ].