DocumentationRecipesReferenceChangelog
Log In
Documentation

How quality metrics are computed (private beta)

🚧

Private beta

This way of computing quality metrics is currently in private beta. It is available to selected customers on request, and it may change before general availability. To request access, contact your Kili representative.

On projects that use the new quality metrics computation, Kili compares two labels of the same asset annotation by annotation, with one method for consensus, review score, honeypot and model predictions. Every score is between 0% and 100%. Each pair of annotations gets its own score, so you can see where two labels disagree and why: in the Agreement dashboard, and pair by pair in the Diff view.

Before you start

  • Access: private beta. A project uses this computation when it is created after it was turned on for your organization, and keeps it. Projects created before keep the current computation.
  • Project types: Image, Geospatial, PDF and Text projects, with a multi-step or multi-group workflow.
  • Where scores show: the Queue page, Explore, the API and the Python SDK, as with the current computation, plus the Agreement dashboard and the Diff view.

What is compared, and when

An asset is finished when its current workflow step is done and the asset didn't move on to another step.

  • Consensus: once every labeler expected on the consensus step has submitted, each labeler's latest label is compared with each other's. The asset's consensus is the average of all these pairs. See Consensus overview.
  • Review score: when the asset finishes on a review step, the label of the first labeling step is compared with the review label that finished the asset. The score is kept on that labeling label. A review step that passes the asset to another step computes nothing, and an asset that finishes without review gets no review score. Review score isn't available on workflows with a consensus step or several work groups.
  • Honeypot: each label submitted on a step with honeypot on is compared with the asset's honeypot label. The asset's honeypot score is the average of its kept labels on that step: labels sent back or corrected don't count. See Honeypot overview.
  • Model predictions (inference labels): on finished assets only, the latest prediction of each model is compared with the label that finished the asset. A prediction imported on an asset that is already finished is compared with its last label right away. Each prediction keeps its own score; the asset shows the newest one.

When a score goes away

  • A label revised or sent back: the asset is no longer finished. All its review scores and model prediction scores are removed, and computed again when the asset finishes. A label of the consensus step takes the whole consensus away until every labeler has submitted again. A label of a honeypot step loses its own honeypot score, and the asset's average is recomputed.
  • Add to review removes no score.
  • A deleted asset keeps its scores in the Agreement dashboard, as past work.

How two labels are compared

Kili compares the two labels job by job, in three steps:

  1. Similarity: every annotation of one label is scored against every nearby annotation of the other, with the measure of its annotation type (below).
  2. Matching: annotations are paired one to one, so that the pairs' total similarity is the highest possible. Categories don't decide the matching: two annotations drawn at the same place with different classes are paired, and their class disagreement lowers their score. An annotation with no plausible counterpart stays unmatched.
  3. Job score: the pairs' scores are combined into one score per job, where every unmatched annotation (missed or extra) lowers the score.

The score of the two labels is the average of their job scores: every job weighs the same, whatever its number of annotations. A job that neither label answered is left out.

Similarity per annotation type

Annotation typeHow two annotations are compared
Bounding box, polygon, semantic maskOverlap: shared area divided by the area of their union (IoU)
PointDistance: identical points score 100%; points more than 10% of the asset's diagonal apart score 0%
LineAverage distance between the two lines; their direction and number of vertices don't matter
VectorStart against start and end against end: a vector drawn the other way round scores about 0%
PoseKeypoint by keypoint, between poses of the same class only
Named entity (Text)Share of the characters both selections cover: the same word at two places scores 0%
Named entity (PDF)Paired by the position of the selections, scored on their text
RelationShare of end objects in common, once their start objects are paired
ClassificationShare of categories in common (F1-score): a single-choice job scores 100% or 0%
Transcription100% minus the share of characters to change (normalized edit distance): Kili against Kilo scores 75%
Page-level classification or transcription (PDF)Page by page, the same page being a pair

The score of a pair of objects

For bounding boxes, polygons, masks, points, lines, named entities and relations, a pair's score combines three parts:

  • Shape, 50%: the similarity above.
  • Class, 25%: 100% when both labels chose the same class, 0% otherwise.
  • Nested jobs, 25%: the average score of the object's nested classification and transcription jobs.

When a job has a single class, or its class has no nested job, that part's weight goes to the shape. A job with one class and no nested job is scored on its shape alone.

The job score

The job score is twice the sum of the pairs' scores, divided by the number of annotations in both labels. A pair counts for its two annotations, and an unmatched annotation for one, at 0%.

Example (one class, shapes only)Job score
Both labels drew the same 3 boxes2 × 3 / (3 + 3) = 100%
Both drew 3 boxes, each pair overlapping at 80%2 × 2.4 / (3 + 3) = 80%
One label drew 3 boxes, the other the same 3 and an extra one2 × 3 / (3 + 4) = 86%
One label drew 3 boxes, the other none0%

Classification jobs

Nested classification answers count with their parent job, and a nested category counts with its own job. For example, under Rain, the questions Freezing? and Windy? both offer yes and no:

Label ALabel BScore
CarCar100%
CarTruck0%
Car, RedCar67%
Rain, Freezing: yes, Windy: yesRain, Freezing: yes, Windy: no67%

A nested transcription counts as a partial match when both labels answered it. When neither label selected anything, they agree: 100%.

Scores per class

Besides the score of each label pair, Kili scores each class:

  • Objects: each label's annotations of a class, with the score of their pair. A box one label called Car and the other Truck counts for Car on one side and Truck on the other, so a class that the two labels never agreed on can't reach 100%.
  • Classifications: categories are matched by name. A category selected in only one label is matched with nothing (∅). In a single-choice job, two different answers are a confusion between their two categories.

Classifications with nested classifications can be read three ways in the Agreement dashboard:

  • Root: the job's own categories (Rain against Cloudy).
  • Leaf: each full answer down to its deepest category (Rain › Heavy against Rain › Light).
  • Sub-job: one nested classification on its own, counted only where both labels selected its parent category. The classifications nested in objects are read this way too, on paired objects of the same class.

A multiple-choice answer is also read as one Combination: City + Parking against City is a disagreement, and the matrix diagonal gives how often the labels chose exactly the same set.

What is left out

  • Video, Audio and LLM projects, and projects on the legacy workflow.
  • Projects created before the computation was turned on: their scores keep the current rules and aren't recomputed.
  • Hidden jobs, and jobs excluded with isIgnoredForMetricsComputations (see Customizing the interface through JSON settings).
  • A score needs two labels: nothing is computed while one of them is missing.

How it differs from the current computation

Current computationThis computation
Several jobsAverage weighted by number of annotationsEvery job weighs the same
Nested jobs of an objectGeometric average: a wrong nested answer gives 0%25% of the object's score
An extra box (3 boxes against the same 3 and one more)75%86%
Multiple-choice classification (Red against Red, Blue)50%67% (F1-score)
Review score and model predictionsSee the current rulesFinished assets only

Related pages


Did this page help you?