Unsupervised Layer-wise Score Aggregation for Textual OOD Detection
Darrin, Maxime, Staerman, Guillaume, Gomes, Eduardo Dadalto Câmara, Cheung, Jackie CK, Piantanida, Pablo, Colombo, Pierre
–arXiv.org Artificial Intelligence
Out-of-distribution (OOD) detection for text applications is a rapidly growing field due to new robustness and security requirements driven by an increased number of AI-based systems. Existing OOD textual detectors often rely on an anomaly score (e.g., Mahalanobis distance) computed on the embedding output of the last layer of the encoder. In this work, we begin by uncovering that the fact that performance of existent methods varies greatly depending on the task and choice of the layer output. More importantly, we show that the usual choice (the last layer) is rarely the best one and thus, far better results could be achieved if the best layer were chosen. To leverage our key observation, we propose a data-driven, unsupervised method to combine layer-wise anomaly scores. In addition, we extend classical textual OOD benchmarks by including classification tasks with a greater number of classes (up to 77), which reflects more realistic settings. On this augmented benchmark, we show that the proposed post-aggregation methods achieve robust and consistent results while removing manual feature selection altogether. Their performance achieves near oracle's best layer performance.
arXiv.org Artificial Intelligence
May-29-2023
- Country:
- North America > United States (1.00)
- Genre:
- Research Report (0.82)
- Industry:
- Information Technology (0.46)
- Technology:
- Information Technology
- Artificial Intelligence
- Machine Learning
- Neural Networks (0.93)
- Performance Analysis > Accuracy (1.00)
- Statistical Learning (1.00)
- Natural Language (1.00)
- Representation & Reasoning (1.00)
- Machine Learning
- Data Science > Data Mining (1.00)
- Artificial Intelligence
- Information Technology