AI Dictionary of Terms

Validation Set

A subset of data used to evaluate a model during the training process, specifically to tune hyperparameters and detect overfitting without touching the final test set.

The Simple Version

A practice exam taken during the semester. It helps the student (the model) figure out which study methods (hyperparameters) work best before taking the final, unseen exam (the test set).

Detailed Explanation

Machine learning data is typically split into three: Train, Validation, and Test. The model learns from the Training set. After each epoch, its performance is checked on the Validation set. This feedback loop is used to adjust hyperparameters (like learning rate or network depth) and implement early stopping. The Test set is kept completely hidden until the very end to provide an unbiased estimate of real-world performance.

Key Characteristics

Business Context

Real-World Analogy

A chef tasting the soup while cooking (validation) to add salt, versus serving it to the food critic (test) for the final review. You adjust based on the taste test, but the critic’s score is the only one that counts for the restaurant’s rating.

Code Example

# Conceptual: Splitting data into Train, Validation, and Test
from sklearn.model_selection import train_test_split

# X = features, y = labels
# First split: 80% train, 20% temp
X_train, X_temp, y_train, y_temp = train_test_split(X, y, test_size=0.2, random_state=42)

# Second split: 50% of temp becomes validation, 50% becomes test (10% each of total)
X_val, X_test, y_val, y_test = train_test_split(X_temp, y_temp, test_size=0.5, random_state=42)

# Model trains on X_train, tunes hyperparameters on X_val, final report on X_test.

Common Misconceptions

Sources & Further Reading