Class MiniMaxMultiAgentFormatter
java.lang.Object
io.agentscope.core.formatter.AbstractBaseFormatter<OpenAIMessage,OpenAIResponse,OpenAIRequest>
io.agentscope.extensions.model.openai.formatter.OpenAIBaseFormatter
io.agentscope.extensions.model.openai.formatter.OpenAIChatFormatter
io.agentscope.extensions.model.openai.formatter.OpenAIMultiAgentFormatter
io.agentscope.extensions.model.openai.compat.minimax.MiniMaxMultiAgentFormatter
- All Implemented Interfaces:
io.agentscope.core.formatter.Formatter<OpenAIMessage,OpenAIResponse, OpenAIRequest>
Multi-agent formatter for MiniMax OpenAI-compatible chat completions.
-
Field Summary
Fields inherited from class io.agentscope.extensions.model.openai.formatter.OpenAIBaseFormatter
messageConverter, responseParser -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidapplyMaxTokens(OpenAIRequest request, io.agentscope.core.model.GenerateOptions options, io.agentscope.core.model.GenerateOptions defaultOptions) voidapplyOptions(OpenAIRequest request, io.agentscope.core.model.GenerateOptions options, io.agentscope.core.model.GenerateOptions defaultOptions) Apply generation options to the request.voidapplyToolChoice(OpenAIRequest request, io.agentscope.core.model.ToolChoice toolChoice) Apply tool choice configuration to the request.protected booleanReturns whether this formatter's target API supports the strict parameter in tool definitions.Methods inherited from class io.agentscope.extensions.model.openai.formatter.OpenAIMultiAgentFormatter
doFormat, doFormatMethods inherited from class io.agentscope.extensions.model.openai.formatter.OpenAIChatFormatter
applyAdditionalBodyParams, applyTools, convertMessageMethods inherited from class io.agentscope.extensions.model.openai.formatter.OpenAIBaseFormatter
applyToolChoice, applyTools, buildRequest, buildRequest, parseResponseMethods inherited from class io.agentscope.core.formatter.AbstractBaseFormatter
convertToolResultToString, extractTextContent, extractTextContent, format, format, formatRoleLabel, getOptionOrDefault, hasMediaContent, saveBase64DataToTempFile, shouldBypassHistory
-
Constructor Details
-
MiniMaxMultiAgentFormatter
public MiniMaxMultiAgentFormatter() -
MiniMaxMultiAgentFormatter
-
-
Method Details
-
applyOptions
public void applyOptions(OpenAIRequest request, io.agentscope.core.model.GenerateOptions options, io.agentscope.core.model.GenerateOptions defaultOptions) Description copied from class:OpenAIBaseFormatterApply generation options to the request. Subclasses implement provider-specific option handling.- Specified by:
applyOptionsin interfaceio.agentscope.core.formatter.Formatter<OpenAIMessage,OpenAIResponse, OpenAIRequest> - Overrides:
applyOptionsin classOpenAIChatFormatter- Parameters:
request- OpenAI request DTOoptions- Generation options to applydefaultOptions- Default options to use if options parameter is null
-
applyMaxTokens
protected void applyMaxTokens(OpenAIRequest request, io.agentscope.core.model.GenerateOptions options, io.agentscope.core.model.GenerateOptions defaultOptions) - Overrides:
applyMaxTokensin classOpenAIChatFormatter
-
supportsStrict
protected boolean supportsStrict()Description copied from class:OpenAIChatFormatterReturns whether this formatter's target API supports the strict parameter in tool definitions.Subclasses can override this method to disable strict parameter for providers that don't support it (e.g., DeepSeek).
- Overrides:
supportsStrictin classOpenAIChatFormatter- Returns:
- true if strict parameter is supported, false otherwise
-
applyToolChoice
Description copied from class:OpenAIBaseFormatterApply tool choice configuration to the request. Subclasses implement provider-specific tool choice handling.- Specified by:
applyToolChoicein interfaceio.agentscope.core.formatter.Formatter<OpenAIMessage,OpenAIResponse, OpenAIRequest> - Overrides:
applyToolChoicein classOpenAIChatFormatter- Parameters:
request- OpenAI request DTOtoolChoice- Tool choice configuration (null means auto)
-