HL

humansignal/label-studio-mcp-server

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

39 stars 15 forks 质量 62 趋势 0Apache-2.0

humansignal/label-studio-mcp-server 是从 https://github.com/humansignal/label-studio-mcp-server. 导入的 MCP 服务器候选

概览

humansignal/label-studio-mcp-server 是从 https://github.com/humansignal/label-studio-mcp-server. 导入的 MCP 服务器候选

概述(AI 翻译)

概述

该项目提供了一个模型上下文协议(MCP)服务器,允许通过 label-studio-sdk 与 Label Studio 实例交互。它通过自然语言或 MCP 客户端的结构化调用,实现对标记项目、任务和预测的程序化管理。使用该 MCP 服务器,您可以发出以下请求:

  • “用这些数据在唱片工作室创建项目…”
  • “我的RAG评审项目中标注了多少任务?”
  • “为我的任务添加预测。”
  • “更新我的标签模板,加入评论框。”

特色

  • 项目管理:创建、更新、列出并查看Label Studio项目的详细信息/配置。
  • 任务管理:从文件导入任务,在项目中列出任务,并检索任务数据/注释。
  • 预测集成:为特定任务添加模型预测。
  • SDK 集成:利用官方 label-studio-sdk 进行通信。

先修条件

  1. 运行Label Studio实例: 你需要一个正在运行的Label Studio实例,并能从该MCP服务器访问。
  2. API 密钥: 从 Label Studio 的用户账户设置中获取 API 密钥。

配置

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Label Studio MCP Server

Overview

This project provides a Model Context Protocol (MCP) server that allows interaction with a Label Studio instance using the label-studio-sdk. It enables programmatic management of labeling projects, tasks, and predictions via natural language or structured calls from MCP clients. Using this MCP Server, you can make requests like:

  • “Create a project in label studio with this data …”
  • “How many tasks are labeled in my RAG review project?”
  • “Add predictions for my tasks.”
  • “Update my labeling template to include a comment box.”

Features

  • Project Management: Create, update, list, and view details/configurations of Label Studio projects.
  • Task Management: Import tasks from files, list tasks within projects, and retrieve task data/annotations.
  • Prediction Integration: Add model predictions to specific tasks.
  • SDK Integration: Leverages the official label-studio-sdk for communication.

Prerequisites

  1. Running Label Studio Instance: You need a running instance of Label Studio accessible from where this MCP server will run.
  2. API Key: Obtain an API key from your user account settings in Label Studio.

Configuration

The MCP server requires the URL and API key for your Label Studio instance. If launching the server via an MCP client configuration file, you can specify the environment variables directly within the server definition. This is often preferred for client-managed servers.

Add the following JSON entry to your claude_desktop_config.json file or Cursor MCP settings:

{
    "mcpServers": {
        "label-studio": {
            "command": "uvx",
            "args": [
                "--from",
                "git+https://github.com/HumanSignal/label-studio-mcp-server",
                "mcp-label-studio"
            ],
            "env": {
                "LABEL_STUDIO_API_KEY": "your_actual_api_key_here", // <-- Your API key
                "LABEL_STUDIO_URL": "http://localhost:8080"
            }
        }
    }
}

<!–

Installation

Follow these instructions to install the server.

git clone https://github.com/HumanSignal/label-studio-mcp-server.git 
cd label-studio-mcp-server

# Install dependencies using uv
uv venv
source .venv/bin/activate 
uv sync
```json
{
  "mcpServers": {
    "label-studio": {
        "command": "uv",
        "args": [
            "--directory",
            "/path/to/your/label-studio-mcp-server", // <-- Update this path
            "run",
            "label-studio-mcp.py"
        ],
        "env": {
            "LABEL_STUDIO_API_KEY": "your_actual_api_key_here", // <-- Your API key
            "LABEL_STUDIO_URL": "http://localhost:8080"
        }
    }
  }
}
在 GitHub 查看完整 README

安装

uvx --from git+https://github.com/HumanSignal/label-studio-mcp-server mcp-label-studio
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "label-studio": { "command": "uvx", "args": [ "--from", "git+https://github.com/HumanSignal/label-studio-mcp-server", "mcp-label-studio" ], "env": { "LABEL_STUDIO_API_KEY": "your_actual_api_key_here", // <-- Your API key "LABEL_STUDIO_URL": "http://localhost:8080" } } } }