;;; File: coordinators.lisp
;;; Time-stamp: <97/01/22 21:42:40 jlitchfi>

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; New and redefined systems for removing "and", "or", and "but" from a ;;;
;;; conjunctive, disjunctive, and contrastive extension, respectively.   ;;;
;;; These patches are most likely redundant.                             ;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

;;; previously defined in no-either.lisp 

;;; IF YOU ARE LOADING PATCHES BY HAND, MAKE SURE YOU LOAD no-either.lisp
;;; *BEFORE* THIS FILE.


(SYSTEM
 :NAME                   EXTENDING-COORDINATION-TYPE
 :INPUTS                 EXTENDING-COORDINATION
 :OUTPUTS                ((0.33333334 ADDITIVE-COORDINATION
				      (INSERT COORDINATOR)
				      (ORDER COORDINATOR EXTENSION))
			  (0.33333334 ALTERNATIVE-COORDINATION
				      (INSERT CORRELATOR) 
				      (ORDER CORRELATOR EXTENDED)
				      (INSERT COORDINATOR)
				      (ORDER COORDINATOR EXTENSION))
			  (0.33333334 CONTRASTIVE-COORDINATION
				      (INSERT COORDINATOR) 
				      (ORDER COORDINATOR EXTENSION)))
 :CHOOSER                EXTENDING-COORDINATION-TYPE-CHOOSER
 :REGION                 CLAUSECOMPLEX
 :METAFUNCTION           LOGICAL
 )

;;; new systems
;;;
;;; We call (LEXIFY COORDINATOR ELLIPSISZERO) in order to remember 
;;; that the coordinator has been elided.

(system 
 :name EXPRESS-ADDITIVE-COORDINATION
 :inputs ADDITIVE-COORDINATION
 :outputs ((0.5 EXPRESS-ADDITIVE-COORDINATION
		(LEXIFY COORDINATOR AND))
	   (0.5 NOT-EXPRESS-ADDITIVE-COORDINATION
		(LEXIFY COORDINATOR ELLIPSISZERO)))
 :chooser EXPRESS-ADDITIVE-COORDINATION-CHOOSER
 :region CLAUSECOMPLEX
 :metafunction LOGICAL
)

(system 
 :name EXPRESS-ALTERNATIVE-COORDINATION
 :inputs ALTERNATIVE-COORDINATION
 :outputs ((0.5 EXPRESS-ALTERNATIVE-COORDINATION
		(LEXIFY COORDINATOR OR))
	   (0.5 NOT-EXPRESS-ALTERNATIVE-COORDINATION
		(LEXIFY COORDINATOR ELLIPSISZERO)))
 :chooser EXPRESS-ALTERNATIVE-COORDINATION-CHOOSER
 :region CLAUSECOMPLEX
 :metafunction LOGICAL
 )

(system 
 :name EXPRESS-CONTRASTIVE-COORDINATION
 :inputs CONTRASTIVE-COORDINATION
 :outputs ((0.5 EXPRESS-CONTRASTIVE-COORDINATION
		(LEXIFY COORDINATOR BUT))
	   (0.5 NOT-EXPRESS-CONTRASTIVE-COORDINATION
		(LEXIFY COORDINATOR ELLIPSISZERO)))
 :chooser EXPRESS-CONTRASTIVE-COORDINATION-CHOOSER
 :region CLAUSECOMPLEX
 :metafunction LOGICAL
 )

;;; previously defined in no-either.lisp

(system
 :name EITHER-SYSTEM
 :inputs (OR EXPRESS-ALTERNATIVE-COORDINATION 
	     NOT-EXPRESS-ALTERNATIVE-COORDINATION)
 :outputs ((0.5 insert-either
                (LEXIFY CORRELATOR EITHER))
           (0.5 no-either
                (lexify correlator ellipsiszero)))
 :chooser EITHER-SYSTEM-CHOOSER
 :selector CHOICE-MASTER
 :old-feature insert-either
 :region CLAUSECOMPLEX
 :metafunction LOGICAL
 )

;;; new choosers

(chooser
 :name EXPRESS-ADDITIVE-COORDINATION-CHOOSER
 :definition ((ask (express-coordinator-q onus)
		   (express (choose EXPRESS-ADDITIVE-COORDINATION))
		   (notexpress (choose NOT-EXPRESS-ADDITIVE-COORDINATION))))
 :comments ""
 :editor "JLL"
 :date "27Feb96 18:15"
)
	
(chooser
 :name EXPRESS-ALTERNATIVE-COORDINATION-CHOOSER
 :definition ((ask (express-coordinator-q onus)
		   (express (choose EXPRESS-ALTERNATIVE-COORDINATION))
		   (notexpress (choose NOT-EXPRESS-ALTERNATIVE-COORDINATION))))
 :comments ""
 :editor "JLL"
 :date "27Feb96 18:15"
)
	
(chooser
 :name EXPRESS-CONTRASTIVE-COORDINATION-CHOOSER
 :definition ((ask (express-coordinator-q onus)
		   (express (choose EXPRESS-CONTRASTIVE-COORDINATION))
		   (notexpress (choose NOT-EXPRESS-CONTRASTIVE-COORDINATION))))
 :comments ""
 :editor "JLL"
 :date "27Feb96 18:15"
)

;;; new inquiry

(askoperator
 :name express-coordinator-q
 :domain TP
 :mode IMPLEMENTED
 :parameters (SPEC)
 :english ("Do you wish to express the coordinator explicitly?")
 :operatorcode trivialdefaultcode
 :parameterassociationtypes (concept)
 :answerset (express notexpress)
 :activedefault express
 :trivialdefault express
)


;;; fix punctuation

(setq (second (second *post-punctuation*))
  (append (second (second *post-punctuation*))
	  '((NOT-EXPRESS-ADDITIVE-COORDINATION COORDINATOR ",")
	    (NOT-EXPRESS-ALTERNATIVE-COORDINATION COORDINATOR ","))))