MLflow MCP Server
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
> **The widest-coverage MLflow MCP — including MLflow 3 traces, prompt-optimization, webhooks, and Databricks trace attachments that no other MCP exposes.**
>
> 82 tools across experiments, runs, registry, logged models, traces, assessments, webhooks, prompt-optimization. Aggregation tools (summarize-experiment, summarize-run) fold 3–5 round-trips into one structured response with already-fetched metric stats.
What it does that others don't
- **Full coverage** — only third-party MLflow MCP shipping prompt-optimization-jobs (5 tools), webhooks (6), MLflow 3 LoggedModel (8), and Databricks trace attachments (list-trace-attachments, get-trace-attachment — Databricks MLflow only; OSS returns 404).
- **Aggregation tools** — summarize-experiment returns experiment + topN runs + metric stats (min/max/mean) in one call from already-fetched data, zero extra round-trips. summarize-run dedups metricHistory.history.*.key (~100KB savings on 4k-point series).
- **MCP Prompts** (4) — debug-failed-traces, promote-best-run, compare-top-runs, annotate-trace-quality. Workflow templates the model invokes directly.
- **MCP Resources** (6) — mlflow://run/{runId}, mlflow://experiment/{expId}, mlflow://run/{runId}/artifacts, mlflow://experiment/{expId}/runs, mlflow://registered-model/{name}/versions, mlflow://trace/{traceId}.
- **Token-efficient by design** — extractFields projection on get-run / search-runs / search-traces / get-trace / fat reads, MLFLOW_TOOLS / MLFLOW_DISABLE 8 categories, search-tools meta-tool.
- **Apps SDK card** — compare-runs renders as a side-by-side card on ChatGPT clients (run summary + metric/param tables with diff highlight) via _meta["openai/outputTemplate"]. Claude clients receive the same JSON content.
- **stdio + Streamable HTTP** — defaults to stdio. Set MCP_TRANSPORT=http for ChatGPT Apps SDK or remote clients (Bearer auth via MCP_HTTP_TOKEN).
Try this — 5 prompts
Connect the server to Claude Desktop or Claude Code, then paste any of these:
1. **Best run** — *"In the customer-churn-v3 experiment, find the run with the highest val_accuracy. Show its hyperparameters and metric history."*
2. **Failure mode clustering** — *"Find traces with status=ERROR from the last 24h in experiment 12. Group the failures by exception type and surface the 3 most common."*
3. **Run comparison** — *"Compare the top 5 runs of experiment 12 by validation_loss. Show differing hyperparameters in a table."*
4. **Model promotion** — *"Get the latest version of recommendation_v2 registered model with the champion alias. Show its training metrics + lineage to the source run."*
5. **Trace deep-dive** — *"Pull trace tr-abc123. Highlight slow spans and any failed feedback annotations."* (Add list-trace-attachments on Databricks workspaces.)
When to use this vs alternatives
| | Official mlflow[mcp] | kkruglik/mlflow-mcp | @us-all/mlflow-mcp (this) |
|--|------------------------|---------------------|------------------------------|
| Tool count | ~9 (trace-only) | ~25 | **78** |
| MLflow 3 LoggedModel | ❌ | ✅ | ✅ |
| Trace attachments | ❌ | ❌ | ✅ Databricks only |
| Prompt-optimization-jobs | ❌ | ❌ | ✅ |
| Webhooks | ❌ | ❌ | ✅ |
| Aggregation tools | ❌ | ❌ | ✅ summarize-experiment, summarize-run |
| MCP Prompts | ❌ | ✅ | ✅ |
| MCP Resources | ❌ | ❌ | ✅ 6 URIs |
| Auth | Databricks SDK | Bearer / basic | Bearer / basic |
| Transport | stdio | stdio | stdio |
The official mlflow[mcp] is bundled inside MLflow itself and intentionally trace-narrow. Use it for quick managed-MLflow trace inspection. Use this server for end-to-end coverage, especially MLflow 3 entities, prompt-optimization workflows, and aggregation-driven AI debugging.
Install
Claude Desktop
Claude Code
Docker
Build from source
Configuration