A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 16, 10:45 UTC
[CI/Build] mypy: check vllm/entrypoints (#9194)
Signed-off-by: Russell Bryant <rbryant@redhat.com>
Russell Bryant committed
Oct 9, 2024 at 13:15 UTC
cdca8994bd856a234112875a92746c5782837768
2 files changed
+6
-3
tools/mypy.sh
+1
-1
@@ -19,7 +19,7 @@ run_mypy vllm/attention
19
#run_mypy vllm/core
20
run_mypy vllm/distributed
21
run_mypy vllm/engine
22
-#run_mypy vllm/entrypoints
22
+run_mypy vllm/entrypoints
23
run_mypy vllm/executor
24
#run_mypy vllm/inputs
25
run_mypy vllm/logging
vllm/entrypoints/llm.py
+5
-2
@@ -514,10 +514,13 @@ class LLM:
514
# Handle multi and single conversations
515
if is_list_of(messages, list):
516
# messages is List[List[...]]
517
- list_of_messages = messages
517
+ list_of_messages = cast(List[List[ChatCompletionMessageParam]],
518
+ messages)
519
else:
520
# messages is List[...]
520
- list_of_messages = [messages]
521
+ list_of_messages = [
522
+ cast(List[ChatCompletionMessageParam], messages)
523
+ ]
524
525
prompts: List[Union[TokensPrompt, TextPrompt]] = []
526