mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 21:37:11 +00:00
fix: content和reasoning_content是同时出现的
This commit is contained in:
parent
6442e371ee
commit
65bb1539e2
2 changed files with 2 additions and 5 deletions
|
|
@ -304,9 +304,7 @@ var ChatGPTAPI = /** @class */ (function () {
|
|||
else if (message_1.tool_calls) {
|
||||
result.functionCall = message_1.tool_calls.map(function (tool) { return tool.function; })[0];
|
||||
}
|
||||
else if (message_1.reasoning_content) {
|
||||
result.thinking_text = message_1.reasoning_content;
|
||||
}
|
||||
result.thinking_text = message_1.reasoning_content;
|
||||
if (message_1.role) {
|
||||
result.role = message_1.role;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -316,9 +316,8 @@ export class ChatGPTAPI {
|
|||
result.functionCall = message.function_call
|
||||
} else if (message.tool_calls) {
|
||||
result.functionCall = message.tool_calls.map(tool => tool.function)[0]
|
||||
} else if (message.reasoning_content) {
|
||||
result.thinking_text = message.reasoning_content
|
||||
}
|
||||
result.thinking_text = message.reasoning_content
|
||||
if (message.role) {
|
||||
result.role = message.role
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue