[Feat] Support thinking_token_budget in Model Runner V2 (#46727)
Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com> Signed-off-by: Nick Hill <nickhill123@gmail.com> Co-authored-by: Nick Hill <nickhill123@gmail.com>
This commit is contained in:
@@ -108,22 +108,15 @@ class InputProcessor:
|
||||
self.tokenizer,
|
||||
)
|
||||
|
||||
if params.thinking_token_budget is not None:
|
||||
if (
|
||||
self.vllm_config.reasoning_config is None
|
||||
or not self.vllm_config.reasoning_config.enabled
|
||||
):
|
||||
raise VLLMValidationError(
|
||||
"thinking_token_budget is set but reasoning_config is "
|
||||
"not configured. Please set --reasoning-parser "
|
||||
"and/or --reasoning-config to use thinking_token_budget."
|
||||
)
|
||||
if self.use_v2_model_runner:
|
||||
raise VLLMValidationError(
|
||||
"thinking_token_budget is not yet supported by the V2 "
|
||||
"model runner. Run vLLM with VLLM_USE_V2_MODEL_RUNNER=0 "
|
||||
"to use thinking_token_budget."
|
||||
)
|
||||
if params.thinking_token_budget is not None and (
|
||||
self.vllm_config.reasoning_config is None
|
||||
or not self.vllm_config.reasoning_config.enabled
|
||||
):
|
||||
raise VLLMValidationError(
|
||||
"thinking_token_budget is set but reasoning_config is "
|
||||
"not configured. Please set --reasoning-parser "
|
||||
"and/or --reasoning-config to use thinking_token_budget."
|
||||
)
|
||||
elif isinstance(params, PoolingParams):
|
||||
supported_pooling_tasks = [
|
||||
task for task in supported_tasks if task in POOLING_TASKS
|
||||
|
||||
Reference in New Issue
Block a user