Topic 1 of 5 · 4 min read
Writing clear labeling guidelines
Goal: Improve a labeling guide so two reviewers would label a borderline case the same way.
A labeling guide is a short written contract that tells every reviewer what each label means, so two people looking at the same output reach the same verdict. If the guide is vague, your human labels are noise, and every metric you compute from them is noise too.
Check yourself · 1 of 3
Which label definition can two reviewers apply the same way?
Why it matters
Human labels are the ground truth you use to check automated judges, compare prompts and decide whether a release is safe. Ask three colleagues "Is this answer helpful?" and you will get three different standards. The disagreement is not carelessness. The question was never defined.
How to write one
- Define each label in one sentence, in terms of what you can see. "Faithful: every claim in the answer appears in the retrieved passages." This is checkable. "Faithful: the answer feels grounded" is not.
- Write decision rules in order. Reviewers should follow a short checklist: first, is the answer on topic? If not, label Off-topic and stop. Next, does it contain a claim not in the sources? If yes, label Unfaithful.
- Split compound questions. "Accurate and polite" is two labels. A reviewer who sees an accurate but rude answer has no valid choice.
- Add worked examples. Two or three per label, taken from real traces, each with the label and a one-line reason.
- Add borderline cases. These are the examples where reasonable people hesitate. State the ruling and why. This section does most of the work.
- Version it. Put a version and a date at the top, and a changelog at the bottom. Labels made under version 1 and version 3 should not be mixed without noting it.
Before and after
Before: Label each reply Good or Bad. Good replies are helpful and correct.
Reviewers will disagree on a reply that is correct but long, or helpful but missing a caveat.
After: Label each reply Pass or Fail. Fail if any of these is true: it states a refund amount not in the policy text; it promises an action the bot cannot take; it ignores the customer's question. Otherwise Pass. Length, tone and typos do not matter for this label. Borderline: a reply that says "usually 5 to 7 days" when the policy says "within 7 days" is a Pass.
What goes wrong
- The guide grows into a manual nobody reads. Keep it to a few pages and move rare cases into the borderline list.
- Rules live in one person's head. The expert who wrote the examples leaves, and new reviewers drift.
- The guide is never changed after disagreements. Every case where reviewers split is a missing rule. Add it, bump the version, and re-label if needed.
Test a draft before you scale: give ten real outputs to two people who have not seen the guide, then compare their labels. Where they differ, the guide is the thing to fix.
Examples
A vague rule made testable
Before: Mark a summary Bad if it is misleading.
After: Mark a summary Fail if it (a) states a number, name or date that is not in the source, or (b) leaves out a risk the source calls critical. Wording, length and order do not count.
Two reviewers can now check the same two conditions against the same source.
A borderline case with a ruling
Case: The bot answers a billing question correctly, then adds an unrelated product recommendation.
Ruling: Pass for the correctness label. The recommendation is tracked under a separate Off-topic-extras label. Written down once, this stops each reviewer from inventing a rule.
Key points
- A labeling guide defines each label by what a reviewer can observe, not by how the output feels.
- Decision rules in a fixed order let two reviewers follow the same path to the same label.
- Worked examples and a borderline-case section carry most of the guide's value.
- Each question should ask one thing; a compound label like accurate and polite forces unfair choices.
- Version the guide and record changes, so labels made under different rules are not silently mixed.
Common mistakes
- Defining labels with feelings or adjectives such as helpful, natural or good.
- Bundling several qualities into one pass or fail label.
- Giving only easy examples and no borderline cases.
- Editing the guide without a version number or a changelog.
Check yourself · 2 of 3
Reviewers keep splitting on replies that are correct but rude, under a single label 'Good reply'. What is the best fix to the guide?
Check yourself · 3 of 3
Your guide is at version 2 and you fix a rule. What should you do with the change?
Practice items, not counted towards your mastery.
Start here
- Cohen's kappa (Wikipedia) (opens in a new tab)ArticleFree
The formula, a worked example and the caveats about prevalence and the common interpretation bands.
- Krippendorff's alpha (Wikipedia) (opens in a new tab)ArticleFree
Agreement for more than two reviewers, missing labels and non-binary scales.
- cohen_kappa_score (scikit-learn) (opens in a new tab)DocsFree
One function call that computes kappa from two lists of labels.
More for this topic
- Your AI product needs evals (Hamel Husain) (opens in a new tab)ArticleFree
Why the domain expert should look at real traces and build a simple viewer around them.