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

wenjin272 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/flink-agents.git


The following commit(s) were added to refs/heads/main by this push:
     new d1c0ee71 [examples] Add static import for copyResource in 
YamlWorkflowAgentExample (#799)
d1c0ee71 is described below

commit d1c0ee71aa16d0a5bd06b7898ea2c6c4b10b054b
Author: Kerui Wang <[email protected]>
AuthorDate: Mon Jun 8 16:35:45 2026 +0800

    [examples] Add static import for copyResource in YamlWorkflowAgentExample 
(#799)
---
 .../org/apache/flink/agents/examples/YamlWorkflowAgentExample.java | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git 
a/examples/src/main/java/org/apache/flink/agents/examples/YamlWorkflowAgentExample.java
 
b/examples/src/main/java/org/apache/flink/agents/examples/YamlWorkflowAgentExample.java
index 60cfbb25..3f118809 100644
--- 
a/examples/src/main/java/org/apache/flink/agents/examples/YamlWorkflowAgentExample.java
+++ 
b/examples/src/main/java/org/apache/flink/agents/examples/YamlWorkflowAgentExample.java
@@ -28,6 +28,8 @@ import 
org.apache.flink.streaming.api.environment.StreamExecutionEnvironment;
 
 import java.io.File;
 
+import static 
org.apache.flink.agents.examples.WorkflowSingleAgentExample.copyResource;
+
 /**
  * Java example demonstrating a YAML-declared workflow agent.
  *
@@ -59,13 +61,12 @@ public class YamlWorkflowAgentExample {
         // Load the YAML — the declared agent and its chat-model connection,
         // chat-model setup, prompt, tool, and actions are all registered on
         // the environment in this single call.
-        File yamlFile =
-                
WorkflowSingleAgentExample.copyResource("yaml/yaml_review_analysis_agent.yaml");
+        File yamlFile = copyResource("yaml/yaml_review_analysis_agent.yaml");
         agentsEnv.loadYaml(yamlFile.toPath());
 
         // Read product reviews from input_data.txt file as a streaming source.
         // Each element represents a ProductReview.
-        File inputDataFile = 
WorkflowSingleAgentExample.copyResource("input_data.txt");
+        File inputDataFile = copyResource("input_data.txt");
         DataStream<String> productReviewStream =
                 env.fromSource(
                         FileSource.forRecordStreamFormat(

Reply via email to