@camunda/e2e-test-suite 0.0.1095 → 0.0.1097

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1138,13 +1138,29 @@ class ModelerCreatePage {
1138
1138
  // processApplicationId is defined, which it now is, so re-entering
1139
1139
  // Play on an already-deployed process application legitimately
1140
1140
  // has nothing to deploy and renders no Deploy button at all.
1141
+ // The "Configure test case" accordion header is always rendered once
1142
+ // the overlay is up -- it's only enabled once deploy has completed --
1143
+ // so isVisible() alone is always true here and this check must gate on
1144
+ // isEnabled() instead, or Step 2 is skipped even when deploy is still
1145
+ // pending and Step 3 spins forever on a button that never unlocks.
1141
1146
  const alreadyDeployed = await configureScenarioButton
1142
- .isVisible({ timeout: 3000 })
1147
+ .isEnabled({ timeout: 3000 })
1143
1148
  .catch(() => false);
1144
1149
  if (!alreadyDeployed) {
1145
1150
  // Step 2: deploy
1146
1151
  await setupDeployButton.click({ timeout });
1147
- await (0, test_1.expect)(this.page.getByText('Process has been successfully deployed')).toBeVisible({ timeout: 90000 });
1152
+ // Test Studio dropped the "Process has been successfully deployed"
1153
+ // toast: DeployStepContent now swaps the Deploy button for an inline
1154
+ // `deploy-success-badge` ("Successfully deployed"), and
1155
+ // TestConfigurationPanel's isDeployStepComplete effect calls
1156
+ // hideConfigurationOverlay() as soon as deploy lands -- which
1157
+ // collapses the Deploy step and opens "Configure test case" on its
1158
+ // own. Accept either signal; a failed deploy renders a "Deployment
1159
+ // failed" badge instead and matches neither.
1160
+ await (0, test_1.expect)(this.page
1161
+ .getByTestId('deploy-success-badge')
1162
+ .or(configureTestPanel)
1163
+ .first()).toBeVisible({ timeout: 90000 });
1148
1164
  }
1149
1165
  // Step 3: leave the overlay, and confirm we actually left it. The
1150
1166
  // button only calls hideConfigurationOverlay(); the overlay's own
@@ -0,0 +1,443 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"
3
+ xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
4
+ xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
5
+ xmlns:zeebe="http://camunda.org/schema/zeebe/1.0"
6
+ xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
7
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
8
+ xmlns:bioc="http://bpmn.io/schema/bpmn/biocolor/1.0"
9
+ xmlns:color="http://www.omg.org/spec/BPMN/non-normative/color/1.0"
10
+ xmlns:modeler="http://camunda.org/schema/modeler/1.0" id="Definitions_18jxukq"
11
+ targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Web Modeler"
12
+ exporterVersion="2de5b0b" modeler:executionPlatform="Camunda Cloud"
13
+ modeler:executionPlatformVersion="8.9.0">
14
+ <bpmn:process id="ai-agent-chat-with-tools-aws" name="AI Agent Chat With Tools AWS"
15
+ isExecutable="true">
16
+ <bpmn:startEvent id="StartEvent_1">
17
+ <bpmn:extensionElements>
18
+ <zeebe:formDefinition formId="ai-agent-chat-initial-request" />
19
+ </bpmn:extensionElements>
20
+ <bpmn:outgoing>Flow_0pbzrme</bpmn:outgoing>
21
+ </bpmn:startEvent>
22
+ <bpmn:sequenceFlow id="Flow_0pbzrme" sourceRef="StartEvent_1" targetRef="Gateway_0z6ctwk" />
23
+ <bpmn:serviceTask id="AI_Agent" name="AI Agent"
24
+ zeebe:modelerTemplate="io.camunda.connectors.agenticai.aiagent.v1"
25
+ zeebe:modelerTemplateVersion="6"
26
+ zeebe:modelerTemplateIcon="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIHZpZXdCb3g9IjAgMCAzMiAzMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGNpcmNsZSBjeD0iMTYiIGN5PSIxNiIgcj0iMTYiIGZpbGw9IiNBNTZFRkYiLz4KPG1h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I1MyAxOC4zOTg3IDIzLjk0NjUgMTcuMDY2OSAyNS45OTE1IDE2LjA4MjRDMjUuOTk2NSAxNi4wNTkzIDI2IDE2LjAzMSAyNiAxNS45OTk3QzI2IDE1Ljk2ODQgMjUuOTk2NSAxNS45NDAzIDI1Ljk5MTUgMTUuOTE3MUMyMy45NDc0IDE0LjkzMjcgMjEuNTI1OSAxMy42MDEgMjAuMDEwNSAxMi4wOTg3IiBzdHJva2U9IiM0OTFEOEIiIHN0cm9rZS13aWR0aD0iNCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgbWFzaz0idXJsKCNwYXRoLTItb3V0c2lkZS0xXzE4NV82KSIvPgo8L3N2Zz4K">
27
+ <bpmn:extensionElements>
28
+ <zeebe:taskDefinition type="io.camunda.agenticai:aiagent:1" retries="3" />
29
+ <zeebe:ioMapping>
30
+ <zeebe:input source="bedrock" target="provider.type" />
31
+ <zeebe:input source="{{secrets.IDP_AWS_REGION}}" target="provider.bedrock.region" />
32
+ <zeebe:input source="credentials" target="provider.bedrock.authentication.type" />
33
+ <zeebe:input source="{{secrets.IDP_AWS_ACCESSKEY}}"
34
+ target="provider.bedrock.authentication.accessKey" />
35
+ <zeebe:input source="{{secrets.IDP_AWS_SECRETKEY}}"
36
+ target="provider.bedrock.authentication.secretKey" />
37
+ <zeebe:input source="global.anthropic.claude-sonnet-4-5-20250929-v1:0"
38
+ target="provider.bedrock.model.model" />
39
+ <zeebe:input
40
+ source="You are a helpful, generic chat agent which can answer a wide amount of questions based on your knowledge and an optional set of available tools.&#10;&#10;If tools are provided, you should prefer them instead of guessing an answer. You can call the same tool multiple times by providing different input values. Don&#39;t guess any tools which were not explicitely configured. If no tool matches the request, try to generate an answer. If you&#39;re not able to find a good answer, return with a message stating why you&#39;re not able to.&#10;&#10;If you are prompted to interact with a person, never guess contact details, but use available user/person lookup tools instead and return with an error if you&#39;re not able to look up appropriate data.&#10;&#10;Thinking, step by step, before you execute your tools, you think using the template `&#60;thinking&#62;&#60;context&#62;&#60;/context&#62;&#60;reflection&#62;&#60;/reflection&#62;&#60;/thinking&#62;`"
41
+ target="data.systemPrompt.prompt" />
42
+ <zeebe:input
43
+ source="=&#34;Generate a single sentence in the following exact format, always using a new random city and country each time:&#10;&#10;The current date and time in {City, Country}, is approximately {h:mm AM/PM} on {Month day, year}.&#10;&#10;But only with the sentence/format as above, nothing else&#34;"
44
+ target="data.userPrompt.prompt" />
45
+ <zeebe:input
46
+ source="=if (is defined(followUpInput) or is defined(followUpDocuments)) then followUpDocuments else inputDocuments"
47
+ target="data.userPrompt.documents" />
48
+ <zeebe:input source="Agent_Tools" target="data.tools.containerElementId" />
49
+ <zeebe:input source="=toolCallResults" target="data.tools.toolCallResults" />
50
+ <zeebe:input source="=agent.context" target="data.context" />
51
+ <zeebe:input source="in-process" target="data.memory.storage.type" />
52
+ <zeebe:input source="=20" target="data.memory.contextWindowSize" />
53
+ <zeebe:input source="=10" target="data.limits.maxModelCalls" />
54
+ <zeebe:input source="text" target="data.response.format.type" />
55
+ <zeebe:input source="=false" target="data.response.format.parseJson" />
56
+ <zeebe:input source="=false" target="data.response.includeAssistantMessage" />
57
+ </zeebe:ioMapping>
58
+ <zeebe:taskHeaders>
59
+ <zeebe:header key="elementTemplateVersion" value="6" />
60
+ <zeebe:header key="elementTemplateId" value="io.camunda.connectors.agenticai.aiagent.v1" />
61
+ <zeebe:header key="resultVariable" value="agent" />
62
+ <zeebe:header key="retryBackoff" value="PT2S" />
63
+ </zeebe:taskHeaders>
64
+ </bpmn:extensionElements>
65
+ <bpmn:incoming>Flow_050377t</bpmn:incoming>
66
+ <bpmn:outgoing>Flow_041ffce</bpmn:outgoing>
67
+ </bpmn:serviceTask>
68
+ <bpmn:exclusiveGateway id="Gateway_0z6ctwk">
69
+ <bpmn:incoming>Flow_0pbzrme</bpmn:incoming>
70
+ <bpmn:incoming>Flow_01k9dy1</bpmn:incoming>
71
+ <bpmn:incoming>Flow_19gp461</bpmn:incoming>
72
+ <bpmn:outgoing>Flow_050377t</bpmn:outgoing>
73
+ </bpmn:exclusiveGateway>
74
+ <bpmn:userTask id="User_Feedback" name="User Feedback">
75
+ <bpmn:extensionElements>
76
+ <zeebe:userTask />
77
+ <zeebe:formDefinition formId="ai-agent-chat-user-feedback" />
78
+ </bpmn:extensionElements>
79
+ <bpmn:incoming>Flow_11y3kim</bpmn:incoming>
80
+ <bpmn:outgoing>Flow_09y08ef</bpmn:outgoing>
81
+ </bpmn:userTask>
82
+ <bpmn:exclusiveGateway id="Gateway_1dcg4ha" name="User satisfied?">
83
+ <bpmn:incoming>Flow_09y08ef</bpmn:incoming>
84
+ <bpmn:outgoing>Flow_19gp461</bpmn:outgoing>
85
+ <bpmn:outgoing>Flow_16c9bwj</bpmn:outgoing>
86
+ </bpmn:exclusiveGateway>
87
+ <bpmn:sequenceFlow id="Flow_09y08ef" sourceRef="User_Feedback" targetRef="Gateway_1dcg4ha" />
88
+ <bpmn:sequenceFlow id="Flow_19gp461" name="no - we follow up" sourceRef="Gateway_1dcg4ha"
89
+ targetRef="Gateway_0z6ctwk">
90
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=userSatisfied = null or
91
+ userSatisfied = false</bpmn:conditionExpression>
92
+ </bpmn:sequenceFlow>
93
+ <bpmn:endEvent id="Event_0i39jej">
94
+ <bpmn:incoming>Flow_16c9bwj</bpmn:incoming>
95
+ </bpmn:endEvent>
96
+ <bpmn:sequenceFlow id="Flow_16c9bwj" name="yes" sourceRef="Gateway_1dcg4ha"
97
+ targetRef="Event_0i39jej">
98
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=userSatisfied</bpmn:conditionExpression>
99
+ </bpmn:sequenceFlow>
100
+ <bpmn:sequenceFlow id="Flow_041ffce" sourceRef="AI_Agent" targetRef="Gateway_0bukj01" />
101
+ <bpmn:exclusiveGateway id="Gateway_0bukj01" name="Includes tool calls?">
102
+ <bpmn:incoming>Flow_041ffce</bpmn:incoming>
103
+ <bpmn:outgoing>Flow_00lg7l2</bpmn:outgoing>
104
+ <bpmn:outgoing>Flow_11y3kim</bpmn:outgoing>
105
+ </bpmn:exclusiveGateway>
106
+ <bpmn:adHocSubProcess id="Agent_Tools" name="Agent Tools">
107
+ <bpmn:extensionElements>
108
+ <zeebe:adHoc activeElementsCollection="=[toolCall._meta.name]" />
109
+ </bpmn:extensionElements>
110
+ <bpmn:incoming>Flow_00lg7l2</bpmn:incoming>
111
+ <bpmn:outgoing>Flow_01k9dy1</bpmn:outgoing>
112
+ <bpmn:multiInstanceLoopCharacteristics>
113
+ <bpmn:extensionElements>
114
+ <zeebe:loopCharacteristics inputCollection="=agent.toolCalls" inputElement="toolCall"
115
+ outputCollection="toolCallResults"
116
+ outputElement="={&#10; id: toolCall._meta.id,&#10; name: toolCall._meta.name,&#10; content: toolCallResult&#10;}" />
117
+ </bpmn:extensionElements>
118
+ </bpmn:multiInstanceLoopCharacteristics>
119
+ <bpmn:scriptTask id="GetDateAndTime" name="Get Date and Time">
120
+ <bpmn:documentation>Returns the current date and time including the timezone.</bpmn:documentation>
121
+ <bpmn:extensionElements>
122
+ <zeebe:script expression="=now()" resultVariable="toolCallResult" />
123
+ </bpmn:extensionElements>
124
+ </bpmn:scriptTask>
125
+ <bpmn:serviceTask id="Search_Recipe" name="Search recipe"
126
+ zeebe:modelerTemplate="io.camunda.connectors.HttpJson.v2" zeebe:modelerTemplateVersion="10"
127
+ zeebe:modelerTemplateIcon="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTgiIGhlaWdodD0iMTgiIHZpZXdCb3g9IjAgMCAxOCAxOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTE3LjAzMzUgOC45OTk5N0MxNy4wMzM1IDEzLjQ0NzUgMTMuNDI4MSAxNy4wNTI5IDguOTgwNjUgMTcuMDUyOUM0LjUzMzE2IDE3LjA1MjkgMC45Mjc3NjUgMTMuNDQ3NSAwLjkyNzc2NSA4Ljk5OTk3QzAuOTI3NzY1IDQuNTUyNDggNC41MzMxNiAwLjk0NzA4MyA4Ljk4MDY1IDAuOTQ3MDgzQzEzLjQyODEgMC45NDcwODMgMTcuMDMzNSA0LjU1MjQ4IDE3LjAzMzUgOC45OTk5N1oiIGZpbGw9IiM1MDU1NjIiLz4KPHBhdGggZD0iTTQuOTMxMjYgMTQuMTU3MUw2Ljc4MTA2IDMuNzE0NzFIMTAuMTM3NUMxMS4xOTE3IDMuNzE0NzEgMTEuOTgyNCAzLjk4MzIzIDEyLjUwOTUgNC41MjAyN0MxMy4wNDY1IDUuMDQ3MzYgMTMuMzE1IDUuNzMzNTggMTMuMzE1IDYuNTc4OTJDMTMuMzE1IDcuNDQ0MTQgMTMuMDcxNCA4LjE1NTIyIDEyLjU4NDEgOC43MTIxNUMxMi4xMDY3IDkuMjU5MTMgMTEuNDU1MyA5LjYzNzA1IDEwLjYyOTggOS44NDU5TDEyLjA2MTkgMTQuMTU3MUgxMC4zMzE1TDkuMDMzNjQgMTAuMDI0OUg3LjI0MzUxTDYuNTEyNTQgMTQuMTU3MUg0LjkzMTI2Wk03LjQ5NzExIDguNTkyODFIOS4yNDI0OEM5Ljk5ODMyIDguNTkyODEgMTAuNTkwMSA4LjQyMzc0IDExLjAxNzcgOC4wODU2MUMxMS40NTUzIDcuNzM3NTMgMTEuNjc0MSA3LjI2NTEzIDExLjY3NDEgNi42Njg0MkMxMS42NzQxIDYuMTkxMDYgMTEuNTI0OSA1LjgxODExIDExLjIyNjUgNS41NDk1OUMxMC45MjgyIDUuMjcxMTMgMTAuNDU1OCA1LjEzMTkgOS44MDkzNiA1LjEzMTlIOC4xMDg3NEw3LjQ5NzExIDguNTkyODFaIiBmaWxsPSJ3aGl0ZSIvPgo8L3N2Zz4K">
128
+ <bpmn:documentation>Searches a recipe given a search query</bpmn:documentation>
129
+ <bpmn:extensionElements>
130
+ <zeebe:taskDefinition type="io.camunda:http-json:1" retries="3" />
131
+ <zeebe:ioMapping>
132
+ <zeebe:input source="noAuth" target="authentication.type" />
133
+ <zeebe:input source="GET" target="method" />
134
+ <zeebe:input source="https://dummyjson.com/recipes/search" target="url" />
135
+ <zeebe:input
136
+ source="={&#10; q: fromAi(toolCall.searchQuery, &#34;The query describing which recipe to search (e.g. a specific dish or the cuisine).&#34;)&#10;}"
137
+ target="queryParameters" />
138
+ <zeebe:input source="=false" target="storeResponse" />
139
+ <zeebe:input source="20" target="connectionTimeoutInSeconds" />
140
+ <zeebe:input source="20" target="readTimeoutInSeconds" />
141
+ <zeebe:input source="=false" target="ignoreNullValues" />
142
+ </zeebe:ioMapping>
143
+ <zeebe:taskHeaders>
144
+ <zeebe:header key="resultExpression"
145
+ value="={&#10; toolCallResult: if (count(response.body.recipes) &#62; 0) then response.body.recipes else &#34;No result found.&#34;&#10;}" />
146
+ <zeebe:header key="retryBackoff" value="PT0S" />
147
+ </zeebe:taskHeaders>
148
+ </bpmn:extensionElements>
149
+ </bpmn:serviceTask>
150
+ <bpmn:scriptTask id="SuperfluxProduct" name="Superflux Product Calculation">
151
+ <bpmn:documentation>Calculates the superflux product (a very complicated method only this
152
+ tool can do) given two input numbers</bpmn:documentation>
153
+ <bpmn:extensionElements>
154
+ <zeebe:script expression="=3 * (inputA + inputB)" resultVariable="toolCallResult" />
155
+ <zeebe:ioMapping>
156
+ <zeebe:input
157
+ source="=fromAi(toolCall.a, &#34;The first number to be superflux calculated.&#34;, &#34;number&#34;)"
158
+ target="inputA" />
159
+ <zeebe:input
160
+ source="=fromAi(toolCall.b, &#34;The second number to be superflux calculated.&#34;, &#34;number&#34;)"
161
+ target="inputB" />
162
+ </zeebe:ioMapping>
163
+ </bpmn:extensionElements>
164
+ </bpmn:scriptTask>
165
+ <bpmn:userTask id="AskHumanToSendEmail" name="Ask human to send email">
166
+ <bpmn:documentation>Ask a human to send an email for you</bpmn:documentation>
167
+ <bpmn:extensionElements>
168
+ <zeebe:userTask />
169
+ <zeebe:formDefinition formId="ai-agent-chat-human-send-email-request" />
170
+ <zeebe:ioMapping>
171
+ <zeebe:input
172
+ source="=fromAi(toolCall.instructions, &#34;Instructions for the human to follow when sending the email, including background of the email.&#34;)"
173
+ target="instructions" />
174
+ <zeebe:input
175
+ source="=fromAi(toolCall.recipient_name, &#34;The recipient&#39;s full name.&#34;)"
176
+ target="recipient_name" />
177
+ <zeebe:input
178
+ source="=fromAi(toolCall.recipient_email, &#34;The the recipient&#39;s email address.&#34;)"
179
+ target="recipient_email" />
180
+ <zeebe:input
181
+ source="=fromAi(toolCall.email_subject, &#34;The subject of the email.&#34;)"
182
+ target="email_subject" />
183
+ <zeebe:input source="=fromAi(toolCall.email_body, &#34;The body of the email.&#34;)"
184
+ target="email_body" />
185
+ <zeebe:output
186
+ source="={&#10; operatorFeedback: operatorFeedback,&#10; emailOk: emailOk&#10;}"
187
+ target="toolCallResult" />
188
+ </zeebe:ioMapping>
189
+ </bpmn:extensionElements>
190
+ <bpmn:outgoing>Flow_0demz1g</bpmn:outgoing>
191
+ </bpmn:userTask>
192
+ <bpmn:sequenceFlow id="Flow_0demz1g" sourceRef="AskHumanToSendEmail"
193
+ targetRef="Gateway_1lux75t" />
194
+ <bpmn:exclusiveGateway id="Gateway_1lux75t" name="OK to send email?">
195
+ <bpmn:incoming>Flow_0demz1g</bpmn:incoming>
196
+ <bpmn:outgoing>Flow_0uqjclh</bpmn:outgoing>
197
+ <bpmn:outgoing>Flow_1l2ws6w</bpmn:outgoing>
198
+ </bpmn:exclusiveGateway>
199
+ <bpmn:sequenceFlow id="Flow_0uqjclh" name="yes" sourceRef="Gateway_1lux75t"
200
+ targetRef="SendEmail">
201
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=toolCallResult.emailOk</bpmn:conditionExpression>
202
+ </bpmn:sequenceFlow>
203
+ <bpmn:sequenceFlow id="Flow_1l2ws6w" name="no" sourceRef="Gateway_1lux75t"
204
+ targetRef="Event_1wxfv4u">
205
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=toolCallResult.emailOk != true</bpmn:conditionExpression>
206
+ </bpmn:sequenceFlow>
207
+ <bpmn:intermediateThrowEvent id="Event_1wxfv4u" name="loop back with feedback">
208
+ <bpmn:incoming>Flow_1l2ws6w</bpmn:incoming>
209
+ </bpmn:intermediateThrowEvent>
210
+ <bpmn:scriptTask id="SendEmail" name="Send email">
211
+ <bpmn:extensionElements>
212
+ <zeebe:script expression="=true" resultVariable="emailSent" />
213
+ <zeebe:ioMapping>
214
+ <zeebe:output source="=emailSent" target="toolCallResult.emailSent" />
215
+ </zeebe:ioMapping>
216
+ </bpmn:extensionElements>
217
+ <bpmn:incoming>Flow_0uqjclh</bpmn:incoming>
218
+ </bpmn:scriptTask>
219
+ </bpmn:adHocSubProcess>
220
+ <bpmn:sequenceFlow id="Flow_00lg7l2" name="yes" sourceRef="Gateway_0bukj01"
221
+ targetRef="Agent_Tools">
222
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=not(is empty(agent.toolCalls))</bpmn:conditionExpression>
223
+ </bpmn:sequenceFlow>
224
+ <bpmn:sequenceFlow id="Flow_11y3kim" name="no" sourceRef="Gateway_0bukj01"
225
+ targetRef="User_Feedback">
226
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">=is empty(agent.toolCalls)</bpmn:conditionExpression>
227
+ </bpmn:sequenceFlow>
228
+ <bpmn:sequenceFlow id="Flow_050377t" sourceRef="Gateway_0z6ctwk" targetRef="AI_Agent" />
229
+ <bpmn:sequenceFlow id="Flow_01k9dy1" sourceRef="Agent_Tools" targetRef="Gateway_0z6ctwk" />
230
+ <bpmn:textAnnotation id="TextAnnotation_0rg9ar3">
231
+ <bpmn:text>Rough outline of the functionality
232
+
233
+ - Loads previous agent context (conversation, metrics, ...)
234
+ - Loads available tool information from ad-hoc sub-process definition
235
+ - Resolves tool information from gateway tool definitions such as MCP
236
+ - Checks limits (e.g. maximum LLM model calls)
237
+ - Merges the current request (either a user message or a tool call response) into the memory
238
+ - Calls the LLM, including previous/edited memory (limited to max amount of messages) +
239
+ available tools schema
240
+ - Returns last response as text or JSON format, depending on the configuration
241
+ - Returns tools to call, including their parameters</bpmn:text>
242
+ </bpmn:textAnnotation>
243
+ <bpmn:association id="Association_0ic98nl" associationDirection="None" sourceRef="AI_Agent"
244
+ targetRef="TextAnnotation_0rg9ar3" />
245
+ <bpmn:textAnnotation id="TextAnnotation_1keavvi">
246
+ <bpmn:text>For every tool call in &lt;agent.toolCalls&gt;</bpmn:text>
247
+ </bpmn:textAnnotation>
248
+ <bpmn:association id="Association_0q5n90x" associationDirection="None" sourceRef="Agent_Tools"
249
+ targetRef="TextAnnotation_1keavvi" />
250
+ <bpmn:textAnnotation id="TextAnnotation_1cvjkfu">
251
+ <bpmn:text>Every execution (flow node or sequence of flow nodes) MUST write
252
+ &lt;toolCallResult&gt; variable</bpmn:text>
253
+ </bpmn:textAnnotation>
254
+ <bpmn:textAnnotation id="TextAnnotation_1tvejhg">
255
+ <bpmn:text>Every task inside of an execution MAY query for external inputs provided by the
256
+ model through the fromAI helper:
257
+
258
+ fromAi(toolCall.id, "The user ID", "number")
259
+
260
+ The outside brain &lt;AI Agent&gt; will take that information to instruct the model which
261
+ data to provide in which format.</bpmn:text>
262
+ </bpmn:textAnnotation>
263
+ <bpmn:textAnnotation id="TextAnnotation_0xt28ql">
264
+ <bpmn:text>Must produce output as &lt;toolCallResults=[ { id, name, content } ]&gt;</bpmn:text>
265
+ </bpmn:textAnnotation>
266
+ <bpmn:association id="Association_14t02ll" associationDirection="None" sourceRef="Agent_Tools"
267
+ targetRef="TextAnnotation_0xt28ql" />
268
+ </bpmn:process>
269
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
270
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="ai-agent-chat-with-tools-aws">
271
+ <bpmndi:BPMNShape id="StartEvent_1_di" bpmnElement="StartEvent_1">
272
+ <dc:Bounds x="152" y="442" width="36" height="36" />
273
+ </bpmndi:BPMNShape>
274
+ <bpmndi:BPMNShape id="Activity_0xj2598_di" bpmnElement="AI_Agent" bioc:stroke="#205022"
275
+ bioc:fill="#c8e6c9" color:background-color="#c8e6c9" color:border-color="#205022">
276
+ <dc:Bounds x="340" y="420" width="100" height="80" />
277
+ <bpmndi:BPMNLabel />
278
+ </bpmndi:BPMNShape>
279
+ <bpmndi:BPMNShape id="Gateway_0z6ctwk_di" bpmnElement="Gateway_0z6ctwk" isMarkerVisible="true">
280
+ <dc:Bounds x="245" y="435" width="50" height="50" />
281
+ </bpmndi:BPMNShape>
282
+ <bpmndi:BPMNShape id="Activity_1fam9db_di" bpmnElement="User_Feedback">
283
+ <dc:Bounds x="640" y="420" width="100" height="80" />
284
+ <bpmndi:BPMNLabel />
285
+ </bpmndi:BPMNShape>
286
+ <bpmndi:BPMNShape id="Gateway_1dcg4ha_di" bpmnElement="Gateway_1dcg4ha" isMarkerVisible="true">
287
+ <dc:Bounds x="805" y="435" width="50" height="50" />
288
+ <bpmndi:BPMNLabel>
289
+ <dc:Bounds x="794" y="492" width="73" height="14" />
290
+ </bpmndi:BPMNLabel>
291
+ </bpmndi:BPMNShape>
292
+ <bpmndi:BPMNShape id="Event_0i39jej_di" bpmnElement="Event_0i39jej">
293
+ <dc:Bounds x="912" y="442" width="36" height="36" />
294
+ </bpmndi:BPMNShape>
295
+ <bpmndi:BPMNShape id="Gateway_0bukj01_di" bpmnElement="Gateway_0bukj01" isMarkerVisible="true">
296
+ <dc:Bounds x="505" y="435" width="50" height="50" />
297
+ <bpmndi:BPMNLabel>
298
+ <dc:Bounds x="499" y="406" width="62" height="27" />
299
+ </bpmndi:BPMNLabel>
300
+ </bpmndi:BPMNShape>
301
+ <bpmndi:BPMNShape id="Activity_03yngb7_di" bpmnElement="Agent_Tools" isExpanded="true"
302
+ bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2"
303
+ color:border-color="#6b3c00">
304
+ <dc:Bounds x="640" y="560" width="400" height="360" />
305
+ </bpmndi:BPMNShape>
306
+ <bpmndi:BPMNShape id="Activity_1sbkoqq_di" bpmnElement="GetDateAndTime">
307
+ <dc:Bounds x="670" y="600" width="100" height="80" />
308
+ <bpmndi:BPMNLabel />
309
+ </bpmndi:BPMNShape>
310
+ <bpmndi:BPMNShape id="Activity_0d8luif_di" bpmnElement="Search_Recipe">
311
+ <dc:Bounds x="920" y="600" width="100" height="80" />
312
+ <bpmndi:BPMNLabel />
313
+ </bpmndi:BPMNShape>
314
+ <bpmndi:BPMNShape id="BPMNShape_0x0a1hy" bpmnElement="SuperfluxProduct">
315
+ <dc:Bounds x="790" y="600" width="100" height="80" />
316
+ <bpmndi:BPMNLabel />
317
+ </bpmndi:BPMNShape>
318
+ <bpmndi:BPMNShape id="Activity_16uhg8o_di" bpmnElement="AskHumanToSendEmail">
319
+ <dc:Bounds x="670" y="730" width="100" height="80" />
320
+ <bpmndi:BPMNLabel />
321
+ </bpmndi:BPMNShape>
322
+ <bpmndi:BPMNShape id="Gateway_1lux75t_di" bpmnElement="Gateway_1lux75t" isMarkerVisible="true">
323
+ <dc:Bounds x="815" y="745" width="50" height="50" />
324
+ <bpmndi:BPMNLabel>
325
+ <dc:Bounds x="812" y="716" width="56" height="27" />
326
+ </bpmndi:BPMNLabel>
327
+ </bpmndi:BPMNShape>
328
+ <bpmndi:BPMNShape id="Event_1ny5xkz_di" bpmnElement="Event_1wxfv4u">
329
+ <dc:Bounds x="822" y="832" width="36" height="36" />
330
+ <bpmndi:BPMNLabel>
331
+ <dc:Bounds x="805" y="875" width="70" height="27" />
332
+ </bpmndi:BPMNLabel>
333
+ </bpmndi:BPMNShape>
334
+ <bpmndi:BPMNShape id="Activity_1sddc2g_di" bpmnElement="SendEmail">
335
+ <dc:Bounds x="910" y="730" width="100" height="80" />
336
+ </bpmndi:BPMNShape>
337
+ <bpmndi:BPMNEdge id="Flow_0demz1g_di" bpmnElement="Flow_0demz1g">
338
+ <di:waypoint x="770" y="770" />
339
+ <di:waypoint x="815" y="770" />
340
+ </bpmndi:BPMNEdge>
341
+ <bpmndi:BPMNEdge id="Flow_0uqjclh_di" bpmnElement="Flow_0uqjclh">
342
+ <di:waypoint x="865" y="770" />
343
+ <di:waypoint x="910" y="770" />
344
+ <bpmndi:BPMNLabel>
345
+ <dc:Bounds x="879" y="752" width="18" height="14" />
346
+ </bpmndi:BPMNLabel>
347
+ </bpmndi:BPMNEdge>
348
+ <bpmndi:BPMNEdge id="Flow_1l2ws6w_di" bpmnElement="Flow_1l2ws6w">
349
+ <di:waypoint x="840" y="795" />
350
+ <di:waypoint x="840" y="832" />
351
+ <bpmndi:BPMNLabel>
352
+ <dc:Bounds x="849" y="803" width="13" height="14" />
353
+ </bpmndi:BPMNLabel>
354
+ </bpmndi:BPMNEdge>
355
+ <bpmndi:BPMNShape id="TextAnnotation_0rg9ar3_di" bpmnElement="TextAnnotation_0rg9ar3">
356
+ <dc:Bounds x="401" y="80" width="578" height="170" />
357
+ <bpmndi:BPMNLabel />
358
+ </bpmndi:BPMNShape>
359
+ <bpmndi:BPMNShape id="TextAnnotation_1keavvi_di" bpmnElement="TextAnnotation_1keavvi">
360
+ <dc:Bounds x="1080" y="510" width="240" height="26" />
361
+ <bpmndi:BPMNLabel />
362
+ </bpmndi:BPMNShape>
363
+ <bpmndi:BPMNShape id="TextAnnotation_1cvjkfu_di" bpmnElement="TextAnnotation_1cvjkfu">
364
+ <dc:Bounds x="1210" y="660" width="260" height="60" />
365
+ <bpmndi:BPMNLabel />
366
+ </bpmndi:BPMNShape>
367
+ <bpmndi:BPMNShape id="TextAnnotation_1tvejhg_di" bpmnElement="TextAnnotation_1tvejhg">
368
+ <dc:Bounds x="1210" y="740" width="286" height="142" />
369
+ <bpmndi:BPMNLabel />
370
+ </bpmndi:BPMNShape>
371
+ <bpmndi:BPMNShape id="TextAnnotation_0xt28ql_di" bpmnElement="TextAnnotation_0xt28ql">
372
+ <dc:Bounds x="1168" y="920" width="370" height="26" />
373
+ <bpmndi:BPMNLabel />
374
+ </bpmndi:BPMNShape>
375
+ <bpmndi:BPMNEdge id="Flow_0pbzrme_di" bpmnElement="Flow_0pbzrme">
376
+ <di:waypoint x="188" y="460" />
377
+ <di:waypoint x="245" y="460" />
378
+ </bpmndi:BPMNEdge>
379
+ <bpmndi:BPMNEdge id="Flow_09y08ef_di" bpmnElement="Flow_09y08ef">
380
+ <di:waypoint x="740" y="460" />
381
+ <di:waypoint x="805" y="460" />
382
+ </bpmndi:BPMNEdge>
383
+ <bpmndi:BPMNEdge id="Flow_19gp461_di" bpmnElement="Flow_19gp461">
384
+ <di:waypoint x="830" y="435" />
385
+ <di:waypoint x="830" y="350" />
386
+ <di:waypoint x="270" y="350" />
387
+ <di:waypoint x="270" y="435" />
388
+ <bpmndi:BPMNLabel>
389
+ <dc:Bounds x="748" y="333" width="83" height="14" />
390
+ </bpmndi:BPMNLabel>
391
+ </bpmndi:BPMNEdge>
392
+ <bpmndi:BPMNEdge id="Flow_16c9bwj_di" bpmnElement="Flow_16c9bwj">
393
+ <di:waypoint x="855" y="460" />
394
+ <di:waypoint x="912" y="460" />
395
+ <bpmndi:BPMNLabel>
396
+ <dc:Bounds x="875" y="442" width="18" height="14" />
397
+ </bpmndi:BPMNLabel>
398
+ </bpmndi:BPMNEdge>
399
+ <bpmndi:BPMNEdge id="Flow_041ffce_di" bpmnElement="Flow_041ffce">
400
+ <di:waypoint x="440" y="460" />
401
+ <di:waypoint x="505" y="460" />
402
+ </bpmndi:BPMNEdge>
403
+ <bpmndi:BPMNEdge id="Flow_00lg7l2_di" bpmnElement="Flow_00lg7l2">
404
+ <di:waypoint x="530" y="485" />
405
+ <di:waypoint x="530" y="850" />
406
+ <di:waypoint x="640" y="850" />
407
+ <bpmndi:BPMNLabel>
408
+ <dc:Bounds x="541" y="492" width="18" height="14" />
409
+ </bpmndi:BPMNLabel>
410
+ </bpmndi:BPMNEdge>
411
+ <bpmndi:BPMNEdge id="Flow_11y3kim_di" bpmnElement="Flow_11y3kim">
412
+ <di:waypoint x="555" y="460" />
413
+ <di:waypoint x="640" y="460" />
414
+ <bpmndi:BPMNLabel>
415
+ <dc:Bounds x="591" y="442" width="13" height="14" />
416
+ </bpmndi:BPMNLabel>
417
+ </bpmndi:BPMNEdge>
418
+ <bpmndi:BPMNEdge id="Flow_050377t_di" bpmnElement="Flow_050377t">
419
+ <di:waypoint x="295" y="460" />
420
+ <di:waypoint x="340" y="460" />
421
+ </bpmndi:BPMNEdge>
422
+ <bpmndi:BPMNEdge id="Flow_01k9dy1_di" bpmnElement="Flow_01k9dy1">
423
+ <di:waypoint x="1040" y="850" />
424
+ <di:waypoint x="1150" y="850" />
425
+ <di:waypoint x="1150" y="950" />
426
+ <di:waypoint x="270" y="950" />
427
+ <di:waypoint x="270" y="485" />
428
+ </bpmndi:BPMNEdge>
429
+ <bpmndi:BPMNEdge id="Association_0ic98nl_di" bpmnElement="Association_0ic98nl">
430
+ <di:waypoint x="410" y="420" />
431
+ <di:waypoint x="495" y="250" />
432
+ </bpmndi:BPMNEdge>
433
+ <bpmndi:BPMNEdge id="Association_0q5n90x_di" bpmnElement="Association_0q5n90x">
434
+ <di:waypoint x="1040" y="620" />
435
+ <di:waypoint x="1120" y="536" />
436
+ </bpmndi:BPMNEdge>
437
+ <bpmndi:BPMNEdge id="Association_14t02ll_di" bpmnElement="Association_14t02ll">
438
+ <di:waypoint x="1040" y="902" />
439
+ <di:waypoint x="1160" y="933" />
440
+ </bpmndi:BPMNEdge>
441
+ </bpmndi:BPMNPlane>
442
+ </bpmndi:BPMNDiagram>
443
+ </bpmn:definitions>