Introduction¶
The common path to running large models locally is: finding weights on the Hub, confirming the format and quantization level, and then configuring the startup parameters for llama.cpp. The quant naming, custom file names, and differences between CPU / CUDA / Metal / ROCm on model pages can easily cause Agents or humans to repeatedly check documentation. huggingface-local-models consolidates “searching GGUF repos → selecting quant → starting services with llama-cli or llama-server” into a single executable default workflow, accompanied by reference instructions regarding Hub discovery, quantization selection, and hardware.
What is this¶
huggingface-local-models is an Agent Skill published by Hugging Face in the huggingface/skills repository. It follows the Agent Skills standard: the SKILL.md file within the directory contains YAML metadata (name, description), which, once activated, guides coding Agents to complete specific tasks.
The official description can be summarized as: selecting and running models locally using llama.cpp and GGUF on CPU, Mac Metal, CUDA, or ROCm; covering finding GGUFs on the Hub, quantization selection, service startup, precise GGUF file finding, converting from Transformers weights when necessary, and OpenAI-compatible local serving.
Core Features¶
The following introduces the capability boundaries specified in the Skill documentation, all of which can be verified in the official SKILL.md.
Default Workflow¶
- Use the
apps=llama.cppfilter when searching on the Hub. - Open
https://huggingface.co/<repo>?local-app=llama.cppand prioritize adopting the local-app snippets and quant suggestions provided by Hugging Face on the page. - Use
https://huggingface.co/api/models/<repo>/tree/main?recursive=trueto confirm the exact.gguffilename. - Start using
llama-cli -hf <repo>:<QUANT>orllama-server -hf <repo>:<QUANT>. - If the repository uses custom naming, fall back to
--hf-repoplus--hf-file. - Only convert from Transformers weights if the repository does not yet provide GGUF.
Quantization Selection Essentials¶
- Prioritize using the quants marked as compatible on the
?local-app=llama.cpppage. - Preserve the repository’s native labels (e.g.,
UD-Q4_K_M); do not “normalize” or rename them yourself. - Default to
Q4_K_Mif there is no special instruction; for coding or technical tasks, considerQ5_K_MorQ6_Kif VRAM/RAM allows. - If VRAM or RAM is tighter, consider
Q3_K_M,Q4_K_S, or theIQ/UD-*variants provided by the repository. mmproj-*.ggufis treated as projection weights, not the main checkpoint.
Extended References¶
The Skill references three documentation files (paths relative to the skill directory): references/hub-discovery.md (URL-first model searching and tree API), references/quantization.md (formats and imatrix, etc.), and references/hardware.md (Metal, CUDA, ROCm, CPU builds, and acceleration).
Installation and Activation¶
Hugging Face Skills can be used via clients that support Agent Skills, such as Claude Code, Codex, Gemini CLI, and Cursor. The repository suggests installing hf-cli first for Hub-related operations; other workflow Skills can be installed on-demand using hf skills add <skill-name>.
Claude Code¶
After registering the plugin marketplace and installing the CLI skill, use hf to add this Skill:
/plugin marketplace add huggingface/skills
/plugin install hf-cli@huggingface/skills
hf skills add huggingface-local-models
Codex¶
Copy or symlink skills/huggingface-local-models to the Codex-conventional .agents/skills location (e.g., $REPO_ROOT/.agents/skills or $HOME/.agents/skills). The client will discover and load SKILL.md according to the Agent Skills standard.
Gemini CLI¶
After installing the extension from the repository root or a GitHub URL, the extension will include the skills within that repository (see the repository’s gemini-extension.json and Gemini CLI extension documentation).
Cursor¶
You can install via the Cursor plugin flow from a repository URL or local checkout; the marketplace entry is primarily hf-cli, and additional Skills can also be installed using hf skills add huggingface-local-models.
Before running the workflows described by this Skill, you need to install llama.cpp and (optionally) the Hugging Face CLI on your machine.
Examples for installing llama.cpp:
brew install llama.cpp
winget install llama.cpp
Or build from source:
git clone https://github.com/ggml-org/llama.cpp
cd llama.cpp
make
You need to log in to the Hub first when accessing gated repositories:
hf auth login
Typical Usage¶
Filtering llama.cpp Models on the Hub¶
Open a filtered model list in your browser, for example, sorting by trending or filtering by parameter count range:
https://huggingface.co/models?apps=llama.cpp&sort=trending
https://huggingface.co/models?search=Qwen3.6&apps=llama.cpp&sort=trending
https://huggingface.co/models?search=<term>&apps=llama.cpp&num_parameters=min:0,max:24B&sort=trending
Pulling and Running Directly from the Hub¶
The repository and quant tags in the following commands come from the official Quick Start to demonstrate the -hf repo:QUANT syntax:
llama-cli -hf unsloth/Qwen3.6-35B-A3B-GGUF:UD-Q4_K_M
llama-server -hf unsloth/Qwen3.6-35B-A3B-GGUF:UD-Q4_K_M
When a specific filename needs to be specified:
llama-server \
--hf-repo unsloth/Qwen3.6-35B-A3B-GGUF \
--hf-file Qwen3.6-35B-A3B-UD-Q4_K_M.gguf \
-c 4096
Converting Only When No Ready-made GGUF Exists¶
Only if the target repository has no GGUF files:
hf download <repo-without-gguf> --local-dir ./model-src
python convert_hf_to_gguf.py ./model-src \
--outfile model-f16.gguf \
--outtype f16
llama-quantize model-f16.gguf model-q4_k_m.gguf Q4_K_M
(convert_hf_to_gguf.py is located in the llama.cpp repository.)
Smoke Testing the Local OpenAI-Compatible Interface¶
Start the server first:
llama-server -hf unsloth/Qwen3.6-35B-A3B-GGUF:UD-Q4_K_M
It serves /v1/chat/completions on local port 8080 by default, which can be verified with curl:
curl http://localhost:8080/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer no-key" \
-d '{
"messages": [
{"role": "user", "content": "Write a limerick about exception handling"}
]
}'
Use Cases and Notes¶
This is suitable for scenarios requiring local inference and hoping for the Agent to handle GGUFs on the Hub and llama.cpp startup parameters via a unified procedure. Keeping data local and avoiding token-based cloud APIs are common motivations for local inference; specific costs and privacy boundaries still depend on your deployment method and model licenses.
Please note the following:
- The Skill guides processes and command conventions; it does not replace installing or compiling llama.cpp with CUDA/Metal/ROCm on your machine. For hardware details, refer to
hardware.mdwithin the Skill and the Hugging Face GGUF + llama.cpp documentation. - Large model quantization and VRAM/RAM usage must be combined with machine configuration; you can use the
hf-memSkill in the same repository to estimate the memory required to load GGUF or Safetensors. - The conversion path is only used when there is no ready-made GGUF; repositories with existing GGUFs on the Hub should prioritize direct download or
-hfreference.
See the Resources section of the Skill documentation for more links: llama.cpp repository, Local Apps, Local Agents, GGUF converter Space.
Conclusion¶
huggingface-local-models encapsulates the model searching, quant selection, and startup methods associated with llama.cpp on the Hugging Face Hub into a Skill that Agents can follow, reducing the back-and-forth checking between documentation and filenames. Official Skill directory: https://github.com/huggingface/skills/tree/main/skills/huggingface-local-models.