This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git


The following commit(s) were added to refs/heads/main by this push:
     new c3d68c49bf Adds JVM tests for camel-quarkus-langchain4j-agent with 
quarkus-langchain4j
c3d68c49bf is described below

commit c3d68c49bf92a2f015b3f6ba5ca5a490998bf168
Author: JiriOndrusek <[email protected]>
AuthorDate: Tue Mar 24 11:16:07 2026 +0100

    Adds JVM tests for camel-quarkus-langchain4j-agent with quarkus-langchain4j
    
    Fixes #8377
    Fixes #8287
    Fixes #8288
    
    Co-authored-by: Jiri Ondrusek <[email protected]>
---
 .../deployment/QuarkusLangchain4jPresent.java      |  31 +++
 .../deployment/SupportLangchain4jProcessor.java    |   8 +-
 .../SupportQuarkusLangchain4jProcessor.java        |  88 ++++++++
 .../langchain4j/QuarkusLangchain4jRecorder.java    |  39 ++++
 .../langchain4j-agent-ql4j/README.adoc             |  34 ++++
 .../langchain4j-agent-ql4j/pom.xml                 | 222 +++++++++++++++++++++
 .../src/main/resources/application.properties      |  22 ++
 .../agent/it/Langchain4jAgentQl4jProfile.java      |  29 +++
 .../agent/it/Langchain4jAgentQl4jTest.java         |  46 +++++
 ..._chat-07697830-e3e8-4de0-ab1a-0387d82fa1f9.json |  10 +-
 ..._chat-18327c5c-fa3b-4848-9c4f-6ed6098e5117.json |  10 +-
 ..._chat-19601aeb-7179-46eb-ad3e-f25d2c18a896.json |   8 +-
 ..._chat-19be9646-6a92-4cb4-a591-b8c058b5d0fa.json |   8 +-
 ..._chat-1cf59dd2-bee9-45f5-8e0a-7369d6656860.json |  24 +++
 ..._chat-2276f051-cf9a-4475-aed4-6754bac3b1f7.json |  10 +-
 ..._chat-2900fd1c-0ebc-42ff-b6ee-ba8caf689719.json |  24 +++
 ..._chat-4258d73c-c1e9-405a-8500-8e3053196ccd.json |  24 +++
 ..._chat-4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c.json |  10 +-
 ..._chat-735d56ed-7b5f-476d-ae91-8c1bb851d16f.json |  10 +-
 ..._chat-89dc149d-8f49-42e4-b157-ca193826fb97.json |  10 +-
 ..._chat-a7f5dc9a-3330-441d-8824-d913baaf2515.json |  10 +-
 ..._chat-af34c8aa-386e-484c-b7b1-5635fc121443.json |  24 +++
 ..._chat-cd782b16-9b47-43d1-966d-f57f33ed5718.json |  10 +-
 ..._chat-d44e4f60-fcba-4b6a-b468-110c5ef3968f.json |  24 +++
 ..._chat-f25e934d-75c9-4136-937c-5be74d187f81.json |  24 +++
 ..._chat-f6c67707-2d86-4806-9a70-2e3b87f76f38.json |  10 +-
 ..._chat-f76fd9b1-66ac-4d0e-bbbb-795b5e05509d.json |  10 +-
 integration-tests-jvm/pom.xml                      |   1 +
 .../langchain4j/agent/it/AgentProducers.java       |   5 +-
 .../agent/it/Langchain4jAgentTestResource.java     |  62 +++++-
 ...embed-1e8084ee-91b3-4095-86b7-9845fe1480d6.json |   1 -
 ..._chat-07483132-9cdf-4380-9dc7-98735923d83f.json |  24 +++
 ...chat-169fb9d1-d29b-4e95-84a4-1ab133179ce5.json} |   8 +-
 ...chat-19d22465-3fb9-4f32-94b0-e0abf68f0df6.json} |   8 +-
 ...chat-1a58e2d0-7224-4a5e-a01b-318e83a9fb29.json} |   8 +-
 ..._chat-2578100a-828a-4b81-bbf2-81dfd2a133b2.json |  24 +++
 ...chat-3397f049-5f70-40ca-ab2f-8169b147fef4.json} |   8 +-
 ...chat-35248f94-bc7e-471a-af71-f485e1621fb4.json} |   8 +-
 ...chat-3bd2313a-d8c2-45cf-98a3-1291e61dbed8.json} |   8 +-
 ..._chat-3d26b3c9-b392-4bb6-b3e6-622c857fc1a4.json |  24 +++
 ..._chat-3d941d4b-d1e9-4e58-aeaf-d52756afeef0.json |  24 +++
 ..._chat-4bd017da-a2a1-4206-b70e-7c0a3f9ddc11.json |  26 ---
 ...chat-4fb0b393-7f23-4703-8a09-a146222baf05.json} |   8 +-
 ...chat-5716f4c5-5f23-4975-8015-0e0026572e7c.json} |   8 +-
 ..._chat-65a5a977-8a4c-4c28-aff7-f4dc7500df43.json |  27 ---
 ..._chat-68c8507d-160c-4641-9a22-84bbe4806890.json |  24 ---
 ...chat-72fd4b94-5f4a-46c4-89c8-8bdec51c9229.json} |   8 +-
 ..._chat-84aa25c6-6069-4780-b9d4-4068a07c101a.json |  24 ---
 ...chat-a6509799-4ad7-4943-8292-0c40ef7a0694.json} |   8 +-
 ...chat-bec7f213-4af1-44b3-bd8e-3e9bcede5363.json} |   8 +-
 ...chat-d4d23b6e-6f85-47ec-8c60-0dafee1ea394.json} |   8 +-
 ...chat-d74a88a5-321f-4d42-8a5e-28ba35105e81.json} |   8 +-
 ..._chat-f472d5b5-8789-4bd9-8e7d-8649badd493b.json |  27 ---
 ...chat-ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5.json} |  13 +-
 54 files changed, 928 insertions(+), 261 deletions(-)

diff --git 
a/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/QuarkusLangchain4jPresent.java
 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/QuarkusLangchain4jPresent.java
new file mode 100644
index 0000000000..7741e015dc
--- /dev/null
+++ 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/QuarkusLangchain4jPresent.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.component.support.langchain4j.deployment;
+
+import java.util.function.BooleanSupplier;
+
+public class QuarkusLangchain4jPresent implements BooleanSupplier {
+    @Override
+    public boolean getAsBoolean() {
+        try {
+            
Thread.currentThread().getContextClassLoader().loadClass("io.quarkiverse.langchain4j.RegisterAiService");
+            return true;
+        } catch (ClassNotFoundException e) {
+            return false;
+        }
+    }
+}
diff --git 
a/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportLangchain4jProcessor.java
 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportLangchain4jProcessor.java
index 6c74ee9185..850acfd807 100644
--- 
a/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportLangchain4jProcessor.java
+++ 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportLangchain4jProcessor.java
@@ -242,7 +242,7 @@ class SupportLangchain4jProcessor {
                 .filter(classInfo -> 
classInfo.name().toString().startsWith("dev.langchain4j"));
     }
 
-    @BuildStep(onlyIf = NativeOrNativeSourcesBuild.class)
+    @BuildStep
     void indexDjlDependencies(
             CurateOutcomeBuildItem curateOutcome,
             BuildProducer<IndexDependencyBuildItem> indexDependency) {
@@ -259,7 +259,7 @@ class SupportLangchain4jProcessor {
         }
     }
 
-    @BuildStep(onlyIf = NativeOrNativeSourcesBuild.class)
+    @BuildStep
     void nativeImageResources(
             CurateOutcomeBuildItem curateOutcome,
             BuildProducer<NativeImageResourcePatternsBuildItem> 
nativeImageResourcePattern,
@@ -313,7 +313,7 @@ class SupportLangchain4jProcessor {
         }
     }
 
-    @BuildStep(onlyIf = NativeOrNativeSourcesBuild.class)
+    @BuildStep
     void jniRuntimeSupport(
             BuildProducer<ReflectiveClassBuildItem> reflectiveClass,
             BuildProducer<JniRuntimeAccessBuildItem> jniRuntimeAccess) {
@@ -348,7 +348,7 @@ class SupportLangchain4jProcessor {
         
reflectiveClass.produce(ReflectiveClassBuildItem.builder("opennlp.tools.sentdetect.SentenceDetectorFactory").build());
     }
 
-    @BuildStep(onlyIf = NativeOrNativeSourcesBuild.class)
+    @BuildStep
     void runtimeInitializedClasses(
             CombinedIndexBuildItem combinedIndex,
             BuildProducer<RuntimeInitializedClassBuildItem> 
runtimeInitializedClass) {
diff --git 
a/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportQuarkusLangchain4jProcessor.java
 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportQuarkusLangchain4jProcessor.java
new file mode 100644
index 0000000000..22c19056de
--- /dev/null
+++ 
b/extensions-support/langchain4j/deployment/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/deployment/SupportQuarkusLangchain4jProcessor.java
@@ -0,0 +1,88 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.component.support.langchain4j.deployment;
+
+import java.util.Set;
+import java.util.stream.Collectors;
+
+import dev.langchain4j.guardrail.Guardrail;
+import dev.langchain4j.guardrail.InputGuardrail;
+import dev.langchain4j.guardrail.OutputGuardrail;
+import io.quarkus.arc.deployment.SyntheticBeanBuildItem;
+import io.quarkus.deployment.annotations.BuildProducer;
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.annotations.BuildSteps;
+import io.quarkus.deployment.annotations.ExecutionTime;
+import io.quarkus.deployment.annotations.Record;
+import io.quarkus.deployment.builditem.CombinedIndexBuildItem;
+import io.quarkus.deployment.builditem.SystemPropertyBuildItem;
+import jakarta.inject.Singleton;
+import 
org.apache.camel.quarkus.component.support.langchain4j.QuarkusLangchain4jRecorder;
+import org.jboss.jandex.ClassInfo;
+import org.jboss.jandex.DotName;
+import org.jboss.jandex.IndexView;
+
+/**
+ * Build steps required only when Quarkus LangChain4j is detected.
+ */
+@BuildSteps(onlyIf = QuarkusLangchain4jPresent.class)
+class SupportQuarkusLangchain4jProcessor {
+    @BuildStep
+    SystemPropertyBuildItem enforceJaxRsHttpClient() {
+        return new 
SystemPropertyBuildItem("langchain4j.http.clientBuilderFactory",
+                
"io.quarkiverse.langchain4j.jaxrsclient.JaxRsHttpClientBuilderFactory");
+    }
+
+    @SuppressWarnings("unchecked")
+    @BuildStep
+    @Record(ExecutionTime.STATIC_INIT)
+    void registerLangChain4jAiServiceTypesForReflection(
+            CombinedIndexBuildItem combinedIndex,
+            BuildProducer<SyntheticBeanBuildItem> syntheticBeans,
+            QuarkusLangchain4jRecorder recorder) {
+        IndexView index = combinedIndex.getIndex();
+        // Guardrails are instantiated dynamically
+        Set<DotName> guardrailTypes = 
index.getAllKnownImplementations(InputGuardrail.class)
+                .stream()
+                .map(ClassInfo::name)
+                .collect(Collectors.toSet());
+
+        index.getAllKnownImplementations(OutputGuardrail.class)
+                .stream()
+                .map(ClassInfo::name)
+                .forEach(guardrailTypes::add);
+
+        guardrailTypes.stream()
+                .filter(s -> 
!s.toString().equals("dev.langchain4j.guardrail.JsonExtractorOutputGuardrail"))
+                .forEach(s -> {
+                    try {
+                        Class<Guardrail<?, ?>> guardrailClass;
+                        guardrailClass = (Class<Guardrail<?, ?>>) 
Thread.currentThread()
+                                .getContextClassLoader()
+                                .loadClass(s.toString());
+                        syntheticBeans
+                                .produce(SyntheticBeanBuildItem.configure(s)
+                                        .scope(Singleton.class)
+                                        .named("GuardrailSynthetic" + 
s.local())
+                                        
.runtimeValue(recorder.instantiateGuardrails(guardrailClass))
+                                        .done());
+                    } catch (ClassNotFoundException e) {
+                        throw new RuntimeException(e);
+                    }
+                });
+    }
+}
diff --git 
a/extensions-support/langchain4j/runtime/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/QuarkusLangchain4jRecorder.java
 
b/extensions-support/langchain4j/runtime/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/QuarkusLangchain4jRecorder.java
new file mode 100644
index 0000000000..af6301a6c9
--- /dev/null
+++ 
b/extensions-support/langchain4j/runtime/src/main/java/org/apache/camel/quarkus/component/support/langchain4j/QuarkusLangchain4jRecorder.java
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.component.support.langchain4j;
+
+import java.lang.reflect.InvocationTargetException;
+
+import dev.langchain4j.guardrail.Guardrail;
+import io.quarkus.runtime.RuntimeValue;
+import io.quarkus.runtime.annotations.Recorder;
+import org.jboss.logging.Logger;
+
+@Recorder
+public class QuarkusLangchain4jRecorder {
+
+    public RuntimeValue<Guardrail<?, ?>> 
instantiateGuardrails(Class<Guardrail<?, ?>> guardrailClass) {
+        try {
+            return new 
RuntimeValue<>(guardrailClass.getConstructor().newInstance());
+        } catch (NoSuchMethodException | InvocationTargetException | 
InstantiationException
+                | IllegalAccessException e) {
+            Logger.getLogger(QuarkusLangchain4jRecorder.class).debugf(e,
+                    "Can not instantiate guardrail of class %s", 
guardrailClass.getName());
+            return null;
+        }
+    }
+}
diff --git a/integration-tests-jvm/langchain4j-agent-ql4j/README.adoc 
b/integration-tests-jvm/langchain4j-agent-ql4j/README.adoc
new file mode 100644
index 0000000000..2eab7e2617
--- /dev/null
+++ b/integration-tests-jvm/langchain4j-agent-ql4j/README.adoc
@@ -0,0 +1,34 @@
+== Limitations of Quarkus LangChain4j being on the classpath
+
+ * Does not work in the native
+ * QL4J requires a different httpClient - 
`io.quarkiverse.langchain4j.jaxrsclient.JaxRsHttpClientBuilderFactory`. See 
processor and recorder for more information.
+ * Even if tests are using `AgentWithoutMemory`, QL4J creates agentWithMemory 
automatically
+
+[IMPORTANT]
+If a `RetrievalAugmentor` with the default scope exists, QL4J detects it and 
applies it to the `AiAgent` (which should not have the `RetrievalAugmentor` at 
all).
+The issue can be simulated on the test `simpleUserMessage` (see QL4J 
https://github.com/quarkiverse/quarkus-langchain4j/blob/8cae9528c12bd0dce143fe2f63daa1660bfcd018/core/runtime/src/main/java/io/quarkiverse/langchain4j/RegisterAiService.java#L136[code]).
+Fot that reason, the  `RetrievalAugmentor` in `AgentProducer` is annotated via 
`@LookupUnlessProperty`, to disable lookup for the QL4J tests.
+Camel-langchain4j works event if lookup is disabled!
+
+== Camel Quarkus Langchain4j Agent with Quarkus LangChain4j Integration Tests
+
+By default, the langchain4j-agent-ql4j integration tests use WireMock to stub 
Ollama API interactions.
+
+To run the `camel-quarkus-langchain4j-agent-ql4j` integration tests against 
the real API, you need a Ollama instance running with the `orca-mini` & 
`granite4:3b` models downloaded.
+
+The MCP client tests require https://nodejs.org/[Node.js] to be installed on 
the test host.
+
+When Ollama is running, set the following environment variables:
+
+[source,shell]
+----
+export LANGCHAIN4J_OLLAMA_BASE_URL=your-ollama-api-url
+----
+
+If the WireMock stub recordings need updating, then remove the existing files 
from `src/test/resources/mappings` and run tests with either:
+
+System property `-Dwiremock.record=true`
+
+Or
+
+Set environment variable `WIREMOCK_RECORD=true`
diff --git a/integration-tests-jvm/langchain4j-agent-ql4j/pom.xml 
b/integration-tests-jvm/langchain4j-agent-ql4j/pom.xml
new file mode 100644
index 0000000000..9cd71d9f9e
--- /dev/null
+++ b/integration-tests-jvm/langchain4j-agent-ql4j/pom.xml
@@ -0,0 +1,222 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+         http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.apache.camel.quarkus</groupId>
+        <artifactId>camel-quarkus-build-parent-it</artifactId>
+        <version>3.35.0-SNAPSHOT</version>
+        <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+    </parent>
+
+    
<artifactId>camel-quarkus-integration-test-langchain4j-agent-ql4j</artifactId>
+    <name>Camel Quarkus :: Integration Tests :: LangChain4j Agent QL4J</name>
+    <description>Integration tests for Camel Quarkus LangChain4j Agent 
extension with Quarkus LangChain4j</description>
+
+    <dependencyManagement>
+        <dependencies>
+            <dependency>
+                <groupId>io.quarkiverse.langchain4j</groupId>
+                <artifactId>quarkus-langchain4j-bom</artifactId>
+                <version>${quarkiverse-langchain4j.version}</version>
+                <type>pom</type>
+                <scope>import</scope>
+            </dependency>
+        </dependencies>
+    </dependencyManagement>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-direct</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-langchain4j-agent</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-langchain4j-tools</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-seda</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>io.quarkus</groupId>
+            <artifactId>quarkus-rest</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.quarkus</groupId>
+            <artifactId>quarkus-rest-jackson</artifactId>
+        </dependency>
+
+        <!-- Quarkus-langchain4j dependencies-->
+        <dependency>
+            <groupId>io.quarkiverse.langchain4j</groupId>
+            <artifactId>quarkus-langchain4j-ollama</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>dev.langchain4j</groupId>
+            <artifactId>langchain4j-embeddings-all-minilm-l6-v2</artifactId>
+        </dependency>
+
+        <!-- test dependencies -->
+        <dependency>
+            <groupId>io.quarkus</groupId>
+            <artifactId>quarkus-junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>io.rest-assured</groupId>
+            <artifactId>rest-assured</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-integration-wiremock-support</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.codehaus.gmavenplus</groupId>
+                <artifactId>gmavenplus-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>group-sources</id>
+                        <goals>
+                            <goal>execute</goal>
+                        </goals>
+                        <phase>generate-sources</phase>
+                        <configuration>
+                            <scripts>
+                                
<script>file:${maven.multiModuleProjectDirectory}/tooling/scripts/copy-tests.groovy</script>
+                            </scripts>
+                            <properties>
+                                
<copy-tests.excludes>**/*api_chat*</copy-tests.excludes>
+                                
<copy-tests.source.dir>${maven.multiModuleProjectDirectory}/integration-tests/langchain4j-agent</copy-tests.source.dir>
+                                
<copy-tests.dest.module.dir>${project.basedir}</copy-tests.dest.module.dir>
+                            </properties>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>add-sources</id>
+                        <phase>generate-sources</phase>
+                        <goals>
+                            <goal>add-source</goal>
+                        </goals>
+                        <configuration>
+                            <sources>
+                                
<source>${basedir}/target/src/main/java</source>
+                            </sources>
+                        </configuration>
+                    </execution>
+                    <execution>
+                        <id>add-test-sources</id>
+                        <phase>generate-sources</phase>
+                        <goals>
+                            <goal>add-test-source</goal>
+                        </goals>
+                        <configuration>
+                            <sources>
+                                
<source>${basedir}/target/src/test/java</source>
+                            </sources>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+        </plugins>
+    </build>
+    <profiles>
+        <profile>
+            <id>virtualDependencies</id>
+            <activation>
+                <property>
+                    <name>!noVirtualDependencies</name>
+                </property>
+            </activation>
+            <dependencies>
+                <!-- The following dependencies guarantee that this module is 
built after them. You can update them by running `mvn process-resources 
-Pformat -N` from the source tree root directory -->
+                <dependency>
+                    <groupId>org.apache.camel.quarkus</groupId>
+                    <artifactId>camel-quarkus-direct-deployment</artifactId>
+                    <version>${project.version}</version>
+                    <type>pom</type>
+                    <scope>test</scope>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>*</groupId>
+                            <artifactId>*</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.camel.quarkus</groupId>
+                    
<artifactId>camel-quarkus-langchain4j-agent-deployment</artifactId>
+                    <version>${project.version}</version>
+                    <type>pom</type>
+                    <scope>test</scope>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>*</groupId>
+                            <artifactId>*</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.camel.quarkus</groupId>
+                    
<artifactId>camel-quarkus-langchain4j-tools-deployment</artifactId>
+                    <version>${project.version}</version>
+                    <type>pom</type>
+                    <scope>test</scope>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>*</groupId>
+                            <artifactId>*</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.camel.quarkus</groupId>
+                    <artifactId>camel-quarkus-seda-deployment</artifactId>
+                    <version>${project.version}</version>
+                    <type>pom</type>
+                    <scope>test</scope>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>*</groupId>
+                            <artifactId>*</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+            </dependencies>
+        </profile>
+    </profiles>
+</project>
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/main/resources/application.properties
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/main/resources/application.properties
new file mode 100644
index 0000000000..6e068962d6
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/main/resources/application.properties
@@ -0,0 +1,22 @@
+## ---------------------------------------------------------------------------
+## Licensed to the Apache Software Foundation (ASF) under one or more
+## contributor license agreements.  See the NOTICE file distributed with
+## this work for additional information regarding copyright ownership.
+## The ASF licenses this file to You under the Apache License, Version 2.0
+## (the "License"); you may not use this file except in compliance with
+## the License.  You may obtain a copy of the License at
+##
+##      http://www.apache.org/licenses/LICENSE-2.0
+##
+## Unless required by applicable law or agreed to in writing, software
+## distributed under the License is distributed on an "AS IS" BASIS,
+## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+## See the License for the specific language governing permissions and
+## limitations under the License.
+## ---------------------------------------------------------------------------
+
+quarkus.devservices.enabled=false
+
+# Testing with quarkus-langchain4j does not work when the RetrievalAugmentor 
bean produced by AgentProducers.retrievalAugmentor is present with scope 
<default>.
+# See README.adoc for more details.
+cq-test.retrieval.augmentor.disabled=true
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jProfile.java
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jProfile.java
new file mode 100644
index 0000000000..3c31944f0d
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jProfile.java
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.component.langchain4j.agent.it;
+
+import java.util.Collections;
+import java.util.Map;
+
+import io.quarkus.test.junit.QuarkusTestProfile;
+
+public class Langchain4jAgentQl4jProfile implements QuarkusTestProfile {
+    public Map<String, String> getConfigOverrides() {
+        // Covers failure with RetrievalAugmentor with scope <default>, see 
README.adoc
+        return 
Collections.singletonMap("cq-test.retrieval.augmentor.disabled", "false");
+    }
+}
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jTest.java
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jTest.java
new file mode 100644
index 0000000000..71653126ae
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentQl4jTest.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.component.langchain4j.agent.it;
+
+import io.quarkus.test.common.QuarkusTestResource;
+import io.quarkus.test.junit.QuarkusTest;
+import io.quarkus.test.junit.TestProfile;
+import io.restassured.RestAssured;
+import org.junit.jupiter.api.Disabled;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.extension.ExtendWith;
+
+import static org.hamcrest.Matchers.*;
+
+@ExtendWith(Langchain4jTestWatcher.class)
+@QuarkusTestResource(Langchain4jAgentTestResource.class)
+@TestProfile(Langchain4jAgentQl4jProfile.class)
+@QuarkusTest
+@Disabled("https://github.com/apache/camel-quarkus/issues/8412";)
+class Langchain4jAgentQl4jTest {
+    @Test
+    void simpleUserMessage() {
+        RestAssured.given()
+                .body(Langchain4jAgentTest.TEST_USER_MESSAGE_SIMPLE)
+                .post("/langchain4j-agent/simple")
+                .then()
+                .statusCode(200)
+                .body(
+                        not(Langchain4jAgentTest.TEST_USER_MESSAGE_SIMPLE),
+                        containsString("Apache Camel"));
+    }
+}
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-07697830-e3e8-4de0-ab1a-0387d82fa1f9.json
similarity index 76%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-07697830-e3e8-4de0-ab1a-0387d82fa1f9.json
index 59a3865afa..25cfd2a638 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-07697830-e3e8-4de0-ab1a-0387d82fa1f9.json
@@ -1,5 +1,5 @@
 {
-  "id" : "3dbd2721-ecf7-4960-a6d9-532629c974d1",
+  "id" : "07697830-e3e8-4de0-ab1a-0387d82fa1f9",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:15.36019929Z\",\"message\":{\"role\":\"assistant\",\"content\":\"John
 
Doe\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":873488110,\"load_duration\":53320906,\"prompt_eval_count\":248,\"prompt_eval_duration\":704054631,\"eval_count\":3,\"eval_duration\":110231366}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:52:36.470066243Z\",\"message\":{\"role\":\"assistant\",\"content\":\"John
 
Doe\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":534016062,\"load_duration\":53519445,\"prompt_eval_count\":248,\"prompt_eval_duration\":373541986,\"eval_count\":3,\"eval_duration\":102695006}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:15 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:52:36 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "3dbd2721-ecf7-4960-a6d9-532629c974d1",
+  "uuid" : "07697830-e3e8-4de0-ab1a-0387d82fa1f9",
   "persistent" : true,
-  "insertionIndex" : 19
+  "insertionIndex" : 20
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-18327c5c-fa3b-4848-9c4f-6ed6098e5117.json
similarity index 81%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-18327c5c-fa3b-4848-9c4f-6ed6098e5117.json
index 66426d79ea..ade89e0be7 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-18327c5c-fa3b-4848-9c4f-6ed6098e5117.json
@@ -1,5 +1,5 @@
 {
-  "id" : "19496598-286d-4354-8021-d0141973f657",
+  "id" : "18327c5c-fa3b-4848-9c4f-6ed6098e5117",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:55.26755228Z\",\"message\":{\"role\":\"assistant\",\"content\":\"[\\n
  \\\"longRunningOperation\\\",\\n  \\\"add\\\",\\n  
\\\"echo\\\"\\n]\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":7199497126,\"load_duration\":44301920,\"prompt_eval_count\":326,\"prompt_eval_duration\":6246528366,\"eval_count\":17,\"eval_duration\":894557129}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:17.439073328Z\",\"message\":{\"role\":\"assistant\",\"content\":\"[\\n
  \\\"longRunningOperation\\\",\\n  \\\"add\\\",\\n  
\\\"echo\\\"\\n]\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":6552718997,\"load_duration\":1604485978,\"prompt_eval_count\":326,\"prompt_eval_duration\":4118866394,\"eval_count\":17,\"eval_duration\":818722420}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:55 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:17 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "19496598-286d-4354-8021-d0141973f657",
+  "uuid" : "18327c5c-fa3b-4848-9c4f-6ed6098e5117",
   "persistent" : true,
-  "insertionIndex" : 14
+  "insertionIndex" : 15
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19601aeb-7179-46eb-ad3e-f25d2c18a896.json
similarity index 59%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19601aeb-7179-46eb-ad3e-f25d2c18a896.json
index 404d65bc24..31e6d982ce 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19601aeb-7179-46eb-ad3e-f25d2c18a896.json
@@ -1,5 +1,5 @@
 {
-  "id" : "ea5aa343-879e-4dd0-94f5-c32886e33ec6",
+  "id" : "19601aeb-7179-46eb-ad3e-f25d2c18a896",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:24.28582676Z\",\"message\":{\"role\":\"assistant\",\"content\":\"That's
 a lovely choice of color! Blue is often associated with tranquility, 
stability, and depth. If you need any information or assistance related to the 
color blue or anything else, feel free to 
ask.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2701949220,\"load_duration\":49357826,\"prompt_eval_count\":69,\"prompt_eval_duration\":3
 [...]
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:56.072101845Z\",\"message\":{\"role\":\"assistant\",\"content\":\"That's
 a lovely choice of color! Blue often symbolizes tranquility, stability, and 
intelligence. If you need any assistance with something related to the color 
blue or anything else, please feel free to 
ask.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2362851743,\"load_duration\":53976634,\"prompt_eval_count\":69,\"prompt_eval_durat
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:24 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:56 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "ea5aa343-879e-4dd0-94f5-c32886e33ec6",
+  "uuid" : "19601aeb-7179-46eb-ad3e-f25d2c18a896",
   "persistent" : true,
   "insertionIndex" : 4
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19be9646-6a92-4cb4-a591-b8c058b5d0fa.json
similarity index 69%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19be9646-6a92-4cb4-a591-b8c058b5d0fa.json
index 53ad1cb5fe..2513f9e073 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-19be9646-6a92-4cb4-a591-b8c058b5d0fa.json
@@ -1,5 +1,5 @@
 {
-  "id" : "b682d927-b36f-427d-b404-b754b054ddb9",
+  "id" : "19be9646-6a92-4cb4-a591-b8c058b5d0fa",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:21.562588173Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Hello
 Alice! It's nice to meet you. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1615998648,\"load_duration\":48578413,\"prompt_eval_count\":36,\"prompt_eval_duration\":645865891,\"eval_count\":18,\"eval_duration\":909874821}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:53.555078401Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Hello
 Alice! It's nice to meet you. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2918023975,\"load_duration\":1621811779,\"prompt_eval_count\":36,\"prompt_eval_duration\":444829594,\"eval_count\":18,\"eval_duration\":842104365}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:21 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:53 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "b682d927-b36f-427d-b404-b754b054ddb9",
+  "uuid" : "19be9646-6a92-4cb4-a591-b8c058b5d0fa",
   "persistent" : true,
   "insertionIndex" : 5
 }
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-1cf59dd2-bee9-45f5-8e0a-7369d6656860.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-1cf59dd2-bee9-45f5-8e0a-7369d6656860.json
new file mode 100644
index 0000000000..ba905c5267
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-1cf59dd2-bee9-45f5-8e0a-7369d6656860.json
@@ -0,0 +1,24 @@
+{
+  "id" : "1cf59dd2-bee9-45f5-8e0a-7369d6656860",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"granite4:3b\",\n  \"messages\" : [ 
{\n    \"role\" : \"user\",\n    \"content\" : \"Calculate the addition of 10 + 
5\"\n  }, {\n    \"role\" : \"assistant\",\n    \"tool_calls\" : [ {\n      
\"function\" : {\n        \"name\" : \"addNumbers\",\n        \"arguments\" : 
{\n          \"a\" : 10,\n          \"b\" : 5\n        }\n      }\n    } ]\n  
}, {\n    \"role\" : \"tool\",\n    \"content\" : \"15\"\n  } ],\n  \"options\" 
: {\n    \"temperature\ [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:34.90049304Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 result of adding 10 and 5 is 
**15**.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1067473083,\"load_duration\":53592261,\"prompt_eval_count\":221,\"prompt_eval_duration\":294501968,\"eval_count\":15,\"eval_duration\":710204520}",
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:53:34 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "1cf59dd2-bee9-45f5-8e0a-7369d6656860",
+  "persistent" : true,
+  "insertionIndex" : 10
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2276f051-cf9a-4475-aed4-6754bac3b1f7.json
similarity index 83%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2276f051-cf9a-4475-aed4-6754bac3b1f7.json
index a97b6e2bce..696f0b8702 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2276f051-cf9a-4475-aed4-6754bac3b1f7.json
@@ -1,5 +1,5 @@
 {
-  "id" : "d366f73b-f02a-4f62-ad43-836f42226e05",
+  "id" : "2276f051-cf9a-4475-aed4-6754bac3b1f7",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:02.290064872Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 long running operation was executed successfully with a total duration of 2 
seconds divided into 2 steps. The process completed as expected without any 
issues.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2629078989,\"load_duration\":45655974,\"prompt_eval_count\":372,\"prompt_eval_duration\":868889130,\"eval_count\":31,\"eval_du
 [...]
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:23.440448006Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 long running operation was executed successfully with a duration of 2 seconds 
and divided into 2 steps. The operation completed as 
expected.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1929759379,\"load_duration\":52765178,\"prompt_eval_count\":372,\"prompt_eval_duration\":468280959,\"eval_count\":28,\"eval_duration\":1393150513}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:02 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:23 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "d366f73b-f02a-4f62-ad43-836f42226e05",
+  "uuid" : "2276f051-cf9a-4475-aed4-6754bac3b1f7",
   "persistent" : true,
-  "insertionIndex" : 12
+  "insertionIndex" : 13
 }
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2900fd1c-0ebc-42ff-b6ee-ba8caf689719.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2900fd1c-0ebc-42ff-b6ee-ba8caf689719.json
new file mode 100644
index 0000000000..b427dde4c4
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-2900fd1c-0ebc-42ff-b6ee-ba8caf689719.json
@@ -0,0 +1,24 @@
+{
+  "id" : "2900fd1c-0ebc-42ff-b6ee-ba8caf689719",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"granite4:3b\",\n  \"messages\" : [ 
{\n    \"role\" : \"user\",\n    \"content\" : \"Calculate the addition of 10 + 
5\"\n  } ],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ 
]\n  },\n  \"stream\" : false,\n  \"tools\" : [ {\n    \"type\" : 
\"function\",\n    \"function\" : {\n      \"name\" : \"addNumbers\",\n      
\"description\" : \"Adds two numbers\",\n      \"parameters\" : {\n        
\"type\" : \"object\",\n        \"proper [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:33.750026429Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_ierq4t3o\",\"function\":{\"index\":0,\"name\":\"addNumbers\",\"arguments\":{\"a\":10,\"b\":5}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5120589516,\"load_duration\":1619646660,\"prompt_eval_count\":183,\"prompt_eval_duration\":2226615831,\"eval_count\":26,\"eval_duration\":1260580895}",
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:53:33 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "2900fd1c-0ebc-42ff-b6ee-ba8caf689719",
+  "persistent" : true,
+  "insertionIndex" : 11
+}
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4258d73c-c1e9-405a-8500-8e3053196ccd.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4258d73c-c1e9-405a-8500-8e3053196ccd.json
new file mode 100644
index 0000000000..78335e9403
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4258d73c-c1e9-405a-8500-8e3053196ccd.json
@@ -0,0 +1,24 @@
+{
+  "id" : "4258d73c-c1e9-405a-8500-8e3053196ccd",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"Return an example JSON object 
about a person named 'John Doe' with the fields age and description\"\n  } ],\n 
 \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:53:41.641750586Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Here is an example JSON object about John Doe with the fields age and 
description:\\n\\n```json\\n{\\n \\\"name\\\": \\\"John Doe\\\",\\n 
\\\"age\\\": 30,\\n \\\"description\\\": \\\"John Doe is a professional in the 
field of technology. He has worked for several years and has a wealth of 
experience.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"s [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:53:41 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "4258d73c-c1e9-405a-8500-8e3053196ccd",
+  "persistent" : true,
+  "insertionIndex" : 8
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-63b71ca8-026b-471b-a34a-da7660be2631.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c.json
similarity index 60%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-63b71ca8-026b-471b-a34a-da7660be2631.json
rename to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c.json
index d49c93a8b8..b4f56eeaa7 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-63b71ca8-026b-471b-a34a-da7660be2631.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c.json
@@ -1,5 +1,5 @@
 {
-  "id" : "63b71ca8-026b-471b-a34a-da7660be2631",
+  "id" : "4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,15 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:27.290839245Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Hello, Alice. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":932736372,\"load_duration\":11343198,\"prompt_eval_count\":46,\"prompt_eval_duration\":341050678,\"eval_count\":12,\"eval_duration\":576140320}",
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:54:00.171109276Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Hello, Alice. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2272290502,\"load_duration\":1217699940,\"prompt_eval_count\":46,\"prompt_eval_duration\":525193681,\"eval_count\":12,\"eval_duration\":526304397}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:27 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:54:00 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "63b71ca8-026b-471b-a34a-da7660be2631",
+  "uuid" : "4dd7ecb9-7dbe-48f5-9b4f-481a21e1144c",
   "persistent" : true,
-  "scenarioName" : "scenario-2-api-chat",
-  "requiredScenarioState" : "scenario-2-api-chat-3",
   "insertionIndex" : 2
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-735d56ed-7b5f-476d-ae91-8c1bb851d16f.json
similarity index 52%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-735d56ed-7b5f-476d-ae91-8c1bb851d16f.json
index a2a35834f7..1e592010bb 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-735d56ed-7b5f-476d-ae91-8c1bb851d16f.json
@@ -1,5 +1,5 @@
 {
-  "id" : "5b13dcfa-8f76-45b3-a149-6c43182869dd",
+  "id" : "735d56ed-7b5f-476d-ae91-8c1bb851d16f",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:47.817132698Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"An example person 
with a unique name and a brief 
description\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":3933350526,\"load_duration\":11705957,\"prompt_eval_count\":60,\"prompt_eval_duration\
 [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:53:10.671236989Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Here is an example JSON object about John Doe with the fields name and 
description:\\n\\n```json\\n{\\n \\\"name\\\": \\\"John Doe\\\",\\n 
\\\"description\\\": \\\"An example person with the name John 
Doe\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":3136126679,\"load_duration\":17379924,\"prompt_eval_count\":60,\"prompt_
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:47 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:10 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "5b13dcfa-8f76-45b3-a149-6c43182869dd",
+  "uuid" : "735d56ed-7b5f-476d-ae91-8c1bb851d16f",
   "persistent" : true,
-  "insertionIndex" : 15
+  "insertionIndex" : 16
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-e7f6e7af-412b-4f34-887c-d19ee0c66d8b.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-89dc149d-8f49-42e4-b157-ca193826fb97.json
similarity index 55%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-e7f6e7af-412b-4f34-887c-d19ee0c66d8b.json
rename to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-89dc149d-8f49-42e4-b157-ca193826fb97.json
index 4e95ba3c7f..312f380d19 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-e7f6e7af-412b-4f34-887c-d19ee0c66d8b.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-89dc149d-8f49-42e4-b157-ca193826fb97.json
@@ -1,24 +1,24 @@
 {
-  "id" : "e7f6e7af-412b-4f34-887c-d19ee0c66d8b",
+  "id" : "89dc149d-8f49-42e4-b157-ca193826fb97",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
     "method" : "POST",
     "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"granite4:3b\",\n  \"messages\" : [ 
{\n    \"role\" : \"user\",\n    \"content\" : \"Hello - my name is Alice\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"Hello Alice! It's nice 
to meet you. How can I assist you today?\",\n    \"tool_calls\" : [ ]\n  }, {\n 
   \"role\" : \"user\",\n    \"content\" : \"And my favorite color is blue\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"That's a lovely choice 
of color! Blue i [...]
+      "equalToJson" : "{\n  \"model\" : \"granite4:3b\",\n  \"messages\" : [ 
{\n    \"role\" : \"user\",\n    \"content\" : \"Hello - my name is Alice\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"Hello Alice! It's nice 
to meet you. How can I assist you today?\",\n    \"tool_calls\" : [ ]\n  }, {\n 
   \"role\" : \"user\",\n    \"content\" : \"And my favorite color is blue\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"That's a lovely choice 
of color! Blue o [...]
       "ignoreArrayOrder" : true,
       "ignoreExtraElements" : false
     } ]
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:26.340021889Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Your
 name is Alice and your favorite color is blue. Is there anything specific you 
would like to know or discuss regarding this 
information?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2038958858,\"load_duration\":47826093,\"prompt_eval_count\":135,\"prompt_eval_duration\":564886840,\"eval_count\":27,\"eval_duration\":1404103133}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:57.861948289Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Your
 name is Alice and your favorite color is blue. Is there anything specific you 
would like to know or discuss regarding this 
information?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1702615652,\"load_duration\":53668184,\"prompt_eval_count\":135,\"prompt_eval_duration\":307615243,\"eval_count\":27,\"eval_duration\":1326830533}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:26 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:57 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "e7f6e7af-412b-4f34-887c-d19ee0c66d8b",
+  "uuid" : "89dc149d-8f49-42e4-b157-ca193826fb97",
   "persistent" : true,
   "insertionIndex" : 3
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-a7f5dc9a-3330-441d-8824-d913baaf2515.json
similarity index 83%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-a7f5dc9a-3330-441d-8824-d913baaf2515.json
index d0a2327ca8..17efebea07 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-a7f5dc9a-3330-441d-8824-d913baaf2515.json
@@ -1,5 +1,5 @@
 {
-  "id" : "4b8e8d96-42d7-4a16-87ca-c1858066e648",
+  "id" : "a7f5dc9a-3330-441d-8824-d913baaf2515",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:57.640601581Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_cjncgqra\",\"function\":{\"index\":0,\"name\":\"longRunningOperation\",\"arguments\":{\"duration\":2,\"steps\":2}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2356783183,\"load_duration\":47164721,\"prompt_eval_count\":319,\"prompt_eval_duration\":836224093,\"eval_count\":27,\"eval_duration\":1453164185}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:53:19.407078876Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_q8izawle\",\"function\":{\"index\":0,\"name\":\"longRunningOperation\",\"arguments\":{\"duration\":2,\"steps\":2}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1837944411,\"load_duration\":52604556,\"prompt_eval_count\":319,\"prompt_eval_duration\":434334830,\"eval_count\":27,\"eval_duration\":1336961683}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:57 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:19 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "4b8e8d96-42d7-4a16-87ca-c1858066e648",
+  "uuid" : "a7f5dc9a-3330-441d-8824-d913baaf2515",
   "persistent" : true,
-  "insertionIndex" : 13
+  "insertionIndex" : 14
 }
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-af34c8aa-386e-484c-b7b1-5635fc121443.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-af34c8aa-386e-484c-b7b1-5635fc121443.json
new file mode 100644
index 0000000000..9c58220217
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-af34c8aa-386e-484c-b7b1-5635fc121443.json
@@ -0,0 +1,24 @@
+{
+  "id" : "af34c8aa-386e-484c-b7b1-5635fc121443",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"system\",\n    \"content\" : \"You are a whimsical storyteller. 
Your responses should be imaginative, descriptive, and always include a touch 
of magic. Start every story with 'Once upon a starlit night...'\"\n  }, {\n    
\"role\" : \"user\",\n    \"content\" : \"Write a short story about a lost 
cat.\"\n  } ],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ 
]\n  },\n  \"stream\" [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:54:18.439524809Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Once upon a starlit night, a curious little girl named Lily wandered through 
the forest, searching for her beloved cat, Boots. She had been missing for days 
and couldn't stop thinking about him. As she walked, she heard a faint meowing 
sound behind her. She turned around to see a tiny kitten, shivering and alone, 
staring up at her with big, pleading  [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:54:18 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "af34c8aa-386e-484c-b7b1-5635fc121443",
+  "persistent" : true,
+  "insertionIndex" : 1
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-cd782b16-9b47-43d1-966d-f57f33ed5718.json
similarity index 66%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-cd782b16-9b47-43d1-966d-f57f33ed5718.json
index a984762216..c5403a1dd3 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-cd782b16-9b47-43d1-966d-f57f33ed5718.json
@@ -1,5 +1,5 @@
 {
-  "id" : "50282a37-becc-455a-829b-8c95dbfeac83",
+  "id" : "cd782b16-9b47-43d1-966d-f57f33ed5718",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:14.47274051Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_w3upfd1y\",\"function\":{\"index\":0,\"name\":\"QueryUserDatabaseByUserID\",\"arguments\":{\"userId\":123}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":4472695102,\"load_duration\":43611230,\"prompt_eval_count\":200,\"prompt_eval_duration\":3210769739,\"eval_count\":23,\"eval_duration\":1200591755}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T09:52:35.899115346Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_11t405yl\",\"function\":{\"index\":0,\"name\":\"QueryUserDatabaseByUserID\",\"arguments\":{\"userId\":123}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5121311754,\"load_duration\":1617003393,\"prompt_eval_count\":200,\"prompt_eval_duration\":2384739468,\"eval_count\":23,\"eval_duration\":1107102121}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:14 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:52:35 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "50282a37-becc-455a-829b-8c95dbfeac83",
+  "uuid" : "cd782b16-9b47-43d1-966d-f57f33ed5718",
   "persistent" : true,
-  "insertionIndex" : 20
+  "insertionIndex" : 21
 }
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-d44e4f60-fcba-4b6a-b468-110c5ef3968f.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-d44e4f60-fcba-4b6a-b468-110c5ef3968f.json
new file mode 100644
index 0000000000..60c103a2e1
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-d44e4f60-fcba-4b6a-b468-110c5ef3968f.json
@@ -0,0 +1,24 @@
+{
+  "id" : "d44e4f60-fcba-4b6a-b468-110c5ef3968f",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"Return an example JSON object 
about a person named 'John Doe' with the fields age and description\"\n  }, {\n 
   \"role\" : \"assistant\",\n    \"content\" : \" Here is an example JSON 
object about John Doe with the fields age and description:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"age\\\": 30,\\n \\\"description\\\": 
\\\"John Doe is a profession [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:53:50.493191339Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object that follows the format you 
specified:\\n\\n```json\\n{\\n \\\"name\\\": \\\"John Doe\\\",\\n \\\"age\\\": 
30,\\n \\\"description\\\": \\\"John Doe is a professional in the field of 
technology. He has worked for several years and has a wealth of 
experience.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\" [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:53:50 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "d44e4f60-fcba-4b6a-b468-110c5ef3968f",
+  "persistent" : true,
+  "insertionIndex" : 6
+}
\ No newline at end of file
diff --git 
a/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f25e934d-75c9-4136-937c-5be74d187f81.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f25e934d-75c9-4136-937c-5be74d187f81.json
new file mode 100644
index 0000000000..5d890c1061
--- /dev/null
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f25e934d-75c9-4136-937c-5be74d187f81.json
@@ -0,0 +1,24 @@
+{
+  "id" : "f25e934d-75c9-4136-937c-5be74d187f81",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"What is Apache Camel?\"\n  } ],\n  
\"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:52:43.232164748Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Apache Camel is an open-source framework used for building and managing 
business processes that involve data movement, messaging, and processing. It 
provides a suite of modular and reusable components that can be used to create 
customized pipelines and workflows. These components include routes, endpoints, 
bindings, and serializers/deserializers. Apa [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 09:52:43 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "f25e934d-75c9-4136-937c-5be74d187f81",
+  "persistent" : true,
+  "insertionIndex" : 18
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f6c67707-2d86-4806-9a70-2e3b87f76f38.json
similarity index 53%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f6c67707-2d86-4806-9a70-2e3b87f76f38.json
index e58e9d79b1..760fbe5050 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f6c67707-2d86-4806-9a70-2e3b87f76f38.json
@@ -1,5 +1,5 @@
 {
-  "id" : "46dd74e1-aa17-497e-bad5-fc74ee8d7959",
+  "id" : "f6c67707-2d86-4806-9a70-2e3b87f76f38",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:09.879393101Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 According to Miles of Camels Car Rental's cancellations policy, if you cancel 
your rental 24 hours before pickup, you will receive a full refund. If you 
cancel between 12 and 24 hours before pickup, you will receive a 50% refund. If 
you cancel less than 12 hours before pickup, there will be no 
refund.\\n\\nAdditionally, according to the company's veh [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:52:30.652901631Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Miles of Camels Car Rental cancellations policy for cancelling 24 hours before 
pickup is as follows:\\n\\nRefund amount: Full refund\\n\\nThis policy applies 
to any cancellation made 24 hours or less before the pickup date and time. The 
cancellation must be made in writing by emailing the customer service 
department at [email protected] or calling (5 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:09 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:52:30 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "46dd74e1-aa17-497e-bad5-fc74ee8d7959",
+  "uuid" : "f6c67707-2d86-4806-9a70-2e3b87f76f38",
   "persistent" : true,
-  "insertionIndex" : 21
+  "insertionIndex" : 22
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f76fd9b1-66ac-4d0e-bbbb-795b5e05509d.json
similarity index 57%
copy from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
copy to 
integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f76fd9b1-66ac-4d0e-bbbb-795b5e05509d.json
index d36d8cadba..dc539ff575 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
+++ 
b/integration-tests-jvm/langchain4j-agent-ql4j/src/test/resources/mappings/api_chat-f76fd9b1-66ac-4d0e-bbbb-795b5e05509d.json
@@ -1,5 +1,5 @@
 {
-  "id" : "98a9059a-eb53-4580-af3c-d32c1a30b95d",
+  "id" : "f76fd9b1-66ac-4d0e-bbbb-795b5e05509d",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:06.209091727Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"An example person 
with a unique name and a brief 
description.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":3900537511,\"load_duration\":9482003,\"prompt_eval_count\":90,\"prompt_eval_duration\
 [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T09:53:28.559023297Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object about John Doe:\\n\\n```\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"A person with a 
unique name that is easy to remember and 
pronounce.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5048182535,\"load_duration\":1472020430,\"prompt_eval_count\":90,\"prompt_eval_du
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:06 GMT",
+      "Date" : "Thu, 12 Mar 2026 09:53:28 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "98a9059a-eb53-4580-af3c-d32c1a30b95d",
+  "uuid" : "f76fd9b1-66ac-4d0e-bbbb-795b5e05509d",
   "persistent" : true,
-  "insertionIndex" : 11
+  "insertionIndex" : 12
 }
\ No newline at end of file
diff --git a/integration-tests-jvm/pom.xml b/integration-tests-jvm/pom.xml
index edac507521..a1a692967a 100644
--- a/integration-tests-jvm/pom.xml
+++ b/integration-tests-jvm/pom.xml
@@ -76,6 +76,7 @@
         <module>json-patch</module>
         <module>jsonapi</module>
         <module>junit-test-framework</module>
+        <module>langchain4j-agent-ql4j</module>
         <module>ldif</module>
         <module>lucene</module>
         <module>main-devmode</module>
diff --git 
a/integration-tests/langchain4j-agent/src/main/java/org/apache/camel/quarkus/component/langchain4j/agent/it/AgentProducers.java
 
b/integration-tests/langchain4j-agent/src/main/java/org/apache/camel/quarkus/component/langchain4j/agent/it/AgentProducers.java
index 8617d3f8c1..d686f20de4 100644
--- 
a/integration-tests/langchain4j-agent/src/main/java/org/apache/camel/quarkus/component/langchain4j/agent/it/AgentProducers.java
+++ 
b/integration-tests/langchain4j-agent/src/main/java/org/apache/camel/quarkus/component/langchain4j/agent/it/AgentProducers.java
@@ -41,6 +41,7 @@ import 
dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever;
 import dev.langchain4j.store.embedding.EmbeddingStore;
 import dev.langchain4j.store.embedding.inmemory.InMemoryEmbeddingStore;
 import dev.langchain4j.store.memory.chat.ChatMemoryStore;
+import io.quarkus.arc.lookup.LookupUnlessProperty;
 import io.smallrye.common.annotation.Identifier;
 import jakarta.enterprise.context.ApplicationScoped;
 import jakarta.enterprise.inject.Produces;
@@ -97,6 +98,8 @@ public class AgentProducers {
     }
 
     @Produces
+    //in special cases (used by test modules inheriting this module), lookup 
of this bean has to be disabled
+    @LookupUnlessProperty(name = "cq-test.retrieval.augmentor.disabled", 
stringValue = "true")
     RetrievalAugmentor retrievalAugmentor() throws IOException {
         ClassLoader classLoader = 
Thread.currentThread().getContextClassLoader();
         try (InputStream stream = 
classLoader.getResourceAsStream("rag/company-knowledge-base.txt")) {
@@ -195,7 +198,7 @@ public class AgentProducers {
     @Identifier("agentWithRag")
     public Agent agentWithRag(
             @Identifier("ollamaOrcaMiniModel") ChatModel chatModel,
-            RetrievalAugmentor retrievalAugmentor) {
+            RetrievalAugmentor retrievalAugmentor) throws IOException {
         return new AgentWithoutMemory(new AgentConfiguration()
                 .withChatModel(chatModel)
                 .withRetrievalAugmentor(retrievalAugmentor));
diff --git 
a/integration-tests/langchain4j-agent/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentTestResource.java
 
b/integration-tests/langchain4j-agent/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentTestResource.java
index e579e9c27f..7ae167b9e7 100644
--- 
a/integration-tests/langchain4j-agent/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentTestResource.java
+++ 
b/integration-tests/langchain4j-agent/src/test/java/org/apache/camel/quarkus/component/langchain4j/agent/it/Langchain4jAgentTestResource.java
@@ -22,10 +22,16 @@ import java.nio.charset.StandardCharsets;
 import java.nio.file.Files;
 import java.nio.file.Path;
 import java.nio.file.Paths;
+import java.util.ArrayList;
+import java.util.Comparator;
+import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
+import java.util.Set;
 import java.util.concurrent.TimeUnit;
 
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.node.ObjectNode;
 import com.github.tomakehurst.wiremock.stubbing.StubMapping;
 import 
org.apache.camel.quarkus.component.langchain4j.agent.it.util.ProcessUtils;
 import 
org.apache.camel.quarkus.test.wiremock.WireMockTestResourceLifecycleManager;
@@ -55,18 +61,44 @@ public class Langchain4jAgentTestResource extends 
WireMockTestResourceLifecycleM
 
     @Override
     protected void processRecordedStubMappings(List<StubMapping> stubMappings) 
{
-        stubMappings.forEach(mapping -> {
+        // Process stubs in recording order so we keep the first occurrence of 
each unique request body
+        List<StubMapping> sorted = new ArrayList<>(stubMappings);
+        sorted.sort(Comparator.comparingLong(StubMapping::getInsertionIndex));
+
+        Set<String> seenRequestBodies = new HashSet<>();
+        ObjectMapper mapper = new ObjectMapper();
+
+        for (StubMapping mapping : sorted) {
             String fileName = mapping.getName() + "-" + mapping.getId() + 
".json";
             Path mappingFilePath = Paths.get("./src/test/resources/mappings/", 
fileName);
 
-            // ignoreExtraElements directive can lead to WireMock getting 
confused about which stub to use on request matching.
-            // Force disabling it manually since there's no specific WireMock 
config option to tune it
+            // When multiple tests send identical requests, WireMock records 
duplicate stubs and links them via
+            // a scenario state machine to enforce recording-time ordering. 
During replay this breaks when tests
+            // run in a different order. Deduplicate by keeping only the first 
stub per unique request body.
+            String requestBodyKey = normalizeRequestBody(mapper, mapping);
+            if (requestBodyKey != null && 
!seenRequestBodies.add(requestBodyKey)) {
+                try {
+                    Files.deleteIfExists(mappingFilePath);
+                } catch (IOException e) {
+                    LOG.warnf("Failed to delete duplicate stub %s: %s", 
fileName, e.getMessage());
+                }
+                continue;
+            }
+
             try {
-                String mappingContent = Files.readString(mappingFilePath);
-                mappingContent = 
mappingContent.replace("\"ignoreExtraElements\" : true", 
"\"ignoreExtraElements\" : false");
-                Files.writeString(mappingFilePath, mappingContent);
+                ObjectNode rootNode = (ObjectNode) 
mapper.readTree(Files.readString(mappingFilePath));
+
+                // Remove scenario state so stubs are not tied to 
recording-time test execution order
+                rootNode.remove("scenarioName");
+                rootNode.remove("requiredScenarioState");
+                rootNode.remove("newScenarioState");
+
+                // ignoreExtraElements can lead to WireMock matching the wrong 
stub; force it off
+                String content = 
mapper.writerWithDefaultPrettyPrinter().writeValueAsString(rootNode);
+                content = content.replace("\"ignoreExtraElements\" : true", 
"\"ignoreExtraElements\" : false");
+                Files.writeString(mappingFilePath, content);
             } catch (IOException e) {
-                throw new RuntimeException(e);
+                throw new RuntimeException("Failed to process stub mapping " + 
fileName, e);
             }
 
             // RetrievalAugmentor bean setup causes /api/embed stubs to be 
recorded on every test run.
@@ -80,7 +112,21 @@ public class Langchain4jAgentTestResource extends 
WireMockTestResourceLifecycleM
                     // Ignored
                 }
             }
-        });
+        }
+    }
+
+    private String normalizeRequestBody(ObjectMapper mapper, StubMapping 
mapping) {
+        var bodyPatterns = mapping.getRequest().getBodyPatterns();
+        if (bodyPatterns == null || bodyPatterns.isEmpty()) {
+            return null;
+        }
+        try {
+            // Normalize to canonical JSON so whitespace differences don't 
prevent deduplication
+            String body = String.valueOf(bodyPatterns.get(0).getValue());
+            return mapper.writeValueAsString(mapper.readTree(body));
+        } catch (Exception e) {
+            return String.valueOf(bodyPatterns.get(0).getValue());
+        }
     }
 
     @Override
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/__files/api_embed-1e8084ee-91b3-4095-86b7-9845fe1480d6.json
 
b/integration-tests/langchain4j-agent/src/test/resources/__files/api_embed-1e8084ee-91b3-4095-86b7-9845fe1480d6.json
deleted file mode 100644
index 73198be1ed..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/__files/api_embed-1e8084ee-91b3-4095-86b7-9845fe1480d6.json
+++ /dev/null
@@ -1 +0,0 @@
-{"model":"nomic-embed-text","embeddings":[[-0.0009466486,0.037309933,-0.1915589,-0.023723029,0.05843722,-0.035545707,-0.0017817644,-0.015704276,-0.028122663,-0.0055035865,-0.052609082,0.04383919,0.00039316143,-0.023646308,0.069905564,-0.029778978,0.0077509126,-0.07298615,-0.06070862,0.091046594,-0.030032177,-0.0020017496,-0.0469251,-0.052244417,0.032175764,-0.011999858,-0.007285211,0.058825955,-0.051475406,-0.025669474,0.025158448,-0.008839627,0.04279815,-0.040296685,-0.07954074,-0.06699
 [...]
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-07483132-9cdf-4380-9dc7-98735923d83f.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-07483132-9cdf-4380-9dc7-98735923d83f.json
new file mode 100644
index 0000000000..d5bc308da2
--- /dev/null
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-07483132-9cdf-4380-9dc7-98735923d83f.json
@@ -0,0 +1,24 @@
+{
+  "id" : "07483132-9cdf-4380-9dc7-98735923d83f",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"granite4:3b\",\n  \"messages\" : [ 
{\n    \"role\" : \"user\",\n    \"content\" : \"Hello - my name is Alice\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"Hello Alice! It's nice 
to meet you. How can I assist you today?\",\n    \"tool_calls\" : [ ]\n  }, {\n 
   \"role\" : \"user\",\n    \"content\" : \"And my favorite color is blue\"\n  
}, {\n    \"role\" : \"assistant\",\n    \"content\" : \"That's lovely to know, 
Alice! Blue is a [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:39.620043426Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Your
 name is Alice and your favorite color is blue. If you have any other details 
or preferences you'd like to share, feel free to let me 
know!\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2009959242,\"load_duration\":52837979,\"prompt_eval_count\":126,\"prompt_eval_duration\":302646671,\"eval_count\":33,\"eval_duration\":1638025929}",
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 08:54:39 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "07483132-9cdf-4380-9dc7-98735923d83f",
+  "persistent" : true,
+  "insertionIndex" : 3
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-169fb9d1-d29b-4e95-84a4-1ab133179ce5.json
similarity index 64%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-169fb9d1-d29b-4e95-84a4-1ab133179ce5.json
index a2a35834f7..feede8f613 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5b13dcfa-8f76-45b3-a149-6c43182869dd.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-169fb9d1-d29b-4e95-84a4-1ab133179ce5.json
@@ -1,5 +1,5 @@
 {
-  "id" : "5b13dcfa-8f76-45b3-a149-6c43182869dd",
+  "id" : "169fb9d1-d29b-4e95-84a4-1ab133179ce5",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:47.817132698Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"An example person 
with a unique name and a brief 
description\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":3933350526,\"load_duration\":11705957,\"prompt_eval_count\":60,\"prompt_eval_duration\
 [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:53:59.397221819Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"An example person 
with the field name of 
name.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2991784333,\"load_duration\":18256360,\"prompt_eval_count\":60,\"prompt_eval_duration\":561792667,\"
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:47 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:53:59 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "5b13dcfa-8f76-45b3-a149-6c43182869dd",
+  "uuid" : "169fb9d1-d29b-4e95-84a4-1ab133179ce5",
   "persistent" : true,
   "insertionIndex" : 15
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19d22465-3fb9-4f32-94b0-e0abf68f0df6.json
similarity index 84%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19d22465-3fb9-4f32-94b0-e0abf68f0df6.json
index d0a2327ca8..1932de273a 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4b8e8d96-42d7-4a16-87ca-c1858066e648.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19d22465-3fb9-4f32-94b0-e0abf68f0df6.json
@@ -1,5 +1,5 @@
 {
-  "id" : "4b8e8d96-42d7-4a16-87ca-c1858066e648",
+  "id" : "19d22465-3fb9-4f32-94b0-e0abf68f0df6",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:57.640601581Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_cjncgqra\",\"function\":{\"index\":0,\"name\":\"longRunningOperation\",\"arguments\":{\"duration\":2,\"steps\":2}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2356783183,\"load_duration\":47164721,\"prompt_eval_count\":319,\"prompt_eval_duration\":836224093,\"eval_count\":27,\"eval_duration\":1453164185}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:08.111007628Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_y8fompp2\",\"function\":{\"index\":0,\"name\":\"longRunningOperation\",\"arguments\":{\"duration\":2,\"steps\":2}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1827555038,\"load_duration\":54331929,\"prompt_eval_count\":319,\"prompt_eval_duration\":432577733,\"eval_count\":27,\"eval_duration\":1326824578}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:57 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:08 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "4b8e8d96-42d7-4a16-87ca-c1858066e648",
+  "uuid" : "19d22465-3fb9-4f32-94b0-e0abf68f0df6",
   "persistent" : true,
   "insertionIndex" : 13
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-1a58e2d0-7224-4a5e-a01b-318e83a9fb29.json
similarity index 69%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-1a58e2d0-7224-4a5e-a01b-318e83a9fb29.json
index 53ad1cb5fe..aa1772e3e7 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-b682d927-b36f-427d-b404-b754b054ddb9.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-1a58e2d0-7224-4a5e-a01b-318e83a9fb29.json
@@ -1,5 +1,5 @@
 {
-  "id" : "b682d927-b36f-427d-b404-b754b054ddb9",
+  "id" : "1a58e2d0-7224-4a5e-a01b-318e83a9fb29",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:21.562588173Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Hello
 Alice! It's nice to meet you. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1615998648,\"load_duration\":48578413,\"prompt_eval_count\":36,\"prompt_eval_duration\":645865891,\"eval_count\":18,\"eval_duration\":909874821}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:35.615906218Z\",\"message\":{\"role\":\"assistant\",\"content\":\"Hello
 Alice! It's nice to meet you. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2900370364,\"load_duration\":1604196710,\"prompt_eval_count\":36,\"prompt_eval_duration\":441392703,\"eval_count\":18,\"eval_duration\":845433348}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:21 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:35 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "b682d927-b36f-427d-b404-b754b054ddb9",
+  "uuid" : "1a58e2d0-7224-4a5e-a01b-318e83a9fb29",
   "persistent" : true,
   "insertionIndex" : 5
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-2578100a-828a-4b81-bbf2-81dfd2a133b2.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-2578100a-828a-4b81-bbf2-81dfd2a133b2.json
new file mode 100644
index 0000000000..a6a0d764a1
--- /dev/null
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-2578100a-828a-4b81-bbf2-81dfd2a133b2.json
@@ -0,0 +1,24 @@
+{
+  "id" : "2578100a-828a-4b81-bbf2-81dfd2a133b2",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"What is Apache Camel?\"\n  } ],\n  
\"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:53:34.028672381Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Apache Camel is an open-source project that provides a framework for building 
high-performance, resilient, and fault-tolerant distributed systems. It allows 
you to easily build complex workflows by integrating, processing, and moving 
data between different systems or services. It supports a wide range of 
protocols and APIs, including HTTP, JMS, REST, [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 08:53:34 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "2578100a-828a-4b81-bbf2-81dfd2a133b2",
+  "persistent" : true,
+  "insertionIndex" : 17
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3553e0ce-5315-4adc-9cf9-7aa020d3fa0c.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3397f049-5f70-40ca-ab2f-8169b147fef4.json
similarity index 62%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3553e0ce-5315-4adc-9cf9-7aa020d3fa0c.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3397f049-5f70-40ca-ab2f-8169b147fef4.json
index 48299e2f16..afb4344326 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3553e0ce-5315-4adc-9cf9-7aa020d3fa0c.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3397f049-5f70-40ca-ab2f-8169b147fef4.json
@@ -1,5 +1,5 @@
 {
-  "id" : "3553e0ce-5315-4adc-9cf9-7aa020d3fa0c",
+  "id" : "3397f049-5f70-40ca-ab2f-8169b147fef4",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:19.916999414Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, I can help with that! Can you please provide me with the specific format 
you want the JSON object to 
follow?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1770008575,\"load_duration\":17062707,\"prompt_eval_count\":52,\"prompt_eval_duration\":479905991,\"eval_count\":26,\"eval_duration\":1265578814}",
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:54:32.615262279Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, I'd be happy to help! Can you please provide me with the specific format 
you want the JSON object to 
follow?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1554193662,\"load_duration\":17846961,\"prompt_eval_count\":52,\"prompt_eval_duration\":235272960,\"eval_count\":28,\"eval_duration\":1295301623}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:19 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:32 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "3553e0ce-5315-4adc-9cf9-7aa020d3fa0c",
+  "uuid" : "3397f049-5f70-40ca-ab2f-8169b147fef4",
   "persistent" : true,
   "insertionIndex" : 6
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-35248f94-bc7e-471a-af71-f485e1621fb4.json
similarity index 58%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-35248f94-bc7e-471a-af71-f485e1621fb4.json
index d36d8cadba..6a9dc6ddf4 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-98a9059a-eb53-4580-af3c-d32c1a30b95d.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-35248f94-bc7e-471a-af71-f485e1621fb4.json
@@ -1,5 +1,5 @@
 {
-  "id" : "98a9059a-eb53-4580-af3c-d32c1a30b95d",
+  "id" : "35248f94-bc7e-471a-af71-f485e1621fb4",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:06.209091727Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe:\\n\\n```json\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"An example person 
with a unique name and a brief 
description.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":3900537511,\"load_duration\":9482003,\"prompt_eval_count\":90,\"prompt_eval_duration\
 [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:54:17.301177168Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object about John Doe:\\n\\n```\\n{\\n 
\\\"name\\\": \\\"John Doe\\\",\\n \\\"description\\\": \\\"A person with a 
unique name that is easy to remember and 
pronounce.\\\"\\n}\\n```\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5075527283,\"load_duration\":1474581221,\"prompt_eval_count\":90,\"prompt_eval_du
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:06 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:17 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "98a9059a-eb53-4580-af3c-d32c1a30b95d",
+  "uuid" : "35248f94-bc7e-471a-af71-f485e1621fb4",
   "persistent" : true,
   "insertionIndex" : 11
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3bd2313a-d8c2-45cf-98a3-1291e61dbed8.json
similarity index 82%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3bd2313a-d8c2-45cf-98a3-1291e61dbed8.json
index 66426d79ea..e5c1f9f59d 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-19496598-286d-4354-8021-d0141973f657.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3bd2313a-d8c2-45cf-98a3-1291e61dbed8.json
@@ -1,5 +1,5 @@
 {
-  "id" : "19496598-286d-4354-8021-d0141973f657",
+  "id" : "3bd2313a-d8c2-45cf-98a3-1291e61dbed8",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:55.26755228Z\",\"message\":{\"role\":\"assistant\",\"content\":\"[\\n
  \\\"longRunningOperation\\\",\\n  \\\"add\\\",\\n  
\\\"echo\\\"\\n]\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":7199497126,\"load_duration\":44301920,\"prompt_eval_count\":326,\"prompt_eval_duration\":6246528366,\"eval_count\":17,\"eval_duration\":894557129}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:06.153461065Z\",\"message\":{\"role\":\"assistant\",\"content\":\"[\\n
  \\\"longRunningOperation\\\",\\n  \\\"add\\\",\\n  
\\\"echo\\\"\\n]\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":6533832018,\"load_duration\":1614820343,\"prompt_eval_count\":326,\"prompt_eval_duration\":4090594435,\"eval_count\":17,\"eval_duration\":817664482}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:55 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:06 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "19496598-286d-4354-8021-d0141973f657",
+  "uuid" : "3bd2313a-d8c2-45cf-98a3-1291e61dbed8",
   "persistent" : true,
   "insertionIndex" : 14
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d26b3c9-b392-4bb6-b3e6-622c857fc1a4.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d26b3c9-b392-4bb6-b3e6-622c857fc1a4.json
new file mode 100644
index 0000000000..a4f9656d89
--- /dev/null
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d26b3c9-b392-4bb6-b3e6-622c857fc1a4.json
@@ -0,0 +1,24 @@
+{
+  "id" : "3d26b3c9-b392-4bb6-b3e6-622c857fc1a4",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"Return an example JSON object 
about a person named 'John Doe' with the fields age and description\"\n  } ],\n 
 \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:54:31.031225222Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here is an example JSON object for John Doe with the fields age and 
description:\\n\\n```\\n{\\n \\\"name\\\": \\\"John Doe\\\",\\n \\\"age\\\": 
30,\\n \\\"description\\\": \\\"John Doe is a professional software developer 
with over 5 years of experience. He enjoys working on challenging projects and 
collaborating with others to achieve shared  [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 08:54:31 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "3d26b3c9-b392-4bb6-b3e6-622c857fc1a4",
+  "persistent" : true,
+  "insertionIndex" : 7
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d941d4b-d1e9-4e58-aeaf-d52756afeef0.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d941d4b-d1e9-4e58-aeaf-d52756afeef0.json
new file mode 100644
index 0000000000..dff87f6b5a
--- /dev/null
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3d941d4b-d1e9-4e58-aeaf-d52756afeef0.json
@@ -0,0 +1,24 @@
+{
+  "id" : "3d941d4b-d1e9-4e58-aeaf-d52756afeef0",
+  "name" : "api_chat",
+  "request" : {
+    "url" : "/api/chat",
+    "method" : "POST",
+    "bodyPatterns" : [ {
+      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"system\",\n    \"content\" : \"You are a whimsical storyteller. 
Your responses should be imaginative, descriptive, and always include a touch 
of magic. Start every story with 'Once upon a starlit night...'\"\n  }, {\n    
\"role\" : \"user\",\n    \"content\" : \"Write a short story about a lost 
cat.\"\n  } ],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ 
]\n  },\n  \"stream\" [...]
+      "ignoreArrayOrder" : true,
+      "ignoreExtraElements" : false
+    } ]
+  },
+  "response" : {
+    "status" : 200,
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:55:08.168700234Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Once upon a starlit night, a curious little girl named Lily wandered through 
the forest, searching for her beloved cat, Whiskers. She had been missing for 
days and couldn't shake the feeling that something was off. As she walked, the 
trees grew taller and the leaves rustled in the wind, until she came across a 
clearing where a group of animals were g [...]
+    "headers" : {
+      "Date" : "Thu, 12 Mar 2026 08:55:08 GMT",
+      "Content-Type" : "application/json; charset=utf-8"
+    }
+  },
+  "uuid" : "3d941d4b-d1e9-4e58-aeaf-d52756afeef0",
+  "persistent" : true,
+  "insertionIndex" : 1
+}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4bd017da-a2a1-4206-b70e-7c0a3f9ddc11.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4bd017da-a2a1-4206-b70e-7c0a3f9ddc11.json
deleted file mode 100644
index ffec0f3930..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4bd017da-a2a1-4206-b70e-7c0a3f9ddc11.json
+++ /dev/null
@@ -1,26 +0,0 @@
-{
-  "id" : "4bd017da-a2a1-4206-b70e-7c0a3f9ddc11",
-  "name" : "api_chat",
-  "request" : {
-    "url" : "/api/chat",
-    "method" : "POST",
-    "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"system\",\n    \"content\" : \"You are a whimsical storyteller. 
Your responses should be imaginative, descriptive, and always include a touch 
of magic. Start every story with 'Once upon a starlit night...'\"\n  }, {\n    
\"role\" : \"user\",\n    \"content\" : \"Write a short story about a lost 
cat.\"\n  } ],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ 
]\n  },\n  \"stream\" [...]
-      "ignoreArrayOrder" : true,
-      "ignoreExtraElements" : false
-    } ]
-  },
-  "response" : {
-    "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:53.383242474Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Once upon a starlit night, a curious little girl named Lily wandered through 
the forest, searching for her missing pet cat. She had been caring for the 
feline for weeks, but he had disappeared without a trace. As she walked deeper 
into the woods, the trees grew thicker and the path became less clear. 
Suddenly, she heard a faint meowing sound coming f [...]
-    "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:53 GMT",
-      "Content-Type" : "application/json; charset=utf-8"
-    }
-  },
-  "uuid" : "4bd017da-a2a1-4206-b70e-7c0a3f9ddc11",
-  "persistent" : true,
-  "scenarioName" : "scenario-1-api-chat",
-  "requiredScenarioState" : "scenario-1-api-chat-2",
-  "insertionIndex" : 1
-}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-cbafc9dd-bc75-4283-aba6-e2950556ba5f.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4fb0b393-7f23-4703-8a09-a146222baf05.json
similarity index 75%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-cbafc9dd-bc75-4283-aba6-e2950556ba5f.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4fb0b393-7f23-4703-8a09-a146222baf05.json
index b8bcad0f1e..068b5b9196 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-cbafc9dd-bc75-4283-aba6-e2950556ba5f.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-4fb0b393-7f23-4703-8a09-a146222baf05.json
@@ -1,5 +1,5 @@
 {
-  "id" : "cbafc9dd-bc75-4283-aba6-e2950556ba5f",
+  "id" : "4fb0b393-7f23-4703-8a09-a146222baf05",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:10.940178285Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_nd08sj0v\",\"function\":{\"index\":0,\"name\":\"addNumbers\",\"arguments\":{\"arg0\":10,\"arg1\":5}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":4693362054,\"load_duration\":47542777,\"prompt_eval_count\":193,\"prompt_eval_duration\":3128994736,\"eval_count\":28,\"eval_duration\":1492960511}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:22.787558621Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_hafu094r\",\"function\":{\"index\":0,\"name\":\"addNumbers\",\"arguments\":{\"arg0\":10,\"arg1\":5}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5324173298,\"load_duration\":1605030908,\"prompt_eval_count\":193,\"prompt_eval_duration\":2346002933,\"eval_count\":28,\"eval_duration\":1358329760}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:10 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:22 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "cbafc9dd-bc75-4283-aba6-e2950556ba5f",
+  "uuid" : "4fb0b393-7f23-4703-8a09-a146222baf05",
   "persistent" : true,
   "insertionIndex" : 10
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5716f4c5-5f23-4975-8015-0e0026572e7c.json
similarity index 55%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5716f4c5-5f23-4975-8015-0e0026572e7c.json
index e58e9d79b1..87642655e1 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-46dd74e1-aa17-497e-bad5-fc74ee8d7959.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-5716f4c5-5f23-4975-8015-0e0026572e7c.json
@@ -1,5 +1,5 @@
 {
-  "id" : "46dd74e1-aa17-497e-bad5-fc74ee8d7959",
+  "id" : "5716f4c5-5f23-4975-8015-0e0026572e7c",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:09.879393101Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 According to Miles of Camels Car Rental's cancellations policy, if you cancel 
your rental 24 hours before pickup, you will receive a full refund. If you 
cancel between 12 and 24 hours before pickup, you will receive a 50% refund. If 
you cancel less than 12 hours before pickup, there will be no 
refund.\\n\\nAdditionally, according to the company's veh [...]
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:53:19.65614024Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 According to the Miles of Camels Car Rental cancellations policy, if you 
cancel 24 hours before pickup, you will receive a full refund. If you cancel 
between 12 and 24 hours before pickup, you will receive a 50% refund. If you 
cancel less than 12 hours before pickup, there will be no 
refund.\\n\\nAdditionally, according to the company's vehicle return [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:09 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:53:19 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "46dd74e1-aa17-497e-bad5-fc74ee8d7959",
+  "uuid" : "5716f4c5-5f23-4975-8015-0e0026572e7c",
   "persistent" : true,
   "insertionIndex" : 21
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-65a5a977-8a4c-4c28-aff7-f4dc7500df43.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-65a5a977-8a4c-4c28-aff7-f4dc7500df43.json
deleted file mode 100644
index 95eea777ae..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-65a5a977-8a4c-4c28-aff7-f4dc7500df43.json
+++ /dev/null
@@ -1,27 +0,0 @@
-{
-  "id" : "65a5a977-8a4c-4c28-aff7-f4dc7500df43",
-  "name" : "api_chat",
-  "request" : {
-    "url" : "/api/chat",
-    "method" : "POST",
-    "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"Hello - my name is Alice\"\n  } 
],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
-      "ignoreArrayOrder" : true,
-      "ignoreExtraElements" : false
-    } ]
-  },
-  "response" : {
-    "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:13.220162181Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Hello, Alice. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":900089323,\"load_duration\":9450899,\"prompt_eval_count\":46,\"prompt_eval_duration\":319079740,\"eval_count\":12,\"eval_duration\":567495610}",
-    "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:13 GMT",
-      "Content-Type" : "application/json; charset=utf-8"
-    }
-  },
-  "uuid" : "65a5a977-8a4c-4c28-aff7-f4dc7500df43",
-  "persistent" : true,
-  "scenarioName" : "scenario-2-api-chat",
-  "requiredScenarioState" : "scenario-2-api-chat-2",
-  "newScenarioState" : "scenario-2-api-chat-3",
-  "insertionIndex" : 8
-}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-68c8507d-160c-4641-9a22-84bbe4806890.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-68c8507d-160c-4641-9a22-84bbe4806890.json
deleted file mode 100644
index 45e1fc64eb..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-68c8507d-160c-4641-9a22-84bbe4806890.json
+++ /dev/null
@@ -1,24 +0,0 @@
-{
-  "id" : "68c8507d-160c-4641-9a22-84bbe4806890",
-  "name" : "api_chat",
-  "request" : {
-    "url" : "/api/chat",
-    "method" : "POST",
-    "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"What is Apache Camel?\"\n  } ],\n  
\"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
-      "ignoreArrayOrder" : true,
-      "ignoreExtraElements" : false
-    } ]
-  },
-  "response" : {
-    "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:21.603626775Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Apache Camel is an open-source framework for building and managing business 
processes that run on top of Camel Transport. It provides a modular, pluggable 
architecture that allows you to easily integrate Camel with other technologies 
such as Java, Spring, Hibernate, and more. Camel can be used to automate tasks 
such as message routing, load balancing [...]
-    "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:21 GMT",
-      "Content-Type" : "application/json; charset=utf-8"
-    }
-  },
-  "uuid" : "68c8507d-160c-4641-9a22-84bbe4806890",
-  "persistent" : true,
-  "insertionIndex" : 17
-}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-72fd4b94-5f4a-46c4-89c8-8bdec51c9229.json
similarity index 78%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-72fd4b94-5f4a-46c4-89c8-8bdec51c9229.json
index 59a3865afa..390c012f0e 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-3dbd2721-ecf7-4960-a6d9-532629c974d1.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-72fd4b94-5f4a-46c4-89c8-8bdec51c9229.json
@@ -1,5 +1,5 @@
 {
-  "id" : "3dbd2721-ecf7-4960-a6d9-532629c974d1",
+  "id" : "72fd4b94-5f4a-46c4-89c8-8bdec51c9229",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:15.36019929Z\",\"message\":{\"role\":\"assistant\",\"content\":\"John
 
Doe\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":873488110,\"load_duration\":53320906,\"prompt_eval_count\":248,\"prompt_eval_duration\":704054631,\"eval_count\":3,\"eval_duration\":110231366}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:53:25.571476951Z\",\"message\":{\"role\":\"assistant\",\"content\":\"John
 
Doe\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":535340580,\"load_duration\":54573052,\"prompt_eval_count\":248,\"prompt_eval_duration\":373240198,\"eval_count\":3,\"eval_duration\":103190582}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:15 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:53:25 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "3dbd2721-ecf7-4960-a6d9-532629c974d1",
+  "uuid" : "72fd4b94-5f4a-46c4-89c8-8bdec51c9229",
   "persistent" : true,
   "insertionIndex" : 19
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-84aa25c6-6069-4780-b9d4-4068a07c101a.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-84aa25c6-6069-4780-b9d4-4068a07c101a.json
deleted file mode 100644
index 58d548fcb3..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-84aa25c6-6069-4780-b9d4-4068a07c101a.json
+++ /dev/null
@@ -1,24 +0,0 @@
-{
-  "id" : "84aa25c6-6069-4780-b9d4-4068a07c101a",
-  "name" : "api_chat",
-  "request" : {
-    "url" : "/api/chat",
-    "method" : "POST",
-    "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"user\",\n    \"content\" : \"Return an example JSON object 
about a person named 'John Doe' with the fields age and description\"\n  } ],\n 
 \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ ]\n  },\n  
\"stream\" : false,\n  \"tools\" : [ ]\n}",
-      "ignoreArrayOrder" : true,
-      "ignoreExtraElements" : false
-    } ]
-  },
-  "response" : {
-    "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:26:18.135421673Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Sure, here's an example JSON object for John Doe with the fields age and 
description:\\n\\n```json\\n{\\n \\\"name\\\": \\\"John Doe\\\",\\n 
\\\"age\\\": 30,\\n \\\"description\\\": \\\"John Doe is a professional 
software developer with over 5 years of experience. He enjoys hiking and 
playing guitar in his free time.\\\"\\n}\\n```\"},\"done\":true,\" [...]
-    "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:18 GMT",
-      "Content-Type" : "application/json; charset=utf-8"
-    }
-  },
-  "uuid" : "84aa25c6-6069-4780-b9d4-4068a07c101a",
-  "persistent" : true,
-  "insertionIndex" : 7
-}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d2554971-ae78-4b13-99c0-57def81dfb2e.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-a6509799-4ad7-4943-8292-0c40ef7a0694.json
similarity index 76%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d2554971-ae78-4b13-99c0-57def81dfb2e.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-a6509799-4ad7-4943-8292-0c40ef7a0694.json
index a147648502..c0ef906f88 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d2554971-ae78-4b13-99c0-57def81dfb2e.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-a6509799-4ad7-4943-8292-0c40ef7a0694.json
@@ -1,5 +1,5 @@
 {
-  "id" : "d2554971-ae78-4b13-99c0-57def81dfb2e",
+  "id" : "a6509799-4ad7-4943-8292-0c40ef7a0694",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:12.287839617Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 sum of 10 and 5 is 
**15**.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1341044668,\"load_duration\":50634799,\"prompt_eval_count\":233,\"prompt_eval_duration\":573930922,\"eval_count\":14,\"eval_duration\":705548128}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:23.936571936Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 result of adding 10 and 5 is 
**15**.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1075459299,\"load_duration\":52346434,\"prompt_eval_count\":233,\"prompt_eval_duration\":306773744,\"eval_count\":15,\"eval_duration\":707026673}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:12 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:23 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "d2554971-ae78-4b13-99c0-57def81dfb2e",
+  "uuid" : "a6509799-4ad7-4943-8292-0c40ef7a0694",
   "persistent" : true,
   "insertionIndex" : 9
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-bec7f213-4af1-44b3-bd8e-3e9bcede5363.json
similarity index 75%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-bec7f213-4af1-44b3-bd8e-3e9bcede5363.json
index a984762216..c9caf18d5a 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-50282a37-becc-455a-829b-8c95dbfeac83.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-bec7f213-4af1-44b3-bd8e-3e9bcede5363.json
@@ -1,5 +1,5 @@
 {
-  "id" : "50282a37-becc-455a-829b-8c95dbfeac83",
+  "id" : "bec7f213-4af1-44b3-bd8e-3e9bcede5363",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:25:14.47274051Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_w3upfd1y\",\"function\":{\"index\":0,\"name\":\"QueryUserDatabaseByUserID\",\"arguments\":{\"userId\":123}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":4472695102,\"load_duration\":43611230,\"prompt_eval_count\":200,\"prompt_eval_duration\":3210769739,\"eval_count\":23,\"eval_duration\":1200591755}",
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:53:24.98599781Z\",\"message\":{\"role\":\"assistant\",\"content\":\"\",\"tool_calls\":[{\"id\":\"call_6sfznvu1\",\"function\":{\"index\":0,\"name\":\"QueryUserDatabaseByUserID\",\"arguments\":{\"userId\":123}}}]},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":5105319322,\"load_duration\":1604510209,\"prompt_eval_count\":200,\"prompt_eval_duration\":2380291099,\"eval_count\":23,\"eval_duration\":1107688402}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:14 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:53:24 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "50282a37-becc-455a-829b-8c95dbfeac83",
+  "uuid" : "bec7f213-4af1-44b3-bd8e-3e9bcede5363",
   "persistent" : true,
   "insertionIndex" : 20
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d4d23b6e-6f85-47ec-8c60-0dafee1ea394.json
similarity index 59%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d4d23b6e-6f85-47ec-8c60-0dafee1ea394.json
index 404d65bc24..99b8177d10 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ea5aa343-879e-4dd0-94f5-c32886e33ec6.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d4d23b6e-6f85-47ec-8c60-0dafee1ea394.json
@@ -1,5 +1,5 @@
 {
-  "id" : "ea5aa343-879e-4dd0-94f5-c32886e33ec6",
+  "id" : "d4d23b6e-6f85-47ec-8c60-0dafee1ea394",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:24.28582676Z\",\"message\":{\"role\":\"assistant\",\"content\":\"That's
 a lovely choice of color! Blue is often associated with tranquility, 
stability, and depth. If you need any information or assistance related to the 
color blue or anything else, feel free to 
ask.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2701949220,\"load_duration\":49357826,\"prompt_eval_count\":69,\"prompt_eval_duration\":3
 [...]
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:37.574204905Z\",\"message\":{\"role\":\"assistant\",\"content\":\"That's
 lovely to know, Alice! Blue is a beautiful color indeed. Is there anything 
specific about the color blue that interests you or any questions related to 
it?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1920130172,\"load_duration\":55515174,\"prompt_eval_count\":69,\"prompt_eval_duration\":203970911,\"eval_count\":34,\"eval_dura
 [...]
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:24 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:37 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "ea5aa343-879e-4dd0-94f5-c32886e33ec6",
+  "uuid" : "d4d23b6e-6f85-47ec-8c60-0dafee1ea394",
   "persistent" : true,
   "insertionIndex" : 4
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d74a88a5-321f-4d42-8a5e-28ba35105e81.json
similarity index 84%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d74a88a5-321f-4d42-8a5e-28ba35105e81.json
index a97b6e2bce..24669b7960 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d366f73b-f02a-4f62-ad43-836f42226e05.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-d74a88a5-321f-4d42-8a5e-28ba35105e81.json
@@ -1,5 +1,5 @@
 {
-  "id" : "d366f73b-f02a-4f62-ad43-836f42226e05",
+  "id" : "d74a88a5-321f-4d42-8a5e-28ba35105e81",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,13 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-03T15:26:02.290064872Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 long running operation was executed successfully with a total duration of 2 
seconds divided into 2 steps. The process completed as expected without any 
issues.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2629078989,\"load_duration\":45655974,\"prompt_eval_count\":372,\"prompt_eval_duration\":868889130,\"eval_count\":31,\"eval_du
 [...]
+    "body" : 
"{\"model\":\"granite4:3b\",\"created_at\":\"2026-03-12T08:54:12.077823233Z\",\"message\":{\"role\":\"assistant\",\"content\":\"The
 long running operation was executed successfully with a duration of 2 seconds 
and divided into 2 steps. The operation completed as 
requested.\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":1921278975,\"load_duration\":53411409,\"prompt_eval_count\":372,\"prompt_eval_duration\":469337569,\"eval_count\":28,\"eval_duration\":1382814223}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:26:02 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:12 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "d366f73b-f02a-4f62-ad43-836f42226e05",
+  "uuid" : "d74a88a5-321f-4d42-8a5e-28ba35105e81",
   "persistent" : true,
   "insertionIndex" : 12
 }
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-f472d5b5-8789-4bd9-8e7d-8649badd493b.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-f472d5b5-8789-4bd9-8e7d-8649badd493b.json
deleted file mode 100644
index d716b7ca19..0000000000
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-f472d5b5-8789-4bd9-8e7d-8649badd493b.json
+++ /dev/null
@@ -1,27 +0,0 @@
-{
-  "id" : "f472d5b5-8789-4bd9-8e7d-8649badd493b",
-  "name" : "api_chat",
-  "request" : {
-    "url" : "/api/chat",
-    "method" : "POST",
-    "bodyPatterns" : [ {
-      "equalToJson" : "{\n  \"model\" : \"orca-mini\",\n  \"messages\" : [ {\n 
   \"role\" : \"system\",\n    \"content\" : \"You are a whimsical storyteller. 
Your responses should be imaginative, descriptive, and always include a touch 
of magic. Start every story with 'Once upon a starlit night...'\"\n  }, {\n    
\"role\" : \"user\",\n    \"content\" : \"Write a short story about a lost 
cat.\"\n  } ],\n  \"options\" : {\n    \"temperature\" : 0.3,\n    \"stop\" : [ 
]\n  },\n  \"stream\" [...]
-      "ignoreArrayOrder" : true,
-      "ignoreExtraElements" : false
-    } ]
-  },
-  "response" : {
-    "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:43.847297578Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Once upon a starlit night, a curious little girl named Lily wandered through 
the forest, searching for her missing cat. She had been searching for hours and 
was about to give up when she heard a faint meowing sound. She followed the 
sound until she came across a small, shivering kitten.\\n\\nLily scooped up the 
tiny creature and took it back home wit [...]
-    "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:43 GMT",
-      "Content-Type" : "application/json; charset=utf-8"
-    }
-  },
-  "uuid" : "f472d5b5-8789-4bd9-8e7d-8649badd493b",
-  "persistent" : true,
-  "scenarioName" : "scenario-1-api-chat",
-  "requiredScenarioState" : "Started",
-  "newScenarioState" : "scenario-1-api-chat-2",
-  "insertionIndex" : 16
-}
\ No newline at end of file
diff --git 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-6b1b3f2e-5aa1-4c9b-88d3-f24a10590c6f.json
 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5.json
similarity index 57%
rename from 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-6b1b3f2e-5aa1-4c9b-88d3-f24a10590c6f.json
rename to 
integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5.json
index d4eef112b8..904353b89a 100644
--- 
a/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-6b1b3f2e-5aa1-4c9b-88d3-f24a10590c6f.json
+++ 
b/integration-tests/langchain4j-agent/src/test/resources/mappings/api_chat-ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5.json
@@ -1,5 +1,5 @@
 {
-  "id" : "6b1b3f2e-5aa1-4c9b-88d3-f24a10590c6f",
+  "id" : "ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5",
   "name" : "api_chat",
   "request" : {
     "url" : "/api/chat",
@@ -12,16 +12,13 @@
   },
   "response" : {
     "status" : 200,
-    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-03T15:25:16.303883793Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Hello, Alice. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":920820435,\"load_duration\":10510752,\"prompt_eval_count\":46,\"prompt_eval_duration\":343358491,\"eval_count\":12,\"eval_duration\":563204651}",
+    "body" : 
"{\"model\":\"orca-mini\",\"created_at\":\"2026-03-12T08:54:42.177426867Z\",\"message\":{\"role\":\"assistant\",\"content\":\"
 Hello, Alice. How can I assist you 
today?\"},\"done\":true,\"done_reason\":\"stop\",\"total_duration\":2518065294,\"load_duration\":1470823432,\"prompt_eval_count\":46,\"prompt_eval_duration\":520854693,\"eval_count\":12,\"eval_duration\":522806793}",
     "headers" : {
-      "Date" : "Tue, 03 Mar 2026 15:25:16 GMT",
+      "Date" : "Thu, 12 Mar 2026 08:54:42 GMT",
       "Content-Type" : "application/json; charset=utf-8"
     }
   },
-  "uuid" : "6b1b3f2e-5aa1-4c9b-88d3-f24a10590c6f",
+  "uuid" : "ff735dd8-8cd3-4f0c-b664-7d7b54bfc7b5",
   "persistent" : true,
-  "scenarioName" : "scenario-2-api-chat",
-  "requiredScenarioState" : "Started",
-  "newScenarioState" : "scenario-2-api-chat-2",
-  "insertionIndex" : 18
+  "insertionIndex" : 2
 }
\ No newline at end of file

Reply via email to