diff --git a/.github/workflows/bld.yml b/.github/workflows/bld.yml
index 4e857aa..cf0302b 100644
--- a/.github/workflows/bld.yml
+++ b/.github/workflows/bld.yml
@@ -25,7 +25,7 @@ jobs:
strategy:
matrix:
java-version: [17, 21, 24]
- kotlin-version: [1.9.25, 2.0.20, 2.1.21]
+ kotlin-version: [1.9.25, 2.0.20, 2.1.20]
steps:
- name: Checkout source repository
diff --git a/README.md b/README.md
index 119c03e..d43ba67 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
# mobibot
[](https://opensource.org/licenses/BSD-3-Clause)
-[](https://kotlinlang.org)
+[](https://kotlinlang.org)
[](https://rife2.com/bld)
[](https://sonarcloud.io/summary/new_code?id=ethauvin_mobibot)
[](https://github.com/ethauvin/mobibot/actions/workflows/bld.yml)
diff --git a/lib/bld/bld-wrapper.properties b/lib/bld/bld-wrapper.properties
index 2ff628d..8b96558 100644
--- a/lib/bld/bld-wrapper.properties
+++ b/lib/bld/bld-wrapper.properties
@@ -2,7 +2,6 @@ bld.downloadExtensionJavadoc=false
bld.downloadExtensionSources=true
bld.downloadLocation=
bld.extension-detekt=com.uwyn.rife2:bld-detekt:0.9.10-SNAPSHOT
-bld.extension-exec=com.uwyn.rife2:bld-exec:1.0.5
bld.extension-gv=com.uwyn.rife2:bld-generated-version:1.0.1
bld.extension-jacoco=com.uwyn.rife2:bld-jacoco-report:0.9.10
bld.extension-kotlin=com.uwyn.rife2:bld-kotlin:1.1.0-SNAPSHOT
diff --git a/pom.xml b/pom.xml
index 323022e..7d916f4 100644
--- a/pom.xml
+++ b/pom.xml
@@ -4,7 +4,7 @@
4.0.0
net.thauvin.erik.mobibot
mobibot
- 0.8.0-rc+20250515215148
+ 0.8.0-rc+20250509073816
mobibot
@@ -54,25 +54,25 @@
org.jetbrains.kotlin
kotlin-stdlib
- 2.1.21
+ 2.1.20
compile
org.jetbrains.kotlin
kotlin-stdlib-common
- 2.1.21
+ 2.1.20
compile
org.jetbrains.kotlin
kotlin-stdlib-jdk7
- 2.1.21
+ 2.1.20
compile
org.jetbrains.kotlin
kotlin-stdlib-jdk8
- 2.1.21
+ 2.1.20
compile
@@ -114,25 +114,25 @@
dev.langchain4j
langchain4j-open-ai
- 1.0.0
+ 0.36.2
compile
dev.langchain4j
langchain4j-google-ai-gemini
- 1.0.0-beta5
+ 0.36.2
compile
dev.langchain4j
langchain4j-core
- 1.0.0
+ 0.36.2
compile
dev.langchain4j
langchain4j
- 1.0.0
+ 0.36.2
compile
diff --git a/src/bld/java/net/thauvin/erik/MobibotBuild.java b/src/bld/java/net/thauvin/erik/MobibotBuild.java
index 0cdac32..dde5dc8 100644
--- a/src/bld/java/net/thauvin/erik/MobibotBuild.java
+++ b/src/bld/java/net/thauvin/erik/MobibotBuild.java
@@ -34,7 +34,10 @@ package net.thauvin.erik;
import rife.bld.BuildCommand;
import rife.bld.Project;
import rife.bld.dependencies.Repository;
-import rife.bld.extension.*;
+import rife.bld.extension.CompileKotlinOperation;
+import rife.bld.extension.DetektOperation;
+import rife.bld.extension.GeneratedVersionOperation;
+import rife.bld.extension.JacocoReportOperation;
import rife.bld.operations.exceptions.ExitStatusException;
import rife.bld.publish.PomBuilder;
import rife.tools.FileUtils;
@@ -42,8 +45,6 @@ import rife.tools.exceptions.FileUtilsErrorException;
import java.io.File;
import java.io.IOException;
-import java.nio.file.Files;
-import java.nio.file.Path;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
@@ -81,8 +82,8 @@ public class MobibotBuild extends Project {
SONATYPE_SNAPSHOTS_LEGACY);
var log4j = version(2, 24, 3);
- var kotlin = version(2, 1, 21);
- var langchain = version(1, 0, 0);
+ var kotlin = version(2, 1, 20);
+ var langchain = version(0, 36, 2);
scope(compile)
// PircBotX
.include(dependency("com.github.pircbotx", "pircbotx", "2.3.1"))
@@ -108,7 +109,7 @@ public class MobibotBuild extends Project {
.include(dependency("org.apache.logging.log4j", "log4j-slf4j2-impl", log4j))
// LangChain4J
.include(dependency("dev.langchain4j", "langchain4j-open-ai", langchain))
- .include(dependency("dev.langchain4j", "langchain4j-google-ai-gemini", "1.0.0-beta5"))
+ .include(dependency("dev.langchain4j", "langchain4j-google-ai-gemini", langchain))
.include(dependency("dev.langchain4j", "langchain4j-core", langchain))
.include(dependency("dev.langchain4j", "langchain4j", langchain))
// Misc.
@@ -239,25 +240,4 @@ public class MobibotBuild extends Project {
.extension(".kt")
.execute();
}
-
- @Override
- public void test() throws Exception {
- var testResultsDir = "build/test-results/test/";
-
- var op = testOperation().fromProject(this);
- op.testToolOptions().reportsDir(new File(testResultsDir));
- op.execute();
-
- var xunitViewer = new File("/usr/bin/xunit-viewer");
- if (xunitViewer.exists() && xunitViewer.canExecute()) {
- var reportsDir = "build/reports/tests/test/";
-
- Files.createDirectories(Path.of(reportsDir));
-
- new ExecOperation()
- .fromProject(this)
- .command(xunitViewer.getPath(), "-r", testResultsDir, "-o", reportsDir + "index.html")
- .execute();
- }
- }
}
diff --git a/src/main/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2.kt b/src/main/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2.kt
index 078eb3c..c31cbaf 100644
--- a/src/main/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2.kt
+++ b/src/main/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2.kt
@@ -77,7 +77,7 @@ class ChatGpt2 : AbstractModule() {
.maxTokens(maxTokens)
.build()
- return model.chat(query)
+ return model.generate(query)
} catch (e: Exception) {
throw ModuleException(
"$CHATGPT_CMD($query): IO",
diff --git a/src/main/kotlin/net/thauvin/erik/mobibot/modules/Gemini2.kt b/src/main/kotlin/net/thauvin/erik/mobibot/modules/Gemini2.kt
index 6707b73..a690e26 100644
--- a/src/main/kotlin/net/thauvin/erik/mobibot/modules/Gemini2.kt
+++ b/src/main/kotlin/net/thauvin/erik/mobibot/modules/Gemini2.kt
@@ -90,7 +90,7 @@ class Gemini2 : AbstractModule() {
.maxOutputTokens(maxTokens)
.build()
- return gemini.chat(query)
+ return gemini.generate(query)
} catch (e: Exception) {
throw ModuleException("$GEMINI_CMD($query): IO", IO_ERROR, e)
}
diff --git a/src/test/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2Test.kt b/src/test/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2Test.kt
index f12e1dd..573dfa2 100644
--- a/src/test/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2Test.kt
+++ b/src/test/kotlin/net/thauvin/erik/mobibot/modules/ChatGpt2Test.kt
@@ -71,7 +71,6 @@ class ChatGpt2Test : LocalProperties() {
.isInstanceOf(ModuleException::class.java)
.hasNoCause()
}
-
private val apiKey = getProperty(ChatGpt2.API_KEY_PROP)
@Test