__init__.py 1.87 KB
Newer Older
1
# SPDX-License-Identifier: Apache-2.0
2
"""vLLM: a high-throughput and memory-efficient inference engine for LLMs"""
3
4
5
6
# The version.py should be independent library, and we always import the
# version library first.  Such assumption is critical for some customization.
from .version import __version__, __version_tuple__  # isort:skip

7
8
9
10
# The environment variables override should be imported before any other
# modules to ensure that the environment variables are set before any
# other modules are imported.
import vllm.env_override  # isort:skip  # noqa: F401
11

12
13
14
15
from vllm.engine.arg_utils import AsyncEngineArgs, EngineArgs
from vllm.engine.async_llm_engine import AsyncLLMEngine
from vllm.engine.llm_engine import LLMEngine
from vllm.entrypoints.llm import LLM
16
from vllm.executor.ray_utils import initialize_ray_cluster
17
from vllm.inputs import PromptType, TextPrompt, TokensPrompt
18
from vllm.model_executor.models import ModelRegistry
19
20
21
22
23
from vllm.outputs import (ClassificationOutput, ClassificationRequestOutput,
                          CompletionOutput, EmbeddingOutput,
                          EmbeddingRequestOutput, PoolingOutput,
                          PoolingRequestOutput, RequestOutput, ScoringOutput,
                          ScoringRequestOutput)
24
from vllm.pooling_params import PoolingParams
25
from vllm.sampling_params import SamplingParams
Woosuk Kwon's avatar
Woosuk Kwon committed
26
27

__all__ = [
28
    "__version__",
29
    "__version_tuple__",
Woosuk Kwon's avatar
Woosuk Kwon committed
30
    "LLM",
31
    "ModelRegistry",
32
    "PromptType",
33
34
    "TextPrompt",
    "TokensPrompt",
Woosuk Kwon's avatar
Woosuk Kwon committed
35
36
37
    "SamplingParams",
    "RequestOutput",
    "CompletionOutput",
38
39
    "PoolingOutput",
    "PoolingRequestOutput",
40
41
42
43
44
45
    "EmbeddingOutput",
    "EmbeddingRequestOutput",
    "ClassificationOutput",
    "ClassificationRequestOutput",
    "ScoringOutput",
    "ScoringRequestOutput",
Woosuk Kwon's avatar
Woosuk Kwon committed
46
47
48
49
    "LLMEngine",
    "EngineArgs",
    "AsyncLLMEngine",
    "AsyncEngineArgs",
50
    "initialize_ray_cluster",
51
    "PoolingParams",
Woosuk Kwon's avatar
Woosuk Kwon committed
52
]