:-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/ReadingALetter.e',117). :- call_pel_directive(translate(unskipped, '/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.pel')). :-include(library('ec_planner/ec_test_incl')). :-expects_dialect(ecalc). :- call_pel_directive(translate(begining, '/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.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:InPress, %; author = "Erik T. Mueller", %; year = "in press", %; title = "Modelling space and time in narratives about restaurants", %; journal = "Literary and Linguistic Computing", %; } %; %;sort boolean %;sort integer %;reified sort predicate %;reified sort function %; %;sort time: integer %;sort offset: integer %; %;reified sort fluent %;reified sort event %; %;predicate Happens(event,time) %;predicate HoldsAt(fluent,time) %;predicate ReleasedAt(fluent,time) %;predicate Initiates(event,fluent,time) %;predicate Terminates(event,fluent,time) %;predicate Releases(event,fluent,time) %; %;sort diameter: integer %; %;sort object %; %;sort agent: object %; %;sort physobj: object %;sort bed: physobj %;sort snowflake: physobj %;sort sky: physobj %; %;sort stuff: physobj %; %;sort surface: physobj %;sort ground: surface %; %;sort snow: stuff %;sort ball %; %;sort food: physobj %;sort fruit: food %;sort orange: fruit %;sort salad: food %; %;sort clothing: physobj %;sort scarf: clothing %;sort hat: clothing %; %;sort vegetablematter: physobj %;sort coal: vegetablematter %; %;sort bodypart: physobj %;sort hand: bodypart %; %;sort papertowels: physobj %;sort device: physobj %;sort electronicdevice: device %;sort lamp: electronicdevice %; %;sort cat: physobj %; %;sort weapon: physobj %;sort gun: weapon %;sort bomb: weapon %;sort bullet: weapon %; %;sort location %;sort room: location, outside: location %; %;sort portal %;sort door: portal, staircase: portal %;sort street: portal %; %;sort building %; %;sort fire: object %; %;sort furniture: physobj %;sort chair: furniture %;sort table: furniture %; %;sort menu: physobj %;sort bill: physobj %; %;sort script %; :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',103). % fluent Holding(agent,physobj) fluent(holding(agent,physobj)). % event PickUp(agent,physobj) event(pickUp(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',105). % event LetGoOf(agent,physobj) event(letGoOf(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',107). % [agent,physobj,time] % Initiates(PickUp(agent,physobj),Holding(agent,physobj),time). initiates_at(pickUp(Agent,Physobj), holding(Agent,Physobj), Time). % [agent,physobj,time] % Happens(PickUp(agent,physobj),time) -> % {location}% % HoldsAt(At(agent,location),time) & % HoldsAt(At(physobj,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',111). exists([Location], (happens_at(pickUp(Agent, Physobj), Time)->holds_at(at_loc(Agent, Location), Time), holds_at(at_loc(Physobj, Location), Time))). % [agent,physobj,time] % Terminates(LetGoOf(agent,physobj),Holding(agent,physobj),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',117). terminates_at(letGoOf(Agent,Physobj), holding(Agent,Physobj), Time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',119). % [agent,physobj,time] % Happens(LetGoOf(agent,physobj),time) -> % HoldsAt(Holding(agent,physobj),time). happens_at(letGoOf(Agent, Physobj), Time) -> holds_at(holding(Agent, Physobj), Time). % [agent,physobj,location,time] % Releases(PickUp(agent,physobj),At(physobj,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',124). releases_at(pickUp(Agent,Physobj), at_loc(Physobj,Location), Time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',126). % [agent,physobj,location,time] % HoldsAt(Holding(agent,physobj),time) & % HoldsAt(At(agent,location),time) -> % HoldsAt(At(physobj,location),time). holds_at(holding(Agent, Physobj), Time), holds_at(at_loc(Agent, Location), Time) -> holds_at(at_loc(Physobj, Location), Time). %;[agent,physobj,location1,location2,time] %;HoldsAt(At(agent,location1),time) & %;location1!=location2 -> %;Terminates(LetGoOf(agent,physobj),At(physobj,location2),time). % [agent,physobj,location,time] % HoldsAt(At(agent,location),time) -> % Initiates(LetGoOf(agent,physobj),At(physobj,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',136). holds_at(at_loc(Agent, Location), Time) -> initiates_at(letGoOf(Agent, Physobj), at_loc(Physobj, Location), Time). % fluent On(physobj,physobj) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',139). fluent(on(physobj,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',142). % event PlaceOn(agent,physobj,physobj) event(placeOn(agent,physobj,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',144). % event TakeOffOf(agent,physobj,physobj) event(takeOffOf(agent,physobj,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',146). % [physobj1,physobj2,time] % HoldsAt(On(physobj1,physobj2),time) -> % physobj1!=physobj2. holds_at(on(Physobj1, Physobj2), Time) -> Physobj1\=Physobj2. % [physobj1,physobj2,time] % HoldsAt(On(physobj1,physobj2),time) -> % !HoldsAt(On(physobj2,physobj1),time). holds_at(on(Physobj1, Physobj2), Time) -> holds_at(not(on(Physobj2, Physobj1)), Time). % [agent,physobj1,physobj2,time] % Initiates(PlaceOn(agent,physobj1,physobj2), % On(physobj1,physobj2),time). initiates_at(placeOn(Agent,Physobj1,Physobj2), on(Physobj1,Physobj2), Time). % [agent,physobj1,physobj2,time] % Terminates(PlaceOn(agent,physobj1,physobj2), % Holding(agent,physobj1),time). terminates_at(placeOn(Agent,Physobj1,Physobj2), holding(Agent,Physobj1), Time). % [agent,physobj1,physobj2,time] % Happens(PlaceOn(agent,physobj1,physobj2),time) -> % HoldsAt(Holding(agent,physobj1),time) & :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',163). % {location}% % HoldsAt(At(agent,location),time) & % HoldsAt(At(physobj2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',165). exists([Location], (happens_at(placeOn(Agent, Physobj1, Physobj2), Time)->holds_at(holding(Agent, Physobj1), Time), holds_at(at_loc(Agent, Location), Time), holds_at(at_loc(Physobj2, Location), Time))). % [agent,physobj1,physobj2,time] % Terminates(TakeOffOf(agent,physobj1,physobj2), % On(physobj1,physobj2),time). terminates_at(takeOffOf(Agent,Physobj1,Physobj2), on(Physobj1,Physobj2), Time). % [agent,physobj1,physobj2,time] % Initiates(TakeOffOf(agent,physobj1,physobj2), % Holding(agent,physobj1),time). initiates_at(takeOffOf(Agent,Physobj1,Physobj2), holding(Agent,Physobj1), Time). % [agent,physobj1,physobj2,location,time] % Releases(TakeOffOf(agent,physobj1,physobj2), % At(physobj1,location), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',178). releases_at(takeOffOf(Agent,Physobj1,Physobj2), at_loc(Physobj1,Location), Time). % [agent,physobj1,physobj2,time] % Happens(TakeOffOf(agent,physobj1,physobj2),time) -> % HoldsAt(On(physobj1,physobj2),time) & :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',183). % {location}% % HoldsAt(At(agent,location),time) & % HoldsAt(At(physobj1,location),time) & % HoldsAt(At(physobj2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',185). exists([Location], (happens_at(takeOffOf(Agent, Physobj1, Physobj2), Time)->holds_at(on(Physobj1, Physobj2), Time), holds_at(at_loc(Agent, Location), Time), holds_at(at_loc(Physobj1, Location), Time), holds_at(at_loc(Physobj2, Location), Time))). % [agent,physobj1,physobj2,location,time] % Releases(PlaceOn(agent,physobj1,physobj2), % At(physobj1,location), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',191). releases_at(placeOn(Agent,Physobj1,Physobj2), at_loc(Physobj1,Location), Time). % [physobj1,physobj2,location,time] % HoldsAt(On(physobj1,physobj2),time) & % HoldsAt(At(physobj2,location),time) -> % HoldsAt(At(physobj1,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',196). holds_at(on(Physobj1, Physobj2), Time), holds_at(at_loc(Physobj2, Location), Time) -> holds_at(at_loc(Physobj1, Location), Time). % fluent At(object,location) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',199). fluent(at_loc(object,location)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',202). % [object,time] % {location} % HoldsAt(At(object,location),time). exists([Location], holds_at(at_loc(Object,Location),Time)). % [object,location1,location2,time] % HoldsAt(At(object,location1),time) & % HoldsAt(At(object,location2),time) -> % location1=location2. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',206). holds_at(at_loc(Object, Location1), Time), holds_at(at_loc(Object, Location2), Time) -> Location1=Location2. % function Side1(portal): location :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',209). function(side1(portal),location). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',211). % function Side2(portal): location function(side2(portal),location). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',213). % fluent NearPortal(object,portal) fluent(nearPortal(object,portal)). % noninertial NearPortal :- call_pel_directive(noninertial(nearPortal)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',216). % [object,portal,time] % HoldsAt(NearPortal(object,portal),time) <-> % {location}% % (Side1(portal)=location| % Side2(portal)=location) & % HoldsAt(At(object,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',218). exists([Location], (holds_at(nearPortal(Object, Portal), Time)<->(side1(Portal)=Location;side2(Portal)=Location), holds_at(at_loc(Object, Location), Time))). % event WalkThroughDoor12(agent,door) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',222). event(walkThroughDoor12(agent,door)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',224). % event WalkThroughDoor21(agent,door) event(walkThroughDoor21(agent,door)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',226). % [agent,door,time] % Happens(WalkThroughDoor12(agent,door),time) -> % HoldsAt(Standing(agent),time) & % HoldsAt(At(agent,Side1(door)),time). happens_at(walkThroughDoor12(Agent, Door), Time) -> holds_at(standing(Agent), Time), holds_at(at_loc(Agent, side1(Door)), Time). % [agent,door,time] % Happens(WalkThroughDoor21(agent,door),time) -> % HoldsAt(Standing(agent),time) & % HoldsAt(At(agent,Side2(door)),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',232). happens_at(walkThroughDoor21(Agent, Door), Time) -> holds_at(standing(Agent), Time), holds_at(at_loc(Agent, side2(Door)), Time). % [agent,door,location,time] % Side2(door)=location -> % Initiates(WalkThroughDoor12(agent,door),At(agent,location),time). side2(Door)=Location -> initiates_at(walkThroughDoor12(Agent, Door), at_loc(Agent, Location), Time). % [agent,door,location,time] % Side1(door)=location -> % Initiates(WalkThroughDoor21(agent,door),At(agent,location),time). side1(Door)=Location -> initiates_at(walkThroughDoor21(Agent, Door), at_loc(Agent, Location), Time). % [agent,door,location,time] % Side1(door)=location -> % Terminates(WalkThroughDoor12(agent,door),At(agent,location),time). side1(Door)=Location -> terminates_at(walkThroughDoor12(Agent, Door), at_loc(Agent, Location), Time). % [agent,door,location,time] % Side2(door)=location -> % Terminates(WalkThroughDoor21(agent,door),At(agent,location),time). side2(Door)=Location -> terminates_at(walkThroughDoor21(Agent, Door), at_loc(Agent, Location), Time). % fluent Hungry(agent) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',251). fluent(hungry(agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',254). % fluent Satiated(agent) fluent(satiated(agent)). % noninertial Satiated :- call_pel_directive(noninertial(satiated)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',257). % [agent,time] % HoldsAt(Hungry(agent),time) <-> !HoldsAt(Satiated(agent),time). holds_at(hungry(Agent), Time) <-> holds_at(not(satiated(Agent)), Time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',259). % event Eat(agent,food) event(eat(agent,food)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',261). % [agent,food,time] % Happens(Eat(agent,food),time) -> % {location}% % HoldsAt(At(agent,location),time) & % HoldsAt(At(food,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',263). exists([Location], (happens_at(eat(Agent, Food), Time)->holds_at(at_loc(Agent, Location), Time), holds_at(at_loc(Food, Location), Time))). % [agent,food,time] % Terminates(Eat(agent,food),Hungry(agent),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',268). terminates_at(eat(Agent,Food), hungry(Agent), Time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',270). % sort restaurant: script subsort(restaurant,script). % sort waiter: agent subsort(waiter,agent). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',272). % sort cook: agent subsort(cook,agent). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',274). % function BillOf(restaurant): bill function(billOf(restaurant),bill). % function CookOf(restaurant): cook function(cookOf(restaurant),cook). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',276). % function TableOf(restaurant): table function(tableOf(restaurant),table). % function WaiterOf(restaurant): waiter function(waiterOf(restaurant),waiter). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',278). % function KitchenDoorOf(restaurant): door function(kitchenDoorOf(restaurant),door). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',280). % fluent BeWaiter0(waiter) fluent(beWaiter0(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',282). % fluent BeWaiter1(waiter) fluent(beWaiter1(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',284). % fluent BeWaiter2(waiter) fluent(beWaiter2(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',286). % fluent BeWaiter3(waiter) fluent(beWaiter3(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',288). % fluent BeWaiter4(waiter) fluent(beWaiter4(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',290). % fluent BeWaiter5(waiter) fluent(beWaiter5(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',292). % fluent BeWaiter6(waiter) fluent(beWaiter6(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',294). % fluent BeWaiter7(waiter) fluent(beWaiter7(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',296). % fluent BeWaiter8(waiter) fluent(beWaiter8(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',298). % fluent BeWaiter9(waiter) fluent(beWaiter9(waiter)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',300). % xor BeWaiter0, BeWaiter1, BeWaiter2, BeWaiter3, BeWaiter4, BeWaiter5, BeWaiter6, BeWaiter7, BeWaiter8, BeWaiter9 xor([ beWaiter0, beWaiter1, beWaiter2, beWaiter3, beWaiter4, beWaiter5, beWaiter6, beWaiter7, beWaiter8, beWaiter9 ]). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',302). % [waiter,agent,time] % HoldsAt(BeWaiter0(waiter),time) -> % Terminates(Greet(waiter,agent), % BeWaiter0(waiter), % time). holds_at(beWaiter0(Waiter), Time) -> terminates_at(greet(Waiter, Agent), beWaiter0(Waiter), Time). % [waiter,agent,time] % HoldsAt(BeWaiter0(waiter),time) -> % Initiates(Greet(waiter,agent), % BeWaiter1(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',309). holds_at(beWaiter0(Waiter), Time) -> initiates_at(greet(Waiter, Agent), beWaiter1(Waiter), Time). % [waiter,agent,food,time] % HoldsAt(BeWaiter1(waiter),time) -> % Terminates(Order(agent,waiter,food), % BeWaiter1(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',315). holds_at(beWaiter1(Waiter), Time) -> terminates_at(order(Agent, Waiter, Food), beWaiter1(Waiter), Time). % [waiter,agent,food,time] % HoldsAt(BeWaiter1(waiter),time) -> % Initiates(Order(agent,waiter,food), % BeWaiter2(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',321). holds_at(beWaiter1(Waiter), Time) -> initiates_at(order(Agent, Waiter, Food), beWaiter2(Waiter), Time). % [restaurant,waiter,time] % WaiterOf(restaurant)=waiter & % HoldsAt(BeWaiter2(waiter),time) -> % Happens(WalkThroughDoor12(waiter,KitchenDoorOf(restaurant)),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',327). waiterOf(Restaurant)=Waiter, holds_at(beWaiter2(Waiter), Time) -> happens_at(walkThroughDoor12(Waiter, kitchenDoorOf(Restaurant)), Time). % [restaurant,waiter,door,time] % HoldsAt(BeWaiter2(waiter),time) & % WaiterOf(restaurant)=waiter & % KitchenDoorOf(restaurant)=door -> % Terminates(WalkThroughDoor12(waiter,door), % BeWaiter2(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',332). holds_at(beWaiter2(Waiter), Time), waiterOf(Restaurant)=Waiter, kitchenDoorOf(Restaurant)=Door -> terminates_at(walkThroughDoor12(Waiter, Door), beWaiter2(Waiter), Time). % [restaurant,waiter,door,time] % HoldsAt(BeWaiter2(waiter),time) & % WaiterOf(restaurant)=waiter & % KitchenDoorOf(restaurant)=door -> % Initiates(WalkThroughDoor12(waiter,door), % BeWaiter3(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',340). holds_at(beWaiter2(Waiter), Time), waiterOf(Restaurant)=Waiter, kitchenDoorOf(Restaurant)=Door -> initiates_at(walkThroughDoor12(Waiter, Door), beWaiter3(Waiter), Time). % [restaurant,food,time] % HoldsAt(BeWaiter3(WaiterOf(restaurant)),time) & % ({agent} HoldsAt(KnowOrder(WaiterOf(restaurant),agent,food),time)) -> % Happens(Order(WaiterOf(restaurant),CookOf(restaurant),food),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',348). holds_at(beWaiter3(waiterOf(Restaurant)), Time), exists([Agent], holds_at(knowOrder(waiterOf(Restaurant), Agent, Food), Time)) -> happens_at(order(waiterOf(Restaurant), cookOf(Restaurant), Food), Time). % [restaurant,waiter,cook,food,time] % WaiterOf(restaurant)=waiter & % CookOf(restaurant)=cook & % HoldsAt(BeWaiter3(waiter),time) -> % Terminates(Order(waiter,cook,food), % BeWaiter3(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',353). waiterOf(Restaurant)=Waiter, cookOf(Restaurant)=Cook, holds_at(beWaiter3(Waiter), Time) -> terminates_at(order(Waiter, Cook, Food), beWaiter3(Waiter), Time). % [restaurant,waiter,cook,food,time] % WaiterOf(restaurant)=waiter & % CookOf(restaurant)=cook & % HoldsAt(BeWaiter3(waiter),time) -> % Initiates(Order(waiter,cook,food), % BeWaiter4(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',361). waiterOf(Restaurant)=Waiter, cookOf(Restaurant)=Cook, holds_at(beWaiter3(Waiter), Time) -> initiates_at(order(Waiter, Cook, Food), beWaiter4(Waiter), Time). % [waiter,food,time] % HoldsAt(BeWaiter4(waiter),time) & % ({agent} HoldsAt(KnowOrder(waiter,agent,food),time)) & % HoldsAt(FoodPrepared(food),time) -> % Happens(PickUp(waiter,food),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',369). holds_at(beWaiter4(Waiter), Time), exists([Agent], holds_at(knowOrder(Waiter, Agent, Food), Time)), holds_at(foodPrepared(Food), Time) -> happens_at(pickUp(Waiter, Food), Time). % [waiter,food,time] % HoldsAt(BeWaiter4(waiter),time) & % ({agent} HoldsAt(KnowOrder(waiter,agent,food),time)) -> % Terminates(PickUp(waiter,food), % BeWaiter4(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',375). holds_at(beWaiter4(Waiter), Time), exists([Agent], holds_at(knowOrder(Waiter, Agent, Food), Time)) -> terminates_at(pickUp(Waiter, Food), beWaiter4(Waiter), Time). % [waiter,food,time] % HoldsAt(BeWaiter4(waiter),time) & % ({agent} HoldsAt(KnowOrder(waiter,agent,food),time)) -> % Initiates(PickUp(waiter,food), % BeWaiter5(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',382). holds_at(beWaiter4(Waiter), Time), exists([Agent], holds_at(knowOrder(Waiter, Agent, Food), Time)) -> initiates_at(pickUp(Waiter, Food), beWaiter5(Waiter), Time). % [restaurant,waiter,time] % WaiterOf(restaurant)=waiter & % HoldsAt(BeWaiter5(waiter),time) -> % Happens(WalkThroughDoor21(waiter,KitchenDoorOf(restaurant)),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',389). waiterOf(Restaurant)=Waiter, holds_at(beWaiter5(Waiter), Time) -> happens_at(walkThroughDoor21(Waiter, kitchenDoorOf(Restaurant)), Time). % [restaurant,waiter,door,time] % HoldsAt(BeWaiter5(waiter),time) & % WaiterOf(restaurant)=waiter & % KitchenDoorOf(restaurant)=door -> % Terminates(WalkThroughDoor21(waiter,door), % BeWaiter5(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',394). holds_at(beWaiter5(Waiter), Time), waiterOf(Restaurant)=Waiter, kitchenDoorOf(Restaurant)=Door -> terminates_at(walkThroughDoor21(Waiter, Door), beWaiter5(Waiter), Time). % [restaurant,waiter,door,time] % HoldsAt(BeWaiter5(waiter),time) & % WaiterOf(restaurant)=waiter & % KitchenDoorOf(restaurant)=door -> % Initiates(WalkThroughDoor21(waiter,door), % BeWaiter6(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',402). holds_at(beWaiter5(Waiter), Time), waiterOf(Restaurant)=Waiter, kitchenDoorOf(Restaurant)=Door -> initiates_at(walkThroughDoor21(Waiter, Door), beWaiter6(Waiter), Time). % [restaurant,waiter,table,food,time] % WaiterOf(restaurant)=waiter & % TableOf(restaurant)=table & % HoldsAt(BeWaiter6(waiter),time) & % HoldsAt(Holding(waiter,food),time) -> % Happens(PlaceOn(waiter,food,table),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',410). waiterOf(Restaurant)=Waiter, tableOf(Restaurant)=Table, holds_at(beWaiter6(Waiter), Time), holds_at(holding(Waiter, Food), Time) -> happens_at(placeOn(Waiter, Food, Table), Time). % [waiter,food,table,time] % HoldsAt(BeWaiter6(waiter),time) -> % Terminates(PlaceOn(waiter,food,table), % BeWaiter6(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',417). holds_at(beWaiter6(Waiter), Time) -> terminates_at(placeOn(Waiter, Food, Table), beWaiter6(Waiter), Time). % [waiter,food,table,time] % HoldsAt(BeWaiter6(waiter),time) -> % Initiates(PlaceOn(waiter,food,table), % BeWaiter7(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',423). holds_at(beWaiter6(Waiter), Time) -> initiates_at(placeOn(Waiter, Food, Table), beWaiter7(Waiter), Time). % [waiter,agent,bill,time] % HoldsAt(BeWaiter7(waiter),time) -> % Terminates(Request(agent,waiter,bill), % BeWaiter7(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',429). holds_at(beWaiter7(Waiter), Time) -> terminates_at(request(Agent, Waiter, Bill), beWaiter7(Waiter), Time). % [waiter,agent,bill,time] % HoldsAt(BeWaiter7(waiter),time) -> % Initiates(Request(agent,waiter,bill), % BeWaiter8(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',435). holds_at(beWaiter7(Waiter), Time) -> initiates_at(request(Agent, Waiter, Bill), beWaiter8(Waiter), Time). % [restaurant,waiter,bill,time] % WaiterOf(restaurant)=waiter & % BillOf(restaurant)=bill & % HoldsAt(BeWaiter8(waiter),time) -> % Happens(PickUp(waiter,bill),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',441). waiterOf(Restaurant)=Waiter, billOf(Restaurant)=Bill, holds_at(beWaiter8(Waiter), Time) -> happens_at(pickUp(Waiter, Bill), Time). % [waiter,bill,time] % HoldsAt(BeWaiter8(waiter),time) -> % Terminates(PickUp(waiter,bill), % BeWaiter8(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',447). holds_at(beWaiter8(Waiter), Time) -> terminates_at(pickUp(Waiter, Bill), beWaiter8(Waiter), Time). % [waiter,bill,time] % HoldsAt(BeWaiter8(waiter),time) -> % Initiates(PickUp(waiter,bill), % BeWaiter9(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',453). holds_at(beWaiter8(Waiter), Time) -> initiates_at(pickUp(Waiter, Bill), beWaiter9(Waiter), Time). % [restaurant,waiter,bill,table,time] % WaiterOf(restaurant)=waiter & % BillOf(restaurant)=bill & % TableOf(restaurant)=table & % HoldsAt(BeWaiter9(waiter),time) -> % Happens(PlaceOn(waiter,bill,table),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',459). waiterOf(Restaurant)=Waiter, billOf(Restaurant)=Bill, tableOf(Restaurant)=Table, holds_at(beWaiter9(Waiter), Time) -> happens_at(placeOn(Waiter, Bill, Table), Time). % [waiter,bill,table,time] % HoldsAt(BeWaiter9(waiter),time) -> % Terminates(PlaceOn(waiter,bill,table), % BeWaiter9(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',466). holds_at(beWaiter9(Waiter), Time) -> terminates_at(placeOn(Waiter, Bill, Table), beWaiter9(Waiter), Time). % [waiter,bill,table,time] % HoldsAt(BeWaiter9(waiter),time) -> % Initiates(PlaceOn(waiter,bill,table), % BeWaiter0(waiter), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',472). holds_at(beWaiter9(Waiter), Time) -> initiates_at(placeOn(Waiter, Bill, Table), beWaiter0(Waiter), Time). % fluent BeCook0(cook) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',476). fluent(beCook0(cook)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',479). % fluent BeCook1(cook) fluent(beCook1(cook)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',481). % xor BeCook0, BeCook1 xor([beCook0,beCook1]). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',483). % [cook,agent,food,time] % HoldsAt(BeCook0(cook),time) -> % Terminates(Order(agent,cook,food), % BeCook0(cook), % time). holds_at(beCook0(Cook), Time) -> terminates_at(order(Agent, Cook, Food), beCook0(Cook), Time). % [cook,agent,food,time] % HoldsAt(BeCook0(cook),time) -> % Initiates(Order(agent,cook,food), % BeCook1(cook), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',490). holds_at(beCook0(Cook), Time) -> initiates_at(order(Agent, Cook, Food), beCook1(Cook), Time). % event FoodPrepare(agent,food) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',494). event(foodPrepare(agent,food)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',497). % fluent FoodPrepared(food) fluent(foodPrepared(food)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',499). % [agent,food,time] % Initiates(FoodPrepare(agent,food), % FoodPrepared(food), % time). initiates_at(foodPrepare(Agent,Food), foodPrepared(Food), Time). % [agent,food,time] % Happens(FoodPrepare(agent,food),time) -> % {location}% % HoldsAt(At(agent,location),time) & % HoldsAt(At(food,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',505). exists([Location], (happens_at(foodPrepare(Agent, Food), Time)->holds_at(at_loc(Agent, Location), Time), holds_at(at_loc(Food, Location), Time))). % [cook,agent,food,time] % HoldsAt(BeCook1(cook),time) & % HoldsAt(KnowOrder(cook,agent,food),time) -> % Happens(FoodPrepare(cook,food),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',511). holds_at(beCook1(Cook), Time), holds_at(knowOrder(Cook, Agent, Food), Time) -> happens_at(foodPrepare(Cook, Food), Time). % [cook,food,time] % HoldsAt(BeCook1(cook),time) -> % Terminates(FoodPrepare(cook,food), % BeCook1(cook), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',516). holds_at(beCook1(Cook), Time) -> terminates_at(foodPrepare(Cook, Food), beCook1(Cook), Time). % [cook,food,time] % HoldsAt(BeCook1(cook),time) -> % Initiates(FoodPrepare(cook,food), % BeCook0(cook), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',522). holds_at(beCook1(Cook), Time) -> initiates_at(foodPrepare(Cook, Food), beCook0(Cook), Time). % event Pay(agent,agent) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',526). event(pay(agent,agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',529). % event Tip(agent,agent) event(tip(agent,agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',531). % [agent,physobj,time] % Happens(LieOn(agent,physobj),time) -> % {room}% % HoldsAt(At(agent,room),time) & % HoldsAt(At(physobj,room),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',533). exists([Room], (happens_at(lieOn(Agent, Physobj), Time)->holds_at(at_loc(Agent, Room), Time), holds_at(at_loc(Physobj, Room), Time))). % [agent,physobj,time] % Happens(SitOn(agent,physobj),time) -> % {room}% % HoldsAt(At(agent,room),time) & % HoldsAt(At(physobj,room),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',538). exists([Room], (happens_at(sitOn(Agent, Physobj), Time)->holds_at(at_loc(Agent, Room), Time), holds_at(at_loc(Physobj, Room), Time))). % event LieOn(agent,physobj) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',542). event(lieOn(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',545). % event SitOn(agent,physobj) event(sitOn(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',547). % event RiseFrom(agent,physobj) event(riseFrom(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',549). % fluent LyingOn(agent,physobj) fluent(lyingOn(agent,physobj)). % fluent SittingOn(agent,physobj) fluent(sittingOn(agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',551). % fluent Standing(agent) fluent(standing(agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',553). % fluent Lying(agent) fluent(lying(agent)). % fluent Sitting(agent) fluent(sitting(agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',555). % noninertial Lying :- call_pel_directive(noninertial(lying)). % noninertial Sitting :- call_pel_directive(noninertial(sitting)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',558). % xor Lying, Sitting, Standing xor([lying,sitting,standing]). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',560). % [agent,physobj,time] % HoldsAt(LyingOn(agent,physobj),time) -> % HoldsAt(Lying(agent),time). holds_at(lyingOn(Agent, Physobj), Time) -> holds_at(lying(Agent), Time). % [agent,physobj,time] % HoldsAt(SittingOn(agent,physobj),time) -> % HoldsAt(Sitting(agent),time). holds_at(sittingOn(Agent, Physobj), Time) -> holds_at(sitting(Agent), Time). % [agent,physobj1,physobj2,time] % HoldsAt(LyingOn(agent,physobj1),time) & % HoldsAt(LyingOn(agent,physobj2),time) -> % physobj1=physobj2. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',569). holds_at(lyingOn(Agent, Physobj1), Time), holds_at(lyingOn(Agent, Physobj2), Time) -> Physobj1=Physobj2. % [agent,physobj1,physobj2,time] % HoldsAt(SittingOn(agent,physobj1),time) & % HoldsAt(SittingOn(agent,physobj2),time) -> % physobj1=physobj2. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',574). holds_at(sittingOn(Agent, Physobj1), Time), holds_at(sittingOn(Agent, Physobj2), Time) -> Physobj1=Physobj2. % [agent,physobj,time] % HoldsAt(Standing(agent),time) -> % Initiates(LieOn(agent,physobj), % LyingOn(agent,physobj), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',579). holds_at(standing(Agent), Time) -> initiates_at(lieOn(Agent, Physobj), lyingOn(Agent, Physobj), Time). % [agent,physobj,time] % Terminates(LieOn(agent,physobj), % Standing(agent), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',585). terminates_at(lieOn(Agent,Physobj), standing(Agent), Time). % [agent,physobj,time] % HoldsAt(Standing(agent),time) -> % Initiates(SitOn(agent,physobj), % SittingOn(agent,physobj), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',590). holds_at(standing(Agent), Time) -> initiates_at(sitOn(Agent, Physobj), sittingOn(Agent, Physobj), Time). % [agent,physobj,time] % Terminates(SitOn(agent,physobj), % Standing(agent), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',596). terminates_at(sitOn(Agent,Physobj), standing(Agent), Time). % [agent,physobj,time] % (HoldsAt(SittingOn(agent,physobj),time) | % HoldsAt(LyingOn(agent,physobj),time)) -> % Initiates(RiseFrom(agent,physobj), % Standing(agent), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',601). holds_at(sittingOn(Agent, Physobj), Time);holds_at(lyingOn(Agent, Physobj), Time) -> initiates_at(riseFrom(Agent, Physobj), standing(Agent), Time). % [agent,physobj,time] % HoldsAt(LyingOn(agent,physobj),time) -> % Terminates(RiseFrom(agent,physobj), % LyingOn(agent,physobj), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',608). holds_at(lyingOn(Agent, Physobj), Time) -> terminates_at(riseFrom(Agent, Physobj), lyingOn(Agent, Physobj), Time). % [agent,physobj,time] % HoldsAt(SittingOn(agent,physobj),time) -> % Terminates(RiseFrom(agent,physobj), % SittingOn(agent,physobj), % time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',614). holds_at(sittingOn(Agent, Physobj), Time) -> terminates_at(riseFrom(Agent, Physobj), sittingOn(Agent, Physobj), Time). % event Greet(agent,agent) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',618). event(greet(agent,agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',621). % event SayGoodbye(agent,agent) event(sayGoodbye(agent,agent)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',623). % [agent1,agent2,time] % Happens(Greet(agent1,agent2),time) -> % {location}% % HoldsAt(At(agent1,location),time) & % HoldsAt(At(agent2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',625). exists([Location], (happens_at(greet(Agent1, Agent2), Time)->holds_at(at_loc(Agent1, Location), Time), holds_at(at_loc(Agent2, Location), Time))). % [agent1,agent2,time] % Happens(SayGoodbye(agent1,agent2),time) -> % {location}% % HoldsAt(At(agent1,location),time) & % HoldsAt(At(agent2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',630). exists([Location], (happens_at(sayGoodbye(Agent1, Agent2), Time)->holds_at(at_loc(Agent1, Location), Time), holds_at(at_loc(Agent2, Location), Time))). % event Order(agent,agent,physobj) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',634). event(order(agent,agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',637). % fluent KnowOrder(agent,agent,physobj) fluent(knowOrder(agent,agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',639). % [agent1,agent2,physobj,time] % Initiates(Order(agent1,agent2,physobj), % KnowOrder(agent2,agent1,physobj), % time). initiates_at(order(Agent1,Agent2,Physobj), knowOrder(Agent2,Agent1,Physobj), Time). % [agent1,agent2,physobj,time] % Happens(Order(agent1,agent2,physobj),time) -> % {location}% % HoldsAt(At(agent1,location),time) & % HoldsAt(At(agent2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',645). exists([Location], (happens_at(order(Agent1, Agent2, Physobj), Time)->holds_at(at_loc(Agent1, Location), Time), holds_at(at_loc(Agent2, Location), Time))). % event Request(agent,agent,physobj) :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',649). event(request(agent,agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',652). % fluent KnowRequest(agent,agent,physobj) fluent(knowRequest(agent,agent,physobj)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',654). % [agent1,agent2,physobj,time] % Initiates(Request(agent1,agent2,physobj), % KnowRequest(agent2,agent1,physobj), % time). initiates_at(request(Agent1,Agent2,Physobj), knowRequest(Agent2,Agent1,Physobj), Time). % [agent1,agent2,physobj,time] % Happens(Request(agent1,agent2,physobj),time) -> % {location}% % HoldsAt(At(agent1,location),time) & % HoldsAt(At(agent2,location),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',660). exists([Location], (happens_at(request(Agent1, Agent2, Physobj), Time)->holds_at(at_loc(Agent1, Location), Time), holds_at(at_loc(Agent2, Location), Time))). %; End of file. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.e',664). :- call_pel_directive(translate(ending, '/pack/logicmoo_ec/ext/ec_sources/ecnet/RepRest.pel')).