Mcp As A Judge

io.github.OtherVibes由 GitHub 帳號 OtherVibes 發布v0.3.20更新於 Nov 10, 2026

MCP as a Judge: a behavioral MCP that strengthens AI coding assistants via explicit LLM evaluations

已驗證STDIO僅桌面開發者工具AI 與機器學習

概覽

AI 產生的概覽

透過讓 LLM 評審計畫、程式碼差異、測試與任務完成情況,為 AI 程式開發助理加上核准關卡。

可以做什麼
MCP as a Judge 是一個行為型 MCP 伺服器,在 AI 程式開發助理與其 LLM 之間插入驗證關卡。set_coding_task 與 get_current_coding_task 等工具用來記錄任務中繼資料;judge_coding_plan、judge_code_change、judge_testing_implementation 與 judge_coding_task_completion 分別評審計畫、統一 Git 差異、測試執行輸出與最終完成情況。raise_missing_requirements 與 raise_obstacle 會針對缺少的資訊或決策向使用者提問。評審透過 MCP sampling 執行,也可退回使用已設定的 LLM API 金鑰。
適用情境
當你希望 AI 程式開發助理依照計畫、程式碼、測試、完成的流程推進,並在每個階段取得明確核准,而不是直接採信生成的程式碼時,適合使用。它適合需要對計畫、差異與測試進行有憑據的評審,並在需求不明確時由人做決定的團隊。它不能取代 IDE 規則或子代理,而是在其上增加可強制執行的關卡。
執行需求
以 stdio 方式在本機執行,可透過 uv 從 PyPI 安裝 mcp-as-a-judge,或以 Docker 映像檔執行。需要 Python 3.13+ 或 Docker Desktop。完整功能需要支援 sampling 與 elicitation 的 MCP 用戶端,例如 VS Code 中的 GitHub Copilot。不支援完整 sampling 的用戶端(包括 Cursor、Claude Code、Augment、Qodo)必須設定 LLM_API_KEY 環境變數;LLM_MODEL_NAME 為選用項目。
安裝前請注意
對於不支援完整 MCP sampling 的用戶端,必須設定 LLM_API_KEY,伺服器隨後會把你提供的計畫、程式碼或測試內容傳送給所選 LLM 供應商進行評審。README 聲明在使用 sampling 時不收集資料、不進行外部呼叫。伺服器會評審程式碼差異與測試輸出,因此敏感程式碼可能包含在評審內容中。Docker 設定使用 --pull=always,每次執行都會拉取最新映像檔。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Mcp As A Judge,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

MCP as a Judge ⚖️

mcp-name: io.github.OtherVibes/mcp-as-a-judge

MCP as a Judge acts as a validation layer between AI coding assistants and LLMs, helping ensure safer and higher-quality code.

[License: MIT] [Python 3.13+] [MCP Compatible]

[CI] [Release] [PyPI version]

MCP as a Judge is a behavioral MCP that strengthens AI coding assistants by requiring explicit LLM evaluations for:

  • Research, system design, and planning
  • Code changes, testing, and task-completion verification

It enforces evidence-based research, reuse over reinvention, and human-in-the-loop decisions.

If your IDE has rules/agents (Copilot, Cursor, Claude Code), keep using them—this Judge adds enforceable approval gates on plan, code diffs, and tests.

Key problems with AI coding assistants and LLMs

  • Treat LLM output as ground truth; skip research and use outdated information
  • Reinvent the wheel instead of reusing libraries and existing code
  • Cut corners: code below engineering standards and weak tests
  • Make unilateral decisions when requirements are ambiguous or plans change
  • Security blind spots: missing input validation, injection risks/attack vectors, least‑privilege violations, and weak defensive programming

Vibe coding doesn’t have to be frustrating

What it enforces

  • Evidence‑based research and reuse (best practices, libraries, existing code)
  • Plan‑first delivery aligned to user requirements
  • Human‑in‑the‑loop decisions for ambiguity and blockers
  • Quality gates on code and tests (security, performance, maintainability)

Key capabilities

  • Intelligent code evaluation via MCP sampling; enforces software‑engineering standards and flags security/performance/maintainability risks
  • Comprehensive plan/design review: validates architecture, research depth, requirements fit, and implementation approach
  • User‑driven decisions via MCP elicitation: clarifies requirements, resolves obstacles, and keeps choices transparent
  • Security validation in system design and code changes

Tools and how they help

ToolWhat it solves
set_coding_taskCreates/updates task metadata; classifies task_size; returns next-step workflow guidance
get_current_coding_taskRecovers the latest task_id and metadata to resume work safely
judge_coding_planValidates plan/design; requires library selection and internal reuse maps; flags risks
judge_code_changeReviews unified Git diffs for correctness, reuse, security, and code quality
judge_testing_implementationValidates tests using real runner output and optional coverage
judge_coding_task_completionFinal gate ensuring plan, code, and tests approvals before completion
raise_missing_requirementsElicits missing details and decisions to unblock progress
raise_obstacleEngages the user on trade‑offs, constraints, and enforced changes

🚀 Quick Start

Requirements & Recommendations

MCP Client Prerequisites

MCP as a Judge is heavily dependent on MCP Sampling and MCP Elicitation features for its core functionality:

System Prerequisites
  • Docker Desktop / Python 3.13+ - Required for running the MCP server
Supported AI Assistants
AI AssistantPlatformMCP SupportStatusNotes
GitHub CopilotVisual Studio Code✅ FullRecommendedComplete MCP integration with sampling and elicitation
Claude Code-⚠️ PartialRequires LLM API keySampling Support feature request
Elicitation Support feature request
Cursor-⚠️ PartialRequires LLM API keyMCP support available, but sampling/elicitation limited
Augment-⚠️ PartialRequires LLM API keyMCP support available, but sampling/elicitation limited
Qodo-⚠️ PartialRequires LLM API keyMCP support available, but sampling/elicitation limited

✅ Recommended setup: GitHub Copilot + VS Code — full MCP sampling; no API key needed.

⚠️ Critical: For assistants without full MCP sampling (Cursor, Claude Code, Augment, Qodo), you MUST set LLM_API_KEY. Without it, the server cannot evaluate plans or code. See LLM API Configuration.

💡 Tip: Prefer large context models (≥ 1M tokens) for better analysis and judgments.

If the MCP server isn’t auto‑used

For troubleshooting, visit the FAQs section.

🔧 MCP Configuration

Configure MCP as a Judge in your MCP-enabled client:

Method 1: Using Docker (Recommended)

One‑click install for VS Code (MCP)

[Install for MCP as a Judge]

Notes:

  • VS Code controls the sampling model; select it via “MCP: List Servers → mcp-as-a-judge → Configure Model Access”.
  1. Configure MCP Settings:

    Add this to your MCP client configuration file:

    json
    {  "command": "docker",  "args": ["run", "--rm", "-i", "--pull=always", "ghcr.io/othervibes/mcp-as-a-judge:latest"],  "env": {    "LLM_API_KEY": "your-openai-api-key-here",    "LLM_MODEL_NAME": "gpt-4o-mini"  }}

    📝 Configuration Options (All Optional):

    • LLM_API_KEY: Optional for GitHub Copilot + VS Code (has built-in MCP sampling)
    • LLM_MODEL_NAME: Optional custom model (see Supported LLM Providers for defaults)
    • The --pull=always flag ensures you always get the latest version automatically

    Then manually update when needed:

    bash
    # Pull the latest versiondocker pull ghcr.io/othervibes/mcp-as-a-judge:latest

Method 2: Using uv

  1. Install the package:

    bash
    uv tool install mcp-as-a-judge
  2. Configure MCP Settings:

    The MCP server may be automatically detected by your MCP‑enabled client.

    📝 Notes:

    • No additional configuration needed for GitHub Copilot + VS Code (has built-in MCP sampling)
    • LLM_API_KEY is optional and can be set via environment variable if needed
  3. To update to the latest version:

    bash
    # Update MCP as a Judge to the latest versionuv tool upgrade mcp-as-a-judge

Select a sampling model in VS Code

  • Open Command Palette (Cmd/Ctrl+Shift+P) → “MCP: List Servers”
  • Select the configured server “mcp-as-a-judge”
  • Choose “Configure Model Access”
  • Check your preferred model(s) to enable sampling

🔑 LLM API Configuration (Optional)

For AI assistants without full MCP sampling support you can configure an LLM API key as a fallback. This ensures MCP as a Judge works even when the client doesn't support MCP sampling.

  • Set LLM_API_KEY (unified key). Vendor is auto-detected; optionally set LLM_MODEL_NAME to override the default.

Supported LLM Providers

RankProviderAPI Key FormatDefault ModelNotes
1OpenAIsk-...gpt-4.1Fast and reliable model optimized for speed
2Anthropicsk-ant-...claude-sonnet-4-20250514High-performance with exceptional reasoning
3GoogleAIza...gemini-2.5-proMost advanced model with built-in thinking
4Azure OpenAI[a-f0-9]{32}gpt-4.1Same as OpenAI but via Azure
5AWS BedrockAWS credentialsanthropic.claude-sonnet-4-20250514-v1:0Aligned with Anthropic
6Vertex AIService Account JSONgemini-2.5-proEnterprise Gemini via Google Cloud
7Groqgsk_...deepseek-r1Best reasoning model with speed advantage
8OpenRoutersk-or-...deepseek/deepseek-r1Best reasoning model available
9xAIxai-...grok-code-fast-1Latest coding-focused model (Aug 2025)
10Mistral[a-f0-9]{64}pixtral-largeMost advanced model (124B params)

Client-Specific Setup

Cursor
  1. Open Cursor Settings:

    • Go to File → Preferences → Cursor Settings
    • Navigate to the MCP tab
    • Click + Add to add a new MCP server
  2. Add MCP Server Configuration:

    json
    {  "command": "uv",  "args": ["tool", "run", "mcp-as-a-judge"],  "env": {    "LLM_API_KEY": "your-openai-api-key-here",    "LLM_MODEL_NAME": "gpt-4.1"  }}

    📝 Configuration Options:

    • LLM_API_KEY: Required for Cursor (limited MCP sampling)
    • LLM_MODEL_NAME: Optional custom model (see Supported LLM Providers for defaults)
Claude Code
  1. Add MCP Server via CLI:

    bash
    # Set environment variables first (optional model override)export LLM_API_KEY="your_api_key_here"export LLM_MODEL_NAME="claude-3-5-haiku"  # Optional: faster/cheaper model
    # Add MCP serverclaude mcp add mcp-as-a-judge -- uv tool run mcp-as-a-judge
  2. Alternative: Manual Configuration:

    • Create or edit ~/.config/claude-code/mcp_servers.json
    json
    {  "command": "uv",  "args": ["tool", "run", "mcp-as-a-judge"],  "env": {    "LLM_API_KEY": "your-anthropic-api-key-here",    "LLM_MODEL_NAME": "claude-3-5-haiku"  }}

    📝 Configuration Options:

    • LLM_API_KEY: Required for Claude Code (limited MCP sampling)
    • LLM_MODEL_NAME: Optional custom model (see Supported LLM Providers for defaults)
Other MCP Clients

For other MCP-compatible clients, use the standard MCP server configuration:

json
{  "command": "uv",  "args": ["tool", "run", "mcp-as-a-judge"],  "env": {    "LLM_API_KEY": "your-openai-api-key-here",    "LLM_MODEL_NAME": "gpt-5"  }}

📝 Configuration Options:

  • LLM_API_KEY: Required for most MCP clients (except GitHub Copilot + VS Code)
  • LLM_MODEL_NAME: Optional custom model (see Supported LLM Providers for defaults)

🔒 Privacy & Flexible AI Integration

🔑 MCP Sampling (Preferred) + LLM API Key Fallback

Primary Mode: MCP Sampling

  • All judgments are performed using MCP Sampling capability
  • No need to configure or pay for external LLM API services
  • Works directly with your MCP-compatible client's existing AI model
  • Currently supported by: GitHub Copilot + VS Code

Fallback Mode: LLM API Key

  • When MCP sampling is not available, the server can use LLM API keys
  • Supports multiple providers via LiteLLM: OpenAI, Anthropic, Google, Azure, Groq, Mistral, xAI
  • Automatic vendor detection from API key patterns
  • Default model selection per vendor when no model is specified

🛡️ Your Privacy Matters

  • The server runs locally on your machine
  • No data collection - your code and conversations stay private
  • No external API calls when using MCP Sampling. If you set LLM_API_KEY for fallback, the server will call your chosen LLM provider only to perform judgments (plan/code/test) with the evaluation content you provide.
  • Complete control over your development workflow and sensitive information

🤝 Contributing

We welcome contributions! Please see CONTRIBUTING.md for guidelines.

Development Setup

bash
# Clone the repositorygit clone https://github.com/OtherVibes/mcp-as-a-judge.gitcd mcp-as-a-judge
# Install dependencies with uvuv sync --all-extras --dev
# Install pre-commit hooksuv run pre-commit install
# Run testsuv run pytest
# Run all checksuv run pytest && uv run ruff check && uv run ruff format --check && uv run mypy src

© Concepts and Methodology

© 2025 OtherVibes and Zvi Fried. The "MCP as a Judge" concept, the "behavioral MCP" approach, the staged workflow (plan → code → test → completion), tool taxonomy/descriptions, and prompt templates are original work developed in this repository.

Prior Art and Attribution

While “LLM‑as‑a‑judge” is a broadly known idea, this repository defines the original “MCP as a Judge” behavioral MCP pattern by OtherVibes and Zvi Fried. It combines task‑centric workflow enforcement (plan → code → test → completion), explicit LLM‑based validations, and human‑in‑the‑loop elicitation, along with the prompt templates and tool taxonomy provided here. Please attribute as: “OtherVibes – MCP as a Judge (Zvi Fried)”.

❓ FAQ

How is “MCP as a Judge” different from rules/subagents in IDE assistants (GitHub Copilot, Cursor, Claude Code)?

FeatureIDE RulesSubagentsMCP as a Judge
Static behavior guidance✓✓✗
Custom system prompts✓✓✓
Project context integration✓✓✓
Specialized task handling✗✓✓
Active quality gates✗✗✓
Evidence-based validation✗✗✓
Approve/reject with feedback✗✗✓
Workflow enforcement✗✗✓
Cross-assistant compatibility✗✗✓

How does the Judge workflow relate to the tasklist? Why do we need both?

  • Tasklist = planning/organization: tracks tasks, priorities, and status. It doesn’t guarantee engineering quality or readiness.
  • Judge workflow = quality gates: enforces approvals for plan/design, code diffs, tests, and final completion. It demands real evidence (e.g., unified Git diffs and raw test output) and returns structured approvals and required improvements.
  • Together: Use the tasklist to organize work; use the Judge to decide when each stage is actually ready to proceed. The server also emits next_tool guidance to keep progress moving through the gates.

If the Judge isn’t used automatically, how do I force it?

  • In your prompt: "use mcp-as-a-judge" or "Evaluate plan/code/test using the MCP server mcp-as-a-judge".
  • VS Code: Command Palette → "MCP: List Servers" → ensure "mcp-as-a-judge" is listed and enabled.
  • Ensure the MCP server is running and, in your client, the judge tools are enabled/approved.

How do I select models for sampling in VS Code?

  • Open Command Palette (Cmd/Ctrl+Shift+P) → "MCP: List Servers"
  • Select "mcp-as-a-judge" → "Configure Model Access"
  • Check your preferred model(s) to enable sampling

📄 License

This project is licensed under the MIT License (see LICENSE).

🙏 Acknowledgments


來源:README.md,提交 896d48a

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.3.20最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分