openml-mcp-server

openml-mcp-server

0

The OpenML MCP Server is designed to facilitate interaction with the OpenML API via clients such as Claude Desktop. It provides tools to query and manage OpenML datasets, tasks, flows, and runs, leveraging the MCP protocol.

⛑️ Work in Progress!

OpenML MCP Server

PyPI Python Versions License: MIT

An MCP (Model Context Protocol) server that allows clients (like Claude Desktop) to interact with the public OpenML API.

This server exposes various OpenML API endpoints as MCP tools, enabling queries for datasets, tasks, flows, runs, and more directly from within an MCP-compatible client.

Table of Contents

Features

  • Provides MCP tools corresponding to major OpenML GET endpoints.
  • Query datasets, tasks, flows, runs, evaluations, setups, studies.
  • List entities with filtering capabilities (where supported by the API).
  • Built using the mcp Python SDK (FastMCP).

Installation and Usage

For End Users

These instructions explain how to use this server with an MCP client like Claude Desktop.

Prerequisites:

  1. Claude Desktop: Ensure you have the latest version installed (Download here).
  2. uv (Python Package Installer): This server is run using uv. Install it once if you don't have it:
    • macOS / Linux:
      curl -LsSf https://astral.sh/uv/install.sh | sh
      
      (Restart your terminal after installation)
    • Windows (PowerShell):
      powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
      
      (Restart your PowerShell terminal after installation)

For Developers

  1. Clone the Repository:
    git clone https://github.com/your-repo/openml-mcp-server.git
    cd openml-mcp-server
    
  2. Install Dependencies:
    uv sync
    

Configuration

  1. Edit Claude Desktop Config:

    • Open Claude Desktop -> Menu -> Settings... -> Developer -> Edit Config.
    • This opens claude_desktop_config.json.
  2. Add Server Configuration:

    • Add the following block inside the mcpServers object (create mcpServers if it doesn't exist):

      {
        "mcpServers": {
          "openml-explorer": {
            "command": "uv",
            "args": [
              "run",
              "openml-mcp-server"
            ],
            "env": {
              "OPENML_API_KEY": "YOUR_ACTUAL_OPENML_API_KEY"
            }
          }
        }
      }
      
  3. Save and Restart:

    • Save claude_desktop_config.json.
    • Completely quit and restart Claude Desktop.
  4. Verify:

    • Look for the hammer icon in the Claude chat input.
    • Click it to see the available "OpenML Explorer" tools (e.g., get_dataset_description, list_tasks).

Examples

  • "Show the description for OpenML dataset ID 61."
  • "List features for dataset 31."
  • "Find the first 3 classification tasks on OpenML."
  • "Get the run description for run ID 100."

Development

See the Testing Instructions below.

Running Tests

To run the test suite (requires pytest and pytest-asyncio):

uv run pytest

Contributing

We welcome contributions! Please see our for more details.

License

This project is licensed under the MIT License. See the LICENSE file for details.