Fix typing in AsyncLLMEngine & add toml to requirements-dev (#2100)
This commit is contained in:
parent
31c1f3255e
commit
6774bd50b0
@ -1,5 +1,6 @@
|
|||||||
# formatting
|
# formatting
|
||||||
yapf==0.32.0
|
yapf==0.32.0
|
||||||
|
toml==0.10.2
|
||||||
ruff==0.1.5
|
ruff==0.1.5
|
||||||
|
|
||||||
# type checking
|
# type checking
|
||||||
|
@ -2,7 +2,7 @@ import asyncio
|
|||||||
import time
|
import time
|
||||||
from functools import partial
|
from functools import partial
|
||||||
from typing import (Any, Dict, Iterable, List, Optional, Set, Tuple, Type,
|
from typing import (Any, Dict, Iterable, List, Optional, Set, Tuple, Type,
|
||||||
Union)
|
Union, AsyncIterator)
|
||||||
|
|
||||||
from vllm.config import ModelConfig
|
from vllm.config import ModelConfig
|
||||||
from vllm.engine.arg_utils import AsyncEngineArgs
|
from vllm.engine.arg_utils import AsyncEngineArgs
|
||||||
@ -405,7 +405,8 @@ class AsyncLLMEngine:
|
|||||||
prompt: Optional[str],
|
prompt: Optional[str],
|
||||||
sampling_params: SamplingParams,
|
sampling_params: SamplingParams,
|
||||||
request_id: str,
|
request_id: str,
|
||||||
prompt_token_ids: Optional[List[int]] = None) -> RequestOutput:
|
prompt_token_ids: Optional[List[int]] = None
|
||||||
|
) -> AsyncIterator[RequestOutput]:
|
||||||
"""Generate outputs for a request.
|
"""Generate outputs for a request.
|
||||||
|
|
||||||
Generate outputs for a request. This method is a coroutine. It adds the
|
Generate outputs for a request. This method is a coroutine. It adds the
|
||||||
|
Loading…
x
Reference in New Issue
Block a user