Fairness-Aware Online Positive-Unlabeled Learning (2024)

Abstract: Machine learning applications for text classification are increasingly used in domains such as toxicity and misinformation detection in online settings. However, obtaining precisely labeled data for training remains challenging, particularly because not all problematic instances are reported. Positive-Unlabeled (PU) learning, which uses only labeled positive and unlabeled samples, offers a solution for these scenarios. A significant concern in PU learning, especially in online settings, is fairness: specific groups may be disproportionately classified as problematic. Despite its importance, this issue has not been explicitly addressed in research. This paper aims to bridge this gap by investigating the fairness of PU learning in both offline and online settings. We propose a novel approach to achieve more equitable results by extending PU learning methods to online learning for both linear and non-linear classifiers and analyzing the impact of the online setting on fairness. Our approach incorporates a convex fairness constraint during training, applicable to both offline and online PU learning. Our solution is theoretically robust, and experimental results demonstrate its efficacy in improving fairness in PU learning in text classification.

## introduction a classification system with machine learning for text data has been developed widely for various application such as toxicity classification @xcite @xcite and misinformation detection @xcite . however, obtaining precisely labeled data for training can be an arduous task @xcite , and the absence of positivity does not automatically equate to negativity in some cases @xcite . for example, in both toxicity and misinformation detection, only part of textual contents containing toxicity or misinformation are reported as concerns, as illustrated in fig. 1 . positive-unlabeled (pu) learning @xcite @xcite aims to learn from this incomplete information and achieve reliable classification by using only labeled-positive and unlabeled samples, where the unlabeled samples are permitted to be classified as either positive or negative. furthermore, we acknowledge the necessity of an online learning framework in pu learning. firstly, integrating pu learning with online learning can effectively address real-world challenges @xcite , when a machine learning system operates in dynamic environments where new data is continuously arriving. for example, as visualized in fig. 1 , the patterns of toxicity or misinformation evolve online, so the machine learning system needs to keep training on newly arrived data with new patterns, while only a few documents are reported as concerns. however, offline batch training is inadequate to sequentially provided data, as retraining the system from scratch with all the data is costly @xcite , while unreported cases might also possess the potential for positivity (de @xcite , necessitating the utilization of a pu learning framework in online scenario @xcite . however, pu learning faces a significant fairness issue by disproportionately predicting certain groups as positive based on factors such as gender, race, and the presence of specific features. fairness concerns in pu learning stem from two different perspectives. first, the training data might naturally contain biases. for example, in the wikipedia talk dataset @xcite for toxicity classification, 36.03% of documents with sexuality terms contain toxicity, whereas only 9.28% of documents without sexuality terms are toxicity documents. a pu learning-based automated toxicity classification system might overly depend on the existence of sexuality terms, resulting in unfair predictions by misleading to an in-figure 1 : online positive-unlabeled (pu) learning is an effective framework for toxicity classification in social networks, where only a subset of positive (reported toxicity) samples are labeled and there exist unlabeled positive (non-reported toxicity), and the data pool evolves over time. however, online pu learning may encounter fairness challenges due to prevalent biases in the data, where contents with identity terms have higher chances of toxicity compared to those without identity terms, as well as the long-term constraints inherent in online learning. furthermore, online learning may encounter fairness issues due to its long-term constraint @xcite . the original data's uneven distribution across sensitive groups means each incremental stage might have few or no samples from certain subgroups, especially with limited positive samples. such imbalances can reduce diversity in each incremental stage. the incrementally provided data may not accurately reflect the overall distribution, potentially leading to a higher false positive rate and more unfair predictions. in fig. 2 (c ), the comparison between the solid bar (offline) and the hatched bar (online) demonstrates that online learning can worsen fairness issues in pu learning. in short, online pu learning suffers from twofold fairness violations due to both 1) pu learning and 2) online learning. wu and he (2022) first addressed fairness in pu learning, but the reason of bias in pu learning was not extensively studied. additionally, wu and he (2022) relies on the selected completely at random (scar) assumption @xcite , which could be unrealistic in practice. @xcite proposed an online pu learning framework, but it didn't discuss fairness issue in pu learning and was limited to linear classifiers. overall, fairness in offline pu learning is largely unexplored, and no research explicitly addresses fairness in online pu learning, making it a pressing concern. in this paper, we firstly address this gap by studying fairness in pu learning and extend it to the online framework by introducing a convex fairness constraint ensuring equalized odds fairness, while maintaining the model's prediction capacity. specifically, we apply pu learning methods to online learning for linear, multilayer perceptron (mlp), and long short-term memory (lstm) (graves and graves, 2012) classifiers, analyzing the impact of the online setting on fairness by defining the concept of fair regret. our proposed approach, fairness-aware online positive-unlabeled learning (fopu) is theoretically grounded, and we provide experimental results to demonstrate its efficacy in enhancing fairness in pu learning. to this end, this paper offers a practical framework for implementing fairer online learning applications for text classification across various real-world contexts. we validate the effectiveness of our approach through extensive experimental results, ensuring fairness without compromising its utility, i.e., f1-score. positive-unlabeled learning. @xcite assumes that labeled examples are selected completely at random (scar) from the entire body of positive samples. however, the assumption of scar is unrealistic in practice @xcite , and overestimates the true class prior @xcite and @xcite suggested optimizing pu risk estimators using true class prior by converting the negative empirical risk to unlabeled empirical risk. moreover, various types of pu frameworks are suggested utilizing label distribution @xcite , data-reweighing @xcite , and data augmentation @xcite . online learning. online gradient descent (ogd) @xcite is a fundamental technique in online learning, while only linear classifier is considered in @xcite . @xcite suggested online deep learning making online learning for a neural network. in this paper, we apply the same strategy @xcite to make lstm (graves and graves, 2012) online. composite task. fairness in machine learning, positive-unlabeled learning, and online learning are three distinct yet deeply interconnected fields. @xcite and @xcite discussed fairness in online learning but not in real-time manner. @xcite proposed online pu learning, viable only for linear classifiers, but the fairness concern is not discussed. although @xcite suggested a post-processing framework attaining fairness in pu learning, it is based on scar assumption which is impractical @xcite , and not feasible to online learning framework and pu risk estimators. ## theoretical analysis in the previous literature, the fairness violation in online learning has not been studied. although @xcite shows a o( √ t log t ) bound of long-term fairness constraint, it is limited to the online meta-learning and not applicable to real-time online learning like fopu. furthermore, the impact of online learning with neural networks on fairness has not been studied either at each round. we prove that the cumulative fairness regret bound ## conclusion in this study, we address the issue of fairness in positive-unlabeled (pu) learning in text classification, particularly in the challenging context of online learning. we emphasize the necessity of strategies that ensure fairness in scenarios where data is incrementally provided, and only positive and unlabeled data are available. our approach aims to enhance fairness in pu learning and extend it to online learning for both linear and deep neural network classifiers. we demonstrate that incorporating a convex fairness constraint during the training significantly improves fairness metrics (∆eod) while maintaining the f1-score. additionally, we delve into the mathematical foundations of fairness in online settings by proving a cumulative fairness loss, i.e. fair regret bound.