Abstract
Detecting out-of-distribution (OOD) samples is crucial for ensuring safety and robustness of models deployed in real-world scenarios. While most OOD detection studies focus on fine-tuned models trained on in-distribution (ID) data, detecting OOD in pre-trained models is also important due to computational limits and the widespread use of open-source models. However, pre-trained models often underperform in same domain shift scenarios, as both ID and OOD samples originate from the same domain, leading to high overlap in their embeddings. To address this issue, we propose CED, a training-free OOD detection method that enhances the distinction between ID and OOD samples. We theoretically validate that strategically selected auxiliary and oracle samples improve this separation. On the basis of our theoretical analysis, CED utilizes these specially designed samples to significantly improve the ability of pre-trained models to differentiate ID from OOD samples in text classification and hallucination detection tasks. We verify that CED is a plug-and-play method compatible with various backbone networks like RoBERTa, Llama, and OpenAI Embedding.
Original language | English |
---|---|
Title of host publication | EMNLP 2024 - 2024 Conference on Empirical Methods in Natural Language Processing, Findings of EMNLP 2024 |
Editors | Yaser Al-Onaizan, Mohit Bansal, Yun-Nung Chen |
Publisher | Association for Computational Linguistics (ACL) |
Pages | 14866-14882 |
Number of pages | 17 |
ISBN (Electronic) | 9798891761681 |
DOIs | |
Publication status | Published - 2024 |
Event | 2024 Findings of the Association for Computational Linguistics, EMNLP 2024 - Hybrid, Miami, United States Duration: 2024 Nov 12 → 2024 Nov 16 |
Publication series
Name | EMNLP 2024 - 2024 Conference on Empirical Methods in Natural Language Processing, Findings of EMNLP 2024 |
---|
Conference
Conference | 2024 Findings of the Association for Computational Linguistics, EMNLP 2024 |
---|---|
Country/Territory | United States |
City | Hybrid, Miami |
Period | 24/11/12 → 24/11/16 |
Bibliographical note
Publisher Copyright:© 2024 Association for Computational Linguistics.
All Science Journal Classification (ASJC) codes
- Computational Theory and Mathematics
- Computer Science Applications
- Information Systems
- Linguistics and Language