Data annotation is the work of putting "correct answers" on raw data. A person, or a system, looks at an example and records what it represents. These labeled examples teach the model.

How it works

Everything starts with raw data: photos, sentences, audio or records. The team defines an annotation guide, which explains the categories and how to decide in doubtful cases. Then annotators apply the markings.

There are common types of annotation:

  • Classification: saying if an email is spam or not.
  • Entity labeling: marking names of people and companies in a text.
  • Boxes and contours: drawing the limit of objects in images.
  • Transcription: converting audio to text.
  • Response evaluation: comparing responses from a model and pointing out the best, used in adjustments by human feedback.

Quality matters more than quantity. To ensure this, several annotators label the same item and the team measures the degree of agreement between them. Divergences show where the guide is confusing.

Practical example

A store wants a model that separates customer messages into "question", "complaint" and "praise". The team gathers a few hundred real messages and labels each one. The format can be simple:

JSON · dados/mensagens.json
[
  { "texto": "Meu pedido não chegou", "rotulo": "reclamacao" },
  { "texto": "Qual o horário de atendimento?", "rotulo": "duvida" },
  { "texto": "Adorei o produto", "rotulo": "elogio" }
]

With these examples, it is possible to train a classifier or fine-tune a language model. They also serve as a test set to measure the accuracy of the result.

What it's for

Annotation is used for supervised learning, where the model learns by comparing its predictions with correct labels. It is also used to evaluate models, creating reliable test sets.

In fine-tuning language models, annotated data with good instructions and responses improves behavior on specific tasks for your business.

Care

Bad labels generate bad models. It is also necessary to take care of biases: if annotators or data do not represent users well, the model inherits the problem.

Finally, respect privacy. Data with personal information must be handled in accordance with LGPD, and often needs to be anonymized before being sent to annotators.