:-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoke.e',40). :- call_pel_directive(translate(unskipped, '/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.pel')). :-include(library('ec_planner/ec_test_incl')). :-expects_dialect(ecalc). :- call_pel_directive(translate(begining, '/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.pel')). %; %; Copyright (c) 2005 IBM Corporation and others. %; All rights reserved. This program and the accompanying materials %; are made available under the terms of the Common Public License v1.0 %; which accompanies this distribution, and is available at %; http://www.eclipse.org/legal/cpl-v10.html %; %; Contributors: %; IBM - Initial implementation %; %; @article{Mueller:2004c, %; author = "Erik T. Mueller", %; year = "2004", %; title = "Understanding script-based stories using commonsense reasoning", %; journal = "Cognitive Systems Research", %; volume = "5", %; number = "4", %; pages = "307--340", %; } %; :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',22). % option modeldiff on :- call_pel_directive(option(modeldiff, on)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',24). % ignore Love, ThreatenedBy :- call_pel_directive(ignore(love)). :- call_pel_directive(ignore(threatenedBy)). % ignore LookOutOnto, Floor, BuildingOf, SkyOf, GroundOf :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',24). :- call_pel_directive(ignore(lookOutOnto)). :- call_pel_directive(ignore(floor)). :- call_pel_directive(ignore(buildingOf)). :- call_pel_directive(ignore(skyOf)). :- call_pel_directive(ignore(groundOf)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',26). % ignore Near, WalkFrom, WalkFromTo, RunFromTo :- call_pel_directive(ignore(near)). :- call_pel_directive(ignore(walkFrom)). :- call_pel_directive(ignore(walkFromTo)). :- call_pel_directive(ignore(runFromTo)). % ignore Side1, Side2 :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',26). :- call_pel_directive(ignore(side1)). :- call_pel_directive(ignore(side2)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',29). % load foundations/Root.e :- call_pel_directive(load('foundations/Root.e')). % load foundations/EC.e :- call_pel_directive(load('foundations/EC.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',31). % load answers/Mueller2003/Ontology.e :- call_pel_directive(load('answers/Mueller2003/Ontology.e')). % load answers/Mueller2004c/RTSpaceM.e :- call_pel_directive(load('answers/Mueller2004c/RTSpaceM.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',33). % load answers/Mueller2004c/OTSpaceM.e :- call_pel_directive(load('answers/Mueller2004c/OTSpaceM.e')). % load answers/Mueller2004c/Container.e :- call_pel_directive(load('answers/Mueller2004c/Container.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',35). % load answers/Mueller2003/Sleep.e :- call_pel_directive(load('answers/Mueller2003/Sleep.e')). % load answers/Mueller2004c/SmallFire.e :- call_pel_directive(load('answers/Mueller2004c/SmallFire.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',37). % load answers/Mueller2004c/Smoke.e :- call_pel_directive(load('answers/Mueller2004c/Smoke.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',39). % location Location1 t(location,location1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',41). % portal DummyPortal1 t(portal,dummyPortal1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',43). % agent Smoker1 t(agent,smoker1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',45). % cigarette Cigarette1 t(cigarette,cigarette1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',47). % container Package1 t(container,package1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',49). % physobj Surface1 t(physobj,surface1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',51). % physobj LightingDevice1 t(physobj,lightingDevice1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',53). % ashtray AshTray1 t(ashtray,ashTray1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',55). % physobj Trash1 t(physobj,trash1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',57). % smoke Smoke1 t(smoke,smoke1). %; prune % sort ona, onb :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',59). sort(ona). sort(onb). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',61). % fluent! On(ona,onb) fluent(on(ona,onb)). % event! PlaceOn(agent,ona,onb) event(placeOn(agent,ona,onb)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',63). % event! TakeOffOf(agent,ona,onb) event(takeOffOf(agent,ona,onb)). % ona! LightingDevice1, Package1, Cigarette1 t(ona,lightingDevice1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',63). t(ona,package1). t(ona,cigarette1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',65). % onb! Surface1, AshTray1 t(onb,surface1). t(onb,ashTray1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',67). % sort insidea, insideb sort(insidea). sort(insideb). % fluent! Inside(insidea,insideb) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',67). fluent(inside(insidea,insideb)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',69). % event! PutInside(agent,insidea,insideb) event(putInside(agent,insidea,insideb)). % event! TakeOutOf(agent,insidea,insideb) event(takeOutOf(agent,insidea,insideb)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',71). % insidea! Cigarette1 t(insidea,cigarette1). % insideb! Package1, Trash1 t(insideb,package1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',71). t(insideb,trash1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',74). % sort lighta, lightb, lightc sort(lighta). sort(lightb). sort(lightc). % event! LightWith(lighta,lightb,lightc) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',74). event(lightWith(lighta,lightb,lightc)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',76). % lighta! Smoker1 t(lighta,smoker1). % lightb! Cigarette1 t(lightb,cigarette1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',78). % lightc! LightingDevice1 t(lightc,lightingDevice1). %; initial state % [agent,object] % !HoldsAt(Holding(agent,object),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',80). holds_at(not(holding(Agent,Object)),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',82). % [agent,physobj] % !HoldsAt(SittingOn(agent,physobj),0). holds_at(not(sittingOn(Agent,Physobj)),0). % [agent,physobj] % !HoldsAt(LyingOn(agent,physobj),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',82). holds_at(not(lyingOn(Agent,Physobj)),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',84). % HoldsAt(On(Package1,Surface1),0). holds_at(on(package1,surface1),0). % [physobj1,physobj2] % !(physobj1=Package1 & physobj2=Surface1) -> % !HoldsAt(On(physobj1, physobj2),0). not((Physobj1=package1, Physobj2=surface1)) -> holds_at(not(on(Physobj1, Physobj2)), 0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',88). % HoldsAt(Dressed(Smoker1),0). holds_at(dressed(smoker1),0). % HoldsAt(Awake(Smoker1),0). holds_at(awake(smoker1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',90). % HoldsAt(Sleep3(Smoker1),0). holds_at(sleep3(smoker1),0). % HoldsAt(Standing(Smoker1),0). holds_at(standing(smoker1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',92). % HoldsAt(CraveNicotine(Smoker1),0). holds_at(craveNicotine(smoker1),0). % HoldsAt(ContainerClosed(Package1),0). holds_at(containerClosed(package1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',94). % [physobj] % !HoldsAt(IsBurning(physobj),0). holds_at(not(isBurning(Physobj)),0). % HoldsAt(Inside(Cigarette1,Package1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',94). holds_at(inside(cigarette1,package1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',96). % [physobj1,physobj2] % !(physobj1=Cigarette1 & physobj2=Package1) -> % !HoldsAt(Inside(physobj1, physobj2),0). not((Physobj1=cigarette1, Physobj2=package1)) -> holds_at(not(inside(Physobj1, Physobj2)), 0). %; narrative :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',101). % Happens(TakeOffOf(Smoker1,Package1,Surface1),0). happens_at(takeOffOf(smoker1,package1,surface1),0). % Happens(ContainerOpen(Smoker1,Package1),1). happens_at(containerOpen(smoker1,package1),1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',103). % Happens(TakeOutOf(Smoker1,Cigarette1,Package1),2). happens_at(takeOutOf(smoker1,cigarette1,package1),2). % Happens(PickUp(Smoker1,LightingDevice1),3). happens_at(pickUp(smoker1,lightingDevice1),3). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',105). % Happens(Light(Smoker1,LightingDevice1),4). happens_at(light(smoker1,lightingDevice1),4). % Happens(LightWith(Smoker1,Cigarette1,LightingDevice1),5). happens_at(lightWith(smoker1,cigarette1,lightingDevice1),5). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',107). % Happens(BlowOut(Smoker1,LightingDevice1),6). happens_at(blowOut(smoker1,lightingDevice1),6). % Happens(PlaceOn(Smoker1,LightingDevice1,Surface1),7). happens_at(placeOn(smoker1,lightingDevice1,surface1),7). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',109). % Happens(PlaceOn(Smoker1,Package1,Surface1),8). happens_at(placeOn(smoker1,package1,surface1),8). % Happens(Puff(Smoker1,Cigarette1),9). happens_at(puff(smoker1,cigarette1),9). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',111). % Happens(BlowOutSmoke(Smoker1,Smoke1),10). happens_at(blowOutSmoke(smoker1,smoke1),10). % Happens(PlaceOn(Smoker1,Cigarette1,AshTray1),11). happens_at(placeOn(smoker1,cigarette1,ashTray1),11). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',113). % Happens(TakeOffOf(Smoker1,Cigarette1,AshTray1),12). happens_at(takeOffOf(smoker1,cigarette1,ashTray1),12). % Happens(Puff(Smoker1,Cigarette1),13). happens_at(puff(smoker1,cigarette1),13). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',115). % Happens(PutOut(Smoker1,Cigarette1),14). happens_at(putOut(smoker1,cigarette1),14). % Happens(PutInside(Smoker1,Cigarette1,Trash1),15). happens_at(putInside(smoker1,cigarette1,trash1),15). % range time 0 16 :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',117). :- call_pel_directive(range(time, 0, 16)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',119). % range offset 0 0 :- call_pel_directive(range(offset, 0, 0)). % range diameter 0 0 :- call_pel_directive(range(diameter, 0, 0)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.e',122). % completion Happens :- call_pel_directive(completion(happens_at)). %; End of file. :- call_pel_directive(translate(ending, '/pack/logicmoo_ec/ext/ec_sources/ecnet/Smoking.pel')).