ComfyUI Model Downloader

Download models from Hugging Face and Civitai into ComfyUI model folders. Use one YAML config and run on any machine (local, server, rented GPU).

Setup

git clone https://git.danhenry.dev/daniel/model-downloader.git
cd model-downloader
python -m venv venv
source venv/bin/activate   # Windows: venv\Scripts\activate
pip install -r requirements.txt
rm config.example.yaml
touch config.yaml

Copy the example config and edit it:

cp config.example.yaml config.yaml

Edit config.yaml: set huggingface_token, civitai_token, comfyui_base_dir, and add entries under models with url and type for each model. Do not commit config.yaml (it is gitignored).

Run

python -m model_downloader
  • --config PATH config file (default: config.yaml in current directory).
  • --dry-run print what would be downloaded and where; no writes.
  • --only TYPE ... only process these model types (e.g. --only loras diffusion_models).

Config and ComfyUI folders

Each model entry has url and type. The type value is the subdirectory name under comfyui_base_dir/models/ (e.g. type: lorasmodels/loras/). Each models/<type> directory must already exist under your ComfyUI base; the tool does not create these directories and will fail if a directory is missing.

Tokens stay in your local config.yaml only; keep them out of git.

Idempotency

Same URL and model type always write to the same path (comfyui_base_dir/models/<subdir>/<filename>). Re-running is safe: existing model files are skipped (no re-download, no overwrite).

Description
No description provided
Readme 39 KiB
Languages
Python 100%