Hugging Face MCP Server
Overview​
Hugging Face provides a large ecosystem of models, datasets, and AI tools. The Hugging Face MCP server enables Enterprise h2oGPTe agents to look up models and datasets and run inference via Hugging Face services.
For more information, visit Hugging Face.
When to use​
Use this MCP server when you want agents to:
- Retrieve information about Hugging Face models and datasets
- Run model inference via Hugging Face APIs
- Search for models or datasets that match a given task
Requirements​
Before configuring this MCP server, ensure you have:
- A Hugging Face account
- A valid Hugging Face API token (
HF_TOKEN)
Key capabilities​
The Hugging Face MCP server can:
- Fetch metadata about models and datasets
- Run inference requests against supported endpoints
- Help agents discover appropriate models and datasets for a task
Configuration​
Add the following configuration in Agents > Tools > New Tool > Remote MCP Tools:
{
"huggingface": {
"command": "npx",
"args": [
"mcp-remote",
"https://huggingface.co/mcp",
"--header",
"Authorization: Bearer os.environ/HF_TOKEN"
],
"env": {
"HF_TOKEN": "os.environ/HF_TOKEN"
}
}
}
Authentication​
In Agents > Authentication, create a secret with:
HF_TOKEN: Hugging Face API token with appropriate permissions
Notes​
- This MCP server uses HTTP transport via the
mcp-remoteclient. - Ensure that your Hugging Face token follows your organization’s security and rotation policies.
Feedback
- Submit and view feedback for this page
- Send feedback about Enterprise h2oGPTe to cloud-feedback@h2o.ai