fix: use selected model in webchat side threads (#10065)

This commit is contained in:
Soulter
2026-09-13 20:07:24 +08:00
committed by GitHub
parent 7ec39bdef0
commit 4007d645c9
2 changed files with 5 additions and 0 deletions
+1
View File
@@ -467,6 +467,7 @@
:thread="activeThread"
:is-dark="isDark"
:deleting="deletingThread"
:get-provider-selection="getSelectedProviderSelection"
@delete="deleteThread"
/>
<ReasoningSidebar
@@ -83,6 +83,7 @@ const props = defineProps<{
thread: ChatThread | null;
isDark: boolean;
deleting?: boolean;
getProviderSelection: () => { providerId: string; modelName: string };
}>();
const emit = defineEmits<{
@@ -155,6 +156,7 @@ async function send() {
const abort = new AbortController();
sending.value = true;
try {
const selection = props.getProviderSelection();
const response = await fetchWithAuth(
chatApi.sendThreadMessageUrl(props.thread.thread_id),
{
@@ -165,6 +167,8 @@ async function send() {
body: JSON.stringify({
message: [{ type: "plain", text }],
flags: buildChatRequestFlags(),
selected_provider: selection.providerId,
selected_model: selection.modelName,
}),
signal: abort.signal,
},