Skip to main content

judge-kappa

CI codecov docstring coverage: 100% enforced dependencies: pip-audit in CI

Ruff mypy: strict pre-commit

PyPI Python versions License Wheel

Unified LLM evaluation that bridges agent-skills-eval (A/B uplift, assertion lists) and MLflow LLMaJ (datasets, named rubric dimensions) while adding statistical rigor missing from both.

Feature matrix

Capability agent-skills-eval MLflow LLMaJ judge-kappa
Native A/B uplift ✅ ❌ ✅
Assertion-based scoring ✅ ❌ ✅
Named rubric dimensions ❌ ✅ ✅
Multi-judge Panel / Jury ❌ ❌ ✅
Krippendorff's α + 95% CI ❌ ❌ ✅
ICC(2,k) variance decomposition ❌ ❌ ✅
Cohen's κ + P(chance) ❌ ❌ ✅
McNemar significance test for uplift ❌ ❌ ✅
Bootstrap CI for mean uplift ❌ ❌ ✅
ICL judge alignment (calibration examples) ❌ ❌ ✅
IRT-based judge weighting (2PL) ❌ ❌ ✅
Per-judge person-fit (outfit MNSQ) ❌ ❌ ✅
Positional bias detection ❌ ❌ ✅
Verbosity bias detection ❌ ❌ ✅
Differential Item Functioning (DIF) ❌ ❌ ✅
Behavioral alignment metric (DISC-style) ❌ ❌ ✅
Pairwise preference rates ❌ ❌ ✅
N-system Elo tournament (N ≤ 6) ❌ ❌ ✅
Order-aware BTL ratings + order-effect interval ❌ ❌ ✅
Unusable-reply accounting (data_quality) ❌ ❌ ✅
Run provenance + token usage on every report ❌ ❌ ✅
Response cache / checkpoint-resume ❌ ❌ ✅
Listwise ranking for N ≥ 7 (RankJudge) ❌ ❌ ✅
CLI-first ✅ ❌ ✅

Installation

# Core — no LLM providers
pip install judge-kappa
uv add judge-kappa

# With Anthropic support
pip install "judge-kappa[anthropic]"
uv add "judge-kappa[anthropic]"

# With OpenAI-compatible support (OpenAI, vLLM, Ollama, OpenRouter, Groq, Together)
pip install "judge-kappa[openai]"
uv add "judge-kappa[openai]"

# Both provider SDKs (OpenAI-compatible and Anthropic)
pip install "judge-kappa[all]"
uv add "judge-kappa[all]"

From source

git clone https://github.com/williamcaban/judge-kappa-eval
cd judge-kappa-eval

# Python 3.12+ required
uv sync --all-extras          # recommended
# or: pip install -e '.[all]'

API keys

export ANTHROPIC_API_KEY="sk-ant-..."
export OPENAI_API_KEY="sk-..."
# For local vLLM/Ollama, set base_url in the config instead of an API key

Quick start

# Validate a config
judge-kappa validate examples/config_skill_minimal.yaml

# Run evaluation
judge-kappa run examples/config_skill_minimal.yaml

# JSON output → file
judge-kappa run examples/config_skill.yaml --format json --output report.json

# Print config JSON Schema (for editor autocomplete)
judge-kappa schema

Runnable demos (no API key required)

# 6 psychometric methods: bootstrap CI, ICC, person-fit, DIF, behavioral alignment, McNemar
python examples/demo_psychometric.py

# IRT-based judge weighting from calibration data
python examples/demo_irt_weighting.py

# Listwise ranking for 8 systems (98% fewer judge calls than tournament)
python examples/demo_rank_judge.py

Documentation

Doc Contents
AGENTS.md Start here for agents/harnesses — repo identity, science table, quick-start, contributing rules
Decision guide Which mode to use — decision tree covering input format, judge strategy, bias detection, N systems, psychometric rigor, and providers
Input types All entry points: evaluate_skill, evaluate_dataset, evaluate_endpoints, evaluate_prerecorded, evaluate_pairwise_dataset, TournamentEvaluator, RankJudge
Pairwise, Tournament, and Listwise Pairwise preference, N-system Elo tournament, RankJudge (N ≥ 7), champion-challenger; cost tables; mode selection guide
Examples 14 worked examples: 9 YAML configs + 5 Python demos with expected output
Key management api_key_env three-case rule; provider quick reference; mixed-provider panel
CLI reference run, validate, schema commands; output formats; --verdicts flag; CI/CD integration
Python API 15 usage patterns; all new v0.2 patterns (McNemar, IRT weighting, RankJudge, DIF, behavioral alignment); report field reference
Config reference Every YAML field documented; skill/dataset/pairwise mode schemas
Architecture Package structure; ABCs and extension points; data flow diagram
Psychometric methods In-depth guide to all 9 psychometric capabilities: when to use, API, interpretation tables
Reliability and reproducibility Explicit request parameters, parse-failure accounting, run provenance and usage, response cache (checkpoint/resume), concurrency
Scholarly references 18 techniques × (description + in-library use + primary citations); consolidated bibliography

Example configs and scripts

File API key? What it demonstrates
examples/config_skill_minimal.yaml yes Single judge, fastest start
examples/config_skill.yaml yes 3-judge panel + ICL calibration + positional bias
examples/config_dataset.yaml yes Diverse JudgeJury with weighted rubric dimensions
examples/config_dataset_panel.yaml yes Homogeneous panel — rubric consistency check
examples/config_endpoints.yaml yes Per-variant generation backend (endpoint A vs B)
examples/config_prerecorded.yaml yes Score pre-recorded outputs (no generation calls)
examples/config_pairwise.yaml yes Pairwise preference rates (PairwiseReport)
examples/config_regulatory.yaml yes Full bias evidence for compliance submissions
examples/config_mixed_panel.yaml yes Anthropic + OpenRouter + vLLM + Ollama in one panel
examples/demo_psychometric.py no Bootstrap CI, ICC, person-fit, DIF, behavioral alignment, McNemar
examples/demo_irt_weighting.py no IRT 2PL judge weighting from calibration data
examples/demo_rank_judge.py no Listwise ranking for 8 systems (98% call reduction)

Development

uv sync --group dev
uv run pytest                                  # tests (151 pass, 0 fail)
uv run pytest --cov --cov-report=term-missing  # with coverage
uv run ruff check src tests                    # lint
uv run mypy src                                # type check

License

Apache 2.0 — github.com/williamcaban/judge-kappa-eval

Metadata

Release files for judge-kappa 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for judge-kappa 0.4.1
File Size Uploaded Provenance Actions
judge_kappa-0.4.1.tar.gz 221.5 kB With provenance Details for judge_kappa-0.4.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for judge-kappa 0.4.1
File Interpreter ABI Platform Actions
judge_kappa-0.4.1-py3-none-any.whl Python 3 none any Details for judge_kappa-0.4.1-py3-none-any.whl

Total release size: 327.7 kB

Release files / judge_kappa-0.4.1.tar.gz

Download URL judge_kappa-0.4.1.tar.gz
Size 221.5 kB
Tags Source
SHA-256 checksum
How to use checksums
31f160c3cc016896f18e4d6288000da233ba9ed5cbc74247afdedda6f42bbb9c
BLAKE2b-256 checksum
How to use checksums
c526897d34518993b12efac2ff19219803e207cf930fa2e5f14e04de704a8681
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

Release files / judge_kappa-0.4.1-py3-none-any.whl

Download URL judge_kappa-0.4.1-py3-none-any.whl
Size 106.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a2edd2e13ea0a34dd766e7a9abfe160debd3c99c3ca1f49f99a21424b0666f7a
BLAKE2b-256 checksum
How to use checksums
0d883dd5913356ad23e4910835b5169330485fff09d5b96c0a7d7f811bf8e22c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

Security for judge-kappa 0.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for judge_kappa-0.4.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 25, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page