Skip to main content
Skip to main content

Drupal AI

NSFW protection

Stop not-safe-for-work images at upload with a free image classification model from Hugging Face and the AI Validations module.

About this video

In this video we will showcase how to use the AI module to set up field validations on your image fields, so people can't upload NSFW images.

NOTE: This will showcase a mild NSFW image of Justin Bieber in underwear from his Calvin Klein campaign.

This will use the AI Validations submodule in the AI module and the Field Validation module, together with the Falconsai/nsfw_image_detection model from Hugging Face, to make sure that you can't upload bad images.

It's very simple to set up and very powerful.

Links:
FreelyGive: https://freelygive.io/
Drupal AI module: https://www.drupal.org/project/ai
Frederik Wouters: https://www.drupal.org/u/wouters_f
Hugging Face model: https://huggingface.co/Falconsai/nsfw_image_detection
Field Validation: https://www.drupal.org/project/field_validation

Watch the video

0:00

Transcript

YouTube's automatic captions, lightly corrected. Click a line to jump to that moment in the video.

Chapters

Updated 1 min read

Other ways to consume this

Filed under Workflows Drupal AI
AI modified

Parts of this content were produced by AI.

How was AI used?

The video and the introduction are Marcus's own, first published on workflows-of-ai.com. AI wrote the subtitle, the summary and the video chapters from the transcript, and corrected misheard names in YouTube's automatic captions.