This project implements a Model Context Protocol (MCP) server for ClearML, enabling AI agents to interact with ClearML experiments, models, and projects.
The ClearML MCP server provides comprehensive tools for AI agents to:
- Discover and analyze ML experiments
- Compare model performance across tasks
- Retrieve training metrics and artifacts
- Search and filter projects and tasks
- Get comprehensive model context and lineage
get_task_info(task_id)- Get ClearML task details, parameters, and statuslist_tasks(project_name, status, tags)- List ClearML tasks with filtersget_task_parameters(task_id)- Get task hyperparameters and configurationget_task_metrics(task_id)- Get task training metrics and scalarsget_task_artifacts(task_id)- Get task artifacts and outputs
get_model_info(task_id)- Get model metadata and configurationlist_models(project_name)- List available models with filteringget_model_artifacts(task_id)- Get model files and download URLs
list_projects()- List available ClearML projectsget_project_stats(project_name)- Get project statistics and task counts
compare_tasks(task_ids, metrics)- Compare multiple tasks by metricssearch_tasks(query, project_name)- Search tasks by name, tags, or description
- fastmcp>=0.1.0
- clearml>=1.16.0
- pydantic>=2.0.0
- Built with FastMCP framework
- Uses stdio transport for Claude Desktop integration
- Leverages existing ~/clearml.conf for authentication
- Implements JSON-RPC 2.0 protocol
- Main executable:
clearml-mcp(via uvx) - Main module:
src/clearml_mcp/clearml_mcp.py
Users must have a configured ~/clearml.conf file with:
[api]
api_server = https://your-clearml-server.com
access_key = your-access-key
secret_key = your-secret-key
# Using uvx (no installation needed)
uvx clearml-mcp
# Verify clearml.conf works first
clearml-task --helpAdd to Claude Desktop configuration:
{
"mcpServers": {
"clearml": {
"command": "uvx",
"args": ["clearml-mcp"]
}
}
}# Run tests (to be implemented)
pytest tests/
# Type checking (to be implemented)
mypy src/clearml_mcp/# Build package
hatch build
# Publish to PyPI
hatch publish- Core MCP server with 12 tools
- PyPI packaging
- Claude Desktop integration
- Documentation
- Tests
- Validates task_id format before API calls
- Uses existing clearml.conf for authentication
- No credentials stored in code
- Local-only usage (no remote server endpoints)