alvarobarttalvarobarttCommunityยท1 Agent Skills Included

hf-mem

Estimate GPU memory needed to run any Hugging Face model

Estimates the inference memory requirements of any Hugging Face model, including Safetensors and GGUF weights plus optional KV cache. Reads model metadata remotely via HTTP range requests, so nothing is downloaded or loaded locally. Helps you check if a model fits your GPU before deployment, saving time and avoiding failed runs.
npx skills add alvarobartt/hf-mem --all -g -y

All Skills in This Repository (1)

Pure Emerald Level Indicators

Frequently Asked Questions

FAQPage Schema
How to install hf-mem?โ–ผ

Run `npx skills add alvarobartt/hf-mem --all -g -y` in your terminal to install this skill globally for your AI agent.

How to check if a model fits on my GPU?โ–ผ

Ask your agent to run hf-mem with the model ID, and it returns the total memory needed for weights and KV cache without downloading anything.

Does hf-mem work with GGUF models?โ–ผ

Yes. It estimates memory per GGUF file, and you can target a specific quantization file for an exact figure.

Can hf-mem estimate KV cache memory?โ–ผ

Yes. The experimental flag adds KV cache estimates for LLMs and VLMs, with options for context length, batch size, and cache precision.

Do I need to download the model first?โ–ผ

No. hf-mem reads only the model metadata over HTTP range requests, so estimates are fast and use no local storage.

Related Repositories in Software Engineering

View All in Software Engineeringโ†’