Class DynamicFanOutFanInWorkflow

java.lang.Object
com.example.workflows.DynamicFanOutFanInWorkflow

public final class DynamicFanOutFanInWorkflow extends Object
A port of adk-python's dynamic_fan_out_fan_in workflow sample: one node splits the user's comma-separated topics, runs a headline agent on each topic concurrently with runNode, and collects the headlines into one table. The number of runs comes from the input, not the graph.
  • Method Details

    • create

      public static Workflow create(String model)
      Builds the workflow, with the agent on model.
    • main

      public static void main(String[] args)
      Runs the workflow on three topics and prints the table. It calls Gemini, so it needs the credentials the README describes; the first argument, if any, overrides the model.