← All projects

04 / NLP · BSC RESEARCH

Fair Play.

Reducing the time harmful content stays online.

  • Python
  • scikit-learn
  • XGBoost
  • Flask
Explore the project ↓
Comments collected
19,282
Reported enhanced-feature F1
0.82

Recorded dissertation results. Evaluation details and limitations are explained below.

CONTEXT

BSc Computer Science · Goldsmiths, University of London

MY ROLE

Research, dataset preparation, modelling and web prototype

ON THIS PAGE

01 / THE QUESTION

Harmful content stays visible too long.

Harmful and abusive content can remain visible while it waits for human moderation. I was particularly concerned about young, impressionable people encountering that content. Fair Play aimed to reduce this exposure by exploring an automated moderation tool that could identify harmful comments and enable a faster response than slow human review.

My contribution

I investigated harmful-language classification as the basis for faster moderation in football discussions. I collected 19,282 comments from r/soccer, used an initial model to assist labelling, manually reviewed the labels and compared Logistic Regression, Random Forest and XGBoost. I also built a Flask-backed interface to make the models accessible through a browser.

02 / GET A FEEL FOR IT

What actually improved the model?

Explore the recorded experiment comparisons. Choose a model and a feature set to see how precision, recall and F1 changed for the harmful-comment class.

EXPERIMENT EXPLORERRecorded results
02 / Compare feature sets

Same problem. Different representations.
Select an approach to compare the trade-offs.

HARMFUL CLASS / F1 SCORE0.63
Baseline
Precision0.57
Recall0.71
F1 score0.63

TF-IDF with stemming. A baseline for comparing more elaborate feature sets.

Source: BSc Final Report · Feature-comparison tables · No live model inference

03 / HOW I APPROACHED IT

The decisions
behind the work.

01Build a relevant dataset

Twitter access constraints led me to Reddit. I collected comments from 13 discussion threads over four weeks, keeping the data collection focused on football discussion.

02Look beyond accuracy

Only 3,131 of the 19,282 comments were labelled harmful. With an 84/16 class split, a model could look accurate while missing the comments that mattered. I focused on minority-class precision, recall and F1.

03Let experiments change the approach

Word2Vec, lexical and topic features underperformed the TF-IDF baseline in these experiments. N-grams and profanity-count features improved the reported F1. SMOTE and random undersampling did not improve the results.

04Connect research to an interface

The repository contains a Flask classification endpoint loading exported models and vectorizers. The prototype is a useful starting point; reliable deployment also requires matching training-time preprocessing and feature construction at inference.

04 / THE FULL PICTURE

Evidence &
limitations.

What this shows

Values are transcribed from the feature-comparison tables in the BSc Final Report. The enhanced-feature table reports precision 0.98, recall 0.70 and F1 0.82 for all three models. The abstract separately reports 0.99 precision for Logistic Regression; that later figure is not substituted into this comparison.

What to keep in mind

The aim was faster moderation and reduced exposure to harmful content. The experiments evaluate classification; they do not establish faster real-world removal than human moderators or measure reduced exposure among young people. The dataset comes from a single community and labels involve judgement. Reported recall of around 0.70 means many harmful comments were still missed. The explorer presents recorded results, not live inference or production moderation performance.

ANOTHER SIDE OF MY WORK

Radar

Data pipelines · Business tools