mlflow-mcp


Namemlflow-mcp JSON
Version 0.1.3 PyPI version JSON
download
home_pageNone
SummaryA Model Context Protocol (MCP) server for MLflow - enables LLMs to interact with MLflow experiments, runs, metrics, and models
upload_time2025-10-10 11:35:09
maintainerNone
docs_urlNone
authorKirill Kruglikov
requires_python>=3.10
licenseMIT
keywords ai llm machine-learning mcp mlflow model-context-protocol
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # MLflow MCP Server

A [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server that enables LLMs to interact with [MLflow](https://mlflow.org) tracking servers. Query experiments, analyze runs, compare metrics, and explore the model registry - all through natural language.

## Features

- **Experiment Management**: List and search experiments, discover available metrics and parameters
- **Run Analysis**: Retrieve run details, query runs with filters, find best performing models
- **Advanced Sorting**: Sort runs by any metric/parameter with flexible field selection
- **Metrics & Parameters**: Get metric histories, compare parameters across runs
- **Artifacts**: Browse and download run artifacts
- **Model Registry**: Access registered models, versions, and deployment stages
- **Comparison Tools**: Side-by-side run comparisons, best run selection
- **Tag-based Search**: Filter runs by custom tags

## Installation

### Using uvx (Recommended)

```bash
# Run directly without installation
uvx mlflow-mcp

# Or install globally
pip install mlflow-mcp
```

### From Source

```bash
git clone https://github.com/kirillkruglikov/mlflow-mcp.git
cd mlflow-mcp
uv sync
uv run mlflow-mcp
```

## Configuration

### Claude Desktop

Add to your Claude Desktop config file:

**macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
**Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
**Linux**: `~/.config/claude/claude_desktop_config.json`

```json
{
  "mcpServers": {
    "mlflow": {
      "command": "uvx",
      "args": ["mlflow-mcp"],
      "env": {
        "MLFLOW_TRACKING_URI": "http://localhost:5000"
      }
    }
  }
}
```

### Environment Variables

- **`MLFLOW_TRACKING_URI`** (required): Your MLflow tracking server URL
  - Examples: `http://localhost:5000`, `https://mlflow.company.com`

## Available Tools

### Experiments

- **`get_experiments()`** - List all experiments
- **`get_experiment_by_name(name)`** - Get experiment by name
- **`get_experiment_metrics(experiment_id)`** - Discover all unique metrics
- **`get_experiment_params(experiment_id)`** - Discover all unique parameters

### Runs

- **`get_runs(experiment_id, limit=5, include_details=False)`** - Get runs for an experiment
- **`get_run(run_id)`** - Get detailed run information
- **`get_runs_sorted(experiment_id, sort_by, ascending=False, limit=10, include_metrics=False, include_params=False, include_tags=False)`** - Get runs sorted by metric/parameter with field selection
- **`query_runs(experiment_id, query, limit=5, include_details=False)`** - Filter runs (e.g., `"metrics.accuracy > 0.9"`)
- **`search_runs_by_tags(experiment_id, tags, limit=5, include_details=False)`** - Find runs by tags

### Metrics & Parameters

- **`get_run_metrics(run_id)`** - Get all metrics for a run
- **`get_run_metric(run_id, metric_name)`** - Get full metric history with steps

### Artifacts

- **`get_run_artifacts(run_id, path="")`** - List artifacts (supports browsing directories)
- **`get_run_artifact(run_id, artifact_path)`** - Download artifact
- **`get_artifact_content(run_id, artifact_path)`** - Read artifact content (text/json)

### Analysis & Comparison

- **`get_best_run(experiment_id, metric, ascending=False)`** - Find best run by metric (supports special characters)
- **`compare_runs(experiment_id, run_ids, include_all_data=False)`** - Side-by-side comparison

### Model Registry

- **`get_registered_models()`** - List all registered models
- **`get_model_versions(model_name)`** - Get all versions of a model
- **`get_model_version(model_name, version)`** - Get version details with metrics

### Health

- **`health()`** - Check server connectivity

## Usage Examples

### Ask Claude

> "Show me all experiments in MLflow"

> "What are the top 5 runs by accuracy in experiment 'my-experiment'?"

> "Compare runs abc123 and def456"

> "Which model has the highest F1 score?"

> "Show me the training loss curve for run xyz789"

> "List all production models in the registry"

## Requirements

- Python >=3.10
- MLflow >=3.4.0
- Access to an MLflow tracking server

## License

MIT License - see [LICENSE](LICENSE) file for details.

## Contributing

Contributions welcome! Please open an issue or submit a pull request.

## Links

- [GitHub Repository](https://github.com/kirillkruglikov/mlflow-mcp)
- [MLflow Documentation](https://mlflow.org/docs/latest/index.html)
- [Model Context Protocol](https://modelcontextprotocol.io)

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "mlflow-mcp",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "ai, llm, machine-learning, mcp, mlflow, model-context-protocol",
    "author": "Kirill Kruglikov",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/eb/b2/44ac2ebcaf0b516a98a85ec2442f00bdc1830d928bd023d7005085ecfb28/mlflow_mcp-0.1.3.tar.gz",
    "platform": null,
    "description": "# MLflow MCP Server\n\nA [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server that enables LLMs to interact with [MLflow](https://mlflow.org) tracking servers. Query experiments, analyze runs, compare metrics, and explore the model registry - all through natural language.\n\n## Features\n\n- **Experiment Management**: List and search experiments, discover available metrics and parameters\n- **Run Analysis**: Retrieve run details, query runs with filters, find best performing models\n- **Advanced Sorting**: Sort runs by any metric/parameter with flexible field selection\n- **Metrics & Parameters**: Get metric histories, compare parameters across runs\n- **Artifacts**: Browse and download run artifacts\n- **Model Registry**: Access registered models, versions, and deployment stages\n- **Comparison Tools**: Side-by-side run comparisons, best run selection\n- **Tag-based Search**: Filter runs by custom tags\n\n## Installation\n\n### Using uvx (Recommended)\n\n```bash\n# Run directly without installation\nuvx mlflow-mcp\n\n# Or install globally\npip install mlflow-mcp\n```\n\n### From Source\n\n```bash\ngit clone https://github.com/kirillkruglikov/mlflow-mcp.git\ncd mlflow-mcp\nuv sync\nuv run mlflow-mcp\n```\n\n## Configuration\n\n### Claude Desktop\n\nAdd to your Claude Desktop config file:\n\n**macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`\n**Windows**: `%APPDATA%\\Claude\\claude_desktop_config.json`\n**Linux**: `~/.config/claude/claude_desktop_config.json`\n\n```json\n{\n  \"mcpServers\": {\n    \"mlflow\": {\n      \"command\": \"uvx\",\n      \"args\": [\"mlflow-mcp\"],\n      \"env\": {\n        \"MLFLOW_TRACKING_URI\": \"http://localhost:5000\"\n      }\n    }\n  }\n}\n```\n\n### Environment Variables\n\n- **`MLFLOW_TRACKING_URI`** (required): Your MLflow tracking server URL\n  - Examples: `http://localhost:5000`, `https://mlflow.company.com`\n\n## Available Tools\n\n### Experiments\n\n- **`get_experiments()`** - List all experiments\n- **`get_experiment_by_name(name)`** - Get experiment by name\n- **`get_experiment_metrics(experiment_id)`** - Discover all unique metrics\n- **`get_experiment_params(experiment_id)`** - Discover all unique parameters\n\n### Runs\n\n- **`get_runs(experiment_id, limit=5, include_details=False)`** - Get runs for an experiment\n- **`get_run(run_id)`** - Get detailed run information\n- **`get_runs_sorted(experiment_id, sort_by, ascending=False, limit=10, include_metrics=False, include_params=False, include_tags=False)`** - Get runs sorted by metric/parameter with field selection\n- **`query_runs(experiment_id, query, limit=5, include_details=False)`** - Filter runs (e.g., `\"metrics.accuracy > 0.9\"`)\n- **`search_runs_by_tags(experiment_id, tags, limit=5, include_details=False)`** - Find runs by tags\n\n### Metrics & Parameters\n\n- **`get_run_metrics(run_id)`** - Get all metrics for a run\n- **`get_run_metric(run_id, metric_name)`** - Get full metric history with steps\n\n### Artifacts\n\n- **`get_run_artifacts(run_id, path=\"\")`** - List artifacts (supports browsing directories)\n- **`get_run_artifact(run_id, artifact_path)`** - Download artifact\n- **`get_artifact_content(run_id, artifact_path)`** - Read artifact content (text/json)\n\n### Analysis & Comparison\n\n- **`get_best_run(experiment_id, metric, ascending=False)`** - Find best run by metric (supports special characters)\n- **`compare_runs(experiment_id, run_ids, include_all_data=False)`** - Side-by-side comparison\n\n### Model Registry\n\n- **`get_registered_models()`** - List all registered models\n- **`get_model_versions(model_name)`** - Get all versions of a model\n- **`get_model_version(model_name, version)`** - Get version details with metrics\n\n### Health\n\n- **`health()`** - Check server connectivity\n\n## Usage Examples\n\n### Ask Claude\n\n> \"Show me all experiments in MLflow\"\n\n> \"What are the top 5 runs by accuracy in experiment 'my-experiment'?\"\n\n> \"Compare runs abc123 and def456\"\n\n> \"Which model has the highest F1 score?\"\n\n> \"Show me the training loss curve for run xyz789\"\n\n> \"List all production models in the registry\"\n\n## Requirements\n\n- Python >=3.10\n- MLflow >=3.4.0\n- Access to an MLflow tracking server\n\n## License\n\nMIT License - see [LICENSE](LICENSE) file for details.\n\n## Contributing\n\nContributions welcome! Please open an issue or submit a pull request.\n\n## Links\n\n- [GitHub Repository](https://github.com/kirillkruglikov/mlflow-mcp)\n- [MLflow Documentation](https://mlflow.org/docs/latest/index.html)\n- [Model Context Protocol](https://modelcontextprotocol.io)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A Model Context Protocol (MCP) server for MLflow - enables LLMs to interact with MLflow experiments, runs, metrics, and models",
    "version": "0.1.3",
    "project_urls": {
        "Homepage": "https://github.com/kkruglik/mlflow-mcp",
        "Issues": "https://github.com/kkruglik/mlflow-mcp/issues",
        "Repository": "https://github.com/kkruglik/mlflow-mcp"
    },
    "split_keywords": [
        "ai",
        " llm",
        " machine-learning",
        " mcp",
        " mlflow",
        " model-context-protocol"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "bcab8bd80a641c0461eaa5358cab2e80c889490c7fdb43b3d2d57b4a88e6a4f0",
                "md5": "21769b6d706badbbf4f4bdcc187e9446",
                "sha256": "bf256b546c55afde6f73bb915c7ecc81fe843e74e49418b39a283af7bf5eca8b"
            },
            "downloads": -1,
            "filename": "mlflow_mcp-0.1.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "21769b6d706badbbf4f4bdcc187e9446",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 9100,
            "upload_time": "2025-10-10T11:35:07",
            "upload_time_iso_8601": "2025-10-10T11:35:07.991016Z",
            "url": "https://files.pythonhosted.org/packages/bc/ab/8bd80a641c0461eaa5358cab2e80c889490c7fdb43b3d2d57b4a88e6a4f0/mlflow_mcp-0.1.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "ebb244ac2ebcaf0b516a98a85ec2442f00bdc1830d928bd023d7005085ecfb28",
                "md5": "3096260df550ccae6fbd59b31dbb6fd3",
                "sha256": "cb01667ae54c87688b6774b143159c55b83c3f2ea09b3a349d413bf9f76a5988"
            },
            "downloads": -1,
            "filename": "mlflow_mcp-0.1.3.tar.gz",
            "has_sig": false,
            "md5_digest": "3096260df550ccae6fbd59b31dbb6fd3",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 178359,
            "upload_time": "2025-10-10T11:35:09",
            "upload_time_iso_8601": "2025-10-10T11:35:09.035868Z",
            "url": "https://files.pythonhosted.org/packages/eb/b2/44ac2ebcaf0b516a98a85ec2442f00bdc1830d928bd023d7005085ecfb28/mlflow_mcp-0.1.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-10-10 11:35:09",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "kkruglik",
    "github_project": "mlflow-mcp",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "mlflow-mcp"
}
        
Elapsed time: 3.80361s