Automated Eval Harness & Judge Calibration
Cloud AI Evaluation & Azure AI Foundry QE β Day 2
Score groundedness, relevance, and coherence with deterministic rubrics, calibrate judge-vs-human agreement using Cohenβs kappa, and detect position and verbosity bias.
An uncalibrated LLM-as-a-Judge can rubber-stamp hallucinated policy guidance or systematically favor longer, padded answers. Today you will run rubric scoring for groundedness, relevance, and coherence, compute Cohen's kappa against human SME labels, and run automated A/B swap tests for position and verbosity bias.
The official reference codebase for Day 2 is hosted in the repository. Clone the repository and navigate to day-2-eval-harness-judge/test_eval_harness.py to run the working solution.
git clone https://github.com/777abhi/cloud-ai-eval-roadmap.git
cd cloud-ai-eval-roadmap/day-2-eval-harness-judge/test_eval_harness.pyRun Judge Calibration & Bias Detection Suite
npm run test:day2kappa = cohens_kappa(judge_labels, human_labels)
pos_audit = detect_position_bias(pairs, judge.compare_pair)
verb_audit = detect_verbosity_bias(concise_vs_verbose, judge.compare_pair)- Evaluated groundedness, relevance, and coherence on 1-5 rubrics to catch hallucinated claims.
- Measured judge-vs-human inter-rater reliability with Cohenβs kappa (>= 0.70 SLO).
- Detected position flip bias via (A, B) vs (B, A) swaps and verbosity bias on padded answers.
π§ Knowledge Check
How does swapping candidate order from (A, B) to (B, A) expose position bias in a Model-as-Judge evaluator?