Resolving Class Imbalance in Hate Speech Detection; A Virtue Ethics Analysis of Didi on its Role in Didi Hitch Murders

Hu, Jinming, School of Engineering and Applied Science, University of Virginia
Laugelli, Benjamin, EN-Engineering and Society, University of Virginia
Tian, Yuan, EN-Comp Science Dept, University of Virginia

My technical and STS research are both related to the negative effects of online
platforms on their users. My technical research focuses on hate speech on the social media
platform Twitter. It proposed and tested methods to identify hate speech tweets automatically
to improve the user experience. My STS research focuses on the rape cases on Didi Hitch, a
ride-hailing platform in China. It explored the ethical responsibilities of Didi as the platform
provider to protect its users. The technical work is about reducing the negative impact of
Twitter through software engineering, while the STS work is about examining the ethical
shortcomings of the engineering company Didi as a whole. The two works are on two
different platforms, but they share the mutual theme of investigating the problems of online
My technical research explores the idea of using machine learning to identify hateful
tweets, focusing on the problem of class imbalance in current data sets. My team analyzes
existing research and came up with a neural network better suited to our problem. We
proposed three different ways to fit a better neural network model given the skewed data sets.
We then evaluated the results and came up with a method that could achieve a higher F1
score than the state-of-art solutions. We aim to provide some new insights on tackling hate
speech on online platforms as well as general ideas for machine learning with imbalanced
data sets. We hope that our methods can help social media companies to better identify hate
speech and their platform and protect their users from such attacks.
My STS research focuses on the problems of another online platform Didi Hitch. My
work examines the rape cases on Didi Hitch rides in 2018 and analyzes Didi’s ethical
responsibilities using the virtue ethics framework. I used Pritchard’s list of virtues for
engineers as a guideline to make a moral judgement on Didi as an engineering company. My
analysis demonstrated that Didi showed a consistent absence of Pritchard’s virtue, making
them unethical in creating and running the Hitch platform. My paper aims to provide aspiring
engineers such as myself with better knowledge to evaluate the ethical implications of their
actions in the professional world.
These two projects allowed me to better understand the responsibilities of being a
software engineer. My technical work allowed me to understand the technical methods
available to make software that is safer for users. Similarly, the STS work enabled me to
evaluate the morality of creating softwares in the setting of a professional software company.
These projects allowed me to better understand the responsibilities of a software engineer and
would guide me as I start a career as a software engineer.

BS (Bachelor of Science)
Hate speech, Virtue Ethics, Didi Hitch, Natural Language Processing

School of Engineering and Applied Science Bachelor of Science in Computer Science
Technical Advisor: Yuan Tian
STS Advisor: Benjamin Laugelli
Technical Team Members: N/A

Issued Date: