build_hf_model - Tinker Documentation

tinker_cookbook.weights.build_hf_model

tinker_cookbook.weights.build_hf_model( base_model, adapter_path, output_path, dtype, trust_remote_code, merge_strategy, dequantize, quantize, serving_format, device)

Build a complete HuggingFace model from Tinker LoRA adapter weights.

Merges the LoRA adapter into the base model and saves the result as a standard HuggingFace model directory, compatible with vLLM, SGLang, TGI, or any HuggingFace-compatible inference framework.

Parameters:

Returns: None

Raises:

from tinker_cookbook import weights
weights.build_hf_model(
base_model="Qwen/Qwen3-8B",
adapter_path="./adapter",
output_path="./merged_model",
)

Referenced by