j- If'J,/-17 ... Proceedings of the Twenty -SeventhHawaii International Conferenceon SystemSciences Volume Ill: Information Systems: DecisionSupport and Knowledge-Based Systems Edited by Jay F. Nunamaker, Jr. and Ralph H. Sprague, Jr. Sponsoredby: The University of Hawaii The University of Hawaii Collegeof BusinessAdministration In cooperation with: The IEEE ComputerSociety Associationfor ComputingMachinery . ~ IEEE Computer Society Press Los Alamitos, California Washington. Brussels. Tokyo I ;~~wQt ~;;)\t..:~,;","~c't'7""",' ""',",c,;~""~,[;c:",j,,,,- . - --'" ~;- ,~~~~'~"~;-." . . ~~ - Towards a Unified AI Formalism Deepak Kumar Susan Haller Dept. of M&thematia Bryn Mawr College Bryn Mawr, PA 19010 dkumarOcc.brynmaw:r .edu S~ Abstract , . I' , , commItment.. , , Semantlcallu, Dept. or Computer Sd~~ South_tern Miaourl State University Sprinlfield, MO 65804 Aa231fOcsm560.amau.edu have come to be called BDI architectures [8]. M~t work on BDI architectures hu as its underlying motivation the need to exa.mine the feasibility of modeling practical rea.. .. 8 BOnIngm resource bounded ~en t s [18, 6]. '"olo th at e,lc.-. th chit tt t t . teg t ' ThaI a unified approach to bul/d, r paper p~lentl . h .t t 0 ch I . Ing .lnte Igent arc I ec U~I. ur approa ~ leI , " on makIng ,ome lemanhc, ontologlro/, al well a, arch,tectural Syed S. All Dept. or Computer SdSlce University or New York at Bufralo Buffalo, NY 1(260-2000 ballerOca.buffalo.edu .~ ar d ~.ures a emp bili.t . _..6:- 0 m ra e reasonIng, p Ian- nIng, an g capa les. 0 ur wor k encompaasesth e .. ell as BO - .1dit lon . a.! 188Ues , . -..6. cal pr-..l reasonmg 188Uesu w mvolved in NLU and KRR. Additionally, the architecture bo t t d .be ' d . ed usmg the prmap Ies we 0 escn 18 . eBlgn f are b ' a -' u ted S ch d . 0 0 J~.-vnen programmmg. u a e81gn na t ur all y ale , . .. commIt our'el~e~ to pnnclplel gotlemlng the natu~ of the entitle, ~p~'ented bv the knowledge ,. " ~p~lentahon forma/11m, and the ~/atlonlhlpl . .' . exp Oloe e . 1-0 . ted d ne oe 0 0 Jec Den esJgn, nam ely, I '.- all th be fi.- f b ' between the facultlel of realonang, acting, and . , natuml language under. tandIng. Mo~ .pecifi- .. exte ndibili.t y, and amenabili' ty t 0 concurrency. We will ret t th . I t 6: F. t will t um 0 ~ m a a er ~..on. lIS we pr~n our d I ' .t 'un er ymg comInl menoe. callU, .we concentmte on the natu~ and ~p~1 .. I.-I . ,I t' I d .entatlon 0 entitle" "" le,l, ac lonl, p anI, an I B th ' , d ' realonlng an acting ru e.. a.cu on ele pnnciplel we p~.ent the de.ign of an integruted AI architectu~ that ha. a unified knowledge ~p~,entationalformali.m al well al a unified real onin~ and ac~ing componen~. The .de.ign o! th~ archatectu~ " ba,ed on ob]ect-o.nen,tedpnnclplel. ~e ol,O Ihov: th~t luch a de.'gn II ?mena~le to Implement.atlon In ,a concurrent ob]ect-onented programmIng pamdlgm. We .demonltmte the adtlantagel of our approach ullng letleral uamplel from our alork. -.1 8 Commitments In this paper, we take a different approach towards the integration process. We start with the premiae that re- In the design of the OK architecture we have made severa.! commitments. M~t of them dea.! with representationa.! iBaues. The representation a.! formalism is designed to fa.. cilitate the representation of intenlionol concept. [22]. All entities repr~nted in the KR formalism are intensiona.! in that it will be possible to have two or more iDBtancesthat denote u many entities and yet may correspond to exactly one extensional object (this is the .Principle of Fine<?rained Rep~t~tion~ [22]). Thus, the id.entity conditiona for two entItles will depend upon theu manner of repre8et;ltation. Additi?nal1.Y' there is no req~ent that the e.nt~ty a£t~ally eXlBts m the. world (e.~, .umcon;s) .or gardlessof the individua.! AI subfield involved, all intel- t~at It lectua.! activity involves representation of knowledge and reasoning. Thus, all knowledge required to fulfill various talks (NLU, planning and acting, reasoning, etc.) is to be repr~nted in a common KR formalism. We also take a unified view of reasoning and acting and incorporate that into a BiDglea£ting and inference engine called a mtionol engine. In what follows, we will identify the buic KR prin- aple o~ ,Displacement [22]). In g~nera.!, we woul~ like t~e entities repr~nted to be extenBlona.!A;8 well as mtenBlon&!. ~or. example, the. name of the entity may be one way of linki;ng up an entIty to the exte~a.! world. .In ,the OK Form~m" we ~ enforce the Umqu~ness Prmaple of repr~nting mtenBlona.!concepts-th~re 18 ~ ~ne-to-o.ne co~pondence between terInB re.pr~ntmg ~ntl,tles an.dm- 1 Introduction 18 ~ble (e.g~,squarecircles) (this 18the P~- ciples,the relationahipbetweenacting and inference,and ~ona.! use that to present the design of a new unified AI formalism. called the Object:based (or OK) Archit.ecture.. The deslgn of the OK ~chitecture employs an obJect-o~ented meth~ology that 18 also amenable to concurrent ~plementatio~. We.aI.sopresent severa.!.examplesof the kinds of. beh&~or ~blted by computation a.! ~ents modeled usmg this paradigm. applied to all entities m the formalism, In previous work we have argued for a unified view o~ acting and inference [13]. We have argued that inference be treated u a kind of acting (menta.! acting). Reasoning itself can be viewed &8 a sequenceof actionl performed in applying inference rules to derive beliefs from other beliefs. Thus, an inference rule can be treated as a rule speclfying an act-that of believing some previously non-believed 2 proposition (i.e., the believe act is implicitly included in The OK BDI Architecture ". ,I concept;a .[22J.The Umqu.eness Prmaple will be ; i 4 ; ~ ; ; - j :. i the semantics of the proposition a.! connective). This leads us to make two commitments in the OK architecture-that there be a single operating module that is responsible for reasoning and acting behavior; and that there be a proper semantic distinction between entities that represent beliefs, We begin by pointing out that we are interested in modeling computationa.! rationa.! agents. The behavior of th~ agents must be driven by their beliefs, desires, and intentiona. AI architectures that enable modeling of such ~ents 92 1060-3425/94$3.00 C)1994IEEE Proceedingsof the Twenty-SeventhAnnual Hawaii International Conferenceon System Sciences,1994 "; '( . ~ ; ; ---~- - - -~ ~-,--~ .'" - acts rules for reasoning, a.nd rules for acting (pla.ns). The first' a unified module for acting a.nd inference, is called a roti~nal engine (as opposed to a.n inference engine). The seCondleads to a.n ontological commitment on the part of the KR formalism. In wha.t follows, we first describe the OK Formalism, tha.t is a.nobject-oriented, int.enaional, propositional knowledge representa.tion formalism. Then we will present the design of the OK Rational Engine that is responsible for implementing the unified view of acting a.ndinference. Together, they constitute the OK BDI architecture (see [13] for a.detailed description). 4 The allow a form of subsumption (a more general, or less restricted, v&ri&ble subsumes a.nother more restricted v&riable of the s&me sort) that corresponds directly to similar naturalla.nguage reasoning based on description subsumption. We will illustrate the utility of structured varia.bles with a naturalla.nguage processing example later. 4.4 As mentioned above, propositions are also treated as conceptual entities. Specific insta.nces of the clasa Propoaition T.~ represent propositions. Asserted propositions form agent's beliefs. It is possible for the mod- . Formalism OK eled agent Th b . cl hi ch of the OK Formalism is de icted . e. a.sIC asa erar y " . p. . m Figure 1. A conceptual entIty 18 a.nything a. cognitive , .. . agent ca.n think a.bout. In mtenslonal representation &1 for' bl . _1 .. ' cl d . di ' d _1ma.lisms, conceptu&A entitles m u e m Vl U&iB, V&rla es, . acts, a.nd beliefs. Conceptual .a.l1 . . En-tity Te~ 18 the topmost class m All instances of this class a.s well a.s insta.ncesof it;a sub<:ia.88e8 ar~ .ten:ns of the O~ forma:!- denote basic (un-n&med) entities, I1, na.med individuals, 12. 4.2 ... denote V2. ... B1! Iaa(J., BLOCI) ... denote propositions, J.1, , where Iaa 18 a..subclass ~d BLOCI are mat.ances variables. .Te? . 18 comp~ " of ~tances that unique represent n&med entitles m the doma.m ?f ~urse. For ~xa.m,ple,a.term that denotes the n&med mdiVldual [JOBI] 18wntten as JOHI. 4.3 -: l ,. , , ; : (HYP,{B1!},{}) of the class Pro~~ition of the class Ind]'Yl.d~al Te~, J. Te~, B1 18the label of the lnsta.nce, a.nd the prOpO8ltlon a.sshown is believed by the agent (denoted by writing the excl&m&otion following the label) as a.hypothesis (HYP).See [15, 13] for more details. The syntax of writing propositions is not IndiVlduals Yidua;t a.nd is defined by the "print-methods" of the Variables 4.5 Acta An act is a.mental concept of something tha.t can be performed by va.rioua actors at va.rioua times. This is also importa.nt for pla.n recognition (facilitating a pla.nsibleconclusion that an agent performing an act could be acting to fulfill some plan). By the Uniquenesa Principle, a. single act must be represented by a single object even if there are several different objects representing beliefs tha.t several different agents performed tha.t act at different times. Acts are represented by objects that are insta.ncesof the subd&88esof the cla.saJ.ct T.~. Acts can be primitive or complez (not shown in the figure). A primitive act ha.s a.neffectory procedural component which is executed when the act is performed. Complex acts have to be decomposed into pla.ns. Our present model of ~g. is based upon & statOo change model (see [14]). We Identify three types of state.- 93 -" "'=c.:c.~.c"c"-"~-",,~,"W"" u- soci&ted clasa. We are claiming that such object-centered representations are inherently ca.nonical in tha.t they ca.n be tr&nsl&ted into a.nother KR formalism simply by supplying a different print-method for ea.chclass. In fact, in [13] we have shown that the OK Formalism is isomorphic to a.sema.nticnetwork formalism, SNePS [22]. Insta.nces of the class Variable Te~ denote arbitrary conceptual entities-individu.a.1s, belie~, ,ac~s,.etc. Va.riabIes are useful for representmg genenc mdiVlduals (e.g., 'a. thing'); genera.! propositions (e.g., 'a t~g that is a. block'); generic propositions (e.g., 'something tha.t John believes'); a.nd generic acts (e.g., 'pick up a thing'). ~e have given special a.ttention to va.riablesthat represe~t mdefinite noun phrases a.nd a.nap~ora.tha.t models ,theIr use in uatura.!language understanding. We have arnved a.t a. non-a.tomic representa.tion of va.riables (also called '~",C. !ured variablel) [3: 4, 5].. The struct.ure of the. va.nable mcludes complex mtern&lized constra.m.u (that, mcludes, but is not limited to, the type of the entity a va.na.blemay be bou~d to) a.nd intem~ed qu.antifier structures. The sem,~tiC8 of str.ucture? v~ables 18 a.n au~ented (by the addition of arbltra.ry mdiVlduals) semantic theory baaed on [7, 22]. The use of such object-oriented va.ria.blesleads to much simpler representations for tasu &8 diap&rate as representing na.tural la.nguage sentences and operators in a planning formalism. Additionally, structured va.ria,bles ""' it [15]. Also, it ena.blesthe agent to store results ?f its in- I2, denote that ferencesin order to mm future recallsmore effiCIent.For ex&mple,a.ninstanceof a.nobject tha.t representsa proposition "A is a block" would be written a.s . . Named The clasa Iudi ... denote B1, B2, acts, a.nd V1. of propositions or via derivation. The instances representing propositions also contain information typically employed by a truthmaintena.nce system (TMS). In the OK architecture, we necessitate the presence of a. TMS because it facilitates severa.! advantages in the representation of actions a.nd pla.ns ISmthat denotemtenllona.!entitles m the domam of di&courseof the modeledagent. All instancesof this classare uniquelyidentified by a.label which is denotedby a.nuppercaseletter followedby a.number. The letters help identify the kind of entity represented.For ex&mple,E1, E2, ". representa.tions . Entities The clasa Concep-tual the OK Formalism. to have may not nec~y believe. Since all instanc,es of the clasa Conceptual Ent 1 ty Te~ are also terms, this enables the t t h '-_I' fs bo t t '--1: agen 0 ave ~e a. u IS own UC1lefs as w ell th Ole f h Th t ' ~'d '" 0 ot ers. e agen s lllll1 18 m odeled a.s a. se t 0 f f th ' E - -'- '- _I' f . t I.- " f uc Ie "pace.. 6'-'1l ~e space COnllS s 0 e propO6ltions believed by the agent either explicitly (hypotheses) _1 4.1 Propositions ~-~'""""C~~-'-..c ,~'"-~C~c._~,,",'"" -~,-~".~c~""~""c;"".-",,,,,,~-~"",. . . , Figure 1: The classhierarchyof the OK Formalism. !~ '" 94 - - . . '" ", , external world states, mental states (belie{ space), and in- c,: ..:f ..~: ;: ~ ;': 4.6 tentional states (agent's current intentions). Accordingly, we identify three classeso{ actions-phtt8ical actiom, mentallJction8, and control action., tha.t bring a.bout changes in their respective sta.tes. 4.5.1 .;,': In addition to standard beliefs that an agent is able to represent, we also define a. special claaa o{ beliefs called tramfonner8. A tramfonner is a. propositional representa.tion tha.t subsumes vanons notions o{ inference and acting. Being propositions, tra.nsformera can be asserted in the agent's belief space; they a.realso beliefs. In general, a. transformer is & pair ofentitie&--(a), (b», where both (a) and (b) can specify beliefs or acta. Thns, when both parts o{ & transformer specify beliefs, it represents a. reasoning rule. When one o{ ita pa.rta specifies beliefs and the other acts, it can represent either an act's preconditions, or its effects, or a. reaction to some beliefs, and so on. Wha.t & tra.nsformer represents is made explicit by specifying its pa.rta. When believed, tra.nsformers can be used during the acting/inference process, which is where they derive their na.me: they tra.nsform acts or beliefs into other beliefs or acts and vice versa. Trans{~~a.tions .can be, applied in forward. and/or backW:&r:d ~~~ fa.shion. U~g a.tra.nsformer m forward chammg 18eqwvalent to the mterpreta.-tion "aiter the agent believes (or intends to perform) (a), it believes (or intends to perform) (b).- The backwa.rdchAining interpretation o{ a.tra.nsformer is, "if the agent wants to believe (or know if it believes) or perform (b), it must first believe (or see if it believes) or per:rorm (a),- There are some tra.nsformers tha.t can be used m forward as well backward cha.ining, while others may be used ouly in { th .3,- t ' .3- upon th e s}""-".c ---=~ one 0 ose uuec IOns. T 1.'W8 depenua ' , prOpo&1tlon represented by the tra.ns{ormer and whether . Physical Acta Physical acts a.redomAin-specific acts that a.ff.ectthe outside world, For exa.mple, if the &gent has an arm and is asked to pick up an object, the arm actua.lly moves to the object, gras~ it, and then lifts it up. DepeDding on the set o{ interfaces provided to the agent we need corespondmg a.ctua.torsto enable the carrying out the action in the external world. This is done by specifying the effectory component of the action by writing procedures tha.t access the actua.tor interface. PICXUPis a. physical action in a. blockswo~ld, For exa.mple, the, act, o{ picking u? a. ~lock c;': !': ,d: J;; na.med A 18represented as an object matance tha.t 18wntten ;' as .: ;' ~.. ," Ai: PICXUP(A) - (~ 4.5.2 f ! ~ i ( Mental Acts . ,as Beliefs of the a.gent may change when actIOns are per- ed ' r . ' ed We ha.ve BELIEVE .orm or an m.erence 18 CaIn out, d DISBELIEVE tal t ' h b' t 1. an a.s men ac IOns w ose 0 Jec s are DeIi fs S I - .3 din d ' , , fr h e, imp y g an remoVIng propO8ltlons om t e b . , beIi . elief-space the danger of space m' t t Tposea 1.:-' , all t lea.vmg h the all d e{ ' ed b -': fs conS18en. W8 18 especl y rue w en env elle I: r ., " '" (~- . ;: ;;c ,: 'li-ansformers I t has ' h 3' h any mea.nlng w en woeu m t e a.ve lOur types of tra.nsformers-t I.- I ' & ac , a.realso added to the belief space, The presenceof a.TMS solves this problem, Typica.lly, TMSs provide explicit opera.tions for adding and deleting new beliefs to and from a. belief space. These opera.tions, in a.ddition to the &8, , , , , . sertmg/deletmg propOSltlons, '"perform con81Btency checks In order to belief space, TMS h resultmg 4' Th ' h guarantee a{ cons18tent us, m t e presence0 a. , t e elLectory components , , , o{ the two mental actIons should be lInplemented usmg the , .., a.ppropna.te opera.tlons,t ' This th t d dTMS STRIPS [8] stra.tegy implements e ex en e allump Ion, -~ Control . . lUlL --'- 0 enve new ellelB. For r exa.mpIe, a.cl&880f t ranslormers th at represent ant ecedentt ul ' alled l_ tC t .t W e use th e consequen r es 18c A'-l q ranslormers. w as Ion m.erence t t' no a Ion Acts (Plans) - (b) to write them. For exa.mple "All blocks are supports- is represented as Plans, in our ontology, are also conceptua.l entities. How- B1!:Vx[I,a(x,BLOCI) - Isa(x,SUPPORT)] a.realso act&-albeit control acts. Control acts, when performed, change the &gent's intentions a.bout carrying out acts, Our repertoire o{ control actions includes .equencing (for representing linear plans), conditional, iteratil1e, diljunctive (equivalent to the OR-splits of the Procedura.l Net formalism [19, 23]), conjunctilJe (AND-splits), 8electil1e,and achiel1eacts (for goal-based plan invoca.tion). These a.resummarized in Ta.ble 1, These control acts are capa.ble o{ representing moat o{ the systems existing (and pla.nmore). structures found in tra.ditiona.l planning In addition to the connective a.bove(which is also ca.lled an or-entailment), our current vocabulary o{ connectives includes and-entailment, numerical-enta.ilment, andor, thresh, and non-derivable. Other quantifiers include the existentia.l, and the numerical quantifiers (see [21]), Given the object-oriented design of the architecture one can define any additional cla.sseso{ connectives depending on their own logical commitments, We should empha.size,once agAin, tha.t since plans are also conceptual entities (and represented in the aame formalism) they can be represented, reasoned a.bout, diacuaaed, as well as followed by an &gent modeled in this architecture. 4.6.2 Belief-Act Transformers These are tra.ns{ormers where (a) is a let o{ belie{(s) and (b) is a.let of acts. Used during backward cha.ining, these can be propositions specifying preconditions o{ actions, i.e. N ,.._~",.-,..'""'.~-c=;~-'"---~. belIef-belIef, 4.6.1 Bellef-Bellef Transformers Th t d d ' ul ( h ( ) ' ese are s an ar reasonIng r es were a 18 a. set 0{ an t ec eden t bell , a. set 0{ consequent be-': ef( s) and (b) 18 li e{( s)) Such r ules can be woeu3' m r10rwar,d b~wa.r, d as ell b .3'- ect' al ' r t d ' b-': r- ever,wewill not definea.separa.te cl&88 {or themasthey ... process, we belIef-act, le/JI and act-ac t. (a) 4.5.3 Chammg .' S. .- 0{ beliefs or an -.mce both (a ) an d (b) can be se~ h r ' , " ' . i~,c~ I. -:~ ntro - -~, '" - t OD t n '",. "', ;;; "~ ,," '~ SEQUElCE(a1' a2) DoOIE(a1,...,an) ~:: DoALL(a1'... ,an) IF«P1,a1),...,(Pn,an») of act ITERATE«p1,a1)'.'" (Pn, an)) ACHIEVE VITHSOKE(x,y,...)(p(x,y, ...),a(x,y,...)) VITHALL(x,y,...)(P(x,y,...),a(x,y,...» Example: VITUU(x)(Helcl(x). PUT(x. TABLE»i. the act of putting ODthe ~ble everything that is being held Ta.ble 1: Summa.ry of control actions (a) is a. precondition of some act (b). We will call it a PreconditionAct tra.nsformer and write it &8 a predica.te transformer is used during backwa.rd chaining to d~mpose the achieving of a goal (b) into a plan (a). For exa.mpIe, "A plan to achieve tha.t A is held is to pick it up" is represented &8 PreconditionAct«(a),(b») For exa.mple,the sentence "Before picking up A it must be clea.r" ma.y be represented &8 BS6!: PlanGoal(PICIUP(A),Held(A» B26! : PreconditionAct(Clear(i),PICIUP(i» Another backwa.rd chaining interpretation tha.t CAn be derived from this tra.nsformer is, "if the &gent wants to . .. Used d.u:mg f°rw.a.r~ chalnlng, th;se tr.a.nsformerscan be P~°Po.s1tlO~S sP«;ci£ymgthe &gent s demr:s to reac.t to certa.m SItuatIons, I.e. the agent, upon COmIngto believe (a) will form an intention to perform (b). We will call these VhenDotransformers a.nd denote them &8 know if it believes (b), it must perform DoVhen(LOOUT(A),Color(A, ?color» 4.6.4 For exa.mple,a general desire like "Whenever something is broken, fix it" ca.nbe represented &8 Transformers 5 -'Clear(i» The OK Rational Engine The OK R.a.tional Engine is u interpreter tha.t opera.tes on specific instuces of objects representing beliefs, tra.nsformers a.nd acts. In other words, it is the operational It ca.nalso be used in backwa.rd chaining during the plu generation process (cl&88ical pla.nning). The PlanGoal 96 - Transformers piling 18a complex act and the plan tha.t decomposesIt 18 expressedin the proposition I. B71. . PlanJ.ct(S~CE(Ptrr(B, TABLE),Ptrr(A,B», PILE(A,B» These a.rethe propositions specifying effects of actions &8 well as those specifying plus for achieving goals. They will be denoted ictEttect ud PluGoal tra.nsformers respec~ tivdy. The ActEttect tra.nsformer will be used in forwa.rd cha.ining to accomplish believing the effects of act (a). For example, the sentence, . After picking up A it is no longer clea.r~is represented &8 B30! : ictEttect(PICIUP(i), Act-Act These a.repropositions specifying plan decompositions for complex actions (called PlanAct tra.nsformers), where (b) is a complex act and (a) is a pla.n that decomposesit into simpler acts. For example, in the sentence, "To pile A on B first .involves put B on the table and ofthen A ononB"a (where p~ creating a. pile twoput blocks ta.~le), B100! : Vx[VhenDo(Broken(x),FIl(x)] Act-Belief (a),. which is rep- resented as a.DoVhentransformer. For exa.mple, "Look at A to find out its color" ca.n be represented &8 VhenDo«(a),(b» 4.6.3 :" / ; "" , ' ; C',c . - .-- - . ,- "7. -- , Ii' 11. '" t'.' c ~ !, ~ ~ ~ f. component of the a.rchitecture tha.t is responsible for pro- 6 ducing the modeled a.gent's reasoning a.nd ading behavior. It is specified by three types of methods (or messa.ges)- In ~ ~, f . B ~ ,. e Ie tie ser ~ - A me thod th a. t n.on al or querymg . a.re two be lied ca.n app t r- fi 0 Co purposes. version.-- beli ela or tl a&- th nsequen y where ~ the l agent's I. [ process p is a belief, of belief that ~ can be the It derived method belief, returns via denotes p, all forwa.rd in central idea I d the where p is a belief, cess of querying returns ; believed all the the by or via. backwa.rd ~ Intend- tha.t ta.k~ denotes act, a. the an ad Nelson a.gent either chaining inference/ading. a.rgument agent's It These when backward ue two methods a.pplied explicitly enable various tra.nsforma.- Send to first tw:o of belief 8ltiO:nal attitudes .Belle~e and Intend mg With the a.gent. can be ~ded a.nd quenes interpretations a.nd Tran..form!, These tra.ns!ormers for through plish.ed' [13] ods: We there re- Va.nOU8 Thus,. can have slots a.s the gether they BELIEVE sion form a.nd its facility for All simplifies the cific for cific these a(;ts the theory iza.tions of a.nd control to gene:al The systems the found action The agent's can acts) tha.t be specified will of intentionality the Intend method acts (to implement inherit its plan (and Thns, the intentions employed), sup-- don't, Actor view the (to- in for revi- rational A~tor to explore implem~nted a.rchitecture of computation. help cap~ure a.rchit~t:ure. m It the 18 our this m the future. the ru.dimentary a conventional, environ- out a.s some a.re simila.r (or Tra.nsformers overall hope In The of consid- a.s well lat~er AI because a.nd representational Vlew sya[12]. la.nguages. arises the Actor to implement Actor engine Only Building is probably primitives nsing uchitec- PLANNER ma.de is inher- of Actor-based for on This a.dequate some formali.&m the been softwa.re OK making to the of have. ha.ve commitmen~. be able represent a.- is used performing to the embedded tha.t we .would meanwhile, .components we of the. OK qu&8l-Concurrent paradigm. standud (i.e. in spe- this building agents method the Examples We started specialized) domain where 7 ing, paper integr&ted &Ie capable acting, by indic.ating rational that cognitive of naturalla.nguage reacting, and we were interested agenu. These interaction, knowledge acquisition reasonbehavior. spe- &8 special- "T.1 For acta). pable t of the work ob- systems. OK systems. goal of by the motivations Hewitt's ha.ve mes- difference in Actor that Actor original Labels determined is missing langu&ges. la.rge the PICIUP(J.) of concur- only a long-term attempts Actor build OK nature no actors. The to indicate Ca.rl sending be the ad Actor model is using the of &8 yet, to object [1, 2]. Like Actor systems, a.s a. ba.sis of computa.tion. that seems fact, out using ments of can be defined for mental the sema.ntia of respective ,. i the example, a.n integrated Intend method intentions by &8 inherited. accomplish a.s belief a.nd directly message, For . the objecta h&8 been da.te, conform) methods the be 'implemented In this we is a procedures such engine specific obfrom object a.nd something behavioral that of this came To a.nd DISBELIEVE effectory their behavior can 18 accom- The Believe by PICXUP(J.» receiver a.rchitectures the me.th- the example above could is very similar to the methods, tema a.gent to individual systems. capabilities support. the out message addre88e8. AI illustrating object ratio- to and identified. mail ture the a.nswer below specific by several &8 well (physical agent with of the Nevertheless b.ackcha.m- to explicitly in OK carried rational each denote ited usmg of all. the a.re implemented methods hiera.rchy Belle.tle! .. instanc~ er&tions BELIEVE have tions (see [15] for details). specify the fulfillment of ads. order underlying TMS). DISBELIEVE We w:orld the provides Each actions the usmg m be object- concurrent messag~ of the computation is employed the how will rent object-based message passing that ex~ernal ~o result inherently maintained mental procedures. TMS for and the This denote transform~rs ac~ ~ m Object conjun.ction exa.mples maintenance. as well B14318 jects architecture. also is updated propo- semantics descnptions sever.&! of the consistency J.n-tCq a query Believe? ~ethods 2 ~hows Kevery be of the receiVing PreconditionJ.c-t(?x. mteract- Notice to d? some uchitecture belief and deta.i1ed present in the Figure for ~onta.ms features The port D°:w'hen the a.re generated ~sed . Vla method. p~ble will ~hen progr~mm;ng. that should For ue message The by concurrent inference messages. self-contained .. implementation a.nd a.s the a user the s beliefs .abo:e. a.n wtent:on query. about cha.mmg Believe. .the It.18 formmg for the by s ~ef.space a.gent defined .a.igonthm in~ agent to mtention. ?eli~ methods~ lea.d to be. mvoked New to th.e ~rres~nd ~d can rega.rding tra.nsformers also &Ie proclaim la.ngua.ge viewed B143: . Believe? receiver and for &8 to methods sender sage itself. the The to that objecta comm~mC&ti°.n pro. tocol . orderly mteradions, which facilitate a.nd The is that Believe?(PreconditionAct(?x,PICIUP(J.») . that. _:1 a con- the spectively ~~tice entin~ .pth Y8lC a ~~orm sending correspond and Corresponding a.nd forwa.rd cha.ining vemonsTran.sform? system al to a.rchitecture. the invoca.tion to perform to tra.nsformers. ading instances each other. &Ie .. . a concurrent engine, ject object-oriented so far In (Intend(o» intention goes nature.- pro- BDI ground infer- p a.nd modeled [17] relating OK a perfect progra.mming of p. with ~ issues the h or oriented the Ita-ins unify be ca.n be Tran.sformtions tha.t &8 its modeled denotes usertional beliefs the it .ded present of a.ny .__1 0g1(;&1 beliefs chaining ~ two properties to nal Belietle(p)?- in a.re proVl tend the we Implementation a.n ence/acting. . ~ l",.. the aBserting space. ~ ,: ~ion, These Belietle(p)!- ~- , this Concurrency current represent ere ~ ~ Towards The instance, of Blowworld in the understanding Domain blocksworld the domain, following the a.gent ia ca.- paragraph: . --~ . 97. '" "i" Method ' BELIEVE.'(fI : Propo.ition Tenn; a- : Sub.titution := NIL) i. let 0 - fla- iJ ASSERTEDf(o) then return the .et {oJ eL.eiJPATTERNf(o) then ", . .. ;~ RESULT - a .et containingall a..erted in.tance. oj 0 ;; endiJ find the .et T oj applicableAntCq tranlJonnerl, i.e. let T - {t I fll ~ NIL 1\ BELIE VE.'(t) , wheret/11- UNIFY(CQ(t),o)} al.o find all the applicableDoWhentranlJonnerl, i.e., let T - T u {t I t/11 ~ NIL 1\ BELIEVE.'(t),wheret/11 - UNIFY(WHEN(t),o)} - Jor each t E T: loop RESULT RESULT u TRANSFORMf(t,t/1cJ endloop find the let oj matching propo.itionl, i.e., letB - {bI t/1b ~ NIL, 1Dhere t/1b -UNIFY(b,o)} " Jor each b E Bloop' RESULT+- RESULT U BELIEVEf(b, t/1b) endloop return RESULT end BELIEVEf Figure 2: The Believe? Method. See [13] for details of other methods. There is a.ta.ble. The ta.ble is a.support. BlockB a.re supports. A is a. block. B is a block. C is a. block. C is clea.r a.nd on the ta.ble. A is clea.r a.nd on the ta.ble. B is clea.r a.ndon the table. .. . .. . . ., PIcking up 18 a pnInltlve actIon. Putting 18 a. primitive action. Before picking up a. block the block must be clea.r. If a block is on a support then after picking up the block the block is not on the support. If a block is on a support then after picking up a block the support is clea.r. After picking up a. block the block is held. Before putting a.block on a support the block must be held. Before putting & block on a support the Notice tha.t the sentence describes a varla.ble tha.t is a block a.nd it is clea.r. The request is represented using the VITHSOME act as VITHSOKE(x)((Isa(x,BLOCK)1\ Clear(x», PICIUP(x») Structured varla.blesca.n also be used to represent luch actioDS. The agent in ca.rrying out the intention of picking up a. clea.r block determines all the blockB tha.t a.re clea.r a.nd picks up one of them. In a situation where, say, the blockB A, B, C a.reclea.r, the agent will respond The designator Is8.(x, BLOCK)1\ Clear(x) is effective on the following Isa(A,BLOCK)1\ Clear(1) Isa(B, BLOCK)1\ Clear(B) Isa(C, BLOCK)1\ Clear(C) for the act VITHSOKE(x)«(Isa(x,BLOCK)1\ Clear(x), PICIUP(x)) support must be clea.r. After putting a. block on a.support the block is clea.r. After putting & block on & support the block is on the support. After putting a block on a.nother block the la.tter block is not clea.r. A pla.n to achieve that a block is held is to pick up the block. A pla.n to achieve tha.t a. block is on a.support is to put the block on the support. If a block is on a support then a.pla.n to achieve I intend to do DoolE(PICKUP(1), PICIUP(B), PICIUP(C)) that the support is clea.r is to pick up the block a.nd then put the block on the ta.ble. PICKUP (C) Chose to do the act i' '¥ :; low doing: BELIEVE(Beld(C» PICIUP(C) The agent pa.rsesto therepresent a.bove sentences uses perform the formalism described them. It a.nd can then actions in the blocksworld using the information provided' DISBELIEVE(Clear(C» DISBELIEVE(On(C TABLE» in these sentences. It is also capable of carrying out reo quests like Next, let us &88umethat in addition to the knowledge described in the pa.ragraphs above, the agent also believes Pick up a clear block. 1. l' ,~ :: : . " 98 111 red colored blocks are wooden. ~ _0. ... . ., 2. Look is a priaitiTe action. 3. It you want to know the color t .t a J. . to go to the Eastern Hills you should take Maple. M~l? Why1 taking Maple avoids heavy tratfic. Why? since taking Kaple there are tewer businesses than taking Sheridan ..,.' By modeling the discourse WIth liB evolvmg iext plAn, IDP can produce concise text iha.t does not repeat old information along with the new. These types of interactions At this point, the agent knows thai J. is a. block but has no beliefs a.bout ita colors. The query will backcha.in as follows: I wonder if Isa(A, WOODD) a.r.ecoherent a.ndcoliabora.iivebecauseeach participa.ni I wonder if Isa(J., BLOCI) I know Isa(A, BLOCI) I wonder it Color(A, RED) knows how his contribution fits in. Levelt refers to this diacourse property as ducour8e deizir [16]. Consistent with the Gricea.n Ma.xims [9], IDP proceB&esfeedback with the idea that the more the user says, the more he feels he needs to say for the system to identify the text pla.n expansion that is sought. Therefore, IDP uses a.ny additional information that the user provides to try to recognize & text plan. This can lead to text plan expansions th&t &Ie not immediate continuations of what the system s&id last. The following exa.mpledemonstra.tes this type of processing: User: Should I take Maple or Sheridan The query has backcha.ined through (1) above. next it backchaoins through (3), First, it derives the specific tra.neformer DoWhen(LOOUT(A), Color(J., ?color» which is then applied and the act LOOUT(A) is performed. As a.result (a.ssumingthat A is colored red), the belief Color(!, RED) to go to the Eastern Hills Mall? take Maple. Why not go on Sheridan? you could take Sherida.n however, taking Maple avoids heavy trattic. In this interaction the user's feedback indicates th&t he would like the sy;tem's response to include information about the feasibility of an alternative route. IDP uses the mentioned act, go-ing on Sheridan, to identify a.discourse entity a.nd a text plan expansion that uses it. This is how IDP continues to pursue its own intentions while providing the implicitly requested information. IDP can also detect IDP: User: IDP: is added to the agent's belief space which completes the earlier chaoinof inference and returns the &Il8wer (that A is wooden). Thus we see thai it is also possible for inference to lead to actions. Similarly, one can forward chain t?rough WhenDotransformers in, order to re~ to sit~&tIO~S. The above e,xa.mplehas illustr&ted ~ mterestmg ar~ifact of o~r a.r~tectur.e--th&t an agent 18,ca.pa.ble.of usm~ actmg ~ semce of mference .as well as ~ference ~ serVIceof ~tmg (~nly the latter bemg the typiCal case m most plannmg/actmg systems). 7.2 Planning Discourse to Discuss user-imposed digressions: User: Should I take Maple or Sheridan to go to the Eaatern Hills K~l? IDP: take Maple. User: Why should I take Maple? IDP: taking Maple avoids heavy trattic. User: Why? IDp. taking Maple there are fewer businesses than taking Sheridan. Plans , . We ~e modelin~ a.nagen~that,is capa~le of descnbmg and Justif~g domaIn pl&Il8 m an In;terac.tlvenatural language settmg [10, 11]. The Interactive Discourse Pla.nner (IDP) relates two areas of resea.rch. The first a.rea, plan recognition, focuses on analyzing naturalla.nguage that is about plans to recognize the speaker'~ intent a.nd p~ovi~e ~ ; helpful respo.nses.!he second a.rea,di,scoursepla.nnmg~18 concerned WIth u8,ng pla.ns for selectmg a.nd opera~es strudurmgin text that ac,hieves co~muni.ca.tive goals. I~P " speaker and the user is the primary liatener. IDP is respon- . User: IDp. . a. collaborative mode m which the system 18 the pnmary " : IDP: IDP: User: IDP: Is A wooden? ; Should I take Maple or Sheridan .. User: If the a.gentis then asked the query: , U~: ot a block look Whyia there heavy trattic now? * since now is rush hour aa I was saying, tak~ Maple aToids. heavy tratfic. ,.' sible for pla.nning text to describe and/or justify a.doma.in pla.n, a.nd the user is responsible for providing feedback tha.t lets IDP know how to continue the discussion in a. way tha.t is helpful. , . . . The ~r s third question (marked WIth a.nastens,k, ) relies on a.n mferenc~ t~at he made from the propOSltl~n that IDP conveyed m liB second response. IDP uses Its text pla.n to detect that this question, unlike the user's first two questiona, initiates a digression. The system makes this determination when it cannot find a wa.yof expa.nding the focussed portion of ita ten pla.n to &Il8wer it. When IDP detects a user-imposed digreaaion,it &Il8wersthe que&tion, and then it immediat.e1ygoes back to pursuing to ita own intention by expanding is texi plan further. In these examples thai intention is to have the user adopt the plan of iaking the Maple Road route. As demonstrated by the lui two lines of IDP's final response, the uniform repre- IDP exploits the OK formalism by using a uniform representation for the text plan that it formnlates a.nd executes incrementally, and the doma.in pl&Il8 thai are under discuaaion. In this way, the text plan a.ndthe doma.in plans a.reboth accessiblefor analyzing the user's feedback. IDP can interpret vaguely articulated feedback, generate concise replies a.nd metacommeniB, and detect user feedback that initiates a. digresaion. AB a tesibed for our model, IDP diacuaseadriving routes u the domain plans. . l I 99 I - .~-~-~" ~~ ~ntation that is used for all information allows IDP to u.e Its own text plan .. content to do this. 7.3 Structured Variables Our system is capable of natural language processing uain~ structured variables. It includes a generalized augmented'" transition network (GATN) natural language parser and generation component linke'd up to the knowledge base (bued on [20]). A GATN grammar specifies the tra.nalation/generation of sentences involving complex noun phrases into/from structured varil.ble representl.tions . An advantage of the use of structured variables lies in the representation and generation of complex no~n phr~ that involve restrictive relative clause complements. Tke ~estriction set of a structured variable typically consists of a. type constraint along with property constraints (adjectlves) and other more complex constraints (restrictive rei&tive clause complements). So, when parsing I. noun phrase, all processing is localized and &88Ociatedwith building its structured variable representation. When generating a surface noun phrase corresponding to the structured variable, all constraints &88Oclatedwith the variable are part of its structure and can be collected and processed euily. T.his is in contrast to non-structured variable repr~ sentatlons (such as FOPL) where the restrictions on variabies are dis&880cia.tedfrom the variables themselves in the antecedents of rules. The interaction below shows .:entences with progressively more complex noun phrases being used. These noun phr&lel are uniformly represented using structured variables. Parsing and generation of these noun phr&lel is simplified beca.usestructured variables collect all relevant restrictions on a variable into one unit a structured variable (user input is shown italicized).' : Every man own. a car I understand that every aan ovna soae car. : Every ~oung man own, a car I understand that every young aan ovna soae car. : Every voung man that love. a girl own, a car that i. .port~ I understand that every young aan that loves any girl ovna S08e sporty car. : Every ~oung man that love. a girl that own. a dog own. a red car that i. .port~ I understand that every young aan that loves any : Every ~oung man that love. a girl and that i. happ~ girl that ovna any dog ovna soae red sporty .. .. rated from the variables in the antecedents of rules involving these variables. This is not the case in a structured variable representation. D__. ~use the structure of representatwns of rules using s~ructured variables is '"fiat", that is, there is not the arlmClal antec:edent-consequentst~ctur.e ~at,ed with firstorder.loglc-based representatIons, It 11 ~ble to frame questIons whose a.nswersare rules and not Jnst ground formul... ~ause of the subsumption relation ?etween structured vanables (a more gener~, or lell.restncted, ~able subsumes another more restncted vanable) , u.eful mferences are possible, directly. Since the structure of the question will mirror the structure of the rule any rule thl.t is subsumed by I. question is an answer to ihat question. What follows is a sample dialog involving questions whose a.nswersare ground propositions (e. g., I. John mortal) as well .. questions whose answers a.re rules (e. g., Who i. mortal): . : Every man ,. mortal I unders:and that every aan is aortal. : Who ,. mortal Every aan ~s aortal. : I. anfJ nch man mortal Tes, eve~ rich aan is aortal. : John ,. a man I understand that John is a aan. : I. John mortal Yes, Jo~ is aortal. : Who ,. mortal John is aortal and every rich aan is aortal and every aan is aortal. : Are all rich voung men that own .ome car mortal Yes, every young rich aan that owns soae car is aortal. : AnfJ rich ~oung man that own. an~ car i. happ~ I understand that every young rich aan that ovna any car ia happy. : I. John happ~ I don't knov. : Young rich John own. a car I understand that aortal rich young John ovna soae car. : Who OtDn.a car Mortal rich young John ovna soae car. : I. John happ~ car. Tes, own. a red .port~ car that wa.te. gcu I understand that every young happy aan that loves any girl owns soae sporty red car that v_tea g_. . aortal rich young John is happy. This dialog also illnstra.tes the uses of subsumption. Since we told the system Every man i. mortal, it follows that any more specifically constrained man (e. g., Every rich lIoung man that Oum6.ome car) must alao be mortal. Note that this a.nswer (a rule) follows directly by subsumption from a rule previously told to the system. This is another way in which rules may be answers to questions, in a representation using structured variables. The utility of structured variables is a pressing argument for the use of object-oriented design a.t all levels of an AI formalism. The parser parses the user's sentence and builds a representa.tion of the user input. The resulting representation is then passed to the generation component, which generates the output response (sometimes prefixed by the canned phrase I underatand that). Hnoun constraints varia.bles corresponding to the complex phraseson were repre- sentedusing first-order logic-basedrepresentations,then 8 Remarks it would be difficult to generate natural language noun phr&lel con:esponding .to these va.ria.b~es.This is beca.use We ha.vepresented a unified formalism for modeling com- the constramts on vana.bles would, likely, be well sepa.- puta.tional rational agents. In doing so, we have made ": co ;\ j : :} ! ;; ' ; ; '. 100 ~~ -", - .- . f , I ! f ; some ontological &8 well &8 semantic commitments. The object-oriented design of the forma.liam ena.bles a canonica.l representa.tion of entities. The architecture h&8 been specifically designed to be extendable-in its ontology, &8 well &8 the underlying logic and action theory. This is a direct benefit from the object-oriented design. One can easily extend the forma.liam by defining additional classes !. and/or subcluaes. The ra.tional enginecan be modified enceon Arlificialintelligence, Melboume,Austra.lia., by changing (or specia.lizing) ita methods. We ha.ve also November 1993. to a.ppea.r. f f ~ I brieily addressedthe pO88ibilityof implementinga concur- rent ra.tional engine. Finally, we presented several exa,mpIes from our work illustra.ting can be modeled. va.rious AI faculties that Acknowledgement ~ ~ tI~ All the work discussed in this pa.per W&8carried under the direction of Dr. Stua.rt C. Sha.piro.Our representa.. tiona.l commitments are a direct result of over two deca.des of work of Dr. Sha.piro and his associates on the SNePS semantic network processing system. [10] S. M. Haller. Interactive genera.tion of plan justifica.. Uona. In Proceeding. of the Fourth European Work.hop on Naturol Language Generation, pages 79-90, 1993. [11] S. M. Haller. An interactive model for plan explana.. tion. In Proceeding.. 01 the Au.rtralian Joint Con/er- . . . [12] C. HeWItt. Procedu.ral embedding of knowledge m planner. 1971. In Proceedlng.r 2nd IJCAi, pages 167-182, [13] Deepa.kKuma.r. From Belieft and Goal.t to intention. and Action.s- An Amalgamated Model of Acting and Infe~nce. PhD thesis, Sta.te University of New York a.t Buffalo, 1993. [14] Deepa.k Kuma.r and Stua.rt C. Sha.piro. Architecture of an intelligent agent in SNePS. SIGART Bulletin, 2(4):89-92, August 1991. [15] Deepa.k Kuma.randStua.rtC. Shapiro.Deductive ef- ~ j i References - [1] Gul Agh&. Concunen t Ob.ect Onen . ted ProgramJ ming. Communication.. 01 A aM, 33(9):125-141, 1990. t [ r t [2] ming Gul Agha Carl InHewitt. ProgramUsingand Actors. Amori Concurrent Yonezawa a.nd Mario Tokoro, editors, Object-Oriented Concun-ent Pro- gromming, pages 37-53. MIT Press, Cambridge, MA, 1987. [3] Syed S. All. A "Natural Logic. for Natural Language Proce..ing and Knowledge Rep~.entation. PhD thesis, State University of New York at Buffalo, Computer Science, 1993. Forthcoming. [16] W. J. M. Levelt. Speaking: From intention to Articulation. MIT Press" Cambridge 1989. [17] Micha.el L. Nelson. Concurrency &; Object-Oriented Programming. ACM SIGPLAN Notice., 26(10):6372, October 1991. [4] Syed S. All. A Structured Representation for Noun Phrasesand Anaphora.. In Proceeding. of the Fifteenth Annual Confe~nce of the Cognititle Science Society, pages 197-202, Hillsdale, NJ, June 1993. La.wrence [18] Anand S. Rao and Micha.el P. Georgeff. An Abstract Architecture for Rationa.l Agents. In Bemha.rd Nebel, Cha.rlesilich, a.ndWilliam Swartout, editors, Proceeding. of the 2nd Confe~nce on Principle. of Knowledge Rep~.entation and Rea.oning, pages 439-449, San Mateo, CA, 1992. Morgan Kaufmann Publishers. . [19] ~a.rl D. S~erdotl. A Structu~ fo,. Plan. and Behaulor. ElBeVlerNorth Holland, New York, NY, 1977. Erlba.um. [5] Syed S. All and Stua.rt C. Sha.piro. Natural La.nguage Processing Using a Propositional Semantic Network with Structured Variables. Mindl and Machine., 3(4), [20] S. C. Shapiro. Genera.li.zedaugmel1~edtranaition network grammars ~or generation from sem~tic n~two~kB;'The Amencan Journal of Computational Llnguutlc., 8(1):12-25, 1982. Nove~ber 1993. Special Issue on Kno,,:ledge Representatlon for Natural Language Proce881Dg. [6] Micha.el E. Bratma.n, David J. Isra.el, and Ma.rtha E. [21] S. C. Shapiro and The SNePS Implementation Group. SNePS-2 u.~,.'. Manual Depa.rtment of Computer Science, SUNY a.t Buffa.lo, 1989. Po~a.ck.Plans a.n~ Resource-~ounded Practical Rea.. sonmg. ComputatIonal IntellIgence, 4(4), 1988. [7] Kit Fine. Realoning with Arbitrory Blackwell, Oxford, 1985. ; , ficiency, belief revision and acting. Journal of Ezperimental Artificial Intelligence (JE( ) and Theo~tical F . "'A i) ,5 2 ,1993. orthcommg. Object.. Basil [8] Micha.el P. Georgeff. Planning. In Annual Retliew. 01 Computer Science Volume .2, pages 359-400. Annual Reviews Inc., Pa.lo Alto, CA, 1987. [9] H. P. Grice. Logic and conversation. In P. Cole and J. L. Morgan, editors, Syntaz and Semantic. 3: SpeechAct.. Academic Press, New York, 1975. [22] S. C. Shapiro a.ndW. J. Rapaport. SNePS considered &8 a fully intensional propoeitiona.l semantic network. In N. Cercone and G. McCalla., editors, The Knowledge Frontier, pages 263-315. Springer-Verlag, New York, 1987. [23] David E. Wilkins. Proctical Planning-Eztending the Clcu.ical AI Planning Paradigm. Morgan Ka.ufmann, Pa.lo Alto, CA, 1988.