;;; -*- Mode: TDL; Coding: utf-8 -*- ;;; HAG (Hausa Grammar) ;;; Author: Berthold Crysmann ;;; 2009 ;;; Rule types for lexical rules and syntax rules output-token-type := word-or-lexrule. b-word-or-irule := word-or-lexrule. b-word := b-word-or-irule & word. ccont-1ep-rule := phrase-or-lexrule & [STEM [FROM #from, TO #to], C-CONT.RELS.LIST < [CFROM #from, CTO #to], ... >]. ccont-2ep-rule := ccont-1ep-rule & [STEM [FROM #from, TO #to], C-CONT.RELS.LIST < [], [CFROM #from, CTO #to], ... >]. ccont-3ep-rule := ccont-2ep-rule & [STEM [FROM #from, TO #to], C-CONT.RELS.LIST < [], [], [CFROM #from, CTO #to], ... >]. robust-spelling-irule := add-only-no-ccont-rule & lexeme-to-lexeme-rule & inflecting-lex-rule & no-prefix-lex-rule & same-supra-lex-rule & nocoord & [MORPH #m, ROBUST +, DTR lex-item & [MORPH #m] ]. ;; was SUPRA supra_noreent lexeme-to-word-rule := same-local-lex-rule & same-modified-lex-rule & same-light-lex-rule & same-non-local-lex-rule & [MORPH #m, INFLECTED infl-word , SUPRA supra_reent, C-CONT [RELS , HCONS ], DTR.MORPH #m]. inher-lkeys-lex-rule := lex-rule & [SYNSEM.LKEYS #lk, DTR.SYNSEM.LKEYS #lk]. ;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Valence alternations ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Stage 1: slashed vs. unslashed realisation can-res-lex-rule := constant-lex-rule & nocoord & same-supra-lex-rule & same-local-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & no-ccont-lex-rule & i-can-res-lex-rule & [MORPH #m, DTR.MORPH #m]. canon-do-lex-rule := can-res-lex-rule & [SYNSEM #ss & [LOCAL.CAT [HEAD.VFORM non-fin, VAL.COMPS canon-val-list]], DTR.SYNSEM #ss]. non-canon-do-lex-rule := can-res-lex-rule & [SYNSEM [LOCAL.CAT [HEAD.VFORM non-fin, VAL.COMPS < slashed . canon-val-list > ]]]. canon-subj-lex-rule := can-res-lex-rule & [SYNSEM #ss & [LOCAL.CAT [HEAD verb & [VFORM fin], VAL.SUBJ canon-val-list]], DTR.SYNSEM #ss]. non-canon-subj-lex-rule := can-res-lex-rule & [SYNSEM [LOCAL.CAT [HEAD verb & [VFORM fin], VAL.SUBJ < slashed > ]]]. ; canon-canon-lex-rule := canon-do-lex-rule & ; canon-subj-lex-rule. ; canon-noncanon-lex-rule := non-canon-do-lex-rule & ; canon-subj-lex-rule. ; noncanon-noncanon-lex-rule := non-canon-do-lex-rule & ; non-canon-subj-lex-rule. ; noncanon-canon-lex-rule := canon-do-lex-rule & ; non-canon-subj-lex-rule. ;;; Null realisation: null-pron-lex-rule := inher-lkeys-lex-rule & const-ltol-rule & same-cont-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & same-ctxt-lex-rule & same-modified-lex-rule & same-head-lex-rule & same-supra-lex-rule & same-mclass-lex-rule & no-prefix-lex-rule & [INFLECTED [FRAME na-or--, CAN-RES na-or-+], MORPH #m & [DERIVED bool], SYNSEM [BOUND -, LOCAL.CAT.VAL [SPR #spr, SPEC #spec]], DTR [MORPH #m, SYNSEM.LOCAL.CAT.VAL [SPR #spr, SPEC #spec]]]. null-pron-do-lex-rule := null-pron-lex-rule & [C-CONT [RELS #r, HCONS #h], SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, COMPS #comps], DTR.SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, COMPS < pronominal-synsem & [OPT +, LOCAL [CAT.HEAD noun, CONT [HOOK.INDEX [PNG.PN 3, SORT non-human], RELS #r, HCONS #h]]] . #comps>]]. null-pron-subj-lex-rule := null-pron-lex-rule & [C-CONT [RELS #r, HCONS #h], SYNSEM.LOCAL.CAT [HEAD verb & [VFORM fin], VAL [SUBJ <>, COMPS #c]], DTR [INFLECTED [CAN-RES +], SYNSEM.LOCAL.CAT.VAL [SUBJ < pronominal-synsem & [OPT +, LOCAL [CAT.HEAD noun, CONT [RELS #r, HCONS #h]]] >, COMPS #c]]]. extraction-lex-rule := inher-lkeys-lex-rule & const-ltol-rule & val-change-only-lex-rule & same-supra-lex-rule & same-mclass-lex-rule. comp-extraction-lex-rule := extraction-lex-rule & [INFLECTED [CAN-RES na-or-+, FRAME na-or--, NUM-GEND #ng & na-or-+], MORPH #m & [DERIVED bool ], SYNSEM [LOCAL [CAT [VAL [SUBJ #subj]]] ], DTR [INFLECTED [NUM-GEND #ng], MORPH #m, SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, COMPS frame-b-c-val-list ]]]. ;;; DO Complement extraction (pre-inflection) comp-extra-lex-rule := comp-extraction-lex-rule & [SYNSEM canonical-synsem & [LOCAL.CAT [HEAD +nv & [VFORM non-fin], VAL.COMPS #comps ]], DTR [SYNSEM [LOCAL.CAT.VAL.COMPS < gap & [BOUND -, LOCAL [CONT.HOOK.INDEX event-or-human-index]] . #comps>]]]. comp2-extra-lex-rule := comp-extraction-lex-rule & [SYNSEM [LOCAL.CAT.VAL.COMPS <#1 . #comps>, NON-LOCAL.SLASH #sl ], DTR [SYNSEM.LOCAL.CAT.VAL.COMPS <#1 & canonical-synsem & [OPT -, NON-LOCAL [SLASH 0-dlist, REL 0-dlist, QUE 0-dlist] ], gap & [BOUND -, NON-LOCAL.SLASH #sl] . #comps > ]]. ;;; TODO: ;;; Dative shift (pre-inflection) ;;; Type raising (pre-inflection) DONE ;;; IO complement extraction (post-inflection) DONE ;;; Infl rule types ;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Frame marking irules ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;; verbal-irule := no-prefix-lex-rule & lexeme-to-word-rule & [INFLECTED infl-word, MORPH #m, SYNSEM [LOCAL [CAT.HEAD verb & [VFORM non-fin]]], DTR [MORPH #m, SYNSEM.LKEYS.--MCLASS vclass, INFLECTED [FRAME -]]]. verb-irule := verbal-irule & [INFLECTED [NUM-GEND na], SYNSEM [LOCAL [CAT.HEAD verb]]]. vn-irule := lexeme-to-word-rule & no-prefix-lex-rule & [MORPH #m, INFLECTED infl-word, SYNSEM.LOCAL [CAT.HEAD verb & [VFORM non-fin]], DTR [MORPH #m, INFLECTED [FRAME -], SYNSEM.LKEYS.--MCLASS v-vn-wa-gr]]. strong-vn-irule := head-change-only-lex-rule & no-prefix-lex-rule & nocoord & inflecting-lex-rule & [MORPH #m, INFLECTED [FRAME -, CAN-RES -, NUM-GEND na], SYNSEM [BOUND -, LOCAL.CAT.HEAD noun & [CASE bare, MOD #mod]], DTR [MORPH #m, INFLECTED infl-root & [FRAME -, CAN-RES -, NUM-GEND na], SYNSEM [LOCAL.CAT.HEAD verb & [MOD #mod, VFORM non-fin]]]]. noun-irule := lexeme-to-word-rule & no-prefix-lex-rule & [MORPH #m, INFLECTED [NUM-GEND na-or-+], SYNSEM.LOCAL.CAT.HEAD nominal, DTR.MORPH #m]. frame-irule := lexeme-to-word-rule & i-frame-lex-rule. a-irule := frame-irule & [SYNSEM.LOCAL.CAT.VAL.COMPS frame-non-b-c-val-list]. verb-a-irule := a-irule & const-ltow-rule & same-len-lex-rule & verb-irule. vn-a-d-irule := a-irule & vn-irule & [SYNSEM.LOCAL [CONT.HOOK.INDEX.E continuative], DTR.SYNSEM.LKEYS.--MCLASS v-vn-reg-gr]. vn-a-irule := infl-ltow-rule & vn-a-d-irule & [SYNSEM.LOCAL.CAT.VAL.COMPS frame-a-val-list]. vn-d-irule := const-ltow-rule & same-supra-lex-rule & vn-a-d-irule & [SYNSEM.LOCAL.CAT.VAL.COMPS frame-d-val-cons & <[LOCAL.CAT.HEAD.KEYS.KEY "_wà_v_applic_rel" ], ...> ]. noun-a-irule := a-irule & same-supra-lex-rule & const-ltow-rule & noun-irule & [INFLECTED infl-word]. noun-b-c-irule := b-c-irule & infl-ltow-rule & noun-irule. noun-b-irule := noun-b-c-irule & b-irule. noun-c-irule := noun-b-c-irule & c-irule & [SUPRA [LEN [LIST , LAST #ll], TONE #tone], DTR [SUPRA [LEN [LIST <[] . #len>, LAST #ll], TONE #tone]]]. b-c-irule := frame-irule & [MORPH.COMPLETE bool, SYNSEM.LOCAL.CAT.VAL.COMPS frame-B-C-val-cons]. b-irule := b-word-or-irule & b-c-irule & [SYNSEM.LOCAL.CAT.VAL.COMPS frame-B-val-cons ]. c-irule := b-c-irule & [SYNSEM.LOCAL.CAT.VAL.COMPS frame-C-val-cons]. verb-c-irule := verbal-irule & c-irule. verb-c-const-irule := const-ltow-rule & verb-C-irule. verb-c-infl-irule := infl-ltow-rule & verb-c-irule. verb-c-short-irule := verb-c-infl-irule & shorten-lex-rule. verb-c-idlen-irule := verb-c-const-irule & same-len-lex-rule. verb-b-irule := verbal-irule & b-irule & infl-ltow-rule & [SUPRA [LEN [LIST < short , long . #list> , LAST #last]], DTR [SUPRA [LEN [LIST < [] . #list> , LAST #last]]] ]. wa-b-irule := verbal-irule & b-irule & infl-ltow-rule & [SUPRA [LEN [LIST < short , short . #list> , LAST #last]], DTR [SUPRA [LEN [LIST < [] . #list> , LAST #last]]] ]. gani-sani-b-irule := verbal-irule & b-irule & infl-ltow-rule & [SUPRA [LEN [LIST , LAST #llast]], DTR [SUPRA [LEN [LIST < [] . #llist> , LAST #llast]]] ]. gani-sani-c-irule := verbal-irule & c-irule & infl-ltow-rule & [SUPRA [LEN [LIST #list , LAST #last]], DTR [SUPRA [LEN [LIST < [] . #list> , LAST #last]]] ]. ; prep-irule := ; no-prefix-lex-rule & ; lexeme-to-word-rule & ; [INFLECTED infl-word, ; SYNSEM [LOCAL [CAT.HEAD adp ]], ; DTR [INFLECTED i-3]]. ; prep-b-irule := ; prep-irule & ; b-irule & ; [DTR [INFLECTED i-3]]. ; prep-c-irule := ; prep-irule & ; c-irule & ; [DTR [INFLECTED i-3]]. pron-or-resump-irule := inher-lkeys-lex-rule & no-prefix-lex-rule & inflecting-lex-rule & same-head-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & nocoord & [SUPRA supra_reent, MORPH #m & [COMPLETE bool], INFLECTED infl-word & [CAN-RES #cr, FRAME #fr, NUM-GEND #ng], SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, SPR #spr, SPEC #spec, COMPS #comps], DTR [MORPH #m, INFLECTED [CAN-RES #cr, FRAME #fr, NUM-GEND #ng], SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, SPR #spr, SPEC #spec, COMPS frame-B-val-cons & <[OPT -, LOCAL [AGR #agr, CONT.HOOK.INDEX #agr, CAT [HEAD noun, VAL [SUBJ <>, SPR <>, COMPS <>, SPEC <>]] ]] . #comps> ]] ]. pron-irule := pron-or-resump-irule & [C-CONT [RELS #r, HCONS #h], DTR.SYNSEM.LOCAL.CAT.VAL.COMPS frame-B-val-cons & < pronominal-synsem & [LOCAL.CONT [RELS #r, HCONS #h]],...>]. ;;; DO pronoun inflection pron-or-resump-do-irule := pron-or-resump-irule & [SUPRA [TONE #tone , LEN [LIST #llist, LAST #llast]], DTR [SUPRA [TONE #tone , LEN [LIST #llist, LAST #llast]]]]. do-pron-irule := pron-or-resump-do-irule & pron-irule. human-do-pron-irule := do-pron-irule & [DTR.SYNSEM.LOCAL.CAT.VAL.COMPS < [LOCAL.CONT.HOOK.INDEX.SORT human], ...> ]. ;;; Grade 5 particle rules gr5-da-particle-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-supra-lex-rule & same-mclass-lex-rule & val-change-only-lex-rule & [INFLECTED #infl & [FRAME -, CAN-RES +, NUM-GEND na], MORPH #m & [MCLASS vclass-gr5], SYNSEM.LOCAL.CAT [HEAD verb, VAL [SUBJ #subj, SPR #spr, COMPS frame-d-val-cons & <#wa & [BOUND +, LOCAL.CAT [HEAD [KEYS.KEY "_wà_v_applic_rel"], VAL [COMPS <#c>]]], canonical-synsem & [BOUND +, LOCAL.CAT [HEAD noun & [KEYS.KEY "_dà_p_sel_rel", CASE da], VAL.COMPS < canonical-synsem > ]], #c . frame-c-val-cons & #comps > ] ], DTR [INFLECTED #infl, MORPH #m, SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, SPR #spr, COMPS frame-d-val-cons & <#wa, #c & [BOUND -] . #comps > ] ] ]. ;;; Type raising rules tr-augment-slash-lex-rule := same-mclass-lex-rule & [SYNSEM [LOCAL.CAT.VAL.COMPS < [_TR +, NON-LOCAL [SLASH [LIST #sl1, LAST #sl2], QUE [LIST #ql1, LAST #ql2]]], ... >, NON-LOCAL [SLASH [LIST #sl1, LAST #sl3], TO-BIND #tb, REL #rel, QUE [LIST #ql1, LAST #ql3]]], DTR [SYNSEM.NON-LOCAL [SLASH [LIST #sl2, LAST #sl3], TO-BIND #tb, REL #rel, QUE [LIST #ql2, LAST #ql3]]]]. ;;; wa applic-tr-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-head-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-supra-lex-rule & tr-augment-slash-lex-rule & [INFLECTED [NUM-GEND na, FRAME -, CAN-RES +], C-CONT [RELS , HCONS ], SYNSEM [BOUND -, LOCAL [CAT [HEAD verb & [VFORM non-fin], VAL [SUBJ #subj, COMPS frame-d-val-cons & < [ BOUND +, LOCAL [CAT [ VAL [ SUBJ <>, SPR < >], HEAD verb & [KEYS.KEY "_wà_v_applic_rel"]], CONT.HOOK [LTOP #l, XARG #e]]], ... >, SPR #spr ]], CONT.HOOK [INDEX #e, LTOP #l]]], DTR.SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, COMPS frame-non-d-val-list, SPR #spr ]]. noun-poss-tr-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-head-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-supra-lex-rule & tr-augment-slash-lex-rule & ccont-1ep-rule & [MORPH.COMPLETE bool, INFLECTED #infl, C-CONT [RELS , HCONS ], SYNSEM [LOCAL [CAT [HEAD noun, VAL [SUBJ #subj, SPR #spr, SPEC #spec, COMPS frame-B-C-val-cons & <[OPT -, LOCAL [CAT [HEAD noun & [CASE bare, MOD <>], VAL [SUBJ <>, SPR <>, COMPS <>, SPEC <>]], CONT.HOOK [INDEX #2]]]>]], CONT.HOOK [LTOP #l, INDEX #1 & ref-ind]]], DTR [INFLECTED #infl & infl-root & [FRAME -, CAN-RES -, NUM-GEND -], SYNSEM [LOCAL.CAT.VAL [SUBJ #subj, SPR #spr, SPEC #spec, COMPS <>]]]]. mod-to-prd-tr-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-agr-lex-rule & same-mc-lex-rule & same-ctxt-lex-rule & same-non-local-lex-rule & same-supra-lex-rule & same-mclass-lex-rule & [INFLECTED #infl, C-CONT [RELS , HCONS ], SYNSEM [LOCAL [CONT.HOOK [LTOP #h, INDEX #i, XARG #x], CAT [HEAD +np & [MOD <>], VAL [SUBJ <#subj & [LOCAL.AGR #x]>, SPR <>, SPEC <>, COMPS #comps ]]]], DTR [INFLECTED #infl & [FRAME na-or--, CAN-RES -, NUM-GEND na-or-+], SYNSEM.LOCAL [CONT.HOOK [LTOP #h, XARG event-or-ref-index, INDEX #i & [E continuative]], CAT [HEAD +np & [MOD < #subj >], VAL [SUBJ <>, SPR <>, SPEC <>, COMPS #comps]]]]]. ;;; Check whether or not type raising works with pronouns ;;; Assuming no for the time being adj-tr-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-supra-lex-rule & same-mclass-lex-rule & same-non-local-lex-rule & [INFLECTED #infl, MORPH #m, C-CONT [RELS , HCONS ], SYNSEM [BOUND -, LOCAL [AGR #i, CONT.HOOK [LTOP #h, INDEX #i], CAT [HEAD noun & [MOD <>], VAL [SUBJ #subj, SPR #spr , SPEC #spec, COMPS frame-C-val-cons & < #mod & [MODIFIABLE na-or-+, MODIFIED notmod, OPT -, LOCAL [CONT.HOOK [LTOP #h, INDEX #i], CAT [HEAD noun & [CASE bare, MOD <>], VAL [SPR #spr , COMPS <>, SPEC <>]]]]>]]]], DTR [MORPH #m, INFLECTED #infl & [NUM-GEND +, FRAME -, CAN-RES -], SYNSEM [LOCAL [CONT.HOOK [LTOP #h, XARG #i], CAT [HEAD noun & [MOD <#mod>], VAL [SUBJ #subj, SPEC #spec, COMPS <>]]]]]]. noun-dem-tr-lex-rule := no-prefix-lex-rule & const-ltol-rule & same-head-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & [MORPH #m & [COMPLETE bool], SUPRA [TONE.LIST #tone, LEN.LIST #len, TONES , LENGTHS ], INFLECTED #infl, C-CONT [RELS , HCONS ], SYNSEM [LOCAL [CAT [HEAD #hd, VAL [SUBJ #subj, SPR <>, SPEC #spec, COMPS frame-B-C-val-cons & < #spr & [OPT -, LOCAL [CAT [HEAD bound-det & [KEYS.KEY dem_q_rel], VAL [SUBJ <>, SPR <>, COMPS <>, SPEC <[LOCAL.CAT.HEAD #hd]>]], CONT [HOOK [INDEX #i & [COG-ST activated, SPECI +]], HCONS ]]]>]], CONT.HOOK [INDEX #i, LTOP #ltop]], NON-LOCAL.SLASH ], DTR [MORPH #m, INFLECTED #infl & [CAN-RES -, FRAME -, NUM-GEND +], SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, SPR <#spr>, SPEC #spec, COMPS <>]]]. noun-dem-proximate-tr-lex-rule := noun-dem-tr-lex-rule & [SYNSEM.LOCAL.CAT.VAL.COMPS <[LOCAL.CAT.HEAD.KEYS.KEY dem_q_proximate_rel]>]. noun-dem-remote-tr-lex-rule := noun-dem-tr-lex-rule & [SYNSEM.LOCAL.CAT.VAL.COMPS <[LOCAL.CAT.HEAD.KEYS.KEY dem_q_remote_rel]>]. ;;;;;;;;;;;;;;;;;; ;;; Morphology ;;; ;;;;;;;;;;;;;;;;;; noun-def-irule := no-prefix-lex-rule & nocoord & inflecting-lex-rule & same-head-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & [SUPRA supra_reent, MORPH #m & [COMPLETE bool], INFLECTED infl-word, SYNSEM.LOCAL.CAT.VAL [SUBJ #subj, COMPS #comps & <>, SPR #spr, SPEC <>], C-CONT [RELS , HCONS ], DTR [MORPH #m, INFLECTED [CAN-RES -, FRAME -, NUM-GEND +], SYNSEM.LOCAL [CONT.HOOK.INDEX [SPECI +], CAT.VAL [SUBJ #subj, COMPS #comps, SPR #spr, SPEC <>]]]]. noun-singular-rule := no-prefix-lex-rule & same-local-lex-rule & same-modified-lex-rule & same-light-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & nocoord & [C-CONT [RELS , HCONS ], MORPH #m & [MCLASS n-pl-infl, COMPLETE +], SYNSEM [LOCAL [CAT.HEAD noun, AGR.PNG p-s-g ]], DTR [MORPH #m, INFLECTED infl-root]]. noun-singular-infl-rule := inflecting-lex-rule & i-num-gen-lex-rule & noun-singular-rule. noun-singular-const-rule := i-num-gen-lex-rule & noun-singular-rule & constant-lex-rule & [SUPRA #sup, DTR [SUPRA #sup]]. noun-plural-rule := no-prefix-lex-rule & same-local-lex-rule & same-modified-lex-rule & same-light-lex-rule & same-non-local-lex-rule & same-mclass-lex-rule & nocoord & [C-CONT [RELS , HCONS ], SYNSEM [LOCAL [CAT.HEAD noun, AGR.PNG p-p-g ]], DTR [INFLECTED infl-root]]. noun-plural-const-rule := noun-plural-rule & constant-lex-rule & i-num-gen-lex-rule & [MORPH #m, DTR.MORPH #m]. noun-plural-infl-rule := noun-plural-rule & inflecting-lex-rule & i-num-gen-lex-rule & [MORPH #m, DTR.MORPH #m]. redup-rule := lex-rule & [--BSE #stem & cons, MORPH.--REDUP.--STEM #stem]. noun-redup-rule := redup-rule & [STEM < #stem >, MORPH [MCLASS #m & n-pl-total-redup, DERIVED #deriv, COMPLETE -, --REDUP.--STEM <#stem>], DTR.MORPH [MCLASS #m, DERIVED #deriv, COMPLETE +]]. noun-plural-redup-const-rule := noun-plural-rule & constant-lex-rule & i-num-gen-lex-rule & noun-redup-rule. noun-plural-redup-infl-rule := noun-plural-rule & inflecting-lex-rule & i-num-gen-lex-rule & noun-redup-rule. ;;; Phrasal types basic-expl-subj-phrase := head-valence-phrase & head-only & head-compositional & [ INFLECTED #infl, SYNSEM canonical-synsem & [ LOCAL.CAT [ VAL [ SUBJ < >, COMPS #comps, SPR #spr, SPEC #spec ], POSTHEAD #ph ], MODIFIED #mod ], C-CONT [ RELS , HCONS ], HEAD-DTR [ INFLECTED #infl & infl-word, SYNSEM [ LOCAL [ CAT [ VAL [ SUBJ < unexpressed & [ OPT +, LOCAL.CONT [HOOK.INDEX expl-ind, RELS , HCONS ] ] >, COMPS #comps & < >, SPR #spr, SPEC #spec ], POSTHEAD #ph ], CONT.HOOK.INDEX event ], MODIFIED #mod ] ] ]. basic-head-opt-subj-phrase := head-valence-phrase & head-only & head-compositional & ccont-2ep-rule & [ INFLECTED #infl, SYNSEM canonical-synsem & [ LOCAL.CAT [ VAL [ SUBJ < >, COMPS #comps, SPR #spr, SPEC #spec ], POSTHEAD #ph ], MODIFIED #mod ], C-CONT [ RELS , HCONS ], HEAD-DTR [ INFLECTED #infl & infl-word, SYNSEM [ LOCAL [ CAT [ VAL [ SUBJ < unexpressed-reg & [ OPT +, LOCAL.CONT.HOOK.INDEX #0 & [COG-ST in-foc] ] >, COMPS #comps & < >, SPR #spr, SPEC #spec ], POSTHEAD #ph ], CONT.HOOK.INDEX event ], MODIFIED #mod ] ] ]. basic-head-comp-phrase :+ [ SYNSEM.LOCAL.CAT.MC #mc, HEAD-DTR.SYNSEM.LOCAL.CAT.MC #mc]. ;;; Using XARG; do not equate entire HOOK basic-head-mod-phrase-simple := head-mod-phrase & binary-headed-phrase & [ SYNSEM [ NON-LOCAL [ SLASH [ LIST #first, LAST #last ], REL 0-dlist ] ], HEAD-DTR.SYNSEM [ LOCAL [ CAT [ HEAD #head, VAL #val, POSTHEAD #ph, MC #hmc ], AGR #agr, CONT.HOOK [LTOP #l, INDEX #i]], NON-LOCAL #nonloc & [ SLASH [ LIST #middle, LAST #last ] ], LIGHT #light, MODIFIABLE #modifiable, MODIFIED #modif ], NON-HEAD-DTR.SYNSEM [ LOCAL.CAT [ HEAD [ MOD < [ LOCAL local & [ CAT [ HEAD #head, VAL #val, POSTHEAD #ph, MC #hmc ], AGR #agr, CONT.HOOK [INDEX #i, LTOP #l] ], NON-LOCAL #nonloc, LIGHT #light, MODIFIABLE #modifiable, MODIFIED #modif ] > ], VAL [ COMPS olist, SPR olist ] ], NON-LOCAL [ SLASH [ LIST #first, LAST #middle ], QUE 0-dlist & [ LIST null ] ] ], C-CONT.RELS ]. basic-head-mod-phrase-simple :+ [ SYNSEM.LOCAL.CAT.MC #mc, NON-HEAD-DTR.SYNSEM.LOCAL.CAT.MC #mc ]. head-comp-phrase := basic-head-1st-comp-phrase & head-initial & [SYNSEM.MODIFIABLE #m, HEAD-DTR.SYNSEM [MODIFIABLE #m, MODIFIED notmod]]. head-cluster-phrase := basic-head-comp-phrase & head-initial & [SYNSEM [MODIFIABLE #m ], HEAD-DTR.SYNSEM [LOCAL.CAT.HEAD.VFORM non-fin, MODIFIABLE #m, MODIFIED notmod]]. subj-head-phrase := decl-head-subj-phrase & head-final & [ HEAD-DTR.SYNSEM.LOCAL.CAT.VAL [COMPS < >, SUBJ <[BOUND -]>] ]. spec-head-phrase := basic-head-spec-phrase & head-final & [ SYNSEM.MODIFIABLE na-or--, HEAD-DTR.SYNSEM.LOCAL.CAT.VAL [SPR <[LOCAL.CAT.HEAD free-det]>, COMPS < > ]]. extracted-subj-phrase := basic-extracted-subj-phrase & head-compositional & [C-CONT [RELS , HCONS ], SYNSEM [LOCAL [CAT [HEAD verb & [VFORM indep]], CONT.HOOK.INDEX [_REL bool]] ], HEAD-DTR.SYNSEM.LOCAL.CAT.VAL [SUBJ <[LOCAL.CAT.VAL [SPR <>, COMPS <>, SUBJ <>]]>] ]. ; Constraint on SUBJ: [LOCAL.CAT.HEAD.CASE npro-case] head-rel-phrase := head-mod-phrase & head-initial & head-compositional & [ SYNSEM [ NON-LOCAL [ SLASH [ LIST #first, LAST #last ], REL 0-dlist ] ], HEAD-DTR.SYNSEM [ MODIFIABLE na-or-+, BOUND -, LOCAL [ CAT [ HEAD noun, VAL [COMPS <>]], AGR #index, CONT.HOOK [INDEX ref-ind & #index, LTOP #top]], NON-LOCAL [ SLASH [ LIST #middle, LAST #last ] ] ], NON-HEAD-DTR.SYNSEM [ LOCAL [CAT [ HEAD comp & [VFORM fin, MOD < > ], VAL [ COMPS olist, SPR olist ] ], CONT.HOOK [INDEX event & [_REL +], LTOP #top]], NON-LOCAL [ TO-BIND [FILLER < >, SLASH ], SLASH [ LIST #first, LAST #middle ], REL , QUE 0-dlist & [ LIST null ] ] ], C-CONT [RELS , HCONS ] ]. filler-head-phrase := basic-head-filler-phrase & basic-head-final & head-compositional & [C-CONT [RELS , HCONS ], SYNSEM.NON-LOCAL [REL & [LIST #rel1, LAST #rel3], QUE ], NON-HEAD-DTR [STEM [FROM #from, TO #to], SYNSEM canonical-synsem & [BOUND -, LOCAL [CAT [HEAD +nvjp, VAL [SUBJ olist, COMPS <>, SPR <>]], CONT.HOOK.INDEX #2 & [--IS +foc]], NON-LOCAL [REL [LIST #rel1, LAST #rel2]]]], HEAD-DTR [SYNSEM canonical-synsem & [LOCAL.CONT.HOOK [LTOP #l, INDEX #1], NON-LOCAL [SLASH [LIST cons, LAST null], REL [LIST #rel2, LAST #rel3] ]]]]. #| rel-comp-phrase := marker-initial-phrase & [C-CONT [RELS , HCONS ], SYNSEM [LOCAL.CAT.HEAD #hd &comp, NON-LOCAL [REL & [LIST #rel1, LAST #rel3], QUE [LIST #que1, LAST #que3]]], NON-MARKER-DTR [STEM [FROM #from, TO #to], SYNSEM [LOCAL.CONT.HOOK.INDEX #2, NON-LOCAL [REL [LIST #rel1, LAST #rel2], QUE [LIST #que1, LAST #que2]]]], MARKER-DTR [SYNSEM [LOCAL [CAT.HEAD #hd, CONT.HOOK [LTOP #l, INDEX #1]], NON-LOCAL [REL [LIST #rel2, LAST #rel3], QUE [LIST #que2, LAST #que3]]]]]. |# ; Bare NP phrase. Consider modifying the PRED value of the quantifier relation ; introduced to match the semantic effect of bare NPs in your language. bare-np-phrase := basic-bare-np-phrase & ccont-1ep-rule & [SYNSEM [MODIFIED notmod, NON-LOCAL #nloc], HEAD-DTR.SYNSEM.NON-LOCAL #nloc, C-CONT.RELS ]. ;;; Non-compositional binary rule type (for reduplication) non-compositional-binary-phrase := word-or-lexrule-min & supra-binary-phrase & [STEM [FROM #from, TO #to], SYNSEM.LOCAL [CONT [ RELS [ LIST #first, LAST #last ], HCONS [ LIST #scfirst, LAST #sclast ] ]], C-CONT [ RELS [ LIST #middle, LAST #last ], HCONS [ LIST #scmiddle, LAST #sclast ] ], ARGS < sign & [STEM [FROM #from]], sign & [STEM [TO #to], SYNSEM.LOCAL local & [ CONT [ RELS [ LIST #first, LAST #middle ], HCONS [ LIST #scfirst, LAST #scmiddle ] ] ] ] > ]. #| non-compositional-binary-phrase :+ [ARGS <[SUPRA [TONES #t1, --TONES #t1, LENGTHS #l1, --LENGTHS #l1]], [SUPRA [TONES #t2, --TONES #t2, LENGTHS #l2, --LENGTHS #l2]]>]. |# ;;; Constrain to reduplicant-lex total-reduplication-phrase := lex-max & non-compositional-binary-phrase & [STEM <#red . #base >, INFLECTED infl-word, SYNSEM [LOCAL [AGR #agr, CAT #cat, COORD #coord], NON-LOCAL #nloc], ARGS < reduplicant-lex & [KEY-ARG +, MORPH [MCLASS #mc, COMPLETE na, --REDUP.--STEM < #red > ], INFLECTED [CAN-RES na-or--, FRAME na-or--], SYNSEM [LOCAL [CAT [HEAD #head], COORD #coord]]], word-or-lexrule & [STEM #base & cons, KEY-ARG -, MORPH [MCLASS #mc, COMPLETE -], SYNSEM [LOCAL [CAT #cat & [HEAD #head], AGR #agr, COORD #coord], NON-LOCAL #nloc]]>]. ;;; Derivational rule types participial-infl-lex-rule := same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & no-prefix-tone-lex-rule & inflecting-lex-rule & nocoord & [SUPRA [TONE.LAST #tlast], SYNSEM [LOCAL [CAT [HEAD head & [--MOD +, MOD < [LOCAL [CAT [HEAD #hd, VAL [COMPS #c]], CONT #cont ], NON-LOCAL #nloc] > ], VAL [SPR <>, SUBJ <>, COMPS <> ]], CONT.HOOK.XARG event-or-ref-index]], DTR [SUPRA [TONE.LAST #tlast], INFLECTED [FRAME -, CAN-RES -], MORPH.MCLASS v-vn-base-gr, SYNSEM [LOCAL [CAT [HEAD verb & [VFORM non-fin], VAL [SUBJ <[NON-LOCAL.SLASH ]>, COMPS frame-b-c-val-cons & < [LOCAL [CAT [HEAD #hd, VAL [COMPS #c]], CONT #cont ], NON-LOCAL #nloc] > ]]]]]]. stative-infl-lex-rule := participial-infl-lex-rule & ccont-1ep-rule & [C-CONT [HOOK [INDEX #e, LTOP #l], RELS , HCONS ], SYNSEM [LOCAL [AGR #x, CAT [HEAD adp ], CONT.HOOK [INDEX #e, XARG #x, LTOP #l]]], INFLECTED [FRAME na, CAN-RES na, NUM-GEND na], SUPRA [TONE.LIST l*-h-cons, LEN [LIST , LAST #llast]], DTR [SUPRA [LEN [LIST <[] . #llist>, LAST #llast]], SYNSEM [LOCAL [CONT.HOOK [LTOP #l, INDEX #e1]]] ] ]. participle-infl-lex-rule := participial-infl-lex-rule & no-ccont-lex-rule & [INFLECTED [FRAME na-or--, NUM-GEND -], SUPRA [TONE.LIST l*-h-h-cons, LEN [LIST , LAST #llast]], MORPH.MCLASS #mclass & n-pl-9_u & [INH-GEND -], SYNSEM [LKEYS.--MCLASS #mclass, LOCAL [AGR #agr, CAT.HEAD noun, CONT.HOOK [XARG #agr, INDEX #e & [E no_tam], LTOP #l]]] , DTR [SUPRA.LEN [LIST <[] . #llist>, LAST #llast], SYNSEM [LOCAL [CONT.HOOK [INDEX #e, LTOP #l]]]]]. pluractional-lex-rule := same-val-lex-rule & same-hc-light-lex-rule & same-posthead-lex-rule & same-mc-lex-rule & same-cont-lex-rule & same-ctxt-lex-rule & same-agr-lex-rule & same-non-local-lex-rule & ccont-1ep-rule & [MORPH.COMPLETE bool, SUPRA [PRFX [TONE ]], C-CONT [RELS , HCONS ], MORPH [DERIVED +], SYNSEM [LOCAL [CONT.HOOK [LTOP #l, INDEX #1 ]]], DTR [MORPH [DERIVED na], INFLECTED [NUM-GEND na-or-+, CAN-RES -, FRAME -] ] ]. pluractional-noun-lex-rule := redup-rule & pluractional-lex-rule & [STEM < #stem >, SYNSEM [LOCAL [AGR [PNG.GEND m], CAT [HEAD noun & [MOD <>], VAL.COMPS val-list], CONT.HOOK.INDEX individual ]], MORPH [--REDUP [--STEM <#stem>, --SUPRA [TONE.LIST l*-h-cons, LEN [LIST cons & [--LT #red-len], LAST #last]]], COMPLETE -], SUPRA [TONE.LIST l*-h-cons, LEN [LIST & [--LT #red-len], LAST #last ]], DTR [SYNSEM.LOCAL.CAT.HEAD verb & [VFORM non-fin], SUPRA [LEN [LIST < [] . #len >, LAST #last]], MORPH [MCLASS v-vn-base-gr, COMPLETE +] ]]. pluractional-noun-infl-lex-rule := pluractional-noun-lex-rule & infl-ltol-rule. pluractional-verb-lex-rule := pluractional-lex-rule & same-head-lex-rule & no-prefix-tone-lex-rule & same-tone-lex-rule & infl-ltol-rule & [MORPH.MCLASS #mclass, SYNSEM [LOCAL [CAT.HEAD verb, CONT.HOOK.INDEX [E real_tam]]], DTR.MORPH.MCLASS #mclass]. pluractional-verb-prefix-lex-rule := pluractional-verb-lex-rule & [SUPRA [LEN.LIST #llist, TONE #tone, PRFX [LEN , TONE ]], DTR [SUPRA [LEN.LIST #llist, TONE #tone]]]. pluractional-verb-infix-lex-rule := pluractional-verb-lex-rule & [SUPRA [LEN.LIST < #l1, #l2, short . #llist>, TONE #tone, PRFX [LEN , TONE ]], DTR [SUPRA [LEN.LIST < #l1, #l2 . #llist & <[], ...> >, TONE #tone]]]. ;;; Equational clauses (insert predication and SUBJ valence by unary rule) equational-phrase := ccont-1ep-rule & unary-phrase & [C-CONT [HCONS , HOOK #hook & [INDEX #e, LTOP #l], RELS ], SYNSEM [LOCAL [CAT [HEAD verb & [KEYS.KEY #key, MOD <>, VFORM indep], VAL [SUBJ < [ LOCAL [ COORD -, CAT [ HEAD +nvjp & [MOD <> ], VAL [SUBJ <>, SPEC <>, COMPS <>, SPR <>]], CONT.HOOK.INDEX #x1] ]>, COMPS <>, SPEC <>, SPR <>] ], CONT.HOOK #hook ], NON-LOCAL #nloc ], ARGS <[SYNSEM canonical-synsem & [LOCAL [CAT [HEAD noun & [MOD <>], VAL [SUBJ <>, SPEC <>, COMPS <>, SPR <> ] ], COORD -, CONT [HOOK.INDEX #x2 & ref-ind] ], NON-LOCAL #nloc ] ] > ]. ;;; Coordination rules ;;; Sentential coordination s-bottom-binary-coord-rule := s-bottom-coord-phrase & conj-first-bottom-coord-rule & [ SYNSEM.NON-LOCAL.TO-BIND #tb, ARGS < [ SYNSEM [LOCAL.COORD-REL verbal-coord-rel, NON-LOCAL.TO-BIND #tb ]], [ SYNSEM.NON-LOCAL.TO-BIND #tb ] > ]. s-top-coord-rule := basic-s-top-coord-rule & apoly-top-coord-rule & [ SYNSEM.NON-LOCAL.TO-BIND #tb, ARGS < [ SYNSEM.NON-LOCAL.TO-BIND #tb ], [ SYNSEM.NON-LOCAL.TO-BIND #tb ] > ]. ;;; NP coordination (poly-/omni-syndetic) ;;; Make omnisyndetic coordination left-branching omni-coord-phrase := coord-phrase & [ C-CONT.HOOK [ LTOP #lbl, INDEX #carg ], RCOORD-DTR omni-right-coord-rule & [ SYNSEM.LOCAL [ COORD-STRAT #strat, COORD +, COORD-REL [ LBL #lbl, ARG0 #carg & coord-index, L-INDEX #lind, R-INDEX #rind ], CONT.HOOK.INDEX #rind ]], LCOORD-DTR [SYNSEM.LOCAL [ COORD-STRAT #strat, COORD na-or--, CONT.HOOK.INDEX #lind ]] ]. omni-top-coord-rule := omni-coord-phrase & [ SYNSEM.LOCAL.COORD -, ARGS < [KEY-ARG -], [KEY-ARG +] >]. np-bot-coord-rule := np-bottom-coord-phrase & omni-conj-first-bottom-coord-rule & [ SYNSEM [NON-LOCAL #nloc], ARGS < [ SYNSEM.NON-LOCAL #nloc], [ SYNSEM.NON-LOCAL #nloc ] > ]. np-right-coord-rule := np-bottom-coord-phrase & omni-conj-first-right-coord-rule & [ SYNSEM [NON-LOCAL #nloc], ARGS < [ SYNSEM.NON-LOCAL #nloc ], [ SYNSEM.NON-LOCAL #nloc ] > ]. np-top-coord-rule := basic-np-top-coord-rule & omni-top-coord-rule & [ SYNSEM.NON-LOCAL #nloc, ARGS < [ SYNSEM.NON-LOCAL #nloc ], [ SYNSEM.NON-LOCAL #nloc ] > ].