Class FunctionCallingHelper
java.lang.Object
org.springframework.ai.chat.model.AbstractToolCallSupport
org.springframework.ai.model.function.FunctionCallingHelper
Deprecated.
Helper class that reuses the
AbstractToolCallSupport to implement the function
call handling logic on the client side. Used when the withProxyToolCalls(true) option
is enabled.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordDeprecated.Helper used to provide only the function definition, without the actual function call implementation. -
Field Summary
Fields inherited from class org.springframework.ai.chat.model.AbstractToolCallSupport
functionCallbackRegister, functionCallbackResolver, IS_RUNTIME_CALL -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated.FunctionCallingHelper(FunctionCallbackResolver functionCallbackResolver, FunctionCallingOptions functionCallingOptions, List<FunctionCallback> toolFunctionCallbacks) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionbuildToolCallConversation(List<Message> previousMessages, AssistantMessage assistantMessage, ToolResponseMessage toolResponseMessage) Deprecated.handleToolCalls(Prompt prompt, ChatResponse response) Deprecated.booleanisToolCall(ChatResponse chatResponse, Set<String> toolCallFinishReasons) Deprecated.processCall(ChatModel chatModel, Prompt prompt, Set<String> finishReasons, Function<AssistantMessage.ToolCall, String> customFunction) Deprecated.reactor.core.publisher.Flux<ChatResponse>processStream(ChatModel chatModel, Prompt prompt, Set<String> finishReasons, Function<AssistantMessage.ToolCall, String> customFunction) Deprecated.Methods inherited from class org.springframework.ai.chat.model.AbstractToolCallSupport
executeFunctions, getFunctionCallbackRegister, isProxyToolCalls, isToolCall, resolveFunctionCallbacks, runtimeFunctionCallbackConfigurations
-
Constructor Details
-
FunctionCallingHelper
public FunctionCallingHelper()Deprecated. -
FunctionCallingHelper
public FunctionCallingHelper(FunctionCallbackResolver functionCallbackResolver, FunctionCallingOptions functionCallingOptions, List<FunctionCallback> toolFunctionCallbacks) Deprecated.
-
-
Method Details
-
isToolCall
Deprecated.- Overrides:
isToolCallin classAbstractToolCallSupport
-
buildToolCallConversation
public List<Message> buildToolCallConversation(List<Message> previousMessages, AssistantMessage assistantMessage, ToolResponseMessage toolResponseMessage) Deprecated.- Overrides:
buildToolCallConversationin classAbstractToolCallSupport
-
handleToolCalls
Deprecated.- Overrides:
handleToolCallsin classAbstractToolCallSupport
-
processStream
public reactor.core.publisher.Flux<ChatResponse> processStream(ChatModel chatModel, Prompt prompt, Set<String> finishReasons, Function<AssistantMessage.ToolCall, String> customFunction) Deprecated. -
processCall
public ChatResponse processCall(ChatModel chatModel, Prompt prompt, Set<String> finishReasons, Function<AssistantMessage.ToolCall, String> customFunction) Deprecated.
-
ToolCallingManagerinstead.