Features
The Deep Thinking feature currently supports the latest models in the GLM-5.2 GLM-5.1 GLM-5 GLM-5-Turbo GLM-5V-Turbo GLM-4.5 GLM-4.6 GLM-4.7 series. By enabling deep thinking, the model can:- Multi-step Reasoning: Break down complex problems into multiple steps for gradual analysis and resolution
- Logical Analysis: Provide clear reasoning processes and logical chains
- Improved Accuracy: Reduce errors and improve answer quality through deep thinking
- Enhanced Interpretability: Display the thinking process to help users understand the model’s reasoning logic
- Intelligent Judgment: The model automatically determines whether deep thinking is needed to optimize response efficiency
Core Parameters
thinking.type: Controls the deep thinking modeenabled(default): Enable dynamic thinking. The model automatically determines whether to think:GLM-5.2,GLM-5.1,GLM-5,GLM-5-Turbo,GLM-5V-Turbo,GLM-4.6, andGLM-4.5auto-decide whether to think, whileGLM-4.7andGLM-4.5Vuse forced thinkingdisabled: Disable deep thinking, provide direct answers
reasoning_effort: Controls the reasoning effort level when chain-of-thought thinking is enabled, only supported byGLM-5.2and above- Allowed values:
max(default and recommended, deep reasoning),xhigh,high(enhanced reasoning),medium,low,minimal,none noneorminimal: Model skips thinking;low/mediumare mapped tohigh;xhighis mapped tomax
- Allowed values:
model: Models that support deep thinking, such asglm-5.2,glm-5.1,glm-5,glm-4.7,glm-4.6,glm-4.5,glm-4.5v, etc.
Code Examples
- cURL
- Python SDK
Basic Call (Enable Deep Thinking)Streaming Call (Deep Thinking + Streaming Output)Control Reasoning Effort (reasoning_effort)Disable Deep Thinking
Response Example
Response format with deep thinking enabled:Best Practices
Recommended scenarios to enable:- Complex problem analysis and solving
- Multi-step reasoning tasks
- Technical solution design
- Strategy planning and decision
- Academic research and analysis
- Creative writing and content creation
- Simple fact query
- Basic translation tasks
- Simple classification judgment
- Quick question and answer requirements
Application scenarios
Academic Research
- Research method design
- Data analysis and explanation
- Theory deduction and proof
Technology Consulting
- System architecture design
- Technological scheme evaluation
- Problem diagnosis and solution
Business Analysis
- Market trends analysis
- Business model design
- Investment decision support
Education Training
- Complex concept explanation
- Learning path planning
- Knowledge system building
Notes
- Response time:Enable deep thinking will increase response time, particularly for complex tasks
- Token consumption:Thinking process will consume extra tokens, please manage your tokens
- Model support:Ensure you’re using models that support deep thinking
- Task matching:Choose whether to enable deep thinking according to the task complexity
- Streaming output:Combine streaming output to see the thinking process, improving user experience