Skip to content

Vllm

Initialization for the ZenML vLLM integration.

VLLMIntegration

Bases: Integration

Definition of vLLM integration for ZenML.

Source code in src/zenml/integrations/vllm/__init__.py
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
class VLLMIntegration(Integration):
    """Definition of vLLM integration for ZenML."""

    NAME = VLLM

    REQUIREMENTS = ["vllm>=0.6.0,<0.7.0", "openai>=1.0.0"]

    @classmethod
    def activate(cls) -> None:
        """Activates the integration."""
        from zenml.integrations.vllm import services

    @classmethod
    def flavors(cls) -> List[Type[Flavor]]:
        """Declare the stack component flavors for the vLLM integration.

        Returns:
            List of stack component flavors for this integration.
        """
        from zenml.integrations.vllm.flavors import VLLMModelDeployerFlavor

        return [VLLMModelDeployerFlavor]

activate() classmethod

Activates the integration.

Source code in src/zenml/integrations/vllm/__init__.py
33
34
35
36
@classmethod
def activate(cls) -> None:
    """Activates the integration."""
    from zenml.integrations.vllm import services

flavors() classmethod

Declare the stack component flavors for the vLLM integration.

Returns:

Type Description
List[Type[Flavor]]

List of stack component flavors for this integration.

Source code in src/zenml/integrations/vllm/__init__.py
38
39
40
41
42
43
44
45
46
47
@classmethod
def flavors(cls) -> List[Type[Flavor]]:
    """Declare the stack component flavors for the vLLM integration.

    Returns:
        List of stack component flavors for this integration.
    """
    from zenml.integrations.vllm.flavors import VLLMModelDeployerFlavor

    return [VLLMModelDeployerFlavor]