Data collection and size

I came across
The app needs just 5 images (per label) to train the model. How is it possible? Per the course and in-general, the AI projects recommend lots of data/images and labeling to get the model accuracy and the project work right.

One think, I noticed on thing: it is not that great with just 5 images. I can easily say this because with my face in the same position, same lighting, I tried to train “wink” and "not winking’ facial expressions.
It wasn’t great in detecting the expressions while in use although the trained model says its 100% on the test data.

Using validation data will give you a better view of the actual model performance Does it offer an option for splitting data into train and validation sets ?