Add pydocstyle to the ruff rules (#52136)
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com> Signed-off-by: Harry Mellor <hej.mellor@gmail.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
804e5377aa
commit
8c1557a79c
@@ -866,7 +866,6 @@ class EngineArgs:
|
||||
@staticmethod
|
||||
def add_cli_args(parser: FlexibleArgumentParser) -> FlexibleArgumentParser:
|
||||
"""Shared CLI arguments for vLLM engine."""
|
||||
|
||||
# Model arguments
|
||||
model_kwargs = get_kwargs(ModelConfig)
|
||||
model_group = parser.add_argument_group(
|
||||
@@ -2042,8 +2041,7 @@ class EngineArgs:
|
||||
usage_context: UsageContext | None = None,
|
||||
headless: bool = False,
|
||||
) -> VllmConfig:
|
||||
"""
|
||||
Create the VllmConfig.
|
||||
"""Create the VllmConfig.
|
||||
|
||||
NOTE: If VllmConfig is incompatible, we raise an error.
|
||||
"""
|
||||
|
||||
+16
-13
@@ -39,7 +39,7 @@ class StreamingInput:
|
||||
|
||||
|
||||
class EngineClient(ABC):
|
||||
"""Protocol class for Clients to Engine"""
|
||||
"""Protocol class for Clients to Engine."""
|
||||
|
||||
vllm_config: VllmConfig
|
||||
model_config: ModelConfig
|
||||
@@ -77,6 +77,7 @@ class EngineClient(ABC):
|
||||
|
||||
Raises:
|
||||
GracefulHTTPError: If the request cannot be admitted.
|
||||
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
@@ -124,6 +125,7 @@ class EngineClient(ABC):
|
||||
Args:
|
||||
request_id: The unique id of the request,
|
||||
or an iterable of such ids.
|
||||
|
||||
"""
|
||||
...
|
||||
|
||||
@@ -149,49 +151,49 @@ class EngineClient(ABC):
|
||||
|
||||
@abstractmethod
|
||||
async def check_health(self) -> None:
|
||||
"""Raise if unhealthy"""
|
||||
"""Raise if unhealthy."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def start_profile(self) -> None:
|
||||
"""Start profiling the engine"""
|
||||
"""Start profiling the engine."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def stop_profile(self) -> None:
|
||||
"""Stop profiling the engine"""
|
||||
"""Stop profiling the engine."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def reset_mm_cache(self) -> None:
|
||||
"""Reset the multi-modal cache"""
|
||||
"""Reset the multi-modal cache."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def reset_encoder_cache(self) -> None:
|
||||
"""Reset the encoder cache"""
|
||||
"""Reset the encoder cache."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def reset_prefix_cache(
|
||||
self, reset_running_requests: bool = False, reset_connector: bool = False
|
||||
) -> bool:
|
||||
"""Reset the prefix cache and optionally any configured connector cache"""
|
||||
"""Reset the prefix cache and optionally any configured connector cache."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def sleep(self, level: int = 1, mode: "PauseMode" = "abort") -> None:
|
||||
"""Sleep the engine"""
|
||||
"""Sleep the engine."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def wake_up(self, tags: list[str] | None = None) -> None:
|
||||
"""Wake up the engine"""
|
||||
"""Wake up the engine."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def is_sleeping(self) -> bool:
|
||||
"""Check whether the engine is sleeping"""
|
||||
"""Check whether the engine is sleeping."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
@@ -219,6 +221,7 @@ class EngineClient(ABC):
|
||||
wait_for_inflight_requests: DEPRECATED. Use ``mode="wait"`` instead.
|
||||
clear_cache: DEPRECATED. Whether to clear KV and prefix caches
|
||||
after draining.
|
||||
|
||||
"""
|
||||
...
|
||||
|
||||
@@ -240,7 +243,7 @@ class EngineClient(ABC):
|
||||
async def scale_elastic_ep(
|
||||
self, new_data_parallel_size: int, drain_timeout: int = 300
|
||||
) -> None:
|
||||
"""Scale the engine"""
|
||||
"""Scale the engine."""
|
||||
raise NotImplementedError
|
||||
|
||||
async def collective_rpc(
|
||||
@@ -256,7 +259,7 @@ class EngineClient(ABC):
|
||||
async def handle_fault(
|
||||
self, fault_tolerance_request: FaultToleranceRequest
|
||||
) -> FaultToleranceResult:
|
||||
"""send fault tolerance instruction to the engine"""
|
||||
"""Send fault tolerance instruction to the engine."""
|
||||
raise NotImplementedError
|
||||
|
||||
async def get_status(self):
|
||||
@@ -264,7 +267,7 @@ class EngineClient(ABC):
|
||||
raise NotImplementedError
|
||||
|
||||
async def get_supported_tasks(self) -> tuple[SupportedTask, ...]:
|
||||
"""Get supported tasks"""
|
||||
"""Get supported tasks."""
|
||||
raise NotImplementedError
|
||||
|
||||
async def init_weight_transfer_engine(
|
||||
|
||||
Reference in New Issue
Block a user