Class LLMAgentRoutingSpecsResolver

  • All Implemented Interfaces:
    ai.ancf.lmos.router.core.AgentRoutingSpecsResolver

    
    public final class LLMAgentRoutingSpecsResolver
     implements AgentRoutingSpecsResolver
                        

    An agent spec resolver that uses a language model to resolve agent specs.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      AgentRoutingSpecsProvider getAgentRoutingSpecsProvider()
      Result<AgentRoutingSpec, AgentRoutingSpecResolverException> resolve(Context context, UserMessage input)
      Result<AgentRoutingSpec, AgentRoutingSpecResolverException> resolve(Set<SpecFilter> filters, Context context, UserMessage input)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LLMAgentRoutingSpecsResolver

        LLMAgentRoutingSpecsResolver(AgentRoutingSpecsProvider agentRoutingSpecsProvider, ModelPromptProvider modelPromptProvider, ModelClient modelClient, Json serializer)
        Parameters:
        agentRoutingSpecsProvider - The provider of agent routing specifications.
        modelPromptProvider - The provider of model prompts.
        modelClient - The client for the language model.
        serializer - The JSON serializer.
    • Method Detail

      • resolve

         Result<AgentRoutingSpec, AgentRoutingSpecResolverException> resolve(Context context, UserMessage input)
      • resolve

         Result<AgentRoutingSpec, AgentRoutingSpecResolverException> resolve(Set<SpecFilter> filters, Context context, UserMessage input)