Start Sidecar Qwen VL from Recommend when the prompt enhancer is offline.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-08-27 22:56:29 -05:00
co-authored by Cursor
parent b2c59c3423
commit 91948dd329
3 changed files with 126 additions and 4 deletions
+5 -3
View File
@@ -1848,14 +1848,13 @@ const recommendDisabled = computed(() => {
if (recommendBusy.value) return true
if (!file.value || !prompt.value.trim()) return true
if (!imageSidecarConfigured.value) return true
if (!imageSidecarOk.value) return true
return false
})
const recommendHint = computed(() => {
if (!imageSidecarConfigured.value) return 'Sidecar Qwen VL is not configured. Set IMAGE_COMFY_HOST.'
if (!imageSidecarOk.value) return 'Sidecar Qwen VL is offline.'
if (!file.value) return 'Load a still first.'
if (!prompt.value.trim()) return 'Type a draft prompt to enhance.'
if (!imageSidecarOk.value) return 'Sidecar is offline. Recommend will start Qwen VL on 192.168.77.101.'
if (imageSidecarBusy.value) return 'Sidecar is busy — this may wait in its queue.'
return 'Send this still and draft to Sidecar Qwen VL.'
})
@@ -2507,7 +2506,9 @@ async function recommendPrompt() {
recommendError.value = ''
recommendText.value = ''
recommendApplied.value = false
recommendMessage.value = 'Uploading still to Sidecar Qwen VL…'
recommendMessage.value = imageSidecarOk.value
? 'Uploading still to Sidecar Qwen VL…'
: 'Sidecar is offline. Starting Qwen VL…'
const body = new FormData()
body.append('image', file.value)
body.append('prompt', prompt.value)
@@ -2542,6 +2543,7 @@ async function recommendPrompt() {
} finally {
recommendBusy.value = false
if (recommendJobId.value) recommendJobId.value = ''
void pollComfyHealth()
}
}