- Notifications
You must be signed in to change notification settings - Fork 476
Open
Description
感谢作者为推理模型添加了思维链展示功能!🙏 当前实现中,思维链字段名称存在不一致,导致部分 API 的兼容性问题。例如:
grok-3-mini-fast-beta使用reasoning_content字段。deepseek/deepseek-r1:free(OpenRouter)使用reasoning字段。
希望能统一或适配不同 API 的思维链字段名称,以提高兼容性和一致性。
重现步骤:
- 调用
grok-3-mini-fast-beta模型的 API,响应中思维链字段为reasoning_content。 - 调用
deepseek/deepseek-r1:free模型的 API,响应中思维链字段为reasoning。 - 当前代码可能无法统一解析这两种字段,导致部分模型思维链无法正常展示。
示例代码:
grok-3-mini-fast-beta响应:
{ "id": "74389f1a-e05a-4bf8-b96e-d83e184c2446", "object": "chat.completion.chunk", "created": 1746608576, "model": "grok-3-mini-fast-beta", "choices": [ { "delta": { "reasoning_content": " is", "role": "assistant" }, "logprobs": null, "finish_reason": null, "index": 0 } ] }deepseek/deepseek-r1:free响应:
{ "id": "gen-1746608852-xIwuByvuBWfWfjCmiVvp", "provider": "Targon", "model": "deepseek/deepseek-r1:free", "object": "chat.completion.chunk", "choices": [ { "index": 0, "delta": { "role": "assistant", "content": "", "reasoning": "得到" }, "finish_reason": null } ] }Metadata
Metadata
Assignees
Labels
No labels