This topic describes the input and output parameters for calling the GUI-Plus model through the OpenAI-compatible interface or the DashScope API.
References: GUI-Plus: A dedicated model for interface interaction
OpenAI compatibility
For SDK calls, set the base_url to: https://{WorkspaceId}.cn-beijing.maas.aliyuncs.com/compatible-mode/v1
For HTTP calls, set the endpoint to: POST https://{WorkspaceId}.cn-beijing.maas.aliyuncs.com/compatible-mode/v1/chat/completions
Before you begin, obtain an API key and configure the API key as an environment variable (This step is being deprecated and will be merged into configuring the API key). If you call the model using the OpenAI SDK, you must install the SDK.
Request bodymodelstring(Required)The model name. Supported model: gui-plus.messagesarray(Required)The context to pass to the Large Language Model (LLM), arranged in conversational order.
Message types System Message object(Optional)A system message that sets the role, tone, task objectives, or constraints for the LLM. It is usually placed first in the messages array.
Properties content string(Required)System instructions that define the model's role, behavior, response style, and task constraints.rolestring(Required)The role of the system message. The value is fixed to system.object(Required)A user message.
Properties content array(Required)The message content.
Properties type string(Required)Valid values:
string(Optional)The input text. This parameter is required when type is set to text.image_urlobjectThe input image information. This parameter is required when type is set to image_url.
Properties url string(Required)The URL or Base64 Data URL of the image. To pass a local file, see Pass a local file.integer(Optional)Sets the minimum pixel threshold for the input image. The unit is pixels.If the input image has fewer pixels than min_pixels, the image is enlarged until its total pixel count exceeds min_pixels.The default and minimum value is 3136.max_pixelsinteger(Optional)Sets the maximum pixel threshold for the input image. The unit is pixels.If the pixel count of the input image is within the [min_pixels, max_pixels] range, the model processes the original image. If the pixel count exceeds max_pixels, the image is downscaled until its total pixel count is below max_pixels.The default and maximum values depend on the value of vl_high_resolution_images:
string(Required)The role of the user message. The value is fixed to user.object(Optional)The model's response. This is typically passed back to the model as context in a multi-turn conversation.
Properties content string(Required)The text content of the model's response.rolestring(Required)The role of the assistant message. The value is fixed to assistant.boolean(Optional) Default: falseSpecifies whether to return the response in a streaming manner.Valid values:
object(Optional)Configuration items for streaming output. This parameter takes effect only when stream is set to true.
Properties include_usage boolean(Optional) Default: falseSpecifies whether to include token usage information in the last data block.Valid values:
integer(Optional)Limits the maximum number of tokens in the model's output. If the generated content exceeds this value, the response is truncated.The default and maximum values are the model's maximum output length. For more information, see Scope of application.vl_high_resolution_imagesboolean(Optional) Default: falseSpecifies whether to increase the maximum pixel count of the input image to the value corresponding to 16384 tokens.
boolean (Optional)When using a hybrid thinking model (which can think before replying), specifies whether to enable the thinking mode. Among the interface interaction series models, only gui-plus-2026-02-26 is a hybrid thinking model. For more information, see Visual reasoning.Valid values:
This is not a standard OpenAI parameter. When calling with the Python SDK, place it in the extra_body object. The configuration is: seedinteger(Optional)A random number seed. This ensures that results are reproducible with the same input and parameters. If you make a call with the same seed and other parameters unchanged, the model returns the same result as much as possible.Value range: [0,2<sup>31</sup>−1].temperaturefloat(Optional)Default: 0.01The sampling temperature, which controls the diversity of the text generated by the model.A higher temperature results in more diverse text. A lower temperature results in more deterministic text.Value range: [0, 2)Both temperature and top_p control the diversity of the generated text. We recommend setting only one of them.top_pfloat(Optional) Default: 0.01The probability threshold for nucleus sampling, which controls the diversity of the text generated by the model.A higher top_p results in more diverse text. A lower top_p results in more deterministic text.Value range: (0,1.0]Both temperature and top_p control the diversity of the generated text. We recommend setting only one of them.top_kinteger(Optional) Default: 1The size of the candidate set for sampling during generation. For example, a value of 50 means that only the 50 tokens with the highest scores in a single generation are used to form the random sampling candidate set. A larger value increases randomness. A smaller value increases determinism. A value of None or a value greater than 100 indicates that the top_k policy is not enabled, and only the top_p policy takes effect.The value must be greater than or equal to 0.This is not a standard OpenAI parameter. When calling with the Python SDK, place it in the extra_body object. The configuration is: extra_body={"top_k": xxx}. When calling with the Node.js SDK or by HTTP, pass it as a top-level parameter.repetition_penaltyfloat(Optional) Default: 1.0The degree of repetition in consecutive sequences during model generation. Increasing repetition_penalty reduces repetition. A value of 1.0 means no penalty. This parameter has a significant impact on the model's performance. We recommend keeping the default value.presence_penalty float(Optional)Controls content repetition when the model generates text. The default value is 1.5.Value range: [-2.0, 2.0]. Positive values reduce repetition. Negative values increase repetition.In scenarios that require diversity, interest, or creativity, such as creative writing or brainstorming, increase this value. In scenarios that emphasize consistency and terminological accuracy, such as technical documents or formal texts, decrease this value.
How it works If the parameter value is positive, the model applies a penalty to tokens that already exist in the current text (the penalty is independent of the number of occurrences). This reduces the chance of these tokens reappearing, thereby reducing content repetition and increasing word diversity.
Example Prompt: Translate this sentence into Chinese: “This movie is good. The plot is good, the acting is good, the music is good, and overall, the whole movie is just good. It is really good, in fact. The plot is so good, and the acting is so good, and the music is so good.”Parameter value is 2.0: This movie is great. The plot is fantastic, the acting is superb, and the music is beautiful. Overall, the entire film is simply outstanding. It is truly excellent, in fact. The story is very compelling, the performances are brilliant, and the score is so moving.Parameter value is 0.0: This movie is good. The plot is good, the acting is good, and the music is good. Overall, the whole movie is good. In fact, it is really great. The plot is very good, the acting is very good, and the music is also excellent.Parameter value is -2.0: This movie is good. The plot is good, the acting is good, and the music is good. Overall, the whole movie is good. In fact, it is really good. The plot is very good, the acting is very good, and the music is very good. string or array(Optional)Specifies stop words. When a string or token_id specified in stop appears in the generated text, generation stops immediately.You can pass sensitive words to control the model's output.When stop is an array, you cannot mix |
|
Chat response object (non-streaming output)idstringThe unique ID of this request.choicesarrayAn array of content generated by the model.
Properties finish_reason stringThe reason the model stopped generating.There are two cases:
integerThe index of the current object in the choices array.messageobjectThe message output by the model.
Properties content stringThe result of the GUI task.refusal stringThis parameter is currently fixed to null.role stringThe role of the message. The value is fixed to assistant.audio objectThis parameter is currently fixed to null.function_call objectThis parameter is currently fixed to null.tool_calls arrayThis parameter is currently fixed to null.integerThe UNIX timestamp when this request was created.modelstringThe model used for this request.object stringAlways chat.completion.service_tier stringThis parameter is currently fixed to null.system_fingerprintstringThis parameter is currently fixed to null.usage objectToken usage information for this request.
Properties completion_tokens integerThe number of tokens in the model's output.prompt_tokens integerThe number of tokens in the input.total_tokens integerThe total number of tokens used, which is the sum of prompt_tokens and completion_tokens.completion_tokens_details objectA fine-grained categorization of the model's output tokens.
Properties accepted_prediction_tokens integerThis parameter is currently fixed to null.audio_tokens integerThis parameter is currently fixed to null.reasoning_tokens integerThis parameter is currently fixed to null.text_tokens integerThe number of tokens corresponding to the model's output text.rejected_prediction_tokensintegerThis parameter is currently fixed to null.objectA fine-grained categorization of the input tokens.
Properties audio_tokens integerThis parameter is currently fixed to null.cached_tokens integerThis parameter is currently fixed to null.text_tokens integerThe number of tokens corresponding to the model's input text.image_tokens integerThe number of tokens corresponding to the model's input image. |
Chat response chunk object (streaming output)idstringThe unique ID of this call. Each chunk object has the same ID.choicesarrayAn array of content generated by the model. If the include_usage parameter is set to true, this is empty in the last chunk.
Properties delta objectThe output content returned in the stream.
Properties content stringqwen-mt-flash provides incremental updates for translation results, while qwen-mt-plus provides non-incremental updates.function_call objectThis parameter is currently fixed to null.refusal objectThis parameter is currently fixed to null.role stringThe role of the message object. This has a value only in the first chunk.stringThe reason the model stopped generating. There are three cases:
integerThe index of the current response in the choices array.integerThe UNIX timestamp when this request was created. Each chunk has the same timestamp.modelstringThe model used for this request.object stringAlways chat.completion.chunk.service_tier stringThis parameter is currently fixed to null.system_fingerprintstringThis parameter is currently fixed to null.usage objectThe tokens used by this request. This is returned only in the last chunk when include_usage is true.
Properties completion_tokens integerThe number of tokens in the model's output.prompt_tokens integerThe number of tokens in the input.total_tokens integerThe total number of tokens used, which is the sum of prompt_tokens and completion_tokens.completion_tokens_details objectA fine-grained categorization of the model's output tokens.
Properties accepted_prediction_tokens integerThis parameter is currently fixed to null.audio_tokens integerThis parameter is currently fixed to null.reasoning_tokens integerThis parameter is currently fixed to null.text_tokens integerThe number of tokens corresponding to the model's output text.rejected_prediction_tokensintegerThis parameter is currently fixed to null.objectA fine-grained categorization of the input tokens.
Properties audio_tokens integerThis parameter is currently fixed to null.cached_tokens integerThis parameter is currently fixed to null.text_tokens integerThe number of tokens corresponding to the model's input text.image_tokens integerThe number of tokens corresponding to the model's input image. |
DashScope
- HTTP request address:
POST https://{WorkspaceId}.cn-beijing.maas.aliyuncs.com/api/v1/services/aigc/multimodal-generation/generation - SDK call: Set
base_urltohttps://{WorkspaceId}.cn-beijing.maas.aliyuncs.com/api/v1.
Before you begin, obtain an API key and configure the API key as an environment variable (This step is being deprecated and will be merged into configuring the API key). If you call the model using the DashScope SDK, you must install the DashScope SDK.
Request bodymodelstring(Required)The model name. Supported model: gui-plus.messagesarray(Required)The context to pass to the LLM, arranged in conversational order.When making an HTTP call, place messages in the input object.
Message types System Message object(Optional)A system message that sets the role, tone, task objectives, or constraints for the LLM. It is usually placed first in the messages array.
Properties content string(Required)System instructions that define the model's role, behavior, response style, and task constraints.rolestring(Required)The role of the system message. The value is fixed to system.object(Required)A user message used to pass questions, instructions, or context to the model.
Properties content string or array(Required)The message content. This is a string if the input is text-only. It is an array if the input includes image data.
Properties text string(Required)The input text.imagestring(Optional)The image file to pass. This can be the URL of the image or a local path. To pass a local file, see Pass a local file.Example: {"image":"https://xxxx.jpeg","max-pixels":12802828}min_pixelsinteger(Optional)Sets the minimum pixel threshold for the input image. The unit is pixels.If the input image has fewer pixels than min_pixels, the image is enlarged until its total pixel count exceeds min_pixels.The default and minimum value is 3136.Use with the image parameter. Example: {"image":"https://xxxx.jpeg","min_pixels":3136}max_pixelsinteger(Optional)Sets the maximum pixel threshold for the input image. The unit is pixels.If the pixel count of the input image is within the [min_pixels, max_pixels] range, the model processes the original image. If the pixel count exceeds max_pixels, the image is downscaled until its total pixel count is below max_pixels.The default and maximum values depend on the value of vl_high_resolution_images:
object(Optional)The model's response. This is typically passed back to the model as context in a multi-turn conversation.
Properties content string(Required)The text content of the model's response.rolestring(Required)The role of the assistant message. The value is fixed to assistant.boolean(Optional) Default: falseSpecifies whether to increase the maximum pixel count of the input image to the value corresponding to 16384 tokens.
boolean (Optional)When using a hybrid thinking model, specifies whether to enable the thinking mode. Among the interface interaction series models, only gui-plus-2026-02-26 is a hybrid thinking model. For more information, see Visual reasoning.Valid values:
The Java SDK uses enableThinking. When making an HTTP call, place enable_thinking in the parameters object.max_tokens integer(Optional)Maximum number of tokens to generate. If the output exceeds this value, the response is truncated.The default and maximum values are the maximum output length of the model. For more information, see Model selection.In the Java SDK, the parameter is maxTokens. When you call via HTTP, place max_tokens in the parameters object.seed integer(Optional)Random number seed for reproducible results. Using the same seed and parameters produces consistent output.Value range: [0, 2 31 -1].When making an HTTP call, place seed in the parameters object.temperature float(Optional)Default: 0.01The sampling temperature, which controls the diversity of the text generated by the model.A higher temperature results in more diverse text. A lower temperature results in more deterministic text.Value range: [0, 2)Both temperature and top_p control the diversity of the generated text. We recommend setting only one of them.When making an HTTP call, place temperature in the parameters object.top_p float(Optional) Default: 0.01The probability threshold for nucleus sampling, which controls the diversity of the text generated by the model.A higher top_p results in more diverse text. A lower top_p results in more deterministic text.Value range: (0,1.0]Both temperature and top_p control the diversity of the generated text. We recommend setting only one of them.In the Java SDK, the parameter is named topP. When you make HTTP calls, include top_p in the parameters object.repetition_penalty float(Optional) Default: 1.0The degree of repetition in consecutive sequences during model generation. Increasing repetition_penalty reduces repetition. A value of 1.0 means no penalty. This parameter has a significant impact on the model's performance. We recommend keeping the default value.In the Java SDK, this parameter is named repetitionPenalty. When you make an HTTP call, place repetition_penalty in the parameters object.presence_penalty float(Optional)Controls content repetition when the model generates text. The default value is 1.5.Value range: [-2.0, 2.0]. Positive values reduce repetition. Negative values increase repetition.In scenarios that require diversity, interest, or creativity, such as creative writing or brainstorming, increase this value. In scenarios that emphasize consistency and terminological accuracy, such as technical documents or formal texts, decrease this value.
How it works If the parameter value is positive, the model applies a penalty to tokens that already exist in the current text (the penalty is independent of the number of occurrences). This reduces the chance of these tokens reappearing, thereby reducing content repetition and increasing word diversity.
Example Prompt: Translate this sentence into Chinese: “This movie is good. The plot is good, the acting is good, the music is good, and overall, the whole movie is just good. It is really good, in fact. The plot is so good, and the acting is so good, and the music is so good.”Parameter value is 2.0: This movie is great. The plot is fantastic, the acting is superb, and the music is beautiful. Overall, the entire film is simply outstanding. It is truly excellent, in fact. The story is very compelling, the performances are brilliant, and the score is so moving.Parameter value is 0.0: This movie is good. The plot is good, the acting is good, and the music is good. Overall, the whole movie is good. In fact, it is really great. The plot is very good, the acting is very good, and the music is also excellent.Parameter value is -2.0: This movie is good. The plot is good, the acting is good, and the music is good. Overall, the whole movie is good. In fact, it is really good. The plot is very good, the acting is very good, and the music is very good. integer(Optional) Default: 1The size of the candidate set for sampling during generation. For example, a value of 50 means that only the 50 tokens with the highest scores in a single generation are used to form the random sampling candidate set. A larger value increases randomness. A smaller value increases determinism. A value of None or a value greater than 100 indicates that the top_k policy is not enabled, and only the top_p policy takes effect.The value must be greater than or equal to 0.This is not a standard OpenAI parameter. When calling with the Python SDK, place it in the extra_body object. The configuration is: extra_body={"top_k": xxx}. When calling with the Node.js SDK or by HTTP, pass it as a top-level parameter.The Java SDK uses topKtop_k in the parameters object.repetition_penalty float(Optional) Default: 1.0The degree of repetition in consecutive sequences during model generation. Increasing repetition_penalty reduces repetition. A value of 1.0 means no penalty. This parameter has a significant impact on the model's performance. We recommend keeping the default value.streamboolean(Optional)Specifies whether to return the response in a streaming manner.Valid values:
This parameter is supported only by the Python SDK. To implement streaming output with the Java SDK, use theincremental_output boolean(Optional) Default: falseSpecifies whether to enable incremental output in streaming mode. We recommend that you set this to true.Parameter values:
In the Java SDK, this parameter is called incrementalOutput. When making HTTP calls, include incremental_output in the parameters object.stop string or array(Optional)Specifies stop words. When a string or token_id specified in stop appears in the generated text, generation stops immediately.You can pass sensitive words to control the model's output.When stop is an array, you cannot mix |
Python |
Chat response object (same format for streaming and non-streaming output)status_codestringThe status code of this request. A value of 200 indicates that the request was successful. Otherwise, the request failed.The Java SDK does not return this parameter. If the call fails, an exception is thrown. The exception message contains the content of status_code and message.request_id stringThe unique ID of this call.The Java SDK returns this parameter as requestIdcode stringThe error code. This is empty if the call is successful.Only the Python SDK returns this parameter.output objectInformation about the call result.
Properties text stringThis parameter is currently fixed to null.finish_reasonstringThe reason the model stopped generating. The possible cases are:
arrayThe model's output information.
Properties finish_reason stringThe possible cases are:
objectThe message object output by the model.
Properties role stringThe role of the output message. The value is fixed to assistant.contentstringThe model's output resultstringThis parameter is currently fixed to null.objectToken information used by this request.
Properties input_tokens integerThe number of input tokens.output_tokens integerThe number of output tokens.image_tokens integerThis field is returned when the input content includes an image. It is the length of the user's input image content after being converted to tokens.characters integerThis parameter is currently fixed to null.input_tokens_detailsobjectA fine-grained categorization of the input tokens.
Properties image_tokens integerThe number of tokens corresponding to the model's input image.text_tokens integerThe number of tokens corresponding to the model's input text.objectA fine-grained categorization of the output tokens.
Properties text_tokens integerThe number of tokens corresponding to the model's input text.integerThe total number of tokens used, which is the sum of input_tokens and output_tokens. |