"""Download pinned public checkpoints into a configurable Hugging Face cache.""" import argparse import os from pathlib import Path from huggingface_hub import hf_hub_download REPOS = ( ("Qwen/Qwen3.5-0.8B", "2fc06364715b967f1860aea9cf38778875588b17"), ("RikiyaT/Qwen3.5-0.8B-weight-space-programming", "d1671a178705bcab7644806d23c535517f35723b"), ) def main(): parser = argparse.ArgumentParser() parser.add_argument("--cache-dir", type=Path, default=Path(os.environ.get("HF_HUB_CACHE", "cache/huggingface"))) args = parser.parse_args() args.cache_dir.mkdir(parents=True, exist_ok=True) for repo, revision in REPOS: path = hf_hub_download( repo_id=repo, filename="model.safetensors-00001-of-00001.safetensors", revision=revision, cache_dir=str(args.cache_dir), token=False, ) print(f"downloaded {repo}@{revision} -> {path}", flush=True) if __name__ == "__main__": main()