HF Skills Let Agents Fine-Tune Models via Prompts
AI Engineergo watch the original →
the gist
Merve Noyan demos Hugging Face skills enabling agents like Claude Code to fine-tune VLMs (e.g., Qwen2-VL on lava-instruct-mix dataset) by calculating VRAM, selecting instances, and launching jobs—all from a single prompt.
The Breakthrough
Hugging Face skills allow coding agents to autonomously fine-tune vision-language models by prompting them with dataset and model names; the agent computes VRAM requirements, selects an instance type, queries validation split preferences, and launches the training job remotely or locally.
What Actually Worked
- Filter agentic models on Hugging Face Hub and sort by benchmarks like SWE-bench Pro or AIME via the datasets page benchmark button to select top open models such as GLM-4.1.
- Use inference providers on Hub to route requests to the fastest or cheapest provider (e.g., Grok, Cerebras) for a given model, with a 'tool used' column for comparison.
- Push agent traces from Cline, Cloud Code, or Pi to a new 'traces' dataset repository type on Hub; view parsed sessions in the dataset viewer and train models on them later.
- Install Hugging Face skills like
huggingface-cli-skill(manages repos, runs jobs, launches demos),llm-trainer-skill(fine-tunes LLMs/VLMs),gradio-skill(builds demos), andhuggingface-dataset-skill(explores datasets via viewer API) to plug Hub into agents. - Run local coding agents with tools like Pi (connects to llama.cpp server), llama-agent binary (takes HF model ID), or Hermes agents (with setup wizard for Slack/WhatsApp integration, using GLM-4.1); quantize GGUF files (e.g., Gemma-2 27B Q4_K_M fits L4 GPU with 24GB VRAM).
- Query MCP server endpoints (models, datasets, spaces, search, jobs, semantic search) from agents; enable 'dynamic spaces' for full app store access (e.g., generate 'baklava made of yarn' via Hugging Face Qwen image model).
Before / After
Omitted: source provides no direct before/after comparisons for techniques shown.
Context
Merve Noyan from Hugging Face open source team highlights open-weight models' advantages: full access for quantization, fine-tuning, edge deployment with privacy; GLM-4.1 leads Artificial Analysis Intelligence Index over closed models. She tours HF Hub's agentic features amid 3M+ models, emphasizing easy local serving (vllm, llama.cpp, LM Studio) and skills that turn 'napkin math' for training into agent prompts. This matters as open models close performance gaps, avoid cloud degradation risks, and enable sci-fi workflows like agent-driven OCR on 30K papers via skills and jobs.
Live demo: Prompt Claude Code to 'train qwen2-vl on lava-instruct-mix'; agent asks for instance/batch size/validation split, launches job, uploads result to Hub.
Notable Quotes
- "What used to be a day of napkin math is now a prompt."
- "Train Q1 3.5 on this data set for me and then it just trains which to me is like a sci-fi at this point."
- "GLM 4.1 is absolutely crashing it... we just catched up and we will catch up even more."