Interface FunctionPrompter
- All Known Implementing Classes:
SwingFunctionPrompter
public interface FunctionPrompter
An interface for UI components that can prompt the user to confirm a batch of
function calls.
This decouples the core function-calling logic from any specific UI implementation (e.g., Swing, command-line), allowing the framework to be embedded in different environments.
- Author:
- anahata
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classA value object holding the results of a user confirmation prompt. -
Method Summary
Modifier and TypeMethodDescriptionprompt(ChatMessage modelMessage, Chat chat) Prompts the user to confirm a list of function calls from the model's response.
-
Method Details
-
prompt
Prompts the user to confirm a list of function calls from the model's response.This method is responsible for displaying the proposed calls and their arguments to the user and collecting their approval or denial for each.
- Parameters:
modelMessage- The fullChatMessagefrom the model, containing one or more function calls.chat- The currentChatinstance, providing access to context and configuration.- Returns:
- A
FunctionPrompter.PromptResultobject containing the user's choices and comments.
-
