Search Benchmark logo

Search Benchmark

Organization
agentic-community
search-benchmark

Generate a search quality benchmark for the AI Registry. Generates ground truth from the registry's assets, runs 100+ queries against the semantic search API, evaluates results using NDCG@10/MRR/Recall, and produces a markdown report. Use when you want to measure search quality after changes to the scoring algorithm, embedding model, or indexed content.

Overview

Publisheragentic-community
Repositorymcp-gateway-registry
Skill namesearch-benchmark
Stars
969
Forks
244
Bundled files
Instructions only
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by agentic-community on GitHub. Read the source before you install it.

Installation

Install the Search Benchmark AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/agentic-community/mcp-gateway-registry/tree/main/.claude/skills/search-benchmark
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/agentic-community/mcp-gateway-registry.git /tmp/mcp-gateway-registry
mkdir -p .claude/skills
cp -r /tmp/mcp-gateway-registry/.claude/skills/search-benchmark .claude/skills/search-benchmark
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Search Benchmark in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Search Benchmark on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Search Benchmark is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Search Benchmark Skill

Measure semantic search quality against a deployed AI Registry. Generates a ground truth dataset from the registry's own assets, runs queries against the live API, evaluates results using standard information retrieval metrics (NDCG@10, MRR, Recall@10), and produces a markdown report.

Prerequisites

  1. Registry URL - The base URL of the deployed registry (e.g., https://d2xl2zfuhgc4l0.cloudfront.net)
  2. JWT Token - A valid admin token in .token file (get from "Get JWT Token" button in registry UI)
  3. Registry must have assets indexed - At least some servers, agents, or skills registered

The .token file supports both raw JWT format and the full JSON response from the registry UI.

Input

/search-benchmark [REGISTRY_URL] [TOKEN_FILE]
  • REGISTRY_URL - Base URL of the registry to benchmark (default: reads from user or uses http://localhost)
  • TOKEN_FILE - Path to the token file (default: .token)

Workflow

Step 1: Check for Existing Ground Truth

Check if a ground truth dataset already exists:

bash
ls tests/fixtures/search_dataset/ground_truth.json 2>/dev/null

If the file exists, report how many queries it contains and ask the user: "A ground truth dataset already exists (N queries). Do you want to use it or generate a new one from this registry?"

  • If use existing: skip to Step 2
  • If generate new: proceed to Step 1b

Step 1b: Generate Expert Ground Truth

This is NOT a simple programmatic generation. You must deeply analyze the registry's assets and craft queries like a search expert. Follow this process:

1b.1: Fetch all assets as JSON

bash
TOKEN=$(python3 -c "
import json
with open('{TOKEN_FILE}') as f:
    raw = f.read().strip()
if raw.startswith('{'):
    data = json.loads(raw)
    print(data.get('tokens',{}).get('access_token') or data.get('access_token',''))
else:
    print(raw.replace('Bearer ',''))
")

curl -s -H "Authorization: Bearer $TOKEN" "{REGISTRY_URL}/api/servers?limit=2000" > /tmp/servers.json
curl -s -H "Authorization: Bearer $TOKEN" "{REGISTRY_URL}/api/agents?limit=2000" > /tmp/agents.json
curl -s -H "Authorization: Bearer $TOKEN" "{REGISTRY_URL}/api/skills?limit=2000" > /tmp/skills.json

1b.2: Analyze the assets deeply

Read the JSON dumps. Filter out stress-test and security-pending assets. For each real asset, understand:

  • What it does (from description)
  • What tools it has (tool names and descriptions)
  • What tags it uses
  • How users would naturally search for it

1b.3: Craft 100 queries across these categories

CategoryCountStrategy
exact-name10Product/server/agent names as queries
semantic15Natural language paraphrases with NO keyword overlap
tool-precision10Exact tool names as queries
tag-based10Tag vocabulary combinations
multi-entity10Queries where correct answers span servers + agents + skills
conflict10Ambiguous terms where vector and keyword disagree
no-answer10Queries completely outside the dataset (no match exists)
agent-focused10Queries specifically targeting agents
skill-focused10Queries specifically targeting skills
tricky15Edge cases, short queries, non-English, adversarial

1b.4: For each query, define expected results

json
{
  "query": "the search query",
  "category": "one of the categories above",
  "description": "what this query tests and why",
  "expected": [
    {"path": "/exact-path-from-registry", "grade": 3, "reason": "why this should match"},
    {"path": "/another-path", "grade": 2, "reason": "why this is relevant but not perfect"}
  ]
}

Grade scale: 3 = perfect match, 2 = highly relevant, 1 = somewhat relevant. For no-answer queries, expected should be an empty list.

1b.5: Validate all paths exist

Every path in expected results must exist in the fetched assets. Verify before saving.

1b.6: Save

Write the ground truth to tests/fixtures/search_dataset/ground_truth.json.

Tell the user how many queries were created per category and that they should review it.

Step 2: Run Benchmark

Run all queries against the live semantic search API and generate a report:

bash
uv run python scripts/benchmark_search.py \
    --url {REGISTRY_URL} \
    --token-file {TOKEN_FILE} \
    --queries tests/fixtures/search_dataset/generated_ground_truth.json

Output:

  • tests/fixtures/search_dataset/benchmark_results.json (raw results)
  • tests/fixtures/search_dataset/benchmark_results.md (markdown report)

Step 3: Review Report

Show the user the key metrics from the report:

  1. Quality Metrics - NDCG@10 > 0.7 is good, > 0.8 is excellent
  2. Score Health - Saturated scores at 1.0 should be < 15% (if higher, scoring formula may have issues)
  3. Quality by Category - Identify weak areas (e.g., agent-focused queries underperforming)
  4. Per-query results - Check specific queries that scored 0.0 (complete miss) or low NDCG

Open the report in the editor for the user to review.

Step 4: Compare Before/After (Optional)

If asked to compare two runs (e.g., before and after a scoring algorithm change):

bash
uv run python scripts/benchmark_search.py \
    --compare tests/fixtures/search_dataset/benchmark_results.json other_results.json

Output Format

The report includes:

  • Registry metadata: version, database backend, server/agent/skill counts
  • Quality Metrics: NDCG@10, MRR, Recall@10 averaged across all queries
  • Score Health: saturation analysis (unique scores, % at 1.0, range)
  • Quality by Category: breakdown per query type
  • Per-query results: top 5 results with scores and ground truth comparison

Interpreting Metrics

MetricGoodExcellentPoor
NDCG@10> 0.65> 0.80< 0.50
MRR> 0.70> 0.85< 0.50
Recall@10> 0.75> 0.90< 0.60
Score saturation< 15%< 5%> 30%

Example

$ /search-benchmark https://d2xl2zfuhgc4l0.cloudfront.net .token

This will:

  1. Generate ~90 queries from the registry's assets
  2. Run each query against the semantic search API
  3. Produce a report showing search quality metrics
  4. Open the report for review

Troubleshooting

  • 401 errors: Token expired. Get a fresh one from the registry UI "Get JWT Token" button.
  • 0 assets found: Registry has no servers/agents/skills registered, or token lacks permissions.
  • Low NDCG on "description-derived" category: Expected for programmatically generated queries. Add hand-curated queries for better evaluation.
  • High saturation (>30% at 1.0): Scoring formula may be using the legacy additive method. Set SEARCH_FUSION_METHOD=rrf on the registry.

Related

Frequently asked questions

What does the Search Benchmark AI skill do?

Generate a search quality benchmark for the AI Registry. Generates ground truth from the registry's assets, runs 100+ queries against the semantic search API, evaluates results using NDCG@10/MRR/Recall, and produces a markdown report. Use when you want to measure search quality after changes to the scoring algorithm, embedding model, or indexed content.

Why use Search Benchmark on TypingMind?

Because you install it once and use it with any model. Search Benchmark is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Search Benchmark in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/agentic-community/mcp-gateway-registry/tree/main/.claude/skills/search-benchmark. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Search Benchmark?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Search Benchmark?

As many as you like. As long as a model supports skills, you can use Search Benchmark with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Search Benchmark AI skill free?

Yes. It is published on GitHub by agentic-community under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇