[Bugfix][Frontend] validate arg priority in frontend LLM class before add request (#27596)
Signed-off-by: Junpu Fan <junpufan@gmail.com>
This commit is contained in:
@@ -1565,6 +1565,12 @@ class LLM:
|
||||
raise ValueError(
|
||||
"The lengths of prompts and lora_request must be the same."
|
||||
)
|
||||
if priority is not None and len(priority) != num_requests:
|
||||
raise ValueError(
|
||||
"The lengths of prompts "
|
||||
f"({num_requests}) and priority ({len(priority)}) "
|
||||
"must be the same."
|
||||
)
|
||||
|
||||
for sp in params if isinstance(params, Sequence) else (params,):
|
||||
if isinstance(sp, SamplingParams):
|
||||
|
||||
Reference in New Issue
Block a user