Skip to content

DeepSeek v4 系列模型在调用工具轮次中未正确回传reasoning_content 导致报错 #2999

@GD-Slime

Description

@GD-Slime

Is it a request payload issue?

  • Yes, this is a request payload issue. I am using a client/cURL to send a request payload, but I received an unexpected error.
  • No, it's another issue.

If it's a request payload issue, you MUST know
Our team doesn't have any GODs or ORACLEs or MIND READERs. Please make sure to attach the request log or curl payload.

Describe the bug
使用 OpenAI 兼容格式提供商接入DeepSeek官方API.

然而, DeepSeek v4 系列模型要求必须在调用工具的轮次后回传reasoning_content, 否则会400报错. 当前CPA版本未实现这一功能.
https://api-docs.deepseek.com/zh-cn/guides/thinking_mode

CLI Type
Codex CLI

Model Name
DeepSeek v4 Series

LLM Client
Codex CLI

Request Information
{"error":{"message":"The reasoning_content in the thinking mode must be passed back to the API.","type":"invalid_request_error","param":null,"code":"invalid_request_error"}}

Expected behavior
正常调用工具

Screenshots
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions