/chat/completions,模型始终开启思考,用顶层 reasoning_effort(low / high / max,默认 max)调节推理强度,响应里会带 reasoning_content。多轮对话或工具调用时,请把上一轮完整的 assistant 消息(含 reasoning_content 和 tool_calls)原样放回 messages;temperature 官方固定为 1.0,不用设置。官方文档:https://platform.kimi.com/docs/api/chat{
"model": "kimi-k3.1-pro",
"messages": [
{
"role": "user",
"content": "1+1 等于多少?"
}
],
"reasoning_effort": "low"
}curl --location --globoff 'https://接口地址/v1/chat/completions' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer sk-xxxx' \
--header 'Content-Type: application/json' \
--data '{
"model": "kimi-k3.1-pro",
"messages": [
{
"role": "user",
"content": "1+1 等于多少?"
}
],
"reasoning_effort": "low"
}'{
"id": "chatcmpl-6adb0d416a4a9c1d0fe639e3",
"object": "chat.completion",
"created": 1792740676,
"model": "kimi-k3.1-pro",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "1 + 1 = 2",
"reasoning_content": "The user is asking a simple math question in Chinese: \"1+1 等于多少?\" (What is 1+1?)\n\nThis is a trivial arithmetic question. The answer is 2. I should respond in Chinese since the conversation is in Chinese. Keep it simple and direct."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 309,
"completion_tokens": 82,
"total_tokens": 391,
"completion_tokens_details": {
"reasoning_tokens": 60
},
"prompt_tokens_details": {
"cache_write_tokens": 256
}
}
}