Repository navigation
[PR] fix(openai): route tool-less audio (TTS) requests through the side passthrough - #6638
Conversation
…ssthrough A TTS call on /chat/completions carries a top-level audio object and no tools. It ran through the full pipeline, which injected the ACP system prompt as messages[0] plus an <acp> prefix on every message, and TTS models 400 on the leading system message. isAudioOutputCall now recognizes the shape and routes it through the ranxianglei#388 verbatim side passthrough, with a WC-025 ledger entry and tripwire in the fakes.
…eto (ranxianglei#6636 review) The tripwire flagged ANY audio-shaped body with a leading system message, but isAudioOutputCall vetoes tool-carrying requests (a main turn whose model has an action surface and accepts a leading system). A legitimate tool-carrying voice-chat main turn, decorated by bili, would have tripped the fake upstream. Add the same no-tools veto so the validator matches the predicate, and pin the boundary with a legal test row.
[bot] 🏷 (ai: vllm-qwen/qwen3.8-27b) Review of PR #6638 — duplicate screening: not a duplicate (no other open issue/PR covers the tool-less audio side-passthrough; this PR is the fix for #6636). Verdict: code is good to merge, pending the fresh CI run (details below). I verified the mechanism end-to-end, ran the touched suites locally, and made two branch updates (both non-destructive, additive):
CI state (live-verified): the original head Behavior change (flagged per policy): a tool-less request with a non-empty top-level (Apology note: an earlier copy of this review was misposted to the wrong mirror thread and has been withdrawn.) 八问(中文结构化结论)
收工判定:代码可合(等新 head |
|
Closes pair #6636 was auto-closed by the batch merge. Superseded by #6765 (merged to master as 78d128d). Your commit 6321ba0 is in master verbatim — same content, same authorship, only the object ID changed (the batch used a real Thanks for the fix — it is live in master from 78d128d onward. |
A TTS call on /chat/completions carries a top-level audio object and no tools. It ran through the full pipeline, which injected the ACP system prompt as messages[0] plus an prefix on every message. TTS models 400 on the leading system message, and the tags would be read aloud as text.
What changed: isAudioOutputCall recognizes a tool-less request with a non-empty top-level audio object and routes it through the #388 verbatim side passthrough, so the request leaves the machine exactly as the client wrote it. Same treatment as the #2500/#5073 utility shapes, including the output-budget high-water skip. A tool-carrying request with audio stays a main turn. Added WC-025 to the wire-contract ledger with a validator tripwire.
How verified: typecheck clean. 5 new tests in tests/issue6636-tts-side-request.test.ts (predicate positives/negatives, side-lane label, and an e2e test using the issue’s exact TTS body: forwarded byte-identical, no system, no tags, kernel untouched; plus a control proving a real tool-carrying turn still gets the ACP system prompt and tags). 153 tests green across the touched and neighboring side-lane suites.
Fixes #6636