Class AgentFactory

java.lang.Object
com.techcognita.javachatx.agent.AgentFactory

public class AgentFactory extends Object
Factory for creating different types of agents. Demonstrates how the framework can be extended with new agent types.
  • Constructor Details

    • AgentFactory

      public AgentFactory()
  • Method Details

    • createEchoAgent

      public static EchoAgent createEchoAgent()
      Create a new EchoAgent with a unique ID.
      Returns:
      A new EchoAgent instance
    • createEchoAgent

      public static EchoAgent createEchoAgent(String id)
      Create a new EchoAgent with a specified ID.
      Parameters:
      id - The ID for the new agent
      Returns:
      A new EchoAgent instance