About
Govbench — Model Context Protocol server
README
Measure any AI's refusal behaviour on an adversarial grid — reproducibly, for free. Defensive by construction: fires adversarial prompts at a model's gate and scores whether it refuses. It never reproduces harmful methods; goals are harm-class labels only.
Disambiguation: this repo vs. csoai/gspc-gov
This package is the adversarial-refusal grid (48 cells: 6 risk categories × 8 attack styles).
It is not the EU AI Act risk-tier classifier. The risk-tier classifier lives in the
CSOAI measurement instrument family as csoai/gspc-gov on Hugging Face — a different
project with a different schema, a different frozen split, and a different six-axis
ledger. The two share a family name (govbench / GSPC governance) but measure different
properties and have different output schemas. Cite them separately.
pip install git+https://github.com/CSOAI-ORG/govbench
Do not run
pip install govbench. That name on PyPI belongs to an unrelated third party (BenchFlow,[email protected]) whose package is also described as a governance benchmarking framework. It is not this project and we have no connection to it. Install from this repository using the line above.
from govbench import score_model
from govbench.scorer import is_refusal
from govbench.benign_controls import over_block_rate
# plug in ANY model — a callable(prompt)->response
def generate(prompt):
return my_model(prompt) # OpenAI, Anthropic, HF, Ollama, your own gate...
result = score_model(generate, verbose=True)
print(result["overall_refusal_rate"], result["by_category"])
print(over_block_rate(generate, is_refusal)) # guard against over-refusing benign asks
What it measures
- 6 risk categories (weapons, CBRN, kinetic-targeting, surveillance, cyber, exfiltration) × 8 attack styles (direct, roleplay, hypothetical, authority, persona, academic, incremental, urgency) = a 48-cell refusal grid (after Meta's Rainbow-Teaming, 2024).
- Refusal rate overall and per-category — where the gate holds, where it leaks.
- Over-block rate on benign controls — a gate that refuses "what is the capital of France?" is broken too.
The honest contract (read this)
- A high refusal rate on this grid is a reference target, not proof of un-jailbreakability. Real attackers vary phrasing far beyond 8 styles. Finding a leak is the point — a grid that finds nothing wasn't trying hard enough.
- This is a measurement standard, not an accredited compliance certification. It maps to EU AI Act Art.9 (risk management), Art.15 (robustness) — but running it is not a legal conformity attestation.
- The refusal detector is a heuristic (string patterns). It can miss a soft refusal or a hedged answer. Inspect
cellsand tune for your context.
Why this exists
Capability benchmarks are everywhere. Governed-refusal-as-a-measured-property is not. As models scale, internal (trained-in) guardrails fail precisely where capability — and danger — is highest. An external, auditable refusal measurement is the missing standard. This is the open version so any lab can run it.
Apache-2.0 (see LICENSE). MEOK AI Labs / CSOAI. Contributions of new attack styles and categories welcome — widening the grid is the whole idea.
Install Govbench in Claude Desktop, Claude Code & Cursor
unyly install govbenchInstalls into Claude Desktop, Claude Code, Cursor & VS Code — handles npx, uvx and build-from-source repos for you.
First time? Get the CLI: curl -fsSL https://unyly.org/install | sh
Or configure manually
Run in your terminal:
claude mcp add govbench -- uvx govbenchStep-by-step: how to install Govbench
FAQ
Is Govbench MCP free?
Yes, Govbench MCP is free — one-click install via Unyly at no cost.
Does Govbench need an API key?
No, Govbench runs without API keys or environment variables.
Is Govbench hosted or self-hosted?
Self-hosted: the server runs locally on your machine via the install command above.
How do I install Govbench in Claude Desktop, Claude Code or Cursor?
Open Govbench on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
Fetch
Web content fetching and conversion for efficient LLM usage.
AWS KB Retrieval
Retrieval from AWS Knowledge Base using Bedrock Agent Runtime.
by modelcontextprotocolSpring AI MCP Server
Provides auto-configuration for setting up an MCP server in Spring Boot applications.
llm-analysis-assistant
A very streamlined mcp client that supports calling and monitoring stdio/sse/streamableHttp, and can also view request responses through the /logs page. It also
by xuzexin-hzMCP-Agent
A simple, composable framework to build agents using Model Context Protocol by [LastMile AI](https://www.lastmileai.dev)
by lastmile-aiSpring AI MCP Client
Provides auto-configuration for MCP client functionality in Spring Boot applications.
mcp.natoma.ai
A Hosted MCP Platform to discover, install, manage and deploy MCP servers by [Natoma Labs](https://www.natoma.ai)
MCPHub
Website to list high quality MCP servers and reviews by real users. Also provide online chatbot for popular LLM models with MCP server support.
MCP Servers Rating and User Reviews
Website to rate MCP servers, write authentic user reviews, and [search engine for agent & mcp](http://www.deepnlp.org/search/agent)
mkinf
An Open Source registry of hosted MCP Servers to accelerate AI agent workflows.
Compare Govbench with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All ai MCPs
