Better overrideShowThoughts value

This commit is contained in:
bmen25124
2025-03-21 22:19:13 +03:00
parent 17e0058763
commit 7df6a78f33

View File

@ -2269,9 +2269,9 @@ async function sendOpenAIRequest(type, messages, signal) {
* @param {boolean?} [options.overrideShowThoughts] Override show thoughts * @param {boolean?} [options.overrideShowThoughts] Override show thoughts
* @returns {string} The reply extracted from the response data * @returns {string} The reply extracted from the response data
*/ */
export function getStreamingReply(data, state, { chatCompletionSource = null, overrideShowThoughts } = {}) { export function getStreamingReply(data, state, { chatCompletionSource = null, overrideShowThoughts = null } = {}) {
const chat_completion_source = chatCompletionSource ?? oai_settings.chat_completion_source; const chat_completion_source = chatCompletionSource ?? oai_settings.chat_completion_source;
const show_thoughts = overrideShowThoughts !== undefined ? overrideShowThoughts : oai_settings.show_thoughts; const show_thoughts = overrideShowThoughts !== null ? overrideShowThoughts : oai_settings.show_thoughts;
if (chat_completion_source === chat_completion_sources.CLAUDE) { if (chat_completion_source === chat_completion_sources.CLAUDE) {
if (show_thoughts) { if (show_thoughts) {