View on GitHub
"```python\nfrom modal_training_gym.deploy_recipes.vllm_recipe import VllmRecipe\n```\n\nvLLM serving configuration.\n\n**Inherits from:** `BaseDeployRecipe`\n\n## Fields\n\n| Field | Type | Default | Description |\n|-------|------|---------|-------------|\n| `recipe_type` | `DeployRecipeType` | `vllm` | |\n| `gpu` | `Optional[Literal['H100', 'H200', 'B200', 'B300']]` | `None` | GPU type for the serving container. Default `None` (inferred). |\n| `n_gpu` | `int \\| None` | `None` | Number of GPUs (tensor-parallel degree for vLLM). Default `None`. |\n| `extra_vllm_args` | `list[str] \\| None` | `None` | Additional CLI args passed to `vllm serve`. Default `None`. |\n| `environment_name` | `str \\| None` | `None` | Modal environment to deploy into. Default `None`. |\n| `deploy_strategy` | `str` | `\"rolling\"` | Modal deployment strategy. Default `\"rolling\"`. |\n| `startup_timeout` | `int` | `1200` | Seconds the server container is allowed to spend in startup before Modal kills it. Default `1200` (20 minutes). |\n\n**Source:** [`modal_training_gym/deploy_recipes/vllm_recipe.py`](https://github.com/modal-projects/training-gym/blob/main/modal_training_gym/deploy_recipes/vllm_recipe.py)\n"
VllmRecipe
vLLM serving configuration.
from modal_training_gym.deploy_recipes.vllm_recipe import VllmRecipevLLM serving configuration.
Inherits from: BaseDeployRecipe
Fields
Section titled “Fields”| Field | Type | Default | Description |
|---|---|---|---|
recipe_type | DeployRecipeType | vllm | |
gpu | Optional[Literal['H100', 'H200', 'B200', 'B300']] | None | GPU type for the serving container. Default None (inferred). |
n_gpu | int | None | None | Number of GPUs (tensor-parallel degree for vLLM). Default None. |
extra_vllm_args | list[str] | None | None | Additional CLI args passed to vllm serve. Default None. |
environment_name | str | None | None | Modal environment to deploy into. Default None. |
deploy_strategy | str | "rolling" | Modal deployment strategy. Default "rolling". |
startup_timeout | int | 1200 | Seconds the server container is allowed to spend in startup before Modal kills it. Default 1200 (20 minutes). |