Class AnthropicConversationMerger
java.lang.Object
io.agentscope.extensions.model.anthropic.formatter.AnthropicConversationMerger
Merges multi-agent conversation messages into a formatted conversation history for Anthropic
API.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionmergeConversation(List<io.agentscope.core.message.Msg> messages, String conversationHistoryPrompt) Merge conversation messages into formatted blocks with history tags.
-
Constructor Details
-
AnthropicConversationMerger
public AnthropicConversationMerger()
-
-
Method Details
-
mergeConversation
public static List<Object> mergeConversation(List<io.agentscope.core.message.Msg> messages, String conversationHistoryPrompt) Merge conversation messages into formatted blocks with history tags.- Parameters:
messages- List of conversation messagesconversationHistoryPrompt- Prompt text to prepend- Returns:
- List of content blocks (text and images)
-