Qwen-Math models provide mathematical reasoning with detailed, verifiable step-by-step solutions.
This document applies only to the China (Beijing) region. To use the model, you must use an API key from the China (Beijing) region.
Models and pricing
Commercial Models
Model name | Input price | Output price | Context window | Max input | Max output | Free quota |
|---|---|---|---|---|---|---|
(per million tokens) | (tokens) | |||||
qwen-math-plus | $0.574 | $1.721 | 4,096 | 3,072 | 3,072 | No free quota is available. |
qwen-math-turbo | $0.287 | $0.861 | ||||
Quick start
Obtain an API key and export the API key as an environment variable. If you use the OpenAI SDK or DashScope SDK to make calls, install the SDK.
- OpenAI compatible
- DashScope
Python
Try the model in the Model Studio console.
Recommendations
- Use English and LaTeX: Qwen-Math handles mathematical problems in English. Use LaTeX for symbols and formulas in your input.
- Control content output: Partial mode ensures the model output closely follows a given prefix, improving accuracy.
- The
temperatureparameter defaults to0. Do not change this setting. - Easily extract results: Qwen-Math outputs the final result in a
\boxed{}block by default.
Frequently asked questions
How do I solve math problems in images with Qwen-Math? |
Qwen-Math does not support image recognition. Qwen-Math input and output parameters are documented in the Qwen API Reference. |
Where can I find error code details? |
If the model call fails and returns an error message, see Error codes for resolution. |