# LLM-as-Judge Graders

> Use a model with a clear rubric to grade open-ended outputs, and calibrate it against human judgments so its scores mean something. Free notes, key concepts,...

Canonical: https://www.internhack.in/roadmaps/tracks/ai-engineer/llm-as-judge
Last updated: 2026-11-28

Use a model with a clear rubric to grade open-ended outputs, and calibrate it against human judgments so its scores mean something.

Intermediate · about 4 hours · difficulty 3/5

Learn first: [Building Golden Datasets](https://www.internhack.in/roadmaps/tracks/ai-engineer/golden-datasets), [Structured Outputs and JSON Schema](https://www.internhack.in/roadmaps/tracks/ai-engineer/structured-outputs)

When there is no single correct answer, a **model grader** can score outputs at scale. Done well it agrees with humans most of the time; done badly it produces confident nonsense.

### Designing a judge

- **Specific rubric**: "Does the answer mention the refund window? Does it cite a source? Is it under 120 words?" beats "rate helpfulness 1 to 10".
- **Binary or small scales**: pass/fail or a 3 point scale is more consistent than 1 to 10.
- **Reasoning before verdict**: ask the judge to explain briefly and then output a structured score.
- **Reference answers** when available make grading far more reliable.
- **Pairwise comparison** ("which of A or B is better?") is useful when comparing two prompt versions.

### Known biases

Judges tend to favour longer answers, the first option in a pair, and outputs from their own model family. Mitigate by swapping order, using length limits in the rubric and checking with a different model.

### Calibration

Label 50 to 100 outputs yourself, run the judge on them, and measure **agreement**. Iterate on the rubric until agreement is high, and re-check whenever you change the judge model. Track precision and recall on the "fail" class, since missed failures are what hurt.

### Good enough to move on

You have a judge prompt with a written rubric, structured output and a measured agreement rate with your own labels, and you can explain where it disagrees and why.

## Key concepts

- **Rubric design**
- **Binary vs scaled scores**
- **Reference-guided grading**
- **Pairwise comparison**
- **Judge biases and mitigations**
- **Calibrating against human labels**

## Mini project

Write a faithfulness judge for your RAG app that checks whether every claim is supported by retrieved context, label 60 answers yourself, and report the judge's agreement, false passes and false fails.

## Check yourself

Your judge passes 98% of outputs. What experiment tells you whether the judge is too lenient?

## Free resources

- [Anthropic docs: grading with models](https://docs.anthropic.com/en/docs/test-and-evaluate/develop-tests) (Anthropic)
- [Judging LLM-as-a-Judge (MT-Bench paper)](https://arxiv.org/abs/2306.05685) (arXiv)

Previous: [Building Golden Datasets](https://www.internhack.in/roadmaps/tracks/ai-engineer/golden-datasets) · Next: [Regression Testing and Evals in CI](https://www.internhack.in/roadmaps/tracks/ai-engineer/eval-driven-development)

## More in Evaluation and Observability

- [Why and How to Evaluate LLM Apps](https://www.internhack.in/roadmaps/tracks/ai-engineer/eval-fundamentals)
- [Building Golden Datasets](https://www.internhack.in/roadmaps/tracks/ai-engineer/golden-datasets)
- [LLM-as-Judge Graders](https://www.internhack.in/roadmaps/tracks/ai-engineer/llm-as-judge)
- [Regression Testing and Evals in CI](https://www.internhack.in/roadmaps/tracks/ai-engineer/eval-driven-development)
- [Tracing and LLM Observability](https://www.internhack.in/roadmaps/tracks/ai-engineer/tracing-observability)
- [Production Feedback and Online Evaluation](https://www.internhack.in/roadmaps/tracks/ai-engineer/online-evaluation)

## Related

- [Roadmaps](https://www.internhack.in/roadmaps)
- [AI Engineer Roadmap](https://www.internhack.in/roadmaps/tracks/ai-engineer)
