정상록TL;DR ml-intern is Hugging Face's open-source ML engineering agent (Apache 2.0, 621⭐ as...
If you've been looking for a Claude Code equivalent that actually understands load_dataset, Trainer, and push_to_hub, this is it.
ml-intern is an autonomous ML engineering agent released by Hugging Face on October 30, 2025. It's a CLI tool that reads papers, trains models, and ships code — end-to-end.
Think of it as "Claude Code, but it speaks fluent Hugging Face."
Repo: https://github.com/huggingface/ml-intern
Stars: 621 ⭐ (2026-04)
Forks: 62
Lang: Python 69.4% + TypeScript 30.1%
License: Apache 2.0
Maintainer: Hugging Face (smolagents org)
Because the architecture isn't hype. It's a textbook implementation of Anthropic's agentic harness principles:
User/CLI
↓
submission_loop (agent_loop.py)
↓
Handlers.run_agent()
↓
Agentic Loop (max 300 iterations)
├─ Session
│ ├─ ContextManager (170k auto-compaction → HF Hub upload)
│ └─ ToolRouter
│ ├─ HF docs & research
│ ├─ HF repos / datasets / papers
│ ├─ HF Jobs (cloud GPU)
│ ├─ GitHub code search
│ ├─ Sandbox & local tools
│ ├─ Planning
│ └─ MCP server tools
└─ Doom Loop Detector
The pieces developers will actually appreciate:
processing, tool_call, approval_required, compacted, interrupted, etc. Perfect for monitoring dashboards.# Clone and install
git clone git@github.com:huggingface/ml-intern.git
cd ml-intern
uv sync
uv tool install -e .
# Verify
ml-intern --help
Then drop 3 keys in .env:
ANTHROPIC_API_KEY=sk-ant-...
HF_TOKEN=hf_...
GITHUB_TOKEN=ghp_...
Done.
ml-intern
REPL-style. Good for first-time users or when you want to approve each tool call.
ml-intern "fine-tune mistralai/Mistral-7B-v0.1 on my HF dataset using LoRA"
Auto-approve is the default. Drop this in a GitHub Action and you have nightly ML experiments.
ml-intern --model anthropic/claude-opus-4-6 "complex reasoning task"
ml-intern --max-iterations 100 "bounded budget"
ml-intern --no-stream "CI-friendly output"
Open agent/core/tools.py and drop a new ToolSpec:
def create_builtin_tools() -> List[ToolSpec]:
return [
# ...existing tools
ToolSpec(
name="my_internal_search",
description="Search my company's internal docs for ML best practices",
input_schema={
"type": "object",
"properties": {
"query": {"type": "string"}
},
"required": ["query"]
},
handler=my_internal_search_handler
),
]
async def my_internal_search_handler(query: str) -> str:
# Your logic here
return formatted_result
Re-install with uv tool install -e . --force and you're done.
In configs/main_agent_config.json:
{
"mcpServers": {
"my-db": {
"command": "node",
"args": ["/opt/mcp-servers/my-db/index.js"],
"env": {
"DB_URL": "${COMPANY_DB_URL}",
"API_KEY": "${COMPANY_API_KEY}"
}
}
}
}
${ENV_VAR} is auto-substituted from your .env. No secret leakage in JSON.
Sionic AI (Korean ML team) runs 1,000+ experiments per day with a Claude Code + HF Skills pipeline. The HF blog post "We Got Claude to Fine-Tune an Open Source LLM" hit 613 upvotes.
This isn't a toy. It's what solo ML teams use to 10x their throughput.
| Feature | Claude Code | ml-intern |
|---|---|---|
| Domain | General coding | ML workflows |
| Model | claude-sonnet-4-5 |
claude-sonnet-4-5 |
| MCP support | ✅ | ✅ |
| Ecosystem | Generic | HF Hub/Jobs/Spaces/Papers |
| Open source | Partial | Fully open (Apache 2.0) |
| Max iterations | Configurable | 300 default |
| Auto-compaction | Yes | 170k + HF Hub upload |
Same philosophy, different specialization. If your daily work is "read paper → download dataset → fine-tune → deploy Space," ml-intern is the right tool.
ml-intern isn't standalone. It's part of a coordinated push:
If you're building anything with LLMs in 2026, this ecosystem is worth knowing.
hf skills add hf-cli.The question isn't "should I use an ML agent?" anymore. It's "how fast can I fork and extend one for my workflow?"
ml-intern gives you a production-grade starting point, Apache 2.0 licensed, with the same Anthropic runtime you already trust from Claude Code.
Six months from launch to 621 stars with active development. That's signal.
Links: