Class SpringToolCallbackAdapter

  • All Implemented Interfaces:
    org.springframework.ai.tool.ToolCallback

    
    public final class SpringToolCallbackAdapter
     implements ToolCallback
                        

    Adapts an Embabel Tool to Spring AI's ToolCallback interface.

    This adapter bridges the framework-agnostic Tool abstraction to Spring AI, allowing tools defined using the Embabel API to be used with Spring AI's chat models and tool calling infrastructure.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      ToolDefinition getToolDefinition()
      ToolMetadata getToolMetadata()
      String call(String toolInput)
      String call(String toolInput, ToolContext toolContext) Override to avoid Spring AI's default warning about unused ToolContext.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait