Skip to main content

VLLMShardArgs

Arguments for sharding a model using vLLM.

Attributes​

AttributeTypeDescription
tensor_parallel_sizeint = 1Number of tensor parallel workers.
dtypestr = "auto"Data type for model weights.
trust_remote_codebool = trueWhether to trust remote code from HuggingFace.
max_model_len`intNone` = null
file_pattern`strNone` = DEFAULT_SHARD_PATTERN
max_file_sizeint = 5368709120Maximum size for each sharded file.

Methods​


get_vllm_args()​

def get_vllm_args(self, model_path: str) -> dict[str, Any]: ...

Get arguments dict for vLLM LLM constructor.

Parameters​

NameTypeDescription
model_pathstrThe filesystem path or HuggingFace repository ID of the model to be loaded.

Returns​

TypeDescription
dict[str, Any]A dictionary containing the model path and configuration parameters required to initialize a vLLM LLM instance.