[Bugfix][Frontend] Reject beam search with echo and logprobs in /v1/completions (#60876)
Signed-off-by: surawut.j <surawut.jirasaktavee@gmail.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
5dc9bcd8cd
commit
c811943137
@@ -492,6 +492,17 @@ class CompletionRequest(OpenAIBaseModel):
|
||||
parameter="logprob_token_ids",
|
||||
)
|
||||
|
||||
if (
|
||||
data.get("use_beam_search")
|
||||
and data.get("echo")
|
||||
and data.get("logprobs") is not None
|
||||
):
|
||||
raise VLLMValidationError(
|
||||
"`echo` with `logprobs` is not supported with beam search "
|
||||
"because beam search does not compute prompt logprobs.",
|
||||
parameter="echo",
|
||||
)
|
||||
|
||||
if (
|
||||
data.get("logprob_token_ids")
|
||||
and data.get("echo")
|
||||
|
||||
Reference in New Issue
Block a user