AS AgentScopeAPI 手册 / API Reference

MiniMaxFormatter

public class MiniMaxFormatter extends OpenAIChatFormatter
源码Source io/agentscope/extensions/model/openai/compat/minimax/MiniMaxFormatter.java:29–88

用于MiniMax OpenAI 兼容的聊天补全的格式化器。位于 io.agentscope.extensions.model.openai.compat.minimax 包,继承自 OpenAIChatFormatter。核心成员包括 applyOptions、applyMaxTokens、applyToolChoice、supportsStrict。

Formatter for MiniMax OpenAI-compatible chat completions.

MiniMax Chat Completions API.

方法摘要Method Summary

方法Method说明Description
public void applyOptions(OpenAIRequest request, GenerateOptions options, GenerateOptions defaultOptions)
应用选项。
Performs the apply options operation.
protected void applyMaxTokens(OpenAIRequest request, GenerateOptions options, GenerateOptions defaultOptions)
应用最大令牌数。
Performs the apply max tokens operation.
public void applyToolChoice(OpenAIRequest request, ToolChoice toolChoice)
应用工具选项。
Performs the apply tool choice operation.
protected boolean supportsStrict()
返回 `supportsStrict` 结果。
Returns the supports strict.

方法详情Method Detail

applyOptions

public void applyOptions(OpenAIRequest request, GenerateOptions options, GenerateOptions defaultOptions)

应用选项。

Performs the apply options operation.

参数Parameters
名称Name类型Type说明Description
requestOpenAIRequest请求(类型 `OpenAIRequest`)。The request.
optionsGenerateOptions选项(类型 `GenerateOptions`)。The options.
defaultOptionsGenerateOptions默认选项(类型 `GenerateOptions`)。The default options.
源码Source io/agentscope/extensions/model/openai/compat/minimax/MiniMaxFormatter.java:31–38

applyMaxTokens

protected void applyMaxTokens(OpenAIRequest request, GenerateOptions options, GenerateOptions defaultOptions)

应用最大令牌数。

Performs the apply max tokens operation.

参数Parameters
名称Name类型Type说明Description
requestOpenAIRequest请求(类型 `OpenAIRequest`)。The request.
optionsGenerateOptions选项(类型 `GenerateOptions`)。The options.
defaultOptionsGenerateOptions默认选项(类型 `GenerateOptions`)。The default options.
源码Source io/agentscope/extensions/model/openai/compat/minimax/MiniMaxFormatter.java:40–48

applyToolChoice

public void applyToolChoice(OpenAIRequest request, ToolChoice toolChoice)

应用工具选项。

Performs the apply tool choice operation.

参数Parameters
名称Name类型Type说明Description
requestOpenAIRequest请求(类型 `OpenAIRequest`)。The request.
toolChoiceToolChoice工具选项(类型 `ToolChoice`)。The tool choice.
源码Source io/agentscope/extensions/model/openai/compat/minimax/MiniMaxFormatter.java:50–53

supportsStrict

protected boolean supportsStrict()

返回 supportsStrict 结果。

Returns the supports strict.

返回Returns boolean
返回布尔值,表示判断结果。Returns a boolean result.
源码Source io/agentscope/extensions/model/openai/compat/minimax/MiniMaxFormatter.java:55–58

继承成员Inherited Members

基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.