First, the key terms.

Feature
A measured input available when a prediction is made.
Label or target
The output the training process is asked to predict.

The idea, explained

Classification predicts a category; regression predicts a numerical quantity. A label is not automatically objective truth: it might be a human judgment, a noisy measurement or a past organizational decision. Training minimizes a chosen loss, so the target and loss must match the intended task. Evaluation should use examples the model did not learn from, preferably representing the people, timing and conditions of actual use.

STEP 1

Define the prediction moment

For a delivery forecast, choose when the prediction must be made: perhaps at dispatch. Only information available then should be used. Arrival scans collected later cannot be legitimate dispatch-time features.

STEP 2

Choose the target

“Late or on time” is a category; “minutes late” is a number. These are different tasks even if they use the same deliveries. A target such as customer satisfaction may be noisy or unavailable for many cases.

STEP 3

Check what labels mean

Labels are produced by a process. A late scanner upload can create an incorrect “late” label. Before choosing an advanced algorithm, inspect how outcomes are recorded and whether the labels match the operational definition.

Follow a worked example.

For a delivery service, predicting whether a parcel is late is classification. Predicting minutes of delay is regression. Labels based on old delivery scans may be wrong if a scanner recorded the event hours after arrival.

Walk it through, one step at a time

  1. Write one example: distance 8 km, dispatched at 9 AM, forecast rain, actual delay 6 minutes.
  2. For regression, the target is 6. For a classifier defining late as more than 5 minutes, the label is “late.”
  3. Create a separate example with delay 3 minutes. It has a different numerical target but the same “on time” category as a zero-delay example.

Where people get stuck

A large labeled dataset can systematically teach the wrong target.

Now try it yourself.

Pause before opening each answer. Explain your reasoning in your own words.

1. Check the core idea

Is predicting a house price classification or regression?

Reveal the answer & reasoning

Regression, because the output is a numerical amount. Predicting a price band instead would be classification.

2. Apply what you learned

Would changing the definition of “late” from 5 minutes to 10 minutes change the task?

Reveal the answer & reasoning

Yes. Some category labels would change even though the deliveries themselves did not. The model must be evaluated against the definition the service actually intends to use.