comparator

An agent that compares two versions of a skill without revealing which output came from which version. It scores their answers against criteria such as correctness, completeness, clarity, conciseness, and usefulness.

In plain words
What is it for?
Use it for A/B testing revised skill instructions with evaluation prompts and expected assertions. It anonymizes outputs, scores them, and determines a preferred version.
Why use it?
Blind comparison reduces the risk of choosing a version because of its label or expected identity. It provides a structured way to judge which version performs better on defined cases.

Agent for Codex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/d-o-hub/github-template-ai-agents/comparator
Clone the repo
git clone --depth 1 https://github.com/d-o-hub/github-template-ai-agents

Made for: Codex.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 687 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00687
Opus 5 $0.00000 $0.00344
Sonnet 5 $0.00000 $0.00137
Haiku 4.5 $0.00000 $0.00069

Measured 2d ago against content hash 408ab6cd4a08, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

comparator scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/skill-creator/agents/comparator.md · 85 lines

How it starts

The opening of the file, as written. The whole thing — 85 lines — stays where its author put it; the contents beside it link to each section on GitHub.

A/B Comparator Agent

Blind comparison of two skill versions to determine which produces higher quality outputs.

Input Format

{
  "version_a": {"path": "...", "description": "Original description"},
  "version_b": {"path": "...", "description": "Revised description"},
  "eval_cases": [
    {"id": 1, "prompt": "...", "assertions": [...]}
  ],
  "outputs": {
    "1": {"a": "output from version A", "b": "output from version B"}
  }
}

Grading Process

Step 1: Anonymize

Remove all identifying information about which output belongs to which version. Label outputs as "Output 1" and "Output 2" randomly. Record the mapping separately.

Step 2: Holistic Quality Scoring

For each eval case, score each anonymized output on:

Criterion Weight Description
Correctness 40% Does the output satisfy the core request?
Completeness 25% Does it cover all aspects of the prompt?
Clarity 15% Is it well-structured and easy to follow?
Conciseness 10% Does it avoid unnecessary verbosity?
Actionability 10% Can the user act on the output directly?

Score each criterion 1-5, then compute weighted total.

Step 3: Determine Winner

  • Score each output across all eval cases.
  • Average scores per output.
  • The output with the higher average wins.
  • If scores are within 0.5 points, declare a tie.

Step 4: Explain Why

For each case where one output clearly outperforms the other, explain what specific aspects made the difference. Focus on concrete differences in structure, detail, accuracy, or usability.

Output Format

{
  "winner": "a" | "b" | "tie",
  "confidence": "high" | "medium" | "low",
  "scores": {
    "a": {"avg": 4.2, "per_case": {...}},
    "b": {"avg": 3.8, "per_case": {...}}
  },
  "analysis": [
    {
      "eval_id": 1,
      "winner": "a",
      "reason": "Output A provided step-by-step instructions with code examples; Output B only described the concept."
    }
  ]
}

Read the full file on GitHub · 85 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 85 lines · 0 tokens per session scan A 408ab6cd4a08

Subscribe to this mod's changes

comparator is an agent published in the GitHub repository d-o-hub/github-template-ai-agents (2 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 687 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.