KatInterview

Designing a Content Moderation System for Prohibited Videos

Machine LearningModel answer
HardModel answerMachine Learningml-systemsclassificationimbalanced-data

Last updated

Design a production pipeline to detect harmful video content at scale, handling extreme imbalance, adversarial evasion, and human review workflows.

Context

Your platform hosts user-uploaded videos and needs to automatically identify content that violates platform policies. The system processes millions of daily uploads, but harmful content represents less than 0.01% of total volume. Malicious uploaders actively attempt to evade detection using techniques like frame manipulation, audio distortion, and re-encoding.

Your Task

Design an end-to-end machine learning system that classifies videos as violating, safe, or requiring manual review. Address these components:

1. Multimodal Design

Explain how you would architect a classifier that processes video frames, audio streams, and accompanying metadata (uploader history, title, tags). How should these signals be combined?

2. Handling Data Challenges

The training data suffers from severe class imbalance (harmful content is extremely rare), label noise from human annotators, and adversarial examples designed to fool detectors. Describe your training approach.

3. Review Workflow

You have limited human moderator capacity—perhaps 5,000 reviews per day. Design a policy that routes content to automatic approval, automatic blocking, or human review queues.

4. Production Monitoring

What metrics would you track beyond standard classification measures? How do you detect when the model is degrading or when adversaries are evolving their tactics?

Constraints

  • Initial screening decisions must complete within 500ms
  • Privacy regulations prohibit long-term storage of non-violating content
  • False positives damage user trust; missed violations cause platform harm

Expected Output Format

For a given video upload, your system should return:

  • A probability score indicating likelihood of violation
  • A routing decision: Auto-approve, Auto-block, or Send-to-review
  • Explanatory signals (which modality triggered the flag)
  • Model version for auditability

Hints

Hint 1

Start by quantifying the scale: at 0.01% prevalence with millions of uploads, even 99.9% specificity yields many false positives. Precision becomes more critical than recall.

Hint 2

Consider a multi-stage cascade: cheap filters first (hash lookups, lightweight models) that catch obvious cases, then expensive deep learning only on suspicious content.

Hint 3

Train your encoders to be invariant to adversarial transformations—use augmentations that mirror real evasion tactics during pretraining.