[V0 Deprecation] Remove V0 model runner base & simplify worker base (#25328)

Signed-off-by: Woosuk Kwon <woosuk.kwon@berkeley.edu>
This commit is contained in:
Woosuk Kwon
2025-09-20 20:49:09 -07:00
committed by GitHub
parent 62b38dc832
commit 1cd885bd54
4 changed files with 11 additions and 706 deletions
+2 -6
View File
@@ -5,8 +5,7 @@ from collections import defaultdict
from contextlib import contextmanager
from dataclasses import dataclass
from itertools import accumulate
from typing import (TYPE_CHECKING, Any, Dict, List, Optional, Tuple, Type,
TypeVar, Union)
from typing import Any, Dict, List, Optional, Tuple, Type, TypeVar, Union
import numpy as np
import torch
@@ -21,9 +20,6 @@ from vllm.utils import async_tensor_h2d, make_tensor_with_pad
logger = init_logger(__name__)
if TYPE_CHECKING:
from vllm.worker.model_runner_base import ModelRunnerBase
# Error string(s) for encoder/decoder
# unsupported attention scenarios
STR_NOT_IMPL_ENC_DEC_ROCM_HIP = ("ROCm/HIP is not currently supported "
@@ -286,7 +282,7 @@ class CommonMetadataBuilder(AttentionMetadataBuilder[TAttentionMetadata]):
class CommonAttentionState(AttentionState):
def __init__(self, runner: "ModelRunnerBase"):
def __init__(self, runner):
self.runner = runner
self._is_graph_capturing = False