source: AgentMind/trunk/AgentMind/data/characters/minds/LIRECGoalLibrary.xml @ 35

Revision 35, 9.7 KB checked in by myl, 11 years ago (diff)

Define two agents, one for each scenario. Can reload previous state now.

Line 
1<GoalLibrary>  
2        <!-- Greeting -->
3        <ActivePursuitGoal name="Greet([target])">
4                <PreConditions>
5                        <Property name="[target](isPerson)" operator="=" value="True" />
6                        <Property name="[target](isPresent)" operator="=" value="True" />
7                        <Property name="[target]" operator="!=" value="[SELF]" />
8                        <RecentEvent occurred="False" subject="[SELF]" action="SpeechAct" target="[target]" parameters="greeting"/>
9                </PreConditions>
10                <SucessConditions>
11                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="greeting"/>
12                        <RecentEvent occurred="True" subject="[target]" action="GreetBack" target="[SELF]"/>
13                </SucessConditions>
14                <FailureConditions>
15                        <Property name="[target](isPresent)" operator="=" value="False" />
16                </FailureConditions>
17                <ExpectedEffects>
18                        <OnSelect drive="Affiliation" target="[SELF]" value="+6"/>
19                </ExpectedEffects>     
20        </ActivePursuitGoal>
21       
22        <!-- Introducing self to user -->
23        <ActivePursuitGoal name="Welcome([target])">
24                <PreConditions>
25                        <Property name="[target]" operator="!=" value="[SELF]" />
26                        <Property name="[target](isPresent)" operator="=" value="True" />
27                        <Property name="[target](greetCorrectly,[SELF])" operator="=" value="True"/>
28                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="greeting"/>
29                        <RecentEvent occurred="False" subject="[SELF]" action="SpeechAct" target="[target]" parameters="welcome"/>
30                </PreConditions>
31                <SucessConditions>
32                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="welcome"/>
33                </SucessConditions>
34                <FailureConditions>
35                </FailureConditions>                   
36                <ExpectedEffects>
37                        <OnSelect drive="Affiliation" target="[SELF]" value="+4"/>
38                </ExpectedEffects>     
39        </ActivePursuitGoal>
40       
41        <!-- Offer item -->
42        <ActivePursuitGoal name="OfferFruit([target],[item])">
43                <PreConditions>
44                        <Property name="[target](isPerson)" operator="=" value="True" />
45                        <Property name="[target]" operator="!=" value="[SELF]" />
46                        <Property name="[target](isPresent)" operator="=" value="True" />
47                        <Property name="[item](isFruit)" operator="=" value="True" />
48                        <Property name="[item](eatable)" operator="=" value="True" />
49                        <Property name="[SELF](time)" operator="=" value="Morning" />
50                        <RecentEvent occurred="False" subject="[target]" action="Accept" target="[SELF]" parameters="*"/>
51                        <RecentEvent occurred="False" subject="[SELF]" action="SpeechAct" target="[target]" parameters="askPreference"/>
52                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="welcome"/>
53                </PreConditions>       
54                <SucessConditions>
55                        <NewEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="[item]"/>
56                        <RecentEvent occurred="True" subject="[target]" action="Accept" target="[SELF]" parameters="[item]"/>
57                </SucessConditions>     
58                <FailureConditions>
59                        <RecentEvent occurred="True" subject="[target]" action="Reject" target="[SELF]" parameters="[item]"/>
60                </FailureConditions>           
61                <ExpectedEffects>
62                        <OnSelect drive="Affiliation" target="[SELF]" value="+2"/>
63                        <OnIgnore drive="Affiliation" target="[SELF]" value="-2"/>
64                        <OnSelect drive="Affiliation" target="[target]" value="+2"/>                   
65                </ExpectedEffects>                     
66        </ActivePursuitGoal>
67       
68        <ActivePursuitGoal name="OfferCake([target],[item])">
69                <PreConditions>
70                        <Property name="[target](isPerson)" operator="=" value="True" />
71                        <Property name="[target]" operator="!=" value="[SELF]" />
72                        <Property name="[target](isPresent)" operator="=" value="True" />
73                        <Property name="[item](isCake)" operator="=" value="True" />
74                        <Property name="[item](eatable)" operator="=" value="True" />
75                        <Property name="[SELF](time)" operator="=" value="Afternoon" />
76                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="welcome"/>
77                </PreConditions>       
78                <SucessConditions>
79                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="[item]"/>
80                <RecentEvent occurred="True" subject="[target]" action="Accept" target="[SELF]" parameters="[item]"/>
81                </SucessConditions>     
82                <FailureConditions>
83                        <RecentEvent occurred="True" subject="[target]" action="Reject" target="[SELF]" parameters="[item]"/>
84                </FailureConditions>
85                <ExpectedEffects>
86                        <OnSelect drive="Affiliation" target="[SELF]" value="+2"/>
87                        <OnIgnore drive="Affiliation" target="[SELF]" value="-2"/>
88                        <OnSelect drive="Affiliation" target="[target]" value="+2"/>                   
89                </ExpectedEffects>                     
90        </ActivePursuitGoal>
91       
92        <ActivePursuitGoal name="AskPreference([target])">
93                <PreConditions>                 
94                        <Property name="[target](isPerson)" operator="=" value="True" />
95                        <Property name="[target]" operator="!=" value="[SELF]" />
96                        <RecentEvent occurred="False" subject="[target]" action="Accept" target="[SELF]" parameters="*"/>
97                        <RecentEvent occurred="True" subject="[target]" action="Reject" target="[SELF]" parameters="*"/>
98                </PreConditions>       
99                <SucessConditions>
100                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="askPreference"/>
101                </SucessConditions>             
102                <ExpectedEffects>
103                        <OnSelect drive="Affiliation" target="[SELF]" value="+5"/>
104                        <OnIgnore drive="Affiliation" target="[SELF]" value="-5"/>
105                        <OnSelect drive="Affiliation" target="[target]" value="+5"/>                   
106                </ExpectedEffects>                     
107        </ActivePursuitGoal>
108       
109        <ActivePursuitGoal name="AcknowledgeChoice([target],[item])">
110                <PreConditions>                 
111                        <Property name="[target](isPerson)" operator="=" value="True" />
112                        <Property name="[target]" operator="!=" value="[SELF]" />
113                        <RecentEvent occurred="True" subject="[target]" action="Choose" target="[SELF]" parameters="[item]"/>
114                </PreConditions>       
115                <SucessConditions>
116                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="acknowledge"/>
117                </SucessConditions>             
118                <ExpectedEffects>
119                        <OnSelect drive="Affiliation" target="[SELF]" value="+3"/>
120                        <OnIgnore drive="Affiliation" target="[SELF]" value="-3"/>
121                        <OnSelect drive="Affiliation" target="[target]" value="+3"/>                   
122                </ExpectedEffects>                     
123        </ActivePursuitGoal>
124       
125        <ActivePursuitGoal name="Goodbye([target],[item])">
126                <PreConditions>                 
127                        <Property name="[target](isPerson)" operator="=" value="True" />
128                        <Property name="[target]" operator="!=" value="[SELF]" />
129                        <RecentEvent occurred="True" subject="[target]" action="Accept" target="[SELF]" parameters="[item]"/>
130                </PreConditions>       
131                <SucessConditions>
132                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="goodbye,[item]"/>
133                </SucessConditions>             
134                <ExpectedEffects>
135                        <OnSelect drive="Affiliation" target="[SELF]" value="+3"/>
136                        <OnIgnore drive="Affiliation" target="[SELF]" value="-3"/>
137                        <OnSelect drive="Affiliation" target="[target]" value="+3"/>                   
138                </ExpectedEffects>                     
139        </ActivePursuitGoal>
140       
141        <!-- Scenario 2 -->
142        <ActivePursuitGoal name="SwearSecrecy([target],[friend][info])">
143                <PreConditions>                 
144                        <Property name="[target](isPerson)" operator="=" value="True" />
145                        <Property name="[target]" operator="!=" value="[SELF]" />
146                        <Property name="[target]([info],isSensitive)" operator="=" value="[friend]" />
147                        <RecentEvent occurred="True" subject="[target]" action="TellSensitiveInfo" target="[SELF]" parameters="[friend],[info]"/>
148                </PreConditions>       
149                <SucessConditions>
150                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="swearSecrecy,[friend]"/>
151                </SucessConditions>             
152                <ExpectedEffects>
153                        <OnSelect drive="Affiliation" target="[SELF]" value="+3"/>
154                        <OnIgnore drive="Affiliation" target="[SELF]" value="-3"/>
155                        <OnSelect drive="Affiliation" target="[target]" value="+3"/>                   
156                </ExpectedEffects>                     
157        </ActivePursuitGoal>
158       
159        <ActivePursuitGoal name="ReplyHideInfo([target],[friend],[info])">
160                <PreConditions>                 
161                        <Property name="[target](isPerson)" operator="=" value="True" />
162                        <Property name="[target]" operator="!=" value="[SELF]" />
163                        <Property name="[friend](isPerson)" operator="=" value="True" />
164                        <Property name="[friend]([info],isSensitive)" operator="=" value="[target]" />
165                        <RecentEvent occurred="True" subject="[target]" action="Ask" target="[SELF]" parameters="[friend],[info]"/>
166                </PreConditions>       
167                <SucessConditions>
168                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="hideInfo"/>
169                </SucessConditions>             
170                <ExpectedEffects>
171                        <OnSelect drive="Affiliation" target="[SELF]" value="+3"/>
172                        <OnIgnore drive="Affiliation" target="[SELF]" value="-3"/>
173                        <OnSelect drive="Affiliation" target="[target]" value="+3"/>                   
174                </ExpectedEffects>                     
175        </ActivePursuitGoal>
176       
177        <ActivePursuitGoal name="ReplyTellInfo([target],[friend],[info])">
178                <PreConditions>                 
179                        <Property name="[target](isPerson)" operator="=" value="True" />
180                        <Property name="[target]" operator="!=" value="[SELF]" />
181                        <!--Property name="[friend]([info],isSensitive)" operator="=" value="[agentX]" />
182                        <Property name="[agentX](isPresent)" operator="=" value="False" /-->
183                        <Property name="[friend](isPerson)" operator="=" value="True" />
184                        <Property name="[friend]([info],isSensitive)" operator="!=" value="[target]" />
185                        <RecentEvent occurred="True" subject="[target]" action="Ask" target="[SELF]" parameters="[friend],[info]"/>
186                </PreConditions>       
187                <SucessConditions>
188                        <RecentEvent occurred="True" subject="[SELF]" action="SpeechAct" target="[target]" parameters="[info],[friend]"/>
189                </SucessConditions>             
190                <ExpectedEffects>
191                        <OnSelect drive="Affiliation" target="[SELF]" value="+3"/>
192                        <OnIgnore drive="Affiliation" target="[SELF]" value="-3"/>
193                        <OnSelect drive="Affiliation" target="[target]" value="+3"/>                   
194                </ExpectedEffects>                     
195        </ActivePursuitGoal>
196</GoalLibrary>
Note: See TracBrowser for help on using the repository browser.