diff --git a/demo2-springai-temporal-integration/pom.xml b/demo2-springai-temporal-integration/pom.xml index f6cda3d..89d3f94 100644 --- a/demo2-springai-temporal-integration/pom.xml +++ b/demo2-springai-temporal-integration/pom.xml @@ -16,8 +16,8 @@ 3.5.3 - 1.0.1 - 1.31.0 + 1.1.0 + 1.34.0 @@ -51,9 +51,9 @@ - io.temporal.ai + io.temporal temporal-spring-ai - 0.0.1-SNAPSHOT + 1.35.0-SNAPSHOT diff --git a/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java b/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java index 3fa5533..114705f 100644 --- a/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java +++ b/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java @@ -4,9 +4,9 @@ package io.temporal.ai.workshop; import io.temporal.activity.ActivityOptions; -import io.temporal.ai.chat.client.TemporalChatClient; -import io.temporal.ai.chat.model.ActivityChatModel; -import io.temporal.ai.chat.model.ChatModelActivity; +import io.temporal.springai.chat.TemporalChatClient; +import io.temporal.springai.model.ActivityChatModel; +import io.temporal.springai.activity.ChatModelActivity; import io.temporal.ai.workshop.tools.ToolActivities; import io.temporal.workflow.Workflow; import io.temporal.workflow.WorkflowInit; diff --git a/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/WorkerApplication.java b/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/WorkerApplication.java index a090e3b..81f9830 100644 --- a/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/WorkerApplication.java +++ b/demo2-springai-temporal-integration/src/main/java/io/temporal/ai/workshop/WorkerApplication.java @@ -1,19 +1,13 @@ // ABOUTME: Spring Boot entry point that starts the Temporal worker. // The temporal-spring-boot-starter auto-configures the worker from application.yaml. +// The temporal-spring-ai plugin auto-registers ChatModelActivity via auto-configuration. package io.temporal.ai.workshop; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.context.annotation.ComponentScan; -import org.springframework.context.annotation.FilterType; @SpringBootApplication -@ComponentScan( - basePackages = "io.temporal.ai", - excludeFilters = @ComponentScan.Filter( - type = FilterType.REGEX, - pattern = "io\\.temporal\\.ai\\.mcp\\..*")) public class WorkerApplication { public static void main(String[] args) { diff --git a/demo2-springai-temporal-integration/src/main/resources/application.yaml b/demo2-springai-temporal-integration/src/main/resources/application.yaml index 8657383..029087d 100644 --- a/demo2-springai-temporal-integration/src/main/resources/application.yaml +++ b/demo2-springai-temporal-integration/src/main/resources/application.yaml @@ -21,5 +21,4 @@ spring: workflow-classes: - io.temporal.ai.workshop.AgentWorkflowImpl activity-beans: - - chatModelActivity - toolActivitiesImpl diff --git a/demo3-mcp/pom.xml b/demo3-mcp/pom.xml index 2d30eff..9f81f9c 100644 --- a/demo3-mcp/pom.xml +++ b/demo3-mcp/pom.xml @@ -16,8 +16,8 @@ 3.5.3 - 1.0.1 - 1.31.0 + 1.1.0 + 1.34.0 @@ -61,9 +61,9 @@ - io.temporal.ai + io.temporal temporal-spring-ai - 0.0.1-SNAPSHOT + 1.35.0-SNAPSHOT diff --git a/demo3-mcp/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java b/demo3-mcp/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java index faf2edd..2786494 100644 --- a/demo3-mcp/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java +++ b/demo3-mcp/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java @@ -4,12 +4,12 @@ package io.temporal.ai.workshop; import io.temporal.activity.ActivityOptions; -import io.temporal.ai.chat.client.TemporalChatClient; -import io.temporal.ai.chat.model.ActivityChatModel; -import io.temporal.ai.chat.model.ChatModelActivity; -import io.temporal.ai.mcp.McpToolCallback; -import io.temporal.ai.mcp.client.ActivityMcpClient; -import io.temporal.ai.mcp.client.McpClientActivity; +import io.temporal.springai.chat.TemporalChatClient; +import io.temporal.springai.model.ActivityChatModel; +import io.temporal.springai.activity.ChatModelActivity; +import io.temporal.springai.mcp.McpToolCallback; +import io.temporal.springai.mcp.ActivityMcpClient; +import io.temporal.springai.mcp.McpClientActivity; import io.temporal.ai.workshop.tools.ToolActivities; import io.temporal.workflow.Workflow; import io.temporal.workflow.WorkflowInit; @@ -56,7 +56,7 @@ public AgentWorkflowImpl(String goal) { ActivityChatModel activityChatModel = new ActivityChatModel(chatModelActivity); ActivityMcpClient mcpClient = new ActivityMcpClient(mcpClientActivity); - List mcpTools = McpToolCallback.fromMcpTools(mcpClient); + List mcpTools = McpToolCallback.fromMcpClient(mcpClient); // Inject current date into system prompt using Temporal's deterministic clock String currentDate = Instant.ofEpochMilli(Workflow.currentTimeMillis()) diff --git a/demo3-mcp/src/main/java/io/temporal/ai/workshop/WorkerApplication.java b/demo3-mcp/src/main/java/io/temporal/ai/workshop/WorkerApplication.java index f59b96c..6a7bf04 100644 --- a/demo3-mcp/src/main/java/io/temporal/ai/workshop/WorkerApplication.java +++ b/demo3-mcp/src/main/java/io/temporal/ai/workshop/WorkerApplication.java @@ -1,12 +1,13 @@ // ABOUTME: Spring Boot entry point that starts the Temporal worker. // The temporal-spring-boot-starter auto-configures the worker from application.yaml. +// The temporal-spring-ai plugin auto-registers ChatModelActivity and McpClientActivity via auto-configuration. package io.temporal.ai.workshop; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; -@SpringBootApplication(scanBasePackages = "io.temporal.ai") +@SpringBootApplication public class WorkerApplication { public static void main(String[] args) { diff --git a/demo3-mcp/src/main/resources/application.yaml b/demo3-mcp/src/main/resources/application.yaml index 96cabca..f08706d 100644 --- a/demo3-mcp/src/main/resources/application.yaml +++ b/demo3-mcp/src/main/resources/application.yaml @@ -25,6 +25,4 @@ spring: workflow-classes: - io.temporal.ai.workshop.AgentWorkflowImpl activity-beans: - - chatModelActivity - toolActivitiesImpl - - mcpClientActivityImpl diff --git a/demo4-hitl/pom.xml b/demo4-hitl/pom.xml index 505619a..2a241c4 100644 --- a/demo4-hitl/pom.xml +++ b/demo4-hitl/pom.xml @@ -16,8 +16,8 @@ 3.5.3 - 1.0.1 - 1.31.0 + 1.1.0 + 1.34.0 @@ -61,9 +61,9 @@ - io.temporal.ai + io.temporal temporal-spring-ai - 0.0.1-SNAPSHOT + 1.35.0-SNAPSHOT diff --git a/demo4-hitl/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java b/demo4-hitl/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java index 07156ea..0f18147 100644 --- a/demo4-hitl/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java +++ b/demo4-hitl/src/main/java/io/temporal/ai/workshop/AgentWorkflowImpl.java @@ -4,12 +4,12 @@ package io.temporal.ai.workshop; import io.temporal.activity.ActivityOptions; -import io.temporal.ai.chat.client.TemporalChatClient; -import io.temporal.ai.chat.model.ActivityChatModel; -import io.temporal.ai.chat.model.ChatModelActivity; -import io.temporal.ai.mcp.McpToolCallback; -import io.temporal.ai.mcp.client.ActivityMcpClient; -import io.temporal.ai.mcp.client.McpClientActivity; +import io.temporal.springai.chat.TemporalChatClient; +import io.temporal.springai.model.ActivityChatModel; +import io.temporal.springai.activity.ChatModelActivity; +import io.temporal.springai.mcp.McpToolCallback; +import io.temporal.springai.mcp.ActivityMcpClient; +import io.temporal.springai.mcp.McpClientActivity; import io.temporal.ai.workshop.tools.ToolActivities; import io.temporal.workflow.Workflow; import io.temporal.workflow.WorkflowInit; @@ -68,7 +68,7 @@ public String run(String goal) { // signal/query handler registration. ActivityChatModel activityChatModel = new ActivityChatModel(chatModelActivity); ActivityMcpClient mcpClient = new ActivityMcpClient(mcpClientActivity); - List mcpTools = McpToolCallback.fromMcpTools(mcpClient); + List mcpTools = McpToolCallback.fromMcpClient(mcpClient); String currentDate = Instant.ofEpochMilli(Workflow.currentTimeMillis()) .atOffset(ZoneOffset.UTC) diff --git a/demo4-hitl/src/main/java/io/temporal/ai/workshop/AskUserTool.java b/demo4-hitl/src/main/java/io/temporal/ai/workshop/AskUserTool.java index c461305..4d3d583 100644 --- a/demo4-hitl/src/main/java/io/temporal/ai/workshop/AskUserTool.java +++ b/demo4-hitl/src/main/java/io/temporal/ai/workshop/AskUserTool.java @@ -3,7 +3,7 @@ package io.temporal.ai.workshop; -import io.temporal.ai.tool.DeterministicTool; +import io.temporal.springai.tool.DeterministicTool; import io.temporal.workflow.Workflow; import org.springframework.ai.tool.annotation.Tool; import org.springframework.ai.tool.annotation.ToolParam; diff --git a/demo4-hitl/src/main/java/io/temporal/ai/workshop/WorkerApplication.java b/demo4-hitl/src/main/java/io/temporal/ai/workshop/WorkerApplication.java index f59b96c..6a7bf04 100644 --- a/demo4-hitl/src/main/java/io/temporal/ai/workshop/WorkerApplication.java +++ b/demo4-hitl/src/main/java/io/temporal/ai/workshop/WorkerApplication.java @@ -1,12 +1,13 @@ // ABOUTME: Spring Boot entry point that starts the Temporal worker. // The temporal-spring-boot-starter auto-configures the worker from application.yaml. +// The temporal-spring-ai plugin auto-registers ChatModelActivity and McpClientActivity via auto-configuration. package io.temporal.ai.workshop; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; -@SpringBootApplication(scanBasePackages = "io.temporal.ai") +@SpringBootApplication public class WorkerApplication { public static void main(String[] args) { diff --git a/demo4-hitl/src/main/resources/application.yaml b/demo4-hitl/src/main/resources/application.yaml index 96cabca..f08706d 100644 --- a/demo4-hitl/src/main/resources/application.yaml +++ b/demo4-hitl/src/main/resources/application.yaml @@ -25,6 +25,4 @@ spring: workflow-classes: - io.temporal.ai.workshop.AgentWorkflowImpl activity-beans: - - chatModelActivity - toolActivitiesImpl - - mcpClientActivityImpl diff --git a/lib/temporal-spring-ai-0.0.1-SNAPSHOT.jar b/lib/temporal-spring-ai-0.0.1-SNAPSHOT.jar deleted file mode 100644 index 5664a41..0000000 Binary files a/lib/temporal-spring-ai-0.0.1-SNAPSHOT.jar and /dev/null differ diff --git a/lib/temporal-spring-ai-1.35.0-SNAPSHOT.jar b/lib/temporal-spring-ai-1.35.0-SNAPSHOT.jar new file mode 100644 index 0000000..d1e4a3a Binary files /dev/null and b/lib/temporal-spring-ai-1.35.0-SNAPSHOT.jar differ diff --git a/scripts/install-libs.sh b/scripts/install-libs.sh index 45cee39..3cec44e 100755 --- a/scripts/install-libs.sh +++ b/scripts/install-libs.sh @@ -10,12 +10,12 @@ LIB_DIR="$SCRIPT_DIR/../lib" echo "Installing temporal-spring-ai jar to local Maven repository..." mvn install:install-file \ - -Dfile="$LIB_DIR/temporal-spring-ai-0.0.1-SNAPSHOT.jar" \ - -DgroupId=io.temporal.ai \ + -Dfile="$LIB_DIR/temporal-spring-ai-1.35.0-SNAPSHOT.jar" \ + -DgroupId=io.temporal \ -DartifactId=temporal-spring-ai \ - -Dversion=0.0.1-SNAPSHOT \ + -Dversion=1.35.0-SNAPSHOT \ -Dpackaging=jar \ -q -echo " Installed temporal-spring-ai-0.0.1-SNAPSHOT" +echo " Installed temporal-spring-ai-1.35.0-SNAPSHOT" echo "Done."